db9f1f9db14763ccebeedc885ca748a5db1d1763
[pspp] / ChangeLog
1 2007-08-19  Bruno Haible  <bruno@clisp.org>
2
3         * tests/test-lseek.c (main): Disable a test for BeOS.
4         * doc/functions/lseek.texi: Document the BeOS bug.
5
6 2007-08-19  Bruno Haible  <bruno@clisp.org>
7             Eric Blake  <ebb9@byu.net>
8
9         * lib/lseek.c: Include <sys/stat.h>.
10         (rpl_lseek): Add workaround code also for Unix platforms.
11         Needed for BeOS.
12         * m4/lseek.m4 (gl_FUNC_LSEEK): When cross-compiling, fail on BeOS.
13         * doc/functions/lseek.texi: Document BeOS definiency.
14
15 2007-08-18  Bruno Haible  <bruno@clisp.org>
16
17         * modules/fstrcmp-tests: New file.
18         * tests/test-fstrcmp.c: New file.
19
20 2007-08-18  Bruno Haible  <bruno@clisp.org>
21
22         * modules/fstrcmp: New file, from GNU gettext with modifications.
23         * lib/fstrcmp.h: New file, from GNU gettext.
24         * lib/fstrcmp.c: New file, from GNU gettext.
25         * MODULES.html.sh (String handling): Add fstrcmp.
26
27 2007-08-18  Bruno Haible  <bruno@clisp.org>
28
29         * lib/diffseq.h (struct context): Change type of 'heuristic' field to
30         'bool'.
31         (diag, compareseq): Remove const from the ctxt argument.
32         (USE_HEURISTIC): Undefine at the end.
33
34 2007-08-18  Jim Meyering  <jim@meyering.net>
35
36         New file: lib/idcache.h
37         * NEWS: Mention the addition.
38         * modules/idcache (Files): Add lib/idcache.h
39         * lib/idcache.c: Include "idcache.h".
40         Don't include <sys/types.h>.
41         Add a FIXME comment.
42         Move file-scoped "static" declarations to the top.
43         * lib/idcache.h: New file.  Include <sys/types.h> here, instead.
44
45 2007-08-17  Bruno Haible  <bruno@clisp.org>
46         and Paul Eggert  <eggert@cs.ucla.edu>
47
48         * MODULES.html.sh: Add diffseq.
49         * modules/diffseq: New file.
50         * lib/diffseq.h: New file, from GNU gettext with a few minor changes,
51         extracted from GNU gettext's fstrcmp.c and GNU diff's analyze.c.
52
53 2007-08-15  Paul Eggert  <eggert@cs.ucla.edu>
54
55         Import changes from coreutils for bootstrap script.
56
57         2007-07-21  Paul Eggert  <eggert@cs.ucla.edu>
58
59         * build-aux/bootstrap (slurp): Work even in environments where
60         "ls" defaults to "ls -A".  Put in a FIXME, though, since the
61         current code does not slurp files whose names start with ".", and
62         this looks like it might be a troublesome area.
63
64         2007-07-11  Jim Meyering  <jim@meyering.net>
65
66         If there's a GPL vN copyright comment, require that N == 3.
67
68         2007-07-08  Jim Meyering  <jim@meyering.net>
69
70         Run the coreutils-specific code only if tests/Makefile.am.in exists.
71         * build-aux/bootstrap (mam_template): Move definition out of loop.
72
73         Create symlinks for gl/{lib,m4}/*, just as for gnulib/{lib,m4}/*.
74
75         * build-aux/bootstrap (symlink_to_dir): Rename function from
76         symlink_to_gnulib.  Add a directory parameter.  Update all
77         callers.
78         (cp_mark_as_generated): Also check for -- and link to -- files in
79         gl/.
80
81         2007-07-08  Jim Meyering  <jim@meyering.net>
82
83         Adapt to deeper hierarchy in gnulib.
84         * build-aux/bootstrap (symlink_to_dir): If the destination
85         directory doesn't exist, create it. This is required at least for
86         "lib/uniwidth/cjk.h".
87
88         2007-05-15  Jim Meyering  <jim@meyering.net>
89
90         * build-aux/bootstrap: Now that generated Makefile.am files
91         are no longer under version control, they must be created at
92         bootstrap time.
93
94 2007-08-14  Ben Pfaff  <blp@gnu.org>
95
96         * lib/count-one-bits.h: Add comments.  From Bruno Haible.
97
98 2007-08-14  Paul Eggert  <eggert@cs.ucla.edu>
99
100         * lib/count-one-bits.h: Don't include <limits.h>; no longer needed
101         given the changes below.
102         (COUNT_ONE_BITS): Use 'verify' rather than 'verify_true'.  Work
103         even on hosts that have padding bits beyond the supported 64.
104
105 2007-08-10  Paul Eggert  <eggert@cs.ucla.edu>
106
107         * NEWS: In xstrtol, remove STRTOL_FATAL_ERROR and add xstrtol_fatal.
108         * lib/xstrtol.h: Don't include exitfail.h; that's now internal to
109         xstrtol.c.  Include getopt.h, since xstrtol_fatal's signature
110         depends on it.
111         (xstrtol_error): Remove.
112         (xstrtol_fatal): New decl, replacing the functionality of xstrtol_error
113         but with a different signature.
114         (ATTRIBUTE_NORETURN, __attribute__): New macros.
115         * lib/xstrtol-error.c: Include exitfail.h.
116         (xstrtol_fatal): New function, with a different signature from the
117         old xstrtol_error, so that the caller need not worry about passing
118         in an exit status, or about storage management of the option argument.
119         (xstrtol_error): Now a static function.  Redo signature to
120         implement xstrtol_fatal.  Output the correct number of hyphens in
121         front of the option so that the caller need not worry about
122         storage management.
123         (N_): New macro.
124         (_): Remove; not used now.
125         * modules/xstrtol: Depend on getopt.
126         * tests/test-xstrtol.c (main): Use new xstrtol_error function instead
127         of old STRTOL_FATAL_ERROR macro.
128         * tests/test-xstrtol.sh (t-xstrtol.xo): Adjust to match new behavior
129         of test program.
130         * tests/test-xstrtoimax.sh (t-xstrtoimax.xo): Likewise.
131         * tests/test-xstrtoumax.sh (t-xstrtoumax.xo): Likewise.
132
133 2007-08-08  Eric Blake  <ebb9@byu.net>
134
135         * lib/xstrtol-error.c: Add missing include.
136
137         Move xstrtol messages into gnulib domain, when --pobase is used.
138         * lib/xstrtol.h (_STRTOL_ERROR): Move messages out of macro...
139         * lib/xstrtol-error.c (xstrtol_error): ...into new file.
140         * modules/xstrtol (Files): Distribute new file.
141         * m4/xstrtol.m4 (gl_XSTRTOL): Build new file.
142         * lib/xstrtol.c (TESTING_XSTRTO): Move tests...
143         * tests/test-xstrtol.c: ...into new file.
144         * tests/test-xstrtoul.c: Also test xstrtoul.
145         * tests/test-xstrtoimax.c: Also test xstrtoimax.
146         * tests/test-xstrtoumax.c: Also test xstrtoumax.
147         * tests/test-xstrtol.sh: Drive the tests.
148         * tests/test-xstrtoimax.sh: Likewise.
149         * tests/test-xstrtoumax.sh: Likewise.
150         * modules/xstrtol-tests: New module.
151         * modules/xstrtoimax-tests: Likewise.
152         * modules/xstrtoumax-tests: Likewise.
153
154 2007-08-08  Jim Meyering  <jim@meyering.net>
155
156         New function: mfile_name_concat.
157         * lib/filenamecat.c (mfile_name_concat): New function, just like
158         file_name_concat, but return NULL upon failure rather than exiting
159         with a diagnostic.
160         * lib/filenamecat.h: Declare it.
161
162 2007-08-07  Bruno Haible  <bruno@clisp.org>
163
164         * m4/inttypes.m4 (gl_INTTYPES_H): Use GL_TRIGGER_STDC_LIMIT_MACROS
165         instead of __STDC_LIMIT_MACROS_TRIGGER. This avoids a redefinition
166         warning from gcc.
167         Reported by Eric Blake.
168
169 2007-08-07  Simon Josefsson  <simon@josefsson.org>
170
171         * modules/crypto/arctwo (License): Use the synonymous term "LGPLv2+".
172         * modules/crypto/arcfour (License): Likewise.
173         * modules/crypto/des-tests (License): Likewise.
174         * modules/crypto/gc-arctwo-tests (License): Likewise.
175         * modules/crypto/gc-des-tests (License): Likewise.
176         * modules/crypto/gc-hmac-md5-tests (License): Likewise.
177         * modules/crypto/gc-hmac-sha1-tests (License): Likewise.
178         * modules/crypto/gc-md2-tests (License): Likewise.
179         * modules/crypto/gc-md4-tests (License): Likewise.
180         * modules/crypto/gc-md5-tests (License): Likewise.
181         * modules/crypto/gc-pbkdf2-sha1-tests (License): Likewise.
182         * modules/crypto/gc-rijndael-tests (License): Likewise.
183         * modules/crypto/gc-sha1-tests (License): Likewise.
184         * modules/crypto/gc-tests (License): Likewise.
185         * modules/crypto/hmac-md5 (License): Likewise.
186         * modules/crypto/hmac-sha1 (License): Likewise.
187         * modules/crypto/md2-tests (License): Likewise.
188         * modules/crypto/md4-tests (License): Likewise.
189         * modules/crypto/md5 (License): Likewise.
190         * modules/crypto/rijndael (License): Likewise.
191         * modules/crypto/sha1 (License): Likewise.
192         * modules/memxor (License): Likewise.
193
194 2007-08-06  Paul Eggert  <eggert@cs.ucla.edu>
195         and Bruno Haible  <bruno@clisp.org>
196
197         * NEWS: Describe interface changes to human, xstrtol.
198         * lib/human.h: Include <xstrtol.h>.
199         (human_options): Return enum strtol_error, not int.  Remove
200         bool arg; take int * instead.
201         * lib/human.c: Don't include "gettext.h".
202         (_): Remove; no longer used.
203         Don't include <xstrtol.h>, since human.h does it.
204         (human_options): Adjust to abovementioned interface changes.
205         Do not report error to stderr; that's now the caller's
206         responsibility.
207         * lib/xstrtol.c (main) [defined TESTING_XSTRTO]: Adjust to
208         interface change.
209         * lib/xstrtol.h (_STRTOL_ERROR): Take Option, Arg rather than
210         Str, Argument_type_string.  All uses changed.  Put " argument"
211         in diagnostics to make them clearer.  Change wording of suffix
212         message for clarity.
213         (STRTOL_FATAL_ERROR): Take Option, Arg rather than Str,
214         Argument_type_string.
215         (STRTOL_FATAL_WARN): Remove; no longer used.
216         * modules/human (Depends-on): Remove gettext-h.
217
218 2007-08-06  Simon Josefsson  <simon@josefsson.org>
219
220         * build-aux/maint.mk, build-aux/GNUmakefile: Relicense to GPLv3+.
221
222 2007-07-31  Bruno Haible  <bruno@clisp.org>
223
224         * m4/stdint.m4 (gl_STDINT_H): Test whether WCHAR_MIN and WCHAR_MAX
225         are defined by <stdint.h> (as opposed to <wchar.h>, as on Dragonfly).
226         Reported by Joerg Sonnenberger <joerg@britannica.bec.de>.
227
228 2007-07-31  Bruno Haible  <bruno@clisp.org>
229
230         * lib/fflush.c (rpl_fflush): On BSD systems, use the __SNPT flag.
231         Suggested by Joerg Sonnenberger <joerg@britannica.bec.de>.
232
233 2007-07-30  Bruno Haible  <bruno@clisp.org>
234
235         * modules/base64 (License): Use the synonymous term "LGPLv2+".
236         * modules/c-ctype (License): Likewise.
237         * modules/c-strcase (License): Likewise.
238         * modules/check-version (License): Likewise.
239         * modules/iconv (License): Likewise.
240         * modules/iconv_open (License): Likewise.
241         * modules/read-file (License): Likewise.
242         * modules/striconv (License): Likewise.
243         * modules/strverscmp (License): Likewise.
244         * modules/vasprintf (License): Likewise.
245         * modules/crypto/des (License): Likewise.
246         * modules/crypto/gc (License): Likewise.
247         * modules/crypto/gc-arcfour (License): Likewise.
248         * modules/crypto/gc-arctwo (License): Likewise.
249         * modules/crypto/gc-des (License): Likewise.
250         * modules/crypto/gc-hmac-md5 (License): Likewise.
251         * modules/crypto/gc-hmac-sha1 (License): Likewise.
252         * modules/crypto/gc-md2 (License): Likewise.
253         * modules/crypto/gc-md4 (License): Likewise.
254         * modules/crypto/gc-md5 (License): Likewise.
255         * modules/crypto/gc-pbkdf2-sha1 (License): Likewise.
256         * modules/crypto/gc-random (License): Likewise.
257         * modules/crypto/gc-rijndael (License): Likewise.
258         * modules/crypto/gc-sha1 (License): Likewise.
259         * modules/crypto/md2 (License): Likewise.
260         * modules/crypto/md4 (License): Likewise.
261
262 2007-07-30  Jim Meyering  <jim@meyering.net>
263
264         * lib/fts.c (fts_read): Upon failure to chdir into a subdirectory,
265         set fts_info to FTS_DNR, not to FTS_ERR, so that the caller knows
266         it has valid stat data.  This bug would cause du not to count the
267         sizes of inaccessible directories.
268         Patch by Bryan Mason <bmason@redhat.com>, via Jose Maria Plans
269         in <http://bugzilla.redhat.com/250077>.
270
271 2007-07-25  Peter O'Gorman  <peter@pogma.com>
272             Bruno Haible  <bruno@clisp.org>
273
274         * m4/include_next.m4 (gl_INCLUDE_NEXT): Test whether #include_next
275         really works. Needed because AIX 4.3 "xlc -E" doesn't understand
276         #include_next, gives a diagnostic about it, but reports no error in
277         the exit code.
278         Reported by Gary V. Vaughan <gary@thewrittenword.com>.
279
280 2007-07-24  Ben Pfaff  <blp@gnu.org>
281
282         Improve name: "count-one-bits" is better than "popcount".
283         * MODULES.html.sh: Update name.
284         * lib/popcount.h: Renamed lib/count-one-bits.h.
285         (popcount): Renamed count_one_bits.
286         (popcountl): Renamed count_one_bits_l.
287         (popcountll): Renamed count_one_bits_ll.
288         * m4/popcount.m4: Renamed m4/count-one-bits.m4.
289         * modules/popcount: Renamed module/count-one-bits.
290         * modules/popcount-tests: Renamed module/count-one-bits-tests.
291         * tests/test-popcount.c: Renamed tests/test-count-one-bits.c.
292
293 2007-07-23  Ben Pfaff  <blp@gnu.org>
294
295         * lib/popcount.h (popcount32): Reduce size of constants, to allow
296         better code generation, and add U to large constants to avoid
297         warnings, in non-GCC case.
298         Suggested by Bruno Haible.
299
300 2007-07-23  Ben Pfaff  <blp@gnu.org>
301
302         * lib/popcount.h: Use verify_true instead of if...abort.
303         * modules/popcount: Depend on verify module.
304         Suggested by Jim Meyering.
305
306 2007-07-23  Bruno Haible  <bruno@clisp.org>
307
308         * gnulib-tool (func_import): Create a .cvsignore file also when the
309         directory is not yet in CVS but the toplevel directory is. When
310         creating a .cvsignore file, add ".deps" and ".dirstamp" to it.
311         Reported by Karl Berry.
312
313 2007-07-22  Ben Pfaff  <blp@gnu.org>
314
315         * lib/popcount.h: Use faster, branchless algorithm for non-GCC
316         case.
317         Suggested by Eric Blake.
318
319 2007-07-22  Ben Pfaff  <blp@gnu.org>
320
321         New module: popcount.
322         * MODULES.html.sh: Add popcount.
323         * modules/popcount: New file.
324         * modules/popcount-tests: New file.
325         * tests/test-popcount.c: New file.
326         * lib/popcount.h: New file.
327         * m4/popcount.m4: New file.
328
329 2007-07-22  Paul Eggert  <eggert@cs.ucla.edu>
330
331         * build-aux/announce-gen: Update to GPLv3.
332
333         * build-aux/config.guess: Update from config.
334
335 2007-07-21  Bruno Haible  <bruno@clisp.org>
336
337         * lib/error.c (_) [ENABLE_NLS]: Define to gettext.
338         * lib/verror.c (_) [ENABLE_NLS]: Likewise.
339
340 2007-07-20  Jim Meyering  <jim@meyering.net>
341
342         * check-module: Diagnose a self-dependency.
343
344 2007-07-19  Bruno Haible  <bruno@clisp.org>
345
346         * gnulib-tool (func_import): Don't abort if pobase or po_domain is
347         empty.
348         Reported by Eric Blake.
349
350 2007-07-18  Bruno Haible  <bruno@clisp.org>
351
352         * gnulib-tool: New options --po-base, --po-domain.
353         (func_usage): Document them.
354         (pobase, po_domain): New variables.
355         (func_emit_lib_Makefile_am): Augment AM_CPPFLAGS, defining
356         DEFAULT_TEXT_DOMAIN.
357         (func_emit_po_Makevars, func_emit_po_POTFILES_in): New functions.
358         (func_import): Consider pobase and po_domain. Create a po/ directory.
359         (func_create_testdir): Set pobase and po_domain to empty.
360         * build-aux/po/Makefile.in.in: New file, from GNU gettext 0.16.1.
361         * build-aux/po/remove-potcdate.sin: New file, from GNU gettext 0.16.1.
362
363 2007-07-18  Bruno Haible  <bruno@clisp.org>
364
365         * gnulib-tool (func_get_automake_snippet): Synthesize also an
366         EXTRA_DIST augmentation for files in build-aux/.
367
368 2007-07-16  Bruno Haible  <bruno@clisp.org>
369
370         * modules/lseek (License): Use the synonymous term "LGPLv2+".
371         * modules/getdelim (License): Likewise.
372
373 2007-07-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
374
375         * modules/arpa_inet (License): Use the synonymous term LGPLv2+.
376         * modules/d-type (License): Likewise.
377         * modules/extensions (License): Likewise.
378         * modules/fnmatch (License): Likewise.
379         * modules/fseeko (License): Likewise.
380         * modules/getaddrinfo (License): Likewise.
381         * modules/getline (License): Likewise.
382         * modules/getlogin_r (License): Likewise.
383         * modules/getpass (License): Likewise.
384         * modules/gettimeofday (License): Likewise.
385         * modules/glob (License): Likewise.
386         * modules/inet_ntop (License): Likewise.
387         * modules/malloc (License): Likewise.
388         * modules/malloca (License): Likewise.
389         * modules/memmem (License): Likewise.
390         * modules/mempcpy (License): Likewise.
391         * modules/memset (License): Likewise.
392         * modules/minmax (License): Likewise.
393         * modules/mktime (License): Likewise.
394         * modules/netinet_in (License): Likewise.
395         * modules/pathmax (License): Likewise.
396         * modules/poll (License): Likewise.
397         * modules/regex (License): Likewise.
398         * modules/snprintf (License): Likewise.
399         * modules/stdbool (License): Likewise.
400         * modules/stdint (License): Likewise.
401         * modules/stdio (License): Likewise.
402         * modules/strcase (License): Likewise.
403         * modules/strcasestr (License): Likewise.
404         * modules/strdup (License): Likewise.
405         * modules/string (License): Likewise.
406         * modules/strndup (License): Likewise.
407         * modules/strnlen (License): Likewise.
408         * modules/strpbrk (License): Likewise.
409         * modules/strptime (License): Likewise.
410         * modules/strsep (License): Likewise.
411         * modules/sys_select (License): Likewise.
412         * modules/sys_socket (License): Likewise.
413         * modules/sys_stat (License): Likewise.
414         * modules/sys_time (License): Likewise.
415         * modules/time (License): Likewise.
416         * modules/time_r (License): Likewise.
417         * modules/timegm (License): Likewise.
418         * modules/unistd (License): Likewise.
419         * modules/vsnprintf (License): Likewise.
420         * modules/wctype (License): Likewise.
421
422 2007-07-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
423
424         * modules/argz (License): LGPLv2+.
425
426 2007-07-15  Karl Berry  <karl@gnu.org>
427
428         * doc/gnulib.texi: revise node structure per new fdl.texi.
429
430 2007-07-14  Bruno Haible  <bruno@clisp.org>
431
432         * lib/uniname/gen-uninames.lisp (main): Emit a "do not edit" line to
433         the output file.
434         * lib/uniname/uninames.h: Regenerated.
435
436 2007-07-14  Karl Berry  <karl@gnu.org>
437
438         * doc/*gpl*.texi, doc/fdl.texi: new versions, consistently
439         omitting sectioning and index commands.
440
441 2007-07-13  Bruno Haible  <bruno@clisp.org>
442
443         New gnulib-tool option --more-symlinks.
444         * gnulib-tool (func_usage): Document --more-symlinks.
445         (do_copyrights): New variable.
446         Recognize option --more-symlinks.
447         (func_import): Don't add a copyright notice transform to
448         sed_transform_lib_file if do_copyrights is empty.
449
450 2007-07-13  Bruno Haible  <bruno@clisp.org>
451
452         * lib/vasnprintf.c (decimal_point_char): Define also if
453         (NEED_PRINTF_LONG_DOUBLE || NEED_PRINTF_INFINITE_DOUBLE)
454         && !NEED_PRINTF_DIRECTIVE_A.
455         Reported by Clemens Koller <clemens.koller@anagramm.de> via
456         Gary V. Vaughan <gary@gnu.org>.
457
458 2007-07-13  Paul Eggert  <eggert@cs.ucla.edu>
459
460         * lib/inttypes_.h: Undo previous change, since it was fixed
461         in a different way in the 2007-07-02 fix to m4/inttypes.m4.
462
463 2007-07-13  Bruno Haible  <bruno@clisp.org>
464
465         * lib/stdint_.h: Fix typo: _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H was
466         misspelled as _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H.
467
468 2007-07-13  Jim Meyering  <jim@meyering.net>
469
470         df: Don't fail for Tru64's "file-on-file mount".
471         * m4/fsusage.m4 (gl_FSUSAGE): Reject Tru64's buggy statvfs,
472         so we fall through and use statfs instead.  Details here:
473         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/10878>
474         Reported by Albert Chin.
475
476 2007-07-13  Bruno Haible  <bruno@clisp.org>
477
478         * modules/alloca-opt (License): Use the synonymous term "LGPLv2+".
479         * modules/configmake (License): Likewise.
480         * modules/gettext (License): Likewise.
481         * modules/gettext-h (License): Likewise.
482         * modules/include_next (License): Likewise.
483         * modules/link-warning (License): Likewise.
484         * modules/localcharset (License): Likewise.
485         * modules/localename (License): Likewise.
486         * modules/lock (License): Likewise.
487         * modules/relocatable-lib-lgpl (License): Likewise.
488         * modules/size_max (License): Likewise.
489         * modules/vasnprintf (License): Likewise.
490         * modules/wchar (License): Likewise.
491         * modules/xsize (License): Likewise.
492
493 2007-07-13  Bruno Haible  <bruno@clisp.org>
494
495         * gnulib-tool (func_import): Treat LGPLv2 as synonymous to LGPL.
496         (func_create_testdir): Handle copying terms "GPLv2+" and "LGPLv2+".
497
498 2007-07-12  Bruno Haible  <bruno@clisp.org>
499
500         * doc/gnulib-intro.texi (Copyright): Clarify the license abbreviations
501         in the modules files.
502
503 2007-07-11  Karl Berry  <karl@gnu.org>
504
505         * MODULES.html.sh (func_module): use
506          sed -e '\|^'"${includefile}"'$|d'
507          instead of /.../d, to avoid errors on $includefile's containing /.
508
509 2007-07-10  Sergey Poznyakoff  <gray@gnu.org.ua>
510
511         * gnulib-tool (func_import): Avoid duplication of --avoid
512         statements
513         (func_dest_tmpfilename,func_create_testdir): Translate `-' in file
514         names to `_' in variable names.
515
516 2007-07-10  Eric Blake  <ebb9@byu.net>
517
518         * lib/version-etc.c (version_etc_va): Default to GPLv3+.
519         * NEWS: Document this change.
520
521 2007-07-08  Bruno Haible  <bruno@clisp.org>
522
523         Update to Unicode 5.0.
524         * lib/uniwidth/width.c (nonspacing_table_data): Add U+00AD,
525         U+0350..U+035F, U+05A2, U+05BA, U+05C5, U+05C7, U+0600..U+0603,
526         U+0610..U+0615, U+0656..U+065E, U+07EB..U+07F3, U+0A01, U+0AE2..U+0AE3,
527         U+0CBC. Remove U+0CBF, U+0CC6. Add U+0CE2..U+0CE3, U+135F,
528         U+17B4..U+17B5, U+17DD. Remove U+180E. Add U+1920..U+1922,
529         U+1927..U+192B, U+1932, U+1939..U+193B, U+1A17..U+1A18, U+1B00..U+1B03,
530         U+1B34, U+1B36..U+1B3A, U+1B3C, U+1B42, U+1B6B..U+1B73, U+1DC0..U+1DCA,
531         U+1DFE..U+1DFF, U+20EB..U+20EF, U+A802, U+A806, U+A80B, U+A825..U+A826,
532         U+10A01..U+10A03, U+10A05..U+10A06, U+10A0C..U+10A0F, U+10A38..U+10A3A,
533         U+10A3F, U+1D242..U+1D244.
534         (nonspacing_table_ind): Update.
535         (uc_width): Assign width 0 to U+E0100..U+E01EF. Assign width 1 to
536         U+4DC0..U+4DFF. Assign width 2 to U+2329..U+232A, U+FE10..U+FE1F.
537
538 2007-07-08  Bruno Haible  <bruno@clisp.org>
539
540         Update to Unicode 5.0.
541         * lib/uniname/gen-uninames.lisp (main): Add the range 0x12xxx to the
542         code transform. Extend the name index field of unicode_name_to_code and
543         unicode_code_to_name from 16 to 24 bits.
544         * lib/uniname/uniname.c (unicode_character_name,
545         unicode_name_character): Add the range 0x12xxx to the code transform.
546         * lib/uniname/uninames.h: Regenerated.
547         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.0.
548
549 2007-07-07  Bruno Haible  <bruno@clisp.org>
550
551         * modules/wcwidth-tests: New file.
552         * tests/test-wcwidth.c: New file.
553
554         Work around MacOS X wcwidth() bug.
555         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test against MacOS X 10.3 bug.
556         * lib/wcwidth.c: Include localcharset.h, streq.h, uniwidth.h.
557         (rpl_wcwidth): Special-case the UTF-8 locales. Fall back to the
558         original wcwidth in non-UTF-8 locales.
559         * modules/wcwidth (Depends-on): Add localcharset, streq,
560         uniwidth/width.
561         * doc/functions/wcwidth.texi: Update.
562
563 2007-07-07  Bruno Haible  <bruno@clisp.org>
564
565         * lib/wchar_.h: Include the GL_LINK_WARNING macro.
566         (wcwidth): New declaration.
567         * m4/wchar.m4 (gl_WCHAR_MODULE_INDICATOR, gl_WCHAR_H_DEFAULTS): New
568         macros.
569         (gl_WCHAR_H): Require gl_WCHAR_H_DEFAULTS. Don't set WCHAR_H to empty
570         here. Prepare for creating <wchar.h> unconditionally.
571         * modules/wchar (Depends-on): Add link-warning.
572         (Makefile.am): Substitute also GNULIB_WCWIDTH, HAVE_DECL_WCWIDTH,
573         REPLACE_WCWIDTH, and GL_LINK_WARNING.
574         * lib/wcwidth.h: Remove file.
575         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gl_WCHAR_H_DEFAULTS. Set
576         HAVE_DECL_WCWIDTH, REPLACE_WCWIDTH, WCHAR_H.
577         * modules/wcwidth (Files): Remove lib/wcwidth.h.
578         (configure.ac): Invoke gl_WCHAR_MODULE_INDICATOR.
579         (Include): Replace wcwidth.h with <wchar.h>.
580         * lib/wcwidth.c: Include <wchar.h> instead of wcwidth.h.
581         * lib/mbchar.h: Don't include wcwidth.h.
582         * lib/mbswidth.c: Likewise.
583         * NEWS: Mention the change.
584
585 2007-07-07  Bruno Haible  <bruno@clisp.org>
586
587         * lib/wcwidth.c: New file, extracted from lib/wcwidth.h.
588         * lib/wcwidth.h: Don't include wctype.h. Replace inline function
589         definition with an external declaration.
590         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Use wcwidth.c when wcwidth is not
591         defined as a function. Remove AC_C_INLINE requirement.
592         * modules/wcwidth (Files): Add lib/wcwidth.c.
593         (Makefile.am): Remove redundant statement.
594
595 2007-07-07  Bruno Haible  <bruno@clisp.org>
596
597         * MODULES.html.sh (Unicode string functions): Add the new modules.
598
599         * tests/uniwidth/test-u32-strwidth.c: New file.
600         * modules/uniwidth/u32-strwidth-tests: New file.
601
602         * lib/uniwidth/u32-strwidth.c: New file.
603         * modules/uniwidth/u32-strwidth: New file.
604
605         * tests/uniwidth/test-u16-strwidth.c: New file.
606         * modules/uniwidth/u16-strwidth-tests: New file.
607
608         * lib/uniwidth/u16-strwidth.c: New file.
609         * modules/uniwidth/u16-strwidth: New file.
610
611         * tests/uniwidth/test-u8-strwidth.c: New file.
612         * modules/uniwidth/u8-strwidth-tests: New file.
613
614         * lib/uniwidth/u8-strwidth.c: New file.
615         * modules/uniwidth/u8-strwidth: New file.
616
617         * tests/uniwidth/test-u32-width.c: New file.
618         * modules/uniwidth/u32-width-tests: New file.
619
620         * lib/uniwidth/u32-width.c: New file.
621         * modules/uniwidth/u32-width: New file.
622
623         * tests/uniwidth/test-u16-width.c: New file.
624         * modules/uniwidth/u16-width-tests: New file.
625
626         * lib/uniwidth/u16-width.c: New file.
627         * modules/uniwidth/u16-width: New file.
628
629         * tests/uniwidth/test-u8-width.c: New file.
630         * modules/uniwidth/u8-width-tests: New file.
631
632         * lib/uniwidth/u8-width.c: New file.
633         * modules/uniwidth/u8-width: New file.
634
635         * tests/uniwidth/test-uc_width.c: New file.
636         * modules/uniwidth/width-tests: New file.
637
638         * lib/uniwidth/width.c: New file, from GNU libiconv.
639         * lib/uniwidth/cjk.h: New file, from GNU libiconv.
640         * modules/uniwidth/width: New file.
641
642         * lib/uniwidth.h: New file, from GNU libiconv.
643         * modules/uniwidth/base: New file.
644
645 2007-07-07  Bruno Haible  <bruno@clisp.org>
646
647         * lib/uniname.h: New file, from GNU gettext.
648         * lib/uniname/gen-uninames.lisp: New file, from GNU gettext.
649         * lib/uniname/uninames.h: New file, from GNU gettext.
650         * lib/uniname/uniname.c: New file, from GNU gettext.
651         * tests/uniname/test-uninames.sh: New file.
652         * tests/uniname/test-uninames.c: New file, from GNU gettext.
653         * tests/uniname/UnicodeDataNames.txt: New file, from GNU gettext.
654         * modules/uniname/base: New file.
655         * modules/uniname/uniname: New file.
656         * modules/uniname/uniname-tests: New file.
657         * MODULES.html.sh (Unicode string functions): Add the new modules.
658
659 2007-07-06  Bruno Haible  <bruno@clisp.org>
660
661         * doc/Makefile (TEXI2HTML): Specify a --reference-limit.
662
663 2007-07-06  Bruno Haible  <bruno@clisp.org>
664
665         * lib/sys_time_.h: Use a recursion-safe inclusion guard rather than
666         a split double-inclusion guard. Needed for cygwin, where <sys/time.h>
667         includes <cygwin/sys_time.h> which includes <sys/select.h> which
668         include <sys/time.h>.
669         Reported by Eric Blake.
670
671 2007-07-06  Eric Blake  <ebb9@byu.net>
672
673         Fix testing canonicalize on cygwin.
674         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
675         Revert patch from 2007-06-19.
676         * tests/test-canonicalize-lgpl.c (main): Instead, skip test when
677         canonicalize module is also in use.
678         * tests/test-canonicalize.c: New file.
679         * tests/test-canonicalize.sh: Likewise.
680         * modules/canonicalize-tests: Likewise.
681
682 2007-07-06  Jim Meyering  <jim@meyering.net>
683
684         * lib/getugroups.c (getugroups): Detect getgrent failure.
685         Adjust comment to reflect reality: this function may return -1.
686
687 2007-07-05  Sergey Poznyakoff  <gray@gnu.org.ua>
688
689         * build-aux/bootstrap (TP_URL,get_translations): Update to use
690         the new TP address.
691         (usage): Fix typo
692         (gnulib_mk): New variable.
693
694 2007-07-05  Jim Meyering  <jim@meyering.net>
695
696         Don't let endgrent clobber errno, no matter how improbable.
697         * lib/getugroups.c (getugroups): Save and restore errno around
698         endgrent call.
699
700         Close the group DB even when failing with 2^31 or more members.
701         * lib/getugroups.c (getugroups): Don't return without calling endgrent.
702
703 2007-07-04  Jim Meyering  <jim@meyering.net>
704
705         * lib/getugroups.h: New file.
706         * lib/getugroups.c: Include "getugroups.h".
707         Remove uses of "register" keyword.
708         Move local variable, "cp", down into scope where used.
709         Give "username" parameter the "const" attribute.
710         * modules/getugroups (Files): Add lib/getugroups.h
711
712 2007-07-04  Karl Berry  <karl@gnu.org>
713
714         * MODULES.html.sh (func_all_modules): Complete rename of
715         gpl/lgpl to gpl-2.0 and lgpl-2.1, and add gpl-3.0.
716
717 2007-07-02  Bruno Haible  <bruno@clisp.org>
718
719         * m4/inttypes.m4 (gl_INTTYPES_H): Define __STDC_LIMIT_MACROS in C++
720         mode, when inttypes.h comes from gnulib.
721         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
722
723 2007-07-02  Simon Josefsson  <simon@josefsson.org>
724
725         * NEWS: Mention lgpl module name change.
726
727         * modules/lgpl-2.1: Renamed from lgpl.
728
729         * NEWS: Mention gpl module name change.
730
731         * modules/gpl-3.0: New file, based on gpl-2.0.
732
733         * modules/gpl-2.0: Renamed from gpl.
734
735         * modules/gpl: Fix filename, doc/gpl.texi is now found at
736         doc/gpl-2.0.texi.
737
738 2007-07-02  Paul Eggert  <eggert@cs.ucla.edu>
739
740         * lib/inttypes_.h [defined __cplusplus&&!defined __STDC_LIMIT_MACROS]:
741         #define __STDC_LIMIT_MACROS temporarily while including
742         <stdint.h>, so that __STDC_LIMIT_MACROS is defined.
743         Problem reported by Joel E. Denny in
744         <http://lists.gnu.org/archive/html/bug-gnulib/2007-07/msg00008.html>.
745
746 2007-07-01  Bruno Haible  <bruno@clisp.org>
747
748         * lib/unistdio.h: New file.
749         * lib/unistdio/u-asnprintf.h: New file.
750         * lib/unistdio/u-asprintf.h: New file.
751         * lib/unistdio/u-printf-args.c: New file.
752         * lib/unistdio/u-printf-args.h: New file.
753         * lib/unistdio/u-printf-parse.h: New file.
754         * lib/unistdio/u-snprintf.h: New file.
755         * lib/unistdio/u-sprintf.h: New file.
756         * lib/unistdio/u-vasprintf.h: New file.
757         * lib/unistdio/u-vsnprintf.h: New file.
758         * lib/unistdio/u-vsprintf.h: New file.
759         * lib/unistdio/ulc-asnprintf.c: New file.
760         * lib/unistdio/ulc-asprintf.c: New file.
761         * lib/unistdio/ulc-fprintf.c: New file, based on lib/fprintf.c.
762         * lib/unistdio/ulc-printf-parse.c: New file.
763         * lib/unistdio/ulc-snprintf.c: New file.
764         * lib/unistdio/ulc-sprintf.c: New file.
765         * lib/unistdio/ulc-vasnprintf.c: New file.
766         * lib/unistdio/ulc-vasprintf.c: New file.
767         * lib/unistdio/ulc-vfprintf.c: New file, based on lib/vfprintf.c.
768         * lib/unistdio/ulc-vsnprintf.c: New file.
769         * lib/unistdio/ulc-vsprintf.c: New file.
770         * lib/unistdio/u8-asnprintf.c: New file.
771         * lib/unistdio/u8-asprintf.c: New file.
772         * lib/unistdio/u8-printf-parse.c: New file.
773         * lib/unistdio/u8-snprintf.c: New file.
774         * lib/unistdio/u8-sprintf.c: New file.
775         * lib/unistdio/u8-vasnprintf.c: New file.
776         * lib/unistdio/u8-vasprintf.c: New file.
777         * lib/unistdio/u8-vsnprintf.c: New file.
778         * lib/unistdio/u8-vsprintf.c: New file.
779         * lib/unistdio/u8-u8-asnprintf.c: New file.
780         * lib/unistdio/u8-u8-asprintf.c: New file.
781         * lib/unistdio/u8-u8-snprintf.c: New file.
782         * lib/unistdio/u8-u8-sprintf.c: New file.
783         * lib/unistdio/u8-u8-vasnprintf.c: New file.
784         * lib/unistdio/u8-u8-vasprintf.c: New file.
785         * lib/unistdio/u8-u8-vsnprintf.c: New file.
786         * lib/unistdio/u8-u8-vsprintf.c: New file.
787         * lib/unistdio/u16-asnprintf.c: New file.
788         * lib/unistdio/u16-asprintf.c: New file.
789         * lib/unistdio/u16-printf-parse.c: New file.
790         * lib/unistdio/u16-snprintf.c: New file.
791         * lib/unistdio/u16-sprintf.c: New file.
792         * lib/unistdio/u16-vasnprintf.c: New file.
793         * lib/unistdio/u16-vasprintf.c: New file.
794         * lib/unistdio/u16-vsnprintf.c: New file.
795         * lib/unistdio/u16-vsprintf.c: New file.
796         * lib/unistdio/u16-u16-asnprintf.c: New file.
797         * lib/unistdio/u16-u16-asprintf.c: New file.
798         * lib/unistdio/u16-u16-snprintf.c: New file.
799         * lib/unistdio/u16-u16-sprintf.c: New file.
800         * lib/unistdio/u16-u16-vasnprintf.c: New file.
801         * lib/unistdio/u16-u16-vasprintf.c: New file.
802         * lib/unistdio/u16-u16-vsnprintf.c: New file.
803         * lib/unistdio/u16-u16-vsprintf.c: New file.
804         * lib/unistdio/u32-asnprintf.c: New file.
805         * lib/unistdio/u32-asprintf.c: New file.
806         * lib/unistdio/u32-printf-parse.c: New file.
807         * lib/unistdio/u32-snprintf.c: New file.
808         * lib/unistdio/u32-sprintf.c: New file.
809         * lib/unistdio/u32-vasnprintf.c: New file.
810         * lib/unistdio/u32-vasprintf.c: New file.
811         * lib/unistdio/u32-vsnprintf.c: New file.
812         * lib/unistdio/u32-vsprintf.c: New file.
813         * lib/unistdio/u32-u32-asnprintf.c: New file.
814         * lib/unistdio/u32-u32-asprintf.c: New file.
815         * lib/unistdio/u32-u32-snprintf.c: New file.
816         * lib/unistdio/u32-u32-sprintf.c: New file.
817         * lib/unistdio/u32-u32-vasnprintf.c: New file.
818         * lib/unistdio/u32-u32-vasprintf.c: New file.
819         * lib/unistdio/u32-u32-vsnprintf.c: New file.
820         * lib/unistdio/u32-u32-vsprintf.c: New file.
821         * tests/unistdio/test-ulc-asnprintf1.c: New file.
822         * tests/unistdio/test-ulc-asnprintf1.h: New file.
823         * tests/unistdio/test-ulc-printf1.h: New file.
824         * tests/unistdio/test-ulc-vasnprintf1.c: New file.
825         * tests/unistdio/test-ulc-vasnprintf2.c: New file.
826         * tests/unistdio/test-ulc-vasnprintf2.sh: New file.
827         * tests/unistdio/test-ulc-vasnprintf3.c: New file.
828         * tests/unistdio/test-ulc-vasnprintf3.sh: New file.
829         * tests/unistdio/test-ulc-vasprintf1.c: New file.
830         * tests/unistdio/test-ulc-vsnprintf1.c: New file.
831         * tests/unistdio/test-ulc-vsprintf1.c: New file.
832         * tests/unistdio/test-u8-asnprintf1.c: New file.
833         * tests/unistdio/test-u8-asnprintf1.h: New file.
834         * tests/unistdio/test-u8-printf1.h: New file.
835         * tests/unistdio/test-u8-vasnprintf1.c: New file.
836         * tests/unistdio/test-u8-vasnprintf2.c: New file.
837         * tests/unistdio/test-u8-vasnprintf2.sh: New file.
838         * tests/unistdio/test-u8-vasnprintf3.c: New file.
839         * tests/unistdio/test-u8-vasnprintf3.sh: New file.
840         * tests/unistdio/test-u8-vasprintf1.c: New file.
841         * tests/unistdio/test-u8-vsnprintf1.c: New file.
842         * tests/unistdio/test-u8-vsprintf1.c: New file.
843         * tests/unistdio/test-u16-asnprintf1.c: New file.
844         * tests/unistdio/test-u16-asnprintf1.h: New file.
845         * tests/unistdio/test-u16-printf1.h: New file.
846         * tests/unistdio/test-u16-vasnprintf1.c: New file.
847         * tests/unistdio/test-u16-vasnprintf2.c: New file.
848         * tests/unistdio/test-u16-vasnprintf2.sh: New file.
849         * tests/unistdio/test-u16-vasnprintf3.c: New file.
850         * tests/unistdio/test-u16-vasnprintf3.sh: New file.
851         * tests/unistdio/test-u16-vasprintf1.c: New file.
852         * tests/unistdio/test-u16-vsnprintf1.c: New file.
853         * tests/unistdio/test-u16-vsprintf1.c: New file.
854         * tests/unistdio/test-u32-asnprintf1.c: New file.
855         * tests/unistdio/test-u32-asnprintf1.h: New file.
856         * tests/unistdio/test-u32-printf1.h: New file.
857         * tests/unistdio/test-u32-vasnprintf1.c: New file.
858         * tests/unistdio/test-u32-vasnprintf2.c: New file.
859         * tests/unistdio/test-u32-vasnprintf2.sh: New file.
860         * tests/unistdio/test-u32-vasnprintf3.c: New file.
861         * tests/unistdio/test-u32-vasnprintf3.sh: New file.
862         * tests/unistdio/test-u32-vasprintf1.c: New file.
863         * tests/unistdio/test-u32-vsnprintf1.c: New file.
864         * tests/unistdio/test-u32-vsprintf1.c: New file.
865         * modules/unistdio/base: New file.
866         * modules/unistdio/u-printf-args: New file.
867         * modules/unistdio/ulc-asnprintf: New file.
868         * modules/unistdio/ulc-asprintf: New file.
869         * modules/unistdio/ulc-fprintf: New file.
870         * modules/unistdio/ulc-printf-parse: New file.
871         * modules/unistdio/ulc-snprintf: New file.
872         * modules/unistdio/ulc-sprintf: New file.
873         * modules/unistdio/ulc-vasnprintf: New file.
874         * modules/unistdio/ulc-vasprintf: New file.
875         * modules/unistdio/ulc-vfprintf: New file.
876         * modules/unistdio/ulc-vsnprintf: New file.
877         * modules/unistdio/ulc-vsprintf: New file.
878         * modules/unistdio/u8-asnprintf: New file.
879         * modules/unistdio/u8-asprintf: New file.
880         * modules/unistdio/u8-printf-parse: New file.
881         * modules/unistdio/u8-snprintf: New file.
882         * modules/unistdio/u8-sprintf: New file.
883         * modules/unistdio/u8-vasnprintf: New file.
884         * modules/unistdio/u8-vasprintf: New file.
885         * modules/unistdio/u8-vsnprintf: New file.
886         * modules/unistdio/u8-vsprintf: New file.
887         * modules/unistdio/u8-u8-asnprintf: New file.
888         * modules/unistdio/u8-u8-asprintf: New file.
889         * modules/unistdio/u8-u8-snprintf: New file.
890         * modules/unistdio/u8-u8-sprintf: New file.
891         * modules/unistdio/u8-u8-vasnprintf: New file.
892         * modules/unistdio/u8-u8-vasprintf: New file.
893         * modules/unistdio/u8-u8-vsnprintf: New file.
894         * modules/unistdio/u8-u8-vsprintf: New file.
895         * modules/unistdio/u16-asnprintf: New file.
896         * modules/unistdio/u16-asprintf: New file.
897         * modules/unistdio/u16-printf-parse: New file.
898         * modules/unistdio/u16-snprintf: New file.
899         * modules/unistdio/u16-sprintf: New file.
900         * modules/unistdio/u16-vasnprintf: New file.
901         * modules/unistdio/u16-vasprintf: New file.
902         * modules/unistdio/u16-vsnprintf: New file.
903         * modules/unistdio/u16-vsprintf: New file.
904         * modules/unistdio/u16-u16-asnprintf: New file.
905         * modules/unistdio/u16-u16-asprintf: New file.
906         * modules/unistdio/u16-u16-snprintf: New file.
907         * modules/unistdio/u16-u16-sprintf: New file.
908         * modules/unistdio/u16-u16-vasnprintf: New file.
909         * modules/unistdio/u16-u16-vasprintf: New file.
910         * modules/unistdio/u16-u16-vsnprintf: New file.
911         * modules/unistdio/u16-u16-vsprintf: New file.
912         * modules/unistdio/u32-asnprintf: New file.
913         * modules/unistdio/u32-asprintf: New file.
914         * modules/unistdio/u32-printf-parse: New file.
915         * modules/unistdio/u32-snprintf: New file.
916         * modules/unistdio/u32-sprintf: New file.
917         * modules/unistdio/u32-vasnprintf: New file.
918         * modules/unistdio/u32-vasprintf: New file.
919         * modules/unistdio/u32-vsnprintf: New file.
920         * modules/unistdio/u32-vsprintf: New file.
921         * modules/unistdio/u32-u32-asnprintf: New file.
922         * modules/unistdio/u32-u32-asprintf: New file.
923         * modules/unistdio/u32-u32-snprintf: New file.
924         * modules/unistdio/u32-u32-sprintf: New file.
925         * modules/unistdio/u32-u32-vasnprintf: New file.
926         * modules/unistdio/u32-u32-vasprintf: New file.
927         * modules/unistdio/u32-u32-vsnprintf: New file.
928         * modules/unistdio/u32-u32-vsprintf: New file.
929         * modules/unistdio/ulc-asnprintf-tests: New file.
930         * modules/unistdio/ulc-vasnprintf-tests: New file.
931         * modules/unistdio/ulc-vasprintf-tests: New file.
932         * modules/unistdio/ulc-vsnprintf-tests: New file.
933         * modules/unistdio/ulc-vsprintf-tests: New file.
934         * modules/unistdio/u8-asnprintf-tests: New file.
935         * modules/unistdio/u8-vasnprintf-tests: New file.
936         * modules/unistdio/u8-vasprintf-tests: New file.
937         * modules/unistdio/u8-vsnprintf-tests: New file.
938         * modules/unistdio/u8-vsprintf-tests: New file.
939         * modules/unistdio/u16-asnprintf-tests: New file.
940         * modules/unistdio/u16-vasnprintf-tests: New file.
941         * modules/unistdio/u16-vasprintf-tests: New file.
942         * modules/unistdio/u16-vsnprintf-tests: New file.
943         * modules/unistdio/u16-vsprintf-tests: New file.
944         * modules/unistdio/u32-asnprintf-tests: New file.
945         * modules/unistdio/u32-vasnprintf-tests: New file.
946         * modules/unistdio/u32-vasprintf-tests: New file.
947         * modules/unistdio/u32-vsnprintf-tests: New file.
948         * modules/unistdio/u32-vsprintf-tests: New file.
949         * MODULES.html.sh (Unicode string functions): Add the new modules.
950
951 2007-07-01  Bruno Haible  <bruno@clisp.org>
952
953         * lib/sprintf.c (sprintf): Limit the available length estimation,
954         to avoid address wraparound.
955         * lib/vsprintf.c (vsprintf): Likewise.
956         * modules/sprintf-posix (Dependencies): Add stdint.
957         * modules/vsprintf-posix (Dependencies): Likewise.
958
959 2007-07-01  Bruno Haible  <bruno@clisp.org>
960
961         * gnulib-tool (self_abspathname): Determine PATH_SEPARATOR and handle
962         Windows PATH as well. Conservative double-quoting. Comments.
963
964 2007-07-01  Bruno Haible  <bruno@clisp.org>
965             Eric Blake  <ebb9@byu.net>
966             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
967
968         * gnulib-tool (self_abspathname): Fix algorithm to cope with
969         empty components in $PATH, denoting '.'.
970
971 2007-07-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
972
973         * gnulib-tool: Fix indentation.
974         (func_create_megatestdir): Likewise.
975         Report by Bruno Haible.
976
977 2007-06-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
978
979         Sync from Automake.
980         * build-aux/gnupload: Fix shell portability issues with for loops.
981         Report by Karl Berry.
982
983 2007-06-29  Simon Josefsson  <simon@josefsson.org>
984
985         * build-aux/maint.mk (POURL): Use translationproject.org.
986
987 2007-06-27  Simon Josefsson  <simon@josefsson.org>
988             Bruno Haible  <bruno@clisp.org>
989
990         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Require gl_HEADER_SYS_SOCKET
991         before using HAVE_WS2TCPIP_H. Check for gai_strerror through an
992         explicit link test, rather than AC_REPLACE_FUNCS - for mingw.
993         (gl_PREREQ_GETADDRINFO): Require gl_HEADER_SYS_SOCKET before using
994         HAVE_SYS_SOCKET_H and HAVE_WS2TCPIP_H.
995
996 2007-06-27  Bruno Haible  <bruno@clisp.org>
997
998         * build-aux/config.rpath: Upgrade to libtool-1.5.24.
999         * build-aux/config.libpath: Upgrade to libtool-1.5.24.
1000
1001 2007-06-26  Karl Berry  <karl@gnu.org>
1002
1003         * MODULES.html.sh: remove xreadlink-with-size.
1004
1005 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
1006
1007         * lib/time_.h: Port to Solaris 8 with Sun Studio 11, using a
1008         method that I hope also handles the double-include problem noted
1009         by Bruno Haible in
1010         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00186.html>.
1011
1012 2007-06-23  Bruno Haible  <bruno@clisp.org>
1013
1014         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
1015         Don't let the 'mostlyclean' target fail if the last subdirectory could
1016         not be removed.
1017         Reported by Karl Berry.
1018
1019 2007-06-23  Bruno Haible  <bruno@clisp.org>
1020
1021         * gnulib-tool (echo): Add a speedier workaround for ksh.
1022         * tests/test-echo.sh: Likewise.
1023
1024 2007-06-23  Bruno Haible  <bruno@clisp.org>
1025
1026         * gnulib-tool (echo): Add workarounds also for bash versions < 2.04.
1027         * tests/test-echo.sh: Likewise.
1028
1029 2007-06-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1030
1031         * gnulib-tool (IFS): Initialize early, so we don't set it to
1032         empty later.
1033         (self_abspathname): Rewrite algorithm to set it, reindent.
1034         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am)
1035         (func_create_megatestdir): Merge some sed scripts.
1036
1037 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
1038
1039         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Check some typos
1040         exposed by Sun Studio 11 cc on Solaris 8.
1041
1042 2007-06-22  Bruno Haible  <bruno@clisp.org>
1043
1044         * gnulib-tool (echo): Ensure the echo primitive does not interpret
1045         backslashes.
1046         * tests/test-echo.sh: New file.
1047
1048 2007-06-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1049
1050         * gnulib-tool (func_add_or_update, func_create_testdir): Do not
1051         simplify `sed_replace_build_aux' scripts, they are portable but
1052         echoing them with `echo' is not.
1053         Report and analysis by Fernando Ferreira <fernando.prog@netcabo.pt>.
1054
1055 2007-06-21  Karl Berry  <karl@gnu.org>
1056
1057         * config/srclist.txt: guess we can't handle the licenses via
1058         srclist at the moment.
1059
1060 2007-06-21  Paul Eggert  <eggert@cs.ucla.edu>
1061
1062         * MODULES.html.sh: Add include_next.
1063         * modules/include_next: New file.
1064
1065 2007-06-20  Paul Eggert  <eggert@cs.ucla.edu>
1066
1067         * m4/include_next.m4 (gl_INCLUDE_NEXT): Define and AC_SUBST
1068         INCLUDE_NEXT.
1069         (gl_CHECK_NEXT_HEADERS): New macro.
1070         * m4/fcntl_h.m4 (gl_FCNTL_H): use gl_CHECK_NEXT_HEADERS instead of
1071         the obsolescent gl_ABSOLUTE_HEADER.
1072         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
1073         * m4/float_h.m4 (gl_FLOAT_H): Likewise.
1074         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
1075         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
1076         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
1077         * m4/math_h.m4 (gl_MATH_H): Likewise.
1078         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
1079         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
1080         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
1081         * m4/stdint.m4 (gl_STDINT_H): Likewise.
1082         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
1083         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
1084         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
1085         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
1086         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
1087         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
1088         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
1089         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
1090         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Likewise.
1091         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
1092         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
1093         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
1094         * m4/inttypes.m4 (gl_INTTYPES_H): Define
1095         _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H to avoid the problem of unclean
1096         builds, since ABSOLUTE_INTTYPES_H is no longer being defined.
1097         * m4/stdint.m4 (gl_STDINT_H): Likewise, for
1098         _GL_JUST_INCLUDE_SYSTEM_STDINT_H.
1099         * lib/fcntl_.h: Use @INCLUDE_NEXT@ @NEXT_foo_H@
1100         rather than @HAVE_INCLUDE_NEXT@ and @ABSOLUTE_foo_H@.
1101         * lib/float_.h: Likewise.
1102         * lib/inttypes_.h: Likewise.
1103         * lib/math_.h: Likewise.
1104         * lib/search_.h: Likewise.
1105         * lib/signal_.h: Likewise.
1106         * lib/stdint_.h: Likewise.
1107         * lib/stdio_.h: Likewise.
1108         * lib/stdlib_.h: Likewise.
1109         * lib/string_.h: Likewise.
1110         * lib/sys_stat_.h: Likewise.
1111         * lib/sys_time_.h: Likewise.
1112         * lib/time_.h: Likewise.
1113         * lib/unistd_.h: Likewise.
1114         * lib/wchar_.h: Likewise.
1115         * lib/wctype_.h: Likewise.
1116         * lib/dirent_.h: Likewise.
1117         * lib/iconv_.h: Likewise.
1118         * lib/locale_.h: Likewise.
1119         * lib/netinet_in_.h: Likewise.
1120         * lib/sys_select_.h: Likewise.
1121         * lib/sys_socket_.h: Likewise.
1122         * lib/sysexits_.h: Likewise.
1123         * modules/fcntl (Depends-on): Depend on include_next, not
1124         absolute_header.
1125         (Makefile): Substitute INCLUDE_NEXT and NEXT_foo_H, not
1126         HAVE_INCLUDE_NEXT and ABSOLUTE_foo_H.
1127         * modules/fchdir: Likewise.
1128         * modules/float: Likewise.
1129         * modules/iconv_open: Likewise.
1130         * modules/inttypes: Likewise.
1131         * modules/locale: Likewise.
1132         * modules/math: Likewise.
1133         * modules/netinet_in: Likewise.
1134         * modules/search: Likewise.
1135         * modules/signal: Likewise.
1136         * modules/stdint: Likewise.
1137         * modules/stdio: Likewise.
1138         * modules/stdlib: Likewise.
1139         * modules/string: Likewise.
1140         * modules/sys_select: Likewise.
1141         * modules/sys_socket: Likewise.
1142         * modules/sys_stat: Likewise.
1143         * modules/sys_time: Likewise.
1144         * modules/sysexits: Likewise.
1145         * modules/time: Likewise.
1146         * modules/unistd: Likewise.
1147         * modules/wchar: Likewise.
1148         * modules/wctype: Likewise.
1149         * modules/sys_stat: Change maintainer to "all".
1150         * modules/unistd: Likewise.
1151
1152 2007-06-20  Karl Berry  <karl@gnu.org>
1153
1154         * config/srclist.txt: track www changes in license files.
1155
1156 2007-06-20  Sergey Poznyakoff  <gray@gnu.org.ua>
1157
1158         * build-aux/bootstrap: Remove stray dot.
1159         Make sure build_aux settings are honored when linking
1160         gnulib_extra_files.
1161
1162 2007-06-19  Eric Blake  <ebb9@byu.net>
1163
1164         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
1165         Allow compilation on cygwin.
1166
1167 2007-06-19  Jim Meyering  <jim@meyering.net>
1168
1169         xreadlink-with-size: Remove module.  No longer used.
1170         Ex-callers now use xreadlink or mreadlink-with-size.
1171         * modules/xreadlink-with-size: Remove module.
1172         * lib/xreadlink-with-size.c: Remove file.
1173         * lib/xreadlink.h (xreadlink_with_size): Remove prototype.
1174         (xreadlink): Remove inaccurate comment.  The one in xreadlink.c,
1175         just before the function definition *is* accurate.
1176
1177         Eliminate one way canonicalize_filename_mode could exit.
1178         * lib/canonicalize.c (canonicalize_filename_mode):
1179         Use mreadlink_with_size, not xreadlink_with_size.
1180
1181 2007-06-18  Paul Eggert  <eggert@cs.ucla.edu>
1182
1183         Detect porting problems to FreeBSD/arm, which has time_t wider than
1184         long int.  Original problem reported for GNU diff by Xin Li in
1185         <http://lists.gnu.org/archive/html/bug-gnu-utils/2007-06/msg00091.html>.
1186         * modules/getdate (Depends-on): Add intprops, verify.
1187         * lib/getdate.y: Include intprops.h, verify.h.  Verify that time_t
1188         is an integer type no wider than long int.
1189
1190 2007-06-18  Jim Meyering  <jim@meyering.net>
1191
1192         New module: mreadlink-with-size.
1193         * MODULES.html.sh: Add mreadlink-with-size.
1194         * modules/mreadlink-with-size: New module
1195         * modules/canonicalize (Depends-on): Depend on mreadlink-with-size,
1196         not xreadlink-with-size.
1197         * lib/mreadlink-with-size.c, lib/mreadlink.h: New files.
1198
1199 2007-06-16  Bruno Haible  <bruno@clisp.org>
1200
1201         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Catch the MacOS X 10.4 bug.
1202         * doc/functions/frexpl.texi: Document the MacOS X 10.4 bug.
1203         Reported by Gary V. Vaughan <gary@gnu.org>.
1204
1205 2007-06-15  Paul Eggert  <eggert@cs.ucla.edu>
1206
1207         Revamp lchown so that it lives in unistd.h where it belongs.
1208         * lib/lchown.h: Remove.
1209         * lib/dirchownmod.c: Don't include lib/lchown.h.
1210         * lib/fchownat.c: Likewise.
1211         * lib/openat.c: Likewise.
1212         * lib/lchown.c (REPLACE_CHOWN): Define to 0 if the system chown
1213         does not follow symlinks.
1214         (EOPNOTSUPP): Define if not defined.
1215         * lib/unistd_.h (chown): Do not replace if REPLADE_CHOWN
1216         is defined to 0.
1217         (lchown): New decl.
1218         * m4/lchown.m4 (gl_FUNC_LCHOWN): Require gl_UNISTD_H_DEFAULTS.
1219         Do not check for lchown decl.
1220         Set REPLACE_LCHOWN.
1221         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set GNULIB_LCHOWN,
1222         REPLACE_LCHOWN.
1223         * modules/chown: Make it clear it follows symlinks.
1224         * modules/lchown: Make it clear it doesn't follow symlinks.
1225         (Files): Remove lib/lchown.h
1226         (Depends-on): Add unistd.
1227         (configure.ac): Add gl_UNISTD_MODULE_INDICATOR([lchown]).
1228         (Include): Include <unistd.h>, not "lchown.h".
1229         * modules/unistd (unistd.h): Substitude GNULIB_LCHOWN and
1230         REPLACE_LCHOWN.
1231
1232 2007-06-15  Jim Meyering  <jim@meyering.net>
1233
1234         Change license (GPL to LGPL) of fsusage and dependents.
1235         * modules/fsusage (License): Change to LGPL.
1236         * modules/full-read (License): Likewise.
1237         * modules/full-write (License): Likewise.
1238         * modules/safe-read (License): Likewise.
1239         * modules/safe-write (License): Likewise.
1240
1241 2007-06-14  Ben Pfaff  <blp@gnu.org>
1242
1243         Missing part of allocsa -> malloca transition.
1244         * modules/relocatable-prog-wrapper: gl_ALLOCSA should be
1245         gl_MALLOCA.
1246
1247 2007-06-12  Bruno Haible  <bruno@clisp.org>
1248
1249         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Guess no when cross-compiling
1250         to ia64, x86_64, i386.
1251         Reported by Eric Blake.
1252
1253 2007-06-12  Bruno Haible  <bruno@clisp.org>
1254
1255         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Guess no also when
1256         cross-compiling to x86_64.
1257
1258 2007-06-12  Paul Eggert  <eggert@cs.ucla.edu>
1259
1260         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Fix POSIX sed portability
1261         glitch reported by Ralf Wildenhues in
1262         <http://lists.gnu.org/archive/html/bug-gnulib/2007-06/msg00114.html>.
1263
1264         * m4/regex.m4 (gl_REGEX): Catch a bug with [[:alnum:]_-] reported by
1265         Vin Shelton.
1266
1267 2007-06-11  Bruno Haible  <bruno@clisp.org>
1268
1269         * lib/printf-args.c (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Fix NULL
1270         replacement string.
1271         Reported by Eric Blake.
1272
1273 2007-06-10  Bruno Haible  <bruno@clisp.org>
1274
1275         Prepare vasnprintf code for use with Unicode strings.
1276         * lib/printf-args.h (PRINTF_FETCHARGS): New macro.
1277         (arg_type) [ENABLE_UNISTDIO]: Define TYPE_U8_STRING, TYPE_U16_STRING,
1278         TYPE_U32_STRING.
1279         (argument) [ENABLE_UNISTDIO]: Add a_u8_string, a_u16_string,
1280         a_u32_string variants.
1281         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
1282         * lib/printf-args.c: Don't include config.h and the specification
1283         header if PRINTF_FETCHARGS is already defined.
1284         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
1285         (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Add code for TYPE_U8_STRING,
1286         TYPE_U16_STRING, TYPE_U32_STRING.
1287         * lib/printf-parse.h [ENABLE_UNISTDIO] (u8_directive, u8_directives,
1288         u16_directive, u16_directives, u32_directive, u32_directives): New
1289         types.
1290         (ulc_printf_parse, u8_printf_parse, u16_printf_parse, u32_printf_parse):
1291         New declarations.
1292         * lib/printf-parse.c: Don't include config.h and the specification
1293         header if PRINTF_PARSE is already defined. Eliminate the set of
1294         parameters for WIDE_CHAR_VERSION; the user of this file must provide
1295         them now. Include c-ctype.h.
1296         (PRINTF_PARSE) [ENABLE_UNISTDIO]: Add code implementing the 'U'
1297         directive and CHAR_T_ONLY_ASCII.
1298         * lib/vasnprintf.c: Don't include config.h and the specification header
1299         if VASNPRINTF is already defined.
1300         (DCHAR_IS_TCHAR, DCHAR_CPY): New macros.
1301         (VASNPRINTF): Use PRINTF_FETCHARGS instead of printf_fetchargs. Use
1302         DCHAR_CPY. Handle the case that DCHAR_T and FCHAR_T are not the same
1303         type. Handle the case that TCHAR_T and FCHAR_T are not of the same
1304         size. Handle the case that DCHAR_T and TCHAR_T are not the same type,
1305         add a conversion from TCHAR_T[] to DCHAR_T[], and rework the padding
1306         code accordingly.
1307         (VASNPRINTF) [ENABLE_UNISTDIO]: Implement the 'U' directive. Enable
1308         pad_ourselves also in this case, with the 'c' and 's' directives, and
1309         with a different notion of "width".
1310         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): New macros.
1311
1312 2007-06-10  Bruno Haible  <bruno@clisp.org>
1313
1314         * modules/unistr/u32-mbsnlen: New file.
1315         * lib/unistr/u32-mbsnlen.c: New file.
1316
1317         * modules/unistr/u16-mbsnlen: New file.
1318         * lib/unistr/u16-mbsnlen.c: New file.
1319
1320         * modules/unistr/u8-mbsnlen: New file.
1321         * lib/unistr/u8-mbsnlen.c: New file.
1322
1323         * lib/unistr.h (u8_mbsnlen, u16_mbsnlen, u32_mbsnlen): New
1324         declarations.
1325
1326 2007-06-10  Bruno Haible  <bruno@clisp.org>
1327
1328         * lib/string_.h (mbsnlen): New declaration.
1329         * lib/mbsnlen.c: New file.
1330         * m4/mbsnlen.m4: New file.
1331         * modules/mbsnlen: New file.
1332         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set GNULIB_MBSNLEN.
1333         * modules/string (string.h): Substitute GNULIB_MBSNLEN.
1334         * MODULES.html.sh (Internationalization functions): Add mbsnlen.
1335
1336 2007-06-10  Bruno Haible  <bruno@clisp.org>
1337
1338         * lib/mbslen.c: Include <stdlib.h>, needed for MB_CUR_MAX.
1339
1340 2007-06-10  Bruno Haible  <bruno@clisp.org>
1341
1342         * lib/mbiter.h: Include <stddef.h>, needed for ptrdiff_t.
1343         * lib/mbuiter.h: Likewise.
1344
1345 2007-06-10  Bruno Haible  <bruno@clisp.org>
1346
1347         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Check for _snprintf
1348         declaration.
1349
1350 2007-06-10  Karl Berry  <karl@gnu.org>
1351
1352         * config/srclist.txt: remove gettext entries, Bruno prefers
1353         to update individually.
1354
1355 2007-06-10  Bruno Haible  <bruno@clisp.org>
1356
1357         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Remove variable
1358         'maxlen'. Ensure only length + width bytes are allocated, not
1359         length + 1 + width.
1360
1361 2007-06-09  Bruno Haible  <bruno@clisp.org>
1362
1363         * lib/vasnprintf.c (FCHAR_T, DCHAR_T, TCHAR_T): New macros.
1364         (CHAR_T): Remove macro.
1365         (VASNPRINTF): Update.
1366
1367 2007-06-09  Bruno Haible  <bruno@clisp.org>
1368
1369         * MODULES.html.sh (Unicode string functions): Add the new modules.
1370
1371         * modules/uniconv/u32-conv-to-enc: New file.
1372         * lib/uniconv/u32-conv-to-enc.c: New file.
1373         * modules/uniconv/u32-conv-to-enc-tests: New file.
1374         * tests/uniconv/test-u32-conv-to-enc.c: New file.
1375
1376         * modules/uniconv/u16-conv-to-enc: New file.
1377         * lib/uniconv/u16-conv-to-enc.c: New file.
1378         * lib/uniconv/u-conv-to-enc.h: New file.
1379         * modules/uniconv/u16-conv-to-enc-tests: New file.
1380         * tests/uniconv/test-u16-conv-to-enc.c: New file.
1381
1382         * modules/uniconv/u8-conv-to-enc: New file.
1383         * lib/uniconv/u8-conv-to-enc.c: New file.
1384         * modules/uniconv/u8-conv-to-enc-tests: New file.
1385         * tests/uniconv/test-u8-conv-to-enc.c: New file.
1386
1387         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
1388         u32_conv_to_encoding): New declarations.
1389
1390 2007-06-09  Bruno Haible  <bruno@clisp.org>
1391
1392         * tests/uniconv/test-u32-strconv-to-enc.c (main): Remove unused code.
1393
1394 2007-06-09  Bruno Haible  <bruno@clisp.org>
1395
1396         Rename 'allocsa' -> 'malloca', 'freesa' -> 'freea'.
1397         * modules/malloca: Renamed from modules/allocsa, updated.
1398         * lib/malloca.h: Renamed from lib/allocsa.h, updated.
1399         * lib/malloca.c: Renamed from lib/allocsa.c, updated.
1400         * lib/malloca.valgrind: Renamed from lib/allocsa.valgrind, updated.
1401         * m4/malloca.m4: Renamed from m4/allocsa.m4, updated.
1402         * modules/malloca-tests: Renamed from modules/allocsa-tests, updated.
1403         * tests/test-malloca.c: Renamed from tests/test-allocsa.c, updated.
1404         * modules/xmalloca: Renamed from modules/xallocsa, updated.
1405         * lib/xmalloca.h: Renamed from lib/xallocsa.h, updated.
1406         * lib/xmalloca.c: Renamed from lib/xallocsa.c, updated.
1407         * modules/c-strcasestr (Depends-on): Update.
1408         * lib/c-strcasestr.c: Update.
1409         * modules/c-strstr (Depends-on): Update.
1410         * lib/c-strstr.c: Update.
1411         * modules/canonicalize-lgpl (Depends-on): Update.
1412         * lib/canonicalize-lgpl.c: Update.
1413         * modules/clean-temp (Depends-on): Update.
1414         * lib/clean-temp.c: Update.
1415         * modules/csharpcomp (Depends-on): Update.
1416         * lib/csharpcomp.c: Update.
1417         * modules/csharpexec (Depends-on): Update.
1418         * lib/csharpexec.c: Update.
1419         * modules/javacomp (Depends-on): Update.
1420         * lib/javacomp.c: Update.
1421         * modules/javaexec (Depends-on): Update.
1422         * lib/javaexec.c: Update.
1423         * modules/mbscasestr (Depends-on): Update.
1424         * lib/mbscasestr.c: Update.
1425         * modules/mbsstr (Depends-on): Update.
1426         * lib/mbsstr.c: Update.
1427         * modules/setenv (Depends-on): Update.
1428         * lib/setenv.c: Update.
1429         * modules/strcasestr (Depends-on): Update.
1430         * lib/strcasestr.c: Update.
1431         * modules/striconveha (Depends-on): Update.
1432         * lib/striconveha.c: Update.
1433         * modules/relocatable-prog-wrapper (Files): Update.
1434         * lib/relocwrapper.c: Update.
1435         * build-aux/install-reloc: Update.
1436         * MODULES.html.sh (Memory management functions <stdlib.h>): Update.
1437
1438 2007-06-08  Bruno Haible  <bruno@clisp.org>
1439
1440         Port to uClibc.
1441         * lib/fbufmode.c (fbufmode): Add special code for uClibc.
1442         * lib/fpurge.c (fpurge): Likewise.
1443         * lib/freading.c (freading): Likewise.
1444         * lib/fseeko.c (rpl_fseeko): Likewise.
1445         * lib/fseterr.c (fseterr): Likewise.
1446         * lib/fwriting.c (fwriting): Likewise.
1447         * tests/test-fflush.c (main): Avoid a failure on uClibc.
1448
1449 2007-06-08  Bruno Haible  <bruno@clisp.org>
1450
1451         * m4/intlmacosx.m4: New file, extracted from gettext.m4.
1452         * m4/gettext.m4 (gt_INTL_MACOSX): Remove macro, moved to intlmacosx.m4.
1453         * modules/gettext (Files): Add m4/intlmacosx.m4.
1454
1455 2007-06-07  Bruno Haible  <bruno@clisp.org>
1456
1457         * modules/localename-tests: New file.
1458         * tests/test-localename.c: New file.
1459
1460         New module 'localename'.
1461         * lib/localename.h: New file.
1462         * lib/localename.c: New file, from GNU gettext.
1463         * m4/localename.m4: New file.
1464         * modules/localename: New file.
1465
1466 2007-06-07  Bruno Haible  <bruno@clisp.org>
1467
1468         Work around the lack of <wchar.h> on some builds of uClibc.
1469         * doc/headers/wchar.texi: Update.
1470         * lib/wchar_.h: Include <wchar.h> only if it exists.
1471         * m4/wchar.m4 (gl_WCHAR_H): Check for <wchar.h>. Set HAVE_WCHAR_H.
1472         * m4/stdint.m4 (gl_STDINT_H): Check for <wchar.h>.
1473         (gl_STDINT_TYPE_PROPERTIES): Don't try to include <wchar.h> if it
1474         doesn't exist.
1475         * modules/wchar (wchar.h): Substitute HAVE_WCHAR_H.
1476         * modules/mbfile (Depends-on): Add wchar.
1477         * modules/mbiter (Depends-on): Likewise.
1478         * modules/mbuiter (Depends-on): Likewise.
1479         Reported by Simon Josefsson.
1480
1481 2007-06-06  Paul Eggert  <eggert@cs.ucla.edu>
1482
1483         Work around problem reported by Steven M. Schweda in
1484         <http://lists.gnu.org/archive/html/bug-tar/2007-06/msg00002.html>:
1485         Tru64 5.1B with the Compaq compiler environment installed declares
1486         an 'isblank' function but does not define it in the C library.
1487         * lib/fnmatch.c (isblank): Check for HAVE_ISBLANK, too.
1488         * lib/regex_internal.h (isblank): Likewise.
1489         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for isblank existence.
1490         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
1491
1492 2007-06-05  Bruno Haible  <bruno@clisp.org>
1493
1494         Fix *printf so that it recognizes non-IEEE numbers on i386, x86_64,
1495         ia64.
1496         * modules/printf-safe: New file.
1497         * modules/fprintf-posix (Depends-on): Add printf-safe.
1498         * modules/printf-posix (Depends-on): Likewise.
1499         * modules/snprintf-posix (Depends-on): Likewise.
1500         * modules/sprintf-posix (Depends-on): Likewise.
1501         * modules/vasnprintf-posix (Depends-on): Likewise.
1502         * modules/vasprintf-posix (Depends-on): Likewise.
1503         * modules/vfprintf-posix (Depends-on): Likewise.
1504         * modules/vprintf-posix (Depends-on): Likewise.
1505         * modules/vsnprintf-posix (Depends-on): Likewise.
1506         * modules/vsprintf-posix (Depends-on): Likewise.
1507         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Require
1508         AC_C_BIGENDIAN. Define CHECK_PRINTF_SAFE if printf-safe is used. Test
1509         non-IEEE numbers on i386, x86_64, ia64. When cross-compiling, guess
1510         "no" on i386, x86_64, ia64.
1511         * tests/test-snprintf-posix.h (LDBL80_WORDS): New macro.
1512         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1513         on i386, x86_64, ia64.
1514         * tests/test-sprintf-posix.h (LDBL80_WORDS): New macro.
1515         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1516         on i386, x86_64, ia64.
1517         * tests/test-vasnprintf-posix.c: Include float.h.
1518         (LDBL80_WORDS): New macro.
1519         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1520         on i386, x86_64, ia64.
1521         * tests/test-vasprintf-posix.c: Include float.h.
1522         (LDBL80_WORDS): New macro.
1523         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1524         on i386, x86_64, ia64.
1525         * tests/test-snprintf-posix.c: Include float.h.
1526         * tests/test-sprintf-posix.c: Likewise.
1527         * tests/test-vsnprintf-posix.c: Likewise.
1528         * tests/test-vsprintf-posix.c: Likewise.
1529
1530 2007-06-05  Bruno Haible  <bruno@clisp.org>
1531
1532         Fix isnanl so that it recognizes non-IEEE numbers on i386, x86_64, ia64.
1533         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Require AC_C_BIGENDIAN. Test
1534         non-IEEE numbers on i386, x86_64, ia64.
1535         (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require AC_C_BIGENDIAN.
1536         * lib/isnan.c (FUNC): Add special code for i386, x86_64, ia64.
1537         * tests/test-isnanl.h: Include float.h.
1538         (main): Check also non-IEEE numbers on i386, x86_64, ia64.
1539
1540 2007-06-05  Bruno Haible  <bruno@clisp.org>
1541
1542         * lib/vasnprintf.c (VASNPRINTF): Do the extra handling of NaN and Inf
1543         also the %a / %A. Handle the %a / %A code before this extra handling.
1544
1545 2007-06-05  Bruno Haible  <bruno@clisp.org>
1546
1547         * lib/vasnprintf.c [NEED_PRINTF_LONG_DOUBLE ||
1548         NEED_PRINTF_INFINITE_LONG_DOUBLE]: Include fpucw.h.
1549
1550 2007-06-05  Bruno Haible  <bruno@clisp.org>
1551
1552         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): Fix
1553         typo in variable name.
1554
1555 2007-06-05  Eric Blake  <ebb9@byu.net>
1556
1557         * m4/lseek.m4 (gl_FUNC_LSEEK): Work when cross-compiling.
1558         Reported by Simon Josefsson.
1559
1560 2007-06-04  Bruno Haible  <bruno@clisp.org>
1561
1562         Avoid test failures on some PowerPC platforms.
1563         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP):
1564         Define differently for PowerPC.
1565         * tests/test-frexpl.c (MIN_NORMAL_EXP): Likewise.
1566         Reported by Gary V. Vaughan <gary@gnu.org>.
1567
1568 2007-06-02  Bruno Haible  <bruno@clisp.org>
1569
1570         Fix test-stdint failure on FreeBSD/ia64.
1571         * m4/stdint.m4 (gl_STDINT_H): Check the values of PTRDIFF_MIN,
1572         PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN,
1573         WCHAR_MAX, WINT_MIN, WINT_MAX entirely, not only for plausibility.
1574         * doc/headers/stdint.texi: Update.
1575
1576 2007-06-01  Bruno Haible  <bruno@clisp.org>
1577
1578         * tests/test-binary-io.c (main): Pass a third argument to open().
1579         Reported by Gary V. Vaughan <gary@gnu.org>.
1580
1581 2007-06-01  Bruno Haible  <bruno@clisp.org>
1582
1583         * doc/functions/frexpl.texi: Update for mingw.
1584
1585 2007-06-01  Bruno Haible  <bruno@clisp.org>
1586
1587         * tests/test-lseek.c (main): Disable test of errno for invalid third
1588         argument.
1589         * doc/functions/lseek.texi: Update.
1590         Reported by Gary V. Vaughan <gary@gnu.org>.
1591
1592 2007-05-28  Bruno Haible  <bruno@clisp.org>
1593
1594         * m4/intl.m4 (AM_INTL_SUBDIR): Substitute variables WOE32, WINDRES.
1595
1596 2007-05-31  Eric Blake  <ebb9@byu.net>
1597
1598         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Guess no on mingw when
1599         cross compiling.
1600
1601 2007-05-30  Eric Blake  <ebb9@byu.net>
1602         and Bruno Haible  <bruno@clisp.org>
1603
1604         Work around mingw test failures exposed by m4-1.4.9b.
1605         * m4/stdint.m4 (gl_STDINT_H): Detect mingw bug.
1606         * tests/test-unistd.c: Disable uid_t and git_t tests for the
1607         moment.
1608
1609 2007-05-30  Bruno Haible  <bruno@clisp.org>
1610
1611         * tests/test-lseek.c: Explicitly close file descriptors 0 and 1 before
1612         assuming that they are closed. Needed on HP-UX 11.
1613
1614 2007-05-29  Bruno Haible  <bruno@clisp.org>
1615
1616         Fix a problem with #include_next.
1617         * lib/dirent_.h: Split the double-inclusion guard.
1618         * lib/fcntl_.h: Likewise.
1619         * lib/float_.h: Likewise.
1620         * lib/iconv_.h: Likewise.
1621         * lib/inttypes_.h: Likewise.
1622         * lib/locale_.h: Likewise.
1623         * lib/math_.h: Likewise.
1624         * lib/netinet_in_.h: Likewise.
1625         * lib/search_.h: Likewise.
1626         * lib/signal_.h: Likewise.
1627         * lib/stdint_.h: Likewise.
1628         * lib/stdio_.h: Likewise.
1629         * lib/stdlib_.h: Likewise.
1630         * lib/string_.h: Likewise.
1631         * lib/sys_select_.h: Likewise.
1632         * lib/sys_socket_.h: Likewise.
1633         * lib/sys_stat_.h: Likewise.
1634         * lib/sys_time_.h: Likewise.
1635         * lib/sysexits_.h: Likewise.
1636         * lib/time_.h: Likewise.
1637         * lib/unistd_.h: Likewise.
1638         * lib/wchar_.h: Likewise.
1639         * lib/wctype_.h: Likewise.
1640
1641 2007-05-29  Bruno Haible  <bruno@clisp.org>
1642
1643         * tests/test-unistd.c: Disable the tests for useconds_t and intptr_t
1644         for the moment.
1645
1646 2007-05-29  Bruno Haible  <bruno@clisp.org>
1647
1648         * m4/isnan.m4 (gl_DOUBLE_EXPONENT_LOCATION): Silence the AC_C_BIGENDIAN
1649         invocation.
1650         Reported by Eric Blake.
1651
1652 2007-05-29  Bruno Haible  <bruno@clisp.org>
1653
1654         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Fix typo in cross-
1655         compiling case.
1656
1657 2007-05-29  Eric Blake  <ebb9@byu.net>
1658             Bruno Haible  <bruno@clisp.org>
1659
1660         * m4/isnanf.m4 (gl_FUNC_ISNANF_NO_LIBM): Avoid syntax error on
1661         cross compiles.
1662
1663 2007-05-28  Eric Blake  <ebb9@byu.net>
1664
1665         * modules/closein-tests (test_closein_LDADD): Support test on
1666         cygwin with libtool.
1667
1668 2007-05-28  Bruno Haible  <bruno@clisp.org>
1669
1670         * tests/uniconv/test-u16-conv-from-enc.c: Remove #ifdef HAVE_CONFIG_H.
1671         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
1672         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
1673         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
1674         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
1675         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
1676         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
1677         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
1678         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
1679
1680 2007-05-28  Eric Blake  <ebb9@byu.net>
1681
1682         Unconditionally include <config.h> in unit tests.
1683         * tests/test-alloca-opt.c: Remove #ifdef HAVE_CONFIG_H.
1684         * tests/test-allocsa.c, tests/test-arcfour.c,
1685         tests/test-arctwo.c, tests/test-argmatch.c, tests/test-argp.c,
1686         tests/test-array_list.c, tests/test-array_oset.c,
1687         tests/test-atexit.c, test-avltree_list.c, test-avltree_oset.c,
1688         test-avltreehash_list.c, test-base64.c, test-binary-io.c,
1689         test-c-ctype.c, test-c-strcasecmp.c, test-c-strcasestr.c,
1690         test-c-strncasecmp.c, test-c-strstr.c, test-canonicalize-lgpl.c,
1691         test-carray_list.c, test-crc.c, test-des.c, test-dirname.c,
1692         test-fflush.c, test-fprintf-posix.c, test-gc-arcfour.c,
1693         test-gc-arctwo.c, test-gc-des.c, test-gc-hmac-md5.c,
1694         test-gc-hmac-sha1.c, test-gc-md2.c, test-gc-md4.c, test-gc-md5.c,
1695         test-gc-pbkdf2-sha1.c, test-gc-rijndael.c, test-gc-sha1.c,
1696         test-gc.c, test-getpass.c, test-hmac-md5.c, test-hmac-sha1.c,
1697         test-iconv.c, test-linked_list.c, test-linkedhash_list.c,
1698         test-lock.c, test-mbscasecmp.c, test-mbscasestr1.c,
1699         test-mbscasestr2.c, test-mbscasestr3.c, test-mbscasestr4.c,
1700         test-mbschr.c, test-mbscspn.c, test-mbsncasecmp.c, test-mbspbrk.c,
1701         test-mbspcasecmp.c, test-mbsrchr.c, test-mbsspn.c, test-mbsstr1.c,
1702         test-mbsstr2.c, test-mbsstr3.c, test-md2.c, test-md4.c,
1703         test-md5.c, test-memmem.c, test-printf-posix.c,
1704         test-rbtree_list.c, test-rbtree_oset.c, test-rbtreehash_list.c,
1705         test-read-file.c, test-rijndael.c, test-snprintf-posix.c,
1706         test-snprintf.c, test-sprintf-posix.c, test-stdint.c,
1707         test-strcasestr.c, test-striconv.c, test-striconveh.c,
1708         test-striconveha.c, test-tls.c, test-vasnprintf-posix.c,
1709         test-vasnprintf-posix2.c, test-vasnprintf.c,
1710         test-vasprintf-posix.c, test-vasprintf.c, test-verify.c,
1711         test-vfprintf-posix.c, test-vprintf-posix.c,
1712         test-vsnprintf-posix.c, test-vsnprintf.c, test-vsprintf-posix.c,
1713         test-xvasprintf.c: Likewise.
1714
1715 2007-05-28  Bruno Haible  <bruno@clisp.org>
1716
1717         * gnulib-tool (func_import): Remember the --with-tests command-line
1718         option through the macro gl_WITH_TESTS in the gnulib-cache.m4.
1719         Reported by Eric Blake.
1720
1721 2007-05-28  Bruno Haible  <bruno@clisp.org>
1722
1723         * modules/ftell-tests: New file.
1724         * tests/test-ftell.c: New file, based on tests/test-ftello.c.
1725         * tests/test-ftell.sh: New file, based on tests/test-ftello.sh.
1726
1727         * lib/ftell.c: New file.
1728         * modules/ftell: New file.
1729         * m4/ftell.m4: New file.
1730         * doc/functions/ftell.texi: Update.
1731         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELL,
1732         REPLACE_FTELL.
1733         * lib/stdio_.h (rpl_ftell): New declaration.
1734         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELL,
1735         REPLACE_FTELL.
1736
1737 2007-05-28  Eric Blake  <ebb9@byu.net>
1738
1739         * lib/allocsa.h (safe_alloca): Avoid compiler warning.
1740
1741 2007-05-28  Bruno Haible  <bruno@clisp.org>
1742
1743         * modules/fseek-tests: New file.
1744         * tests/test-fseek.c: New file, based on tests/test-fseeko.c.
1745         * tests/test-fseek.sh: New file, based on tests/test-fseeko.sh.
1746
1747         * lib/fseek.c: New file.
1748         * modules/fseek: New file.
1749         * m4/fseek.m4: New file.
1750         * doc/functions/fseek.texi: Update.
1751         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEK,
1752         REPLACE_FSEEK.
1753         * lib/stdio_.h (rpl_fseek): New declaration.
1754         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEK,
1755         REPLACE_FSEEK.
1756
1757 2007-05-28  Bruno Haible  <bruno@clisp.org>
1758
1759         * lib/stdio_.h (fflush): More comments.
1760
1761 2007-05-28  Bruno Haible  <bruno@clisp.org>
1762
1763         * m4/lseek.m4 (gl_FUNC_LSEEK): When not cross-compiling, perform a real
1764         runtime test.
1765
1766 2007-05-28  Eric Blake  <ebb9@byu.net>
1767
1768         Improve lseek module.
1769         * lib/lseek.c (rpl_lseek): Detect EBADF on mingw.
1770         * lib/unistd_.h (lseek): Scale back link warning message.
1771         * tests/test-lseek.c: Beef up test.
1772         * tests/test-lseek.sh: Exercise more facets of lseek.
1773         Reported by Bruno Haible.
1774
1775 2007-05-28  Bruno Haible  <bruno@clisp.org>
1776
1777         * tests/test-unistd.c: Test all the types that <unistd.h> is expected
1778         to define.
1779
1780 2007-05-27  Bruno Haible  <bruno@clisp.org>
1781
1782         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-31 patch.
1783
1784 2007-05-27  Bruno Haible  <bruno@clisp.org>
1785
1786         * modules/openmp: New file.
1787         * m4/openmp.m4: New file, taken from autoconf's CVS with changes by
1788         Noah Misch.
1789
1790 2007-05-26  Bruno Haible  <bruno@clisp.org>
1791
1792         * modules/chdir-long (Depends-on): Add fchdir.
1793         * modules/chdir-safer (Depends-on): Likewise.
1794         * modules/fts (Depends-on): Likewise.
1795         * modules/fts-lgpl (Depends-on): Likewise.
1796         * modules/openat (Depends-on): Likewise.
1797         * modules/savewd (Depends-on): Likewise.
1798
1799 2007-05-24  Eric Blake  <ebb9@byu.net>
1800
1801         Fix lseek on mingw.
1802         * modules/lseek: New module.
1803         * m4/lseek.m4: New file.
1804         * lib/lseek.c: New file.
1805         * modules/lseek-tests: New file.
1806         * tests/test-lseek.c: New file.
1807         * tests/test-lseek.sh: New file.
1808         * MODULES.html.sh: Document lseek module.
1809         * modules/fflush (Depends-on): Add lseek, fseeko.
1810         * modules/fseeko (Depends-on): Likewise.
1811         * modules/ftello (Depends-on): Likewise.
1812         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Replace fseek[o] if lseek is
1813         broken.
1814         * m4/ftello.m4 (gl_FUNC_FTELLO): Replace ftell[o] if lseek is
1815         broken.
1816         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Trigger fseeko module.
1817         * lib/fseeko.c (rpl_fseeko): Quit early on non-seekable files.
1818         * lib/ftello.c (rpl_ftello): Likewise.
1819         * tests/test-fseeko.c (main): Test this.
1820         * tests/test-fseeko.sh: Likewise.
1821         * tests/test-ftello.c (main): Likewise.
1822         * tests/test-ftello.sh: Likewise.
1823         * lib/stdio_.h (fseek, ftell): Simplify, since missing fseeko now
1824         implies replacing fseek.
1825         * modules/stdio (Makefile.am): No longer need HAVE_FSEEKO,
1826         HAVE_FTELLO.
1827         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add lseek info.
1828         * modules/unistd (Makefile.am): Likewise.
1829         * lib/unistd_.h (lseek): Declare a replacement.
1830         * doc/functions/lseek.texi (lseek): Document this fix.
1831         * doc/functions/fseek.texi (fseek): Likewise.
1832         * doc/functions/ftell.texi (ftell): Likewise.
1833
1834 2007-05-24  Bruno Haible  <bruno@clisp.org>
1835
1836         * tests/test-vasnprintf-posix.c (test_function): Allow up to 50 bytes
1837         in the printed representation of a NaN.
1838         * tests/test-vasprintf-posix.c (test_function): Likewise.
1839         * tests/test-snprintf-posix.h (test_function): Likewise.
1840         * tests/test-sprintf-posix.h (test_function): Likewise.
1841         Reported by Eric Blake.
1842
1843 2007-05-23  Eric Blake  <ebb9@byu.net>
1844
1845         Fix fseeko/ftello on cygwin 1.5.24.
1846         * doc/functions/fseeko.texi (fseeko): Document the fix.
1847         * doc/functions/ftello.texi (ftello): Document the fix.
1848         * doc/functions/stdin.texi (stdin): Document the cygwin bug.
1849         * doc/functions/stdout.text (stdout): New file.
1850         * doc/functions/stderr.text (stderr): New file.
1851         * doc/gnulib.texi (Function Substitutes): Use new files.
1852         * tests/test-fseeko.c (main): Check for broken fseeko on cygwin
1853         prior to 1.7.0.
1854         * tests/test-ftello.c (main): Likewise for ftello.
1855         * tests/test-fseeko.sh: New file.
1856         * tests/test-ftello.sh: New file.
1857         * modules/fseeko-tests (Makefile.am): Ensure test-fseeko is run
1858         with seekable stdin.
1859         * modules/ftello-tests (Makefile.am): Likewise for test-ftello.
1860         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Detect the cygwin bug.
1861         (gl_REPLACE_FSEEKO): New macro.
1862         * m4/ftello.m4 (gl_FUNC_FTELLO, gl_REPLACE_FTELLO): Likewise.
1863         * modules/fseeko (Files): Distribute fseeko.c.
1864         * modules/ftello (Files): Distribute ftello.c.
1865         * lib/fseeko.c (rpl_fseeko) [__CYGWIN__]: Convert stdin to 64-bit
1866         mode.
1867         * lib/ftello.c (rpl_ftello): New file.
1868         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Allow replacement of
1869         fseeko, ftello.
1870         (gl_STDIN_LARGE_OFFSET): New macro.
1871         * modules/stdio (Makefile.am): Perform the replacement.
1872         * lib/stdio_.h (rpl_fseeko, rpl_ftello): Define when needed.
1873
1874 2007-05-23  Bruno Haible  <bruno@clisp.org>
1875
1876         * lib/stdio_.h (fseeko, ftello): Provide a link warning only if
1877         GNULIB_POSIXCHECK is defined.
1878
1879 2007-05-21  Bruno Haible  <bruno@clisp.org>
1880
1881         * m4/printf.m4 (gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE):
1882         Check also the output for NaN arguments. When cross-compiling, guess
1883         no on IRIX.
1884         * lib/vasnprintf.c: Update comments.
1885         * tests/test-vasnprintf-posix.c (strisnan): New function.
1886         (test_function): Use it.
1887         * tests/test-vasprintf-posix.c (strisnan): New function.
1888         (test_function): Use it.
1889         * tests/test-snprintf-posix.h (strisnan): New function.
1890         (test_function): Use it.
1891         * tests/test-sprintf-posix.h (strisnan): New function.
1892         (test_function): Use it.
1893         Reported by Eric Blake.
1894
1895 2007-05-20  Bruno Haible  <bruno@clisp.org>
1896
1897         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Add test for large finite
1898         numbers that fails on BeOS.
1899         * doc/functions/frexpl.texi: Update.
1900
1901 2007-05-20  Jim Meyering  <jim@meyering.net>
1902
1903         * NEWS: Mention the incompatible change (s/futimens/gl_futimens/)
1904         forced upon us by glibc-2.6.
1905
1906 2007-05-20  Bruno Haible  <bruno@clisp.org>
1907
1908         Fix *printf result for NaN, Inf on AIX, Solaris, OSF/1.
1909         * m4/printf.m4 (gl_PRINTF_INFINITE): Update cross-compiling guesses.
1910         (gl_PRINTF_INFINITE_LONG_DOUBLE): New macro.
1911         * lib/vasnprintf.c: Use NEED_PRINTF_INFINITE_DOUBLE instead of
1912         NEED_PRINTF_INFINITE.
1913         (is_infinitel): New function.
1914         (VASNPRINTF): Handle NEED_PRINTF_INFINITE_LONG_DOUBLE case.
1915         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE): Renamed from
1916         gl_PREREQ_VASNPRINTF_INFINITE.
1917         (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): New macro.
1918         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
1919         gl_PRINTF_INFINITE_LONG_DOUBLE and test its result. Invoke
1920         gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE and
1921         gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE instead of
1922         gl_PREREQ_VASNPRINTF_INFINITE.
1923         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
1924         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1925         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1926         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1927         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
1928         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1929         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1930         * doc/functions/fprintf.texi: Update.
1931         * doc/functions/printf.texi: Update.
1932         * doc/functions/snprintf.texi: Update.
1933         * doc/functions/sprintf.texi: Update.
1934         * doc/functions/vfprintf.texi: Update.
1935         * doc/functions/vprintf.texi: Update.
1936         * doc/functions/vsnprintf.texi: Update.
1937         * doc/functions/vsprintf.texi: Update.
1938
1939 2007-05-20  Bruno Haible  <bruno@clisp.org>
1940
1941         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): Set REPLACE_FREXPL if frexpl
1942         was not found in libc.
1943         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
1944
1945 2007-05-20  Bruno Haible  <bruno@clisp.org>
1946
1947         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
1948         printed as "-nan" instead of "nan".
1949         * tests/test-vasprintf-posix.c (test_function): Likewise.
1950         * tests/test-snprintf-posix.h (test_function): Likewise.
1951         * tests/test-sprintf-posix.h (test_function): Likewise.
1952         Needed for HP-UX 11.
1953
1954 2007-05-20  Jim Meyering  <jim@meyering.net>
1955
1956         Fix buggy test for the fchownat-deref bug.
1957         * m4/openat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Create the dangling
1958         symlink required for the run-test.  Without it, this test would
1959         always declare that fchownat doesn't work, and client code would
1960         unnecessarily use the replacement function with fixed libc.
1961         (gl_FUNC_FCHOWNAT): Eliminate a variable that wasn't initialized.
1962         Reported by Greg Schafer.
1963
1964 2007-05-19  Bruno Haible  <bruno@clisp.org>
1965
1966         * m4/isnanf.m4 (gl_ISNANF_WORKS): New macro.
1967         (gl_FUNC_ISNANF_NO_LIBM): Invoke it.
1968         * lib/isnan.c (FUNC): Use run-time expressions for SGI compiler.
1969         Needed for IRIX 6.5 and Solaris 2.5.1.
1970
1971 2007-05-19  Bruno Haible  <bruno@clisp.org>
1972
1973         * tests/test-vasnprintf-posix.c (have_minus_zero): New function.
1974         (test_function): Skip tests involving -0.0 on platforms where
1975         -0.0 = 0.0.
1976         * tests/test-vasprintf-posix.c (have_minus_zero): New function.
1977         (test_function): Skip tests involving -0.0 on platforms where
1978         -0.0 = 0.0.
1979         * tests/test-snprintf-posix.h (have_minus_zero): New function.
1980         (test_function): Skip tests involving -0.0 on platforms where
1981         -0.0 = 0.0.
1982         * tests/test-sprintf-posix.h (have_minus_zero): New function.
1983         (test_function): Skip tests involving -0.0 on platforms where
1984         -0.0 = 0.0.
1985         * tests/test-fprintf-posix.h (test_function): Remove all -0.0 related
1986         tests.
1987         * tests/test-printf-posix.h (test_function): Likewise.
1988         * tests/test-printf-posix.output: Remove all -0.0 related results.
1989         Needed for IRIX 6.5.
1990
1991 2007-05-19  Bruno Haible  <bruno@clisp.org>
1992
1993         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
1994         printed as "nan0x7fffffff" instead of "nan".
1995         * tests/test-vasprintf-posix.c (test_function): Likewise.
1996         * tests/test-snprintf-posix.h (test_function): Likewise.
1997         * tests/test-sprintf-posix.h (test_function): Likewise.
1998         * tests/test-fprintf-posix.h (NaN): Remove macro.
1999         (test_function): Remove all NaN related tests.
2000         * tests/test-printf-posix.h (NaN): Remove macro.
2001         (test_function): Remove all NaN related tests.
2002         * tests/test-printf-posix.output: Remove all NaN related results.
2003         Needed for IRIX 6.5.
2004
2005 2007-05-19  Bruno Haible  <bruno@clisp.org>
2006
2007         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Fix C89 syntax error in test code.
2008         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
2009
2010 2007-05-19  Bruno Haible  <bruno@clisp.org>
2011
2012         * lib/float_.h: New file.
2013         * m4/float_h.m4: New file.
2014         * modules/float: New file.
2015         * modules/isnanl (Dependencies): Add float.
2016         * modules/isnanl-nolibm (Dependencies): Likewise.
2017         * modules/mathl (Dependencies): Likewise.
2018         * modules/printf-frexpl (Dependencies): Likewise.
2019         * modules/signbit (Dependencies): Likewise.
2020         * modules/vasnprintf (Dependencies): Likewise.
2021         * doc/headers/float.texi: Update.
2022
2023 2007-05-19  Jim Meyering  <jim@meyering.net>
2024
2025         * lib/utimens.c (gl_futimens): Rename from futimens,
2026         now that glibc-2.6 declares futimens.
2027         * lib/utimens.h: Likewise.
2028
2029 2007-05-19  Bruno Haible  <bruno@clisp.org>
2030
2031         Avoid test failures on mingw.
2032         * tests/test-fprintf-posix.sh: Convert CR/LF to LF in output.
2033         * tests/test-printf-posix.sh: Likewise.
2034         * tests/test-vfprintf-posix.sh: Likewise.
2035         * tests/test-vprintf-posix.sh: Likewise.
2036
2037 2007-05-19  Bruno Haible  <bruno@clisp.org>
2038
2039         Fix *printf result for NaN, Inf, -0.0 on mingw.
2040         * m4/printf.m4 (gl_PRINTF_INFINITE): New macro.
2041         * lib/vasnprintf.c: Include math.h and isnan.h.
2042         (is_infinite_or_zero): New function.
2043         (VASNPRINTF): Fix also the handling of infinite or zero 'double'
2044         values in the %f, %F, %e, %E, %g, %G directives.
2045         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE): New macro.
2046         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
2047         gl_PRINTF_INFINITE and test its result. Invoke
2048         gl_PREREQ_VASNPRINTF_INFINITE.
2049         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
2050         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2051         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2052         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2053         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2054         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2055         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2056         * doc/functions/fprintf.texi: Update.
2057         * doc/functions/printf.texi: Update.
2058         * doc/functions/snprintf.texi: Update.
2059         * doc/functions/sprintf.texi: Update.
2060         * doc/functions/vfprintf.texi: Update.
2061         * doc/functions/vprintf.texi: Update.
2062         * doc/functions/vsnprintf.texi: Update.
2063         * doc/functions/vsprintf.texi: Update.
2064
2065 2007-05-19  Bruno Haible  <bruno@clisp.org>
2066
2067         * lib/vasnprintf.c (convert_to_decimal): Add an extra_zeroes argument.
2068         (scale10_round_decimal_long_double): Inline scale10_round_long_double.
2069         Instead of multiplying with 10^k, set extra_zeroes to k.
2070         (scale10_round_long_double): Remove function.
2071
2072 2007-05-18  Bruno Haible  <bruno@clisp.org>
2073
2074         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Fix logic bug
2075         introduced on 2007-05-06.
2076
2077 2007-05-18  Bruno Haible  <bruno@clisp.org>
2078
2079         * tests/test-vasnprintf-posix.c (test_function): Also test the %e and
2080         %g directives.
2081         * tests/test-vasprintf-posix.c (test_function): Likewise.
2082         * tests/test-snprintf-posix.h (test_function): Likewise.
2083         * tests/test-sprintf-posix.h (test_function): Likewise.
2084
2085 2007-05-18  Bruno Haible  <bruno@clisp.org>
2086
2087         * tests/test-vasnprintf-posix.c (SIZEOF): New macro.
2088         (strmatch): New function.
2089         (test_function): Test the %f directive on numbers of various exponents.
2090         * tests/test-vasprintf-posix.c (SIZEOF): New macro.
2091         (strmatch): New function.
2092         (test_function): Test the %f directive on numbers of various exponents.
2093         * tests/test-snprintf-posix.h (strmatch): New function.
2094         (test_function): Test the %f directive on numbers of various exponents.
2095         * tests/test-sprintf-posix.h (strmatch): New function.
2096         (test_function): Test the %f directive on numbers of various exponents.
2097         * tests/test-snprintf-posix.c (SIZEOF): New macro.
2098         * tests/test-sprintf-posix.c (SIZEOF): New macro.
2099         * tests/test-vsnprintf-posix.c (SIZEOF): New macro.
2100         * tests/test-vsprintf-posix.c (SIZEOF): New macro.
2101
2102 2007-05-18  Bruno Haible  <bruno@clisp.org>
2103
2104         Add support for 'long double' number output.
2105         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE): New macro.
2106         * lib/vasnprintf.c: Include math.h and float+.h.
2107         (mp_limb_t): New type.
2108         (GMP_LIMB_BITS): New macro.
2109         (mp_twolimb_t): New type.
2110         (GMP_TWOLIMB_BITS): New macro.
2111         (mpn_t): New type.
2112         (multiply, divide, convert_to_decimal, decode_long_double,
2113         scale10_round_long_double, scale10_round_decimal_long_double,
2114         floorlog10l): New functions.
2115         (VASNPRINTF) [NEED_PRINTF_LONG_DOUBLE]: Implement 'long double' support
2116         for the %f, %F, %e, %E, %g, %G directives.
2117         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_LONG_DOUBLE): New macro.
2118         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
2119         gl_PRINTF_LONG_DOUBLE and test its result. Invoke
2120         gl_PREREQ_VASNPRINTF_LONG_DOUBLE.
2121         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
2122         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2123         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2124         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2125         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2126         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2127         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2128         * modules/fprintf-posix (Depends-on): Add frexpl-nolibm.
2129         * modules/snprintf-posix (Depends-on): Likewise.
2130         * modules/sprintf-posix (Depends-on): Likewise.
2131         * modules/vasnprintf-posix (Depends-on): Likewise.
2132         * modules/vasprintf-posix (Depends-on): Likewise.
2133         * modules/vfprintf-posix (Depends-on): Likewise.
2134         * modules/vsnprintf-posix (Depends-on): Likewise.
2135         * modules/vsprintf-posix (Depends-on): Likewise.
2136         * modules/vasnprintf (Files): Add lib/float+.h.
2137         * doc/functions/fprintf.texi: Update.
2138         * doc/functions/printf.texi: Update.
2139         * doc/functions/snprintf.texi: Update.
2140         * doc/functions/sprintf.texi: Update.
2141         * doc/functions/vfprintf.texi: Update.
2142         * doc/functions/vprintf.texi: Update.
2143         * doc/functions/vsnprintf.texi: Update.
2144         * doc/functions/vsprintf.texi: Update.
2145
2146 2007-05-18  Bruno Haible  <bruno@clisp.org>
2147
2148         * lib/vasnprintf.c (USE_SNPRINTF): Define to 0 on BeOS.
2149
2150 2007-05-18  Bruno Haible  <bruno@clisp.org>
2151
2152         * lib/vasnprintf.c (VASNPRINTF) [WIN32]: Use %I64d instead of %lld
2153         for printing 64-bit integers. Needed for mingw.
2154
2155 2007-05-18  Bruno Haible  <bruno@clisp.org>
2156
2157         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
2158         gl_FUNC_FREXPL_WORKS.
2159         * modules/printf-frexpl (Files): Add m4/frexpl.m4.
2160
2161 2007-05-18  Bruno Haible  <bruno@clisp.org>
2162
2163         * modules/frexpl-nolibm-tests: New file.
2164
2165         * modules/frexpl-nolibm: New file.
2166         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): New macro.
2167
2168 2007-05-17  Paul Eggert  <eggert@cs.ucla.edu>
2169
2170         * lib/dirent_.h: Prefer #include_next <foo.h> to #include
2171         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
2172         GCC 4.2, which otherwise issues a lot of warnings.
2173         * lib/iconv_.h, lib/locale_.h, lib/netinet_in_.h, lib/sys_select_.h:
2174         * lib/sys_socket_.h, lib/sys_stat_.h, lib/sysexits_.h, lib/unistd_.h:
2175         Likewise.
2176         * modules/fchdir (dirent.h): Substitute @HAVE_INCLUDE_NEXT@.
2177         * modules/iconv_open (iconv.h): Likewise.
2178         * modules/locale (locale.h): Likewise.
2179         * modules/netinet_in (netinet/in.h): Likewise.
2180         * modules/sys_select (sys_select.h): Likewise.
2181         * modules/sys_socket (sys/socket.h): Likewise.
2182         * modules/sys_stat (sys/stat.h): Likewise.
2183         * modules/sysexits (sysexits.h): Likewise.
2184         * modules/unistd (unistd.h): Likewise.
2185
2186 2007-05-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2187
2188         * modules/closein-tests (Makefile.am): Distribute
2189         `test-closein.sh'.
2190
2191 2007-05-17  Bruno Haible  <bruno@clisp.org>
2192
2193         * tests/test-printf-posix.output: Renamed from
2194         tests/test-fprintf-posix.out.
2195         * modules/fprintf-posix-tests: Update.
2196         * modules/printf-posix-tests: Update.
2197         * modules/vfprintf-posix-tests: Update.
2198         * modules/vprintf-posix-tests: Update.
2199         * tests/test-fprintf-posix.sh: Update.
2200         * tests/test-printf-posix.sh: Update.
2201         * tests/test-vfprintf-posix.sh: Update.
2202         * tests/test-vprintf-posix.sh: Update.
2203         Reported by Ralf Wildenhues.
2204
2205 2007-05-16  Paul Eggert  <eggert@cs.ucla.edu>
2206
2207         * lib/fcntl_.h: Prefer #include_next <foo.h> to #include
2208         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
2209         GCC 4.2, which otherwise issues a lot of warnings.
2210         * lib/inttypes_.h, lib/math_.h, lib/search_.h, lib/signal_.h:
2211         * lib/stdint_.h, lib/stdio_.h, lib/stdlib_.h, lib/string_.h:
2212         * lib/sys_time_.h, lib/time_.h, lib/wchar_.h, lib/wctype_.h: Likewise.
2213         * lib/stdlib_.h: Don't bother with #pragma GCC system_header, as
2214         it should no longer be needed.
2215         * lib/string_.h: Likewise.
2216         * modules/absolute-header (HAVE_INCLUDE_NEXT): New 'make' define.
2217         * modules/fcntl (fcntl.h): Substitute @HAVE_INCLUDE_NEXT@.
2218         * modules/inttypes (inttypes.h): Likewise.
2219         * modules/math (math.h): Likewise.
2220         * modules/search (search.h): Likewise.
2221         * modules/signal (signal.h): Likewise.
2222         * modules/stdint (stdint.h): Likewise.
2223         * modules/stdio (stdio.h): Likewise.
2224         * modules/stdlib (stdlib.h): Likewise.
2225         * modules/string (string.h): Likewise.
2226         * modules/sys_time (sys/time.h): Likewise.
2227         * modules/time (time.h): Likewise.
2228         * modules/wchar (wchar.h): Likewise.
2229         * modules/wctype (wtype.h): Likewise.
2230
2231 2007-05-16  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
2232
2233         * doc/gnulib-tool.texi (CVS Issues): Fix typo.
2234
2235 2007-05-13  Bruno Haible  <bruno@clisp.org>
2236
2237         * stpcpy.m4 (gl_FUNC_STPCPY): Require AC_C_RESTRICT.
2238         * stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
2239         * strsep.m4 (gl_FUNC_STRSEP): Likewise.
2240         * strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
2241         (gl_PREREQ_STRTOK_R): Don't require it here.
2242
2243 2007-05-13  Bruno Haible  <bruno@clisp.org>
2244
2245         * lib/stdlib_.h (mkdtemp, mkstemp): Comment out argument name. Needed
2246         when used in C++ mode.
2247
2248 2007-05-12  Bruno Haible  <bruno@clisp.org>
2249
2250         * lib/linebuffer.h: Tweak doc.
2251         * lib/linebuffer.c: Likewise.
2252
2253 2007-05-12  James Youngman  <jay@gnu.org>
2254
2255         * lib/linebuffer.c (readlinebuffer_delim): New function,
2256         like readlinebuffer, but use a caller-specified delimiter.
2257         (readlinebuffer): Just call readlinebuffer_delim with '\n'
2258         as the delimiter.
2259         * lib/linebuffer.h (readlinebuffer_delim): Declare it.
2260
2261 2007-05-12  Sergey Poznyakoff  <gray@gnu.org.ua>
2262
2263         * m4/openat.m4 (gl_FUNC_OPENAT): Do not require openat-die.
2264         * modules/openat (Files): Remove openat-die.c.
2265         (Depends-on): Add openat-die.
2266         * modules/openat-die: New module.
2267
2268 2007-05-06  Bruno Haible  <bruno@clisp.org>
2269
2270         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING, gl_VSNPRINTF_ZEROSIZE_C99):
2271         Update with info about Cygwin.
2272         * doc/functions/fprintf.texi: Update.
2273         * doc/functions/printf.texi: Update.
2274         * doc/functions/snprintf.texi: Update.
2275         * doc/functions/sprintf.texi: Update.
2276         * doc/functions/vfprintf.texi: Update.
2277         * doc/functions/vprintf.texi: Update.
2278         * doc/functions/vsnprintf.texi: Update.
2279         * doc/functions/vsprintf.texi: Update.
2280         Reported by Eric Blake.
2281
2282 2007-05-06  Bruno Haible  <bruno@clisp.org>
2283
2284         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Perform the
2285         padding ourselves for the floating-point directives.
2286         * m4/printf.m4 (gl_PRINTF_FLAG_ZERO): New macro.
2287         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ZERO): New macro.
2288         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2289         gl_PRINTF_FLAG_ZERO and test its result. Invoke
2290         gl_PREREQ_VASNPRINTF_FLAG_ZERO.
2291         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2292         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
2293         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2294         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2295         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2296         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2297         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2298         * tests/test-snprintf-posix.h (test_function): Also check the width
2299         and some flags in the %f directive.
2300         * tests/test-sprintf-posix.h (test_function): Likewise.
2301         * tests/test-vasnprintf-posix.c (test_function): Likewise.
2302         * tests/test-vasprintf-posix.c (test_function): Likewise.
2303         * doc/functions/fprintf.texi: Update.
2304         * doc/functions/printf.texi: Update.
2305         * doc/functions/snprintf.texi: Update.
2306         * doc/functions/sprintf.texi: Update.
2307         * doc/functions/vfprintf.texi: Update.
2308         * doc/functions/vprintf.texi: Update.
2309         * doc/functions/vsnprintf.texi: Update.
2310         * doc/functions/vsprintf.texi: Update.
2311
2312 2007-05-06  Bruno Haible  <bruno@clisp.org>
2313
2314         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_GROUPING]: Don't
2315         pass the ' flag character to sprintf or snprintf.
2316         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING): New macro.
2317         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_GROUPING): New macro.
2318         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2319         gl_PRINTF_FLAG_GROUPING and test its result. Invoke
2320         gl_PREREQ_VASNPRINTF_FLAG_GROUPING.
2321         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2322         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
2323         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2324         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2325         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2326         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2327         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2328         * tests/test-snprintf-posix.h (test_function): Also check the grouping
2329         flag.
2330         * tests/test-sprintf-posix.h (test_function): Likewise.
2331         * tests/test-vasnprintf-posix.c (test_function): Likewise.
2332         * tests/test-vasprintf-posix.c (test_function): Likewise.
2333         * doc/functions/fprintf.texi: Update.
2334         * doc/functions/printf.texi: Update.
2335         * doc/functions/snprintf.texi: Update.
2336         * doc/functions/sprintf.texi: Update.
2337         * doc/functions/vfprintf.texi: Update.
2338         * doc/functions/vprintf.texi: Update.
2339         * doc/functions/vsnprintf.texi: Update.
2340         * doc/functions/vsprintf.texi: Update.
2341
2342 2007-05-01  Bruno Haible  <bruno@clisp.org>
2343
2344         * tests/test-argp-2.sh (func_compare): Drop .exe suffix.
2345
2346 2007-05-03  Paul Eggert  <eggert@cs.ucla.edu>
2347
2348         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use better
2349         comment for D_INO_IN_DIRENT.  Problem reported by James Youngman.
2350
2351 2007-05-02  Paul Eggert  <eggert@cs.ucla.edu>
2352
2353         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Test whether
2354         readdir returns garbage in d_ino.  Problem reported by Kaz Sasayama in
2355         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00021.html>.
2356
2357 2007-05-02  Sergey Poznyakoff  <gray@gnu.org.ua>
2358
2359         * lib/argp-help.c (struct hol_entry): New member `ord'.
2360         (HOL_ENTRY_PTRCMP): Use ord for comparison
2361         (hol_sort): Initialize ord.
2362
2363 2007-05-01  Bruno Haible  <bruno@clisp.org>
2364
2365         * doc/functions/_Exit_C99.texi: Renamed from doc/functions/_Exit.texi.
2366         Reported by Eric Blake.
2367         * doc/gnulib.texi (Function Substitutes): Update.
2368
2369 2007-05-01  Bruno Haible  <bruno@clisp.org>
2370
2371         * doc/functions.texi: Remove file, now redundant through
2372         doc/functions/*.texi.
2373
2374 2007-05-01  Bruno Haible  <bruno@clisp.org>
2375
2376         * modules/argp (Depends-on): Add sleep.
2377
2378 2007-05-01  Bruno Haible  <bruno@clisp.org>
2379
2380         * modules/sleep-tests: New file.
2381         * tests/test-sleep.c: New file.
2382
2383         * modules/sleep: New file.
2384         * lib/sleep.c: New file.
2385         * m4/sleep.m4: New file.
2386         * lib/unistd_.h (sleep): New declaration.
2387         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_SLEEP,
2388         HAVE_SLEEP.
2389         * modules/unistd (Makefile.am): Substitute GNULIB_SLEEP, HAVE_SLEEP.
2390         * doc/functions/sleep.texi: Document the sleep module.
2391
2392 2007-05-01  Bruno Haible  <bruno@clisp.org>
2393
2394         * lib/sigprocmask.h: Remove file.
2395         * lib/signal_.h: Incorporate the previous contents of sigprocmask.h.
2396         * lib/sigprocmask.c: Include <signal.h> instead of sigprocmask.h.
2397         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Substitute GNULIB_SIGPROCMASK,
2398         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T.
2399         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
2400         gl_SIGNAL_H_DEFAULTS. Set HAVE_POSIX_SIGNALBLOCKING as a shell variable.
2401         (gl_PREREQ_SIGPROCMASK): Require gl_SIGNAL_H_DEFAULTS. Set
2402         HAVE_SIGSET_T as a shell variable.
2403         * modules/signal (Makefile.am): Substitute GNULIB_SIGPROCMASK,
2404         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T into signal.h.
2405         * modules/sigprocmask (Files): Remove lib/sigprocmask.h.
2406         (Depends-on): Add signal. Remove verify.
2407         (configure.ac): Invoke gl_SIGNAL_MODULE_INDICATOR.
2408         (Include): Mention <signal.h> instead of sigprocmask.h.
2409         * NEWS: Mention the change.
2410         * lib/fatal-signal.c: Don't include sigprocmask.h.
2411
2412 2007-05-01  Bruno Haible  <bruno@clisp.org>
2413
2414         * modules/signal: New file.
2415         * lib/signal_.h: New file.
2416         * m4/signal_h.m4: New file.
2417
2418 2007-05-01  Bruno Haible  <bruno@clisp.org>
2419
2420         * lib/wctype_.h: Test HAVE_ISWCNTRL at configure time.
2421         * m4/wctype.m4 (gl_WCTYPE_H): Substitute HAVE_ISWCNTRL.
2422         * modules/wctype (Makefile.am): Substitute HAVE_ISWCNTRL instead of
2423         HAVE_WCTYPE_CTMP_BUG into wctype.h.
2424
2425 2007-05-01  Bruno Haible  <bruno@clisp.org>
2426
2427         * lib/sys_stat_.h: Test HAVE_LSTAT, HAVE_DECL_MKDIR, HAVE_IO_H at
2428         configure time.
2429         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Substitute HAVE_LSTAT,
2430         HAVE_DECL_MKDIR, HAVE_IO_H via AC_SUBST.
2431         * modules/sys_stat (Makefile.am): Substitute their values into
2432         sys/stat.h.
2433
2434 2007-05-01  Bruno Haible  <bruno@clisp.org>
2435
2436         * lib/glob_.h: Test HAVE_SYS_CDEFS_H at configure time.
2437         * m4/glob.m4 (gl_PREREQ_GLOB): Substitute HAVE_SYS_CDEFS_H via AC_SUBST.
2438         * modules/glob (Makefile.am): Put HAVE_SYS_CDEFS_H value into glob.h.
2439
2440 2007-05-01  Bruno Haible  <bruno@clisp.org>
2441
2442         * doc/header/assert.texi: Undo last change: don't mention the gnulib
2443         'assert' module here.
2444
2445 2007-05-01  Bruno Haible  <bruno@clisp.org>
2446
2447         * doc/functions/*.texi: New files.
2448         * doc/functions/google-ranking.txt: New file.
2449         * doc/gnulib.texi (Function Substitutes): New chapter.
2450         (ctime, inet_ntoa): Remove sections.
2451         * doc/ctime.texi: Remove file.
2452         * doc/inet_ntoa.texi: Remove file.
2453         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Update
2454         dependencies.
2455         (%.info): New rule, specifying a --reference-limit.
2456
2457 2007-05-01  Bruno Haible  <bruno@clisp.org>
2458
2459         * MODULES.html.sh (posix_functions): Remove 'exec', 'toc'.
2460
2461 2007-05-01  Bruno Haible  <bruno@clisp.org>
2462
2463         * modules/mkdir (Depends-on): Add sys_stat, because sys_stat provides
2464         the portability of 'mkdir' to mingw systems.
2465
2466 2007-05-01  Bruno Haible  <bruno@clisp.org>
2467
2468         * doc/headers/google-ranking.txt: New file.
2469
2470 2007-04-30  Eric Blake  <ebb9@byu.net>
2471
2472         Prefer fseeko to fseek.
2473         * modules/getpass (Depends-on): Add fseeko.
2474         * lib/getpass.c (getpass): Use fseeko, not fseek.
2475
2476 2007-04-30  Sergey Poznyakoff  <gray@gnu.org.ua>
2477
2478         * lib/argp-help.c (hol_entry_cmp): Option sorting algorithm
2479         assumes the sorting is stable, while most qsort implementations
2480         are not.  Use argument addresses to ensure they never compare as
2481         equal.
2482
2483         * tests/test-argp-2.sh (usage-indent test): Fix output
2484         (func_compare): Restore diff options
2485         * tests/test-argp.c: Restore #include "progname.h"
2486
2487 2007-04-29  Bruno Haible  <bruno@clisp.org>
2488
2489         * m4/printf.m4 (gl_VSNPRINTF_ZEROSIZE_C99): New macro.
2490         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2491         gl_VSNPRINTF_ZEROSIZE_C99. Test gl_cv_func_vsnprintf_zerosize_c99.
2492         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2493         * modules/snprintf-posix-tests (Files): Add tests/test-snprintf.c.
2494         (configure.ac): Define CHECK_SNPRINTF_POSIX.
2495         (TESTS, check_PROGRAMS): Add test-snprintf.
2496         * modules/vsnprintf-posix-tests (Files): Add tests/test-vsnprintf.c.
2497         (configure.ac): Define CHECK_VSNPRINTF_POSIX.
2498         (TESTS, check_PROGRAMS): Add test-vsnprintf.
2499         * tests/test-snprintf.c (main) [!CHECK_SNPRINTF_POSIX]: Disable
2500         assertions that fail on HP-UX, OSF/1, or IRIX.
2501         * tests/test-vsnprintf.c (main) [!CHECK_VSNPRINTF_POSIX]: Likewise.
2502
2503 2007-04-29  Bruno Haible  <bruno@clisp.org>
2504
2505         * MODULES.html.sh (posix_functions): Remove 'contents'.
2506
2507 2007-04-29  Karl Berry  <karl@gnu.org>
2508
2509         * config/srclist.txt (gendocs_template_min): new entry.
2510
2511 2007-04-29  Bruno Haible  <bruno@clisp.org>
2512
2513         Work around fpurge bug on BSD systems.
2514         * modules/fpurge (Makefile.am): Compile fpurge.c unconditionally.
2515         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't invoke AC_LIBOBJ.
2516         * lib/fpurge.h (fpurge): Don't handle __fpurge wrapper here. Define
2517         fpurge to rpl_fpurge if the system already has this function.
2518         * lib/fpurge.c (fpurge): Handle also the __fpurge wrapper case and
2519         the case where the system already has this function. Correct invariants
2520         on BSD systems.
2521         * lib/fseeko.c (rpl_fseeko): Update recognition of preceding fflush on
2522         BSD systems.
2523
2524 2007-04-29  Sergey Poznyakoff  <gray@gnu.org.ua>
2525
2526         * lib/argp-help.c (hol_cluster_cmp): Reverse comparison.  Change
2527         proposed by Sven Verdoolaege.
2528
2529         * tests/test-argp.c: Fix option ordering.  Test deeply clustered
2530         options.
2531         * tests/test-argp-2.sh (func_compare): Use diff instead of cmp.
2532         (usage and help tests): Update
2533
2534 2007-04-29  Bruno Haible  <bruno@clisp.org>
2535
2536         * tests/test-fflush.c (main): Use a file of size 17, not 10.
2537         Print more information in case of failure. Disable a test on BeOS.
2538
2539 2007-04-29  Bruno Haible  <bruno@clisp.org>
2540
2541         * tests/**/test-*.[hc] (ASSERT): Use fprintf to show the line number.
2542         This helps debugging on systems on which no gdb is available.
2543
2544 2007-04-29  Bruno Haible  <bruno@clisp.org>
2545
2546         * lib/freading.h: Improve comments.
2547         * lib/fwriting.h: Likewise.
2548         * tests/test-freading.c (main): Don't check freading immediately after
2549         repositioning. Needed for glibc.
2550
2551 2007-04-29  Bruno Haible  <bruno@clisp.org>
2552
2553         * lib/freading.c (freading): Trivial simplification.
2554
2555 2007-04-28  Bruno Haible  <bruno@clisp.org>
2556
2557         * tests/test-fwriting.c (main): Also test the interaction between
2558         fflush and fwriting.
2559         * modules/fwriting-tests (Depends-on): Add fflush.
2560
2561         * tests/test-freading.c (main): Also test the interaction between
2562         fflush and freading.
2563         * modules/freading-tests (Depends-on): Add fflush.
2564
2565 2007-04-28  Bruno Haible  <bruno@clisp.org>
2566
2567         * lib/stdio_.h (fseek, ftell): Provide link warnings suggesting to use
2568         fseeko and ftello.
2569         Suggested by Eric Blake.
2570
2571 2007-04-28  Jim Meyering  <jim@meyering.net>
2572
2573         Avoid false-negative in gl_STDINT_H's C99 conformance test.
2574         * m4/stdint.m4 (gl_STDINT_H): When checking whether stdint.h conforms
2575         to C99, include all of gl_STDINT_INCLUDES, not just <stddef.h>.
2576
2577 2007-04-27  Eric Blake  <ebb9@byu.net>
2578
2579         * doc/headers/assert.texi (assert.h): Document assert module use.
2580
2581 2007-04-27  Bruno Haible  <bruno@clisp.org>
2582
2583         * doc/headers/*.texi: New files.
2584         * doc/gnulib.texi (Header File Substitutes): New chapter.
2585         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Specify
2586         dependencies.
2587         (standards.info ,standards.html, standards.dvi): Update dependencies.
2588         (mostlyclean, clean): New targets.
2589
2590 2007-04-27  Bruno Haible  <bruno@clisp.org>
2591
2592         * lib/sysexits_.h: Renamed from lib/sysexit_.h.
2593         * modules/sysexits (Files, Makefile.am): Update.
2594
2595         * lib/sys_socket_.h: Renamed from lib/socket_.h.
2596         * modules/sys_socket (Files, Makefile.am): Update.
2597
2598         * lib/sys_stat_.h: Renamed from lib/stat_.h.
2599         * modules/sys_stat (Files, Makefile.am): Update.
2600
2601 2007-04-27  Eric Blake  <ebb9@byu.net>
2602
2603         * lib/freading.h: Improve comments.
2604         * lib/fwriting.h: Likewise.
2605         * lib/fflush.c: Likewise.
2606
2607         Fix closein for mingw.
2608         * modules/closein-tests: Add tests for closein.
2609         * tests/test-closein.c: New file.
2610         * tests/test-closein.sh: Likewise.
2611         * lib/unistd_.h [!SEEK_CUR]: Mingw also needs stdlib.h for _exit.
2612         * lib/closein.c (close_stdin): Don't fflush non-seekable streams.
2613
2614 2007-04-27  Bruno Haible  <bruno@clisp.org>
2615
2616         * lib/inttypes_.h [_DECC]: Don't use #include_next if the compiler
2617         version is < 6.
2618         * lib/math_.h [__DECC]: Likewise.
2619         * lib/stdio_.h [__DECC]: Likewise.
2620         * lib/stdlib_.h [__DECC]: Likewise.
2621         * lib/string_.h [__DECC]: Likewise.
2622         * lib/time_.h [__DECC]: Likewise.
2623         * lib/wchar_.h [__DECC]: Likewise.
2624         * lib/wctype_.h [__DECC]: Likewise.
2625
2626 2007-04-27  Bruno Haible  <bruno@clisp.org>
2627
2628         * tests/test-fbufmode.c (main): Relax test, to avoid failure on mingw.
2629
2630 2007-04-27  Bruno Haible  <bruno@clisp.org>
2631
2632         * lib/fflush.c: Add comments.
2633         * modules/fpurge-tests (Depends-on): Add fflush.
2634         * modules/freadable-tests (Depends-on): Likewise.
2635         * modules/fwritable-tests (Depends-on): Likewise.
2636
2637 2007-04-27  Charles Wilson  <libtool@cwilson.fastmail.fm>
2638
2639         * m4/argz.m4 (gl_FUNC_ARGZ): Use !HAVE_WORKING_ARGZ instead of
2640         SYSTEM_ARGZ_IS_BROKEN.  Also, minor stylistic improvements.
2641         Report by Bruno Haible <bruno@clisp.org>.
2642
2643 2007-04-26  Eric Blake  <ebb9@byu.net>
2644
2645         Fix fflush on mingw.
2646         * modules/fflush (Depends-on): Add freading.
2647         * lib/fflush.c (rpl_fflush): Use freading to avoid losing buffered
2648         but unread data.
2649
2650 2007-04-26  Eric Blake  <ebb9@byu.net>
2651         and Bruno Haible  <bruno@clisp.org>
2652
2653         Implement freading and fwriting.
2654         * lib/freading.c: New file.
2655         * lib/freading.h: Likewise.
2656         * m4/freading.m4: Likewise.
2657         * modules/freading: Likewise.
2658         * modules/freading-tests: Likewise.
2659         * tests/test-freading.c: Likewise.
2660         * lib/fwriting.c: New file.
2661         * lib/fwriting.h: Likewise.
2662         * m4/fwriting.m4: Likewise.
2663         * modules/fwriting: Likewise.
2664         * modules/fwriting-tests: Likewise.
2665         * tests/test-fwriting.c: Likewise.
2666         * MODULES.html.sh (File stream based Input/Output): Mention them.
2667
2668 2007-04-26  Bruno Haible  <bruno@clisp.org>
2669
2670         * lib/stdio_.h (fseeko, ftello): Check that off_t has the same size as
2671         'long' when we assume it.
2672         Suggested by Eric Blake.
2673
2674 2007-04-26  Bruno Haible  <bruno@clisp.org>
2675
2676         Ensure fseeko, ftello are declared on glibc systems.
2677         * modules/fflush (configure.ac-early): Require AC_FUNC_FSEEKO.
2678         * modules/fseeko (configure.ac-early): Likewise.
2679         * modules/ftello (configure.ac-early): Likewise.
2680         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't define HAVE_FSEEKO, rely on
2681         AC_FUNC_FSEEKO for this.
2682         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Inline gl_CHECK_FSEEKO.
2683         (gl_CHECK_FSEEKO): Remove macro.
2684
2685 2007-04-26  Bruno Haible  <bruno@clisp.org>
2686
2687         * tests/test-fflush.c (main): Also check the ftell result after
2688         fflush and fseek/fseeko.
2689         * lib/fflush.c (rpl_fflush): For BSD implementations, update the
2690         file descriptor position cache in the stream.
2691         * lib/fseeko.c (rpl_fseeko): Likewise.
2692
2693 2007-04-26  Bruno Haible  <bruno@clisp.org>
2694
2695         * modules/fflush-tests (Depends-on): Add fseeko.
2696
2697 2007-04-25  Charles Wilson  <libtool@cwilson.fastmail.fm>
2698             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2699
2700         * lib/argz_.h: ensure error_t definition is obtained in same
2701         mechanism system argz.h would have.
2702         * m4/argz.m4 (gl_FUNC_ARGZ): add new test to check if $host's
2703         argz facilities are known bad.  Err on the side of caution if
2704         cross-compiling.
2705
2706 2007-04-25  Eric Blake  <ebb9@byu.net>
2707
2708         * lib/fpurge.c (includes): Use stdlib.h for free.
2709         * tests/test-fflush.c (main): Also test fflush-fseeko.
2710
2711 2007-04-25  Bruno Haible  <bruno@clisp.org>
2712
2713         Make fflush+fseek POSIX-compliant on FreeBSD and MacOS X.
2714         * lib/fseeko.c: New file.
2715         * lib/stdio_.h: Include <sys/types.h> when off_t is needed.
2716         (fseeko, fseek): Define to replacements if REPLACE_FFLUSH.
2717         * m4/fseeko.m4 (gl_CHECK_FSEEKO): New macro, extracted from
2718         gl_FUNC_FSEEKO.
2719         (gl_FUNC_FSEEKO): Invoke it.
2720         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Arrange to compile fseeko.c. Invoke
2721         gl_CHECK_FSEEKO. Define HAVE_FSEEKO.
2722         * modules/fflush (Files): Add lib/fseeko.c, m4/fseeko.m4.
2723
2724 2007-04-25  Bruno Haible  <bruno@clisp.org>
2725
2726         * modules/fflush (Depends-on): Add ftello.
2727
2728 2007-04-25  Bruno Haible  <bruno@clisp.org>
2729
2730         * modules/ftello-tests: New file.
2731         * tests/test-ftello.c: New file.
2732
2733         * modules/ftello: New file.
2734         * m4/ftello.m4: New file.
2735         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELLO,
2736         HAVE_FTELLO.
2737         * lib/stdio_.h (ftello): New declaration.
2738         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELLO,
2739         HAVE_FTELLO.
2740
2741 2007-04-25  Bruno Haible  <bruno@clisp.org>
2742
2743         * modules/fseeko-tests: New file.
2744         * tests/test-fseeko.c: New file.
2745
2746         * modules/fseeko: New file.
2747         * m4/fseeko.m4: New file.
2748         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEKO,
2749         HAVE_FSEEKO.
2750         * lib/stdio_.h (fseeko): New declaration.
2751         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEKO,
2752         HAVE_FSEEKO.
2753
2754 2007-04-25  Bruno Haible  <bruno@clisp.org>
2755
2756         * lib/stdio_.h (fflush): Add support for GNULIB_POSIXCHECK.
2757
2758 2007-04-25  Bruno Haible  <bruno@clisp.org>
2759
2760         * lib/unistd_.h: Include <stdio.h> if needed to get the SEEK_* macros.
2761         * tests/test-stdio.c: Check that the various SEEK_* macros are defined.
2762         * tests/test-unistd.c: Likewise.
2763         * tests/test-fcntl.c: Likewise.
2764
2765 2007-04-23  Eric Blake  <ebb9@byu.net>
2766
2767         * lib/fflush.c: Fix missing include.
2768         Reported by Bruno Haible.
2769
2770 2007-04-23  Bruno Haible  <bruno@clisp.org>
2771
2772         * lib/fpurge.c (fpurge) [glibc, BSD]: Free a malloc()ed ungetc buffer.
2773         Reported by Eric Blake.
2774
2775 2007-04-23  Bruno Haible  <bruno@clisp.org>
2776
2777         * lib/fbufmode.c (fbufmode): Port to Solaris/SPARC64.
2778
2779 2007-04-23  Bruno Haible  <bruno@clisp.org>
2780
2781         * lib/fseterr.c (fseterr): Don't hardcode the value of _IOERR.
2782
2783 2007-04-23  Bruno Haible  <bruno@clisp.org>
2784
2785         * tests/test-fbufmode.c (main): Be prepared to a failure of setvbuf.
2786         Needed on HP-UX 11.
2787
2788 2007-04-16  Eric Blake  <ebb9@byu.net>
2789
2790         Make fflush rely on fpurge.
2791         * lib/fflush.c (rpl_fflush): Rely on fpurge module, rather than
2792         open coding all variants.
2793         * modules/fflush (Depends-on): Add fpurge and unistd.
2794         * modules/fflush-tests (Depends-on): Unistd is no longer extra.
2795         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Simplify.
2796
2797         Fix --with-tests compilation on cygwin.
2798         * modules/argmatch-tests (Makefile.am): List gnulib library first
2799         in LDADD.
2800         * modules/argp-tests (Makefile.am): Likewise.
2801         * modules/array-list-tests (Makefile.am): Likewise.
2802         * modules/array-oset-tests (Makefile.am): Likewise.
2803         * modules/avltree-list-tests (Makefile.am): Likewise.
2804         * modules/avltree-oset-tests (Makefile.am): Likewise.
2805         * modules/avltreehash-list-tests (Makefile.am): Likewise.
2806         * modules/carray-list-tests (Makefile.am): Likewise.
2807         * modules/dirname-tests (Makefile.am): Likewise.
2808         * modules/frexp-tests (Makefile.am): Likewise.
2809         * modules/isnanl-tests (Makefile.am): Likewise.
2810         * modules/linked-list-tests (Makefile.am): Likewise.
2811         * modules/linkedhash-list-tests (Makefile.am): Likewise.
2812         * modules/lock-tests (Makefile.am): Likewise.
2813         * modules/rbtree-list-tests (Makefile.am): Likewise.
2814         * modules/rbtree-oset-tests (Makefile.am): Likewise.
2815         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
2816         * modules/tls-tests (Makefile.am): Likewise.
2817         * modules/tsearch-tests (Makefile.am): Likewise.
2818         * modules/xvasprintf-tests (Makefile.am): Likewise.
2819
2820         Fix fpurge for cygwin.
2821         * lib/fpurge.c (fpurge): Fix order of operation flub, and return a
2822         value.
2823         * modules/fpurge-tests (Depends-on): Clean up trash.
2824
2825 2007-04-16  Simon Josefsson  <simon@josefsson.org>
2826
2827         * lib/gc-libgcrypt.c (gc_hash_open): Shut up compiler warnings.
2828
2829         * m4/autobuild.m4: Re-indent.
2830
2831 2007-04-13  Bruno Haible  <bruno@clisp.org>
2832
2833         * modules/fpurge-tests: New file.
2834         * tests/test-fpurge.c: New file.
2835
2836         * modules/fpurge: New file.
2837         * lib/fpurge.h: New file.
2838         * lib/fpurge.c: New file.
2839         * m4/fpurge.m4: New file.
2840
2841 2007-04-13  Bruno Haible  <bruno@clisp.org>
2842
2843         * modules/fbufmode-tests: New file.
2844         * tests/test-fbufmode.c: New file.
2845
2846         * modules/fbufmode: New file.
2847         * lib/fbufmode.h: New file.
2848         * lib/fbufmode.c: New file.
2849         * m4/fbufmode.m4: New file.
2850
2851 2007-04-13  Bruno Haible  <bruno@clisp.org>
2852
2853         * modules/fwritable-tests: New file.
2854         * tests/test-fwritable.c: New file.
2855
2856         * modules/fwritable: New file.
2857         * lib/fwritable.h: New file.
2858         * lib/fwritable.c: New file.
2859         * m4/fwritable.m4: New file.
2860
2861 2007-04-13  Bruno Haible  <bruno@clisp.org>
2862
2863         * modules/freadable-tests: New file.
2864         * tests/test-freadable.c: New file.
2865
2866         * modules/freadable: New file.
2867         * lib/freadable.h: New file.
2868         * lib/freadable.c: New file.
2869         * m4/freadable.m4: New file.
2870
2871 2007-04-13  Bruno Haible  <bruno@clisp.org>
2872
2873         * modules/fflush-tests (Makefile.am): Remove EXTRA_DIST. Augment
2874         MOSTLYCLEANFILES.
2875
2876 2007-04-13  Paul Eggert  <eggert@cs.ucla.edu>
2877
2878         * build-aux/bootstrap (gnulib_tool_option_extras): New var, used by
2879         gzip bootstrap.conf to avoid dragging in i18n machinery.
2880         (gnulib_tool_option): Use it.
2881
2882 2007-04-13  Bruno Haible  <bruno@clisp.org>
2883
2884         * tests/test-vasnprintf-posix.c (test_function): Add tests for %f and
2885         %F directives.
2886         * tests/test-vasprintf-posix.c (test_function): Likewise.
2887         * tests/test-snprintf-posix.h (test_function): Likewise.
2888         * tests/test-sprintf-posix.h (test_function): Likewise.
2889         * tests/test-fprintf-posix.h (test_function): Likewise.
2890         * tests/test-printf-posix.h (test_function): Likewise.
2891         * tests/test-fprintf-posix.out: Likewise.
2892
2893 2007-04-13  Bruno Haible  <bruno@clisp.org>
2894
2895         * modules/lock-tests (configure.ac): For LIBSCHED, try also -lposix4.
2896         * modules/tls-tests (configure.ac): Likewise.
2897         Reported by Arto C. Nirkko <anirkko@insel.ch>.
2898
2899 2007-04-13  Bruno Haible  <bruno@clisp.org>
2900
2901         * lib/tls.c (glthread_tls_get): Fix return type.
2902         Patch by Arto C. Nirkko <anirkko@insel.ch>.
2903
2904 2007-04-12  Eric Blake  <ebb9@byu.net>
2905
2906         * modules/gettime (Depends-on): Remove gettime.
2907         Reported by Dmitry V. Levin.
2908
2909 2007-04-12  Bruno Haible  <bruno@clisp.org>
2910
2911         * modules/fflush (Include): Mention <stdio.h>.
2912         * modules/strtoimax (Include): Mention <inttypes.h>.
2913         * modules/strtoumax (Include): Likewise.
2914
2915 2007-04-12  Eric Blake  <ebb9@byu.net>
2916
2917         * .cvsignore: New file.
2918         * .gitignore: Likewise.
2919
2920 2007-04-12  Bruno Haible  <bruno@clisp.org>
2921
2922         * modules/iconv-tests (test_iconv_LDADD): Mention -liconv after LDADD,
2923         not before, since $(LDADD) often contains libgnu.a.
2924         * modules/striconv-tests (test_striconv_LDADD): Likewise.
2925         * modules/striconveh-tests (test_striconveh_LDADD): Likewise.
2926         * modules/striconveha-tests (test_striconveha_LDADD): Likewise.
2927         Needed on Cygwin.
2928
2929 2007-04-12  Eric Blake  <ebb9@byu.net>
2930
2931         Work around glibc's failure to flush stdin on fclose.
2932         * lib/closein.c (close_stdin): Flush stdin before closing.
2933
2934         Work around glibc's failure to reset seekable stdin on exit.
2935         * modules/closein: New module.
2936         * lib/closein.c: New file.
2937         * lib/closein.h: Likewise.
2938         * m4/closein.m4: Likewise.
2939         * MODULES.html.sh (File stream based Input/Output): Document it.
2940
2941 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2942
2943         * gnulib-tool: Rename generated 'autobuild' script to
2944         'do-autobuild' in --create-megatestdir output.
2945
2946         * doc/gnulib.texi (Build robot for gnulib): Fix.
2947
2948 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2949
2950         * modules/sysexits (Depends-on): Add absolute-header.
2951
2952 2007-04-12  Eric Blake  <ebb9@byu.net>
2953
2954         No need to preserve errno on success.
2955         * lib/fflush.c (rpl_fflush): Simplify errno tracking.
2956         Reported by Bruno Haible.
2957
2958 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2959
2960         * MODULES.html.sh (Support for maintaining and releasing
2961         projects): Add autobuild.  Suggested by Eric Blake <ebb9@byu.net>.
2962
2963 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2964
2965         * gnulib-tool (func_modules_add_dummy): Respect --avoid=dummy.
2966
2967 2007-04-12  Simon Josefsson  <simon@josefsson.org>
2968
2969         * modules/autobuild: New module.
2970
2971         * m4/autobuild.m4: New file.
2972
2973 2007-04-11  Bruno Haible  <bruno@clisp.org>
2974
2975         * lib/vasnprintf.c (VASNPRINTF): Implement the %F directive using the
2976         %f directive, if NEED_PRINTF_DIRECTIVE_F is defined.
2977         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): New macro.
2978         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_F): New macro.
2979         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
2980         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2981         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2982         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2983         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2984         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2985         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Invoke
2986         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2987         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2988         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Invoke
2989         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2990         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2991         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Invoke
2992         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2993         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2994         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Invoke
2995         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2996         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
2997         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Invoke
2998         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
2999         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3000         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Invoke
3001         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3002         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3003         Reported by Eric Blake.
3004
3005 2007-04-11  Bruno Haible  <bruno@clisp.org>
3006
3007         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Fix test. It always failed.
3008
3009 2007-04-10  Bruno Haible  <bruno@clisp.org>
3010
3011         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
3012         for NaN and Infinity. Needed on FreeBSD 6.1.
3013         * tests/test-vasnprintf-posix.c (test_function): Undo last change
3014         regarding results for "%010a" of Infinity and NaN.
3015         * tests/test-vasprintf-posix.c (test_function): Likewise.
3016         * tests/test-snprintf-posix.h (test_function): Likewise.
3017         * tests/test-sprintf-posix.h (test_function): Likewise.
3018         * tests/test-fprintf-posix.h (test_function): Likewise.
3019         * tests/test-printf-posix.h (test_function): Likewise.
3020         * tests/test-fprintf-posix.out: Likewise.
3021
3022 2007-04-10  Bruno Haible  <bruno@clisp.org>
3023
3024         * modules/locale-tests: New file.
3025         * tests/test-locale.c: New file.
3026
3027         * modules/locale: New file.
3028         * lib/locale_.h: New file.
3029         * m4/locale_h.m4: New file.
3030
3031 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
3032             Bruno Haible  <bruno@clisp.org>
3033
3034         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
3035         be determined, test for availability of the copysignf, copysign,
3036         copysignl functions.
3037         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
3038         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
3039         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
3040
3041 2007-04-09  Eric Blake  <ebb9@byu.net>
3042
3043         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
3044         * modules/stdio (Makefile.am): Support fflush.
3045         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
3046         * modules/fflush: New file.
3047         * lib/fflush.c: Likewise.
3048         * m4/fflush.m4: Likewise.
3049         * modules/fflush-tests: New test.
3050         * tests/test-fflush.c: Likewise.
3051         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
3052
3053 2007-04-06  Bruno Haible  <bruno@clisp.org>
3054
3055         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
3056         (VASNPRINTF): Use signbit for faster determination whether to print a
3057         minus sign.
3058         * modules/vasnprintf (Files): Remove lib/float+.h.
3059         * modules/fprintf-posix (Depends-on): Add signbit.
3060         * modules/snprintf-posix (Depends-on): Likewise.
3061         * modules/sprintf-posix (Depends-on): Likewise.
3062         * modules/vasnprintf-posix (Depends-on): Likewise.
3063         * modules/vasprintf-posix (Depends-on): Likewise.
3064         * modules/vfprintf-posix (Depends-on): Likewise.
3065         * modules/vsnprintf-posix (Depends-on): Likewise.
3066         * modules/vsprintf-posix (Depends-on): Likewise.
3067
3068 2007-04-06  Bruno Haible  <bruno@clisp.org>
3069
3070         * tests/test-frexp.c (main): Test also the sign bit of zero results.
3071         * tests/test-frexpl.c (main): Likewise.
3072         * tests/test-ldexpl.c (main): Likewise.
3073         * modules/frexp-tests (Depends-on): Add signbit.
3074         * modules/frexpl-tests (Depdends-on): Likewise.
3075         * modules/ldexpl-tests (Depdends-on): Likewise.
3076
3077 2007-04-06  Bruno Haible  <bruno@clisp.org>
3078
3079         * modules/signbit-tests: New file.
3080         * tests/test-signbit.c: New file.
3081
3082         * modules/signbit: New file.
3083         * lib/signbitf.c: New file.
3084         * lib/signbitd.c: New file.
3085         * lib/signbitl.c: New file.
3086         * m4/signbit.m4: New file.
3087         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
3088         (signbit): New macro.
3089         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
3090         REPLACE_SIGNBIT.
3091         * modules/math (Makefile.am) Substibute also GNULIB_SIGNBIT and
3092         REPLACE_FREXPL into math.h.
3093
3094 2007-04-06  Bruno Haible  <bruno@clisp.org>
3095
3096         * modules/isnanf-nolibm-tests: New file.
3097         * tests/test-isnanf.c: New file.
3098
3099         * modules/isnanf-nolibm: New file.
3100         * lib/isnanf.h: New file.
3101         * lib/isnanf.c: New file.
3102         * lib/isnan.c: Consider the USE_FLOAT macro.
3103         * m4/isnanf.m4: New file.
3104
3105 2007-04-06  Bruno Haible  <bruno@clisp.org>
3106
3107         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
3108         (Link): New section.
3109
3110         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
3111
3112 2007-04-06  Bruno Haible  <bruno@clisp.org>
3113
3114         Assume the 'long double' type.
3115         * m4/longdouble.m4: Remove file.
3116         * config/srclist.txt: Don't mention longdouble.m4.
3117         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
3118         * lib/float+.h: Likewise.
3119         * lib/frexp.c: Likewise.
3120         * lib/printf-args.h: Likewise.
3121         * lib/printf-args.c: Likewise.
3122         * lib/printf-frexp.c: Likewise.
3123         * lib/printf-parse.c: Likewise.
3124         * lib/vasnprintf.c: Likewise.
3125         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
3126         * m4/intl.m4: Likewise.
3127         * m4/isnanl.m4: Likewise.
3128         * m4/printf.m4: Likewise.
3129         * m4/printf-frexpl.m4: Likewise.
3130         * m4/vasnprintf.m4: Likewise.
3131         * modules/allocsa (Files): Remove m4/longdouble.m4.
3132         * modules/gettext (Files): Likewise.
3133         * modules/relocatable-prog-wrapper (Files): Likewise.
3134         * modules/vasnprintf (Files): Likewise.
3135         * modules/isnanl (Files): Likewise.
3136         (Include): Simplify.
3137         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
3138         (Include): Simplify.
3139         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
3140         (Include): Simplify.
3141         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
3142         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3143         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
3144         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3145         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
3146         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3147         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
3148         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3149         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
3150         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3151         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
3152         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3153         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
3154         * tests/test-isnanl.c: Likewise.
3155         * tests/test-snprintf-posix.h: Likewise.
3156         * tests/test-sprintf-posix.h: Likewise.
3157         * tests/test-vasnprintf-posix.c: Likewise.
3158         * tests/test-vasnprintf-posix2.c: Likewise.
3159         * tests/test-vasprintf-posix.c: Likewise.
3160
3161 2007-04-06  Bruno Haible  <bruno@clisp.org>
3162
3163         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
3164         * lib/math_.h [__DECC]: Include the overridden include file through
3165         #include_next, outside the double-inclusion guard.
3166         * lib/stdio_.h [__DECC]: Likewise.
3167         * lib/stdlib_.h [__DECC]: Likewise.
3168         * lib/string_.h [__DECC]: Likewise.
3169         * lib/time_.h [__DECC]: Likewise.
3170         * lib/wchar_.h [__DECC]: Likewise.
3171         * lib/wctype_.h [__DECC]: Likewise.
3172         * lib/inttypes_.h [__DECC]: Likewise.
3173         Reported by Albert Chin <china@thewrittenword.com> in
3174         <http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00088.html>.
3175
3176 2007-04-04  Eric Blake  <ebb9@byu.net>
3177
3178         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
3179         1.5.x.
3180
3181 2007-04-04  Bruno Haible  <bruno@clisp.org>
3182
3183         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
3184         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
3185
3186 2007-04-04  Bruno Haible  <bruno@clisp.org>
3187
3188         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
3189         results for "%010a" of Infinity and NaN.
3190         * tests/test-vasprintf-posix.c (test_function): Likewise.
3191         * tests/test-snprintf-posix.h (test_function): Likewise.
3192         * tests/test-sprintf-posix.h (test_function): Likewise.
3193         * tests/test-fprintf-posix.h (test_function): Remove these tests.
3194         * tests/test-printf-posix.h (test_function): Likewise.
3195         * tests/test-fprintf-posix.out: Update.
3196         Needed for FreeBSD 6.1.
3197
3198 2007-04-04  Bruno Haible  <bruno@clisp.org>
3199
3200         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
3201         directly used by the gnulib modules nor by gnulib-tool.
3202
3203 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
3204
3205         * DEPENDENCIES: Give overall description of version dependency
3206         desirability.  Use more-typical names for apps.
3207         Add shell, coreutils, diffutils, grep, tar, gzip.
3208
3209 2007-04-04  Simon Josefsson  <simon@josefsson.org>
3210
3211         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
3212
3213 2007-04-04  Karl Berry  <karl@gnu.org>
3214
3215         * MODULES.html.sh (func_module): missing '.
3216
3217 2007-04-03  Bruno Haible  <bruno@clisp.org>
3218
3219         * modules/argmatch-tests (Makefile.am): New variable
3220         test_argmatch_LDADD.
3221         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
3222         * modules/array-list-tests (Makefile.am): New variable
3223         test_array_list_LDADD.
3224         * modules/array-oset-tests (Makefile.am): New variable
3225         test_array_oset_LDADD.
3226         * modules/avltree-list-tests (Makefile.am): New variable
3227         test_avltree_list_LDADD.
3228         * modules/avltree-oset-tests (Makefile.am): New variable
3229         test_avltree_oset_LDADD.
3230         * modules/avltreehash-list-tests (Makefile.am): New variable
3231         test_avltreehash_list_LDADD.
3232         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
3233         test_canonicalize_lgpl_LDADD.
3234         * modules/carray-list-tests (Makefile.am): New variable
3235         test_carray_list_LDADD.
3236         * modules/dirname-tests (Makefile.am): New variable
3237         test_dirname_LDADD.
3238         * modules/linked-list-tests (Makefile.am): New variable
3239         test_linked_list_LDADD.
3240         * modules/linkedhash-list-tests (Makefile.am): New variable
3241         test_linkedhash_list_LDADD.
3242         * modules/rbtree-list-tests (Makefile.am): New variable
3243         test_rbtree_list_LDADD.
3244         * modules/rbtree-oset-tests (Makefile.am): New variable
3245         test_rbtree_oset_LDADD.
3246         * modules/rbtreehash-list-tests (Makefile.am): New variable
3247         test_rbtreehash_list_LDADD.
3248         * modules/xvasprintf-tests (Makefile.am): New variable
3249         test_xvasprintf_LDADD.
3250         Reported by Eric Blake.
3251
3252 2007-04-03  Eric Blake  <ebb9@byu.net>
3253
3254         * DEPENDENCIES: Weaken m4 requirements.
3255
3256 2007-04-03  Bruno Haible  <bruno@clisp.org>
3257
3258         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
3259         * modules/isnanl-tests (configure.ac): Likewise.
3260
3261 2007-04-03  Ben Pfaff  <blp@gnu.org>
3262
3263         * modules/iconv_open: Add $(srcdir)/ to source directory
3264         references in Makefile fragments that call gperf, to fix VPATH
3265         builds.
3266
3267 2007-04-03  Bruno Haible  <bruno@clisp.org>
3268
3269         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
3270         * lib/ldexpl.c: Undo last change.
3271
3272 2007-04-03  Bruno Haible  <bruno@clisp.org>
3273
3274         * modules/printf-frexpl (Depends-on): Undo last change.
3275         (Files): Add m4/ldexpl.m4.
3276
3277 2007-04-03  Bruno Haible  <bruno@clisp.org>
3278
3279         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
3280         * modules/isnanl (Link): New section.
3281
3282         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
3283         * modules/frexp (Link): New section.
3284
3285         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
3286         * modules/frexpl (Link): New section.
3287
3288         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
3289         * modules/ldexpl (Link): New section.
3290
3291 2007-04-03  Bruno Haible  <bruno@clisp.org>
3292
3293         * modules/TEMPLATE-EXTENDED: New file.
3294         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
3295
3296 2007-04-03  Bruno Haible  <bruno@clisp.org>
3297
3298         * DEPENDENCIES: New file.
3299         Suggested by Simon Josefsson.
3300
3301 2007-04-03  Bruno Haible  <bruno@clisp.org>
3302
3303         * doc/gnulib.texi: Escape @.
3304
3305 2007-04-03  James Youngman  <jay@gnu.org>
3306         and Paul Eggert  <eggert@cs.ucla.edu>
3307
3308         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
3309         birthtime on all systems that have birthtime, not just those which
3310         use st_birthtimensec rather than st_birthtim.  Putting zero in
3311         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
3312         that the birth time is not available for files on an NFS mount.
3313
3314 2007-04-03  Simon Josefsson  <simon@josefsson.org>
3315
3316         * modules/memxor: Move back from crypto/, suggested by Bruno.
3317         * modules/crypto/hmac-sha1: Fix memxor dependency.
3318
3319         * modules/crypto/gc: Moved from ../.
3320
3321 2007-04-02  Eric Blake  <ebb9@byu.net>
3322
3323         * lib/ldexpl.c (includes): Avoid libm.
3324
3325         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
3326
3327 2007-04-02  Bruno Haible  <bruno@clisp.org>
3328
3329         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
3330         on IRIX.
3331
3332 2007-04-02  Bruno Haible  <bruno@clisp.org>
3333
3334         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
3335         x86 or x86_64 platforms running MacOS X.
3336         Reported by Ryan Schmidt <@ryandesign.com>.
3337
3338 2007-04-02  Bruno Haible  <bruno@clisp.org>
3339
3340         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
3341         i386.
3342
3343 2007-04-01  Simon Josefsson  <simon@josefsson.org>
3344
3345         * modules/crypto/arcfour: Moved from ../.
3346         * modules/crypto/arcfour-tests: Moved from ../.
3347         * modules/crypto/arctwo: Moved from ../.
3348         * modules/crypto/arctwo-tests: Moved from ../.
3349         * modules/crypto/des: Moved from ../.
3350         * modules/crypto/des-tests: Moved from ../.
3351         * modules/crypto/gc-arcfour: Moved from ../.
3352         * modules/crypto/gc-arcfour-tests: Moved from ../.
3353         * modules/crypto/gc-arctwo: Moved from ../.
3354         * modules/crypto/gc-arctwo-tests: Moved from ../.
3355         * modules/crypto/gc-des: Moved from ../.
3356         * modules/crypto/gc-des-tests: Moved from ../.
3357         * modules/crypto/gc-hmac-md5: Moved from ../.
3358         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
3359         * modules/crypto/gc-hmac-sha1: Moved from ../.
3360         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
3361         * modules/crypto/gc-md2: Moved from ../.
3362         * modules/crypto/gc-md2-tests: Moved from ../.
3363         * modules/crypto/gc-md4: Moved from ../.
3364         * modules/crypto/gc-md4-tests: Moved from ../.
3365         * modules/crypto/gc-md5: Moved from ../.
3366         * modules/crypto/gc-md5-tests: Moved from ../.
3367         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
3368         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
3369         * modules/crypto/gc-random: Moved from ../.
3370         * modules/crypto/gc-rijndael: Moved from ../.
3371         * modules/crypto/gc-rijndael-tests: Moved from ../.
3372         * modules/crypto/gc-sha1: Moved from ../.
3373         * modules/crypto/gc-sha1-tests: Moved from ../.
3374         * modules/crypto/gc-tests: Moved from ../.
3375         * modules/crypto/hmac-md5: Moved from ../.
3376         * modules/crypto/hmac-md5-tests: Moved from ../.
3377         * modules/crypto/hmac-sha1: Moved from ../.
3378         * modules/crypto/hmac-sha1-tests: Moved from ../.
3379         * modules/crypto/md2: Moved from ../.
3380         * modules/crypto/md2-tests: Moved from ../.
3381         * modules/crypto/md4: Moved from ../.
3382         * modules/crypto/md4-tests: Moved from ../.
3383         * modules/crypto/md5: Moved from ../.
3384         * modules/crypto/md5-tests: Moved from ../.
3385         * modules/crypto/memxor: Moved from ../.
3386         * modules/crypto/rijndael: Moved from ../.
3387         * modules/crypto/rijndael-tests: Moved from ../.
3388         * modules/crypto/sha1: Moved from ../.
3389
3390 2007-03-30  James Youngman  <jay@gnu.org>
3391
3392         * tests/test-stat-time.c (prepare_test): use chmod() rather than
3393         rename() to change the ctime of a file (because ctime is unaffected
3394         by rename on jfs2 on AIX 5.1).
3395         (main): Start by doing cleanup, in case a previous run failed leaving
3396         test files behind.
3397
3398 2007-03-31  Bruno Haible  <bruno@clisp.org>
3399
3400         Support old proprietary implementations of iconv.
3401         * modules/iconv_open: New file.
3402         * lib/iconv_.h: New file.
3403         * m4/iconv_h.m4: New file.
3404         * lib/iconv_open.c: New file.
3405         * lib/iconv_open-aix.gperf: New file.
3406         * lib/iconv_open-hpux.gperf: New file.
3407         * lib/iconv_open-irix.gperf: New file.
3408         * lib/iconv_open-osf.gperf: New file.
3409         * m4/iconv_open.m4: New file.
3410         * modules/linebreak (Depends-on): Add iconv_open.
3411         * modules/striconv (Depends-on): Likewise.
3412         * modules/striconveh (Depends-on): Likewise.
3413         * modules/unicodeio (Depends-on): Likewise.
3414         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
3415         (iconv_t)(-1).
3416         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
3417         conversion if cd is (iconv_t)(-1).
3418         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
3419         is not possible.
3420
3421 2007-03-31  Bruno Haible  <bruno@clisp.org>
3422
3423         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
3424         work on Solaris either. Protect also second use of "autodetect_jp".
3425
3426 2007-03-31  Bruno Haible  <bruno@clisp.org>
3427
3428         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
3429         the function is not present.
3430
3431 2007-03-31  Bruno Haible  <bruno@clisp.org>
3432
3433         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
3434         the function is not present.
3435
3436 2007-03-31  Bruno Haible  <bruno@clisp.org>
3437
3438         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
3439         a bug in HP-UX iconv_open().
3440
3441 2007-03-31  Bruno Haible  <bruno@clisp.org>
3442
3443         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
3444         (Mathematics <math.h>): New section, add fpieee.
3445         (Input/output <stdio.h>): Add fseterr.
3446         (Mathematics <math.h>): New section, add printf-frexp.
3447         (Container data structures): Add sublist.
3448         (Core language properties): Add fpucw, inline.
3449         (Functions for greatest-width integer types <inttypes.h>): Add
3450         imaxabs, imaxdiv, inttypes.
3451         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
3452         isnanl-nolibm, ldexp.
3453         (Mathematics <math.h>): New section, add printf-frexpl.
3454         (Support for systems lacking POSIX:2001): Add fprintf-posix,
3455         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
3456         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
3457         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
3458         (Unicode string functions): Add unistr/u*-mbtoucr.
3459         (Java): Add javacomp-script, javaexec-script.
3460         (C#): Add csharpcomp-script, csharpexec-script.
3461         (Support for building libraries and executables): Add havelib,
3462         relocatable-*.
3463         (Support for maintaining and releasing projects): Renamed from
3464         'Support for maintaining and release projects'. Add announce-gen.
3465
3466 2007-03-31  Bruno Haible  <bruno@clisp.org>
3467
3468         * README: Talk primarily about git.
3469         (git and CVS): Renamed from CVS.
3470         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
3471         gnulib is available through git.
3472         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
3473
3474 2007-03-30  Bruno Haible  <bruno@clisp.org>
3475
3476         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
3477         * lib/poll_.h: Likewise.
3478         * lib/stat_.h: Likewise.
3479         * lib/sys_time_.h: Likewise.
3480         * lib/sysexit_.h: Likewise.
3481         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
3482         * lib/stdbool_.h: Likewise.
3483         * lib/byteswap_.h: Add double-inclusion guard.
3484
3485 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
3486
3487         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
3488
3489 2007-03-30  Karl Berry  <karl@gnu.org>
3490
3491         * config/srclist-update: double space after USA in the license
3492         substitution, since that's how it's usually (?) written.
3493
3494 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
3495
3496         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
3497         reported by Bruno Haible.
3498
3499 2007-03-29  Bruno Haible  <bruno@clisp.org>
3500
3501         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
3502         a bug in AIX iconv().
3503
3504 2007-03-29  Bruno Haible  <bruno@clisp.org>
3505
3506         * modules/ldexpl-tests: New file.
3507         * tests/test-ldexpl.c: New file.
3508
3509 2007-03-29  Bruno Haible  <bruno@clisp.org>
3510
3511         * lib/ldexpl.c: Include fpucw.h.
3512         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
3513         multiplication.
3514         * modules/ldexpl (Depends-on): Add fpucw.
3515
3516 2007-03-29  Bruno Haible  <bruno@clisp.org>
3517
3518         * modules/ldexpl: New file.
3519         * m4/ldexpl.m4: New file.
3520         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
3521         set.
3522         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
3523         REPLACE_LDEXPL.
3524         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
3525         REPLACE_LDEXPL.
3526         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
3527         gl_FUNC_LDEXPL_WORKS.
3528         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
3529         * modules/mathl (Files): Remove lib/ldexpl.c.
3530         (Depends-on): Add ldexpl.
3531
3532 2007-03-29  Bruno Haible  <bruno@clisp.org>
3533
3534         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
3535
3536 2007-03-29  Bruno Haible  <bruno@clisp.org>
3537
3538         * tests/test-striconveh.c (main): Don't assume that a direct conversion
3539         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
3540         and possibly also HP-UX.
3541         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
3542         work on AIX, IRIX, HP-UX, OSF/1.
3543         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
3544         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
3545         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
3546         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
3547         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
3548         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
3549
3550 2007-03-29  Bruno Haible  <bruno@clisp.org>
3551
3552         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
3553
3554 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
3555
3556         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
3557         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
3558
3559 2007-03-29  Eric Blake  <ebb9@byu.net>
3560
3561         * lib/acl-internal.h: Remove redundant include.
3562         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
3563         Cygwin when a file is locked.
3564
3565 2007-03-29  Bruno Haible  <bruno@clisp.org>
3566
3567         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
3568         file.
3569         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
3570
3571 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
3572
3573         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
3574         try to remove a parent directory if the child couldn't be removed
3575         (except for the first rmdir, which could fail because the child
3576         doesn't exist).  Problem reported by Jeff Blaine in
3577         <http://lists.gnu.org/archive/html/bug-tar/2007-03/msg00014.html>.
3578
3579 2007-03-28  Bruno Haible  <bruno@clisp.org>
3580
3581         * lib/striconveh.c (utf8conv_carefully): New function.
3582         (mem_cd_iconveh_internal): Invoke it.
3583
3584 2007-03-28  Bruno Haible  <bruno@clisp.org>
3585
3586         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
3587         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
3588         input.
3589         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
3590         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
3591         unistr/u8-uctomb.
3592
3593 2007-03-28  Bruno Haible  <bruno@clisp.org>
3594
3595         * modules/unistr/u8-mbtoucr: New file.
3596         * lib/unistr/u8-mbtoucr.c: New file.
3597         * modules/unistr/u16-mbtoucr: New file.
3598         * lib/unistr/u16-mbtoucr.c: New file.
3599         * modules/unistr/u16-mbtoucr: New file.
3600         * lib/unistr/u16-mbtoucr.c: New file.
3601         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
3602
3603 2007-03-27  Simon Josefsson  <simon@josefsson.org>
3604             Bruno Haible  <bruno@clisp.org>
3605
3606         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
3607         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
3608         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
3609
3610         * m4/stdio_h.m4: Add stubs for vasprintf too.
3611
3612         * modules/stdio: Support vasprintf in sed command.
3613
3614         * modules/vasprintf: Depend on stdio for prototypes.  Remove
3615         vasprintf.h.  Add stdio module indicator.
3616
3617         * lib/stdio_.h: Declare asprintf and vasprintf, based on
3618         vasprintf.h.
3619
3620         * lib/vasprintf.h: File removed.
3621
3622         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
3623         * lib/vasprintf.c: Ditto.
3624         * lib/xvasprintf.c: Ditto.
3625         * tests/test-vasprintf-posix.c: Ditto.
3626         * tests/test-vasprintf.c: Ditto.
3627
3628 2007-03-27  Bruno Haible  <bruno@clisp.org>
3629
3630         Make vasnprintf multithread-safe.
3631         * lib/vasnprintf.c (decimal_point_char): New function.
3632         (VASNPRINTF): Use it.
3633         Suggested by Simon Josefsson.
3634
3635 2007-03-27  Eric Blake  <ebb9@byu.net>
3636
3637         Support sub-second birthtime on cygwin.
3638         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
3639         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
3640         (get_stat_birthtime): Also work with st_birthtim.
3641
3642 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
3643
3644         * lib/stat-time.h (USE_BIRTHTIME): Remove.
3645         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
3646         (get_stat_birthtime_ns): Do not try to use "spare" fields.
3647         (get_stat_birthtime_ns): Simplify compile-time tests.
3648         (get_stat_birthtime): Change the API to look like
3649         get_stat_mtime etc., except return a negative tv_nsec on error.
3650         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
3651         Don't check for "spare" fields.
3652         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
3653         or for struct stat.st_birthtime, as these tests aren't used.
3654         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
3655
3656 2007-03-27  Bruno Haible  <bruno@clisp.org>
3657
3658         * lib/stat-time.h: Include <sys/stat.h>.
3659
3660 2007-03-27  James Youngman  <jay@gnu.org>
3661
3662         * lib/stat-time.h (get_stat_birthtime): New function for
3663           retrieving st_birthtime as provided by UFS2 (hence *BSD).
3664         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
3665           and its variants.
3666         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
3667         * modules/stat-time-test: New file.
3668         * tests/test-stat-time.c: New test, devised by Bruno Haible.
3669
3670 2007-03-26  Bruno Haible  <bruno@clisp.org>
3671
3672         Better support of signalling NaNs.
3673         * lib/atanl.c: Include isnanl.h.
3674         (atanl): Perform test for NaN at the beginning of the function and
3675         through a call to isnanl.
3676         * lib/cosl.c: Include isnanl.h.
3677         (cosl): Perform test for NaN at the beginning of the function and
3678         through a call to isnanl.
3679         * lib/ldexpl.c: Include isnanl.h.
3680         (ldexpl): Perform test for NaN through a call to isnanl.
3681         * lib/logl.c: Include isnanl.h.
3682         (logl): Perform test for NaN at the beginning of the function and
3683         through a call to isnanl.
3684         * lib/sinl.c: Include isnanl.h.
3685         (sinl): Perform test for NaN at the beginning of the function and
3686         through a call to isnanl.
3687         * lib/sqrtl.c: Include isnanl.h.
3688         (sqrtl): Perform test for NaN at the beginning of the function and
3689         through a call to isnanl.
3690         * lib/tanl.c: Include isnanl.h.
3691         (tanl): Perform test for NaN at the beginning of the function and
3692         through a call to isnanl.
3693         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
3694         * modules/mathl (Depends-on): Add isnanl.
3695
3696 2007-03-26  Eric Blake  <ebb9@byu.net>
3697
3698         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
3699         regression in logic sense of previous patch.
3700
3701 2007-03-26  Bruno Haible  <bruno@clisp.org>
3702
3703         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
3704         unportable shell command "if ! ...".
3705         Reported by Ralf Wildenhues.
3706
3707 2007-03-25  Bruno Haible  <bruno@clisp.org>
3708
3709         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
3710         <sysexits.h> file, and only add EX_CONFIG.
3711         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
3712         absolute file name and whether it is sufficient. Substitute also
3713         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
3714         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
3715         ABSOLUTE_SYSEXITS_H into sysexits.h.
3716
3717 2007-03-25  Bruno Haible  <bruno@clisp.org>
3718
3719         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
3720         hints is NULL.
3721
3722 2007-03-25  Bruno Haible  <bruno@clisp.org>
3723
3724         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
3725         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
3726
3727 2007-03-25  Bruno Haible  <bruno@clisp.org>
3728
3729         * lib/vasnprintf.c: Include langinfo.h.
3730         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
3731         multithread-safe.
3732         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
3733         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
3734         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
3735         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
3736         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
3737         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
3738         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
3739         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
3740         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
3741         Reported by Simon Josefsson.
3742
3743 2007-03-25  Bruno Haible  <bruno@clisp.org>
3744
3745         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
3746         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
3747         * modules/vasnprintf (Depends-on): Add stdint.
3748
3749 2007-03-25  Bruno Haible  <bruno@clisp.org>
3750
3751         * modules/fpieee: New file.
3752         * m4/fpieee.m4: New file.
3753         * modules/isnan-nolibm (Depends-on): Add fpieee.
3754         * modules/isnanl-nolibm (Depends-on): Add fpieee.
3755         * modules/isnanl (Depends-on): Add fpieee.
3756
3757 2007-03-25  Bruno Haible  <bruno@clisp.org>
3758
3759         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
3760
3761 2007-03-25  Bruno Haible  <bruno@clisp.org>
3762
3763         Avoid test failures on IRIX 6.5.
3764         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
3765         (main): Use it.
3766         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
3767         macros.
3768         (main): Use them.
3769
3770 2007-03-25  Bruno Haible  <bruno@clisp.org>
3771
3772         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
3773         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
3774         exists but doesn't work.
3775         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
3776         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
3777         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
3778         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
3779
3780 2007-03-25  Bruno Haible  <bruno@clisp.org>
3781
3782         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
3783         returns inf. Needed on IRIX 6.5.
3784
3785 2007-03-25  Bruno Haible  <bruno@clisp.org>
3786
3787         * tests/test-frexpl.c: Include isnanl-nolibm.h.
3788         (main): Use isnanl instead of x != x idiom.
3789         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
3790
3791         * tests/test-frexp.c: Include isnan.h.
3792         (main): Use isnan instead of x != x idiom.
3793         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
3794
3795 2007-03-25  Bruno Haible  <bruno@clisp.org>
3796
3797         * tests/test-frexp.c (NaN): New function/macro.
3798         (main): Use it instead of 0.0 / 0.0.
3799         * tests/test-isnan.c (NaN): New function/macro.
3800         (main): Use it instead of 0.0 / 0.0.
3801         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
3802         (test_function): Use it instead of 0.0 / 0.0.
3803         * tests/test-vasprintf-posix.c (NaN): New function/macro.
3804         (test_function): Use it instead of 0.0 / 0.0.
3805         * tests/test-snprintf-posix.h (NaN): New function/macro.
3806         (test_function): Use it instead of 0.0 / 0.0.
3807         * tests/test-sprintf-posix.h (NaN): New function/macro.
3808         (test_function): Use it instead of 0.0 / 0.0.
3809         * tests/test-fprintf-posix.h (NaN): New function/macro.
3810         (test_function): Use it instead of 0.0 / 0.0.
3811         * tests/test-printf-posix.h (NaN): New function/macro.
3812         (test_function): Use it instead of 0.0 / 0.0.
3813
3814         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
3815
3816 2007-03-25  Bruno Haible  <bruno@clisp.org>
3817
3818         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
3819
3820 2007-03-25  Bruno Haible  <bruno@clisp.org>
3821
3822         * lib/regexec.c (merge_state_with_log): Make static.
3823
3824 2007-03-25  Bruno Haible  <bruno@clisp.org>
3825
3826         * lib/trigl.c (kernel_rem_pio2): Make static.
3827
3828 2007-03-25  Bruno Haible  <bruno@clisp.org>
3829
3830         * lib/sincosl.c (sincosl_table): Make static.
3831
3832 2007-03-25  Bruno Haible  <bruno@clisp.org>
3833
3834         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
3835         if the compiler does not support C99.
3836
3837 2007-03-25  Bruno Haible  <bruno@clisp.org>
3838
3839         * modules/time (Makefile.am): Ensure all rule action lines start with a
3840         tab.
3841
3842 2007-03-24  Bruno Haible  <bruno@clisp.org>
3843
3844         * modules/tsearch-tests: New file.
3845         * tests/test-tsearch.sh: New file.
3846         * tests/test-tsearch.c: New file, mostly copied from glibc.
3847
3848         * modules/search-tests: New file.
3849         * tests/test-search.c: New file.
3850
3851         * modules/search: New file.
3852         * lib/search_.h: New file, incorporating lib/tsearch.h.
3853         * m4/search_h.m4: New file.
3854         * lib/tsearch.h: Remove file.
3855         * lib/tsearch.c: Include search.h instead of tsearch.h.
3856         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
3857         HAVE_TSEARCH.
3858         * modules/tsearch (Files): Remove lib/tsearch.h.
3859         (Depends-on): Add search.
3860         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
3861         (Include): Change tsearch.h into search.h.
3862
3863 2007-03-24  Bruno Haible  <bruno@clisp.org>
3864
3865         * modules/fpucw: New file.
3866         * lib/fpucw.h: New file.
3867         * lib/frexp.c: Include fpucw.h.
3868         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
3869         (FUNC): Use them.
3870         * lib/printf-frexp.c: Include fpucw.h.
3871         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
3872         (FUNC): Use them.
3873         * lib/vasnprintf.c: Include fpucw.h.
3874         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
3875         'long double' calculations.
3876         * tests/test-frexpl.c: Include fpucw.h.
3877         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
3878         * tests/test-printf-frexpl.c: Include fpucw.h.
3879         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
3880         * modules/frexpl (Depends-on): Add fpucw.
3881         * modules/printf-frexpl (Depends-on): Likewise.
3882         * modules/fprintf-posix (Depends-on): Likewise.
3883         * modules/snprintf-posix (Depends-on): Likewise.
3884         * modules/sprintf-posix (Depends-on): Likewise.
3885         * modules/vasnprintf-posix (Depends-on): Likewise.
3886         * modules/vasprintf-posix (Depends-on): Likewise.
3887         * modules/vfprintf-posix (Depends-on): Likewise.
3888         * modules/vsnprintf-posix (Depends-on): Likewise.
3889         * modules/vsprintf-posix (Depends-on): Likewise.
3890         * modules/frexpl-tests (Depends-on): Likewise.
3891         * modules/printf-frexpl-tests (Depends-on): Likewise.
3892
3893 2007-03-24  Bruno Haible  <bruno@clisp.org>
3894
3895         * lib/float+.h: New file.
3896         * lib/isnan.c: Include float+.h.
3897         (SIZE): New macro.
3898         (FUNC): Compare only SIZE bytes of the value.
3899         * lib/vasnprintf.c: Include float+.h.
3900         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
3901         SIZEOF_LDBL or SIZEOF_DBL bytes.
3902         * modules/isnan-nolibm (Files): Add lib/float+.h.
3903         * modules/isnanl-nolibm (Files): Add lib/float+.h.
3904         * modules/isnanl (Files): Add lib/float+.h.
3905         * modules/vasnprintf (Files): Add lib/float+.h.
3906
3907 2007-03-24  Bruno Haible  <bruno@clisp.org>
3908
3909         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
3910         include isnanl-nolibm.h.
3911
3912 2007-03-24  Bruno Haible  <bruno@clisp.org>
3913
3914         * tests/test-read-file.c (main): Don't produce spurious output for
3915         expected situations. Make the test fail if it encountered unexpected
3916         results.
3917
3918 2007-03-24  Bruno Haible  <bruno@clisp.org>
3919
3920         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
3921         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
3922
3923 2007-03-24  Bruno Haible  <bruno@clisp.org>
3924
3925         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
3926
3927 2007-03-24  Bruno Haible  <bruno@clisp.org>
3928
3929         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
3930         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
3931
3932         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
3933         * modules/utf8-ucs4: Turn into a symbolic link to module
3934         unistr/u8-mbtouc.
3935
3936         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
3937         utf8-ucs4-unsafe.
3938         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
3939         unistr/u8-mbtouc-unsafe.
3940
3941         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
3942         * modules/utf16-ucs4: Turn into a symbolic link to module
3943         unistr/u16-mbtouc.
3944
3945         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
3946         utf16-ucs4-unsafe.
3947         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
3948         unistr/u16-mbtouc-unsafe.
3949
3950         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
3951         * modules/ucs4-utf8: Turn into a symbolic link to module
3952         unistr/u8-ubtomb.
3953
3954         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
3955         * modules/ucs4-utf16: Turn into a symbolic link to module
3956         unistr/u16-ubtomb.
3957
3958 2007-03-24  Bruno Haible  <bruno@clisp.org>
3959
3960         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
3961         Enable the function only if HAVE_INLINE.
3962         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
3963         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
3964         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
3965         Enable the function only if HAVE_INLINE.
3966         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
3967         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
3968         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
3969         Enable the function only if HAVE_INLINE.
3970         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
3971         Enable the function only if HAVE_INLINE.
3972         * modules/utf8-ucs4: Update.
3973         * modules/utf8-ucs4-unsafe: Update.
3974         * modules/utf16-ucs4: Update.
3975         * modules/utf16-ucs4-unsafe: Update.
3976         * modules/ucs4-utf8: Update.
3977         * modules/ucs4-utf16: Update.
3978
3979 2007-03-24  Bruno Haible  <bruno@clisp.org>
3980
3981         * lib/utf8-ucs4.h: Remove file.
3982         * lib/utf8-ucs4-unsafe.h: Remove file.
3983         * lib/utf16-ucs4.h: Remove file.
3984         * lib/utf16-ucs4-unsafe.h: Remove file.
3985         * lib/ucs4-utf8.h: Remove file.
3986         * lib/ucs4-utf16.h: Remove file.
3987         * lib/unistr.h: Include their previous contents.
3988         * m4/utf-ucs4.m4: Remove file.
3989         * m4/ucs4-utf.m4: Remove file.
3990         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
3991         (Depends-on): Add unistr/base.
3992         (configure.ac): Remove gl_UTF_UCS4.
3993         (Makefile.am): Update.
3994         (Include): Change to unistr.h.
3995         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
3996         (Depends-on): Add unistr/base.
3997         (configure.ac): Remove gl_UTF_UCS4.
3998         (Makefile.am): Update.
3999         (Include): Change to unistr.h.
4000         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
4001         (Depends-on): Add unistr/base.
4002         (configure.ac): Remove gl_UTF_UCS4.
4003         (Makefile.am): Update.
4004         (Include): Change to unistr.h.
4005         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
4006         (Depends-on): Add unistr/base.
4007         (configure.ac): Remove gl_UTF_UCS4.
4008         (Makefile.am): Update.
4009         (Include): Change to unistr.h.
4010         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
4011         (Depends-on): Add unistr/base.
4012         (configure.ac): Remove gl_UCS4_UTF.
4013         (Makefile.am): Update.
4014         (Include): Change to unistr.h.
4015         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
4016         (Depends-on): Add unistr/base.
4017         (configure.ac): Remove gl_UCS4_UTF.
4018         (Makefile.am): Update.
4019         (Include): Change to unistr.h.
4020         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
4021         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
4022         utf8-ucs4-unsafe.h.
4023         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
4024         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
4025         utf16-ucs4-unsafe.h.
4026         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
4027         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
4028         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
4029         * lib/unistr/u8-strchr.c: Likewise.
4030         * lib/unistr/u8-strrchr.c: Likewise.
4031         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
4032         * lib/unistr/u16-strchr.c: Likewise.
4033         * lib/unistr/u16-strrchr.c: Likewise.
4034         * lib/striconveh.c: Update.
4035         * lib/linebreak.c: Update.
4036
4037 2007-03-24  Bruno Haible  <bruno@clisp.org>
4038
4039         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
4040         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
4041
4042 2007-03-22  Bruno Haible  <bruno@clisp.org>
4043
4044         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
4045
4046 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
4047
4048         * MODULES.html.sh (File system functions): New module write-any-file.
4049         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
4050         * m4/write-any-file.m4: New files.
4051
4052 2007-03-23  Eric Blake  <ebb9@byu.net>
4053
4054         * gnulib-tool: Rearrange space-tab sequences, since some editors
4055         like to eat them.
4056
4057 2007-03-23  Eric Blake  <ebb9@byu.net>
4058
4059         * lib/version-etc.c (version_etc_va): Update license wording to
4060         be more concise.  Recommended by Richard Stallman.
4061
4062 2007-03-22  Bruno Haible  <bruno@clisp.org>
4063
4064         * lib/poll.c (MSG_PEEK): New fallback definition.
4065
4066 2007-03-22  Bruno Haible  <bruno@clisp.org>
4067
4068         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
4069         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
4070         (main): Update.
4071         Fixes a compilation error on BeOS.
4072
4073 2007-03-22  Bruno Haible  <bruno@clisp.org>
4074
4075         * modules/frexpl-tests: New file.
4076         * tests/test-frexpl.c: New file.
4077
4078         * modules/frexpl: New file.
4079         * m4/frexpl.m4: New file.
4080         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
4081         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
4082         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
4083         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
4084         (Depends-on): Add frexpl. Remove isnanl-nolibm.
4085         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
4086
4087 2007-03-22  Bruno Haible  <bruno@clisp.org>
4088
4089         * lib/frexpl.c: Share code with lib/frexp.c.
4090         * modules/mathl (Files): Add lib/frexp.c.
4091         (Depends-on): Add isnanl-nolibm.
4092
4093 2007-03-22  Bruno Haible  <bruno@clisp.org>
4094
4095         * modules/printf-frexp (Files): Add m4/frexp.m4.
4096         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
4097         only if the found frexp function actually works.
4098
4099 2007-03-22  Bruno Haible  <bruno@clisp.org>
4100
4101         * lib/frexp.c: Remove older implementation that uses divisions.
4102
4103 2007-03-21  Bruno Haible  <bruno@clisp.org>
4104
4105         * modules/frexp-tests: New file.
4106         * tests/test-frexp.c: New file.
4107
4108         * modules/frexp: New file.
4109         * lib/frexp.c: New file.
4110         * m4/frexp.m4: New file.
4111         * lib/math_.h (frexp): New declaration.
4112         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
4113         REPLACE_FREXP.
4114         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
4115
4116 2007-03-21  Bruno Haible  <bruno@clisp.org>
4117
4118         * modules/isnanl-tests: New file.
4119         * tests/test-isnanl.c: New file.
4120
4121         * modules/isnanl: New file.
4122         * lib/isnanl.h: New file.
4123         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
4124         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
4125         gl_FUNC_ISNANL_WORKS.
4126         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
4127         New macros.
4128
4129 2007-03-21  Bruno Haible  <bruno@clisp.org>
4130
4131         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
4132         lib/isnanl.h.
4133         (Include): Update.
4134         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
4135         * lib/vasnprintf.c: Update.
4136         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
4137         tests/test-isnanl.h, remove tests/test-isnanl.c.
4138         (Makefile.am): Update.
4139         * tests/test-isnanl-nolibm.c: New file.
4140         * tests/test-isnanl.h: New file.
4141         * tests/test-isnanl.c: Remove file.
4142
4143 2007-03-21  Jim Meyering  <jim@meyering.net>
4144
4145         When trying to open ".", treat ESTALE like EACCES.
4146         * lib/savewd.c (savewd_save): Resort to forking not just upon
4147         failure with EACCES, but also when errno is ESTALE.
4148
4149 2007-03-20  Bruno Haible  <bruno@clisp.org>
4150
4151         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
4152         Needed on AIX 5.1. Reported by Matthew Woehlke.
4153
4154 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
4155
4156         Suggestions by Bruno Haible:
4157         * lib/acl-internal.h: Include "gettext.h" rather than rolling
4158         our own.
4159         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
4160         * modules/acl (Depends-on): Add gettext.
4161
4162 2007-03-19  Bruno Haible  <bruno@clisp.org>
4163
4164         * modules/iconvme: Remove file.
4165         * lib/iconvme.h: Remove file.
4166         * lib/iconvme.c: Remove file.
4167         * m4/iconvme.m4: Remove file.
4168
4169 2007-03-19  Bruno Haible  <bruno@clisp.org>
4170
4171         * doc/relocatable-maint.texi: Break long shell script line.
4172         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
4173
4174 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
4175
4176         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
4177         handle file_has_acl.
4178         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
4179         * lib/acl.c: Move header inclusions and related macro defns into
4180         lib/acl-internal.h.
4181         (S_ISLNK): Remove defn, since that's now done for us.
4182         (file_has_acl): Move to lib/file-has-acl.c.
4183         Call acl_trivial if available.  This is the crucial part of the fix.
4184         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
4185         shared within the library.  Rewrite a bit, partly to make it compatible
4186         with the GNU coding style.
4187         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
4188         Remove unnecessary double-quotes.
4189         Don't test for acl_to_text; the build will catch that.
4190         Replace acl_entries if it doesn't exist and it is needed.
4191         Check for -lsec and acl_trivial (as used on Solaris 10).
4192         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
4193         lib/file-has-acl.c.
4194         (Depends-on): Add sys_stat, for S_ISLNK.
4195
4196 2007-03-19  Ben Pfaff  <blp@gnu.org>
4197
4198         * doc/gnulib.texi: Fix typos.
4199         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
4200
4201 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
4202
4203         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
4204         If size is zero here, buf must be zero.
4205
4206 2007-03-19  Simon Josefsson  <simon@josefsson.org>
4207
4208         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
4209         <bruno@clisp.org>.
4210
4211 2007-03-18  Bruno Haible  <bruno@clisp.org>
4212
4213         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
4214         Suggested by Eric Blake.
4215
4216 2007-03-18  Ben Pfaff  <blp@gnu.org>
4217
4218         * doc/relocatable.texi: Recommend using as prefix a directory
4219         that does not exist and will never be created.  Based on
4220         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
4221         and others.
4222
4223 2007-03-17  Bruno Haible  <bruno@clisp.org>
4224
4225         * lib/fchownat.c: Include lchown.h.
4226
4227 2007-03-17  Bruno Haible  <bruno@clisp.org>
4228
4229         Fix endless loop when the given allocated size was > INT_MAX.
4230         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
4231         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
4232         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
4233         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
4234         * lib/sprintf.c (sprintf): Likewise.
4235
4236 2007-03-17  Bruno Haible  <bruno@clisp.org>
4237
4238         * tests/test-argp-2.sh (func_compare): Output a context diff.
4239
4240 2007-03-17  Bruno Haible  <bruno@clisp.org>
4241
4242         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
4243         locale's decimal-point character.
4244
4245 2007-03-17  Bruno Haible  <bruno@clisp.org>
4246
4247         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
4248         before comparing it. Needed because on some platforms (e.g. x86) a
4249         'long double' occupies less bytes than sizeof (long double).
4250
4251 2007-03-17  Bruno Haible  <bruno@clisp.org>
4252
4253         * tests/test-crc.c (main): Make printf statements 64-bit clean.
4254         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
4255         * tests/test-getaddrinfo.c (simple): Likewise.
4256         * tests/test-read-file.c (main): Likewise.
4257
4258 2007-03-17  Bruno Haible  <bruno@clisp.org>
4259
4260         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
4261
4262 2007-03-17  Bruno Haible  <bruno@clisp.org>
4263
4264         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
4265         unused variable.
4266
4267 2007-03-17  Bruno Haible  <bruno@clisp.org>
4268
4269         * tests/test-c-strcasecmp.c: Include c-strcase.h.
4270         * tests/test-c-strncasecmp.c: Likewise.
4271
4272 2007-03-17  Bruno Haible  <bruno@clisp.org>
4273
4274         * modules/stdlib (Depends-on): Add unistd.
4275         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
4276         Needed for MacOS X 10.3.
4277
4278 2007-03-17  Bruno Haible  <bruno@clisp.org>
4279
4280         * lib/unistr/u-strdup.h: Include <stdlib.h>.
4281
4282 2007-03-17  Bruno Haible  <bruno@clisp.org>
4283
4284         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
4285
4286 2007-03-17  Bruno Haible  <bruno@clisp.org>
4287
4288         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
4289         to reflect files copied from gnulib (with or without modifications).
4290         Suggested by Jim Meyering.
4291
4292 2007-03-17  Eric Blake  <ebb9@byu.net>
4293
4294         * NEWS: Document stdlib change from 2007-02-18.
4295
4296 2007-03-17  Jim Meyering  <jim@meyering.net>
4297
4298         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
4299         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
4300         someone uses a name containing shell meta-characters.
4301         Reported by Alfred M. Szmidt.
4302
4303         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
4304
4305 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
4306
4307         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
4308         and copy gettext configuration files only if configure.ac contains
4309         a use of AM_GNU_GETTEXT_VERSION.
4310
4311 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
4312
4313         * build-aux/bootstrap (gnulib_name): New variable.
4314         (gnulib_tool_options): Use it.
4315
4316 2007-03-13  Simon Josefsson  <simon@josefsson.org>
4317
4318         * tests/test-des.c: Use new namespace.
4319
4320 2007-03-15  Bruno Haible  <bruno@clisp.org>
4321
4322         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
4323         Reported by James Youngman <jay@gnu.org>.
4324
4325 2007-03-15  Bruno Haible  <bruno@clisp.org>
4326
4327         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
4328         declared prototype. Needed with cc on OSF/1 5.1.
4329
4330 2007-03-15  Bruno Haible  <bruno@clisp.org>
4331
4332         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
4333         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
4334         (struct gl_list_implementation): Add dispose_fn argument to the
4335         'create_empty', 'create' methods.
4336         (struct gl_list_impl_base): Add field 'dispose_fn'.
4337         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
4338         argument.
4339         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
4340         dispose_fn argument.
4341         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
4342         dispose_fn on the dropped values.
4343         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
4344         dispose_fn argument.
4345         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
4346         dropped values.
4347         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
4348         (gl_tree_remove_node): Call dispose_fn on the dropped value.
4349         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
4350         (gl_tree_remove_node): Call dispose_fn on the dropped value.
4351         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
4352         argument.
4353         (gl_tree_list_free): Call dispose_fn on the dropped values.
4354         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
4355         the dropped values.
4356         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
4357         Add dispose_fn argument.
4358         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
4359         Call dispose_fn on the dropped values.
4360         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
4361         Add dispose_fn argument.
4362         (gl_sublist_create): Initialize the 'dispose_fn' field.
4363         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
4364         * tests/test-array_list.c (main): Update.
4365         * tests/test-carray_list.c (main): Update.
4366         * tests/test-avltree_list.c (main): Update.
4367         * tests/test-rbtree_list.c (main): Update.
4368         * tests/test-avltreehash_list.c (main): Update.
4369         * tests/test-rbtreehash_list.c (main): Update.
4370         * tests/test-linked_list.c (main): Update.
4371         * tests/test-linkedhash_list.c (main): Update.
4372         * tests/test-array_oset.c (main): Update.
4373
4374 2007-03-15  Bruno Haible  <bruno@clisp.org>
4375
4376         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
4377         (gl_oset_create_empty): Add dispose_fn argument.
4378         (struct gl_oset_implementation): Add dispose_fn argument to
4379         'create_empty' method.
4380         (struct gl_oset_impl_base): Add dispose_fn field.
4381         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
4382         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
4383         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
4384         values.
4385         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
4386         (gl_tree_oset_free): Call dispose_fn on the dropped values.
4387         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
4388         dropped value.
4389         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
4390         dropped value.
4391         * tests/test-array_oset.c (main): Update.
4392         * tests/test-avltree_oset.c (main): Update.
4393         * tests/test-rbtree_oset.c (main): Update.
4394         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
4395
4396 2007-03-13  Bruno Haible  <bruno@clisp.org>
4397
4398         * tests/test-stdbool.c (i): Update after last patch.
4399
4400 2007-03-12  Bruno Haible  <bruno@clisp.org>
4401
4402         * lib/quotearg.c: Include <wctype.h> early, before the definition of
4403         the iswprint macro. Needed on Solaris 2.5.1.
4404
4405 2007-03-12  Bruno Haible  <bruno@clisp.org>
4406
4407         * tests/test-printf-frexp.c (main): Declare x as volatile.
4408
4409 2007-03-12  Simon Josefsson  <simon@josefsson.org>
4410
4411         * doc/gnulib.texi (Build robot for gnulib): New section.
4412
4413 2007-03-12  Jim Meyering  <jim@meyering.net>
4414
4415         * build-aux/bootstrap: New file.
4416         * build-aux/bootstrap.conf: New file, from coreutils.
4417
4418 2007-03-11  Bruno Haible  <bruno@clisp.org>
4419
4420         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
4421
4422 2007-03-12  Simon Josefsson  <simon@josefsson.org>
4423
4424         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
4425         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
4426         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
4427
4428 2007-03-11  Bruno Haible  <bruno@clisp.org>
4429
4430         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
4431         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
4432
4433 2007-03-11  Bruno Haible  <bruno@clisp.org>
4434
4435         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
4436         formula. Needed for SunPRO C 5.0.
4437
4438 2007-03-11  Bruno Haible  <bruno@clisp.org>
4439
4440         * modules/long-options (Depends-on): Add getopt.
4441
4442 2007-03-11  Bruno Haible  <bruno@clisp.org>
4443
4444         * modules/modechange (Depends-on): Add stdbool.
4445
4446 2007-03-11  Bruno Haible  <bruno@clisp.org>
4447
4448         * modules/i-ring (Depends-on): Add stdbool.
4449
4450 2007-03-11  Bruno Haible  <bruno@clisp.org>
4451
4452         * modules/gc-des (Depends-on): Add stdbool.
4453
4454 2007-03-11  Bruno Haible  <bruno@clisp.org>
4455
4456         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
4457
4458 2007-03-11  Bruno Haible  <bruno@clisp.org>
4459
4460         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
4461
4462 2007-03-11  Bruno Haible  <bruno@clisp.org>
4463
4464         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
4465
4466 2007-03-11  Bruno Haible  <bruno@clisp.org>
4467
4468         * lib/vasnprintf.c (sprintf): Undefine.
4469
4470 2007-03-11  Bruno Haible  <bruno@clisp.org>
4471
4472         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
4473         initializers in SunPRO C and Compaq C compilers.
4474
4475 2007-03-11  Bruno Haible  <bruno@clisp.org>
4476
4477         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
4478         decrementing code ANSI C compliant.
4479
4480 2007-03-11  Bruno Haible  <bruno@clisp.org>
4481
4482         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
4483         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
4484
4485 2007-03-11  Bruno Haible  <bruno@clisp.org>
4486
4487         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
4488         <stdbool.h> substitute doesn't pass.
4489
4490 2007-03-11  Bruno Haible  <bruno@clisp.org>
4491
4492         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
4493
4494 2007-03-11  Bruno Haible  <bruno@clisp.org>
4495
4496         * gnulib-tool (func_create_megatestdir): Create also an autobuild
4497         script, for submission to autobuild.josefsson.org.
4498
4499 2007-03-10  Bruno Haible  <bruno@clisp.org>
4500
4501         * modules/canonicalize-lgpl-tests: New file.
4502         * tests/test-canonicalize-lgpl.sh: New file.
4503         * tests/test-canonicalize-lgpl.c: New file.
4504
4505         * modules/c-strcase-tests: New file.
4506         * tests/test-c-strcase.sh: New file.
4507         * tests/test-c-strcasecmp.c: New file.
4508         * tests/test-c-strncasecmp.c: New file.
4509
4510         * modules/atexit-tests: New file.
4511         * tests/test-atexit.sh: New file.
4512         * tests/test-atexit.c: New file.
4513
4514 2007-03-10  Bruno Haible  <bruno@clisp.org>
4515
4516         * tests/test-binary-io.sh: Use temporary filenames that are not so
4517         likely to clash with those of other tests (in a parallel make).
4518         * tests/test-binary-io.c: Likewise.
4519
4520 2007-03-10  Bruno Haible  <bruno@clisp.org>
4521
4522         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
4523         fallback; use #error instead.
4524         Suggested by Simon Josefsson.
4525
4526 2007-03-10  Bruno Haible  <bruno@clisp.org>
4527
4528         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
4529         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
4530         first and the last.
4531
4532 2007-03-10  Bruno Haible  <bruno@clisp.org>
4533
4534         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
4535
4536 2007-03-10  Bruno Haible  <bruno@clisp.org>
4537
4538         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
4539         "make distcheck".
4540         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
4541         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
4542         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
4543
4544 2007-03-10  Bruno Haible  <bruno@clisp.org>
4545
4546         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
4547         variable.
4548         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
4549         variable.
4550
4551 2007-03-09  Eric Blake  <ebb9@byu.net>
4552         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
4553
4554         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
4555         types are not being provided by gnulib.
4556         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
4557         types are supported.
4558
4559 2007-03-10  Bruno Haible  <bruno@clisp.org>
4560
4561         * lib/stdio_.h (__attribute__): New macro.
4562         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
4563         vsprintf): Specify __attribute__ __format__ for GCC.
4564         Suggested by Eric Blake.
4565
4566 2007-03-09  Bruno Haible  <bruno@clisp.org>
4567
4568         * modules/printf-posix-tests: New file.
4569         * tests/test-printf-posix.sh: New file.
4570         * tests/test-printf-posix.c: New file.
4571
4572         * modules/printf-posix: New file.
4573         * lib/printf.c: New file.
4574         * m4/printf-posix-rpl.m4: New file.
4575         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
4576         REPLACE_PRINTF.
4577         * lib/stdio_.h (printf): New declaration.
4578         (format, __format__, ____printf____, ____scanf____, ____strftime____,
4579         ____strfmon____): New macros.
4580         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
4581         REPLACE_PRINTF.
4582
4583 2007-03-09  Bruno Haible  <bruno@clisp.org>
4584
4585         * tests/test-vasnprintf-posix2.sh: New file.
4586         * tests/test-vasnprintf-posix2.c: New file.
4587         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
4588         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
4589         (Makefile.am): Activate test-vasnprintf-posix2.sh.
4590
4591         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
4592         a locale dependent decimal point, rather than always '.'.
4593
4594 2007-03-09  Eric Blake  <ebb9@byu.net>
4595
4596         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
4597         spite of platforms like Tandem/NSK that define it to -1.
4598
4599 2007-03-08  Bruno Haible  <bruno@clisp.org>
4600
4601         * modules/vprintf-posix-tests: New file.
4602         * tests/test-vprintf-posix.sh: New file.
4603         * tests/test-vprintf-posix.c: New file.
4604         * tests/test-printf-posix.h: New file.
4605
4606         * modules/vprintf-posix: New file.
4607         * lib/vprintf.c: New file.
4608         * m4/vprintf-posix.m4: New file.
4609         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
4610         REPLACE_VPRINTF.
4611         * lib/stdio_.h (vprintf): New declaration.
4612         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
4613         REPLACE_VPRINTF.
4614
4615 2007-03-08  Bruno Haible  <bruno@clisp.org>
4616
4617         * modules/fprintf-posix-tests: New file.
4618         * tests/test-fprintf-posix.sh: New file.
4619         * tests/test-fprintf-posix.c: New file.
4620
4621         * modules/fprintf-posix: New file.
4622         * lib/fprintf.c: New file.
4623         * m4/fprintf-posix.m4: New file.
4624         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
4625         REPLACE_FPRINTF.
4626         * lib/stdio_.h (fprintf): New declaration.
4627         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
4628         REPLACE_FPRINTF.
4629
4630 2007-03-08  Bruno Haible  <bruno@clisp.org>
4631
4632         * modules/vfprintf-posix-tests: New file.
4633         * tests/test-vfprintf-posix.sh: New file.
4634         * tests/test-vfprintf-posix.c: New file.
4635         * tests/test-fprintf-posix.h: New file.
4636         * tests/test-fprintf-posix.out: New file.
4637
4638         * modules/vfprintf-posix: New file.
4639         * lib/vfprintf.c: New file.
4640         * m4/vfprintf-posix.m4: New file.
4641         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
4642         REPLACE_VFPRINTF.
4643         * lib/stdio_.h (vfprintf): New declaration.
4644         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
4645         REPLACE_VFPRINTF.
4646
4647 2007-03-08  Bruno Haible  <bruno@clisp.org>
4648
4649         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
4650
4651 2007-03-08  Bruno Haible  <bruno@clisp.org>
4652
4653         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
4654         instead of 'expr' invocations.
4655         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
4656         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
4657         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
4658         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
4659         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
4660         Suggested by Paul Eggert.
4661
4662 2007-03-08  Bruno Haible  <bruno@clisp.org>
4663
4664         * modules/fseterr-tests: New file.
4665         * tests/test-fseterr.c: New file.
4666
4667         * modules/fseterr: New file.
4668         * lib/fseterr.h: New file.
4669         * lib/fseterr.c: New file.
4670
4671 2007-03-08  Bruno Haible  <bruno@clisp.org>
4672
4673         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
4674         * lib/getopt_.h: Likewise.
4675         * lib/mbswidth.h: Likewise.
4676         * lib/setenv.h: Likewise.
4677         * lib/vasnprintf.h: Likewise.
4678         * lib/vasprintf.h: Likewise.
4679         * lib/verror.h: Likewise.
4680         * lib/xsetenv.h: Likewise.
4681         * lib/xvasprintf.h: Likewise.
4682
4683 2007-03-08  Jim Meyering  <jim@meyering.net>
4684
4685         * users.txt: Add parted.
4686
4687         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
4688
4689 2007-03-07  Bruno Haible  <bruno@clisp.org>
4690
4691         * m4/printf.m4: Make the shell script snippets copy&pastable.
4692
4693 2007-03-02  Bruno Haible  <bruno@clisp.org>
4694
4695         * lib/netinet_in_.h: New file.
4696         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
4697         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
4698         * modules/netinet_in (Files): Add lib/netinet_in_.h.
4699         (Depends-on): Add absolute-header.
4700         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
4701         into netinet/in.h.
4702
4703 2007-03-03  Bruno Haible  <bruno@clisp.org>
4704
4705         * lib/sys_select_.h: New file.
4706         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
4707         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
4708         * modules/sys_select (Files): Add lib/sys_select_.h.
4709         (Depends-on): Add absolute-header.
4710         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
4711         into sys/select.h.
4712
4713 2007-03-02  Bruno Haible  <bruno@clisp.org>
4714
4715         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
4716         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
4717         values.
4718         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
4719         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
4720         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
4721         * modules/sys_socket (Depends-on): Add absolute-header.
4722         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
4723         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
4724         (Include): Remove requirement of inclusion of <sys/types.h>.
4725
4726 2007-03-02  Bruno Haible  <bruno@clisp.org>
4727
4728         * lib/byteswap_.h (bswap_32): Fix formula.
4729
4730 2007-03-06  Bruno Haible  <bruno@clisp.org>
4731
4732         * modules/sprintf-posix-tests: New file.
4733         * tests/test-sprintf-posix.c: New file.
4734
4735         * modules/sprintf-posix: New file.
4736         * lib/sprintf.c: New file.
4737         * m4/sprintf-posix.m4: New file.
4738         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
4739         REPLACE_SPRINTF.
4740         * lib/stdio_.h (sprintf): New declaration.
4741         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
4742         REPLACE_SPRINTF.
4743
4744 2007-03-06  Bruno Haible  <bruno@clisp.org>
4745
4746         * modules/vsprintf-posix-tests: New file.
4747         * tests/test-vsprintf-posix.c: New file.
4748         * tests/test-sprintf-posix.h: New file.
4749
4750         * modules/vsprintf-posix: New file.
4751         * lib/vsprintf.c: New file.
4752         * m4/vsprintf-posix.m4: New file.
4753         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
4754         REPLACE_VSPRINTF.
4755         * lib/stdio_.h (vsprintf): New declaration.
4756         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
4757         REPLACE_VSPRINTF.
4758
4759 2007-03-06  Bruno Haible  <bruno@clisp.org>
4760
4761         * modules/vsnprintf (Depend-on): Remove minmax.
4762
4763 2007-03-06  Bruno Haible  <bruno@clisp.org>
4764
4765         * modules/snprintf-posix-tests: New file.
4766         * tests/test-snprintf-posix.c: New file.
4767
4768         * modules/snprintf-posix: New file.
4769         * m4/snprintf-posix.m4: New file.
4770         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
4771         gl_FUNC_SNPRINTF.
4772         (gl_FUNC_SNPRINTF): Invoke it.
4773         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
4774         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
4775         is set.
4776         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
4777
4778 2007-03-06  Bruno Haible  <bruno@clisp.org>
4779
4780         * modules/vsnprintf-posix-tests: New file.
4781         * tests/test-vsnprintf-posix.c: New file.
4782         * tests/test-snprintf-posix.h: New file.
4783
4784         * modules/vsnprintf-posix: New file.
4785         * m4/vsnprintf-posix.m4: New file.
4786         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
4787         gl_FUNC_VSNPRINTF.
4788         (gl_FUNC_VSNPRINTF): Invoke it.
4789         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
4790         * lib/stdio_.h (vsnprintf): Define as a replacement if
4791         REPLACE_VSNPRINTF is set.
4792         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
4793
4794 2007-03-06  Bruno Haible  <bruno@clisp.org>
4795
4796         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
4797         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
4798
4799 2007-03-06  Bruno Haible  <bruno@clisp.org>
4800
4801         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
4802         (asinl): Declare also if HAVE_DECL_ASINL is set.
4803         (atanl): Declare also if HAVE_DECL_ATANL is set.
4804         (ceill): Declare also if HAVE_DECL_CEILL is set.
4805         (cosl): Declare also if HAVE_DECL_COSL is set.
4806         (expl): Declare also if HAVE_DECL_EXPL is set.
4807         (floorl): Declare also if HAVE_DECL_FLOORL is set.
4808         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
4809         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
4810         (logl): Declare also if HAVE_DECL_LOGL is set.
4811         (sinl): Declare also if HAVE_DECL_SINL is set.
4812         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
4813         (tanl): Declare also if HAVE_DECL_TANL is set.
4814         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
4815         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
4816         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
4817         declaration of frexpl, ldexpl.
4818         * modules/printf-frexpl (Depends-on): Add math.
4819         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
4820
4821 2007-03-05  Bruno Haible  <bruno@clisp.org>
4822
4823         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
4824         frexpl and ldexpl are declared.
4825         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
4826
4827 2007-03-05  Bruno Haible  <bruno@clisp.org>
4828
4829         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
4830         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
4831
4832 2007-03-05  Bruno Haible  <bruno@clisp.org>
4833
4834         * lib/stdio_.h: Include <stddef.h>.
4835
4836 2007-03-05  Bruno Haible  <bruno@clisp.org>
4837
4838         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
4839
4840 2007-03-05  Bruno Haible  <bruno@clisp.org>
4841
4842         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
4843         NetBSD 4, from Ralf Wildenhues.
4844
4845 2007-03-04  Bruno Haible  <bruno@clisp.org>
4846
4847         * lib/vasprintf.h: Update #if logic for the case when the functions
4848         exist but are overridden.
4849
4850 2007-03-04  Bruno Haible  <bruno@clisp.org>
4851
4852         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
4853         implementations: glibc-2.4 and MacOS X 10.3.
4854         * tests/test-vasnprintf-posix.c (test_function): Test also the case
4855         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
4856         * tests/test-vasprintf-posix.c (test_function): Likewise.
4857
4858 2007-03-04  Bruno Haible  <bruno@clisp.org>
4859
4860         * modules/vasprintf-posix-tests: New file.
4861         * tests/test-vasprintf-posix.c: New file.
4862
4863         * modules/vasprintf-posix: New file.
4864         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
4865         defined.
4866         * m4/vasprintf-posix.m4: New file.
4867         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
4868         gl_FUNC_VASPRINTF.
4869         (gl_FUNC_VASPRINTF): Invoke it.
4870         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
4871         here.
4872         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
4873
4874 2007-03-04  Bruno Haible  <bruno@clisp.org>
4875
4876         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
4877         REPLACE_GETTIMEOFDAY.
4878         * modules/sys_time (Makefile.am): Likewise.
4879         * m4/sys_time_h.m4: Likewise.
4880         * m4/gettimeofday.m4: Likewise.
4881
4882 2007-03-04  Bruno Haible  <bruno@clisp.org>
4883
4884         * modules/vasnprintf-posix-tests: New file.
4885         * tests/test-vasnprintf-posix.c: New file.
4886
4887         * modules/vasnprintf-posix: New file.
4888         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
4889         printf-frexpl.h.
4890         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
4891         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
4892         REPLACE_VASNPRINTF is defined.
4893         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
4894         gl_FUNC_VASNPRINTF.
4895         (gl_FUNC_VASNPRINTF): Invoke it.
4896         * m4/vasnprintf-posix.m4: New file.
4897         * m4/printf.m4: New file.
4898
4899 2007-03-04  Bruno Haible  <bruno@clisp.org>
4900
4901         Compile progreloc.c only if --enable-relocatable is specified.
4902         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
4903         if --enable-relocatable was specified.
4904         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
4905         lib_SOURCES.
4906
4907 2007-03-04  Jim Meyering  <jim@meyering.net>
4908
4909         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
4910         Use it consistently, rather than enumerating errno constants.
4911
4912 2007-03-04  Bruno Haible  <bruno@clisp.org>
4913
4914         * modules/xvasprintf-tests: New file.
4915         * tests/test-xvasprintf.c: New file.
4916
4917         * modules/vasprintf-tests: New file.
4918         * tests/test-vasprintf.c: New file.
4919
4920         * modules/vasnprintf-tests: New file.
4921         * tests/test-vasnprintf.c: New file.
4922
4923         * modules/vsnprintf-tests: New file.
4924         * tests/test-vsnprintf.c: New file.
4925
4926         * modules/snprintf-tests: New file.
4927         * tests/test-snprintf.c: New file.
4928
4929 2007-03-04  Bruno Haible  <bruno@clisp.org>
4930
4931         Compile relocatable.c only if --enable-relocatable is specified.
4932         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
4933         gl_RELOCATABLE_LIBRARY.
4934         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
4935         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
4936         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
4937         gl_RELOCATABLE_LIBRARY.
4938         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
4939         (Makefile.am): Remove lib_SOURCES.
4940         * modules/relocatable-lib-lgpl (configure.ac): Invoke
4941         gl_RELOCATABLE_LIBRARY.
4942         (Makefile.am): Remove lib_SOURCES.
4943         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
4944         always.
4945         * modules/relocatable-prog-wrapper (configure.ac): Invoke
4946         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
4947
4948 2007-03-04  Bruno Haible  <bruno@clisp.org>
4949
4950         * modules/argmatch-tests: New file.
4951         * tests/test-argmatch.c: New file.
4952
4953         * tests/test-allocsa.c (main): Halve the number of loop runs.
4954
4955         * modules/alloca-opt-tests: New file.
4956         * tests/test-alloca-opt.c: New file.
4957
4958 2007-03-04  Jim Meyering  <jim@meyering.net>
4959
4960         Work around difference between Linux ACLs and Solaris 10 ZFS.
4961         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
4962         for EINVAL.
4963
4964 2007-03-03  Bruno Haible  <bruno@clisp.org>
4965
4966         * modules/relocatable-prog (Depends-on): Add back progreloc's
4967         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
4968
4969 2007-03-03  Bruno Haible  <bruno@clisp.org>
4970
4971         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
4972         * modules/relocatable-lib: New file.
4973
4974 2007-03-03  Bruno Haible  <bruno@clisp.org>
4975
4976         * modules/relocatable-prog: Renamed from modules/relocatable.
4977         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
4978
4979 2007-03-03  Bruno Haible  <bruno@clisp.org>
4980
4981         * modules/relocatable-script (Files): Add doc/relocatable.texi,
4982         m4/relocatable-lib.m4.
4983         (Depends-on): Remove 'relocatable'.
4984         (configure.ac): Add gl_RELOCATABLE_NOP.
4985
4986 2007-03-03  Bruno Haible  <bruno@clisp.org>
4987
4988         * modules/relocatable-prog-wrapper: New file.
4989         * modules/relocatable (Depends-on): Add it. Remove all other
4990         dependencies except progname.
4991         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
4992
4993         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
4994         (gl_FUNC_STRERROR): Nop.
4995         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
4996
4997         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
4998         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
4999
5000         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
5001         (gl_FUNC_READLINK): Update.
5002
5003         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
5004
5005 2007-03-03  Bruno Haible  <bruno@clisp.org>
5006
5007         * lib/xreadlink.c: Include <unistd.h> unconditionally.
5008         * modules/xreadlink (Depends-on): Add unistd.
5009         * modules/xreadlink-with-size (Depends-on): Likewise.
5010
5011 2007-03-03  Bruno Haible  <bruno@clisp.org>
5012
5013         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
5014         extracted from gt_FUNC_SETENV.
5015         (gt_FUNC_SETENV): Remove macro.
5016         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
5017         remove gt_FUNC_SETENV.
5018
5019 2007-03-03  Bruno Haible  <bruno@clisp.org>
5020
5021         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
5022         ENABLE_RELOCATABLE here.
5023         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
5024
5025 2007-03-03  Bruno Haible  <bruno@clisp.org>
5026
5027         * modules/rbtreehash-list-tests (Depends-on): Add progname.
5028         * tests/test-rbtreehash_list.c: Include progname.h.
5029         (main): Call set_program_name.
5030
5031         * modules/rbtree-oset-tests (Depends-on): Add progname.
5032         * tests/test-rbtree_oset.c: Include progname.h.
5033         (main): Call set_program_name.
5034
5035         * modules/rbtree-list-tests (Depends-on): Add progname.
5036         * tests/test-rbtree_list.c: Include progname.h.
5037         (main): Call set_program_name.
5038
5039         * modules/linked-list-tests (Depends-on): Add progname.
5040         * tests/test-linked_list.c: Include progname.h.
5041         (main): Call set_program_name.
5042
5043 2007-03-03  Bruno Haible  <bruno@clisp.org>
5044
5045         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
5046         All uses of __restrict changed to _Restrict_.
5047         * lib/glob_.h (__restrict): Remove macro.
5048
5049 2007-03-02  Bruno Haible  <bruno@clisp.org>
5050
5051         * modules/gettext (configure.ac): Require gettext infrastructure
5052         from version 0.16.1.
5053
5054 2007-03-02  Bruno Haible  <bruno@clisp.org>
5055
5056         * modules/linkedhash-list-tests (Depends-on): Add progname.
5057         * tests/test-linkedhash_list.c: Include progname.h.
5058         (main): Call set_program_name.
5059
5060         * modules/carray-list-tests (Depends-on): Add progname.
5061         * tests/test-carray_list.c: Include progname.h.
5062         (main): Call set_program_name.
5063
5064         * modules/avltreehash-list-tests (Depends-on): Add progname.
5065         * tests/test-avltreehash_list.c: Include progname.h.
5066         (main): Call set_program_name.
5067
5068         * modules/avltree-oset-tests (Depends-on): Add progname.
5069         * tests/test-avltree_oset.c: Include progname.h.
5070         (main): Call set_program_name.
5071
5072         * modules/avltree-list-tests (Depends-on): Add progname.
5073         * tests/test-avltree_list.c: Include progname.h.
5074         (main): Call set_program_name.
5075
5076         * modules/array-oset-tests (Depends-on): Add progname.
5077         * tests/test-array_oset.c: Include progname.h.
5078         (main): Call set_program_name.
5079
5080         * modules/array-list-tests (Depends-on): Add progname.
5081         * tests/test-array_list.c: Include progname.h.
5082         (main): Call set_program_name.
5083
5084         * modules/argp-tests (Depends-on): Add progname.
5085         * tests/test-argp.c: Include argp.h first. Include progname.h.
5086         (main): Call set_program_name.
5087
5088 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
5089
5090         * doc/gnulib-tool.texi (Initial import): Reword description of
5091         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
5092         limited effect even if defined after the first system include.
5093
5094 2007-03-01  Bruno Haible  <bruno@clisp.org>
5095
5096         * build-aux/config.libpath: Update to libtool-1.5.22.
5097         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
5098
5099 2007-03-01  Bruno Haible  <bruno@clisp.org>
5100
5101         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
5102         foo_CFLAGS.
5103         Reported by Ralf Wildenhues.
5104
5105 2007-03-01  Bruno Haible  <bruno@clisp.org>
5106
5107         * build-aux/install-reloc: Remove object files left over by some
5108         compilers.
5109         Reported by Ralf Wildenhues.
5110
5111 2007-03-01  Bruno Haible  <bruno@clisp.org>
5112
5113         * build-aux/install-reloc: Break long lines.
5114
5115 2007-03-01  Bruno Haible  <bruno@clisp.org>
5116
5117         * doc/relocatable.texi: Document that it may not work on OpenBSD.
5118         Reported by Ralf Wildenhues.
5119
5120 2007-03-01  Bruno Haible  <bruno@clisp.org>
5121
5122         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
5123         include ordering constraints.
5124
5125 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
5126
5127         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
5128         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
5129         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
5130         as another example.
5131         * lib/time_.h: Fix misspelling.
5132         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
5133         Require gl_HEADER_TIME_H_DEFAULTS.
5134         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
5135         * m4/time_r.m4 (gl_TIME_R): Likewise.
5136         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
5137
5138 2007-03-01  Bruno Haible  <bruno@clisp.org>
5139
5140         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
5141         * m4/utimens.m4 (gl_UTIMENS): Likewise.
5142
5143 2007-03-01  Jim Meyering  <jim@meyering.net>
5144
5145         * modules/xreadlink (Maintainer): Add my name.
5146         * modules/xreadlink-with-size (Depends-on): Alphabetize.
5147
5148 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
5149             Bruno Haible  <bruno@clisp.org>
5150
5151         * build-aux/install-reloc: Compile also c-ctype.c.
5152         * build-aux/relocatable.sh.in: New file.
5153         * doc/relocatable.texi: New file.
5154         * doc/relocatable-maint.texi: New file.
5155         * doc/gnulib.texi: Include relocatable-maint.texi.
5156         * lib/progreloc.c: Include unistd.h unconditionally.
5157         * lib/relocwrapper.c: Include unistd.h unconditionally.
5158         Include c-ctype.h.
5159         (add_dotbin): Use c_tolower.
5160         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
5161         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
5162         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
5163         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
5164         to m4/relocatable-lib.m4.
5165         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
5166         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
5167         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
5168         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
5169         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
5170         * modules/relocatable: New file.
5171         * modules/relocatable-lib: New file.
5172         * modules/relocatable-script: New file.
5173
5174 2007-02-28  Bruno Haible  <bruno@clisp.org>
5175
5176         Import --enable-relocatable infrastructure.
5177         * build-aux/config.libpath: New file, from GNU gettext.
5178         * build-aux/install-reloc: New file, from GNU gettext.
5179         * build-aux/reloc-ldflags: New file, from GNU gettext.
5180         * lib/relocatable.h: New file, from GNU gettext.
5181         * lib/relocatable.c: New file, from GNU gettext.
5182         * lib/relocwrapper.c: New file, from GNU gettext.
5183         * m4/relocatable.m4: New file, from GNU gettext.
5184
5185 2007-02-28  Bruno Haible  <bruno@clisp.org>
5186
5187         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
5188
5189         * modules/xreadlink: New file, from GNU gettext with modifications.
5190         * lib/xreadlink.c: New file, from GNU gettext.
5191         * lib/xreadlink.h: Add comments.
5192         (xreadlink): New declaration.
5193
5194         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
5195         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
5196         lib/xreadlink-with-size.c.
5197         (configure.ac): Remove gl_XREADLINK invocation.
5198         (Makefile.am): Augment lib_SOURCES.
5199         * m4/xreadlink.m4: Remove file.
5200         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
5201         (xreadlink_with_size): Renamed from xreadink.
5202         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
5203         * modules/canonicalize (Depends-on): Replace xreadlink with
5204         xreadlink-with-size.
5205         * lib/canonicalize.c (canonicalize_filename_mode): Update.
5206
5207 2007-02-25  Jim Meyering  <jim@meyering.net>
5208
5209         * build-aux/announce-gen: When complaining about excess arguments,
5210         list them.
5211
5212 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
5213
5214         * README: Document signed integer overflow situation more
5215         accurately.
5216
5217 2007-02-25  Bruno Haible  <bruno@clisp.org>
5218
5219         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
5220         'a' or 'A' conversion.
5221
5222 2007-02-25  Bruno Haible  <bruno@clisp.org>
5223
5224         * modules/filename: Renamed from modules/pathname.
5225         (Files): Replace lib/pathname.h with lib/filename.h. Replace
5226         lib/concatpath.c with lib/concat-filename.c.
5227         (Makefile.am): Update.
5228         (Include): Replace pathname.h with filename.h.
5229         * lib/filename.h: Renamed from lib/pathname.h.
5230         (concatenated_filename): Renamed from concatenated_pathname.
5231         * lib/concat-filename.c: Renamed from lib/concatpath.c.
5232         (concatenated_filename): Renamed from concatenated_pathname.
5233         * lib/findprog.c: Include filename.h instead of pathname.h.
5234         (find_in_path): Update.
5235         * lib/javacomp.c: Include filename.h instead of pathname.h.
5236         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
5237         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
5238         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
5239         is_oldgcj_14_13_usable, is_javac_usable): Update.
5240         * lib/javaexec.c: Include filename.h instead of pathname.h.
5241         (execute_java_class): Update.
5242         * modules/findprog: Update.
5243         * modules/javacomp: Update.
5244         * modules/javaexec: Update.
5245         * MODULES.html.sh (File system functions): Add 'filename', remove
5246         'pathname'.
5247
5248 2007-02-25  Bruno Haible  <bruno@clisp.org>
5249
5250         * modules/printf-frexpl-tests: New file.
5251         * tests/test-printf-frexpl.c: New file.
5252
5253         * modules/printf-frexpl: New file.
5254         * lib/printf-frexpl.h: New file.
5255         * lib/printf-frexpl.c: New file.
5256         * m4/printf-frexpl.m4: New file.
5257
5258 2007-02-25  Bruno Haible  <bruno@clisp.org>
5259
5260         * modules/printf-frexp-tests: New file.
5261         * tests/test-printf-frexp.c: New file.
5262
5263         * modules/printf-frexp: New file.
5264         * lib/printf-frexp.h: New file.
5265         * lib/printf-frexp.c: New file.
5266         * m4/printf-frexp.m4: New file.
5267
5268 2007-02-25  Bruno Haible  <bruno@clisp.org>
5269
5270         Assume automake >= 1.10 for the tests.
5271         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
5272         * modules/arctwo-tests: Likewise.
5273         * modules/argp-tests: Likewise.
5274         * modules/avltree-list-tests: Likewise.
5275         * modules/avltree-oset-tests: Likewise.
5276         * modules/avltreehash-list-tests: Likewise.
5277         * modules/carray-list-tests: Likewise.
5278         * modules/crc-tests: Likewise.
5279         * modules/des-tests: Likewise.
5280         * modules/gc-arcfour-tests: Likewise.
5281         * modules/gc-arctwo-tests: Likewise.
5282         * modules/gc-des-tests: Likewise.
5283         * modules/gc-hmac-md5-tests: Likewise.
5284         * modules/gc-hmac-sha1-tests: Likewise.
5285         * modules/gc-md2-tests: Likewise.
5286         * modules/gc-md4-tests: Likewise.
5287         * modules/gc-md5-tests: Likewise.
5288         * modules/gc-pbkdf2-sha1-tests: Likewise.
5289         * modules/gc-rijndael-tests: Likewise.
5290         * modules/gc-sha1-tests: Likewise.
5291         * modules/gc-tests: Likewise.
5292         * modules/getaddrinfo-tests: Likewise.
5293         * modules/hmac-md5-tests: Likewise.
5294         * modules/hmac-sha1-tests: Likewise.
5295         * modules/linked-list-tests: Likewise.
5296         * modules/linkedhash-list-tests: Likewise.
5297         * modules/lock-tests: Likewise.
5298         * modules/md2-tests: Likewise.
5299         * modules/md4-tests: Likewise.
5300         * modules/md5-tests: Likewise.
5301         * modules/rbtree-list-tests: Likewise.
5302         * modules/rbtree-oset-tests: Likewise.
5303         * modules/rbtreehash-list-tests: Likewise.
5304         * modules/read-file-tests: Likewise.
5305         * modules/rijndael-tests: Likewise.
5306         * modules/stdint-tests: Likewise.
5307         * modules/tls-tests: Likewise.
5308
5309 2007-02-24  Bruno Haible  <bruno@clisp.org>
5310
5311         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
5312         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
5313         function; instead check whether isnan with a double argument links.
5314         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
5315         function; instead check whether isnan with a 'long double' argument
5316         links.
5317         Reported by Eric Blake <ebb9@byu.net>.
5318
5319 2007-02-24  Bruno Haible  <bruno@clisp.org>
5320
5321         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
5322         defined.
5323         * lib/isnanl.c: Remove all code. Just include isnan.c.
5324         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
5325
5326 2007-02-25  Jim Meyering  <jim@meyering.net>
5327
5328         Avoid conflicting types for 'unsetenv' on FreeBSD.
5329         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
5330         conflicting with FreeBSD's (5.0 and 6.1) function declaration
5331         in stdlib.h.
5332
5333 2007-02-24  Bruno Haible  <bruno@clisp.org>
5334
5335         * modules/isnanl-nolibm-tests: New file.
5336         * tests/test-isnanl.c: New file.
5337
5338         * modules/isnanl-nolibm: New file.
5339         * lib/isnanl.h: New file.
5340         * lib/isnanl.c: New file.
5341         * m4/isnanl.m4: New file.
5342
5343 2007-02-24  Bruno Haible  <bruno@clisp.org>
5344
5345         * modules/isnan-nolibm-tests: New file.
5346         * tests/test-isnan.c: New file.
5347
5348         * modules/isnan-nolibm: New file.
5349         * lib/isnan.h: New file.
5350         * lib/isnan.c: New file.
5351         * m4/isnan.m4: New file.
5352
5353 2007-02-24  Bruno Haible  <bruno@clisp.org>
5354
5355         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
5356         assume that an exponent fits in 20 bits.
5357
5358 2007-02-24  Jim Meyering  <jim@meyering.net>
5359
5360         * m4/regex.m4: Update the description of the configure-time option,
5361         --without-included-regex, to state accurately what the defaults are,
5362         and perhaps to give people an idea why using this option is risky.
5363
5364 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
5365
5366         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
5367         loops on small arguments.  This attempts to avoid the problem
5368         Bruno Haible reported for AIX 4.3.2 in
5369         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
5370
5371 2007-02-23  Bruno Haible  <bruno@clisp.org>
5372
5373         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
5374         Needed for help2man.
5375
5376 2007-02-23  Karl Berry  <karl@gnu.org>
5377
5378         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
5379         exists, foo.h should be cvs-ignored, not committed.
5380
5381 2007-02-23  Eric Blake  <ebb9@byu.net>
5382
5383         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
5384         * lib/stat-time.h (includes): Likewise.
5385         * lib/utimecmp.c (includes): Likewise.
5386         * lib/utimens.h (includes): Likewise.
5387         * lib/getdate.y (includes): Also include "timespec.h" for use
5388         internal to the module.
5389         * modules/utimens (Depends-on): Revert yesterday's patch.
5390         * modules/nanosleep (Depends-on): Add missing dependency.
5391
5392 2007-02-22  Bruno Haible  <bruno@clisp.org>
5393
5394         * lib/glob.c: Don't include getlogin_r.h.
5395
5396 2007-02-22  Jim Meyering  <jim@meyering.net>
5397
5398         * modules/utimens (Depends-on): Add timespec, required for
5399         utimens.h's inclusion of timespec.h.
5400
5401 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
5402
5403         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
5404         long unreadable paths in GNU/Linux.  Problem reported by Andreas
5405         Schwab in
5406         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
5407         I'll try to think of a better way to fix the Solaris problem.
5408
5409         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
5410         like glibc; on Solaris 10, it fails with errno == EINVAL.
5411         POSIX says the behavior is unspecified if the first argument is NULL,
5412         so play it safe and never pass NULL to the system getcwd.
5413
5414 2007-02-21  Jim Meyering  <jim@meyering.net>
5415
5416         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
5417         of gettimeofday.  It would conflict with the one now always
5418         provided via sys_time_.h.  Reported by Matthew Woehlke, as
5419         an IRIX 6.5 build failure.
5420
5421 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
5422
5423         Minor fixups to port to Solaris 10 with Sun C 5.8.
5424         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
5425         * modules/getcwd (Depends-on): Add dirfd.
5426         * lib/putenv.c (putenv): #undef it.
5427         (rpl_putenv): New decl.
5428         (malloc, free): Include <stdlib.h> rather than prototyping separately.
5429
5430 2007-02-20  Bruno Haible  <bruno@clisp.org>
5431
5432         * modules/stdio-tests: New file.
5433         * tests/test-stdio.c: New file.
5434
5435         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
5436         (Depends-on): Add stdio.
5437         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
5438         (Include): Use <stdio.h> instead of vsnprintf.h.
5439         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
5440         HAVE_DECL_VSNPRINTF.
5441         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
5442
5443         * modules/snprintf (Files): Remove lib/snprintf.h.
5444         (Depends-on): Add stdio.
5445         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
5446         (Include): Use <stdio.h> instead of snprintf.h.
5447         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
5448         HAVE_DECL_SNPRINTF.
5449         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
5450         * lib/getaddrinfo.c: Likewise.
5451
5452         * modules/stdio: New file.
5453         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
5454         * lib/snprintf.h: Remove file.
5455         * lib/vsnprintf.h: Remove file.
5456         * lib/.cppi-disable: Remove snprintf.h.
5457         * m4/stdio_h.m4: New file.
5458         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
5459
5460 2007-02-20  Jim Meyering  <jim@meyering.net>
5461
5462         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
5463         used by e.g., mingw.  From Bruno Haible.
5464
5465 2007-02-19  Bruno Haible  <bruno@clisp.org>
5466
5467         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
5468         warnings.
5469         Reported by Ben Pfaff <blp@cs.stanford.edu>.
5470
5471 2007-02-19  Bruno Haible  <bruno@clisp.org>
5472
5473         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
5474         from mingw users.
5475
5476 2007-02-19  Bruno Haible  <bruno@clisp.org>
5477
5478         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
5479         warnings.
5480         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
5481
5482 2007-02-19  Jim Meyering  <jim@meyering.net>
5483
5484         Don't use FD after a successful "fdopendir (fd)".
5485         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
5486         Reset it by calling dirfd on the just-obtained DIR*.
5487
5488         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
5489         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
5490
5491 2007-02-18  Bruno Haible  <bruno@clisp.org>
5492
5493         * lib/readlink.c: Include <unistd.h>.
5494         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
5495         HAVE_READLINK.
5496         * modules/readlink (Depends-on): Add unistd.
5497         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5498         (Include): Add <unistd.h>.
5499
5500         * lib/getlogin_r.h: Remove file.
5501         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
5502         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
5503         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
5504         HAVE_DECL_GETLOGIN_R.
5505         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
5506         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5507         (Include): Use <unistd.h> instead of getlogin_r.h.
5508
5509         * lib/getcwd.h: Remove file.
5510         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
5511         * lib/xgetcwd.c: Likewise.
5512         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
5513         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
5514         * modules/getcwd (Files): Remove lib/getcwd.h.
5515         (Depends-on): Add unistd.
5516         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5517         (Include): Use <unistd.h> instad of getcwd.h.
5518
5519         * lib/ftruncate.c: Include <unistd.h> first.
5520         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
5521         Set HAVE_FTRUNCATE.
5522         * modules/ftruncate (Depends-on): Add unistd.
5523         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5524
5525         * lib/fchdir.c: Include <unistd.h> first.
5526         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
5527         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
5528         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
5529         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5530         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
5531
5532         * lib/dup2.c: Include <unistd.h> first.
5533         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
5534         HAVE_DUP2.
5535         * modules/dup2 (Depends-on): Add unistd.
5536         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5537
5538         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
5539         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
5540         REPLACE_CHOWN. Don't define chown as a macro here.
5541         * modules/chown (Depends-on): Add unistd.
5542         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5543
5544         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
5545         Add definition for GL_LINK_WARNING.
5546         (chown, dup2): New declarations.
5547         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
5548         link warning.
5549         (ftruncate): New declaration.
5550         (getcwd): New declaration, taken from old getcwd.h.
5551         (getlogin_r): New declaration, taken from old getlogin_r.h.
5552         (readlink): New declaration.
5553         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
5554         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
5555         (gl_PREREQ_UNISTD): Remove macro.
5556         (gl_UNISTD_MODULE_INDICATOR): New macro.
5557         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
5558         many new variables. Don't set UNISTD_H.
5559         * modules/unistd (Description): Change.
5560         (Depends-on): Add link-warning.
5561         (configure.ac): Update.
5562         (Makefile.am): Create unistd.h always. Substitute many new variables
5563         into it.
5564
5565 2007-02-18  Bruno Haible  <bruno@clisp.org>
5566
5567         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
5568         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
5569         HAVE_GETSUBOPT.
5570         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
5571         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
5572         * lib/getsubopt.h: Remove file.
5573         * modules/getsubopt (Files): Remove lib/getsubopt.h.
5574         (Depends-on): Add stdlib.
5575         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5576         (Includes): Use <stdlib.h> instead of getsubopt.h.
5577         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
5578         Set HAVE_GETSUBOPT.
5579         * lib/getsubopt.c: Don't include getsubopt.h.
5580
5581 2007-02-18  Bruno Haible  <bruno@clisp.org>
5582
5583         * modules/fchdir (Depends-on): Add dup2.
5584
5585 2007-02-18  Bruno Haible  <bruno@clisp.org>
5586
5587         * lib/stdlib_.h: Handle glibc's special invocation convention
5588         specially.
5589
5590 2007-02-18  Bruno Haible  <bruno@clisp.org>
5591
5592         * modules/stdlib-tests: New file.
5593         * tests/test-stdlib.c: New file.
5594
5595         * modules/mkstemp (Files): Remove lib/mkstemp.h.
5596         (Depends-on): Add stdlib.
5597         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5598         (Includes): Use <stdlib.h> instead of mkstemp.h.
5599         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
5600         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
5601         * lib/mkstemp.c: Don't include mkstemp.h.
5602         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
5603         * lib/stdlib--.h: Don't include mkstemp.h.
5604
5605         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
5606         (Depends-on): Add stdlib.
5607         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5608         (Includes): Use <stdlib.h> instead of mkdtemp.h.
5609         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
5610         HAVE_MKDTEMP.
5611         * lib/mkdtemp.c: Don't include mkdtemp.h.
5612         * lib/clean-temp.c: Don't include mkdtemp.h.
5613
5614         * modules/exit (Files): Remove lib/exit.h.
5615         (Depends-on): Add stdlib.
5616         (Makefile.am): Remove lib_SOURCES.
5617         (Include): Use <stdlib.h> instead of exit.h.
5618         * lib/argmatch.c: Don't include exit.h.
5619         * lib/execute.c: Likewise.
5620         * lib/pagealign_alloc.c: Likewise.
5621         * lib/pipe.c: Likewise.
5622         * lib/wait-process.c: Likewise.
5623         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
5624         * lib/exitfail.c: Likewise.
5625         * lib/savewd.c: Likewise.
5626         * lib/xsetenv.c: Likewise.
5627
5628         * modules/stdlib: New file.
5629         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
5630         and extra comments about mkstemp().
5631         * lib/exit.h: Remove file.
5632         * lib/mkdtemp.h: Remove file.
5633         * lib/mkstemp.h: Remove file.
5634         * m4/stdlib_h.m4: New file.
5635         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
5636
5637 2007-02-18  Bruno Haible  <bruno@clisp.org>
5638
5639         * modules/math-tests: New file.
5640         * tests/test-math.c: New file.
5641
5642         * modules/math: New file.
5643         * modules/mathl (Files): Remove lib/mathl.h.
5644         (Depends-on): Add math.
5645         (Makefile.am): Don't mention mathl.h.
5646         (Include): Use <math.h> instead of mathl.h.
5647         * lib/math_.h: New file.
5648         * lib/mathl.h: Remove file.
5649         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
5650         mathl.h.
5651         * lib/asinl.c: Likewise.
5652         * lib/atanl.c: Likewise.
5653         * lib/ceill.c: Likewise.
5654         * lib/cosl.c: Likewise.
5655         * lib/expl.c: Likewise.
5656         * lib/floorl.c: Likewise.
5657         * lib/frexpl.c: Likewise.
5658         * lib/ldexpl.c: Likewise.
5659         * lib/logl.c: Likewise.
5660         * lib/sincosl.c: Likewise.
5661         * lib/sinl.c: Likewise.
5662         * lib/sqrtl.c: Likewise.
5663         * lib/tanl.c: Likewise.
5664         * lib/trigl.c: Likewise.
5665         * m4/math_h.m4: New file.
5666         * MODULES.html.sh (Mathematics): Add math.
5667
5668 2007-02-17  Bruno Haible  <bruno@clisp.org>
5669
5670         * modules/wctype-tests: New file.
5671         * tests/test-wctype.c: New file.
5672
5673         * modules/wchar-tests: New file.
5674         * tests/test-wchar.c: New file.
5675
5676         * modules/unistd-tests: New file.
5677         * tests/test-unistd.c: New file.
5678
5679         * modules/time-tests: New file.
5680         * tests/test-time.c: New file.
5681
5682         * modules/sysexits-tests: New file.
5683         * tests/test-sysexits.c: New file.
5684
5685         * modules/sys_time-tests: New file.
5686         * tests/test-sys_time.c: New file.
5687
5688         * modules/sys_stat-tests: New file.
5689         * tests/test-sys_stat.c: New file.
5690
5691         * modules/sys_socket-tests: New file.
5692         * tests/test-sys_socket.c: New file.
5693
5694         * modules/sys_select-tests: New file.
5695         * tests/test-sys_select.c: New file.
5696
5697         * modules/string-tests: New file.
5698         * tests/test-string.c: New file.
5699
5700         * modules/stdbool-tests: New file.
5701         * tests/test-stdbool.c: New file.
5702
5703         * modules/netinet_in-tests: New file.
5704         * tests/test-netinet_in.c: New file.
5705
5706         * modules/inttypes-tests: New file.
5707         * tests/test-inttypes.c: New file.
5708
5709         * modules/fcntl-tests: New file.
5710         * tests/test-fcntl.c: New file.
5711
5712         * modules/byteswap-tests: New file.
5713         * tests/test-byteswap.c: New file.
5714
5715         * modules/arpa_inet-tests: New file.
5716         * tests/test-arpa_inet.c: New file.
5717
5718 2007-02-17  Bruno Haible  <bruno@clisp.org>
5719
5720         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
5721         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
5722         if the corresponding module is not enabled. Emit link warnings if
5723         the function is used nevertheless.
5724         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
5725         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
5726         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
5727         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
5728         * modules/inttypes (Depends-on): Add link-warning.
5729         (Makefile.am): Copy the contents of build-aux/link-warning.h into
5730         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
5731         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
5732         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
5733         * modules/imaxdiv (configure.ac): Likewise.
5734         * modules/strtoimax (configure.ac): Likewise.
5735         * modules/strtoumax (configure.ac): Likewise.
5736
5737 2007-02-17  Bruno Haible  <bruno@clisp.org>
5738
5739         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
5740         gl_STRING_MODULE_INDICATOR_DEFAULTS.
5741         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
5742         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
5743
5744 2007-02-17  Bruno Haible  <bruno@clisp.org>
5745
5746         * modules/link-warning: New file.
5747         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
5748         * lib/string_.h (GL_LINK_WARNING): Remove definition.
5749         * modules/string (Depends-on): Add link-warning.
5750         (Makefile.am): Copy the contents of build-aux/link-warning.h into
5751         string.h.
5752         * MODULES.html.sh (Support for building libraries and executables): Add
5753         link-warning.
5754
5755 2007-02-17  Bruno Haible  <bruno@clisp.org>
5756
5757         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
5758         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
5759         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
5760         long lines.
5761
5762 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
5763             Bruno Haible  <bruno@clisp.org>
5764
5765         * modules/tmpfile: New file.
5766         * lib/tmpfile.c: New file.
5767         * m4/tmpfile.m4: New file.
5768         * MODULES.html.sh (func_all_modules): New section "Input/output".
5769
5770 2007-02-15  Bruno Haible  <bruno@clisp.org>
5771
5772         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
5773         (supports_delete_on_close): New function.
5774         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
5775
5776 2007-02-14  Bruno Haible  <bruno@clisp.org>
5777
5778         * modules/mbspcasecmp-tests: New file.
5779         * tests/test-mbspcasecmp.sh: New file.
5780         * tests/test-mbspcasecmp.c: New file.
5781
5782         New module mbspcasecmp.
5783         * modules/mbspcasecmp: New file.
5784         * lib/mbspcasecmp.c: New file.
5785         * lib/string_.h (strncasecmp): Change warning message.
5786         (mbspcasecmp): New declaration.
5787         * m4/mbspcasecmp.m4: New file.
5788         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5789         GNULIB_MBSPCASECMP.
5790         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
5791         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
5792
5793 2007-02-14  Bruno Haible  <bruno@clisp.org>
5794
5795         * modules/mbsncasecmp-tests: New file.
5796         * tests/test-mbsncasecmp.sh: New file.
5797         * tests/test-mbsncasecmp.c: New file.
5798
5799         New module mbsncasecmp.
5800         * modules/mbsncasecmp: New file.
5801         * lib/mbsncasecmp.c: New file.
5802         * lib/string_.h (mbsncasecmp): New declaration.
5803         * m4/mbsncasecmp.m4: New file.
5804         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5805         GNULIB_MBSNCASECMP.
5806         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
5807         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
5808
5809 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
5810
5811         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
5812         Verify that it doesn't overlap with our flags.
5813         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
5814         do not have the desired effect in multibyte locales; instead, use
5815         mbscasecmp.
5816         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
5817         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
5818         we don't require GNU fnmatch ourselves (if our users require it, they
5819         should do so explicitly).
5820
5821         Fix regex code so it doesn't rely on strcasecmp.
5822         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
5823         Otherwise, include gnulib's langinfo.h.
5824         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
5825         undesirable behavior in non-C locales.  Instead, rely on localecharset.
5826         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
5827         * modules/regex (FILES): Remove m4/codeset.m4.
5828         (Depends-on): Add localcharset.  Remove strcase.
5829
5830 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5831
5832         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
5833         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
5834
5835 2007-02-13  Bruno Haible  <bruno@clisp.org>
5836
5837         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
5838         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
5839
5840 2007-02-12  Bruno Haible  <bruno@clisp.org>
5841
5842         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
5843         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
5844         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
5845         time warning rather than a link error.
5846
5847 2007-02-12  Bruno Haible  <bruno@clisp.org>
5848
5849         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
5850         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
5851         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
5852
5853 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
5854
5855         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
5856         args, not 2.
5857
5858 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
5859
5860         New module 'time', so that apps can include <time.h> as per
5861         POSIX and GNU instead of separate include files like time_r.h
5862         and timegm.h.  This implementation tries out a simpler approach
5863         for replacing decls in standard include files (as compared to
5864         the string module), somewhat as an experiment.
5865
5866         * config/srclist.txt: Comment out mktime.c for now.
5867         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
5868         since it doesn't apply any more.  Use generic wording instead.
5869         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
5870         'time'.
5871         * lib/time_.h, m4/time_h.m4, modules/time: New files.
5872         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
5873         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
5874         Don't include <sys/types.h>; no longer needed since we assume C89.
5875         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
5876         * lib/strftime.c: Likewise.
5877         * lib/time_r.c: Likewise.
5878         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
5879         * lib/nanosleep.c: Include <time.h> first, to check interface.
5880         * lib/strptime.c: Likewise.
5881         * lib/time_r.c: Likewise.
5882         * lib/timegm.c: Likewise.
5883         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
5884         needed.
5885         * lib/timegm.c: Don't include timegm.h; no longer needed.
5886         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
5887         time.h now handles any problems in that area.
5888         (struct timespec, nanosleep): Remove; time.h now arranges for these.
5889         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
5890         that time.h defines struct timespec.
5891         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
5892         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
5893         handles that.
5894         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
5895         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
5896         needed.  Set REPLACE_LOCALTIME.
5897         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
5898         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
5899         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
5900         nanosleep; time_h.m4 now does that.  Don't require
5901         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
5902         module handles this now.
5903         * modules/getdate (Depends-on): Remove timespec.  Add time.
5904         * modules/nanosleep (Depends-on): Likewise.
5905         * modules/stat-time (Depends-on): Likewise.
5906         * modules/nanosleep (Include): Include time.h, not timespec.h.
5907         * modules/strptime (Files): Remove lib/strptime.h.
5908         (Depends-on): Add extensions, time.
5909         (Include): Include time.h, not strptime.h.
5910         * modules/time_r (Files): Remove lib/time_r.h.
5911         (Depends-on): Add time.
5912         (Include): Include time.h, not time_r.h.
5913         * modules/timegm: Likewise.
5914         * modules/timespec (Description): Now does timespec-related decls
5915         of our own, instead of struct timespec itself.
5916         (Depends-on): Add time; remove extensions.
5917         (Maintainer): Add self.
5918         * modules/utimecmp (Depends-on): Add time; remove timespec.
5919         * modules/utimens (Depends-on): Likewise.
5920         * modules/xnanosleep (Depends-on): Likewise.
5921
5922 2007-02-11  Bruno Haible  <bruno@clisp.org>
5923
5924         * lib/c-strstr.c: Include allocsa.h.
5925         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
5926         * lib/c-strcasestr.c: Include allocsa.h.
5927         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
5928         * lib/strcasestr.c: Include allocsa.h.
5929         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
5930         * lib/mbsstr.c: Include allocsa.h.
5931         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
5932         allocsa/freesa instead of malloc/free.
5933         * lib/mbscasestr.c: Include allocsa.h.
5934         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
5935         allocsa/freesa instead of malloc/free.
5936         * modules/c-strstr (Depends-on): Add allocsa.
5937         * modules/c-strcasestr (Depends-on): Likewise.
5938         * modules/strcasestr (Depends-on): Likewise.
5939         * modules/mbsstr (Depends-on): Likewise.
5940         * modules/mbscasestr (Depends-on): Likewise.
5941
5942 2007-02-11  Bruno Haible  <bruno@clisp.org>
5943
5944         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
5945
5946         * modules/mbsspn-tests: New file.
5947         * tests/test-mbsspn.sh: New file.
5948         * tests/test-mbsspn.c: New file.
5949
5950 2007-02-11  Bruno Haible  <bruno@clisp.org>
5951
5952         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
5953
5954         * modules/mbspbrk-tests: New file.
5955         * tests/test-mbspbrk.sh: New file.
5956         * tests/test-mbspbrk.c: New file.
5957
5958 2007-02-11  Bruno Haible  <bruno@clisp.org>
5959
5960         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
5961         unneeded cast.
5962
5963         * modules/mbscspn-tests: New file.
5964         * tests/test-mbscspn.sh: New file.
5965         * tests/test-mbscspn.c: New file.
5966
5967 2007-02-11  Bruno Haible  <bruno@clisp.org>
5968
5969         * modules/mbscasecmp-tests: New file.
5970         * tests/test-mbscasecmp.sh: New file.
5971         * tests/test-mbscasecmp.c: New file.
5972
5973 2007-02-11  Bruno Haible  <bruno@clisp.org>
5974
5975         Ensure O(n) worst-case complexity of mbscasestr.
5976         * lib/mbscasestr.c: Include stdbool.h.
5977         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
5978         functions.
5979         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
5980         the bookkeeping indicates that it's worth it.
5981         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
5982
5983         * modules/mbscasestr-tests: New file.
5984         * tests/test-mbscasestr1.c: New file.
5985         * tests/test-mbscasestr2.sh: New file.
5986         * tests/test-mbscasestr2.c: New file.
5987         * tests/test-mbscasestr3.sh: New file.
5988         * tests/test-mbscasestr3.c: New file.
5989         * tests/test-mbscasestr4.sh: New file.
5990         * tests/test-mbscasestr4.c: New file.
5991         * m4/locale-tr.m4: New file.
5992
5993 2007-02-11  Bruno Haible  <bruno@clisp.org>
5994
5995         Ensure O(n) worst-case complexity of mbsstr.
5996         * lib/mbsstr.c: Include stdbool.h.
5997         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
5998         functions.
5999         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
6000         bookkeeping indicates that it's worth it.
6001         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
6002
6003         * modules/mbsstr-tests: New file.
6004         * tests/test-mbsstr1.c: New file.
6005         * tests/test-mbsstr2.sh: New file.
6006         * tests/test-mbsstr2.c: New file.
6007         * tests/test-mbsstr3.sh: New file.
6008         * tests/test-mbsstr3.c: New file.
6009         * m4/locale-fr.m4: New file.
6010
6011 2007-02-11  Bruno Haible  <bruno@clisp.org>
6012
6013         * lib/mbsrchr.c (mbsrchr): Fix bug.
6014
6015         * modules/mbsrchr-tests: New file.
6016         * tests/test-mbsrchr.sh: New file.
6017         * tests/test-mbsrchr.c: New file.
6018
6019 2007-02-11  Bruno Haible  <bruno@clisp.org>
6020
6021         * lib/mbschr.c (mbschr): Fix bug.
6022
6023         * modules/mbschr-tests: New file.
6024         * tests/test-mbschr.sh: New file.
6025         * tests/test-mbschr.c: New file.
6026         * m4/locale-zh.m4: New file.
6027
6028 2007-02-11  Bruno Haible  <bruno@clisp.org>
6029
6030         Support for copying multibyte string iterators.
6031         * lib/mbiter.h: Include <string.h>.
6032         (mbiter_multi_copy): New function.
6033         (mbi_copy): New macro.
6034         * lib/mbuiter.h: Include <string.h>.
6035         (mbuiter_multi_copy): New function.
6036         (mbui_copy): New macro.
6037
6038 2007-02-11  Bruno Haible  <bruno@clisp.org>
6039
6040         New module mbslen.
6041         * modules/mbslen: New file.
6042         * lib/mbslen.c: New file.
6043         * lib/string_.h (mbslen): New declaration.
6044         * m4/mbslen.m4: New file.
6045         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6046         GNULIB_MBSLEN.
6047         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
6048         * MODULES.html.sh (Internationalization functions): Add mbslen.
6049
6050 2007-02-11  Bruno Haible  <bruno@clisp.org>
6051
6052         Ensure O(n) worst-case complexity of strcasestr substitute.
6053         * lib/strcasestr.c: Include stdbool.h.
6054         (knuth_morris_pratt): New function.
6055         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
6056         bookkeeping indicates that it's worth it.
6057         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
6058
6059         * modules/strcasestr-tests: New file.
6060         * tests/test-strcasestr.c: New file.
6061
6062 2007-02-11  Bruno Haible  <bruno@clisp.org>
6063
6064         Ensure O(n) worst-case complexity of c_strcasestr.
6065         * lib/c-strcasestr.c: Include stdbool.h, string.h.
6066         (knuth_morris_pratt): New function.
6067         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
6068         the bookkeeping indicates that it's worth it.
6069         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
6070
6071         * modules/c-strcasestr-tests: New file.
6072         * tests/test-c-strcasestr.c: New file.
6073
6074 2007-02-11  Bruno Haible  <bruno@clisp.org>
6075
6076         Ensure O(n) worst-case complexity of c_strstr.
6077         * lib/c-strstr.c: Include stdbool.h, string.h.
6078         (knuth_morris_pratt): New function.
6079         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
6080         bookkeeping indicates that it's worth it.
6081         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
6082
6083         * lib/c-strstr.c: Complete rewrite for maintainability.
6084
6085         * modules/c-strstr-tests: New file.
6086         * tests/test-c-strstr.c: New file.
6087
6088 2007-02-11  Bruno Haible  <bruno@clisp.org>
6089
6090         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
6091         5.2.1 and earlier, whereby \055 was treated just like the range
6092         delimiter '-'.
6093         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
6094
6095 2007-02-08  Bruno Haible  <bruno@clisp.org>
6096
6097         * modules/regex (Depends-on): Add stdbool.
6098         Reported by Dalibor Topic <robilad@kaffe.org>.
6099
6100 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
6101
6102         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
6103         Prefer returning from main to exiting from it.
6104         Remove unnecessary parens after sizeof.
6105
6106 2007-02-05  Bruno Haible  <bruno@clisp.org>
6107
6108         New module mbssep.
6109         * modules/mbssep: New file.
6110         * lib/mbssep.c: New file.
6111         * lib/string_.h (strsep): Add a conditional link warning.
6112         (mbssep): New declaration.
6113         * m4/mbssep.m4: New file.
6114         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6115         GNULIB_MBSSEP.
6116         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
6117         * MODULES.html.sh (Internationalization functions): Add mbssep.
6118
6119 2007-02-05  Bruno Haible  <bruno@clisp.org>
6120
6121         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
6122         Optimize search in case of 1 delimiter.
6123
6124 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
6125
6126         * lib/acl.h: Include sys/types.h before sys/acl.h.
6127
6128 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
6129
6130         Merge upstream fix for glibc bugzilla #3957:
6131
6132         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
6133
6134         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
6135         bit for RE_HAT_LISTS_NOT_NEWLINE.
6136         (build_charclass_op): Remove bogus comment.
6137
6138 2007-02-05  Simon Josefsson  <simon@josefsson.org>
6139
6140         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
6141
6142 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
6143
6144         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
6145         * lib/memmem.c [!defined _LIBC]: Include config.h.
6146
6147 2007-02-04  Bruno Haible  <bruno@clisp.org>
6148
6149         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
6150         warning message.
6151
6152 2007-02-04  Bruno Haible  <bruno@clisp.org>
6153
6154         New module mbstok_r.
6155         * modules/mbstok_r: New file.
6156         * lib/mbstok_r.c: New file.
6157         * lib/string_.h (strtok_r): Change argument names to match the
6158         comments. Add a conditional link warning.
6159         (mbstok_r): New declaration.
6160         * m4/mbstok_r.m4: New file.
6161         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6162         GNULIB_MBSTOK_R.
6163         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
6164         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
6165
6166 2007-02-04  Bruno Haible  <bruno@clisp.org>
6167
6168         New module mbsspn.
6169         * modules/mbsspn: New file.
6170         * lib/mbsspn.c: New file.
6171         * lib/string_.h (strspn): Add a conditional link warning.
6172         (mbsspn): New declaration.
6173         * m4/mbsspn.m4: New file.
6174         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6175         GNULIB_MBSSPN.
6176         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
6177         * MODULES.html.sh (Internationalization functions): Add mbsspn.
6178
6179 2007-02-04  Bruno Haible  <bruno@clisp.org>
6180
6181         New module mbspbrk.
6182         * modules/mbspbrk: New file.
6183         * lib/mbspbrk.c: New file.
6184         * lib/string_.h (strpbrk): Add a conditional link warning.
6185         (mbspbrk): New declaration.
6186         * m4/mbspbrk.m4: New file.
6187         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6188         GNULIB_MBSPBRK.
6189         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
6190         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
6191
6192 2007-02-04  Bruno Haible  <bruno@clisp.org>
6193
6194         New module mbscspn.
6195         * modules/mbscspn: New file.
6196         * lib/mbscspn.c: New file.
6197         * lib/string_.h (strcspn): Add a conditional link warning.
6198         (mbscspn): New declaration.
6199         * m4/mbscspn.m4: New file.
6200         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6201         GNULIB_MBSCSPN.
6202         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
6203         * MODULES.html.sh (Internationalization functions): Add mbscspn.
6204
6205 2007-02-04  Bruno Haible  <bruno@clisp.org>
6206
6207         New module mbscasestr, reduced goal of strcasestr.
6208         * modules/mbscasestr: New file.
6209         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
6210         (mbscasestr): Renamed from strcasestr.
6211         * lib/strcasestr.c: Don't include mbuiter.h.
6212         (strcasestr): Remove support for multibyte locales.
6213         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
6214         Change the conditional link warning.
6215         (mbscasestr): New declaration.
6216         * m4/mbscasestr.m4: New file.
6217         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
6218         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
6219         REPLACE_STRCASESTR.
6220         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
6221         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
6222         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
6223         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
6224         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
6225         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
6226         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
6227         (Depends-on): Remove mbuiter.
6228         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
6229
6230 2007-02-04  Bruno Haible  <bruno@clisp.org>
6231
6232         Simplify handling of strncasecmp.
6233         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
6234         the conditional link warning.
6235         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
6236         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
6237         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
6238         * modules/strcase (configure.ac): Don't invoke
6239         gl_STRING_MODULE_INDICATOR.
6240         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
6241
6242 2007-02-04  Bruno Haible  <bruno@clisp.org>
6243
6244         New module mbscasecmp, reduced goal of strcasecmp.
6245         * modules/mbscasecmp: New file.
6246         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
6247         (mbscasecmp): Renamed from strcasecmp.
6248         * lib/strcasecmp.c: Don't include mbuiter.h.
6249         (strcasecmp): Remove support for multibyte locales.
6250         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
6251         Change the conditional link warning.
6252         (mbscasecmp): New declaration.
6253         * m4/mbscasecmp.m4: New file.
6254         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
6255         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
6256         REPLACE_STRCASECMP.
6257         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
6258         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6259         GNULIB_MBSCASECMP.
6260         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
6261         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
6262         * modules/strcase (Files): Remove m4/mbrtowc.m4.
6263         (Depends-on): Remove mbuiter.
6264         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
6265
6266 2007-02-04  Bruno Haible  <bruno@clisp.org>
6267
6268         New module mbsstr. Remove module strstr.
6269         * modules/mbsstr: New file.
6270         * modules/strstr: Remove file.
6271         * lib/mbsstr.c: Renamed from lib/strstr.c.
6272         (mbsstr): Renamed from strstr.
6273         * lib/string_.h (strstr): Remove declaration. Change the conditional
6274         link warning.
6275         (mbsstr): New declaration.
6276         * m4/mbsstr.m4: New file.
6277         * m4/strstr.m4: Remove file.
6278         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
6279         REPLACE_STRSTR.
6280         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
6281         Don't initialize GNULIB_STRSTR.
6282         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
6283         substitute GNULIB_STRSTR and REPLACE_STRSTR.
6284         * MODULES.html.sh (Internationalization functions): Add mbsstr.
6285         (Support for systems lacking ANSI C 89): Remove strstr.
6286
6287 2007-02-04  Bruno Haible  <bruno@clisp.org>
6288
6289         New module mbsrchr.
6290         * modules/mbsrchr: New file.
6291         * lib/mbsrchr.c: New file.
6292         * lib/string_.h (strrchr): Add a conditional link warning.
6293         (mbsrchr): New declaration.
6294         * m4/mbsrchr.m4: New file.
6295         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6296         GNULIB_MBSRCHR.
6297         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
6298         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
6299
6300 2007-02-04  Bruno Haible  <bruno@clisp.org>
6301
6302         New module mbschr.
6303         * modules/mbschr: New file.
6304         * lib/mbschr.c: New file.
6305         * lib/string_.h (strchr): Add a conditional link warning.
6306         (mbschr): New declaration.
6307         * m4/mbschr.m4: New file.
6308         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6309         GNULIB_MBSCHR.
6310         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
6311         * MODULES.html.sh (Internationalization functions): Add mbschr.
6312
6313 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
6314
6315         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
6316
6317         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
6318
6319 2007-02-04  Bruno Haible  <bruno@clisp.org>
6320
6321         New module description section 'configure.ac-early'.
6322         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
6323         (func_get_autoconf_early_snippet): New function.
6324         (func_import, func_create_testdir): Use it. Remove special cases for
6325         modules 'extensions' and 'lock'.
6326         * modules/extensions (configure.ac-early): Require
6327         gl_USE_SYSTEM_EXTENSIONS.
6328         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
6329
6330 2007-02-04  Bruno Haible  <bruno@clisp.org>
6331
6332         Make use of gcj-4.3's -fsource and -ftarget option.
6333         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
6334         and if so try the options -fsource and -ftarget.
6335         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
6336         source_version, ftarget_option, target_version arguments.
6337         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
6338         (is_envjavac_oldgcj_14_14_usable): Renamed from
6339         is_envjavac_gcj_14_14_usable.
6340         (is_envjavac_oldgcj_14_13_usable): Renamed from
6341         is_envjavac_gcj_14_13_usable.
6342         (is_gcj_present): Update.
6343         (is_gcj_43, is_gcj43_usable): New functions.
6344         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
6345         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
6346         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
6347         try the options -fsource and -ftarget.
6348
6349 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
6350
6351         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
6352         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
6353         larger value.
6354
6355 2007-02-03  Jim Meyering  <jim@meyering.net>
6356
6357         Give tools a better chance to allocate space for very large buffers.
6358         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
6359
6360         Make pwd and readlink work also when run with an unreadable parent dir
6361         on systems with openat support.
6362         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
6363         provided getcwd function, even when we have openat support.
6364         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
6365
6366 2007-02-02  Bruno Haible  <bruno@clisp.org>
6367
6368         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
6369         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
6370         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
6371         portability problems if one of these functions is only used on specific
6372         platforms.
6373         Reported by Paul Eggert.
6374
6375 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
6376
6377         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
6378         is causing more trouble than it's curing.
6379         * lib/regex_internal.h (__mempcpy): Remove.
6380         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
6381         (and make the code a tad smaller to boot).
6382         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
6383
6384 2007-02-02  Jim Meyering  <jim@meyering.net>
6385
6386         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
6387         section, not in the Makefile.am: one.
6388
6389 2007-02-02  Eric Blake  <ebb9@byu.net>
6390
6391         * lib/strchrnul.c: Always include config.h first.
6392
6393         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
6394         gnulib strstr is not necessary here.
6395
6396 2007-02-02  Simon Josefsson  <simon@josefsson.org>
6397
6398         * m4/socklen.m4: Fix typo.
6399
6400 2007-02-02  Eric Blake  <ebb9@byu.net>
6401
6402         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
6403         * modules/netinet_in (Makefile.am): Likewise.
6404
6405 2007-02-01  Bruno Haible  <bruno@clisp.org>
6406
6407         * lib/string_.h (GL_LINK_WARNING): New macro.
6408         (strcasecmp, strstr, strcasestr): If provided by the system,
6409         conditionally define as a macro that leads to a warning instead of to
6410         an error.
6411         (strncasecmp): Conditionally define as a macro that leads to a warning.
6412
6413 2007-02-01  Karl Berry  <karl@gnu.org>
6414
6415         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
6416
6417 2007-02-01  Bruno Haible  <bruno@clisp.org>
6418
6419         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
6420         renamings.
6421
6422 2007-02-01  Eric Blake  <ebb9@byu.net>
6423
6424         * modules/regex (Depends-on): Revert dependence on mempcpy.
6425         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
6426         module's definition of mempcpy.
6427         Reported by Paul Eggert.
6428
6429 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
6430
6431         * lib/string_.h: If the gnulib module XYZ is not present, undefine
6432         the symbol XYZ before redefining it.  This fixes a problem with
6433         programs that don't use XYZ, when compiled on systems that define
6434         XYZ to something else.
6435
6436 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
6437
6438         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
6439         occurs when "mkdir -m foo" creates a setgid directory that is (1)
6440         writeable to group or other and (2) is intended to have a special
6441         mode bit that is set or cleared.  In such a case, the directory
6442         should be neither group- nor other-writeable until the special
6443         mode bits are right.
6444
6445 2007-01-31  Eric Blake  <ebb9@byu.net>
6446
6447         * modules/mountlist (Depends-on): Add strstr.
6448
6449         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
6450         bug.
6451         * modules/string (Makefile.am): Remove redundant replacement.
6452         * modules/regex (Depends-on): Add mempcpy.
6453
6454 2007-01-31  Bruno Haible  <bruno@clisp.org>
6455
6456         New module description field 'Link'.
6457         * gnulib-tool (func_usage): Document --extract-link-directive.
6458         (sed_extract_prog): Recognize 'Link' directive.
6459         (func_get_link_directive): New function.
6460         (func_import): Show summary of link directives.
6461         Handle --extract-link-directive option.
6462         * modules/acl (Link): New section.
6463         * modules/clock-time (Link): New section.
6464         * modules/euidaccess (Link): New section.
6465         * modules/gettext (Link): New section.
6466         * modules/iconv (Link): New section.
6467         * modules/lock (Link): New section.
6468         * modules/nanosleep (Link): New section.
6469         * modules/readline (Link): New section.
6470
6471 2007-01-27  Bruno Haible  <bruno@clisp.org>
6472
6473         Enforce the use of gnulib modules for unportable <string.h> functions.
6474         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
6475         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
6476         (gl_HEADER_STRING_H_BODY): Require it.
6477         * lib/string_.h: If the gnulib module XYZ is not present, redefine
6478         the symbol XYZ to one that gives a link error.
6479         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
6480         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
6481         * modules/mempcpy (configure.ac): Likewise.
6482         * modules/memrchr (configure.ac): Likewise.
6483         * modules/stpcpy (configure.ac): Likewise.
6484         * modules/stpncpy (configure.ac): Likewise.
6485         * modules/strcase (configure.ac): Likewise.
6486         * modules/strcasestr (configure.ac): Likewise.
6487         * modules/strchrnul (configure.ac): Likewise.
6488         * modules/strdup (configure.ac): Likewise.
6489         * modules/strndup (configure.ac): Likewise.
6490         * modules/strnlen (configure.ac): Likewise.
6491         * modules/strpbrk (configure.ac): Likewise.
6492         * modules/strsep (configure.ac): Likewise.
6493         * modules/strstr (configure.ac): Likewise.
6494         * modules/strtok_r (configure.ac): Likewise.
6495
6496 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
6497
6498         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
6499
6500 2007-01-30  Jim Meyering  <jim@meyering.net>
6501
6502         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
6503
6504 2007-01-29  Bruno Haible  <bruno@clisp.org>
6505
6506         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
6507         * lib/execute.c: Likewise.
6508         * lib/pipe.c: Likewise.
6509         * lib/printf-args.h: Likewise.
6510         * lib/printf-args.c: Likewise.
6511         * lib/printf-parse.c: Likewise.
6512         * lib/vasnprintf.c: Likewise.
6513
6514 2007-01-29  Eric Blake  <ebb9@byu.net>
6515
6516         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
6517         declaration.
6518
6519 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
6520
6521         * lib/strptime.h (strptime): Use 'restrict' for args where
6522         POSIX requires this.
6523         * lib/strptime.c (strptime): Likewise.
6524         Change license notice from LGPL to GPL, since gnulib-tool will
6525         change this as needed.
6526         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
6527         defined.
6528         Include "strptime.h" first, to check interface.
6529         Do not #undef _LIBC and _NL_CURRENT.
6530         Do not include <stdlib.h>; no longer needed.
6531         Include "time_r.h" and declare ptime_locale_status
6532         only if _LIBC is not defined.
6533         (__P): Remove unused macro.
6534         (match_string): Bring back glibc version, but use it only if _LIBC
6535         is defined.
6536         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
6537         Remove unnecessary assertion and abort() call.
6538         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
6539         * m4/strptime.m4: Fix serial number comment.
6540         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
6541         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
6542         (Depends-on): Add time_r.
6543
6544 2007-01-29  Bruno Haible  <bruno@clisp.org>
6545
6546         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
6547         strptime.
6548         * modules/strptime (Depends-on): Add stdbool.
6549         * lib/strptime.h: Include <time.h> always. Add comments.
6550
6551 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
6552
6553         * modules/strptime: New file.
6554         * lib/strptime.h: New file.
6555         * lib/strptime.c: New file.
6556         * m4/strptime.m4: New file.
6557
6558 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
6559
6560         * MODULES.html.sh: New module mpsort.
6561         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
6562
6563         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
6564         a circularity problem with HP-UX ia64 reported by Bob Proulx in
6565         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
6566         All uses changed.
6567         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
6568         All uses changed.
6569         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
6570         to _Restrict_.
6571         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
6572         the parameter matches the prototype.
6573
6574 2007-01-28  Jim Meyering  <jim@meyering.net>
6575
6576         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
6577         sys/time.h here, reverting that part of the previous patch:
6578         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
6579
6580 2007-01-28  Bruno Haible  <bruno@clisp.org>
6581
6582         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
6583         value of $(SYS_TIME_H).
6584         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
6585         remove it conditionally, too. [added by Jim Meyering]
6586         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
6587         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
6588         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
6589         GETTIMEOFDAY_REPLACEMENT to 1.
6590
6591 2007-01-28  Bruno Haible  <bruno@clisp.org>
6592
6593         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
6594         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
6595         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
6596         Set UNISTD_H instead of UNISTD_H2.
6597         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
6598
6599 2007-01-28  Bruno Haible  <bruno@clisp.org>
6600
6601         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
6602         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
6603
6604 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6605
6606         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
6607         (func_create_testdir): Ensure C locale for `grep' and `tr'
6608         character ranges.
6609         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
6610         ACLOCAL_AMFLAGS parsing state machine.
6611
6612 2007-01-27  Bruno Haible  <bruno@clisp.org>
6613
6614         * modules/unistr/base: Update.
6615
6616 2007-01-27  Bruno Haible  <bruno@clisp.org>
6617
6618         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
6619         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
6620         * modules/unistr/u32-mbtouc-unsafe: Renamed from
6621         modules/unistr/u32-mbtouc.
6622         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
6623         * lib/unistr.h: Update.
6624         * lib/linebreak.c: Update.
6625         * modules/unistr/u32-mbtouc: Renamed from
6626         modules/unistr/u32-mbtouc-safe.
6627         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
6628         * lib/unistr.h: Update.
6629         * lib/unistr/u32-to-u8.c: Update.
6630         * lib/unistr/u32-to-u16.c: Update.
6631
6632 2007-01-27  Bruno Haible  <bruno@clisp.org>
6633
6634         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
6635         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
6636         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
6637         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
6638         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
6639         * modules/unistr/u16-mbtouc-unsafe: Renamed from
6640         modules/unistr/u16-mbtouc.
6641         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
6642         * lib/unistr.h: Update.
6643         * lib/linebreak.c: Update.
6644         * modules/linebreak: Update.
6645         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
6646         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
6647         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
6648         * modules/unistr/u16-mbtouc: Renamed from
6649         modules/unistr/u16-mbtouc-safe.
6650         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
6651         * lib/unistr.h: Update.
6652         * lib/unistr/u16-to-u8.c: Update.
6653         * modules/unistr/u16-to-u8: Update.
6654         * lib/unistr/u16-to-u32.c: Update.
6655         * modules/unistr/u16-to-u32: Update.
6656
6657 2007-01-27  Bruno Haible  <bruno@clisp.org>
6658
6659         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
6660         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
6661         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
6662         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
6663         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
6664         * modules/unistr/u8-mbtouc-unsafe: Renamed from
6665         modules/unistr/u8-mbtouc.
6666         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
6667         * lib/unistr.h: Update.
6668         * lib/striconveh.c: Update.
6669         * modules/striconveh: Update.
6670         * lib/linebreak.c: Update.
6671         * modules/linebreak: Update.
6672         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
6673         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
6674         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
6675         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
6676         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
6677         * lib/unistr.h: Update.
6678         * lib/striconveh.c: Update.
6679         * modules/striconveh: Update.
6680         * lib/unistr/u8-to-u16.c: Update.
6681         * modules/unistr/u8-to-u16: Update.
6682         * lib/unistr/u8-to-u32.c: Update.
6683         * modules/unistr/u8-to-u32: Update.
6684
6685 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6686
6687         Sync from Libtool.
6688         * lib/argz.c: Do not include strings.h nor memory.h, include
6689         string.h unconditionally.  Patch by Simon Josefsson.
6690
6691 2007-01-27  Bruno Haible  <bruno@clisp.org>
6692
6693         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
6694         from gl_HEADER_STRING_H_BODY.
6695         (gl_HEADER_STRING_H_BODY): Require it.
6696         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
6697         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
6698         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
6699         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
6700         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
6701         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
6702         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
6703         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
6704         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
6705         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
6706         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
6707         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
6708         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
6709         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
6710         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
6711
6712 2007-01-27  Bruno Haible  <bruno@clisp.org>
6713
6714         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
6715         check_PROGRAMS into noinst_PROGRAMS.
6716         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
6717         check_PROGRAMS in this case.
6718         (func_import): Set for_test to false.
6719         (func_create_testdir): Set for_test to true.
6720
6721 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
6722             Bruno Haible  <bruno@clisp.org>
6723
6724         * modules/strcasestr (Files): Remove lib/strcasestr.h.
6725         (Depends-on): Add string.
6726         (Includes): Use <string.h> instead of strcasestr.h.
6727         * modules/string (Makefile.am): Also substitute the value of
6728         REPLACE_STRCASESTR.
6729         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
6730         assume strcasestr is declared in <string.h> not <strings.h>. Also
6731         set REPLACE_STRCASESTR.
6732         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
6733         REPLACE_STRCASESTR.
6734         * lib/strcasestr.h: Remove file.
6735         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
6736         * lib/string_.h (strcasestr): New declaration.
6737
6738 2007-01-27  Bruno Haible  <bruno@clisp.org>
6739
6740         * lib/string_.h: Use 'extern'.
6741
6742 2007-01-27  Jim Meyering  <jim@meyering.net>
6743
6744         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
6745         of set-but-not-used local, "q".
6746
6747         * lib/mempcpy.c: Include <config.h> before <string.h>.
6748         This fixes a compilation error on HP-UX, due to the system's
6749         "restrict"-using mempcpy prototype.
6750
6751 2007-01-26  Bruno Haible  <bruno@clisp.org>
6752
6753         Small optimization.
6754         * lib/javacomp.c: Include c-strstr.h.
6755          (is_envjavac_gcj): Use c_strstr instead of strstr.
6756         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
6757
6758 2007-01-26  Bruno Haible  <bruno@clisp.org>
6759
6760         * MODULES.html.sh (Unicode string functions): Add the new modules.
6761
6762         * modules/uniconv/u32-strconv-to-locale: New file.
6763         * lib/uniconv/u32-strconv-to-locale.c: New file.
6764
6765         * modules/uniconv/u16-strconv-to-locale: New file.
6766         * lib/uniconv/u16-strconv-to-locale.c: New file.
6767
6768         * modules/uniconv/u8-strconv-to-locale: New file.
6769         * lib/uniconv/u8-strconv-to-locale.c: New file.
6770
6771         * modules/uniconv/u32-strconv-from-locale: New file.
6772         * lib/uniconv/u32-strconv-from-locale.c: New file.
6773
6774         * modules/uniconv/u16-strconv-from-locale: New file.
6775         * lib/uniconv/u16-strconv-from-locale.c: New file.
6776
6777         * modules/uniconv/u8-strconv-from-locale: New file.
6778         * lib/uniconv/u8-strconv-from-locale.c: New file.
6779
6780         * modules/uniconv/u32-strconv-to-enc: New file.
6781         * lib/uniconv/u32-strconv-to-enc.c: New file.
6782         * modules/uniconv/u32-strconv-to-enc-tests: New file.
6783         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
6784
6785         * modules/uniconv/u16-strconv-to-enc: New file.
6786         * lib/uniconv/u16-strconv-to-enc.c: New file.
6787         * lib/uniconv/u-strconv-to-enc.h: New file.
6788         * modules/uniconv/u16-strconv-to-enc-tests: New file.
6789         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
6790
6791         * modules/uniconv/u8-strconv-to-enc: New file.
6792         * lib/uniconv/u8-strconv-to-enc.c: New file.
6793         * modules/uniconv/u8-strconv-to-enc-tests: New file.
6794         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
6795
6796         * modules/uniconv/u32-strconv-from-enc: New file.
6797         * lib/uniconv/u32-strconv-from-enc.c: New file.
6798         * modules/uniconv/u32-strconv-from-enc-tests: New file.
6799         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
6800
6801         * modules/uniconv/u16-strconv-from-enc: New file.
6802         * lib/uniconv/u16-strconv-from-enc.c: New file.
6803         * modules/uniconv/u16-strconv-from-enc-tests: New file.
6804         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
6805
6806         * modules/uniconv/u8-strconv-from-enc: New file.
6807         * lib/uniconv/u8-strconv-from-enc.c: New file.
6808         * lib/uniconv/u-strconv-from-enc.h: New file.
6809         * modules/uniconv/u8-strconv-from-enc-tests: New file.
6810         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
6811
6812         * modules/uniconv/u32-conv-from-enc: New file.
6813         * lib/uniconv/u32-conv-from-enc.c: New file.
6814         * modules/uniconv/u32-conv-from-enc-tests: New file.
6815         * tests/uniconv/test-u32-conv-from-enc.c: New file.
6816
6817         * modules/uniconv/u16-conv-from-enc: New file.
6818         * lib/uniconv/u16-conv-from-enc.c: New file.
6819         * lib/uniconv/u-conv-from-enc.h: New file.
6820         * modules/uniconv/u16-conv-from-enc-tests: New file.
6821         * tests/uniconv/test-u16-conv-from-enc.c: New file.
6822
6823         * modules/uniconv/u8-conv-from-enc: New file.
6824         * lib/uniconv/u8-conv-from-enc.c: New file.
6825         * modules/uniconv/u8-conv-from-enc-tests: New file.
6826         * tests/uniconv/test-u8-conv-from-enc.c: New file.
6827
6828         * modules/uniconv/base: New file.
6829         * lib/uniconv.h: New file.
6830
6831 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
6832
6833         * doc/gnulib-tool.texi (Initial import): Update to match current
6834         behavior with strdup module.
6835         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
6836         * lib/memmem.h: Remove; all uses removed.  This is now done
6837         by <string.h>.
6838         * lib/mempcpy.h: Likewise.
6839         * lib/memrchr.h: Likewise.
6840         * lib/stpcpy.h: Likewise.
6841         * lib/stpncpy.h: Likewise.
6842         * lib/strcase.h: Likewise.
6843         * lib/strchrnul.h: Likewise.
6844         * lib/strdup.h: Likewise.
6845         * lib/strndup.h: Likewise.
6846         * lib/strnlen.h: Likewise.
6847         * lib/strpbrk.h: Likewise.
6848         * lib/strsep.h: Likewise.
6849         * lib/strstr.h: Likewise.
6850         * lib/strtok_r.h: Likewise.
6851         * lib/string_.h: New file.
6852         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
6853         Rely on <string.h> instead.
6854         * lib/canon-host.c: Likewise.
6855         * lib/chdir-long.c: Likewise.
6856         * lib/concatpath.c: Likewise.
6857         * lib/exclude.c: Likewise.
6858         * lib/fchdir.c: Likewise.
6859         * lib/getaddrinfo.c: Likewise.
6860         * lib/getcwd.c: Likewise.
6861         * lib/getsubopt.c: Likewise.
6862         * lib/glob.c: Likewise.
6863         * lib/hard-locale.c: Likewise.
6864         * lib/iconvme.c: Likewise.
6865         * lib/javacomp.c: Likewise.
6866         * lib/mempcpy.c: Likewise.
6867         * lib/memrchr.c: Likewise.
6868         * lib/regex_internal.h: Likewise.
6869         * lib/stpncpy.c: Likewise.
6870         * lib/strcasecmp.c: Likewise.
6871         * lib/strchrnul.c: Likewise.
6872         * lib/strdup.c: Likewise.
6873         * lib/striconv.c: Likewise.
6874         * lib/striconveh.c: Likewise.
6875         * lib/striconveha.c: Likewise.
6876         * lib/strncasecmp.c: Likewise.
6877         * lib/strndup.c: Likewise.
6878         * lib/strnlen.c: Likewise.
6879         * lib/strsep.c: Likewise.
6880         * lib/strstr.c: Likewise.
6881         * lib/strtok_r.c: Likewise.
6882         * lib/userspec.c: Likewise.
6883         * lib/w32spawn.h: Likewise.
6884         * lib/xstrndup.c: Likewise.
6885         * lib/mountlist.c (strstr): Remove decl.
6886         * m4/string_h.m4: New file.
6887         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
6888         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
6889         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
6890         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
6891         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
6892         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
6893         Set REPLACE_STRCASECMP if necessary.
6894         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
6895         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
6896         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
6897         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
6898         HAVE_DECL_STRDUP if necessary.
6899         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
6900         since gl_FUNC_STRNDUP does that now.
6901         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
6902         Check for decl here...
6903         (gl_PREREQ_STRNLEN): ... not here.
6904         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
6905         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
6906         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
6907         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
6908         necessary.
6909         * modules/string: New file.
6910         * modules/memmem (Files): Remove special-purpose include file.
6911         (Depends-on): Add string.
6912         (Include): Include <string.h>, not the removed file.
6913         * modules/mempcpy: Likewise.
6914         * modules/memrchr: Likewise.
6915         * modules/stpcpy: Likewise.
6916         * modules/stpncpy: Likewise.
6917         * modules/strcase: Likewise.
6918         * modules/strchrnul: Likewise.
6919         * modules/strdup: Likewise.
6920         * modules/strndup: Likewise.
6921         * modules/strnlen: Likewise.
6922         * modules/strpbrk: Likewise.
6923         * modules/strsep: Likewise.
6924         * modules/strstr: Likewise.
6925         * modules/strtok_r: Likewise.
6926         * tests/test-dirname.c: Don't include "strdup.h", since
6927         <string.h> now suffices.
6928         * tests/test-memmem.c: Don't include "memmem.h", since
6929         <string.h> now suffices.
6930
6931 2007-01-25  Bruno Haible  <bruno@clisp.org>
6932
6933         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
6934         *resultp is 0.
6935
6936         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
6937         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
6938         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
6939         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
6940
6941         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
6942         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
6943         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
6944         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
6945         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
6946         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
6947
6948 2007-01-24  Bruno Haible  <bruno@clisp.org>
6949
6950         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
6951         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
6952         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
6953         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
6954         gl_FUNC_FTS_CORE.
6955         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
6956         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
6957         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
6958         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
6959         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
6960         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
6961         gl_FUNC_FCHOWNAT.
6962         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
6963         gl_FUNC_STRFTIME.
6964         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
6965         Reported by Ralf Wildenhues.
6966
6967 2007-01-24  Bruno Haible  <bruno@clisp.org>
6968
6969         Drop AC_REQUIRE calls that are redundant with the module dependencies.
6970         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
6971         gl_GETADDRINFO.
6972         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
6973         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
6974         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
6975
6976 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
6977
6978         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
6979         Don't use 'exit'; just return from 'main'.
6980         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
6981
6982         * lib/fnmatch_.h: Readjust white space and comments to match
6983         glibc, to avoid spurious diffs.
6984
6985 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
6986
6987         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
6988         2004-12-01 change by Jakub Jelinek, since this code won't compile
6989         if !LIBC.  Problem reported by Bob Proulx.
6990
6991 2007-01-23  Bruno Haible  <bruno@clisp.org>
6992
6993         * lib/striconveh.c: Include c-strcaseeq.h.
6994         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
6995         * modules/striconveh (Depends-on): Add c-strcaseeq.
6996
6997 2007-01-23  Bruno Haible  <bruno@clisp.org>
6998
6999         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
7000
7001         * modules/c-strcaseeq: New file.
7002         * lib/c-strcaseeq.h: New file.
7003
7004         * modules/streq: New file.
7005         * lib/streq.h: New file.
7006
7007 2007-01-23  Bruno Haible  <bruno@clisp.org>
7008
7009         * modules/striconveha-tests: New file.
7010         * tests/test-striconveha.c: New file.
7011
7012         * lib/striconveha.h: Include <stdbool.h>.
7013         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
7014         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
7015         (mem_iconveha_notranslit): Renamed from mem_iconveha.
7016         (mem_iconveha): New function.
7017         (str_iconveha_notranslit): Renamed from str_iconveha.
7018         (str_iconveha): New function.
7019         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
7020         c-strcase.
7021
7022 2007-01-23  Bruno Haible  <bruno@clisp.org>
7023
7024         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
7025         encodings without forgiving before trying any encoding with handler.
7026         (str_iconveha): Try all encodings without forgiving before trying any
7027         encoding with handler.
7028
7029 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
7030
7031         Import the following changes from libc.
7032
7033         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
7034
7035         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
7036
7037         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
7038
7039         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
7040         normal_bracket label.
7041
7042         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
7043
7044         [BZ #361]
7045         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
7046         to normal_bracket after fetching the next character.
7047
7048 2007-01-22  Bruno Haible  <bruno@clisp.org>
7049
7050         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
7051         argument.
7052         * lib/striconveh.c (iconv_carefully_1): New function.
7053         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
7054         argument.
7055         (str_cd_iconveh): Update.
7056         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
7057         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
7058         * tests/test-striconveh.c (MAGIC): New macro.
7059         (new_offsets): New function.
7060         (main): Test call with and without offsets.
7061
7062 2007-01-22  Bruno Haible  <bruno@clisp.org>
7063
7064         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
7065         * modules/sys_select (Makefile.am): Likewise.
7066         * modules/sys_socket (Makefile.am): Likewise.
7067         * modules/sys_time (Makefile.am): Likewise.
7068
7069 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
7070
7071         * modules/gettimeofday (License): Change from GPL to LGPL, since
7072         gettimeofday is a library function.
7073
7074 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
7075
7076         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
7077
7078 2007-01-21  Bruno Haible  <bruno@clisp.org>
7079
7080         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
7081
7082 2007-01-21  Bruno Haible  <bruno@clisp.org>
7083
7084         * modules/striconveha: New file.
7085         * lib/striconveha.h: New file.
7086         * lib/striconveha.c: New file.
7087         * MODULES.html.sh (Internationalization functions): Add striconveha.
7088         * lib/striconv.c (str_iconv): Optimize the case of an empty input
7089         string.
7090         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
7091
7092 2007-01-21  Bruno Haible  <bruno@clisp.org>
7093
7094         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
7095         * lib/striconveh.c (str_iconveh): Likewise.
7096
7097 2007-01-21  Bruno Haible  <bruno@clisp.org>
7098
7099         * lib/striconveh.h (mem_iconveh): New declaration.
7100         * lib/striconveh.c (mem_iconveh): New function.
7101         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
7102
7103 2007-01-21  Bruno Haible  <bruno@clisp.org>
7104
7105         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
7106
7107         * lib/striconveh.h (mem_cd_iconveh): Change specification.
7108         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
7109         original result buffer.
7110         (str_cd_iconveh): Update.
7111         * tests/test-striconveh.c (main): Update.
7112
7113         * lib/striconv.h (mem_cd_iconv): Change specification.
7114         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
7115         result buffer.
7116         (str_cd_iconv): Update.
7117         * tests/test-striconv.c (main): Update.
7118
7119 2007-01-21  Bruno Haible  <bruno@clisp.org>
7120
7121         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
7122
7123 2007-01-20  Jim Meyering  <jim@meyering.net>
7124
7125         * lib/userspec.c (parse_with_separator): If a user or group string
7126         starts with "+", skip the corresponding name-to-ID look-up, since
7127         such a look-up must fail: user and group names may not include "+".
7128
7129 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
7130
7131         * lib/poll.c: Include sys/time.h and time.h unconditionally,
7132         since we now assume the sys_time module.
7133         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
7134         check for sys/time.h; no longer needed.
7135         * modules/poll (Depends-on): Depend on sys_time.
7136
7137 2007-01-18  Bruno Haible  <bruno@clisp.org>
7138
7139         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
7140         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
7141
7142         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
7143         gettimeofday.
7144
7145         * tests/test-gettimeofday.c: Include <time.h>.
7146         (dummy): Remove variable.
7147
7148         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
7149         gl_HEADER_SYS_TIME_H.
7150         (gl_HEADER_SYS_TIME_H): New macro.
7151
7152         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
7153         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7154         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
7155         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
7156         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7157         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
7158         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
7159         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7160         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
7161         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
7162         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7163
7164         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
7165         last change; it caused a compilation error when cross-compiling to
7166         Cygwin.
7167
7168 2007-01-18  Jim Meyering  <jim@meyering.net>
7169
7170         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
7171         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
7172         than the race-prone "test -d sys || mkdir sys".
7173         (configure.ac): Use AC_PROG_MKDIR_P.
7174         * modules/sys_select: Likewise.
7175         * modules/sys_socket: Likewise.
7176         * modules/sys_time: Likewise.
7177
7178 2007-01-18  Eric Blake  <ebb9@byu.net>
7179
7180         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
7181         replace gettimeofday.
7182         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
7183         name, to avoid infinite recursion.
7184
7185 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
7186
7187         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
7188         module sys_time.
7189         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
7190         assume timespec.h defines struct timeval.
7191         * lib/settime.c: Likewise.
7192         * lib/utimens.c: Likewise.
7193         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
7194         since we now assume the gettimeofday module.
7195         * lib/tempname.c (__gen_tempname): Likewise.
7196         * lib/gettimeofday.h: Remove.
7197         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
7198         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
7199         Include <time.h>, for 'time()'.
7200         (localtime_buffer_addr): Also use this workaround if
7201         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
7202         to simplify the uses.  All uses changed.
7203         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
7204         that #undef is inside {}, and 'const' follows type name consistently.
7205         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
7206         (gettimeofday): Do not use the maximum possible value for
7207         tv->tv_usec, since that might break usages other than ls.c.
7208         Instead, we'll leave ls.c alone.  This undoes today's patch
7209         by Bruno.  Add a compile-time warning for 1s-clock resolution;
7210         we've never observed the problem but might as well keep the
7211         canary.
7212         * lib/nanosleep.c: Include timespec.h first, for interface check.
7213         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
7214         now assume the sys_time module.
7215         * lib/tempname.c: Likewise.
7216         * lib/timespec.h: Likewise.
7217         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
7218         needed.
7219         * lib/strftime.c: Likewise.
7220         * lib/timespec.h: Likewise.
7221         * lib/posixtm.c: Include posixtm.h first, for interface check.
7222         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
7223         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
7224         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
7225         * lib/sys_time_.h: New file.
7226         * lib/timespec.h (struct timespec): Use long int, not long.
7227         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
7228         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
7229         Remove obsolescent call to AC_HEADER_TIME.
7230         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
7231         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7232         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
7233         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
7234         Likewise.
7235         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
7236         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
7237         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
7238         into the sys_time module.  Check for gettimeofday just once.
7239         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
7240         for gettimeofday signature to just check the signature.  Merely
7241         compile it, since linking doesn't test signature.  Improve test for
7242         whether gettimeofday.o is actually needed.
7243         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
7244         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
7245         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
7246         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7247         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
7248         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
7249         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
7250         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
7251         than worrying about sys/time.h.
7252         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
7253         Don't bother worrying about TIME_WITH_SYS_TIME.
7254         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
7255         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
7256         * m4/sys_time_h.m4: New file.
7257         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
7258         Don't include sys/time.h.  Return from main rather than exiting.
7259         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
7260         all uses changed.
7261         * modules/gethrxtime (Depends-on): Add sys_time.
7262         * modules/gettime (Depends-on): Likewise.
7263         * modules/gettimeofday (Depends-on): Likewise.
7264         * modules/nanosleep (Depends-on): Likewise.
7265         * modules/settime (Depends-on): Likewise.
7266         * modules/tempname (Depends-on): Likewise.
7267         * modules/utimens (Depends-on): Likewise.
7268         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
7269         (Include:) Change back to <sys/time.h>.
7270         (Maintainer:) Add self.
7271         * modules/sys_time: New file.
7272         * modules/tempname (Depends-on): Add gettimeofday.
7273         * tests/test-gettimeofday.c: Include <sys/time.h>
7274         rather than gettimeofday.h.
7275
7276 2007-01-17  Bruno Haible  <bruno@clisp.org>
7277
7278         * gnulib-tool (func_get_license): Revert last patch. Instead, let
7279         the license default to GPL.
7280         (func_create_testdir): Don't complain if a module is LGPL and its
7281         tests module depends on GPLed modules.
7282
7283 2007-01-17  Bruno Haible  <bruno@clisp.org>
7284
7285         * lib/gettimeofday.c (gettimeofday): Add code for the case
7286         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
7287         maximum possible value for tv->tv_usec, rather than the minimum one.
7288
7289 2005-10-08  Martin Lambers  <marlam@marlam.de>
7290 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
7291 2007-01-16  Bruno Haible  <bruno@clisp.org>
7292
7293         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
7294         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
7295         gl_FUNC_GETTIMEOFDAY.
7296         (Include): Add gettimeofday.h.
7297         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
7298         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
7299         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
7300         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
7301         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
7302         * lib/gettimeofday.h: New file.
7303         * lib/gettimeofday.c: Include <sys/timeb.h>.
7304         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
7305         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7306         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
7307         fall back on time().
7308
7309         * tests/test-gettimeofday.c: New file.
7310         * modules/gettimeofday-tests: New file.
7311
7312 2007-01-16  Eric Blake  <ebb9@byu.net>
7313
7314         * modules/fnmatch (Depends-on): Depend on wchar.
7315         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
7316         * m4/fnmatch.m4: Likewise.
7317         * modules/mbchar (Makefile.am): Assume <wchar.h>.
7318         * m4/mbchar.m4: Likewise.
7319         * modules/mbswidth (Depends-on): Depend on wchar.
7320         * lib/mbswidth.c: Assume <wchar.h>.
7321         * m4/mbswidth.m4: Likewise.
7322         * modules/quotearg (Depends-on): Depend on wchar.
7323         * lib/quotearg.c: Assume <wchar.h>.
7324         * m4/quotearg.m4: Likewise.
7325         * modules/regex (Depends-on): Depend on wchar.
7326         * lib/regex_internal.h: Assume <wchar.h>.
7327         * m4/regex.m4: Likewise.
7328         * modules/stdint (Depends-on): Depend on wchar.
7329         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
7330         * m4/stdint.m4: Likewise.
7331         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
7332         * modules/strftime (Depends-on): Depend on wchar.
7333         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
7334         * modules/strtol (Depends-on): Depend on wchar.
7335         * lib/strtol.c: Assume <wchar.h>.
7336         * modules/wcwidth (Depends-on): Depend on wchar.
7337         * lib/wcwidth.h: Assume <wchar.h>.
7338         * m4/wcwidth.m4: Likewise.
7339
7340 2007-01-16  Bruno Haible  <bruno@clisp.org>
7341
7342         * modules/csharpexec-script: New, created from...
7343         * modules/csharpexec: ... this.
7344
7345 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
7346
7347         * modules/javaexec-script: New, created from...
7348         * modules/javaexec: ... this.
7349
7350 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
7351
7352         * modules/poll (Dependencies): Add sys_select.
7353
7354 2007-01-15  Jim Meyering  <jim@meyering.net>
7355
7356         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
7357         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
7358         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
7359         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
7360
7361 2007-01-15  Bruno Haible  <bruno@clisp.org>
7362
7363         * modules/striconveh: New file.
7364         * lib/striconveh.h: New file.
7365         * lib/striconveh.c: New file.
7366         * MODULES.html.sh (Internationalization functions): Add striconveh.
7367
7368         * modules/striconveh-tests: New file.
7369         * tests/test-striconveh.c: New file.
7370
7371 2007-01-15  Bruno Haible  <bruno@clisp.org>
7372
7373         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
7374         not from GNU libiconv or GNU libc.
7375
7376 2007-01-15  Bruno Haible  <bruno@clisp.org>
7377
7378         * doc/gnulib-intro.texi (Copyright): Explain the different license
7379         terms for module descriptions, autoconf macros, tests, documentation.
7380
7381 2007-01-14  Bruno Haible  <bruno@clisp.org>
7382
7383         * modules/striconv-tests: New file.
7384         * tests/test-striconv.c: New file.
7385
7386 2007-01-14  Bruno Haible  <bruno@clisp.org>
7387
7388         * modules/iconv-tests: New file.
7389         * tests/test-iconv.c: New file.
7390
7391 2007-01-14  Bruno Haible  <bruno@clisp.org>
7392
7393         * gnulib-tool (func_get_license): For test modules, use the license of
7394         the main module.
7395
7396 2007-01-14  Bruno Haible  <bruno@clisp.org>
7397
7398         * modules/iconv (Include): Clarify that <iconv.h> can only be included
7399         if iconv is found to exist.
7400
7401 2007-01-14  Bruno Haible  <bruno@clisp.org>
7402
7403         * modules/c-ctype-tests: New file.
7404         * tests/test-c-ctype.c: New file.
7405
7406 2007-01-14  Bruno Haible  <bruno@clisp.org>
7407
7408         * modules/binary-io-tests: New file.
7409         * tests/test-binary-io.sh: New file.
7410         * tests/test-binary-io.c: New file.
7411
7412 2007-01-14  Bruno Haible  <bruno@clisp.org>
7413
7414         * modules/array-oset-tests: New file.
7415         * tests/test-array_oset.c: New file.
7416
7417 2007-01-14  Bruno Haible  <bruno@clisp.org>
7418
7419         * modules/array-list-tests: New file.
7420         * tests/test-array_list.c: New file.
7421
7422 2007-01-14  Bruno Haible  <bruno@clisp.org>
7423
7424         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
7425         and make.
7426         Reported by Simon Josefsson in
7427         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
7428
7429 2007-01-14  Bruno Haible  <bruno@clisp.org>
7430
7431         * modules/allocsa-tests: New file.
7432         * tests/test-allocsa.c: New file.
7433
7434 2007-01-14  Bruno Haible  <bruno@clisp.org>
7435
7436         * modules/fchdir (Depends-on): Add absolute-header.
7437         * modules/unistd (Depends-on): Likewise.
7438
7439 2006-12-30  Bruno Haible  <bruno@clisp.org>
7440
7441         * modules/fchdir: New file.
7442         * modules/unistd (Files): Add lib/unistd_.h.
7443         (Makefile.am): Generate unistd.h from unistd_.h.
7444         * lib/fchdir.c: New file.
7445         * lib/dirent_.h: New file.
7446         * lib/unistd_.h: New file.
7447         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
7448         * m4/fchdir.m4: New file.
7449         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
7450         (gl_HEADER_UNISTD): Invoke it.
7451         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
7452         function.
7453         * lib/backupfile.c (opendir, closedir): Undefine.
7454         * lib/chown.c (open, close): Undefine.
7455         * lib/clean-temp.c (open, close): Undefine.
7456         * lib/copy-file.c (open, close): Undefine.
7457         * lib/execute.c (open, close): Undefine.
7458         * lib/fsusage.c (open, close): Undefine.
7459         * lib/gc-gnulib.c (open, close): Undefine.
7460         * lib/getcwd.c (opendir, closedir): Undefine.
7461         * lib/glob.c (opendir, closedir): Undefine.
7462         * lib/javacomp.c (open, close): Undefine.
7463         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
7464         * lib/openat-proc.c (open, close): Undefine.
7465         * lib/pagealign_alloc.c (open, close): Undefine.
7466         * lib/pipe.c (open, close): Undefine.
7467         * lib/progreloc.c (open, close): Undefine.
7468         * lib/savedir.c (opendir, closedir): Undefine.
7469         * lib/utime.c (open, close): Undefine.
7470         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
7471
7472 2007-01-10  Bruno Haible  <bruno@clisp.org>
7473
7474         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
7475
7476 2007-01-12  Eric Blake  <ebb9@byu.net>
7477
7478         Provide a robust <wchar.h>.  Further simplifications are now
7479         possible in other modules, but not included here.
7480         * modules/wchar: New module.
7481         * m4/wchar.m4: New file.
7482         * lib/wchar_.h: Likewise.
7483         * modules/mbchar (Depends-on): Depend on wchar, as the first use
7484         of the new module.
7485         * MODULES.html.sh (Extended multibyte and wide character utilities):
7486         New section.
7487
7488 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
7489
7490         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
7491         to a reasonable default for memory allocation.
7492         (xreadlink): Don't allocate a huge buffer, to work around a buggy
7493         file system that reports garbage st_size values for symlinks.
7494         Problem reported by Liyang Hu.
7495
7496 2007-01-11  Simon Josefsson  <simon@josefsson.org>
7497
7498         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
7499         Emacs .#* auto-save files).
7500
7501 2007-01-11  Bruno Haible  <bruno@clisp.org>
7502
7503         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
7504         directory.
7505
7506 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
7507
7508         Use @...@ consistently in lib/wctype_.h.
7509         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
7510         on it being set to 1 or 0.
7511         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
7512         go back to AC_SUBSTing it.
7513         * modules/wctype (Makefile.am): Undo previous change.
7514
7515 2007-01-10  Eric Blake  <ebb9@byu.net>
7516
7517         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
7518         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
7519         * modules/wctype (Makefile.am): Likewise.
7520         Reported by Chris McGuire.
7521
7522 2007-01-10  Jim Meyering  <jim@meyering.net>
7523
7524         fts.c: a small readability/maintainability improvement
7525         * lib/fts.c (fts_read): Make this code slightly more readable and
7526         maintainable by hoisting the "sp->fts_cur = p" assignments to
7527         immediately follow the statements that set P.  Derived from
7528         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
7529
7530 2007-01-10  Eric Blake  <ebb9@byu.net>
7531
7532         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
7533         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
7534         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
7535         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
7536         Reported by Chris McGuire.
7537
7538 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7539
7540         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
7541         in sed script.
7542
7543 2007-01-09  Bruno Haible  <bruno@clisp.org>
7544
7545         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
7546         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
7547         variables.
7548         (func_module): Use them.
7549
7550 2007-01-09  Bruno Haible  <bruno@clisp.org>
7551
7552         * modules/unistr/base: New file.
7553         * lib/unistr.h: New file.
7554
7555         * modules/unistr/u8-to-u16: New file.
7556         * lib/unistr/u8-to-u16.c: New file.
7557
7558         * modules/unistr/u8-to-u32: New file.
7559         * lib/unistr/u8-to-u32.c: New file.
7560
7561         * modules/unistr/u16-to-u8: New file.
7562         * lib/unistr/u16-to-u8.c: New file.
7563
7564         * modules/unistr/u16-to-u32: New file.
7565         * lib/unistr/u16-to-u32.c: New file.
7566
7567         * modules/unistr/u32-to-u8: New file.
7568         * lib/unistr/u32-to-u8.c: New file.
7569
7570         * modules/unistr/u32-to-u16: New file.
7571         * lib/unistr/u32-to-u16.c: New file.
7572
7573         * modules/unistr/u8-check: New file.
7574         * modules/unistr/u16-check: New file.
7575         * modules/unistr/u32-check: New file.
7576         * lib/unistr/u8-check.c: New file.
7577         * lib/unistr/u16-check.c: New file.
7578         * lib/unistr/u32-check.c: New file.
7579
7580         * modules/unistr/u8-chr: New file.
7581         * modules/unistr/u16-chr: New file.
7582         * modules/unistr/u32-chr: New file.
7583         * lib/unistr/u8-chr.c: New file.
7584         * lib/unistr/u16-chr.c: New file.
7585         * lib/unistr/u32-chr.c: New file.
7586
7587         * modules/unistr/u8-cmp: New file.
7588         * modules/unistr/u16-cmp: New file.
7589         * modules/unistr/u32-cmp: New file.
7590         * lib/unistr/u8-cmp.c: New file.
7591         * lib/unistr/u16-cmp.c: New file.
7592         * lib/unistr/u32-cmp.c: New file.
7593
7594         * modules/unistr/u8-cpy: New file.
7595         * modules/unistr/u16-cpy: New file.
7596         * modules/unistr/u32-cpy: New file.
7597         * lib/unistr/u8-cpy.c: New file.
7598         * lib/unistr/u16-cpy.c: New file.
7599         * lib/unistr/u32-cpy.c: New file.
7600         * lib/unistr/u-cpy.h: New file.
7601
7602         * modules/unistr/u8-cpy-alloc: New file.
7603         * modules/unistr/u16-cpy-alloc: New file.
7604         * modules/unistr/u32-cpy-alloc: New file.
7605         * lib/unistr/u8-cpy-alloc.c: New file.
7606         * lib/unistr/u16-cpy-alloc.c: New file.
7607         * lib/unistr/u32-cpy-alloc.c: New file.
7608         * lib/unistr/u-cpy-alloc.h: New file.
7609
7610         * modules/unistr/u8-endswith: New file.
7611         * modules/unistr/u16-endswith: New file.
7612         * modules/unistr/u32-endswith: New file.
7613         * lib/unistr/u8-endswith.c: New file.
7614         * lib/unistr/u16-endswith.c: New file.
7615         * lib/unistr/u32-endswith.c: New file.
7616         * lib/unistr/u-endswith.h: New file.
7617
7618         * modules/unistr/u8-mblen: New file.
7619         * modules/unistr/u16-mblen: New file.
7620         * modules/unistr/u32-mblen: New file.
7621         * lib/unistr/u8-mblen.c: New file.
7622         * lib/unistr/u16-mblen.c: New file.
7623         * lib/unistr/u32-mblen.c: New file.
7624
7625         * modules/unistr/u8-mbtouc: New file.
7626         * modules/unistr/u16-mbtouc: New file.
7627         * modules/unistr/u32-mbtouc: New file.
7628         * lib/unistr/u8-mbtouc.c: New file.
7629         * lib/unistr/u16-mbtouc.c: New file.
7630         * lib/unistr/u32-mbtouc.c: New file.
7631
7632         * modules/unistr/u8-mbtouc-safe: New file.
7633         * modules/unistr/u16-mbtouc-safe: New file.
7634         * modules/unistr/u32-mbtouc-safe: New file.
7635         * lib/unistr/u8-mbtouc-safe.c: New file.
7636         * lib/unistr/u16-mbtouc-safe.c: New file.
7637         * lib/unistr/u32-mbtouc-safe.c: New file.
7638
7639         * modules/unistr/u8-move: New file.
7640         * modules/unistr/u16-move: New file.
7641         * modules/unistr/u32-move: New file.
7642         * lib/unistr/u8-move.c: New file.
7643         * lib/unistr/u16-move.c: New file.
7644         * lib/unistr/u32-move.c: New file.
7645         * lib/unistr/u-move.h: New file.
7646
7647         * modules/unistr/u8-next: New file.
7648         * modules/unistr/u16-next: New file.
7649         * modules/unistr/u32-next: New file.
7650         * lib/unistr/u8-next.c: New file.
7651         * lib/unistr/u16-next.c: New file.
7652         * lib/unistr/u32-next.c: New file.
7653
7654         * modules/unistr/u8-prev: New file.
7655         * modules/unistr/u16-prev: New file.
7656         * modules/unistr/u32-prev: New file.
7657         * lib/unistr/u8-prev.c: New file.
7658         * lib/unistr/u16-prev.c: New file.
7659         * lib/unistr/u32-prev.c: New file.
7660
7661         * modules/unistr/u8-set: New file.
7662         * modules/unistr/u16-set: New file.
7663         * modules/unistr/u32-set: New file.
7664         * lib/unistr/u8-set.c: New file.
7665         * lib/unistr/u16-set.c: New file.
7666         * lib/unistr/u32-set.c: New file.
7667         * lib/unistr/u-set.h: New file.
7668
7669         * modules/unistr/u8-startswith: New file.
7670         * modules/unistr/u16-startswith: New file.
7671         * modules/unistr/u32-startswith: New file.
7672         * lib/unistr/u8-startswith.c: New file.
7673         * lib/unistr/u16-startswith.c: New file.
7674         * lib/unistr/u32-startswith.c: New file.
7675         * lib/unistr/u-startswith.h: New file.
7676
7677         * modules/unistr/u8-stpcpy: New file.
7678         * modules/unistr/u16-stpcpy: New file.
7679         * modules/unistr/u32-stpcpy: New file.
7680         * lib/unistr/u8-stpcpy.c: New file.
7681         * lib/unistr/u16-stpcpy.c: New file.
7682         * lib/unistr/u32-stpcpy.c: New file.
7683         * lib/unistr/u-stpcpy.h: New file.
7684
7685         * modules/unistr/u8-stpncpy: New file.
7686         * modules/unistr/u16-stpncpy: New file.
7687         * modules/unistr/u32-stpncpy: New file.
7688         * lib/unistr/u8-stpncpy.c: New file.
7689         * lib/unistr/u16-stpncpy.c: New file.
7690         * lib/unistr/u32-stpncpy.c: New file.
7691         * lib/unistr/u-stpncpy.h: New file.
7692
7693         * modules/unistr/u8-strcat: New file.
7694         * modules/unistr/u16-strcat: New file.
7695         * modules/unistr/u32-strcat: New file.
7696         * lib/unistr/u8-strcat.c: New file.
7697         * lib/unistr/u16-strcat.c: New file.
7698         * lib/unistr/u32-strcat.c: New file.
7699         * lib/unistr/u-strcat.h: New file.
7700
7701         * modules/unistr/u8-strchr: New file.
7702         * modules/unistr/u16-strchr: New file.
7703         * modules/unistr/u32-strchr: New file.
7704         * lib/unistr/u8-strchr.c: New file.
7705         * lib/unistr/u16-strchr.c: New file.
7706         * lib/unistr/u32-strchr.c: New file.
7707
7708         * modules/unistr/u8-strcmp: New file.
7709         * modules/unistr/u16-strcmp: New file.
7710         * modules/unistr/u32-strcmp: New file.
7711         * lib/unistr/u8-strcmp.c: New file.
7712         * lib/unistr/u16-strcmp.c: New file.
7713         * lib/unistr/u32-strcmp.c: New file.
7714
7715         * modules/unistr/u8-strcpy: New file.
7716         * modules/unistr/u16-strcpy: New file.
7717         * modules/unistr/u32-strcpy: New file.
7718         * lib/unistr/u8-strcpy.c: New file.
7719         * lib/unistr/u16-strcpy.c: New file.
7720         * lib/unistr/u32-strcpy.c: New file.
7721         * lib/unistr/u-strcpy.h: New file.
7722
7723         * modules/unistr/u8-strcspn: New file.
7724         * modules/unistr/u16-strcspn: New file.
7725         * modules/unistr/u32-strcspn: New file.
7726         * lib/unistr/u8-strcspn.c: New file.
7727         * lib/unistr/u16-strcspn.c: New file.
7728         * lib/unistr/u32-strcspn.c: New file.
7729         * lib/unistr/u-strcspn.h: New file.
7730
7731         * modules/unistr/u8-strdup: New file.
7732         * modules/unistr/u16-strdup: New file.
7733         * modules/unistr/u32-strdup: New file.
7734         * lib/unistr/u8-strdup.c: New file.
7735         * lib/unistr/u16-strdup.c: New file.
7736         * lib/unistr/u32-strdup.c: New file.
7737         * lib/unistr/u-strdup.h: New file.
7738
7739         * modules/unistr/u8-strlen: New file.
7740         * modules/unistr/u16-strlen: New file.
7741         * modules/unistr/u32-strlen: New file.
7742         * lib/unistr/u8-strlen.c: New file.
7743         * lib/unistr/u16-strlen.c: New file.
7744         * lib/unistr/u32-strlen.c: New file.
7745         * lib/unistr/u-strlen.h: New file.
7746
7747         * modules/unistr/u8-strmblen: New file.
7748         * modules/unistr/u16-strmblen: New file.
7749         * modules/unistr/u32-strmblen: New file.
7750         * lib/unistr/u8-strmblen.c: New file.
7751         * lib/unistr/u16-strmblen.c: New file.
7752         * lib/unistr/u32-strmblen.c: New file.
7753
7754         * modules/unistr/u8-strmbtouc: New file.
7755         * modules/unistr/u16-strmbtouc: New file.
7756         * modules/unistr/u32-strmbtouc: New file.
7757         * lib/unistr/u8-strmbtouc.c: New file.
7758         * lib/unistr/u16-strmbtouc.c: New file.
7759         * lib/unistr/u32-strmbtouc.c: New file.
7760
7761         * modules/unistr/u8-strncat: New file.
7762         * modules/unistr/u16-strncat: New file.
7763         * modules/unistr/u32-strncat: New file.
7764         * lib/unistr/u8-strncat.c: New file.
7765         * lib/unistr/u16-strncat.c: New file.
7766         * lib/unistr/u32-strncat.c: New file.
7767         * lib/unistr/u-strncat.h: New file.
7768
7769         * modules/unistr/u8-strncmp: New file.
7770         * modules/unistr/u16-strncmp: New file.
7771         * modules/unistr/u32-strncmp: New file.
7772         * lib/unistr/u8-strncmp.c: New file.
7773         * lib/unistr/u16-strncmp.c: New file.
7774         * lib/unistr/u32-strncmp.c: New file.
7775
7776         * modules/unistr/u8-strncpy: New file.
7777         * modules/unistr/u16-strncpy: New file.
7778         * modules/unistr/u32-strncpy: New file.
7779         * lib/unistr/u8-strncpy.c: New file.
7780         * lib/unistr/u16-strncpy.c: New file.
7781         * lib/unistr/u32-strncpy.c: New file.
7782         * lib/unistr/u-strncpy.h: New file.
7783
7784         * modules/unistr/u8-strnlen: New file.
7785         * modules/unistr/u16-strnlen: New file.
7786         * modules/unistr/u32-strnlen: New file.
7787         * lib/unistr/u8-strnlen.c: New file.
7788         * lib/unistr/u16-strnlen.c: New file.
7789         * lib/unistr/u32-strnlen.c: New file.
7790         * lib/unistr/u-strnlen.h: New file.
7791
7792         * modules/unistr/u8-strpbrk: New file.
7793         * modules/unistr/u16-strpbrk: New file.
7794         * modules/unistr/u32-strpbrk: New file.
7795         * lib/unistr/u8-strpbrk.c: New file.
7796         * lib/unistr/u16-strpbrk.c: New file.
7797         * lib/unistr/u32-strpbrk.c: New file.
7798         * lib/unistr/u-strpbrk.h: New file.
7799
7800         * modules/unistr/u8-strrchr: New file.
7801         * modules/unistr/u16-strrchr: New file.
7802         * modules/unistr/u32-strrchr: New file.
7803         * lib/unistr/u8-strrchr.c: New file.
7804         * lib/unistr/u16-strrchr.c: New file.
7805         * lib/unistr/u32-strrchr.c: New file.
7806
7807         * modules/unistr/u8-strspn: New file.
7808         * modules/unistr/u16-strspn: New file.
7809         * modules/unistr/u32-strspn: New file.
7810         * lib/unistr/u8-strspn.c: New file.
7811         * lib/unistr/u16-strspn.c: New file.
7812         * lib/unistr/u32-strspn.c: New file.
7813         * lib/unistr/u-strspn.h: New file.
7814
7815         * modules/unistr/u8-strstr: New file.
7816         * modules/unistr/u16-strstr: New file.
7817         * modules/unistr/u32-strstr: New file.
7818         * lib/unistr/u8-strstr.c: New file.
7819         * lib/unistr/u16-strstr.c: New file.
7820         * lib/unistr/u32-strstr.c: New file.
7821         * lib/unistr/u-strstr.h: New file.
7822
7823         * modules/unistr/u8-strtok: New file.
7824         * modules/unistr/u16-strtok: New file.
7825         * modules/unistr/u32-strtok: New file.
7826         * lib/unistr/u8-strtok.c: New file.
7827         * lib/unistr/u16-strtok.c: New file.
7828         * lib/unistr/u32-strtok.c: New file.
7829         * lib/unistr/u-strtok.h: New file.
7830
7831         * modules/unistr/u8-uctomb: New file.
7832         * modules/unistr/u16-uctomb: New file.
7833         * modules/unistr/u32-uctomb: New file.
7834         * lib/unistr/u8-uctomb.c: New file.
7835         * lib/unistr/u16-uctomb.c: New file.
7836         * lib/unistr/u32-uctomb.c: New file.
7837
7838         * MODULES.html.sh (Unicode string functions): Add the new modules.
7839
7840 2007-01-08  Bruno Haible  <bruno@clisp.org>
7841
7842         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
7843         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
7844         subdirectories.
7845
7846 2007-01-08  Karl Berry  <karl@gnu.org>
7847
7848         * doc/error.texi: mention that main() fns must set program_name
7849         when progname is used.
7850
7851 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
7852
7853         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
7854         WCTYPE_H is empty, for the benefit of builds from non-distclean
7855         directories.  Problem reported by Eric Blake in
7856         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
7857
7858 2007-01-08  Bruno Haible  <bruno@clisp.org>
7859
7860         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
7861         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
7862         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
7863         PROVIDE_CANONICALIZE_FILENAME_MODE.
7864         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
7865
7866 2007-01-08  Bruno Haible  <bruno@clisp.org>
7867
7868         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
7869         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
7870         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
7871         * lib/fts.c: Likewise.
7872         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
7873
7874 2006-12-25  Bruno Haible  <bruno@clisp.org>
7875
7876         * modules/utf8-ucs4-safe: New file.
7877         * lib/utf8-ucs4-safe.h: New file.
7878         * lib/unistr/utf8-ucs4-safe.c: New file.
7879
7880         * modules/utf16-ucs4-safe: New file.
7881         * lib/utf16-ucs4-safe.h: New file.
7882         * lib/unistr/utf16-ucs4-safe.c: New file.
7883
7884         * MODULES.html.sh (Unicode string functions): Add the new modules.
7885
7886 2007-01-08  Bruno Haible  <bruno@clisp.org>
7887
7888         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
7889         (Depends-on): Add unitypes.
7890         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
7891         (u8_mbtouc_aux): Move out to separate file.
7892         (u8_mbtouc): Use ucs4_t, uint8_t types.
7893         * lib/unistr/utf8-ucs4.c: New file.
7894
7895         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
7896         (Depends-on): Add unitypes.
7897         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
7898         (u16_mbtouc_aux): Move out to separate file.
7899         (u16_mbtouc): Use ucs4_t, uint16_t types.
7900         * lib/unistr/utf16-ucs4.c: New file.
7901
7902         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
7903         (Depends-on): Add unitypes.
7904         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
7905         (u8_uctomb_aux): Move out to separate file.
7906         (u8_uctomb): Use ucs4_t, uint8_t types.
7907         * lib/unistr/ucs4-utf8.c: New file.
7908
7909         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
7910         (Depends-on): Add unitypes.
7911         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
7912         (u16_uctomb_aux): Move out to separate file.
7913         (u16_uctomb): Use ucs4_t, uint16_t types.
7914         * lib/unistr/ucs4-utf16.c: New file.
7915
7916 2006-12-25  Bruno Haible  <bruno@clisp.org>
7917
7918         * modules/unitypes: New file.
7919         * lib/unitypes.h: New file.
7920         * MODULES.html.sh (func_all_modules): New section "Unicode string
7921         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
7922         this section. Add unitypes.
7923
7924 2007-01-08  Bruno Haible  <bruno@clisp.org>
7925
7926         Avoid variable names that conflict with those from libtool.
7927         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
7928         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
7929         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
7930         library_names_spec to acl_library_names_spec, hardcode_* to
7931         acl_hardcode_*.
7932         Reported by Ralf Wildenhues.
7933
7934 2007-01-08  Bruno Haible  <bruno@clisp.org>
7935
7936         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
7937         definition.
7938         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
7939         definition.
7940         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
7941         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
7942         definition.
7943         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
7944         definition.
7945         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
7946         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
7947         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
7948         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
7949         definition.
7950         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
7951         definition.
7952         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
7953         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
7954         GC_USE_<algorithm>.
7955         * lib/gc-libgcrypt.c: Likewise.
7956         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
7957         * modules/gc-arctwo (configure.ac): Likewise.
7958         * modules/gc-des (configure.ac): Likewise.
7959         * modules/gc-hmac-md5 (configure.ac): Likewise.
7960         * modules/gc-hmac-sha1 (configure.ac): Likewise.
7961         * modules/gc-md2 (configure.ac): Likewise.
7962         * modules/gc-md4 (configure.ac): Likewise.
7963         * modules/gc-md5 (configure.ac): Likewise.
7964         * modules/gc-random (configure.ac): Likewise.
7965         * modules/gc-rijndael (configure.ac): Likewise.
7966         * modules/gc-sha1 (configure.ac): Likewise.
7967
7968 2007-01-08  Bruno Haible  <bruno@clisp.org>
7969
7970         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
7971         macro definition.
7972         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
7973         definition.
7974         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
7975         definition.
7976         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
7977         * modules/fcntl-safer (configure.ac): Likewise.
7978         * modules/fopen-safer (configure.ac): Likewise.
7979         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
7980         GNULIB_FWRITEERROR macro definition.
7981
7982 2007-01-08  Bruno Haible  <bruno@clisp.org>
7983
7984         * m4/gnulib-common.m4: New file.
7985         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
7986         (func_get_filelist): Add m4/gnulib-common.m4.
7987
7988 2007-01-08  Bruno Haible  <bruno@clisp.org>
7989
7990         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
7991         command.
7992
7993 2007-01-08  Jim Meyering  <jim@meyering.net>
7994
7995         Use a more robust test for a "can't happen" condition.
7996         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
7997         narrowed the st_size value.  Presuming the "can't happen" condition
7998         is true, that narrowing could conceivably convert an invalid st_size
7999         value into a valid one.  Instead, use a change based on Matthew
8000         Woehlke's original patch.
8001
8002         Slight readability improvement: use an assert-like macro
8003         in place of literal "abort ()" uses.
8004         * lib/fts.c (fts_assert): Define.
8005         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
8006         Use this macro instead of a bare 'abort'.
8007
8008 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
8009
8010         Don't worry about using IRIX 5.3's wctype.h broken definitions;
8011         simply work around them.
8012         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
8013         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
8014         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
8015         declaring.
8016         Don't bother to define as macros, since the standard doesn't require it.
8017         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
8018         longer worry about IRIX 5.3.
8019         (HAVE_WCTYPE_CTMP_BUG): Remove.
8020
8021 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8022
8023         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
8024         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
8025         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
8026         Problems reported by Georg Schwarz for IRIX 5.3.
8027
8028         * gnulib-tool (autoconf_minversion): Take the maximum version number
8029         found, not the minimum.  Problem reported by James Youngman.
8030
8031 2007-01-03  Karl Berry  <karl@gnu.org>
8032
8033         * doc/error.texi: new file, explaining interaction with progname.
8034         * doc/gnulib.texi: include it.  Update copyright.
8035
8036 2007-01-03  Simon Josefsson  <simon@josefsson.org>
8037
8038         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
8039         AC_CANONICAL_HOST, to improve autobuild outputs.
8040
8041 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
8042             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
8043
8044         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
8045         sockets, server sockets, and other file descriptors.  Count errors
8046         to compute the return value.  Reorder the code a bit to be easier
8047         to follow.  Don't set event bits that were not requested (except
8048         POLLERR and POLLHUP).
8049
8050 2007-01-01  Bruno Haible  <bruno@clisp.org>
8051
8052         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
8053
8054 2007-01-03  Jim Meyering  <jim@meyering.net>
8055
8056         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
8057
8058 2007-01-02  Bruno Haible  <bruno@clisp.org>
8059
8060         * modules/settime (Include): Require timespec.h.
8061         * modules/nanosleep (Include): Likewise.
8062
8063 2007-01-01  Bruno Haible  <bruno@clisp.org>
8064
8065         * gnulib-tool (func_emit_copyright_notice): Bump year.
8066         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
8067
8068 2007-01-01  Bruno Haible  <bruno@clisp.org>
8069
8070         Improve support for OpenBSD.
8071         * build-aux/config.rpath (libname_spec): Export.
8072         (library_names_spec): New variable. Export.
8073         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
8074         library_names_spec from the config.rpath output. Locate shared library
8075         through the name pattern in library_names_spec.
8076
8077 2007-01-01  Eric Blake  <ebb9@byu.net>
8078
8079         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
8080
8081 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
8082
8083         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
8084         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
8085         assume the C locale, and avoid an "eval" that could cause trouble.
8086         Problem with SORT reported by Bob Proulx.
8087
8088         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
8089         Define.  Trivial patch from Henning Nielsen Lund, originally
8090         sent to bug-grep@gnu.org today.
8091
8092 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
8093
8094         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
8095         struct stat.  Problem reported by Henning Nielsen Lund.
8096         * lib/acl.c: Include acl.h first, to check interface.  Don't
8097         bother to include sys/types.h and sys/stat.h again.
8098
8099 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
8100
8101         Import the following change from libc; problem reported by
8102         Sven Verdoolaege.
8103
8104         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
8105
8106         [BZ #1373]
8107         * lib/argp.h: Remove __NTH for __argp_usage inline function.
8108
8109 2006-12-28  Jim Meyering  <jim@meyering.net>
8110
8111         * build-aux/announce-gen: Do not assume that the package
8112         builds any of tar.gz, tar.bz2, and .xdelta files.
8113         Suggestion from Simon Josefsson.
8114
8115 2006-12-28  Simon Josefsson  <simon@josefsson.org>
8116
8117         * modules/announce-gen: New file.
8118
8119 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
8120
8121         * lib/mbchar.h: Just include <wctype.h>; the wctype module
8122         handles its gotchas now.
8123         * lib/mbswidth.c: Likewise.
8124         * lib/wcwidth.h: Likewise.
8125         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
8126         and iswcntrl; the wctype module does this stuff now.
8127         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
8128         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
8129         * modules/mbchar (Depends-on): Add wctype.
8130         * modules/mbswidth (Depends-on): Likewise.
8131         * modules/wcwidth (Depends-on): Likewise.
8132
8133 2006-12-27  Eric Blake  <ebb9@byu.net>
8134
8135         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
8136         module uses more than what <wctype.h> is required to provide.
8137
8138 2006-12-26  Eric Blake  <ebb9@byu.net>
8139
8140         * gnulib-tool (sed_extract_prog): Avoid space-tab.
8141
8142 2006-12-26  Eric Blake  <ebb9@byu.net>
8143
8144         * modules/absolute-header: New module.
8145         * modules/fcntl (Depends-on): Depend on it.
8146         * modules/inttypes (Depends-on): Likewise.
8147         * modules/stdint (Depends-on): Likewise.
8148         * modules/sys_stat (Depends-on): Likewise.
8149         * modules/wctype (Depends-on): Likewise.
8150         * MODULES.html.sh (Support for building libraries and
8151         executables): Document it.
8152
8153 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
8154
8155         * gnulib-tool (SED): Remove, undoing previous change.
8156         The problem was that it broke coreutils on Solaris, because
8157         "sed --posix" leaked into a makefile.
8158         (sed): New alias, if 'alias' and GNU sed.
8159
8160 2006-12-24  Jim Meyering  <jim@meyering.net>
8161
8162         Work around an fchownat bug in glibc-2.4:
8163         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
8164         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
8165         in spite of the -P option.
8166         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
8167         New macros.
8168         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
8169         * modules/openat (Files): Add lib/fchownat.c.
8170         * lib/openat.c (fchownat): Don't define here.  Move to...
8171         * lib/fchownat.c: ...this new file.
8172
8173 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
8174
8175         Fix bug reported by Bruno Haible in
8176         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
8177         where quotearg.c didn't compile on Mac OS X 10.2 because it
8178         lacks <wchar.h> and wint_t.
8179         * lib/wctype_.h (__wctype_wint_t): New type.
8180         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
8181         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
8182         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
8183         Arg is now of type __wctype_wint_t, not wint_t.
8184         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
8185         substitute HAVE_WINT_T.
8186         * modules/wctype (Files): Add m4/wint_t.m4.
8187         (wctype.h): Substitute HAVE_WINT_T.
8188
8189 2006-12-23  Bruno Haible  <bruno@clisp.org>
8190
8191         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
8192
8193 2006-12-23  Bruno Haible  <bruno@clisp.org>
8194
8195         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
8196         S_ISLNK.
8197         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
8198         mingw.
8199
8200 2006-12-22  Bruno Haible  <bruno@clisp.org>
8201
8202         * lib/copy-file.c: Include acl.h.
8203         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
8204         Close the file descriptors only after being done with copy_acl.
8205         * modules/copy-file (Depends-on): Add acl.
8206
8207 2006-12-22  Bruno Haible  <bruno@clisp.org>
8208
8209         * gnulib-tool (SED): New variable.
8210         Use $SED instead of sed everywhere.
8211
8212 2006-12-22  Bruno Haible  <bruno@clisp.org>
8213
8214         * modules/no-c++: New file.
8215         * m4/no-c++.m4: New file.
8216         * MODULES.html.sh (Support for building libraries and executables):
8217         Add no-c++.
8218
8219 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
8220
8221         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
8222         Include <limits.h>, and use its INT_MAX to rewrite the
8223         j loop so that it does not overflow 'int'.  Problem reported by
8224         Ralf Wildenhues in
8225         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
8226         Play it safe by shifting left by 1 rather than multiplying by 2,
8227         as GCC is less likely to optimize this away when the value
8228         is signed (when it assumes overflow leads to undefined behavior).
8229         Also, don't assume time_t uses two's complement.
8230
8231 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
8232
8233         * MODULES.html.sh: New module wctype.
8234         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
8235         * lib/fnmatch.c: Don't bother to include <wchar.h> before
8236         <wctype.h>, since the new wctype module should fix this.
8237         * lib/quotearg.c: Include <wctype.h> unconditionally, since
8238         the wctype module should arrange for it.
8239         * lib/regex_internal.h: Likewise.
8240         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
8241         since the wctype module should handle this now.
8242         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
8243         * modules/fnmatch (Depends-on): Add wctype.
8244         * modules/quotearg (Depends-on): Likewise.
8245         * modules/regex (Depends-on): Likewise.
8246
8247 2006-12-19  Bruno Haible  <bruno@clisp.org>
8248
8249         * lib/strdup.h [C++]: Wrap definitions in extern "C".
8250         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
8251
8252 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8253
8254         * modules/savewd (Depends-on): Fix dependency on fcntl.
8255
8256 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
8257
8258         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
8259         conforms to C99, rather than relying on the user's environment
8260         setting of STDINT_H.
8261
8262 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
8263         and Eric Blake  <ebb9@byu.net>
8264
8265         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
8266         This is more consistent with the other defines here.
8267         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
8268         Port to z/OS.  Problem reported by Paul Gilmartin.
8269         Change local vars to use gl_ prefix rather than ac_.
8270         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
8271         with other defines.
8272         * modules/double-slash-root: New module.
8273         * modules/dirname (Files): Remove m4/double-slash-root.m4.
8274         (Depends-on): Add double-slash-root.
8275         * MODULES.html.sh (File system functions): Mention new module.
8276
8277 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
8278
8279         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
8280         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
8281         This is for the benefit of gzip, which doesn't do i18n.
8282
8283 2006-12-12  Jim Meyering  <jim@meyering.net>
8284
8285         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
8286         Reported by Andreas Schwab <schwab@suse.de>.
8287
8288 2006-12-12  Bruno Haible  <bruno@clisp.org>
8289
8290         Merge these changes.
8291         2006-09-05  Bruno Haible  <bruno@clisp.org>
8292         * lib/iconvme.c (iconv_string): No need to save and restore errno when
8293         iconv_alloc succeeded.
8294         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
8295         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
8296         test for " && dest " at the end - dest is always != NULL there. Call
8297         iconv with 4xNULL arguments initially, to reset the state. Call iconv
8298         with 2xNULL arguments, also to flush the state storage. Handle the
8299         IRIX iconv behaviour. Realloc the final result, to throw away unused
8300         memory.
8301
8302 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
8303
8304         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
8305         and fchmodat unconditionally, since glibc 2.4 has them.
8306         Problem reported by Arkadiusz Miskiewicz.
8307
8308 2006-12-10  Bruno Haible  <bruno@clisp.org>
8309
8310         * gnulib-tool (func_import): Show the include files only for those
8311         modules that are copied and specified.
8312         Reported by Karl Berry.
8313
8314 2006-12-08  Jim Meyering  <jim@meyering.net>
8315
8316         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
8317         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
8318
8319         * build-aux/announce-gen: Add two new options, both optional:
8320         --bootstrap-tools=TOOL_LIST
8321               a comma-separated list of tools, e.g.,
8322               autoconf,automake,bison,gnulib
8323         --gnulib-snapshot-date=DATE
8324               if gnulib is in the bootstrap tool list,
8325               then report this as the snapshot date.
8326               If not specified, use the current date/time.
8327               If you specify a date here, be sure it's UTC.
8328
8329 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8330
8331         * tests/test-argp-2.sh: Fix test to match actual output.
8332         (func_compare): Fix sed script to be portable.
8333
8334 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
8335
8336         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
8337         workaround for this case.  It is not autoconfigured now; offhand
8338         it's hard to see how to autoconfigure it.
8339
8340 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
8341
8342         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
8343         a directory that is about to be chowned.  Such a directory's
8344         initial file permissions should permit the owner only and this
8345         should not be changed until after the chown, since the group and
8346         other bits would be incorrect if they granted permission before
8347         the chown.
8348
8349         Fix porting problem for iswctype reported by Georg Schwarz in:
8350         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
8351         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
8352         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
8353         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
8354         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
8355
8356 2006-12-03  Jim Meyering  <jim@meyering.net>
8357
8358         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
8359         p->fts_statp may not yet be defined.
8360         (fts_read): Instead, set it in the caller, once p->fts_statp is
8361         sure to be defined, and corresponds to a top-level directory.
8362         This bug made du -x fail.  Here's the coreutils test case:
8363         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
8364         Reported by Mike Frysinger.
8365
8366 2006-12-01  Jim Meyering  <jim@meyering.net>
8367
8368         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
8369         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
8370         Reported by Simon Josefsson.
8371
8372 2006-11-30  Jim Meyering  <jim@meyering.net>
8373
8374         * m4/warning.m4: Use the all-permissive copyright notice
8375         recommended by RMS (rather than LGPL).
8376         * m4/vararrays.m4: Likewise.
8377         * m4/flexmember.m4: Likewise.
8378
8379 2006-11-29  Bruno Haible  <bruno@clisp.org>
8380
8381         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
8382         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
8383         using +=.
8384         Reported by Simon Josefsson <simon@josefsson.org>.
8385
8386 2006-11-28  James Youngman <jay@gnu.org>
8387
8388         * README: Advise users that they might find the bug-gnulib@gnu.org
8389         and autotools-announce@gnu.org mailing lists useful.
8390
8391 2006-11-28  Bruno Haible  <bruno@clisp.org>
8392
8393         * m4/ptrdiff_max.m4: Remove file.
8394
8395 2006-11-21  Bruno Haible  <bruno@clisp.org>
8396
8397         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
8398         _AC_COMPUTE_INT.
8399         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8400         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
8401         _AC_COMPUTE_INT.
8402         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8403         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
8404         _AC_COMPUTE_INT.
8405         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8406
8407 2006-11-28  Jim Meyering  <jim@meyering.net>
8408
8409         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
8410         warning from "gcc -Wshadow" about shadowing the builtin.
8411
8412 2006-11-27  Bruno Haible  <bruno@clisp.org>
8413
8414         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
8415         _AC_COMPUTE_INT.
8416         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8417
8418 2006-11-27  Bruno Haible  <bruno@clisp.org>
8419             Paul Eggert  <eggert@cs.ucla.edu>
8420
8421         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
8422
8423 2006-11-26  Bruno Haible  <bruno@clisp.org>
8424
8425         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
8426         noinst_LTLIBRARIES.
8427
8428 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
8429             Bruno Haible  <bruno@clisp.org>
8430
8431         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
8432         if compiling with "gcc -ansi".
8433
8434 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
8435
8436         Fix some incompatibilities with gcc -ansi -pedantic.
8437         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
8438         if compiling pedantically with GCC, unless it's C99 or later.
8439         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
8440         it mishandles gcc -ansi -pedantic as well.
8441         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
8442         if gcc -pedantic.
8443         * lib/regexec.c (check_node_accept_bytes): Don't use auto
8444         initializers for struct if -pedantic, unless it's C99 or later.
8445
8446 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
8447
8448         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
8449         Don't close an fd more than once. Identical atimes indicate
8450         success, not failure.
8451
8452 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
8453
8454         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
8455
8456 2006-11-23  Jim Meyering  <jim@meyering.net>
8457
8458         * build-aux/announce-gen: New file.  From coreutils.
8459
8460 2006-11-22  Jim Meyering  <jim@meyering.net>
8461
8462         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
8463         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
8464         (fts_read): Use a temporary to narrow the overused st_size member
8465         before using it in a switch statement.  Reported by Matthew Woehlke.
8466
8467         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
8468         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
8469
8470 2006-11-20  Bruno Haible  <bruno@clisp.org>
8471
8472         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
8473         changequote instead of pairs of brackets.
8474         Reported by Andreas Schwab <schwab@suse.de>.
8475
8476 2006-11-21  Jim Meyering  <jim@meyering.net>
8477
8478         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
8479         so as to remain compatible with older compilers.
8480         Patch from Michael Deutschmann.
8481
8482 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
8483
8484         * MODULES.html.sh (File system functions): Add openat.
8485
8486         * lib/openat.h (rpl_fstatat): New macro, if
8487         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
8488         (fstatat): Define to rpl_fstatat under the same conditions,
8489         unless COMPILING_FSTATAT.
8490         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
8491         seems to have the bug.
8492         * lib/fstatat.c: New file.
8493         * modules/openat (Files): Add it.
8494
8495 2006-11-20  Bruno Haible  <bruno@clisp.org>
8496
8497         * Makefile: New file.
8498
8499 2006-11-20  Jim Meyering  <jim@meyering.net>
8500
8501         The beginnings of syntax-related checks for gnulib.
8502         * lib/Makefile: New file.
8503         * lib/t-idcache: New script.  Ensure that the two halves of
8504         idcache.c stay in sync.
8505
8506         * lib/idcache.c: Adjust comments in user- and group- portions to
8507         be more accurate, and to be consistent with one another.
8508
8509 2006-11-20  Jim Meyering  <jim@meyering.net>
8510
8511         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
8512         continue using the flexible array member (thus, this module performs
8513         half as many malloc calls), with the addition that...
8514         (getgroup, getuser): Consistently record a non-match via an empty
8515         "name" string, and map an empty string match to a NULL return value.
8516         * modules/idcache (Depends-on): Re-add flexmember.
8517
8518         * lib/idcache.c (getuser): Remove all uses of the register keyword.
8519         (getuidbyname, getgroup, getgidbyname): Likewise.
8520
8521         Use cleaner syntax: NULL rather than 0.
8522         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
8523
8524 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
8525
8526         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
8527         It mishandled the case where the group was missing.
8528         Problem reported by Greg Schafer.
8529         * modules/idcache: Likewise.
8530
8531 2006-11-18  Jim Meyering  <jim@meyering.net>
8532
8533         * check-module (%exempt_header): Add exception for some
8534         conditionally-included headers.
8535
8536         * modules/i-ring (Depends-on): Add verify.
8537         (License): Change to LGPL.
8538
8539 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
8540
8541         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
8542         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
8543         and inttostr.h.  Use snprintf rather than uinttostr, so that
8544         LGPLed code doesn't depend on GPLed.
8545
8546 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
8547
8548         * modules/inline (License): Change from GPL to LGPL.
8549
8550 2006-11-17  Jim Meyering  <jim@meyering.net>
8551
8552         * modules/d-type (License): Switch to LGPL.
8553
8554 2006-11-15  Bruno Haible  <bruno@clisp.org>
8555
8556         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
8557
8558 2006-11-15  Eric Blake  <ebb9@byu.net>
8559
8560         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
8561         the module dependency.
8562
8563 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
8564             Bruno Haible  <bruno@clisp.org>
8565
8566         * gnulib-tool (func_create_testdir): Add license consistency check.
8567
8568 2006-11-15  Eric Blake  <ebb9@byu.net>
8569
8570         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
8571         random "(cached)" in configure output.
8572
8573 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8574
8575         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
8576         test for conforming inttypes.h is both announced and cached.
8577
8578         * MODULES.html.sh (seen_modules, seen_files): New variables.
8579         (func_module): Rewrite to use a few less gnulib-tool and sed
8580         invocations.  Avoid a couple of quadratic algorithms for ...
8581         (missed_modules, missed_files): ... these, with ...
8582         (func_append, func_tmpdir): ... these new functions, from
8583         gnulib-tool.  Analogously, install traps for cleanup.
8584
8585         * tests/test-gc.c (main): Remove unused variables.
8586         * tests/test-read-file.c: Include stdlib.h, for 'free'.
8587
8588 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
8589
8590         * modules/inttostr (License): Change to LGPL.
8591
8592 2006-11-14  Eric Blake  <ebb9@byu.net>
8593
8594         * modules/tempname (License): Change to LGPL.
8595
8596 2006-11-14  Eric Blake  <ebb9@byu.net>
8597
8598         * doc/functions.texi (Function Portability): *printf functions on
8599         Cygwin now understand all POSIX size specifiers.
8600
8601 2006-11-14  Bruno Haible  <bruno@clisp.org>
8602
8603         * modules/c-ctype (License): Change to LGPL.
8604
8605 2006-11-12  Bruno Haible  <bruno@clisp.org>
8606
8607         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
8608         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
8609         for GNOME libraries, for which the include files are installed in
8610         subdirectories of $prefix/include.
8611
8612 2006-11-12  Bruno Haible  <bruno@clisp.org>
8613
8614         * m4/lib-link.m4: Require at least autoconf-2.54.
8615         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
8616         name to underscores for the --with option.
8617
8618 2006-11-13  Bruno Haible  <bruno@clisp.org>
8619
8620         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
8621         the tests directory.
8622         Reported by Ralf Wildenhues.
8623
8624 2006-11-13  Bruno Haible  <bruno@clisp.org>
8625
8626         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
8627         (func_emit_initmacro_end): Undo the override here.
8628         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
8629         Works around the famous automake error in coreutils.
8630
8631 2006-11-13  Eric Blake  <ebb9@byu.net>
8632
8633         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
8634         element, not its node.
8635
8636 2006-11-12  Bruno Haible  <bruno@clisp.org>
8637
8638         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
8639         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
8640
8641 2006-11-12  Bruno Haible  <bruno@clisp.org>
8642
8643         * gnulib-tool: New option --local-symlink.
8644         (func_usage): Document it.
8645         (lsymbolic): New variable.
8646         (func_import, func_create_testdir): If --symlink was not specified,
8647         test whether --local-symlink was specified and the file comes from
8648         the local_gnulib_dir.
8649
8650 2006-11-12  Bruno Haible  <bruno@clisp.org>
8651
8652         * gnulib-tool (func_ln): New function.
8653         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
8654
8655 2006-11-12  Bruno Haible  <bruno@clisp.org>
8656
8657         Finish support for source files in subdirectories.
8658         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
8659         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
8660         AUTOMAKE_OPTIONS.
8661         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
8662
8663 2006-11-12  Bruno Haible  <bruno@clisp.org>
8664
8665         * gnulib-tool (func_get_automake_snippet): Synthesize also an
8666         EXTRA_lib_SOURCES augmentation.
8667         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
8668
8669 2006-11-12  Jim Meyering  <jim@meyering.net>
8670
8671         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
8672         file descriptors.  This also averts a failure on systems with
8673         native openat support when a traversed directory lacks "x" access.
8674         * lib/fts_.h: Include "i-ring.h"
8675         (struct FTS) [fts_fd_ring]: New member.
8676         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
8677         (FCHDIR): Add parentheses.
8678         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
8679         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
8680         When descending, rather than simply closing the previous
8681         fts_cwd_fd value, push that file descriptor onto the ring.
8682         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
8683         (fts_open): Initialize the new fd_ring member.
8684         (fts_close): Clear the ring.
8685         (fts_safe_changedir): When possible, use our new fd_ring to skip
8686         the diropen and fstat and dev/ino comparison that would normally
8687         accompany a virtual `chdir ("..")'.
8688
8689         * modules/fts (Depends-on): Add i-ring.
8690         * modules/i-ring: New module.
8691         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
8692         * m4/i-ring.m4: New file.
8693
8694 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8695
8696         * gnulib-tool (func_create_testdir): Fix replacement of
8697         `build-aux' in configure.ac.  Run autotools in gltests
8698         subdirectory.
8699         (func_create_testdir, func_create_megatestdir, test): There is
8700         no need for '--force' in most autotool invocations in a new
8701         tree.  Actually fail the whole test if any of the tools, or the
8702         configure or make stages fail.
8703
8704         Sync from Automake.
8705         * build-aux/gnupload: Revert last change.  Add pointer to upload
8706         instructions of the GNU Maintenance Instructions.
8707         Suggestion by Karl Berry.
8708
8709 2006-11-10  Jim Meyering  <jim@meyering.net>
8710
8711         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
8712
8713 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
8714
8715         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
8716         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
8717         (bind_textdomain_codeset) [! ENABLE_NLS]:
8718         Evaluate all the arguments.  That way, callers get compatible behavior
8719         if the arguments have side effects.  Also, it avoids some GCC
8720         diagnostics in some cases; Joel E. Denny reported problems when Bison
8721         was configured with --enable-gcc-warnigs.
8722
8723 2006-11-10  Jim Meyering  <jim@meyering.net>
8724
8725         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
8726         relevant options in CFLAGS (like -O, -fno-inline) are taken into
8727         account.
8728
8729 2006-11-10  Jim Meyering  <jim@meyering.net>
8730
8731         * modules/inline: New file/module.
8732         * modules/xalloc (Files): Remove m4/inline.m4.
8733         (Depends-on): Add inline, instead.
8734         * modules/oset: Likewise.
8735         * modules/list: Likewise.
8736
8737 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
8738
8739         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
8740         Problem reported by Matthew Woehlke.
8741
8742 2006-11-09  Bruno Haible  <bruno@clisp.org>
8743
8744         * lib/tempname.c (gen_tempname): Remove variant that invokes
8745         __gen_tempname.
8746         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
8747         __gen_tempname.
8748
8749 2006-11-08  Bruno Haible  <bruno@clisp.org>
8750
8751         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
8752         to 'yes' instead of 'cross-compiling'.
8753
8754 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
8755
8756         * lib/quotearg.h (quotearg_free): New decl.
8757         * lib/quotearg.c (quotearg_free): New function.
8758         (slot0, nslots, slotvec0, slotvec):
8759         Now file-scope so that quotearg_free can get at them.
8760
8761 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8762
8763         Sync from Automake.
8764         * build-aux/gnupload: Add missing 'gnu' to example URL.
8765         Report by Karl Berry.
8766
8767 2006-11-08  Bruno Haible  <bruno@clisp.org>
8768
8769         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
8770         Suggested by Paul Eggert.
8771
8772 2006-11-08  Jim Meyering  <jim@meyering.net>
8773
8774         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
8775         It's already included if !_LIBC.
8776         (fts_safe_changedir): Add a comment.
8777
8778 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
8779
8780         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
8781         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
8782         Matthew Woehlke.
8783
8784         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
8785         definitions up, to avoid colliding with change below.
8786         (static_inline) [HAVE_INLINE]: New macro.
8787         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
8788         Provide extern decls when !HAVE_INLINE.  Do not define unless
8789         static_inline is defined, either by us or by xmalloc.c.  Use
8790         static_inline rather than static inline.
8791         (XCALLOC): Optimize sizeof(T) = 1 case.
8792         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
8793
8794 2006-11-07  Bruno Haible  <bruno@clisp.org>
8795
8796         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
8797         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
8798         AC_C_INLINE.
8799         * modules/xalloc (Files): Add m4/inline.m4.
8800
8801 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8802
8803         * README: Fix typo.
8804         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
8805         (Miscellanous Notes): ...from this.
8806
8807 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
8808
8809         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
8810         Mention that offsetof should be used instead of sizeof.
8811         From Bruno Haible.
8812
8813 2006-11-07  Bruno Haible  <bruno@clisp.org>
8814
8815         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
8816
8817 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
8818
8819         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
8820         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
8821         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
8822         (gl_tree_add_before, gl_tree_add_after):
8823         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
8824         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
8825         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
8826         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
8827         (gl_linked_add_after, gl_linked_add_at): Likewise.
8828         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
8829         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
8830         (gl_tree_add_before, gl_tree_add_after): Likewise.
8831         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
8832         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
8833         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
8834
8835 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8836
8837         * lib/gl_oset.h: Use C comment style, not C++ comment style.
8838
8839 2006-11-06  Bruno Haible  <bruno@clisp.org>
8840
8841         * m4/inline.m4: New file.
8842         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
8843         * modules/list (Files): Add m4/inline.m4.
8844         * modules/oset (Files): Likewise.
8845
8846 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
8847
8848         * lib/idcache.c: Include <stddef.h>, for offsetof.
8849         (struct userid.name): Change from char * to a flexible array member.
8850         All uses changed.
8851         * modules/idcache (Depends-on): Add flexmember.
8852
8853         * MODULES.html.sh (Core language properties): New module flexmember.
8854         * modules/flexmember, m4/flexmember.m4: New files.
8855
8856         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
8857         inline functions that are identical with the old xnmalloc_inline,
8858         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
8859         that we can avoid some unnecessary integer multiplications and
8860         divisions in the common case where the element size is known at
8861         compile time.
8862         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
8863         needed.
8864         (xnboundedmalloc): Remove.
8865         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
8866         arguments, for consistency with rest of this header.
8867         (xcharalloc): Rewrite using XNMALLOC.
8868         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
8869         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
8870         versions have been moved to lib/xalloc.h and renamed to be the
8871         non-*_inline versions.
8872         (xmalloc, xrealloc): Implement without reference to the xnmalloc
8873         and xnrealloc functions, since those functions are now inline and
8874         now call us.
8875         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
8876         renaming described above.
8877         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
8878         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
8879         captures the dependency in AC_C_INLINE.
8880
8881         New module canonicalize-lgpl, proposed by Charles Wilson in
8882         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
8883         with a few small changes afterwards.
8884         * MODULES.html.sh (File system functions): New module
8885         canonicalize-lgpl.
8886         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
8887         and canonicalize_file_name.
8888         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
8889         * modules/canonicalize-lgpl: New files.
8890
8891 2006-11-05  Bruno Haible  <bruno@clisp.org>
8892
8893         * gnulib-tool (func_import, func_create_testdir): Create directories
8894         also for files in subdirectories of lib/.
8895
8896 2006-11-05  Bruno Haible  <bruno@clisp.org>
8897
8898         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
8899         ANSI C compliant.
8900
8901 2006-11-03  Bruno Haible  <bruno@clisp.org>
8902
8903         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
8904         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
8905         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
8906         (xnboundedmalloc): New inline function.
8907         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
8908         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
8909         xmalloc.
8910         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
8911         xmalloc.
8912         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
8913         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
8914         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
8915         xmalloc.
8916         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
8917         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
8918         xmalloc.
8919         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
8920         gl_tree_add_after): Use XMALLOC instead of xmalloc.
8921         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
8922         xmalloc.
8923         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
8924         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
8925         gl_tree_add_after): Use XMALLOC instead of xmalloc.
8926         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
8927         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
8928         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
8929         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
8930
8931 2006-11-03  Bruno Haible  <bruno@clisp.org>
8932
8933         * lib/c-ctype.h [C++]: Define functions without name mangling.
8934         * lib/fwriteerror.h [C++]: Likewise.
8935         * lib/gcd.h [C++]: Likewise.
8936         * lib/linebreak.h [C++]: Likewise.
8937
8938 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
8939
8940         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
8941         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
8942         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
8943         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
8944         Check for functions and headers just once.
8945         Check for declaration of canonicalize_file_name.
8946         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
8947
8948 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
8949
8950         * gnulib-tool (func_import): Fix typo in actioncmd.
8951
8952 2006-11-02  Bruno Haible  <bruno@clisp.org>
8953
8954         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
8955         newline sequence in the Makefile.am snippet as a space, like "make"
8956         does.
8957         Reported by Roger Persson <perrog@gmail.com>.
8958
8959 2006-11-01  Bruno Haible  <bruno@clisp.org>
8960
8961         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
8962         already declared in <string.h>.
8963         * lib/strcase.h (strncasecmp): Don't declare it if yes.
8964
8965 2006-11-01  Bruno Haible  <bruno@clisp.org>
8966
8967         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
8968         * lib/strcase.h: Include <string.h>.
8969         (strcasecmp): Define to rpl_strcasecmp here.
8970
8971 2006-11-01  Bruno Haible  <bruno@clisp.org>
8972
8973         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
8974
8975 2006-11-01  Eric Blake  <ebb9@byu.net>
8976
8977         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
8978
8979         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
8980
8981 2006-10-29  Bruno Haible  <bruno@clisp.org>
8982
8983         Make it compile in C++ mode.
8984         * lib/full-write.c (full_rw): Add a cast.
8985
8986 2006-11-01  Bruno Haible  <bruno@clisp.org>
8987
8988         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
8989         be POSIX compliant.
8990         Reported by Roger Persson <perrog@gmail.com>.
8991
8992 2006-11-01  Eric Blake  <ebb9@byu.net>
8993
8994         * lib/getopt_.h: Fix comments.
8995
8996 2006-10-31  Eric Blake  <ebb9@byu.net>
8997
8998         * modules/tmpdir (Depends-on): Add sys_stat.
8999         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
9000         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
9001         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
9002         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
9003         tempname.
9004
9005 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
9006
9007         Avoid some C++ diagnostics reported by Bruno Haible.
9008         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
9009         xmalloc.
9010         (quotearg_alloc): Use xcharalloc rather than xmalloc.
9011         (struct slotvec): Move to top level.
9012         (quotearg_n_options): Rewrite to avoid xmalloc.
9013         * lib/xalloc.h (xcharalloc): New function.
9014         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
9015         [defined __cplusplus]: Add function template that provides result
9016         type propagation.  This part of the change is from Bruno Haible.
9017
9018 2006-10-29  Bruno Haible  <bruno@clisp.org>
9019
9020         Make it compile in C++ mode.
9021         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
9022         * lib/strnlen1.c (strnlen1): Cast memchr result.
9023         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
9024         * lib/clean-temp.c (string_equals, string_hash): Add casts.
9025         (create_temp_dir): Rename local variable 'template'.
9026         (compile_csharp_using_sscli): Add cast.
9027         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
9028         * lib/findprog.c (find_in_path): Likewise.
9029         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
9030         * lib/wait-process.c (register_slave_subprocess): Likewise.
9031
9032 2006-10-22  Bruno Haible  <bruno@clisp.org>
9033
9034         * modules/tsearch: New file.
9035         * lib/tsearch.h: New file.
9036         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
9037         * m4/tsearch.m4: New file.
9038         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
9039
9040 2006-10-29  Eric Blake  <ebb9@byu.net>
9041
9042         * lib/arcfour.c: Assume config.h.
9043         * lib/arctwo.c: Likewise.
9044         * lib/base64.c: Likewise.
9045         * lib/check-version.c: Likewise.
9046         * lib/crc.c: Likewise.
9047         * lib/des.c: Likewise.
9048         * lib/gc-gnulib.c: Likewise.
9049         * lib/gc-libgcrypt.c: Likewise.
9050         * lib/gc-pbkdf2-sha1.c: Likewise.
9051         * lib/getaddrinfo.c: Likewise.
9052         * lib/getdelim.c: Likewise.
9053         * lib/getline.c: Likewise.
9054         * lib/hmac-md5.c: Likewise.
9055         * lib/hmac-sha1.c: Likewise.
9056         * lib/iconvme.c: Likewise.
9057         * lib/md2.c: Likewise.
9058         * lib/md4.c: Likewise.
9059         * lib/memxor.c: Likewise.
9060         * lib/read-file.c: Likewise.
9061         * lib/readline.c: Likewise.
9062         * lib/rijndael-alg-fst.c: Likewise.
9063         * lib/rijndael-api-fst.c: Likewise.
9064         * lib/xgetdomainname.c: Likewise.
9065
9066 2006-10-28  Eric Blake  <ebb9@byu.net>
9067
9068         * lib/xstrndup.c: Assume config.h.
9069
9070 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
9071
9072         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
9073         stat-macros.h is now for our own macros, whereas stat_h is for
9074         macros in the <sys/stat.h> name space.
9075         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
9076         (STAT_MACROS_H): Remove.
9077         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
9078         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
9079         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
9080         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
9081         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
9082         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
9083         Move these macros to ...
9084         * lib/stat_.h: here.  Don't include stat-macros.h.
9085         * lib/canonicalize.c: Don't include stat-macros.h.
9086         * lib/chown.c: Likewise.
9087         * lib/euidaccess.c: Likewise.
9088         * lib/file-type.c: Likewise.
9089         * lib/filemode.c: Likewise.
9090         * lib/glob.c: Likewise.
9091         * lib/isapipe.c: Likewise.
9092         * lib/lchown.c: Likewise.
9093         * lib/lstat.c: Likewise.
9094         * lib/mkdir-p.c: Likewise.
9095         * lib/rmdir.c: Likewise.
9096         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
9097         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
9098         unless mkdir isn't declared, to speed up 'configure'.
9099         Always create sys/stat.h, since it's unlikely any real sys/stat.h
9100         would define all the S_* symbols.
9101         * modules/canonicalize (Depends-on):
9102         Depend on sys_stat, not stat-macros.
9103         * modules/chown: Likewise.
9104         * modules/euidaccess: Likewise.
9105         * modules/filemode: Likewise.
9106         * modules/file-type: Likewise.
9107         * modules/glob: Likewise.
9108         * modules/isapipe: Likewise.
9109         * modules/lchown: Likewise.
9110         * modules/lstat: Likewise.
9111         * modules/mkancesdirs: Likewise.
9112         * modules/rmdir: Likewise.
9113         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
9114         * modules/modechange: Likewise.
9115         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
9116         (configure.ac): Remove gl_STAT_MACROS.
9117         * modules/sys_stat (Depends-on): Remove stat-macros.
9118
9119 2006-10-27  Bruno Haible  <bruno@clisp.org>
9120
9121         * m4/signed.m4: Remove file.
9122         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
9123         invocation.
9124         * modules/vasnprintf (Files): Remove m4/signed.m4.
9125
9126 2006-10-27  Bruno Haible  <bruno@clisp.org>
9127
9128         Update to GNU gettext 0.16.
9129         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
9130         m4/inttypes-h.m4, m4/signed.m4.
9131         * m4/gettext.m4: Update to GNU gettext 0.16.
9132         * m4/intl.m4: New file, from GNU gettext.
9133         * m4/intldir.m4: New file, from GNU gettext.
9134         * config/srclist.txt: Update
9135
9136 2006-10-27  Eric Blake  <ebb9@byu.net>
9137
9138         * MODULES.html.sh: Document tempname.
9139         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
9140         dependencies.
9141         (Files): Move lib/tempname.c...
9142         * modules/tempname: ...to this new module.
9143         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
9144         (gl_PREREQ_TEMPNAME): Move...
9145         * m4/tempname.m4: ...to this new file.
9146         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
9147         * modules/sys_stat (Depends-on): Add stat-macros.
9148         * lib/stat_.h (includes): Pick up stat macros.
9149         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
9150         if stat macros are broken.
9151         * lib/tempname.c (includes): No need to include "stat-macros.h".
9152         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
9153         (direxists, __path_search) [!_LIBC]: Don't compile these in
9154         gnulib; the tmpdir module covers that.
9155         * lib/tempname.h: New file.
9156
9157 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
9158
9159         * COPYING: Explain how gnulib-tool converts licence headers.
9160         Almost all wording by Eric Blake.
9161
9162 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
9163
9164         * lib/mbchar.h (is_basic_table): Make read-only.
9165         * lib/mbchar.c (is_basic_table): Likewise.
9166         Reported by John Darrington.
9167
9168 2006-10-25  Bruno Haible  <bruno@clisp.org>
9169
9170         * lib/progname.h (set_program_name): Undefine before defining.
9171
9172 2006-10-25  Bruno Haible  <bruno@clisp.org>
9173
9174         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
9175         false for non-gcc C++ compilers.
9176         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
9177
9178 2006-10-24  Bruno Haible  <bruno@clisp.org>
9179
9180         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
9181         iconv implementations like Irix iconv.
9182
9183 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
9184
9185         * modules/vararrays: New file.
9186         * m4/vararrays.m4: New file, taken from diffutils.
9187         * MODULES.html.sh: New module vararrays.
9188
9189 2006-10-24  Karl Berry  <karl@gnu.org>
9190
9191         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
9192         Don't call GNU Unix.
9193
9194 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9195
9196         * users.txt: Add Libtool.
9197
9198         Sync from Libtool:
9199
9200         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
9201
9202         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
9203         to gnulib's policy of including config.h unconditionally.
9204
9205 2006-10-24  Bruno Haible  <bruno@clisp.org>
9206
9207         * modules/wcwidth (Files): Add m4/wint_t.m4.
9208         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
9209         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
9210
9211 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
9212
9213         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
9214         to pacify GCC with some -W flags enabled.  Problem reported by
9215         Bruno Haible.
9216
9217 2006-10-24  Jim Meyering  <jim@meyering.net>
9218
9219         * MODULES.html.sh: Remove uinttostr.  It's not a module.
9220         Reported by Karl Berry.
9221
9222 2006-10-23  Bruno Haible  <bruno@clisp.org>
9223
9224         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
9225
9226 2006-10-24  Bruno Haible  <bruno@clisp.org>
9227
9228         * lib/gl_list.h: Use C comment style, not C++ comment style.
9229
9230 2006-10-23  Eric Blake  <ebb9@byu.net>
9231
9232         * lib/getaddrinfo.c (includes): Add missing include.
9233
9234 2006-10-23  Bruno Haible  <bruno@clisp.org>
9235             Paul Eggert  <eggert@cs.ucla.edu>
9236
9237         Ability to rename obstack_free.
9238         * lib/obstack.h (__obstack_free): New macro. Declare instead of
9239         obstack_free.
9240         (obstack_free): Invoke the __obstack_free macro.
9241         * lib/obstack.c (obstack_free): Use __obstack_free macro.
9242
9243 2006-10-23  Bruno Haible  <bruno@clisp.org>
9244             Paul Eggert  <eggert@cs.ucla.edu>
9245
9246         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
9247         __argc, __argv from the declaration. (They are defined as macros on
9248         mingw.)
9249
9250 2006-10-22  Bruno Haible  <bruno@clisp.org>
9251
9252         * doc/gnulib-intro.texi: New file.
9253         * doc/gnulib.texi: Include it.
9254
9255 2006-10-21  Bruno Haible  <bruno@clisp.org>
9256
9257         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
9258         "Introduction", "Miscellanous Notes", "Particular Modules".
9259
9260 2006-10-21  Bruno Haible  <bruno@clisp.org>
9261
9262         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9263         Change mostlyclean-local rule to avoid sh syntax error from bash
9264         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
9265
9266 2006-10-23  Jim Meyering  <jim@meyering.net>
9267
9268         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
9269         in place of snprintf.
9270
9271         * modules/inttostr (Files): Add lib/uinttostr.c.
9272         * lib/uinttostr.c (inttostr): New file/function.
9273         * lib/inttostr.h (uinttostr): Declare.
9274         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
9275         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
9276         Add uinttostr.
9277         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
9278
9279 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
9280
9281         * lib/canonicalize.c (ELOOP): Define if not already defined.
9282         Problem reported by Bruno Haible in
9283         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
9284
9285 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
9286
9287         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
9288         Problem reported by Perry Smith and Ville Laurikari.
9289
9290         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
9291         uses.
9292
9293 2006-10-19  Bruno Haible  <bruno@clisp.org>
9294
9295         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
9296         for mingw.
9297
9298 2006-10-19  Bruno Haible  <bruno@clisp.org>
9299
9300         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
9301         Needed for mingw.
9302
9303 2006-10-19  Bruno Haible  <bruno@clisp.org>
9304
9305         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
9306
9307 2006-10-19  Bruno Haible  <bruno@clisp.org>
9308
9309         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
9310         it.
9311
9312 2006-10-19  Bruno Haible  <bruno@clisp.org>
9313
9314         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
9315         invocation.
9316
9317 2006-10-19  Bruno Haible  <bruno@clisp.org>
9318
9319         * gnulib-tool (func_create_testdir): Don't include ftruncate and
9320         mountlist by default.
9321
9322 2006-10-16  Bruno Haible  <bruno@clisp.org>
9323
9324         * lib/c-strstr.c: Include c-strstr.h.
9325
9326 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
9327
9328         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
9329         in a slash.
9330
9331 2006-10-18  Bruno Haible  <bruno@clisp.org>
9332
9333         * lib/lock.h [C++]: Wrap definitions in extern "C".
9334
9335 2006-10-18  Bruno Haible  <bruno@clisp.org>
9336
9337         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
9338         gl_LIBOBJS list.
9339
9340 2006-10-18  Bruno Haible  <bruno@clisp.org>
9341
9342         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
9343
9344 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
9345
9346         * lib/xstrtol.h: Include gettext.h.
9347         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
9348         Problem reported by Eric Blake.
9349         * modules/xstrtol (Depends-on): Add gettext-h.
9350
9351 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
9352
9353         * lib/strftime.c (advance): New macro.
9354         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
9355         incomplete type, so you can't add 0 to it.  Problem and patch
9356         reported by Eelco Dolstra for dietlibc.
9357
9358 2006-10-18  Jim Meyering  <jim@meyering.net>
9359
9360         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
9361         type for a local, and rename it: s/up/user_proc/.
9362
9363 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
9364
9365         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
9366         READ_UTMP_USER_PROCESS.
9367         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
9368
9369 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
9370
9371         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
9372         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
9373
9374 2006-10-17  Eric Blake  <ebb9@byu.net>
9375
9376         * lib/sigprocmask.c (sigprocmask): Fix typo.
9377
9378         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
9379
9380         * modules/clean-temp (Makefile.am): Don't add to make output...
9381         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
9382         config.h.
9383
9384 2006-10-17  Bruno Haible  <bruno@clisp.org>
9385
9386         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
9387         differently if DEFAULT_TEXT_DOMAIN is set.
9388
9389 2006-10-16  Bruno Haible  <bruno@clisp.org>
9390
9391         * lib/clean-temp.c: Include fwriteerror.h.
9392
9393 2006-10-16  Bruno Haible  <bruno@clisp.org>
9394
9395         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
9396
9397 2006-10-16  Bruno Haible  <bruno@clisp.org>
9398
9399         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
9400         * lib/sigprocmask.h: Include <sys/types.h>.
9401         (sigset_t): Use the system's definition if present.
9402
9403 2006-10-17  Eric Blake  <ebb9@byu.net>
9404
9405         * lib/xvasprintf.c (includes): Assume config.h.
9406         * lib/xasprintf.c (includes): Likewise.
9407
9408 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
9409
9410         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
9411         at least as wide as intmax_t.
9412
9413 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
9414
9415         (Imported from Automake.)
9416         * build-aux/gnupload: Update to version 1.1 of directive file.
9417
9418 2006-10-16  Eric Blake  <ebb9@byu.net>
9419
9420         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
9421         match Automake 1.10a.
9422
9423 2006-10-14  Bruno Haible  <bruno@clisp.org>
9424
9425         * modules/sigprocmask: New file.
9426         * lib/sigprocmask.h: New file.
9427         * lib/sigprocmask.c: New file.
9428         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
9429         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
9430         request sigprocmask.o.
9431         (gl_PREREQ_SIGPROCMASK): New macro.
9432         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
9433         (Depends-on): Add sigprocmask.
9434         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
9435         gt_SIGNALBLOCKING. Test for 'raise' only once.
9436         * lib/fatal-signal.c: Include sigprocmask.h.
9437         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
9438         unblock_fatal_signals): Define always.
9439         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
9440         sigprocmask.
9441
9442 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9443
9444         Sync from Automake.
9445         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
9446         which incorrectly sets the mode of an existing destination
9447         directory.  In some cases the unpatched install-sh could do the
9448         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
9449         system.  We hope this is rare in practice, but it's clearly worth
9450         fixing.  Problem reported by Alex Unleashed in
9451         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
9452         Also, don't bother to check for -m bugs unless we're using -m;
9453         suggested by Stepan Kasal.
9454
9455 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9456
9457         Sync from Automake.
9458         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
9459         `-c' flag, so they appear at the same position as in %FASTDEP%
9460         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
9461         which ignores unknown options only after the first non-option.
9462         Bug report against M4 by Nelson H. F. Beebe.
9463
9464 2006-10-13  Jim Meyering  <jim@meyering.net>
9465
9466         Fix a bug in yesterday's change.
9467         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
9468         p->fts_statp->st_dev would be used uninitialized.
9469         Ensures that we always call fts_stat on the very first entry.
9470         Miklos Szeredi reported that find -xdev stopped working.
9471
9472 2006-10-12  Bruno Haible  <bruno@clisp.org>
9473
9474         * gnulib-tool (func_get_automake_snippet): Append an automatically
9475         computed EXTRA_DIST augmentation.
9476         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
9477         * modules/alloca-opt (Makefile.am): Likewise.
9478         * modules/allocsa (Makefile.am): Likewise.
9479         * modules/arcfour (Makefile.am): Likewise.
9480         * modules/arctwo (Makefile.am): Likewise.
9481         * modules/argmatch (Makefile.am): Likewise.
9482         * modules/argz (Makefile.am): Likewise.
9483         * modules/atexit (Makefile.am): Likewise.
9484         * modules/backupfile (Makefile.am): Likewise.
9485         * modules/byteswap (Makefile.am): Likewise.
9486         * modules/c-strtod (Makefile.am): Likewise.
9487         * modules/c-strtold (Makefile.am): Likewise.
9488         * modules/calloc (Makefile.am): Likewise.
9489         * modules/canon-host (Makefile.am): Likewise.
9490         * modules/canonicalize (Makefile.am): Likewise.
9491         * modules/chdir-long (Makefile.am): Likewise.
9492         * modules/chdir-safer (Makefile.am): Likewise.
9493         * modules/check-version (Makefile.am): Likewise.
9494         * modules/chown (Makefile.am): Likewise.
9495         * modules/cloexec (Makefile.am): Likewise.
9496         * modules/close-stream (Makefile.am): Likewise.
9497         * modules/closeout (Makefile.am): Likewise.
9498         * modules/crc (Makefile.am): Likewise.
9499         * modules/csharpexec (Makefile.am): Likewise.
9500         * modules/cycle-check (Makefile.am): Likewise.
9501         * modules/des (Makefile.am): Likewise.
9502         * modules/dev-ino (Makefile.am): Likewise.
9503         * modules/dirfd (Makefile.am): Likewise.
9504         * modules/dirname (Makefile.am): Likewise.
9505         * modules/dup2 (Makefile.am): Likewise.
9506         * modules/eealloc (Makefile.am): Likewise.
9507         * modules/error (Makefile.am): Likewise.
9508         * modules/euidaccess (Makefile.am): Likewise.
9509         * modules/exclude (Makefile.am): Likewise.
9510         * modules/exitfail (Makefile.am): Likewise.
9511         * modules/fcntl-safer (Makefile.am): Likewise.
9512         * modules/fcntl (Makefile.am): Likewise.
9513         * modules/file-type (Makefile.am): Likewise.
9514         * modules/fileblocks (Makefile.am): Likewise.
9515         * modules/filemode (Makefile.am): Likewise.
9516         * modules/filenamecat (Makefile.am): Likewise.
9517         * modules/fnmatch (Makefile.am): Likewise.
9518         * modules/fopen-safer (Makefile.am): Likewise.
9519         * modules/fpending (Makefile.am): Likewise.
9520         * modules/fprintftime (Makefile.am): Likewise.
9521         * modules/free (Makefile.am): Likewise.
9522         * modules/fsusage (Makefile.am): Likewise.
9523         * modules/ftruncate (Makefile.am): Likewise.
9524         * modules/fts (Makefile.am): Likewise.
9525         * modules/gc-arcfour (Makefile.am): Likewise.
9526         * modules/gc-des (Makefile.am): Likewise.
9527         * modules/gc-hmac-md5 (Makefile.am): Likewise.
9528         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
9529         * modules/gc-md4 (Makefile.am): Likewise.
9530         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
9531         * modules/gc-sha1 (Makefile.am): Likewise.
9532         * modules/gc (Makefile.am): Likewise.
9533         * modules/getaddrinfo (Makefile.am): Likewise.
9534         * modules/getcwd (Makefile.am): Likewise.
9535         * modules/getdelim (Makefile.am): Likewise.
9536         * modules/getdomainname (Makefile.am): Likewise.
9537         * modules/getgroups (Makefile.am): Likewise.
9538         * modules/gethostname (Makefile.am): Likewise.
9539         * modules/gethrxtime (Makefile.am): Likewise.
9540         * modules/getline (Makefile.am): Likewise.
9541         * modules/getloadavg (Makefile.am): Likewise.
9542         * modules/getlogin_r (Makefile.am): Likewise.
9543         * modules/getndelim2 (Makefile.am): Likewise.
9544         * modules/getopt (Makefile.am): Likewise.
9545         * modules/getpagesize (Makefile.am): Likewise.
9546         * modules/getpass-gnu (Makefile.am): Likewise.
9547         * modules/getpass (Makefile.am): Likewise.
9548         * modules/getsubopt (Makefile.am): Likewise.
9549         * modules/gettime (Makefile.am): Likewise.
9550         * modules/gettimeofday (Makefile.am): Likewise.
9551         * modules/getugroups (Makefile.am): Likewise.
9552         * modules/getusershell (Makefile.am): Likewise.
9553         * modules/glob (Makefile.am): Likewise.
9554         * modules/group-member (Makefile.am): Likewise.
9555         * modules/hard-locale (Makefile.am): Likewise.
9556         * modules/hash (Makefile.am): Likewise.
9557         * modules/hmac-md5 (Makefile.am): Likewise.
9558         * modules/hmac-sha1 (Makefile.am): Likewise.
9559         * modules/human (Makefile.am): Likewise.
9560         * modules/idcache (Makefile.am): Likewise.
9561         * modules/imaxabs (Makefile.am): Likewise.
9562         * modules/imaxdiv (Makefile.am): Likewise.
9563         * modules/inet_ntop (Makefile.am): Likewise.
9564         * modules/inet_pton (Makefile.am): Likewise.
9565         * modules/intprops (Makefile.am): Likewise.
9566         * modules/inttostr (Makefile.am): Likewise.
9567         * modules/inttypes (Makefile.am): Likewise.
9568         * modules/isapipe (Makefile.am): Likewise.
9569         * modules/javaversion (Makefile.am): Likewise.
9570         * modules/lchmod (Makefile.am): Likewise.
9571         * modules/lchown (Makefile.am): Likewise.
9572         * modules/localcharset (Makefile.am): Likewise.
9573         * modules/long-options (Makefile.am): Likewise.
9574         * modules/lstat (Makefile.am): Likewise.
9575         * modules/malloc (Makefile.am): Likewise.
9576         * modules/mathl (Makefile.am): Likewise.
9577         * modules/mbchar (Makefile.am): Likewise.
9578         * modules/md2 (Makefile.am): Likewise.
9579         * modules/md4 (Makefile.am): Likewise.
9580         * modules/md5 (Makefile.am): Likewise.
9581         * modules/memcasecmp (Makefile.am): Likewise.
9582         * modules/memchr (Makefile.am): Likewise.
9583         * modules/memcmp (Makefile.am): Likewise.
9584         * modules/memcoll (Makefile.am): Likewise.
9585         * modules/memcpy (Makefile.am): Likewise.
9586         * modules/memmem (Makefile.am): Likewise.
9587         * modules/memmove (Makefile.am): Likewise.
9588         * modules/mempcpy (Makefile.am): Likewise.
9589         * modules/memrchr (Makefile.am): Likewise.
9590         * modules/memset (Makefile.am): Likewise.
9591         * modules/memxor (Makefile.am): Likewise.
9592         * modules/mkancesdirs (Makefile.am): Likewise.
9593         * modules/mkdir-p (Makefile.am): Likewise.
9594         * modules/mkdir (Makefile.am): Likewise.
9595         * modules/mkdtemp (Makefile.am): Likewise.
9596         * modules/mkstemp (Makefile.am): Likewise.
9597         * modules/mktime (Makefile.am): Likewise.
9598         * modules/modechange (Makefile.am): Likewise.
9599         * modules/mountlist (Makefile.am): Likewise.
9600         * modules/nanosleep (Makefile.am): Likewise.
9601         * modules/obstack (Makefile.am): Likewise.
9602         * modules/openat (Makefile.am): Likewise.
9603         * modules/pagealign_alloc (Makefile.am): Likewise.
9604         * modules/pathmax (Makefile.am): Likewise.
9605         * modules/physmem (Makefile.am): Likewise.
9606         * modules/poll (Makefile.am): Likewise.
9607         * modules/posixtm (Makefile.am): Likewise.
9608         * modules/posixver (Makefile.am): Likewise.
9609         * modules/putenv (Makefile.am): Likewise.
9610         * modules/quote (Makefile.am): Likewise.
9611         * modules/quotearg (Makefile.am): Likewise.
9612         * modules/raise (Makefile.am): Likewise.
9613         * modules/read-file (Makefile.am): Likewise.
9614         * modules/readline (Makefile.am): Likewise.
9615         * modules/readlink (Makefile.am): Likewise.
9616         * modules/readtokens (Makefile.am): Likewise.
9617         * modules/readutmp (Makefile.am): Likewise.
9618         * modules/realloc (Makefile.am): Likewise.
9619         * modules/regex (Makefile.am): Likewise.
9620         * modules/rename-dest-slash (Makefile.am): Likewise.
9621         * modules/rename (Makefile.am): Likewise.
9622         * modules/rijndael (Makefile.am): Likewise.
9623         * modules/rmdir (Makefile.am): Likewise.
9624         * modules/rpmatch (Makefile.am): Likewise.
9625         * modules/safe-read (Makefile.am): Likewise.
9626         * modules/safe-write (Makefile.am): Likewise.
9627         * modules/same-inode (Makefile.am): Likewise.
9628         * modules/same (Makefile.am): Likewise.
9629         * modules/save-cwd (Makefile.am): Likewise.
9630         * modules/savedir (Makefile.am): Likewise.
9631         * modules/setenv (Makefile.am): Likewise.
9632         * modules/settime (Makefile.am): Likewise.
9633         * modules/sha1 (Makefile.am): Likewise.
9634         * modules/sig2str (Makefile.am): Likewise.
9635         * modules/snprintf (Makefile.am): Likewise.
9636         * modules/stat-macros (Makefile.am): Likewise.
9637         * modules/stat-time (Makefile.am): Likewise.
9638         * modules/stdbool (Makefile.am): Likewise.
9639         * modules/stdint (Makefile.am): Likewise.
9640         * modules/stdlib-safer (Makefile.am): Likewise.
9641         * modules/stpcpy (Makefile.am): Likewise.
9642         * modules/stpncpy (Makefile.am): Likewise.
9643         * modules/strcase (Makefile.am): Likewise.
9644         * modules/strcasestr (Makefile.am): Likewise.
9645         * modules/strchrnul (Makefile.am): Likewise.
9646         * modules/strcspn (Makefile.am): Likewise.
9647         * modules/strdup (Makefile.am): Likewise.
9648         * modules/strerror (Makefile.am): Likewise.
9649         * modules/strftime (Makefile.am): Likewise.
9650         * modules/strndup (Makefile.am): Likewise.
9651         * modules/strnlen (Makefile.am): Likewise.
9652         * modules/strpbrk (Makefile.am): Likewise.
9653         * modules/strsep (Makefile.am): Likewise.
9654         * modules/strstr (Makefile.am): Likewise.
9655         * modules/strtod (Makefile.am): Likewise.
9656         * modules/strtoimax (Makefile.am): Likewise.
9657         * modules/strtok_r (Makefile.am): Likewise.
9658         * modules/strtol (Makefile.am): Likewise.
9659         * modules/strtoll (Makefile.am): Likewise.
9660         * modules/strtoul (Makefile.am): Likewise.
9661         * modules/strtoull (Makefile.am): Likewise.
9662         * modules/strtoumax (Makefile.am): Likewise.
9663         * modules/strverscmp (Makefile.am): Likewise.
9664         * modules/sys_socket (Makefile.am): Likewise.
9665         * modules/sys_stat (Makefile.am): Likewise.
9666         * modules/sysexits (Makefile.am): Likewise.
9667         * modules/time_r (Makefile.am): Likewise.
9668         * modules/timegm (Makefile.am): Likewise.
9669         * modules/timespec (Makefile.am): Likewise.
9670         * modules/tmpfile-safer (Makefile.am): Likewise.
9671         * modules/trim (Makefile.am): Likewise.
9672         * modules/unistd-safer (Makefile.am): Likewise.
9673         * modules/unlinkdir (Makefile.am): Likewise.
9674         * modules/unlocked-io (Makefile.am): Likewise.
9675         * modules/userspec (Makefile.am): Likewise.
9676         * modules/utime (Makefile.am): Likewise.
9677         * modules/utimecmp (Makefile.am): Likewise.
9678         * modules/utimens (Makefile.am): Likewise.
9679         * modules/vasnprintf (Makefile.am): Likewise.
9680         * modules/vasprintf (Makefile.am): Likewise.
9681         * modules/vsnprintf (Makefile.am): Likewise.
9682         * modules/xalloc (Makefile.am): Likewise.
9683         * modules/xgetcwd (Makefile.am): Likewise.
9684         * modules/xnanosleep (Makefile.am): Likewise.
9685         * modules/xreadlink (Makefile.am): Likewise.
9686         * modules/xstrtod (Makefile.am): Likewise.
9687         * modules/xstrtol (Makefile.am): Likewise.
9688         * modules/xstrtold (Makefile.am): Likewise.
9689         * modules/yesno (Makefile.am): Likewise.
9690         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
9691
9692 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
9693
9694         * modules/error (Makefile.am): Distribute files through
9695         EXTRA_DIST, not lib_SOURCES.
9696
9697 2006-10-12  Eric Blake  <ebb9@byu.net>
9698
9699         * modules/error (Makefile.am): Distribute files in /lib.
9700         * modules/obstack (Makefile.am): Likewise.
9701
9702 2006-10-12  Bruno Haible  <bruno@clisp.org>
9703
9704         * modules/acl (Makefile.am): Distribute all files in lib/ through
9705         EXTRA_DIST.
9706         * modules/arcfour (Makefile.am): Likewise.
9707         * modules/arctwo (Makefile.am): Likewise.
9708         * modules/argmatch (Makefile.am): Likewise.
9709         * modules/argz (Makefile.am): Likewise.
9710         * modules/atexit (Makefile.am): Likewise.
9711         * modules/backupfile (Makefile.am): Likewise.
9712         * modules/c-strtod (Makefile.am): Likewise.
9713         * modules/c-strtold (Makefile.am): Likewise.
9714         * modules/calloc (Makefile.am): Likewise.
9715         * modules/canon-host (Makefile.am): Likewise.
9716         * modules/canonicalize (Makefile.am): Likewise.
9717         * modules/chdir-long (Makefile.am): Likewise.
9718         * modules/chdir-safer (Makefile.am): Likewise.
9719         * modules/check-version (Makefile.am): Likewise.
9720         * modules/chown (Makefile.am): Likewise.
9721         * modules/cloexec (Makefile.am): Likewise.
9722         * modules/close-stream (Makefile.am): Likewise.
9723         * modules/closeout (Makefile.am): Likewise.
9724         * modules/crc (Makefile.am): Likewise.
9725         * modules/cycle-check (Makefile.am): Likewise.
9726         * modules/des (Makefile.am): Likewise.
9727         * modules/dirfd (Makefile.am): Likewise.
9728         * modules/dirname (Makefile.am): Likewise.
9729         * modules/dup2 (Makefile.am): Likewise.
9730         * modules/euidaccess (Makefile.am): Likewise.
9731         * modules/exclude (Makefile.am): Likewise.
9732         * modules/exitfail (Makefile.am): Likewise.
9733         * modules/fcntl-safer (Makefile.am): Likewise.
9734         * modules/file-type (Makefile.am): Likewise.
9735         * modules/fileblocks (Makefile.am): Likewise.
9736         * modules/filemode (Makefile.am): Likewise.
9737         * modules/filenamecat (Makefile.am): Likewise.
9738         * modules/fnmatch (Makefile.am): Likewise.
9739         * modules/fopen-safer (Makefile.am): Likewise.
9740         * modules/fpending (Makefile.am): Likewise.
9741         * modules/fprintftime (Makefile.am): Likewise.
9742         * modules/free (Makefile.am): Likewise.
9743         * modules/fsusage (Makefile.am): Likewise.
9744         * modules/ftruncate (Makefile.am): Likewise.
9745         * modules/fts (Makefile.am): Likewise.
9746         * modules/gc (Makefile.am): Likewise.
9747         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
9748         * modules/getaddrinfo (Makefile.am): Likewise.
9749         * modules/getcwd (Makefile.am): Likewise.
9750         * modules/getdelim (Makefile.am): Likewise.
9751         * modules/getdomainname (Makefile.am): Likewise.
9752         * modules/getgroups (Makefile.am): Likewise.
9753         * modules/gethostname (Makefile.am): Likewise.
9754         * modules/gethrxtime (Makefile.am): Likewise.
9755         * modules/getline (Makefile.am): Likewise.
9756         * modules/getloadavg (Makefile.am): Likewise.
9757         * modules/getlogin_r (Makefile.am): Likewise.
9758         * modules/getopt (Makefile.am): Likewise.
9759         * modules/getpass (Makefile.am): Likewise.
9760         * modules/getpass-gnu (Makefile.am): Likewise.
9761         * modules/getsubopt (Makefile.am): Likewise.
9762         * modules/gettime (Makefile.am): Likewise.
9763         * modules/gettimeofday (Makefile.am): Likewise.
9764         * modules/getugroups (Makefile.am): Likewise.
9765         * modules/getusershell (Makefile.am): Likewise.
9766         * modules/glob (Makefile.am): Likewise.
9767         * modules/group-member (Makefile.am): Likewise.
9768         * modules/hard-locale (Makefile.am): Likewise.
9769         * modules/hash (Makefile.am): Likewise.
9770         * modules/hmac-md5 (Makefile.am): Likewise.
9771         * modules/hmac-sha1 (Makefile.am): Likewise.
9772         * modules/human (Makefile.am): Likewise.
9773         * modules/idcache (Makefile.am): Likewise.
9774         * modules/imaxabs (Makefile.am): Likewise.
9775         * modules/imaxdiv (Makefile.am): Likewise.
9776         * modules/inet_ntop (Makefile.am): Likewise.
9777         * modules/inet_pton (Makefile.am): Likewise.
9778         * modules/inttostr (Makefile.am): Likewise.
9779         * modules/isapipe (Makefile.am): Likewise.
9780         * modules/lchown (Makefile.am): Likewise.
9781         * modules/long-options (Makefile.am): Likewise.
9782         * modules/lstat (Makefile.am): Likewise.
9783         * modules/malloc (Makefile.am): Likewise.
9784         * modules/mathl (Makefile.am): Likewise.
9785         * modules/mbchar (Makefile.am): Likewise.
9786         * modules/md2 (Makefile.am): Likewise.
9787         * modules/md4 (Makefile.am): Likewise.
9788         * modules/md5 (Makefile.am): Likewise.
9789         * modules/memcasecmp (Makefile.am): Likewise.
9790         * modules/memchr (Makefile.am): Likewise.
9791         * modules/memcmp (Makefile.am): Likewise.
9792         * modules/memcoll (Makefile.am): Likewise.
9793         * modules/memcpy (Makefile.am): Likewise.
9794         * modules/memmem (Makefile.am): Likewise.
9795         * modules/memmove (Makefile.am): Likewise.
9796         * modules/mempcpy (Makefile.am): Likewise.
9797         * modules/memrchr (Makefile.am): Likewise.
9798         * modules/memset (Makefile.am): Likewise.
9799         * modules/memxor (Makefile.am): Likewise.
9800         * modules/mkancesdirs (Makefile.am): Likewise.
9801         * modules/mkdir (Makefile.am): Likewise.
9802         * modules/mkdir-p (Makefile.am): Likewise.
9803         * modules/mkdtemp (Makefile.am): Likewise.
9804         * modules/mkstemp (Makefile.am): Likewise.
9805         * modules/mktime (Makefile.am): Likewise.
9806         * modules/modechange (Makefile.am): Likewise.
9807         * modules/mountlist (Makefile.am): Likewise.
9808         * modules/nanosleep (Makefile.am): Likewise.
9809         * modules/openat (Makefile.am): Likewise.
9810         * modules/pagealign_alloc (Makefile.am): Likewise.
9811         * modules/physmem (Makefile.am): Likewise.
9812         * modules/poll (Makefile.am): Likewise.
9813         * modules/posixtm (Makefile.am): Likewise.
9814         * modules/posixver (Makefile.am): Likewise.
9815         * modules/putenv (Makefile.am): Likewise.
9816         * modules/quote (Makefile.am): Likewise.
9817         * modules/quotearg (Makefile.am): Likewise.
9818         * modules/raise (Makefile.am): Likewise.
9819         * modules/read-file (Makefile.am): Likewise.
9820         * modules/readline (Makefile.am): Likewise.
9821         * modules/readlink (Makefile.am): Likewise.
9822         * modules/readtokens (Makefile.am): Likewise.
9823         * modules/readutmp (Makefile.am): Likewise.
9824         * modules/realloc (Makefile.am): Likewise.
9825         * modules/regex (Makefile.am): Likewise.
9826         * modules/rename (Makefile.am): Likewise.
9827         * modules/rename-dest-slash (Makefile.am): Likewise.
9828         * modules/rijndael (Makefile.am): Likewise.
9829         * modules/rmdir (Makefile.am): Likewise.
9830         * modules/rpmatch (Makefile.am): Likewise.
9831         * modules/safe-read (Makefile.am): Likewise.
9832         * modules/safe-write (Makefile.am): Likewise.
9833         * modules/same (Makefile.am): Likewise.
9834         * modules/save-cwd (Makefile.am): Likewise.
9835         * modules/savedir (Makefile.am): Likewise.
9836         * modules/setenv (Makefile.am): Likewise.
9837         * modules/settime (Makefile.am): Likewise.
9838         * modules/sha1 (Makefile.am): Likewise.
9839         * modules/sig2str (Makefile.am): Likewise.
9840         * modules/snprintf (Makefile.am): Likewise.
9841         * modules/stdlib-safer (Makefile.am): Likewise.
9842         * modules/stpcpy (Makefile.am): Likewise.
9843         * modules/stpncpy (Makefile.am): Likewise.
9844         * modules/strcase (Makefile.am): Likewise.
9845         * modules/strcasestr (Makefile.am): Likewise.
9846         * modules/strchrnul (Makefile.am): Likewise.
9847         * modules/strcspn (Makefile.am): Likewise.
9848         * modules/strdup (Makefile.am): Likewise.
9849         * modules/strerror (Makefile.am): Likewise.
9850         * modules/strftime (Makefile.am): Likewise.
9851         * modules/strndup (Makefile.am): Likewise.
9852         * modules/strnlen (Makefile.am): Likewise.
9853         * modules/strpbrk (Makefile.am): Likewise.
9854         * modules/strsep (Makefile.am): Likewise.
9855         * modules/strstr (Makefile.am): Likewise.
9856         * modules/strtod (Makefile.am): Likewise.
9857         * modules/strtoimax (Makefile.am): Likewise.
9858         * modules/strtok_r (Makefile.am): Likewise.
9859         * modules/strtol (Makefile.am): Likewise.
9860         * modules/strtoll (Makefile.am): Likewise.
9861         * modules/strtoul (Makefile.am): Likewise.
9862         * modules/strtoull (Makefile.am): Likewise.
9863         * modules/strtoumax (Makefile.am): Likewise.
9864         * modules/strverscmp (Makefile.am): Likewise.
9865         * modules/time_r (Makefile.am): Likewise.
9866         * modules/timegm (Makefile.am): Likewise.
9867         * modules/tmpfile-safer (Makefile.am): Likewise.
9868         * modules/unistd-safer (Makefile.am): Likewise.
9869         * modules/unlinkdir (Makefile.am): Likewise.
9870         * modules/userspec (Makefile.am): Likewise.
9871         * modules/utime (Makefile.am): Likewise.
9872         * modules/utimecmp (Makefile.am): Likewise.
9873         * modules/utimens (Makefile.am): Likewise.
9874         * modules/vasnprintf (Makefile.am): Likewise.
9875         * modules/vasprintf (Makefile.am): Likewise.
9876         * modules/vsnprintf (Makefile.am): Likewise.
9877         * modules/xalloc (Makefile.am): Likewise.
9878         * modules/xgetcwd (Makefile.am): Likewise.
9879         * modules/xnanosleep (Makefile.am): Likewise.
9880         * modules/xreadlink (Makefile.am): Likewise.
9881         * modules/xstrtod (Makefile.am): Likewise.
9882         * modules/xstrtol (Makefile.am): Likewise.
9883         * modules/xstrtold (Makefile.am): Likewise.
9884         * modules/yesno (Makefile.am): Likewise.
9885
9886 2006-10-12  Jim Meyering  <jim@meyering.net>
9887
9888         * m4/getloadavg.m4: Revert the change below.
9889
9890         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
9891         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
9892         fail with a symlink, which is what coreutils' ./bootstrap now
9893         creates by default.
9894
9895 2006-10-12  Bruno Haible  <bruno@clisp.org>
9896
9897         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
9898         mingw.
9899         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
9900         MSVC and mingw explicitly.
9901
9902 2006-10-11  Simon Josefsson  <jas@extundo.com>
9903             Bruno Haible  <bruno@clisp.org>
9904
9905         Add support for multiple gnulib-tool invocations in the scope of a
9906         single configure.ac file.
9907         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
9908         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
9909         with the same contents as the _LIBADD variable.
9910         (func_emit_initmacro_start, func_emit_initmacro_end,
9911         func_emit_initmacro_done): New functions.
9912         (func_import, func_create_testdir): Invoke them. Allow the identifiers
9913         gl_LIBOBJS and gl_LTLIBOBJS.
9914
9915 2006-10-11  Bruno Haible  <bruno@clisp.org>
9916
9917         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
9918         (func_create_testdir): Don't create po/Makefile.am, don't invoke
9919         autoreconf. Instead, invoke autopoint explicitly but move back the
9920         *.m4 files from gnulib.
9921
9922 2006-10-11  Bruno Haible  <bruno@clisp.org>
9923
9924         * gnulib-tool (func_usage): Make module names after --create-testdir
9925         optional.
9926         (func_create_testdir): If no module was specified, use nearly all
9927         modules.
9928
9929 2006-10-12  Jim Meyering  <jim@meyering.net>
9930
9931         Big performance improvement for fts-based tools that use FTS_NOSTAT.
9932         Avoid spurious inode-mismatch problems on non-POSIX file systems.
9933         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
9934         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
9935         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
9936         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
9937         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
9938         (fts_set_stat_required): New function.
9939         (fts_open): Defer the calls to fts_stat, if possible or requested.
9940         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
9941         into fts_stat itself.
9942         (fts_read): Perform any required (deferred) fts_stat call.
9943         (fts_build): Likewise, for the directory we're about to open and read.
9944         In the readdir loop, carefully decide whether each entry will require
9945         an eventual call to fts_stat, using dirent.d_type info if available.
9946         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
9947         a command line argument into this function.  Update all callers.
9948         Map a return value of FTS_DOT to FTS_D for a command line argument.
9949         * modules/fts (Depends-on): Add d-type.  Alphabetize.
9950         Thanks to Miklos Szeredi for his tenacity and for the initial
9951         bug report about "find" failing on a FUSE-based file system.
9952
9953         * lib/fts.c (fts_open): Use consistent indentation.
9954
9955 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
9956
9957         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
9958         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
9959         reported by Jim Meyering.  All uses of cache variables renamed
9960         to match Autoconf's.
9961         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
9962         the other one.
9963
9964         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
9965         Fix misspelling in diagnostic.
9966
9967 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
9968
9969         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
9970         defined.  Problem reported by Matthew Woehlke.
9971
9972         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
9973         Add support for Tandem NonStop R series.
9974         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
9975         Use new macro.
9976
9977         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
9978         (has_trailing_slash): Omit size arg; all callers changed.
9979         Omit 'inline', since it doesn't help performance and we'd
9980         need to configure it.
9981         Don't count //, ///, etc. as having a trailing slash.
9982         As a side effect, this removes a C99ism reported by Matthew Woehlke.
9983         (rpl_rename_dest_slash): On failure, use rename's errno rather
9984         than (in some cases) an incorrect or junk errno.
9985         Simplify code by removing need to compute length; this does
9986         cause it to make two passes instead of one over the file name,
9987         but it's worth it.
9988
9989         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
9990         change, since Autoconf's version may no longer be appropriate now
9991         that we are using CVS Autoconf's version.  Add support for Tandem.
9992
9993 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
9994             Bruno Haible  <bruno@clisp.org>
9995
9996         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
9997         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
9998         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
9999         gl_AC_TYPE_LONG_LONG.
10000
10001         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
10002         instead of HAVE_LONG_LONG.
10003         * lib/printf-args.c (printf_fetchargs): Likewise.
10004         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
10005         * lib/vasnprintf.c (VASNPRINTF): Likewise.
10006         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
10007         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
10008         gl_AC_TYPE_LONG_LONG.
10009
10010 2006-10-11  Bruno Haible  <bruno@clisp.org>
10011
10012         * m4/longlong.m4: Add comments.
10013         * m4/ulonglong.m4: Likewise.
10014
10015 2006-10-10  Bruno Haible  <bruno@clisp.org>
10016
10017         Make it possible to #define stpcpy, strdup to aliases.
10018         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
10019         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
10020
10021 2006-10-10  Bruno Haible  <bruno@clisp.org>
10022
10023         Make it possible to #define gcd to an alias.
10024         * lib/gcd.c: Include config.h.
10025
10026 2006-10-10  Bruno Haible  <bruno@clisp.org>
10027
10028         Make it possible to #define c_isascii to an alias.
10029         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
10030         defined. Undefine the macros before defining them, to avoid gcc
10031         warnings.
10032         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
10033         define NO_C_CTYPE_MACROS early.
10034
10035 2006-10-10  Bruno Haible  <bruno@clisp.org>
10036
10037         Make it possible to #define set_program_name to an alias.
10038         * lib/progname.c: Don't undefine set_program_name; instead, undefine
10039         ENABLE_RELOCATABLE early.
10040
10041 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
10042
10043         Port to Tandem NSK OSS, which has 64-bit signed int but at most
10044         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
10045         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
10046         More generally, don't assume that 64-bit signed int is available
10047         if unsigned int is, and vice versa.
10048         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
10049         unsigned symbols, not on their signed counterparts.
10050         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
10051         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
10052         (UINT64_C, UINTMAX_C):
10053         Likewise.
10054         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
10055         unsigned counterparts.
10056         (Have_long_long, Unsigned): New macros.
10057         (Int): Renamed from INT.
10058         (strtoimax): Use the new macros.
10059         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
10060         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
10061         * modules/inttypes (inttypes.h): Substitute
10062         HAVE_UNSIGNED_LONG_LONG_INT.
10063         * modules/stdint (stdint.h): Likewise.
10064         (Files): Add m4/ulonglong.m4.
10065
10066 2006-10-10  Bruno Haible  <bruno@clisp.org>
10067
10068         Fix a gcc -Wshadow warning.
10069         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
10070         to 'bucket'.
10071         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
10072         gl_linked_indexof_from_to): Likewise.
10073         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
10074         Likewise.
10075         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
10076         Likewise.
10077         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
10078         Reported by Eric Blake.
10079
10080 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
10081
10082         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
10083         for NetBSD.  Problem reported by Bruno Haible.
10084
10085 2006-10-09  Jim Meyering  <jim@meyering.net>
10086
10087         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
10088         Patch from Bruno Haible.
10089
10090 2006-10-09  Jim Meyering  <jim@meyering.net>
10091
10092         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
10093         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
10094         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
10095
10096 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
10097
10098         Don't include <config.h> twice; this doesn't work in some cases,
10099         e.g., when config.h has "#define intmax_t long long int" and
10100         we include <config.h>, <inttypes.h>, <config.h> in that order.
10101         Problem reported by Matthew Woehlke in:
10102         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
10103         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
10104         * lib/fts-cycle.c: Don't include config.h.
10105         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
10106         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
10107         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
10108         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
10109         inttypes.h.
10110         * lib/xstrtoumax.c: Likewise.
10111         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
10112         __strtol and the like, so that this module is more like its siblings.
10113         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
10114         Remove; no longer needed now that we assume gnulib inttypes.h.
10115
10116 2006-10-08  Bruno Haible  <bruno@clisp.org>
10117
10118         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
10119         option.
10120
10121 2006-10-07  Jim Meyering  <jim@meyering.net>
10122
10123         * modules/inttypes (inttypes.h): Revert what seems to have been
10124         an inadvertent part of today's change: use "|", not "/" in the
10125         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
10126
10127 2006-10-07  Bruno Haible  <bruno@clisp.org>
10128
10129         * modules/sublist: New file.
10130
10131 2006-10-07  Bruno Haible  <bruno@clisp.org>
10132
10133         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
10134         * modules/argz (argz.h): Likewise.
10135         * modules/arpa_inet (arpa/inet.h): Likewise.
10136         * modules/byteswap (byteswap.h): Likewise.
10137         * modules/configmake (configmake.h): Likewise.
10138         * modules/fcntl (fcntl.h): Likewise.
10139         * modules/fnmatch (fnmatch.h): Likewise.
10140         * modules/getopt (getopt.h): Likewise.
10141         * modules/glob (glob.h): Likewise.
10142         * modules/inttypes (inttypes.h): Likewise.
10143         * modules/netinet_in (netinet/in.h): Likewise.
10144         * modules/poll (poll.h): Likewise.
10145         * modules/stdbool (stdbool.h): Likewise.
10146         * modules/stdint (stdint.h): Likewise.
10147         * modules/sys_select (sys/select.h): Likewise.
10148         * modules/sys_socket (sys/socket.h): Likewise.
10149         * modules/sys_stat (sys/stat.h): Likewise.
10150         * modules/sysexits (sysexits.h): Likewise.
10151         * modules/unistd (unistd.h): Likewise.
10152         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
10153         Add a "DO NOT EDIT" comment to the generated file.
10154         (func_import): Likewise for gnulib-comp.m4.
10155
10156 2006-10-07  Bruno Haible  <bruno@clisp.org>
10157
10158         * lib/gl_sublist.h: New file.
10159         * lib/gl_sublist.c: New file.
10160
10161 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
10162
10163         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
10164         name (relative to the original working directory) and the file
10165         name component (relative to the temporary working directory).  All
10166         callers changed.
10167         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
10168         * lib/mkdir-p.c (make_dir_parents): Likewise.
10169         * lib/mkdir-p.h (make_dir_parents): Likewise.
10170
10171 2006-10-06  Eric Blake  <ebb9@byu.net>
10172
10173         Define several macros for use by the clean-temp module.
10174         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
10175         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
10176         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
10177
10178         * lib/clean-temp.h (close_stream_temp): New declaration.
10179         * lib/clean-temp.c (includes): Pull in headers according to what
10180         other modules are in use.
10181         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
10182
10183 2006-10-06  Bruno Haible  <bruno@clisp.org>
10184
10185         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
10186         instead of fopen, fwriteerror.
10187
10188 2006-10-06  Bruno Haible  <bruno@clisp.org>
10189
10190         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
10191         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
10192         int.
10193         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
10194         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
10195         Return an error indicator.
10196         Suggested by Eric Blake.
10197
10198 2006-10-06  Bruno Haible  <bruno@clisp.org>
10199
10200         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
10201         Reported by Eric Blake.
10202
10203 2006-10-06  Bruno Haible  <bruno@clisp.org>
10204
10205         * modules/closeout (Description): Mention stderr too.
10206
10207 2006-10-06  Bruno Haible  <bruno@clisp.org>
10208         and Paul Eggert  <eggert@cs.ucla.edu>
10209
10210         * lib/closeout.c (close_stdout): Also close stderr.
10211         * lib/closeout.h: Update comment.
10212
10213 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
10214
10215         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
10216         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
10217         * lib/dirchownmod.c: Include lchown.h.
10218         * lib/lchown.c: Don't include files that lchown.h now includes.
10219         Don't declare chown, since lchown.h now does that.
10220         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
10221         (lchown): Define to rpl_chown if lchown is declared but
10222         does not exist.  Declare using a prototype if lchown is not
10223         declared.  Add a copyright notice.
10224         * lib/mkstemp.h: Include <unistd.h>.
10225         * lib/openat.c: Include lchown.h.
10226
10227         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
10228         we now test for that separately.
10229         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
10230         rather than O_NOFOLLOW, when testing whether it's possible to
10231         avoid a race condition reliably.
10232         * lib/savewd.c (savewd_chdir): Likewise.
10233
10234         Remove macros that are no longer needed now that stdint.h is
10235         reliable.
10236         * lib/fsusage.c (UINTMAX_MAX): Remove.
10237         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
10238         * lib/utimecmp.c (SIZE_MAX): Remove.
10239
10240         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
10241
10242         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
10243         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
10244         O_NOATIME works.
10245
10246 2006-10-05  Bruno Haible  <bruno@clisp.org>
10247
10248         * lib/gl_list.h (gl_sortedlist_search_from_to,
10249         gl_sortedlist_indexof_from_to): New declarations.
10250         (gl_list_implementation): New fields sortedlist_search_from_to,
10251         sortedlist_indexof_from_to.
10252         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
10253         inline functions.
10254         * lib/gl_list.c (gl_sortedlist_search_from_to,
10255         gl_sortedlist_indexof_from_to): New functions.
10256         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
10257         function.
10258         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
10259         (gl_array_sortedlist_search_from_to): New function.
10260         (gl_array_list_implementation): Update.
10261         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
10262         function.
10263         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
10264         (gl_carray_sortedlist_search_from_to): New function.
10265         (gl_carray_list_implementation): Update.
10266         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
10267         gl_linked_sortedlist_indexof_from_to): New functions.
10268         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
10269         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
10270         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
10271         gl_tree_sortedlist_indexof_from_to): New functions.
10272         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
10273         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
10274         Update.
10275         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
10276         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
10277         Update.
10278
10279 2006-10-05  Bruno Haible  <bruno@clisp.org>
10280
10281         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
10282         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
10283         (struct gl_list_implementation): Add fields search_from_to,
10284         indexof_from_to. Remove fields search, indexof.
10285         (gl_list_search): Use the search_from_to method.
10286         (gl_list_search_from, gl_list_search_from_to): New functions.
10287         (gl_list_indexof): Use the indexof_from_to method.
10288         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
10289         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
10290         (gl_list_search_from, gl_list_search_from_to): New functions.
10291         (gl_list_indexof): Use the indexof_from_to method.
10292         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
10293         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
10294         gl_array_indexof. Add start_index, end_index arguments.
10295         (gl_array_search_from_to): Renamed from gl_array_search. Add
10296         start_index, end_index arguments.
10297         (gl_array_remove, gl_array_list_implementation): Update.
10298         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
10299         gl_carray_indexof. Add start_index, end_index arguments.
10300         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
10301         start_index, end_index arguments.
10302         (gl_carray_remove, gl_carray_list_implementation): Update.
10303         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
10304         gl_linked_search. Add start_index, end_index arguments.
10305         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
10306         start_index, end_index arguments.
10307         (gl_linked_remove): Update.
10308         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
10309         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
10310         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
10311         field to 'size_t'.
10312         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
10313         gl_tree_search. Add start_index, end_index arguments.
10314         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
10315         start_index, end_index arguments.
10316         (gl_tree_remove): Update.
10317         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
10318         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
10319         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
10320         function.
10321         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
10322         gl_tree_search. Add start_index, end_index arguments.
10323         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
10324         start_index, end_index arguments.
10325         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
10326         Update.
10327         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
10328
10329 2006-10-05  Bruno Haible  <bruno@clisp.org>
10330
10331         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
10332
10333         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
10334         fwriteerror_temp): New declarations.
10335         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
10336         (descriptors): New variable.
10337         (cleanup): First, close the descriptors.
10338         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
10339         fclose_temp, fwriteerror_temp): New functions.
10340
10341 2006-10-04  Jim Meyering  <jim@meyering.net>
10342
10343         * lib/fts.c (fts_open): Tiny comment change.
10344
10345 2006-10-04  Bruno Haible  <bruno@clisp.org>
10346
10347         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
10348         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
10349         gl_LOCK_BODY.
10350         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
10351         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
10352         gl_LOCK_EARLY_BODY.
10353         (gl_LOCK): Require gl_LOCK_BODY.
10354
10355 2006-10-04  Bruno Haible  <bruno@clisp.org>
10356
10357         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
10358         (gl_oset_search_atleast): New declaration.
10359         (struct gl_oset_implementation): Add field 'search_atleast'.
10360         (gl_oset_search_atleast): New inline function.
10361         * lib/gl_oset.c (gl_oset_search_atleast): New function.
10362         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
10363         (gl_array_oset_implementation): Update.
10364         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
10365         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
10366         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
10367
10368 2006-10-04  Bruno Haible  <bruno@clisp.org>
10369
10370         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
10371
10372 2006-10-03  Bruno Haible  <bruno@clisp.org>
10373
10374         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
10375         from gl_avltreehash_list_implementation.
10376
10377 2006-10-03  Bruno Haible  <bruno@clisp.org>
10378
10379         * lib/gl_oset.c (gl_oset_add): Fix return type.
10380
10381 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
10382
10383         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
10384
10385 2006-10-02  Eric Blake  <ebb9@byu.net>
10386
10387         * modules/strnlen (Depends-on): Add extensions.
10388
10389 2006-10-02  Eric Blake  <ebb9@byu.net>
10390
10391         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
10392         definition in 2.60+.
10393
10394 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
10395
10396         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
10397         checks.
10398
10399 2006-10-02  Bruno Haible  <bruno@clisp.org>
10400
10401         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
10402         to the AUTOMAKE_OPTIONS.
10403         Reported by Jim Meyering.
10404
10405 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
10406
10407         Work around bug in Solaris 10 /proc file system:
10408         /proc/self/fd/NNN/.. isn't the parent directory of
10409         the directory whose file descriptor is NNN.  This needs to
10410         be worked around at run time, not compile time, since a
10411         program might be built on Solaris 8, where things work, and
10412         run on Solaris 10.
10413         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
10414         to use the following interface instead:
10415         (OPENAT_BUFFER_SIZE): New macro.
10416         (openat_proc_name): New function.
10417         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
10418         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
10419         Likewise.
10420         * lib/openat-proc.c: New file.
10421         * modules/openat (Files): Add lib/openat-proc.c.
10422         (Depends-on): Add same-inode, stdbool.
10423         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
10424
10425 2006-09-29  Bruno Haible  <bruno@clisp.org>
10426
10427         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
10428         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
10429         argument. Set stdout_closed before testing for ferror, not after.
10430         (fwriteerror, fwriteerror_no_ebadf): New functions.
10431
10432 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10433
10434         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
10435
10436 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
10437
10438         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
10439         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
10440
10441 2006-09-28  Jim Meyering  <jim@meyering.net>
10442
10443         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
10444         Include <unistd.h>.
10445
10446 2006-09-28  Bruno Haible  <bruno@clisp.org>
10447
10448         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
10449         * modules/linkedhash-list (Depends-on): Likewise.
10450         * modules/rbtreehash-list (Depends-on): Likewise.
10451
10452 2006-09-28  Bruno Haible  <bruno@clisp.org>
10453
10454         * lib/strndup.h: Simplify the redefinition of strndup.
10455         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
10456         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
10457
10458 2006-09-28  Bruno Haible  <bruno@clisp.org>
10459
10460         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
10461         * lib/gl_linkedhash_list.c: Likewise.
10462         * lib/gl_rbtreehash_list.c: Likewise.
10463
10464 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
10465
10466         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
10467         getaddrinfo.
10468
10469         * lib/__fpending.h: Don't include <stdio_ext.h> unless
10470         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
10471         it causes <stdio_ext.h> to cause a compile-time error.
10472         Problem reported by Nelson H. F. Beebe.
10473         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
10474         of HAVE_DECL___PENDING.
10475
10476         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
10477         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
10478         declaration.
10479
10480 2006-09-27  Jim Meyering  <jim@meyering.net>
10481
10482         This file could end up with a definition for a function
10483         named __strndup, rather than rpl_strndup on a system with
10484         incomplete weak_alias support.
10485         * lib/strndup.c (strndup): Rename from __strndup.
10486         Remove #defines that used to map __strndup to strndup.
10487         Don't use K&R prototypes.
10488         Remove LIBC-related code, since this file is not sync'd with glibc.
10489         * lib/strndup.h: Revamp, accordingly.
10490         * m4/strndup.m4: Modernize.
10491
10492 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
10493
10494         * modules/savewd (Depends-on): Add 'raise'.
10495         * lib/savewd.c: Include <signal.h>, for 'raise'.
10496
10497 2006-09-26  Jim Meyering  <jim@meyering.net>
10498
10499         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
10500         when we detect Darwin 8.7.0's acl_get_file bug.
10501         Rearrange to perform the new (below) run-test while $LIBS
10502         contains any acl-related library.  Set USE_ACL at the end.
10503         (gl_ACL_GET_FILE): New function.
10504
10505 2006-09-26  Eric Blake  <ebb9@byu.net>
10506
10507         * lib/verror.c: Include <config.h> unconditionally.
10508
10509 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
10510
10511         * modules/clock-time (Maintainer): Add self.
10512         * modules/getlogin_r (Depends-on): Add extensions.
10513
10514 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10515
10516         * modules/clock-time: New module.
10517         * modules/nanosleep (Depends-on): Add clock-time.
10518         * modules/gethrxtime (Depends-on): Likewise.
10519         * modules/gettime (Depends-on): Likewise.
10520         * modules/settime (Depends-on): Likewise.
10521
10522         * modules/fts-lgpl: Depend on openat.
10523         * modules/mkancesdirs: Depend on savewd.
10524         * modules/mkdir-p: Likewise.
10525
10526 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10527
10528         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
10529
10530         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
10531         `gl_have_arbitrary_file_name_length_limit' to
10532         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
10533         actually works between configure runs.
10534
10535 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10536             Bruno Haible  <bruno@clisp.org>
10537
10538         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
10539
10540 2006-09-25  Jim Meyering  <jim@meyering.net>
10541
10542         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
10543         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
10544
10545 2006-09-25  Eric Blake  <ebb9@byu.net>
10546
10547         * gnulib-tool (func_import, func_create_testdir): Fix typos in
10548         exec's in 2006-09-18 patch when shuffling fds.
10549
10550 2006-09-25  Bruno Haible  <bruno@clisp.org>
10551
10552         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
10553         Reported by Jim Meyering.
10554
10555 2006-09-24  Jim Meyering  <jim@meyering.net>
10556
10557         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
10558         compare a pointer against a literal "0".  That caused failures with
10559         at least HP-UX's hpcc.
10560
10561 2006-09-22  Simon Josefsson  <jas@extundo.com>
10562
10563         * modules/gc-sha1:
10564         * modules/gc-md4:
10565         * modules/gc-hmac-sha1:
10566         * modules/gc-hmac-md5:
10567         * modules/gc-des:
10568         * modules/gc-arcfour: Distribute more files.
10569
10570 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10571
10572         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
10573         (gl_linked_iterator_from_to): Initialize struct completely.
10574         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
10575         (gl_tree_iterator_from_to): Likewise
10576         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
10577         * lib/gl_array_list.c [lint] (gl_array_iterator)
10578         (gl_array_iterator_from_to): Likewise.
10579         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
10580         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
10581         (gl_carray_iterator_from_to): Likewise.
10582
10583         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
10584         * lib/md4.c (md4_process_block): Remove unused variable.
10585         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
10586         parentheses for clarity.
10587
10588 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10589
10590         * modules/bison-i18n (Depends-on): Add gettext.
10591
10592 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10593
10594         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
10595         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
10596         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
10597         also add missing comma that caused broken test.
10598         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
10599         stdlib.h, for `abort'.
10600         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
10601         variables.
10602         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
10603         include unistd.h if present, for `rmdir'.
10604         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
10605         variables.
10606         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
10607         in the process include standard headers for prototypes.
10608         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
10609         gets declared on GNU/Linux.
10610         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
10611         unistd.h, for `rmdir'.
10612         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
10613
10614         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
10615         always true.
10616         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
10617
10618         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
10619
10620 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10621
10622         * gnulib-tool (func_version): Create output all at once.  This
10623         may help avoid triggering unnecessary SIGPIPEs, and at any
10624         rate it doesn't hurt.
10625
10626 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10627             Bruno Haible  <bruno@clisp.org>
10628
10629         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
10630         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
10631         * m4/signed.m4 (bh_C_SIGNED): Likewise.
10632
10633         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
10634         (gl_FUNC_VASPRINTF): Invoke it.
10635
10636 2006-09-22  Bruno Haible  <bruno@clisp.org>
10637
10638         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
10639         getloadavg.c as first argument.
10640
10641 2006-09-22  Bruno Haible  <bruno@clisp.org>
10642
10643         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
10644         at the beginning of the gl_INIT macro.
10645         * modules/getloadavg (configure.ac): Pass $gl_source_base to
10646         gl_GETLOADAVG.
10647
10648 2006-09-22  Bruno Haible  <bruno@clisp.org>
10649
10650         * gnulib-tool (func_create_megatestdir): Don't include the config-h
10651         module.
10652         Suggested by Ralf Wildenhues.
10653
10654 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
10655
10656         Import this patch from libc:
10657
10658         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
10659
10660         * lib/regex_internal.c (re_string_reconstruct): Handle
10661         offset < pstr->valid_raw_len && pstr->offsets_needed case.
10662         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
10663         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
10664         re_string_context_at.
10665
10666         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
10667         now requires it.
10668         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
10669         gl_REGEX now does it for us.
10670         (gl_REGEX): Add test taken from
10671         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
10672
10673         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
10674         Check that large offsets work.  Modernize Autoconf usages.
10675         Prefer "yes" to mean a good thing rather than a bad.
10676         Don't put "#define mkstemp" in config.h, as this might interfere
10677         with standard system headers that "#define mkstemp mkstemp64".
10678
10679         * modules/mkstemp (Depends-on): Add extensions, so that
10680         mkstemp is visible on some platforms.
10681         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
10682         (Include): Change to "mkstemp.h" from <stdlib.h>.
10683         (Files): Add mkstemp.h.
10684
10685         * lib/mkstemp.h: New file, since some standard headers
10686         #define mkstemp.
10687         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
10688         Include "mkstemp.h".
10689         Make the _LIBC code resemble glibc original more,
10690         e.g., use K&R style.
10691         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
10692         (mkstemp): Remove, since mkstemp.h does this for us.
10693         * lib/stdlib--.h: Include mkstemp.h.
10694
10695         Import this patch from libc:
10696
10697         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
10698
10699         * lib/tempname.c (__gen_tempname): Change attempts_min
10700         into a macro.  Use preprocessor to decide how to initialize
10701         attempts [Coverity CID 67].
10702
10703 2006-09-20  Bruno Haible  <bruno@clisp.org>
10704
10705         * lib/mkdtemp.c: Import from libc.
10706         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
10707                 * sysdeps/posix/tempname.c (__gen_tempname): Change
10708                 attempts_min into a macro.  Use preprocessor to decide how to
10709                 initialize attempts [Coverity CID 67].
10710         2001-11-27  Paul Eggert  <eggert@twinsun.com>
10711                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
10712                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
10713
10714 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10715
10716         * gnulib-tool (func_exit): New function, to allow to pass the
10717         exit status portably through the trap.  Use everywhere.
10718         (--help, --version): Signal a write error.
10719         (trap): catch SIGPIPE, for write errors.
10720         Exit at the end of the trap, with the correct exit status.
10721
10722 2006-09-19  Karl Berry  <karl@gnu.org>
10723
10724         * doc/gnulib.texi: note about the license texinfo files.
10725
10726 2006-09-19  Eric Blake  <ebb9@byu.net>
10727
10728         * gnulib-tool: Avoid space-tab.
10729
10730 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
10731
10732         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
10733         that prevented coreutils 6.1 from building.  Problem reported
10734         by Petter Reinholdtsen.
10735
10736 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
10737
10738         * gnulib-tool (avoidlist): Fix typo that broke options like
10739         --avoid=lock that are used by coreutils bootstrap.
10740
10741 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
10742
10743         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
10744         more systematically.
10745
10746 2006-09-18  Jim Meyering  <jim@meyering.net>
10747
10748         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
10749
10750 2006-09-18  Bruno Haible  <bruno@clisp.org>
10751
10752         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
10753
10754 2006-09-18  Bruno Haible  <bruno@clisp.org>
10755
10756         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
10757         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
10758         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
10759         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
10760         * m4/gettext.m4: Require autoconf >= 2.52.
10761         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
10762         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
10763         of gl_cv_header_inttypes_h.
10764
10765 2006-09-18  Bruno Haible  <bruno@clisp.org>
10766
10767         * lib/javaversion.c: Include configmake.h.
10768
10769 2006-09-18  Bruno Haible  <bruno@clisp.org>
10770
10771         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
10772         avoid that the while loops be executed in a subshell.
10773
10774 2006-09-18  Bruno Haible  <bruno@clisp.org>
10775
10776         * MODULES.html.sh (func_module): Break long lines.
10777         Suggested by Bruce Korb <bkorb@gnu.org>.
10778
10779 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10780
10781         Speed up by a factor of 1.12.
10782         * gnulib-tool (nl): New variable.
10783         (func_import): Rewrite include directive extraction to only read each
10784         directive once.
10785
10786 2006-09-17  Bruno Haible  <bruno@clisp.org>
10787
10788         * modules/javaversion (Makefile.am): Remove DEFS setting.
10789         (Depends-on): Add configmake, for PKGDATADIR definition.
10790
10791 2006-09-17  Bruno Haible  <bruno@clisp.org>
10792
10793         * gnulib-tool (func_create_testdir): Rewrite all files at once.
10794
10795 2006-09-17  Bruno Haible  <bruno@clisp.org>
10796
10797         * gnulib-tool (func_append): New function, stolen from libtool.m4.
10798         (func_modules_transitive_closure, func_modules_add_dummy,
10799         func_modules_to_filelist, func_import, func_create_testdir,
10800         func_create_megatestdir, ...): Use it wherever possible.
10801         Suggested by Ralf Wildenhues.
10802
10803 2006-09-16  Karl Berry  <karl@gnu.org>
10804
10805         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
10806         to avoid sectioning errors.
10807         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
10808         [ifinfo]: blank line after @center-ed titles.
10809         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
10810         Spell FSF address consistently with others.
10811         (These changes approved by rms.)
10812
10813 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10814
10815         Speed up by a factor of 1.61.
10816         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
10817         already checked module names again.
10818
10819 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10820
10821         Speed up by a factor of 1.13.
10822         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
10823         for new_files, and the input to func_add_or_update.
10824
10825 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10826
10827         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
10828         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
10829
10830 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10831
10832         * modules/mkancesdirs (Depends-on): Add fcntl.
10833         * modules/savewd: New file.
10834         * MODULES.html.sh (File system functions): Add savewd.
10835
10836         * modules/configmake (Makefile.am): Add support for the
10837         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
10838
10839 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10840
10841         * m4/savewd.m4: New file.
10842
10843 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
10844
10845         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
10846         (dirchownmod): New arg FD.  All callers changed.
10847         Use FD rather than opening the directory ourself, as opening is
10848         now the caller's responsibility.
10849         * lib/dirchownmod.h: Likewise.
10850         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
10851         hosts that require <sys/types.h> before <sys/stat.h>.  Include
10852         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
10853         (test_dir): Remove.
10854         (mkancesdirs): Return length of prefix of FILE that has already
10855         been made, or -2 if there is a child doing the work.  Redo
10856         algorithm so that it is O(N) rather than O(N**2).  Optimize away
10857         ".", and treat ".." specially since it might stray back into
10858         already-created areas.  Use a subprocess if necessary.  New arg
10859         WD; all users changed.  MAKE_DIR function should now return 1
10860         if it creates a directory that is not readable.  Return -2 if
10861         a child process is spun off.
10862         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
10863         Adjust signature to match code.
10864         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
10865         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
10866         all users changed.
10867         * lib/savewd.c, lib/savewd.h: New files.
10868
10869 2006-09-15  Jim Meyering  <jim@meyering.net>
10870
10871         * modules/rename-dest-slash: New module.
10872         * MODULES.html.sh (posix_compat): Add it here.
10873
10874         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
10875
10876 2006-09-15  Jim Meyering  <jim@meyering.net>
10877
10878         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
10879         file.
10880
10881         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
10882
10883 2006-09-15  Jim Meyering  <jim@meyering.net>
10884
10885         * lib/rename-dest-slash.c (has_trailing_slash): Use
10886         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
10887         (rpl_rename_dest_slash): Perform the cheaper trailing slash
10888         test before testing whether SRC is a directory.
10889         Suggestions from Bruno Haible.
10890
10891         Avoid a warning about an unused variable.
10892         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
10893         into the #ifdef block where it's used.
10894
10895         * lib/rename-dest-slash.c: New file.
10896
10897 2006-09-14  Bruno Haible  <bruno@clisp.org>
10898
10899         * lib/allocsa.c: Include <config.h> unconditionally.
10900         * lib/asnprintf.c: Likewise.
10901         * lib/asprintf.c: Likewise.
10902         * lib/c-strcasecmp.c: Likewise.
10903         * lib/c-strcasestr.c: Likewise.
10904         * lib/c-strncasecmp.c: Likewise.
10905         * lib/c-strstr.c: Likewise.
10906         * lib/classpath.c: Likewise.
10907         * lib/clean-temp.c: Likewise.
10908         * lib/concatpath.c: Likewise.
10909         * lib/copy-file.c: Likewise.
10910         * lib/csharpcomp.c: Likewise.
10911         * lib/csharpexec.c: Likewise.
10912         * lib/execute.c: Likewise.
10913         * lib/fatal-signal.c: Likewise.
10914         * lib/findprog.c: Likewise.
10915         * lib/fwriteerror.c: Likewise.
10916         * lib/gl_array_list.c: Likewise.
10917         * lib/gl_array_oset.c: Likewise.
10918         * lib/gl_avltree_list.c: Likewise.
10919         * lib/gl_avltree_oset.c: Likewise.
10920         * lib/gl_avltreehash_list.c: Likewise.
10921         * lib/gl_carray_list.c: Likewise.
10922         * lib/gl_linked_list.c: Likewise.
10923         * lib/gl_linkedhash_list.c: Likewise.
10924         * lib/gl_list.c: Likewise.
10925         * lib/gl_oset.c: Likewise.
10926         * lib/gl_rbtree_list.c: Likewise.
10927         * lib/gl_rbtree_oset.c: Likewise.
10928         * lib/gl_rbtreehash_list.c: Likewise.
10929         * lib/imaxabs.c: Likewise.
10930         * lib/imaxdiv.c: Likewise.
10931         * lib/javacomp.c: Likewise.
10932         * lib/javaexec.c: Likewise.
10933         * lib/javaversion.c: Likewise.
10934         * lib/linebreak.c: Likewise.
10935         * lib/localcharset.c: Likewise.
10936         * lib/lock.c: Likewise.
10937         * lib/mbchar.c: Likewise.
10938         * lib/mbswidth.c: Likewise.
10939         * lib/mkdtemp.c: Likewise.
10940         * lib/pipe.c: Likewise.
10941         * lib/printf-args.c: Likewise.
10942         * lib/printf-parse.c: Likewise.
10943         * lib/progname.c: Likewise.
10944         * lib/progreloc.c: Likewise.
10945         * lib/readlink.c: Likewise.
10946         * lib/sh-quote.c: Likewise.
10947         * lib/stpcpy.c: Likewise.
10948         * lib/stpncpy.c: Likewise.
10949         * lib/strcasecmp.c: Likewise.
10950         * lib/strcasestr.c: Likewise.
10951         * lib/strcspn.c: Likewise.
10952         * lib/striconv.c: Likewise.
10953         * lib/strncasecmp.c: Likewise.
10954         * lib/strnlen1.c: Likewise.
10955         * lib/strstr.c: Likewise.
10956         * lib/strtok_r.c: Likewise.
10957         * lib/tls.c: Likewise.
10958         * lib/tmpdir.c: Likewise.
10959         * lib/unicodeio.c: Likewise.
10960         * lib/unsetenv.c: Likewise.
10961         * lib/vasnprintf.c: Likewise.
10962         * lib/vasprintf.c: Likewise.
10963         * lib/wait-process.c: Likewise.
10964         * lib/xallocsa.c: Likewise.
10965         * lib/xsetenv.c: Likewise.
10966         * lib/xstriconv.c: Likewise.
10967
10968 2006-09-13  Simon Josefsson  <jas@extundo.com>
10969
10970         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
10971         that internally, suggested by Ralf Wildenhues
10972         <Ralf.Wildenhues@gmx.de>.
10973
10974 2006-09-13  Simon Josefsson  <jas@extundo.com>
10975
10976         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
10977         @LIBOBJS@.
10978         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
10979
10980 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
10981
10982         * lib/_fpending.c: Include <config.h> unconditionally, since we no
10983         longer worry about uses that don't define HAVE_CONFIG_H.
10984         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
10985         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
10986         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
10987         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
10988         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
10989         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
10990         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
10991         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
10992         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
10993         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
10994         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
10995         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
10996         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
10997         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
10998         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
10999         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
11000         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
11001         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
11002         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
11003         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
11004         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
11005         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
11006         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
11007         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
11008         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
11009         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
11010         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
11011         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
11012         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
11013         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
11014         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
11015         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
11016         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
11017         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
11018         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
11019         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
11020         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
11021         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
11022         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
11023         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
11024         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
11025         Likewise.
11026
11027 2006-09-13  Eric Blake  <ebb9@byu.net>
11028
11029         * lib/getopt.c: Fix typo in last commit.
11030
11031 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
11032
11033         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
11034         dgettext.
11035
11036 2006-09-12  Jim Meyering  <jim@meyering.net>
11037
11038         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
11039         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
11040         Reported by Nelson H. F. Beebe.
11041
11042 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
11043
11044         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
11045         program_invocation_name and program_invocation_short_name are
11046         initialized.
11047         * lib/argp-namefrob.h: Move declarations of program_invocation_name
11048         and program_invocation_short_name to argp.h, so they are visible
11049         to user programs.
11050         * lib/argp.h: Likewise
11051
11052 2006-09-10  Bruno Haible  <bruno@clisp.org>
11053
11054         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
11055         m4/inttypes_h.m4, m4/uintmax_t.m4.
11056
11057 2006-09-10  Bruno Haible  <bruno@clisp.org>
11058
11059         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
11060         gl_AC_TYPE_UINTMAX_T.
11061
11062 2006-09-10  Bruno Haible  <bruno@clisp.org>
11063
11064         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
11065
11066 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11067
11068         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
11069         convention.  Text proposed by Bruno Haible.
11070         (struct argp_option): Document the use of N_() wrappers.
11071
11072         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
11073         '\v', and translate the two parts separately, instead of feeding
11074         the whole string to gettext.  This allows to exclude
11075         '\v' from the strings visible to the translator by writing doc
11076         strings as N_("..") "\v" N_("..").
11077
11078 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
11079
11080         * config/srclist.txt: Undo latest change; the bug was fixed.
11081
11082 2006-09-09  Bruno Haible  <bruno@clisp.org>
11083
11084         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
11085         assignments if building a library without libtool.
11086         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
11087         in func_emit_lib_Makefile_am.
11088         (func_import): When building a static library libfoo.a, arrange to
11089         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
11090         (func_create_testdir): Likewise.
11091         * modules/gc (configure.ac, Makefile.am): If building statically,
11092         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
11093         * modules/iconvme (configure.ac, Makefile.am): Likewise.
11094         * modules/striconv (configure.ac, Makefile.am): Likewise.
11095         Based on a suggestion by Ralf Wildenhues.
11096
11097 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11098
11099         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
11100         Check for unistd.h too, since Autoconf doesn't assume POSIX.
11101         Also:
11102
11103         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11104         Add year_2050_test to catch glibc bug 2821
11105         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
11106
11107         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11108         Prefer #ifdef to #if.
11109
11110         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
11111         Return from 'main' instead of calling 'exit'.
11112
11113 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11114
11115         * lib/mktime.c (guess_time_tm): Fix bug where mktime
11116         returned the maximum time_t value rather than (time_t) -1.
11117         Problem originally reported by William Bardwell
11118         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
11119
11120         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
11121         Moved to here ...
11122         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
11123         ... from here.
11124
11125 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11126
11127         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
11128         2821 is fixed.
11129
11130 2006-09-08  Jim Meyering  <jim@meyering.net>
11131
11132         Don't make generated files read-only.  That would bother too many
11133         people.  However, do retain the ability to work when targets are
11134         read-only: remove the destination and temporary files before writing
11135         them (when generated via sed or echo), or by using the -f option for
11136         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
11137         * modules/alloca-opt, modules/argz, modules/arpa_inet:
11138         * modules/byteswap, modules/configmake, modules/fcntl:
11139         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
11140         * modules/localcharset, modules/netinet_in, modules/poll:
11141         * modules/stdbool, modules/stdint, modules/sys_select:
11142         * modules/sys_socket, modules/sys_stat, modules/sysexits:
11143
11144 2006-09-08  Jim Meyering  <jim@meyering.net>
11145
11146         Avoid new build failure on FreeBSD 6.0.
11147         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
11148         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
11149         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
11150
11151 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11152
11153         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
11154
11155 2006-09-07  Jim Meyering  <jim@meyering.net>
11156
11157         Fix global typo in last change: use chmod u-w, not chmod u-x.
11158         Spotted by Paul Eggert and Bruce Korb.
11159         * modules/alloca-opt, modules/argz, modules/arpa_inet:
11160         * modules/byteswap, modules/configmake, modules/fcntl:
11161         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
11162         * modules/localcharset, modules/netinet_in, modules/poll:
11163         * modules/stdbool, modules/stdint, modules/sys_select:
11164         * modules/sys_socket, modules/sys_stat, modules/sysexits:
11165
11166 2006-09-06  Jim Meyering  <jim@meyering.net>
11167
11168         Make generated files be read-only.
11169         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
11170         Ensure that each generated file is now read-only.
11171         * modules/argz: Likewise.
11172         * modules/arpa_inet: Likewise.
11173         * modules/byteswap: Likewise.
11174         * modules/configmake: Likewise.
11175         * modules/fcntl: Likewise.
11176         * modules/fnmatch: Likewise.
11177         * modules/getopt: Likewise.
11178         * modules/glob: Likewise.
11179         * modules/inttypes: Likewise.
11180         * modules/netinet_in: Likewise.
11181         * modules/poll: Likewise.
11182         * modules/stdbool: Likewise.
11183         * modules/stdint: Likewise.
11184         * modules/sys_select: Likewise.
11185         * modules/sys_socket: Likewise.
11186         * modules/sys_stat: Likewise.
11187         * modules/sysexits: Likewise.
11188         * modules/localcharset: Same as above, but continue using temporary
11189         file named "t-$@" (why different?) rather than the "$@-t" used
11190         everywhere else.
11191
11192         * modules/sysexits (Makefile.am): Replace literal occurrences
11193         of "sysexit.h" more readable, and more consistent, "$@".
11194
11195 2006-09-06  Bruno Haible  <bruno@clisp.org>
11196
11197         * modules/striconv: New file.
11198         * modules/xstriconv: New file.
11199         * MODULES.html.sh (Internationalization functions): Add striconv,
11200         xstriconv.
11201
11202 2006-09-06  Bruno Haible  <bruno@clisp.org>
11203
11204         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
11205         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
11206         not using libtool correctly.
11207
11208 2006-09-06  Bruno Haible  <bruno@clisp.org>
11209
11210         * lib/striconv.h: New file.
11211         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
11212         iconvstring.c.
11213         * lib/xstriconv.h: New file.
11214         * lib/xstriconv.c: New file.
11215
11216 2006-09-06  Bruno Haible  <bruno@clisp.org>
11217
11218         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
11219         lib_..._LDFLAGS.
11220
11221 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11222
11223         * lib/argz_.h: Sync from Libtool.
11224
11225         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
11226                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
11227
11228         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
11229
11230 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
11231
11232         * modules/trim: New file.
11233
11234 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
11235
11236         * lib/trim.h: New file.
11237         * lib/trim.c: New file.
11238
11239 2006-09-05  Bruno Haible  <bruno@clisp.org>
11240
11241         * MODULES.html.sh (String handling): Add trim.
11242
11243 2006-09-04  Karl Berry  <karl@gnu.org>
11244
11245         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
11246         until next release.
11247
11248 2006-09-03  Bruno Haible  <bruno@clisp.org>
11249
11250         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
11251         correctly.
11252
11253 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11254
11255         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
11256         not gl_GETLOADAVG.  Omit unneeded semicolons.
11257         Problems reported by Ralf Wildenhues in
11258         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
11259         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
11260         at the end, which is the usual gnulib style.
11261
11262         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
11263         of doing all the work ourselves.
11264         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
11265         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
11266
11267 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11268
11269         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
11270         Problem reported by Ralf Wildenhues in
11271         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
11272
11273         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
11274         HAVE_STRUCT_STATFS_F_FSTYPENAME.
11275
11276 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11277
11278         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
11279         yesterday's patch by changing test -n to test -z.
11280
11281 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11282
11283         * modules/getloadavg (Files): Add m4/getloadavg.m4.
11284         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
11285         the former is now obsolescent.
11286
11287         * modules/chdir-long (Depends-on): Add fcntl.
11288
11289 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11290
11291         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
11292         obsolescent, and programs should use gnulib instead.
11293         * m4/getloadavg.m4: New file, with contents taken from Autoconf
11294         but with prefixes changed.
11295
11296 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11297
11298         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
11299         or stdbool.h, because they might not exist while configuring.
11300
11301         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
11302         Don't include unistd.h or limits.h; not needed, since chdir-long.h
11303         does that for us.
11304         (O_DIRECTORY): Remove.
11305
11306 2006-08-31  Eric Blake  <ebb9@byu.net>
11307
11308         * gnulib-tool: Don't let emacs change spaces to TAB.
11309
11310 2006-08-31  Bruno Haible  <bruno@clisp.org>
11311
11312         * gnulib-tool: When calling func_import more than once, do it in a
11313         subshell.
11314         Reported by Eric Blake <ebb9@byu.net>.
11315
11316 2006-08-31  Bruno Haible  <bruno@clisp.org>
11317
11318         * gnulib-tool (nl): Remove variable.
11319         (sed_transform_lib_file): Use more robust test for config-h module.
11320         (func_import): Fix typo in 2006-08-25 patch.
11321
11322 2006-08-31  Bruno Haible  <bruno@clisp.org>
11323
11324         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
11325         specified, augment Makefile.am variables instead of assigning them.
11326
11327 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11328
11329         Work around a bug in both the Linux and SunOS 64-bit kernels:
11330         nanosleep mishandles sleeps for longer than 2**31 seconds.
11331         Problem reported by Frank v Waveren in
11332         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
11333         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
11334         Check for nanosleep bug.
11335         (LIB_NANOSLEEP): Append clock_gettime library if needed.
11336
11337 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11338
11339         Work around a bug in both the Linux and SunOS 64-bit kernels:
11340         nanosleep mishandles sleeps for longer than 2**31 seconds.
11341         Problem reported by Frank v Waveren in
11342         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
11343         * lib/nanosleep.c (BILLION): New constant.
11344         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
11345         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
11346         implementation.
11347
11348 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11349
11350         * modules/nanosleep (Depends-on): Add gettime.
11351
11352 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11353         and Simon Josefsson  <jas@extundo.com>
11354         and Oskar Liljeblad  <oskar@osk.mine.nu>
11355
11356         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
11357         * gnulib-tool (func_import): New license type 'unmodifiable license
11358         text'.
11359         * modules/fdl: Use it.  Longer description.
11360         * module/gpl, module/lgpl: New files.
11361
11362 2006-08-30  Jim Meyering  <jim@meyering.net>
11363
11364         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
11365         shadowing the parameter.
11366
11367 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11368
11369         Sync from Libtool:
11370
11371         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11372
11373         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
11374         sharing with gnulib.  Report by Eric Blake.
11375
11376 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11377
11378         * modules/isapipe: New file.
11379         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
11380
11381 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11382
11383         * modules/configmake (Makefile.am): Add a comment, and omit
11384         the CONFIGMAKE_ prefix from generated macro names.  Suggested
11385         by Bruno Haible.
11386
11387 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11388
11389         * m4/isapipe.m4: New file.
11390
11391 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11392
11393         * lib/isapipe.c, lib/isapipe.h: New files.
11394
11395 2006-08-29  Jim Meyering  <jim@meyering.net>
11396
11397         * modules/configmake (Makefile.am): Make configmake.h depend on
11398         Makefile.  Otherwise, a stale configmake.h could hang around.
11399
11400 2006-08-29  Eric Blake  <ebb9@byu.net>
11401
11402         * lib/error.c (error_at_line, print_errno_message): Match libc, after
11403         resolution of upstream bug 3044.
11404
11405 2006-08-29  Bruno Haible  <bruno@clisp.org>
11406
11407         * modules/localcharset (Depends-on): Add configmake.
11408         (Makefile.am): Remove setting of LIBDIR through DEFS.
11409
11410 2006-08-29  Bruno Haible  <bruno@clisp.org>
11411
11412         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
11413         defined.
11414
11415 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11416
11417         * modules/fcntl: New file.
11418         * modules/chdir-safer (Depends-on): Add fcntl.
11419         * modules/fts: Likewise.
11420         * modules/mkdir-p: Likewise.
11421
11422         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
11423         This undoes the most recent change, since we're now addressing the
11424         problem in a different way.
11425
11426         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
11427         into output, since the output might be called Makefile.am even
11428         if $makefile_name is something different.
11429         (func_import): Use $makefile_am rather than
11430         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
11431         empty.
11432
11433         * modules/inttypes (Files): Add m4/inttypes-h.m4.
11434
11435 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11436
11437         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
11438         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
11439         recent change to stdint.m4, since we're now addressing the problem in a
11440         different way.
11441
11442 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11443
11444         * m4/fcntl_h.m4: New file.
11445
11446 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11447
11448         * lib/fcntl_.h: New file.
11449         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
11450         the fcntl module.
11451         * lib/dirchownmod.c: Likewise.
11452         * lib/fts.c: Likewise.
11453
11454         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
11455         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
11456         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
11457         just before including <inttypes.h>, to avoid circular inclusion.
11458
11459 2006-08-28  Jim Meyering  <jim@meyering.net>
11460
11461         * doc/visibility.texi: Actually read and correct the grammar of the
11462         sentence affected by yesterday's change.
11463
11464 2006-08-28  Eric Blake  <ebb9@byu.net>
11465
11466         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
11467         needs wrapper.
11468
11469 2006-08-28  Eric Blake  <ebb9@byu.net>
11470
11471         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
11472
11473 2006-08-28  Eric Blake  <ebb9@byu.net>
11474
11475         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
11476
11477 2006-08-28  Bruno Haible  <bruno@clisp.org>
11478
11479         * modules/c-strstr: New file, from GNU gettext.
11480         * MODULES.html.sh (String handling): Add c-strstr.
11481
11482 2006-08-28  Bruno Haible  <bruno@clisp.org>
11483
11484         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
11485         macros.
11486         Reported by Eric Blake.
11487
11488 2006-08-28  Bruno Haible  <bruno@clisp.org>
11489
11490         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
11491         (VASNPRINTF): Return a string of length > INT_MAX without failing.
11492         * lib/vasprintf.c: Include errno.h, limits.h.
11493         (EOVERFLOW): New fallback definition.
11494         (vasprintf): Test here whether the string length is > INT_MAX.
11495         * lib/vsnprintf.c: Include errno.h, limits.h.
11496         (EOVERFLOW): New fallback definition.
11497         (vsnprintf): Fix bug when generated string was too long for the buffer.
11498         Test here whether the string length is > INT_MAX.
11499
11500 2006-08-28  Bruno Haible  <bruno@clisp.org>
11501
11502         * lib/inttypes_.h (SCNX*): Remove definitions.
11503         Reported by Eric Blake.
11504
11505 2006-08-28  Bruno Haible  <bruno@clisp.org>
11506
11507         * lib/c-strstr.h: New file, from GNU gettext.
11508         * lib/c-strstr.c: New file, from GNU gettext.
11509
11510 2006-08-28  Bruno Haible  <bruno@clisp.org>
11511
11512         * gnulib-tool: Reorder some statements.
11513
11514 2006-08-28  Bruno Haible  <bruno@clisp.org>
11515
11516         * gnulib-tool: New option --makefile-name.
11517         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
11518         $makefile_name.
11519         (func_import): Write $makefile_name to the cache file, and read it from
11520         there unless explicitly specified. Use $makefile_name as file name
11521         instead of Makefile.am. Adjust the recommendations accordingly.
11522
11523 2006-08-28  Bruno Haible  <bruno@clisp.org>
11524
11525         * gnulib-tool (func_verify_module): Check against misapplying patch.
11526
11527 2006-08-28  Bruno Haible  <bruno@clisp.org>
11528
11529         * gnulib-tool (func_relativize, func_relconcat): New functions.
11530         Give an error if --local-dir is given with --update.
11531         Remove trailing slashes from $local_gnulib_dir.
11532         (func_import): Store the relativized $local_gnulib_dir in
11533         gnulib-cache.m4, and read it from there if not specified explicitly.
11534
11535 2006-08-28  Bruno Haible  <bruno@clisp.org>
11536
11537         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
11538         is the current directory. Respect also $local_gnulib_dir.
11539
11540 2006-08-28  Bruno Haible  <bruno@clisp.org>
11541             Simon Josefsson  <jas@extundo.com>
11542
11543         BeOS portability.
11544         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
11545
11546 2006-08-27  Jim Meyering  <jim@meyering.net>
11547
11548         * doc/visibility.texi: Remove duplicate word: "pointer".
11549
11550 2006-08-26  Bruno Haible  <bruno@clisp.org>
11551
11552         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
11553         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
11554         (Makefile.am): Create inttypes.h from inttypes_.h.
11555         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
11556
11557         * modules/imaxabs: New file.
11558
11559         * modules/imaxdiv: New file.
11560
11561 2006-08-26  Bruno Haible  <bruno@clisp.org>
11562
11563         * m4/inttypes.m4: New file.
11564         * m4/_inttypes_h.m4: Remove file.
11565         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
11566         PRI_MACROS_BROKEN.
11567         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
11568
11569         * m4/imaxabs.m4: New file.
11570
11571         * m4/imaxdiv.m4: New file.
11572
11573 2006-08-26  Bruno Haible  <bruno@clisp.org>
11574
11575         * lib/inttypes_.h: New file.
11576         * lib/inttypes.h: Remove file.
11577         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
11578
11579         * lib/imaxabs.c: New file.
11580
11581         * lib/imaxdiv.c: New file.
11582
11583 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11584
11585         New config-h module, so that "make" output needn't be cluttered
11586         by -DHAVE_CONFIG_H.
11587         * MODULES.html.sh (Support for building libraries and executables):
11588         Add config-h.
11589         * modules/config-h: New file.
11590         * gnulib-tool (nl, sed_transform_lib_file): New vars.
11591         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
11592         the config-h module is used.
11593
11594         New configmake module, so that "make" output needn't be cluttered
11595         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
11596         * MODULES.html.sh (Support for building libraries and executables):
11597         Add configmake.
11598         * modules/configmake: New file.
11599
11600 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11601
11602         * m4/config-h.m4: New file.
11603
11604 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11605
11606         * config/srclist.txt: Add elisp-comp.
11607
11608 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11609
11610         * MODULES.html.sh (Support for building libraries and executables):
11611         Add elisp-comp.
11612         * build-aux/elisp-comp: New file.
11613         * modules/elisp-comp: New file.
11614
11615 2006-08-24  Bruno Haible  <bruno@clisp.org>
11616
11617         * gnulib-tool (func_create_testdir): Use non-default values of
11618         sourcebase and m4base.
11619
11620 2006-08-24  Bruno Haible  <bruno@clisp.org>
11621
11622         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
11623         HTML structure.
11624
11625 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11626
11627         * modules/openat (Depends-on): Add lchown.
11628
11629 2006-08-23  Bruno Haible  <bruno@clisp.org>
11630
11631         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
11632         of gl_LOCK_EARLY instead of gl_LOCK.
11633
11634 2006-08-23  Bruno Haible  <bruno@clisp.org>
11635
11636         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
11637         on OSF/1 to no.
11638         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
11639
11640 2006-08-23  Bruno Haible  <bruno@clisp.org>
11641
11642         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
11643         as unusable.
11644
11645         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
11646         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
11647         (gl_LOCK): New macro.
11648
11649 2006-08-22  Simon Josefsson  <jas@extundo.com>
11650
11651         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
11652         to md5 module.
11653
11654 2006-08-22  Simon Josefsson  <jas@extundo.com>
11655
11656         * MODULES.html.sh: Add "Support for maintaining and release
11657         projects".
11658
11659         * build-aux/gnupload: New file, from coreutils.
11660
11661 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11662
11663         Avoid the need for AC_LIBSOURCES in m4 macros.
11664         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
11665         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
11666         * modules/check-version (EXTRA_DIST): Add check-version.h.
11667         * modules/crc (EXTRA_DIST): Add crc.h.
11668         * modules/des (EXTRA_DIST): Add des.h.
11669         * modules/gc (EXTRA_DIST): Add gc.h.
11670         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
11671         * modules/getline (EXTRA_DIST): Add getline.h.
11672         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
11673         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
11674         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
11675         * modules/md2 (EXTRA_DIST): Add md2.h.
11676         * modules/md4 (EXTRA_DIST): Add md4.h.
11677         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
11678         * modules/read-file (EXTRA_DIST): Add read-file.h.
11679         * modules/readline (EXTRA_DIST): Add readline.h.
11680         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
11681         rijndael-api-fst.h.
11682
11683 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11684
11685         * m4/rijndael.m4 (gl_ARCFOUR):
11686         * m4/arctwo.m4 (gl_ARCTWO):
11687         * m4/check-version.m4 (gl_CHECK_VERSION):
11688         * m4/crc.m4 (gl_CRC):
11689         * m4/des.m4 (gl_DES):
11690         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
11691         * m4/gc.m4 (gl_GC):
11692         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
11693         * m4/getline.m4 (gl_FUNC_GETLINE):
11694         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
11695         * m4/hmac-md5.m4 (gl_HMAC_MD5):
11696         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
11697         * m4/md2.m4 (gl_MD2):
11698         * m4/md4.m4 (gl_MD4):
11699         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
11700         * m4/read-file.m4 (gl_FUNC_READ_FILE):
11701         * m4/readline.m4 (gl_FUNC_READLINE):
11702         * m4/rijndael.m4 (gl_RIJNDAEL):
11703         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
11704         to get the necessary .h files and whatnot.
11705
11706 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11707
11708         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
11709         gnulib rather than the other way around.
11710         * config/srclistvars.sh (COREUTILS): Remove.
11711
11712 2006-08-22  Jim Meyering  <jim@meyering.net>
11713
11714         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
11715
11716         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
11717
11718 2006-08-22  Eric Blake  <ebb9@byu.net>
11719
11720         * modules/regexprops-generic: New file.
11721         * MODULES.html.sh (Support for building documentation): List it.
11722
11723 2006-08-22  Eric Blake  <ebb9@byu.net>
11724
11725         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
11726         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
11727         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
11728         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
11729
11730 2006-08-22  Bruno Haible  <bruno@clisp.org>
11731
11732         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
11733         and lib_LTLIBRARIES like the other lib_* variables.
11734
11735 2006-08-22  Bruno Haible  <bruno@clisp.org>
11736
11737         * build-aux/x-to-1.in: New file, from GNU gettext.
11738
11739 2006-08-22  Bruno Haible  <bruno@clisp.org>
11740
11741         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
11742         <utmpx.h> exists.
11743
11744 2006-08-22  Bruno Haible  <bruno@clisp.org>
11745
11746         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
11747         <utmpx.h> exists.
11748
11749 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11750
11751         BeOS portability.
11752         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
11753         exist.
11754         Problem reported by Bruno Haible.
11755
11756 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11757
11758         Avoid the need for AC_LIBSOURCES in m4 macros.
11759         * modules/acl (EXTRA_DIST): Add acl.h.
11760         * modules/argmatch (Files): Add m4/argmatch.m4.
11761         (configure.ac): Add gl_ARGMATCH.
11762         (EXTRA_DIST): Renamed from lib_SOURCES, for
11763         consistency with the other modules.  Remove argmatch.c.
11764         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
11765         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
11766         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
11767         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
11768         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
11769         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
11770         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
11771         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
11772         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
11773         * modules/closeout (EXTRA_DIST): Add closeout.h.
11774         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
11775         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
11776         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
11777         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
11778         dirname.h; remove basename.c and stripslash.c.
11779         * modules/exclude (EXTRA_DIST): Add exclude.h.
11780         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
11781         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
11782         * modules/file-type (EXTRA_DIST): Add file-type.h.
11783         * modules/filemode (EXTRA_DIST): Add filemode.h.
11784         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
11785         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
11786         * modules/fpending (EXTRA_DIST): Add __fpending.h.
11787         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
11788         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
11789         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
11790         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
11791         * modules/getdate (EXTRA_DIST): Add getdate.c.
11792         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
11793         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
11794         * modules/getpass (EXTRA_DIST): Add getpass.h.
11795         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
11796         * modules/group-member (EXTRA_DIST): Add group-member.h.
11797         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
11798         * modules/hash (EXTRA_DIST): Add hash.h.
11799         * modules/human (EXTRA_DIST): Add human.h.
11800         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
11801         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
11802         * modules/lchown (EXTRA_DIST): Add lchown.h.
11803         * modules/long-options (EXTRA_DIST): Add long-options.h.
11804         * modules/lstat (EXTRA_DIST): Add lstat.h.
11805         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
11806         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
11807         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
11808         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
11809         * modules/memxor (EXTRA_DIST): Add memxor.h.
11810         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
11811         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
11812         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
11813         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
11814         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
11815         * modules/physmem (EXTRA_DIST): Add physmem.h.
11816         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
11817         * modules/posixver (EXTRA_DIST): Add posixver.h.
11818         * modules/quote (EXTRA_DIST): Add quote.h.
11819         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
11820         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
11821         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
11822         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
11823         regex_internal.h regexec.c.
11824         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
11825         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
11826         * modules/same (EXTRA_DIST): Add same.h.
11827         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
11828         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
11829         * modules/savedir (EXTRA_DIST): Add savedir.h.
11830         * modules/sha1 (EXTRA_DIST): Add sha1.h.
11831         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
11832         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
11833         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
11834         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
11835         * modules/strdup (EXTRA_DIST): Add strdup.h.
11836         * modules/strftime (EXTRA_DIST): Add strftime.h.
11837         * modules/strndup (EXTRA_DIST): Add strndup.h.
11838         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
11839         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
11840         * modules/time_r (EXTRA_DIST): Add time_r.h.
11841         * modules/timespec (EXTRA_DIST): Add timespec.h.
11842         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
11843         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
11844         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
11845         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
11846         * modules/userspec (EXTRA_DIST): Add userspec.h.
11847         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
11848         * modules/utimens (EXTRA_DIST): Add utimens.h.
11849         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
11850         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
11851         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
11852         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
11853         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
11854         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
11855         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
11856         * modules/yesno (EXTRA_DIST): Add yesno.h.
11857
11858 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11859
11860         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
11861
11862         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
11863         * m4/dev-ino.m4, same-inode.m4: Remove.
11864
11865         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
11866         * m4/acl.m4 (AC_FUNC_ACL):
11867         * m4/backupfile.m4 (gl_BACKUPFILE):
11868         * m4/c-strtod.m4 (gl_C99_STRTOLD):
11869         * m4/canon-host.m4 (gl_CANON_HOST):
11870         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
11871         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
11872         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
11873         * m4/cloexec.m4 (gl_CLOEXEC):
11874         * m4/close-stream.m4 (gl_CLOSE_STREAM):
11875         * m4/closeout.m4 (gl_CLOSEOUT):
11876         * m4/dirfd.m4 (gl_FUNC_DIRFD):
11877         * m4/dirname.m4 (gl_DIRNAME):
11878         * m4/exclude.m4 (gl_EXCLUDE):
11879         * m4/exitfail.m4 (gl_EXITFAIL):
11880         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
11881         * m4/file-type.m4 (gl_FILE_TYPE):
11882         * m4/filemode.m4 (gl_FILEMODE):
11883         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
11884         * m4/fpending.m4 (gl_FUNC_FPENDING):
11885         * m4/fprintftime.m4 (gl_FPRINTFTIME):
11886         * m4/fts.m4 (gl_FUNC_FTS):
11887         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
11888         * m4/getdate.m4 (gl_GETDATE):
11889         * m4/gethrxtime.m4 (gl_GETHRXTIME):
11890         * m4/getpagesize.m4 (gl_GETPAGESIZE):
11891         * m4/getpass.m4 (gl_FUNC_GETPASS):
11892         * m4/gettime.m4 (gl_GETTIME):
11893         * m4/getugroups.m4 (gl_GETUGROUPS):
11894         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
11895         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
11896         * m4/hard-locale.m4 (gl_HARD_LOCALE):
11897         * m4/hash.m4 (gl_HASH):
11898         * m4/idcache.m4 (gl_IDCACHE):
11899         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
11900         * m4/lchown.m4 (gl_FUNC_LCHOWN):
11901         * m4/long-options.m4 (gl_LONG_OPTIONS):
11902         * m4/lstat.m4 (gl_FUNC_LSTAT):
11903         * m4/md5.m4 (gl_MD5):
11904         * m4/memcasecmp.m4 (gl_MEMCASECMP):
11905         * m4/memcoll.m4 (gl_MEMCOLL):
11906         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
11907         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
11908         * m4/memxor.m4 (gl_MEMXOR):
11909         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
11910         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
11911         * m4/modechange.m4 (gl_MODECHANGE):
11912         * m4/mountlist.m4 (gl_MOUNTLIST):
11913         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
11914         * m4/openat.m4 (gl_FUNC_OPENAT):
11915         * m4/pathmax.m4 (gl_PATHMAX):
11916         * m4/physmem.m4 (gl_PHYSMEM):
11917         * m4/posixtm.m4 (gl_POSIXTM):
11918         * m4/posixver.m4 (gl_POSIXVER):
11919         * m4/quote.m4 (gl_QUOTE):
11920         * m4/quotearg.m4 (gl_QUOTEARG):
11921         * m4/readtokens.m4 (gl_READTOKENS):
11922         * m4/readutmp.m4 (gl_READUTMP):
11923         * m4/regex.m4 (gl_REGEX):
11924         * m4/safe-read.m4 (gl_SAFE_READ):
11925         * m4/safe-write.m4 (gl_SAFE_WRITE):
11926         * m4/same.m4 (gl_SAME):
11927         * m4/save-cwd.m4 (gl_SAVE_CWD):
11928         * m4/savedir.m4 (gl_SAVEDIR):
11929         * m4/settime.m4 (gl_SETTIME):
11930         * m4/sha1.m4 (gl_SHA1):
11931         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
11932         * m4/stat-macros.m4 (gl_STAT_MACROS):
11933         * m4/stat-time.m4 (gl_STAT_TIME):
11934         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
11935         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
11936         * m4/strdup.m4 (gl_FUNC_STRDUP):
11937         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
11938         * m4/strndup.m4 (gl_FUNC_STRNDUP):
11939         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
11940         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
11941         * m4/time_r.m4 (gl_TIME_R):
11942         * m4/timespec.m4 (gl_TIMESPEC):
11943         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
11944         * m4/unlinkdir.m4 (gl_UNLINKDIR):
11945         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
11946         * m4/userspec.m4 (gl_USERSPEC):
11947         * m4/utimecmp.m4 (gl_UTIMECMP):
11948         * m4/utimens.m4 (gl_UTIMENS):
11949         * m4/xalloc.m4 (gl_XALLOC):
11950         * m4/xgetcwd.m4 (gl_XGETCWD):
11951         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
11952         * m4/xreadlink.m4 (gl_XREADLINK):
11953         * m4/xstrtod.m4 (gl_XSTRTOD):
11954         * m4/yesno.m4 (gl_YESNO):
11955         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
11956         to get the necessary .h files and whatnot.
11957
11958 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
11959             Bruno Haible  <bruno@clisp.org>
11960
11961         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
11962         /bin/sh understanding of '!' conditional negation.
11963
11964 2006-08-21  Jim Meyering  <jim@meyering.net>
11965
11966         * modules/openat (Depends-on): Really alphabetize.
11967
11968         * modules/acl (Depends-on): Add error and quote.
11969
11970         * check-module (find_included_lib_files): Add at-func.c to the
11971         ok-to-include-more-than-once white list.
11972
11973         * modules/openat (Depends-on): Add lstat.  Alphabetize.
11974
11975 2006-08-21  Bruno Haible  <bruno@clisp.org>
11976
11977         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
11978         Emit a pkgdata_DATA variable only if some snippets add contents to it.
11979         Reported by Martin Lambers <marlam@marlam.de>.
11980
11981 2006-08-21  Bruno Haible  <bruno@clisp.org>
11982
11983         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
11984         specify an installation location, don't emit a noinst_LIBRARIES or
11985         noinst_LTLIBRARIES assignment.
11986
11987 2006-08-21  Bruno Haible  <bruno@clisp.org>
11988
11989         BeOS portability.
11990         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
11991         BeOS has mbrtowc() but no <wctype.h>.
11992
11993 2006-08-21  Bruno Haible  <bruno@clisp.org>
11994
11995         BeOS portability.
11996         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
11997         exist.
11998
11999 2006-08-21  Bruno Haible  <bruno@clisp.org>
12000
12001         BeOS portability.
12002         * lib/mbchar.h: Include <wctype.h> only if it exists.
12003
12004 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12005
12006         Remove files that are no longer needed by their respective modules.
12007         * m4/obstack.m4: Remove.
12008         * m4/strerror_r.m4: Remove.
12009         * m4/uint32_t.m4: Remove.
12010         * m4/uintptr_t.m4: Remove.
12011         * m4/ullong_max.m4: Remove.
12012         * m4/xstrtoimax.m4: Remove.
12013         * m4/xstrtoumax.m4: Remove.
12014
12015         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
12016         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
12017         dependencies now capture this.
12018
12019         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
12020         Do not use AC_LIBSOURCES, since gnulib modules now do this.
12021         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
12022         * m4/human.m4 (gl_HUMAN): Likewise.
12023         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
12024         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
12025
12026         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
12027
12028         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
12029         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
12030         stdint.
12031         * m4/human.m4 (gl_HUMAN): Likewise.
12032         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
12033         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
12034         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
12035         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
12036         * m4/xstrtol (gl_XSTRTOL): Likewise.
12037
12038         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
12039         AC_TYPE_LONG_LONG_INT.
12040         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
12041         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
12042         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
12043         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
12044
12045         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
12046         on stdbool.
12047
12048         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
12049         (gl_PREREQ_XSTRTOUL): Remove.
12050
12051         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
12052
12053         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
12054         mode.
12055
12056 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12057
12058         Add and change modules to make it easier for coreutils to use
12059         gnulib-tool.
12060         * modules/backupfile (Files): Remove m4/d-ino.m4.
12061         (Depends-on): Add d-ino.
12062         * modules/cycle-check (Depends-on): Add stdint.
12063         (lib_SOURCES): Add cycle-check.h.
12064         * modules/d-ino: New module.
12065         * modules/d-type: New module.
12066         * modules/error (Files): Remove m4/strerror_r.m4.
12067         * modules/filemode (Files): Add m4/st_dm_mode.m4.
12068         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
12069         m4/inttypes_h.m4, m4/uintmax_t.m4.
12070         (Depends-on): Add stdint.
12071         (lib_SOURCES): Add fsusage.h.
12072         * modules/getcwd (Files): Remove d-ino.m4.
12073         (Depends-on): Add d-ino.
12074         * modules/getndelim2 (Depends-on): Add stdint.
12075         * modules/glob (Files): Remove m4/d-type.m4.
12076         (Depends-on): Add d-type.
12077         * modules/host-os: New module.
12078         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
12079         m4/inttypes_h.m4, m4/uintmax_t.m4.
12080         * Depends-on: Add stdint.
12081         (lib_SOURCES): Add human.h.
12082         * modules/inttostr (Files): Remove m4/intmax_t.m4,
12083         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
12084         m4/uintmax_t.m4, m4/ulonglong.m4.
12085         (Depends-on): Add stdint.
12086         (EXTRA_DIST): Add inttostr.h.
12087         * modules/lchmod: New module.
12088         * modules/link-follow: New module.
12089         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
12090         (Depends-on): Add lchmod.
12091         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
12092         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
12093         (Depends-on): Add stdint.
12094         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
12095         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
12096         (Depends-on): Add stdint.
12097         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
12098         * modules/perl: New module.
12099         * modules/regex (Depends-on): Add stdint.
12100         * modules/rmdir-errno: New module.
12101         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
12102         m4/intmax_t.m4.
12103         (Depends-on): Add stdint.
12104         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
12105         m4/uintmax_t.m4.
12106         (Depends-on): Add stdint.
12107         * modules/unlink-busy: New module.
12108         * modules/utimecmp (Depends-on): Add stdint.
12109         * modules/uptime: New module.
12110         * modules/winsz-ioctl: New module.
12111         * modules/winsz-termios: New module.
12112         * modules/xnanosleep (Depends-on): Add nanosleep.
12113         * modules/ullong_max: Remove.
12114         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
12115         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
12116         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
12117         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
12118         (Depends-on): Add inttypes.
12119         (lib_SOURCES): Add xstrtol.h.
12120         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
12121         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
12122         * MODULES.html.sh: Move 'assert' into the assert section.
12123         Move 'dummy' into the linking section.
12124         Remove ullong_max.
12125         Add section for compatibility checks for POSIX:2001 functions,
12126         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
12127         winsz-ioctl, and winsz-termios into it.
12128         Add lchmod.
12129         Add top-level Misc section and put host-os, perl, and uptime
12130         into it.
12131
12132 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12133
12134         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
12135         now assume the stdint module.  Do not include inttypes.h.
12136         * lib/fsusage.h: Likewise.
12137         * lib/getndelim2.c: Likewise.
12138         * lib/human.h: Likewise.
12139         * lib/inttostr.h: Likewise.
12140         * lib/obstack.c: Likewise.
12141         * lib/regex_internal.h: Likewise.
12142         * lib/tempname.c: Likewise.
12143         * lib/utimecmp.c: Likewise.
12144         * lib/xstrtol.h: Likewise.
12145
12146         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
12147
12148         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
12149         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
12150         * lib/xtime.h: Likewise.
12151
12152 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12153
12154         * modules/openat (Files): Add lib/fchmodat.c.
12155         Fixes problem reported by Jay Youngman.
12156
12157 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12158
12159         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
12160         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
12161
12162 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
12163             Bruno Haible  <bruno@clisp.org>
12164
12165         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
12166         and is a script that invokes bison. Tighten the code. Add comments.
12167
12168 2006-08-18  Jim Meyering  <jim@meyering.net>
12169
12170         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
12171         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
12172         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
12173         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
12174
12175 2006-08-18  Bruno Haible  <bruno@clisp.org>
12176
12177         * modules/bison-i18n: New file.
12178         * MODULES.html.sh (Internationalization functions): Add it.
12179
12180 2006-08-18  Bruno Haible  <bruno@clisp.org>
12181
12182         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
12183         sys/statvfs.h. When getmntinfo was found, check its declaration and
12184         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
12185
12186 2006-08-18  Bruno Haible  <bruno@clisp.org>
12187
12188         * m4/bison-i18n.m4: New file, from bison.
12189
12190 2006-08-18  Bruno Haible  <bruno@clisp.org>
12191
12192         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
12193         (ME_DUMMY): Treat "kernfs" as a dummy.
12194         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
12195
12196 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
12197
12198         Update from coreutils.
12199
12200         2006-08-15  Jim Meyering  <jim@meyering.net>
12201
12202         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
12203
12204         2006-01-17  Jim Meyering  <jim@meyering.net>
12205
12206         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
12207
12208         2006-01-11  Jim Meyering  <jim@meyering.net>
12209
12210         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
12211         Check for the lchmod function.
12212
12213 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
12214
12215         Update from coreutils.
12216
12217         * lib/__fpending.h: Add copyright notice.
12218         * lib/fprintftime.h: Likewise.
12219         * lib/savedir.c: Use (C) in copyright notice.
12220         * lib/savedir.h: Likewise.
12221
12222         2006-08-15  Jim Meyering  <jim@meyering.net>
12223
12224         * lib/at-func.c: New file, with the logic of all emulated at-functions.
12225         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
12226         in support of the EXPECTED_ERRNO macro.
12227         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
12228         definitions.  Instead, define the appropriate symbols and include
12229         "at-func.c".
12230         * lib/mkdirat.c (mkdirat): Likewise.
12231         * lib/fchmodat.c (fchmodat): Likewise.
12232         (ENOSYS): Remove definition.
12233         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
12234         it.  Don't include "unistd--.h" -- it wasn't ever used.
12235
12236         2006-01-17  Jim Meyering  <jim@meyering.net>
12237
12238         Rewrite fts.c not to change the current working directory,
12239         by using openat, fstatat, fdopendir, etc..
12240
12241         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
12242         (HAVE_OPENAT_SUPPORT): Define.
12243         [_LIBC] (fchdir): Don't undef or define; no longer used.
12244         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
12245         Now, this `function' always succeeds, and consumes its file descriptor
12246         parameter -- so callers must not close such FDs.  Update callers.
12247         (diropen_fd, opendirat, cwd_advance_fd): New functions.
12248         (diropen): Add parameter, SP.  Adjust all callers.
12249         Implement using diropen_fd, rather than open.
12250         (fts_open): Initialize new member, fts_cwd_fd.
12251         Remove fts_rft-setting code.
12252         (fts_close): Close fts_cwd_fd, if necessary.
12253         (__opendir2): Define in terms of opendir or opendirat,
12254         depending on whether the FST_NOCHDIR flag is set.
12255         (fts_build): Since fts_safe_changedir consumes its FD, and since
12256         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
12257         and close the dup'd file descriptor upon failure.
12258         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
12259         (fts_safe_changedir): Tweak semantics to reflect that this function
12260         now calls cwd_advance_fd and hence consumes its FD argument.
12261         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
12262         [struct FTS] (fts_rft): Remove now-unused member.
12263         [struct FTS] (fts_cycle.state): Improve comment.
12264
12265         * lib/openat.c (openat_needs_fchdir): New function.
12266         * lib/openat.h (openat_needs_fchdir): Declare it.
12267
12268 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
12269
12270         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
12271         Problem and fix reported by Pádraig Brady in
12272         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
12273
12274 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12275
12276         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
12277
12278 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12279
12280         * lib/memcoll.c (memcoll): Optimize for the common case where the
12281         arguments are bytewise equal.
12282
12283 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12284
12285         * doc/regexprops-generic.texi: Add a copyright notice.
12286
12287 2006-08-15  Bruno Haible  <bruno@clisp.org>
12288
12289         * modules/tmpdir (License): Change to LGPL.
12290
12291 2006-08-15  Bruno Haible  <bruno@clisp.org>
12292
12293         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
12294         module.
12295
12296 2006-08-14  Simon Josefsson  <jas@extundo.com>
12297
12298         * config/srclist.txt: Add gnupload.
12299
12300 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12301
12302         Change copyright notice from LGPL 2 to GPL 2, since that's the
12303         standard form used in the gnulib repository.
12304         * tests/test-lock.c: Likewise.
12305         * tests/test-stdint.c: Likewise.
12306         * tests/test-tls.c: Likewise.
12307
12308         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
12309         prelude-manager.  User shorter URLs for GNU projects, without '?'.
12310         Add copyright notice.
12311
12312         * check-module: Add copyright notice.  Output a copyright
12313         notice if "--version" is specified.
12314         * modules/COPYING: New file.
12315         * tests/test-getaddrinfo.c: Add copyright notice.
12316         * tests/test-verify.c: Likewise.
12317
12318 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12319
12320         Change copyright notice from LGPL 2 to GPL 2, since that's the
12321         standard form used in the gnulib repository.
12322         * lib/lock.c: LGPL -> GPL.
12323         * lib/lock.h: Likewise.
12324         * lib/strnlen1.c: Likewise.
12325         * lib/strnlen1.h: Likewise.
12326         * lib/tls.c: Likewise.
12327         * lib/tls.h: Likewise.
12328         * lib/tmpdir.c: Likewise.
12329
12330         * lib/TODO: Remove; this belongs only in coreutils.
12331
12332 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12333
12334         Add copyright notices to long-enough files that lack them, since
12335         otherwise the files aren't clearly free.  Use the same notice that
12336         getdate.texi already uses.
12337         * doc/alloca-opt.texi: Add copyright notice.
12338         * doc/alloca.texi: Likewise.
12339         * doc/ctime.texi: Likewise.
12340         * doc/functions.texi: Likewise.
12341         * doc/gcd.texi: Likewise.
12342         * doc/gnulib-tool.texi: Likewise.
12343         * doc/inet_ntoa.texi: Likewise.
12344         * doc/visibility.texi: Likewise.
12345
12346         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
12347         * doc/quote.texi: Add copyright notice.
12348
12349         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
12350         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
12351         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
12352         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
12353         is now obsolete, and give a pointer to the Sun list.
12354         Add copyright notice.
12355
12356 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12357
12358         * config/srclistvars.sh: Add copyright notice.
12359
12360 2006-08-14  Eric Blake  <ebb9@byu.net>
12361
12362         Import the following change from libc:
12363
12364         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
12365
12366         Upstream bug 2997.
12367         * lib/misc/error.c: Add space between program name and message if file
12368         name is missing.
12369
12370 2006-08-12  Karl Berry  <karl@gnu.org>
12371
12372         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
12373         remove, these originate in gnulib now.
12374
12375 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12376
12377         * doc/Makefile (standards.info standards.html standards.dvi):
12378         Also depend on make-stds.texi.
12379
12380 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
12381
12382         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
12383         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
12384
12385         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
12386         in wchar_t.  Problem reported by Eric Blake.
12387
12388         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
12389         LEN is smaller than SIZE.  Suggested by Bruno Haible.
12390         Also, help the compiler to keep LEN in a register.
12391
12392 2006-08-11  Eric Blake  <ebb9@byu.net>
12393
12394         * users.txt: Sort.  Add tar.
12395
12396 2006-08-11  Bruno Haible  <bruno@clisp.org>
12397
12398         * users.txt: New file.
12399
12400 2006-08-11  Bruno Haible  <bruno@clisp.org>
12401
12402         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
12403         before <wchar.h>. Needed for OSF/1 and BSD/OS.
12404
12405 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
12406
12407         * modules/snprintf (Depends-on): Remove minmax.
12408         (Maintainer): Add self and Bruno.
12409
12410 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
12411
12412         * lib/.cppi-disable: Add snprintf.h, socket_.h.
12413         * lib/snprintf.c: Include <errno.h> and <limits.h>.
12414         (EOVERFLOW): Define if the system does not.
12415         Do not include "minmax.h"; it wasn't used.
12416         (snprintf): Don't assume size_t promotes to an unsigned type.
12417         Fix bug when generated string was too long for the buffer: the
12418         buffer's contents are supposed to be the initial prefix of the
12419         output.  Don't assume vasnprintf returns EOVERFLOW if the size
12420         exceeds INT_MAX; do the check ourselves.
12421
12422         Import the following changes from libc:
12423
12424         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
12425
12426         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
12427         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
12428         set wc to the byte which couldn't be converted.
12429         (re_string_reconstruct): Don't clear valid_raw_len before calling
12430         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
12431         tip_context using re_string_context_at.
12432
12433         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
12434
12435         * lib/posix/regex.h: g++ still cannot handled [restrict].
12436
12437         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
12438
12439         * lib/posix/regex.h: Remove special handling for VMS.
12440
12441 2006-08-10  Jim Meyering  <jim@meyering.net>
12442
12443         * modules/same-inode: New module.
12444         * modules/dev-ino: New module.
12445         * modules/cycle-check: Depend on these modules, rather than simply
12446         including their .h files.
12447         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
12448         required via m4/cycle-check.m4.
12449         * modules/same: Depend on new same-inode module, rather than
12450         including same-inode.h.
12451         * modules/chdir-safer: New file.
12452
12453         * modules/chown (Depends-on): Add stat-macros.
12454
12455 2006-08-10  Jim Meyering  <jim@meyering.net>
12456
12457         * m4/cycle-check.m4: New file.
12458         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
12459         * m4/dev-ino.m4, m4/same-inode.m4: New files.
12460
12461 2006-08-10  Eric Blake  <ebb9@byu.net>
12462
12463         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
12464         in from original proposal.
12465
12466 2006-08-10  Eric Blake  <ebb9@byu.net>
12467         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
12468
12469         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
12470         namespace.
12471
12472 2006-08-10  Bruno Haible  <bruno@clisp.org>
12473
12474         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
12475         as well.
12476
12477 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12478
12479         Sync from coreutils.
12480
12481         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
12482
12483         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
12484         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
12485
12486 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12487
12488         * modules/restrict: Remove; no longer needed now that we assume
12489         Autoconf 2.59 or later.
12490         * MODULES.html.sh: Remove 'restrict'.
12491         * modules/argp (Depends-on): Remove 'restrict'.
12492         * modules/base64 (Depends-on): Likewise.
12493         * modules/gc (Depends-on): Likewise.
12494         * modules/getaddrinfo (Depends-on): Likewise.
12495         * modules/glob (Depends-on): Likewise.
12496         * modules/inet_ntop (Depends-on): Likewise.
12497         * modules/inet_pton (Depends-on): Likewise.
12498         * modules/memxor (Depends-on): Likewise.
12499         * modules/regex (Depends-on): Likewise.
12500         * modules/strtok_r (Depends-on): Likewise.
12501         * modules/time_r (Depends-on): Likewise.
12502
12503 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12504
12505         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
12506         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
12507         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
12508         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
12509         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
12510         * m4/memxor.m4 (gl_MEMXOR): Likewise.
12511         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
12512         gl_C_RESTRICT replaced by AC_C_RESTRICT.
12513
12514         Merge from coreutils.
12515         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
12516         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
12517         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
12518         * m4/time_r.m4 (gl_TIME_R): Likewise.
12519
12520 2006-08-09  Karl Berry  <karl@gnu.org>
12521
12522         * config/srclist.txt: no more gettext-tools, per Bruno.
12523
12524 2006-08-08  Eric Blake  <ebb9@byu.net>
12525
12526         * modules/verror: New module.
12527         * MODULES.html.sh: Document it.
12528
12529 2006-08-08  Eric Blake  <ebb9@byu.net>
12530
12531         * lib/verror.h, lib/verror.c: New files.
12532
12533 2006-08-08  Eric Blake  <ebb9@byu.net>
12534
12535         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
12536         verror_at_line output complies with GNU Coding Standards even when
12537         file is NULL.
12538
12539 2006-08-07  Bruno Haible  <bruno@clisp.org>
12540
12541         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
12542         versions of AIX.
12543         Reported by Ralf Wildenhues.
12544
12545 2006-08-07  Bruno Haible  <bruno@clisp.org>
12546
12547         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
12548         in an AC_DEFUN. Needed so that the autoconf snippets can use
12549         AC_REQUIRE.
12550
12551 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12552
12553         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12554         Initialize pkgdata_DATA.
12555         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
12556         overriding it.
12557
12558 2006-08-06  Eric Blake  <ebb9@byu.net>
12559
12560         * lib/error.h: Fold in some upstream changes from glibc.
12561         * lib/error.c: Likewise.
12562
12563 2006-08-04  Bruno Haible  <bruno@clisp.org>
12564
12565         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12566         Make the mostlyclean-local rule depend on mostlyclean-generic.
12567         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
12568
12569 2006-07-31  Bruno Haible  <bruno@clisp.org>
12570
12571         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
12572         <stdlib.h>, <string.h>.
12573
12574 2006-07-30  Bruno Haible  <bruno@clisp.org>
12575
12576         * modules/readlink (License): Change to LGPL.
12577
12578 2006-07-30  Bruno Haible  <bruno@clisp.org>
12579
12580         * modules/javaversion (Makefile.am): Distribute javaversion.java and
12581         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
12582         set PKGDATADIR to point to it.
12583
12584 2006-07-30  Bruno Haible  <bruno@clisp.org>
12585
12586         * modules/csharpexec (configure.ac): Comment out macro invocation.
12587         * modules/javaexec (configure.ac): Likewise.
12588         * modules/javacomp-script (configure.ac): Likewise.
12589
12590         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
12591
12592 2006-07-30  Bruno Haible  <bruno@clisp.org>
12593
12594         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
12595         linked-list.
12596
12597 2006-07-30  Bruno Haible  <bruno@clisp.org>
12598
12599         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
12600
12601 2006-07-30  Bruno Haible  <bruno@clisp.org>
12602
12603         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12604         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
12605         get removed.
12606
12607 2006-07-29  Bruno Haible  <bruno@clisp.org>
12608
12609         Make it possible for gnulib-tool to work with locally modified or
12610         augmented gnulib repositories.
12611         * gnulib-tool (func_usage): Document --local-dir option.
12612         (local_gnulib_dir): New variable.
12613         Handle --local-dir option.
12614         (func_lookup_file): New function.
12615         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
12616         (func_get_description, func_get_filelist, func_get_description,
12617         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
12618         func_get_automake_snippet, func_get_include_directive,
12619         func_get_license, func_get_maintainer): Use func_lookup_file.
12620         (func_import, func_create_testdir): Use func_lookup_file.
12621
12622 2006-07-29  Bruno Haible  <bruno@clisp.org>
12623
12624         * modules/setenv (Depends-on): Add unistd.
12625
12626 2006-07-29  Bruno Haible  <bruno@clisp.org>
12627
12628         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
12629
12630 2006-07-29  Bruno Haible  <bruno@clisp.org>
12631
12632         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
12633
12634 2006-07-29  Bruno Haible  <bruno@clisp.org>
12635
12636         * gnulib-tool (import, update): If there is no Makefile.am, look at
12637         aclocal.m4, instead of bailing out.
12638
12639 2006-07-29  Bruno Haible  <bruno@clisp.org>
12640
12641         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
12642         Categorize the options by when they are useful.
12643
12644 2006-07-29  Bruno Haible  <bruno@clisp.org>
12645
12646         * gnulib-tool (func_usage): Document option --no-libtool.
12647         Handle option --no-libtool.
12648         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
12649         for changed semantics of $libtool variable.
12650         (func_import): Likewise. If libtool is not used, show this through
12651         an option --no-libtool.
12652         (func_create_testdir): Update.
12653
12654 2006-07-29  Bruno Haible  <bruno@clisp.org>
12655
12656         * gnulib-tool (func_import): Extend error message about missing
12657         --doc-base.
12658
12659 2006-07-29  Bruno Haible  <bruno@clisp.org>
12660
12661         * gnulib-tool (func_import): Don't create the $docbase directory if
12662         there is no file to store there.
12663
12664 2006-07-29  Bruno Haible  <bruno@clisp.org>
12665
12666         * gnulib-tool (autoconf_minversion): If a --dir option is given and
12667         relevant, look for configure.ac there, not in the current directory.
12668         Also use a simple search for AC_PREREQ, not "autoconf --trace".
12669
12670 2006-07-29  Bruno Haible  <bruno@clisp.org>
12671
12672         * gnulib-tool (SORT): New variable.
12673         (func_usage): Undocument --assume-autoconf option.
12674         Remove --assume-autoconf option handling.
12675         (autoconf_minversion): Determine from the contents of configure.ac.
12676         (func_import): Remove autoconf_minversion handling.
12677         Suggested by Eric Blake.
12678
12679 2006-07-29  Bruno Haible  <bruno@clisp.org>
12680
12681         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
12682
12683 2006-07-29  Bruno Haible  <bruno@clisp.org>
12684
12685         * config/srclist.txt (*setenv.[ch]): Remove rules.
12686
12687 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12688
12689         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
12690
12691 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12692
12693         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
12694         arpa/inet.h.
12695
12696 2006-07-28  Simon Josefsson  <jas@extundo.com>
12697
12698         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
12699         * modules/inet_pton (Depends-on): Likewise.
12700
12701 2006-07-28  Simon Josefsson  <jas@extundo.com>
12702
12703         * m4/netinet_in_h.m4: New file.
12704
12705 2006-07-28  Simon Josefsson  <jas@extundo.com>
12706
12707         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
12708         #include's.
12709
12710 2006-07-28  Simon Josefsson  <jas@extundo.com>
12711
12712         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
12713         #include's.
12714
12715 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
12716
12717         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
12718         setgid on directories only if they set these bits.
12719         * lib/modechange.h: Remove obsolete comment about masks.
12720
12721 2006-07-28  Eric Blake  <ebb9@byu.net>
12722
12723         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
12724         macro expansion.
12725
12726 2006-07-28  Bruno Haible  <bruno@clisp.org>
12727
12728         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
12729
12730 2006-07-28  Bruno Haible  <bruno@clisp.org>
12731
12732         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
12733
12734 2006-07-28  Bruno Haible  <bruno@clisp.org>
12735
12736         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
12737         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
12738         Define fallbacks.
12739         Avoids link error on FreeBSD 4.x.
12740         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
12741
12742         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
12743         encoding.
12744         * lib/mbswidth.c (iswcntrl): Likewise.
12745
12746 2006-07-27  Bruno Haible  <bruno@clisp.org>
12747
12748         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
12749         test.
12750
12751 2006-07-27  Bruno Haible  <bruno@clisp.org>
12752
12753         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
12754         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
12755         defined.
12756
12757 2006-07-26  Eric Blake  <ebb9@byu.net>
12758
12759         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
12760
12761 2006-07-26  Eric Blake  <ebb9@byu.net>
12762
12763         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
12764         like mingw that lack mkstemp.
12765         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
12766         avoid compilation warning on mingw.
12767
12768 2006-07-26  Bruno Haible  <bruno@clisp.org>
12769
12770         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
12771         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
12772         INT_FAST*_MIN, INTPTR_MIN.
12773
12774 2006-07-25  Bruno Haible  <bruno@clisp.org>
12775
12776         * modules/version-etc (Depends-on): Add stdarg.
12777
12778 2006-07-25  Bruno Haible  <bruno@clisp.org>
12779
12780         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
12781         complex commands.
12782
12783 2006-07-25  Bruno Haible  <bruno@clisp.org>
12784
12785         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
12786         defined in <stdarg.h> or config.h.
12787
12788 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
12789
12790         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
12791         (gl_STDIO_SAFER): Remove.
12792
12793 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
12794
12795         * MODULES.html.sh (File stream based Input/Output):
12796         Add fopen-safer, tmpfile-safer; remove stdio-safer.
12797         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
12798         * modules/fopen-safer, modules/tmpfile-safer: New files.
12799         * modules/stdio-safer: Remove.
12800
12801 2006-07-24  Bruno Haible  <bruno@clisp.org>
12802
12803         * modules/tmpdir: New file.
12804         * MODULES.html.sh (File system functions): Add it.
12805
12806 2006-07-24  Bruno Haible  <bruno@clisp.org>
12807
12808         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
12809         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
12810
12811 2006-07-24  Bruno Haible  <bruno@clisp.org>
12812
12813         * modules/clean-temp: New file.
12814
12815 2006-07-24  Bruno Haible  <bruno@clisp.org>
12816
12817         * m4/tmpdir.m4: New file, from GNU gettext.
12818
12819 2006-07-24  Bruno Haible  <bruno@clisp.org>
12820
12821         * lib/tmpdir.h: New file, from GNU gettext.
12822         * lib/tmpdir.c: New file, from GNU gettext.
12823
12824 2006-07-24  Bruno Haible  <bruno@clisp.org>
12825
12826         * lib/clean-temp.h: New file, from GNU gettext.
12827         * lib/clean-temp.c: New file, from GNU gettext.
12828
12829 2006-07-23  Eric Blake  <ebb9@byu.net>
12830
12831         * modules/stdio-safer (Files): Add tmpfile-safer.c.
12832         (Depends-on): Add binary-io.
12833
12834 2006-07-23  Eric Blake  <ebb9@byu.net>
12835
12836         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
12837
12838 2006-07-23  Eric Blake  <ebb9@byu.net>
12839
12840         * lib/tmpfile-safer.c: New file.
12841         * lib/stdio-safer.h (fopen_safer): Add prototype.
12842         * lib/stdio--.h (tmpfile): Make safer.
12843
12844 2006-07-23  Bruno Haible  <bruno@clisp.org>
12845
12846         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
12847         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
12848         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
12849         gl_linked_remove_at): Use it.
12850
12851 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12852         and Simon Josefsson <jas@extundo.com>
12853
12854         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
12855
12856         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
12857
12858 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
12859
12860         * modules/close-stream: New file.
12861         * modules/closeout (Description): Make it clear that it exits
12862         with a diagnostic on error.
12863         (Depends-on): Add close-stream.  Remove fpending, stdbool.
12864         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
12865
12866 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
12867
12868         * m4/close-stream.m4: New file.
12869
12870 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
12871
12872         * lib/close-stream.c, lib/close-stream.h: New files.
12873
12874 2006-07-22  Bruno Haible  <bruno@clisp.org>
12875
12876         Merge from GNU gettext 0.15.
12877
12878         2006-05-01  Bruno Haible  <bruno@clisp.org>
12879
12880                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
12881
12882         2006-07-22  Bruno Haible  <bruno@clisp.org>
12883
12884                 * modules/javaversion: New file.
12885                 * MODULES.html.sh (Java): Add javaversion.
12886
12887         2006-03-12  Bruno Haible  <bruno@clisp.org>
12888
12889                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
12890
12891         2005-12-04  Bruno Haible  <bruno@clisp.org>
12892
12893                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
12894                 (untested).
12895
12896         2006-06-21  Bruno Haible  <bruno@clisp.org>
12897
12898                 Avoid warnings from recent versions of mcs.
12899                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
12900                 -o, -L, -r any more. Use options documented since mcs-1.0
12901                 instead. Similarly for -g.
12902
12903         2005-12-04  Bruno Haible  <bruno@clisp.org>
12904
12905                 * build-aux/csharpcomp.sh.in: Suffix for resources is
12906                 .resources, not .resource.
12907
12908         2005-07-09  Bruno Haible  <bruno@clisp.org>
12909
12910                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
12911                 add a .dll suffix.
12912                 Reported by Mark Junker <mjscod@gmx.de>.
12913
12914         2006-07-22  Bruno Haible  <bruno@clisp.org>
12915
12916                 * modules/gettext: Upgrade to gettext-0.15.
12917                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
12918                 m4/visibility.m4.
12919                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
12920
12921 2006-07-22  Bruno Haible  <bruno@clisp.org>
12922
12923         Merge from GNU gettext 0.15.
12924
12925         2006-03-25  Bruno Haible  <bruno@clisp.org>
12926
12927                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
12928
12929         2006-07-21  Bruno Haible  <bruno@clisp.org>
12930
12931                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
12932                 "1.1".
12933
12934         2006-05-09  Bruno Haible  <bruno@clisp.org>
12935
12936                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
12937                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
12938                 for the conftestver execution.
12939
12940         2006-05-01  Bruno Haible  <bruno@clisp.org>
12941
12942                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
12943                 optional target-version argument. Verify that the compiler
12944                 groks source of the specified source-version, or add -source
12945                 option as necessary. Verify that the compiler produces
12946                 bytecode in the specified target-version, or add -target and
12947                 -source options as necessary. Make the result of the test
12948                 available as variable CONF_JAVAC. Also log error output in
12949                 config.log.
12950
12951         2006-03-11  Bruno Haible  <bruno@clisp.org>
12952
12953                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
12954
12955         2006-05-09  Bruno Haible  <bruno@clisp.org>
12956
12957                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
12958                 CLASSPATH_SEPARATOR to a semicolon.
12959
12960         2006-03-12  Bruno Haible  <bruno@clisp.org>
12961
12962                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
12963                 available as variable CONF_JAVA, for subsequent autoconf
12964                 tests. Also log error output in config.log.
12965
12966         2006-07-19  Bruno Haible  <bruno@clisp.org>
12967
12968                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
12969                 that getline works on glibc2 systems. Needed to avoid trouble
12970                 in relocatable.c.
12971                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
12972
12973         2005-12-04  Bruno Haible  <bruno@clisp.org>
12974
12975                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
12976                 launcher (untested).
12977
12978         2005-12-04  Bruno Haible  <bruno@clisp.org>
12979
12980                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
12981
12982         2006-07-22  Bruno Haible  <bruno@clisp.org>
12983
12984                 * gettext.m4: Update from GNU gettext-0.15.
12985                 * nls.m4: Likewise.
12986                 * po.m4: Likewise.
12987                 * inttypes-pri.m4: Likewise.
12988                 * inttypes-h.m4: Renamed from inttypes.m4.
12989                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
12990
12991 2006-07-22  Bruno Haible  <bruno@clisp.org>
12992
12993         Merge from GNU gettext 0.15.
12994
12995         2005-07-05  Bruno Haible  <bruno@clisp.org>
12996
12997                 * printf-args.c (printf_fetchargs): Work around broken
12998                 definition of wint_t on mingw.
12999
13000         2005-02-12  Bruno Haible  <bruno@clisp.org>
13001
13002                 * xallocsa.h: Add extern "C" for C++.
13003
13004         2006-05-17  Bruno Haible  <bruno@clisp.org>
13005
13006                 Cygwin portability.
13007                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
13008
13009         2006-04-30  Bruno Haible  <bruno@clisp.org>
13010
13011                 * progreloc.c: Include <mach-o/dyld.h> if available.
13012                 (find_executable): Use _NSGetExecutablePath when possible.
13013
13014         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
13015
13016                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
13017                 function.
13018
13019         2005-12-29  Bruno Haible  <bruno@clisp.org>
13020
13021                 * progreloc.c (set_program_name_and_installdir): Fix
13022                 compilation error.
13023
13024         2005-12-04  Bruno Haible  <bruno@clisp.org>
13025
13026                 Cygwin portability.
13027                 * progreloc.c: Include <windows.h> also on Cygwin.
13028                 (find_executable): Add support for Cygwin.
13029                 (set_program_name_and_installdir): Handle also platforms with
13030                 nonempty EXEEXT.
13031
13032         2006-07-11  Bruno Haible  <bruno@clisp.org>
13033
13034                 * javacomp.c: Fix a comment.
13035                 Reported by Jim Meyering.
13036
13037         2006-04-30  Bruno Haible  <bruno@clisp.org>
13038
13039                 * javacomp.h (compile_java_class): Add source_version,
13040                 target_version arguments.
13041                 * javacomp.c: Rewritten to choose only a compiler that
13042                 respects the specified source_version and target_version.
13043
13044         2006-06-27  Bruno Haible  <bruno@clisp.org>
13045
13046                 Assume correct S_ISDIR macro.
13047                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
13048
13049         2006-07-22  Bruno Haible  <bruno@clisp.org>
13050
13051                 * javaversion.h: New file, from GNU gettext.
13052                 * javaversion.c: New file, from GNU gettext.
13053                 * javaversion.java: New file, from GNU gettext.
13054                 * javaversion.class: New file, from GNU gettext.
13055
13056         2006-05-17  Bruno Haible  <bruno@clisp.org>
13057
13058                 Cygwin portability.
13059                 * javaexec.c (execute_java_class): Test for jview program
13060                 also on Cygwin.
13061
13062         2006-04-09  Bruno Haible  <bruno@clisp.org>
13063
13064                 * fatal-signal.c: Don't include string.h.
13065                 (at_fatal_signal): Use a copying loop instead of memcpy.
13066
13067         2005-12-04  Bruno Haible  <bruno@clisp.org>
13068
13069                 * csharpexec.c: Add support for 'clix' launcher (untested).
13070                 (execute_csharp_using_sscli): New function.
13071                 (execute_csharp_program): Call it.
13072
13073         2006-06-21  Bruno Haible  <bruno@clisp.org>
13074
13075                 Avoid warnings from recent versions of mcs.
13076                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
13077                 -o, -L, -r any more. Use options documented since mcs-1.0
13078                 instead. Similarly for -g.
13079
13080         2005-07-09  Bruno Haible  <bruno@clisp.org>
13081
13082                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
13083                 add a .dll suffix.
13084                 Reported by Mark Junker <mjscod@gmx.de>.
13085
13086         2006-06-17  Bruno Haible  <bruno@clisp.org>
13087
13088                 * config.charset: Update for NetBSD 3.0.
13089
13090         2006-05-17  Bruno Haible  <bruno@clisp.org>
13091
13092                 Cygwin portability.
13093                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
13094
13095         2006-05-16  Bruno Haible  <bruno@clisp.org>
13096
13097                 * localcharset.c [CYGWIN]: Include <windows.h>.
13098                 (get_charset_aliases): For Cygwin, return the same CPxxx
13099                 aliases list as under WIN32.
13100                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
13101                 the environment variables. Fall back to GetACP().
13102
13103         2006-04-05  Bruno Haible  <bruno@clisp.org>
13104
13105                 * config.charset: Update Juan Manuel Guerrero's address.
13106
13107         2005-02-12  Bruno Haible  <bruno@clisp.org>
13108
13109                 * allocsa.h: Add extern "C" for C++.
13110
13111         2005-02-10  Bruno Haible  <bruno@clisp.org>
13112
13113                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
13114                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
13115
13116         2006-07-22  Bruno Haible  <bruno@clisp.org>
13117
13118                 * gettext.h: Update to GNU gettext-0.15.
13119
13120 2006-07-22  Bruno Haible  <bruno@clisp.org>
13121
13122         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
13123         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
13124         lib-prefix.m4, longdouble.m4, ssize_t.m4.
13125
13126 2006-07-21  Eric Blake  <ebb9@byu.net>
13127
13128         * modules/stdlib-safer: New file.
13129         * MODULES.html.sh (File stream based Input/Output): Add
13130         stdlib-safer.
13131
13132 2006-07-21  Eric Blake  <ebb9@byu.net>
13133
13134         * lib/stdlib-safer.h: New file from coreutils, required by
13135         stdlib--.h.
13136
13137 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
13138
13139         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
13140
13141 2006-07-20  Bruno Haible  <bruno@clisp.org>
13142
13143         * gnulib-tool: Recognize new option --assume-autoconf.
13144         (autoconf_minversion): New variable.
13145         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
13146
13147 2006-07-20  Bruno Haible  <bruno@clisp.org>
13148
13149         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
13150
13151 2006-07-19  Derek R. Price  <derek@ximbiot.com>
13152
13153         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
13154         Reindent and repaginate.
13155
13156 2006-07-19  Derek Price  <derek@ximbiot.com>
13157
13158         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
13159         Correct grammar.
13160
13161 2006-07-17  Bruno Haible  <bruno@clisp.org>
13162
13163         * modules/list: New file.
13164         * modules/array-list: New file.
13165         * modules/carray-list, modules/carray-list-tests: New files.
13166         * modules/linked-list, modules/linked-list-tests: New files.
13167         * modules/avltree-list, modules/avltree-list-tests: New files.
13168         * modules/rbtree-list, modules/rbtree-list-tests: New files.
13169         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
13170         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
13171         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
13172         * modules/oset: New file.
13173         * modules/array-oset: New file.
13174         * modules/avltree-oset, modules/avltree-oset-tests: New files.
13175         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
13176         * tests/test-carray_list.c: New file.
13177         * tests/test-linked_list.c: New file.
13178         * tests/test-avltree_list.c: New file.
13179         * tests/test-rbtree_list.c: New file.
13180         * tests/test-linkedhash_list.c: New file.
13181         * tests/test-avltreehash_list.c: New file.
13182         * tests/test-rbtreehash_list.c: New file.
13183         * tests/test-avltree_oset.c: New file.
13184         * tests/test-rbtree_oset.c: New file.
13185         * MODULES.html.sh (Container data structures): New section.
13186
13187 2006-07-17  Bruno Haible  <bruno@clisp.org>
13188
13189         * m4/gl_list.m4: New file.
13190
13191 2006-07-17  Bruno Haible  <bruno@clisp.org>
13192
13193         * lib/gl_list.h: New file.
13194         * lib/gl_list.c: New file.
13195         * lib/gl_array_list.h: New file.
13196         * lib/gl_array_list.c: New file.
13197         * lib/gl_carray_list.h: New file.
13198         * lib/gl_carray_list.c: New file.
13199         * lib/gl_linked_list.h: New file.
13200         * lib/gl_linked_list.c: New file.
13201         * lib/gl_anylinked_list1.h: New file.
13202         * lib/gl_anylinked_list2.h: New file.
13203         * lib/gl_avltree_list.h: New file.
13204         * lib/gl_avltree_list.c: New file.
13205         * lib/gl_anyavltree_list1.h: New file.
13206         * lib/gl_anyavltree_list2.h: New file.
13207         * lib/gl_rbtree_list.h: New file.
13208         * lib/gl_rbtree_list.c: New file.
13209         * lib/gl_anyrbtree_list1.h: New file.
13210         * lib/gl_anyrbtree_list2.h: New file.
13211         * lib/gl_anytree_list1.h: New file.
13212         * lib/gl_anytree_list2.h: New file.
13213         * lib/gl_linkedhash_list.h: New file.
13214         * lib/gl_linkedhash_list.c: New file.
13215         * lib/gl_anyhash_list1.h: New file.
13216         * lib/gl_anyhash_list2.h: New file.
13217         * lib/gl_avltreehash_list.h: New file.
13218         * lib/gl_avltreehash_list.c: New file.
13219         * lib/gl_rbtreehash_list.h: New file.
13220         * lib/gl_rbtreehash_list.c: New file.
13221         * lib/gl_anytreehash_list1.h: New file.
13222         * lib/gl_anytreehash_list2.h: New file.
13223
13224         * lib/gl_oset.h: New file.
13225         * lib/gl_oset.c: New file.
13226         * lib/gl_array_oset.h: New file.
13227         * lib/gl_array_oset.c: New file.
13228         * lib/gl_avltree_oset.h: New file.
13229         * lib/gl_avltree_oset.c: New file.
13230         * lib/gl_rbtree_oset.h: New file.
13231         * lib/gl_rbtree_oset.c: New file.
13232         * lib/gl_anytree_oset.h: New file.
13233
13234 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
13235
13236         * m4/mkancesdirs.m4: New file.
13237         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
13238         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
13239         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
13240         it.
13241
13242 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
13243
13244         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
13245         * lib/mkancesdirs.h: New files.
13246         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
13247         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
13248         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
13249         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
13250         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
13251         callers changed.  Revamp internals significantly, by not
13252         attempting to create directories that are temporarily more
13253         permissive than the final results.  Do not attempt to use
13254         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
13255         This removes some race conditions, fixes some bugs, and simplifies
13256         things.  Use new dirchownmod function to do owner and mode changes.
13257         * lib/mkdir-p.h: Likewise.
13258         * lib/modechange.c (octal_to_mode): New function.
13259         (struct mode_change): New member mentioned.
13260         (make_node_op_equals): New arg mentioned.  All callers changed.
13261         (mode_compile): Keep track of which mode bits the user has explicitly
13262         mentioned.
13263         (mode_adjust): New arg DIR, so that we implement the X op correctly.
13264         New arg PMODE_BITS, to keep track of which mode bits the user
13265         mentioned; it treats S_ISUID and S_ISGID speciall.
13266         All callers changed.
13267         * lib/modechange.h: Likewise.
13268
13269 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
13270
13271         * MODULES.html.sh: Add mkancestors.
13272         * modules/mkancesdirs: New module.
13273         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
13274         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
13275         The chdir-safer and afs files are now orphans; I'll remove them
13276         unless someone speaks up.
13277         Add lib/dirchownmod.c, lib/dirchownmod.h.
13278         (Depends-on): Remove alloca, chown, save-cwd, dirname.
13279         Add lchown, mkancesdirs.
13280         (Maintainer): Add self.
13281
13282 2006-07-15  Karl Berry  <karl@gnu.org>
13283
13284         * gnulib-tool: help message wording/arrangement.
13285
13286 2006-07-14  Simon Josefsson  <jas@extundo.com>
13287
13288         * doc/gnulib.texi (Libtool and Windows): New section.
13289
13290 2006-07-12  Simon Josefsson  <jas@extundo.com>
13291
13292         * modules/gendocs (License): Fix license, approved by Karl.
13293
13294 2006-07-12  Eric Blake  <ebb9@byu.net>
13295
13296         * MODULES.html.sh: Add gendocs.
13297
13298 2006-07-11  Eric Blake  <ebb9@byu.net>
13299
13300         * modules/fdl: New module, to install doc/fdl.texi.
13301         * MODULES.html.sh: Add new section for documentation modules.
13302         * gnulib-tool: Avoid space-tab.
13303         (--doc-base): New option, to manage files from doc.
13304
13305 2006-07-11  Eric Blake  <ebb9@byu.net>
13306
13307         * m4/absolute-header.m4: Fix comments to match recent change.
13308
13309 2006-07-11  Eric Blake  <ebb9@byu.net>
13310
13311         * gnulib-tool: List --doc-base before --tests-base.
13312
13313 2006-07-11  Derek R. Price  <derek@ximbiot.com>
13314
13315         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
13316
13317 2006-07-11  Bruno Haible  <bruno@clisp.org>
13318
13319         * README: Mention where to put documentation.
13320
13321 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13322
13323         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
13324
13325 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
13326
13327         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
13328         to stdint.m4.
13329
13330 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
13331
13332         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
13333         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
13334         "no/such/file/stdint.h" when there is no such file, so that
13335         the resulting C code can be parsed by dodgy compilers.
13336         Problems reported by Bob Proulx.
13337
13338 2006-07-10  Derek R. Price  <derek@ximbiot.com>
13339
13340         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
13341         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
13342         macros into the GNU _D_EXACT_NAMLEN.
13343         * lib/savedir.c:  Likewise.
13344         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
13345
13346 2006-07-10  Derek R. Price  <derek@ximbiot.com>
13347         and Paul Eggert  <eggert@cs.ucla.edu>
13348
13349         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
13350         * m4/savedir.m4:
13351         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
13352         macros into the GNU _D_EXACT_NAMLEN.
13353
13354 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
13355
13356         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
13357         around the absolute name, to work around a problem with the HP-UX
13358         11.23 native C compiler, reported by Bob Proulx.
13359
13360 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
13361
13362         * doc/maintain.texi, make-stds.texi: Sync from
13363         <http://savannah.gnu.org/projects/gnustandards>.
13364
13365 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
13366
13367         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
13368
13369 2006-07-09  Jim Meyering  <jim@meyering.net>
13370
13371         * m4/glob.m4: Remove a doubled word in a comment.
13372
13373 2006-07-09  Jim Meyering  <jim@meyering.net>
13374
13375         * lib/argp-pv.c: Remove a doubled word in a comment.
13376         * lib/check-version.c (check_version): Likewise.
13377         * lib/javacomp.c (compile_java_class): Likewise.
13378
13379 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
13380
13381         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
13382         for the benefit of people using Autoconf 2.60.  If you want to
13383         support older Autoconf versions you can copy m4/onceonly_2_57.m4
13384         (or m4/onceonly.m4, if pre-2.57) manually.
13385
13386 2006-07-08  Jim Meyering  <jim@meyering.net>
13387
13388         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
13389         comment.
13390         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
13391         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
13392         comment.
13393
13394 2006-07-08  Jim Meyering  <jim@meyering.net>
13395
13396         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
13397
13398 2006-07-07  Simon Josefsson  <jas@extundo.com>
13399
13400         * tests/test-crc.c: Change expected crc value, the test vector
13401         were probably computed using the old broken crc.c?
13402
13403 2006-07-06  Simon Josefsson  <jas@extundo.com>
13404
13405         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
13406         now the canonical place for the M4 file).
13407
13408         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
13409         from the sys_socket dependency now.
13410
13411         * modules/inet_pton (Files): Ditto.
13412
13413         * modules/inet_ntop (Files): Ditto.
13414
13415 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
13416
13417         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
13418         not gl_PREREQ_GETUSERSHELL.
13419
13420 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13421
13422         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
13423         with only one argument, for Autoconf 2.60.
13424         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
13425         expand to nothing, so add a shell command to avoid syntax error.
13426         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
13427
13428 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13429
13430         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
13431
13432 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
13433
13434         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
13435         no longer needed.  Check for isblank decl.
13436         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
13437         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
13438         of existence.
13439
13440 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
13441
13442         * lib/getloadavg.c: Use __VMS, not VMS.
13443         * lib/getopt.c: Likewise.
13444         * lib/getpagesize.h: Likewise.
13445         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
13446         and probably does not work.
13447
13448 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
13449
13450         * lib/.cppi-disable: Add wcwidth.
13451         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
13452         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
13453         (ISGRAPH): Remove.  All uses changed to isgraph.
13454         (FOLD) [!defined _LIBC]: Remove special case.
13455         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
13456         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
13457         HAVE_ISBLANK.
13458         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
13459         case.
13460
13461 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
13462
13463         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
13464         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
13465         brackets.  Other minor changes to suppress some compiler
13466         warnings.
13467
13468 2006-07-06  Derek R. Price  <derek@ximbiot.com>
13469         and Paul Eggert  <eggert@cs.ucla.edu>
13470
13471         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
13472         of invoking obsolescent AC_HEADER_DIRENT macro.
13473         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
13474         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
13475         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
13476         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
13477         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
13478         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
13479         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
13480         * m4/readdir.m4: Remove; no longer needed.
13481
13482 2006-07-06  Derek R. Price  <derek@ximbiot.com>
13483         and Paul Eggert  <eggert@cs.ucla.edu>
13484
13485         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
13486         Don't worry about this obsolete case any more.
13487         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
13488         directories.
13489         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
13490         worry about this obsolete case any more.
13491         * lib/fts.c: Likewise.
13492         * lib/getcwd.c: Likewise.
13493         * lib/glob.h: Likewise.
13494         * lib/savedir.c: Likewise.
13495
13496 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
13497
13498         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
13499         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
13500         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
13501         needed.
13502         All uses removed.
13503         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13504         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
13505         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
13506         needed.
13507         * m4/getdate.m4 (gl_GETDATE): Likewise.
13508         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
13509         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
13510         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
13511         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13512         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
13513         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
13514         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
13515         needed.
13516
13517 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
13518
13519         * lib/memcasecmp.c: Include <limits.h>.
13520         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
13521         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
13522         Don't assume isdigit succeeds only on '0' through '9'.
13523
13524 2006-07-05  Eric Blake  <ebb9@byu.net>
13525
13526         * modules/getaddrinfo (Depends-on): Add snprintf.
13527
13528 2006-07-05  Eric Blake  <ebb9@byu.net>
13529
13530         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
13531         to avoid 'header present but could not be compiled' on cygwin.
13532
13533 2006-07-05  Eric Blake  <ebb9@byu.net>
13534
13535         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
13536         missing from netdb.h.
13537         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
13538
13539 2006-07-05  Derek R. Price  <derek@ximbiot.com>
13540
13541         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
13542         no longer needed.
13543         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
13544         * m4/getdate.m4 (gl_GETDATE): Likewise.
13545         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
13546         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
13547         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
13548         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13549         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
13550
13551 2006-07-05  Derek R. Price  <derek@ximbiot.com>
13552
13553         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
13554         All uses of is_space replaced by isspace.
13555         * lib/exit.h: Don't talk about STDC_HEADERS.
13556         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
13557         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
13558         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
13559         replaced by isprint etc.
13560         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
13561         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
13562         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
13563         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
13564         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
13565         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
13566
13567 2006-07-05  Bruno Haible  <bruno@clisp.org>
13568
13569         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
13570         the function exists, before testing against AIX.
13571         Reported by Martin Lambers <marlam@marlam.de>.
13572
13573 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
13574
13575         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
13576         From Mark D. Baushke.
13577
13578 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
13579
13580         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
13581         to the absolute name, not just one, to bypass Sun C 5.8's
13582         "warning: #include of /usr/include/... may be non-portable".
13583
13584 2006-07-04  Eric Blake  <ebb9@byu.net>
13585
13586         * modules/dirname-tests: New test module.
13587         * tests/test-dirname.c: New file, replacing dirname.c
13588         TEST_DIRNAME section that was recently deleted.
13589
13590 2006-07-04  Bruno Haible  <bruno@clisp.org>
13591
13592         Assume ANSI C header files and <ctype.h> functions.
13593         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
13594         (mbsnwidth): Use isprint, iscntrl instead.
13595
13596 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13597
13598         Merge from coreutils.
13599         * MODULES.html.sh: Add xstrtold.
13600         * modules/xstrtold: New file.
13601         * modules/cycle-check (Files): Add lib/same-inode.h.
13602         * modules/dirname (Files): Add m4/double-slash-root.m4.
13603         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
13604         * modules/mkdir-p (Files): Add lib/same-inode.h.
13605         * modules/same (Files): Add lib/same-inode.h.
13606
13607 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13608
13609         * m4/absolute-header.m4: Renamed from full-header-path.m4.
13610         This is to keep the terminology clean; POSIX talks about
13611         "absolute pathnames", not "full pathnames", but the GNU
13612         Coding Standards say to use "path" for something else;
13613         so use "absolute" to keep both sides happy.
13614         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
13615         Set gl_absolute_header, not gl_full_header_path.
13616         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
13617         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
13618         All uses changed.
13619
13620         Merge from coreutils.
13621
13622         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
13623
13624         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
13625         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
13626         want to require the building of c-strtod.o.
13627         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
13628         needs -lm directly.
13629         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
13630
13631         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
13632
13633         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
13634         --as-needed option if available.  Problem reported by Albert Chin in
13635         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
13636         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
13637         cc merely issues a bunch of annoying warnings for --as-needed
13638         (this problem was reported by Bob Proulx).  Also, try linking with
13639         -lm to detect a bug in binutils 2.16 (this problem was reported
13640         by Ralf Wildenhues).
13641
13642         2006-06-18  Jim Meyering  <jim@meyering.net>
13643
13644         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
13645         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
13646         macro.
13647         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
13648         also check for glibc-2.4's abort-inducing bug.
13649
13650         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
13651         Low-probability clean-up should be to use rmdir to get rid of
13652         the just-created directory, not unlink.
13653
13654         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
13655         configure fail, and request a bug report to inform us about it.
13656         Add a comment that, barring reports to the contrary, in 2007 we'll
13657         assume ftruncate is universally available.
13658
13659         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
13660
13661         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
13662
13663         2006-03-12  Jim Meyering  <jim@meyering.net>
13664
13665         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
13666         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
13667         * m4/same.m4 (gl_SAME): Likewise.
13668         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
13669
13670         2006-03-11  Eric Blake  <ebb9@byu.net>
13671
13672         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
13673         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
13674         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
13675         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
13676
13677 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13678
13679         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
13680         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
13681         reported by Mark D. Baushke, one in
13682         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
13683
13684         Merge from coreutils.
13685
13686         * lib/.cppi-disable: Add stdint_.h.
13687         * lib/.cvsignore: Add stdint.h.
13688
13689         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
13690
13691         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
13692         both double and long double versions.
13693         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
13694         * lib/xstrtold.c: New file.
13695         * lib/xstrtod.h (xstrtold): New decl.
13696
13697         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
13698
13699         * lib/filemode.c (setst): Remove.
13700         (strmode): Rewrite to avoid setst.  This makes the code shorter,
13701         (arguably) clearer, and the generated code is a bit smaller on my
13702         Debian GNU/Linux stable x86 host.
13703
13704         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
13705
13706         * lib/filemode.c: Include "filemode.h" first, to test the interface.
13707         Assume that filemode.h includes sys/types.h and sys/stat.h.
13708         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
13709         (ftypelet): Reorder to put common cases first, for efficiency.
13710         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
13711         to do 'M'.
13712         (strmode): Renamed from mode_string, and now stores 12 bytes instead
13713         of 10, for compatibility with FreeBSD.  All callers changed.
13714         (filemodestring): Now stores 12 bytes instead of 10, and sets file
13715         types that can't be deduced solely from st_mode.  First arg is now a
13716         const pointer.
13717         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
13718         (strmode): Renamed from mode_string.
13719         (filemodestring): New decl.
13720         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
13721         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
13722         needed.
13723         (S_ISPORT, S_ISWHT): New macros, if not already defined.
13724
13725         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
13726
13727         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
13728         fsusage.h now does that.  Include fsusage.h first, to test interface.
13729         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
13730         at most one method (the old code could have generated decls that
13731         didn't conform to C89, not that this was ever exercised).
13732         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
13733
13734         2006-03-19  Jim Meyering  <jim@meyering.net>
13735
13736         Work even in a chroot where d_ino values for entries in "/"
13737         don't match the stat.st_ino values for the same names.
13738         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
13739         number, iterate through all entries again, using lstat instead.
13740         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
13741         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
13742
13743         * lib/getcwd.c (__getcwd): Clarify a comment.
13744         Use memcpy in place of a call to strcpy.
13745
13746         2006-03-12  Jim Meyering  <jim@meyering.net>
13747
13748         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
13749         matches that of the current directory (which we're about to chdir ".."
13750         out of), then save the dev-ino of the parent, instead.
13751
13752         * lib/same-inode.h (SAME_INODE): New file/macro.
13753         * lib/chdir-safer.c (SAME_INODE): Remove definition.
13754         Include "same-inode.h", instead.
13755         * lib/same.c: Likewise.
13756         * lib/cycle-check.h: Include "same-inode.h".
13757         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
13758         * lib/cycle-check.c (SAME_INODE): Remove definition.
13759         * lib/root-dev-ino.h: Include "same-inode.h".
13760
13761         2006-03-11  Eric Blake  <ebb9@byu.net>
13762
13763         * lib/same.c (same_name): s/base_name/last_component/
13764         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
13765         * lib/filenamecat.c (file_name_concat): Likewise.
13766
13767         2006-03-11  Eric Blake  <ebb9@byu.net>,
13768                     Paul Eggert  <eggert@cs.ucla.edu>
13769
13770         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
13771         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
13772         drive prefix.
13773         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
13774         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
13775         (last_component): New method.
13776         * lib/dirname.c (dir_len): Determine when drive letters need a
13777         subsequent slash.  Preserve // when it is special.
13778         (dir_name): Don't append dot when drive letter is absolute.
13779         [TEST_DIRNAME]: Move into a full-blown gnulib test.
13780         * lib/basename.c (base_name): New semantics - malloc the result.
13781         Preserve // when it is special.  Preserve relative files that look
13782         like drive letters.
13783         (base_len): Preserve // when it is special.
13784         (last_component): New method, similar to old base_name semantics.
13785         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
13786         base_name.  Strip redundant slashes from ///.
13787
13788 2006-07-03  Jim Meyering  <jim@meyering.net>
13789
13790         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
13791         macro is used before the first cycle_check call.
13792
13793 2006-07-03  Eric Blake  <ebb9@byu.net>
13794
13795         * modules/dirname (Depends-on): Add xstrndup.
13796
13797 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
13798
13799         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
13800         test cases, so that config.log is a bit easier to follow.
13801
13802 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
13803
13804         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
13805         both are 64 bits, since this seems to be the tradition, and this
13806         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
13807         we ever run into a host that prefers long long to long in this
13808         case, we'll need another configure-time test.  Problem reported by
13809         Jim Meyering.
13810
13811 2006-07-02  Eric Blake  <ebb9@byu.net>
13812
13813         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
13814
13815 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
13816
13817         * modules/inttypes (Depends-on): No longer depends on stdint.
13818         * modules/stdint (Description): Say more about assumptions.
13819         Say that the fast types might differ.  Say macros are used.
13820         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
13821         (Makefile.am): Revise list of substituted symbols to match
13822         new stdint.m4.
13823         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
13824         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
13825         * tests/test-stdint.c (verify_same_types)
13826         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
13827         the code conforms to C99/C89.
13828         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
13829         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
13830
13831 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
13832
13833         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
13834         but fix a bug, by requiring at least 64 bits.
13835         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
13836         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
13837         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
13838         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
13839
13840         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
13841         changes.  Make 2.59 a prerequisite.  Check and substitute for
13842         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
13843         inttypes.h.  Do not use special include files; just use the
13844         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
13845         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
13846         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
13847         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
13848         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
13849         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
13850         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
13851         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
13852         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
13853         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
13854         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
13855         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
13856         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
13857         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
13858         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
13859         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
13860         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
13861         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
13862         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
13863         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
13864         WINT_MAX.  Check for C99 conformance more strictly, by detecting
13865         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
13866         not check for things that C99 does not require, e.g., int8_t.  If
13867         a test isn't needed unless <stdint.h> isn't working, and is
13868         unlikely to be needed for any other reason, then don't do it
13869         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
13870         size_t, since we assume C89 freestanding at least.  Do not check
13871         for sig_atomic_t, wchar_t, or wint_t, since the code now does
13872         the right thing even if the types are not defined.  Instead use:
13873         (gl_STDINT_TYPE_PROPERTIES): New macro.
13874         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
13875         testing whether <sys/types.h> clashes, as Autoconf does this for
13876         us now.  All uses removed.
13877         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
13878         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
13879         (gl_CHECK_TYPE_SAME):
13880         Remove; no longer needed.
13881         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
13882         exists, since we'll return 0 anyway in that case.
13883         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
13884
13885 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
13886
13887         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
13888         possible collision with system files.
13889         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
13890         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
13891         WCHAR_MIN and WCHAR_MAX in this case.
13892         (<stddef.h>): Do not include; no longer needed.
13893         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
13894         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
13895         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
13896         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
13897         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
13898         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
13899         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
13900         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
13901         !defined(__c99))]: Include in this case too, since it's harmless
13902         now.
13903         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
13904         dangerous to do so.
13905         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
13906         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
13907         (_STDINT_MIN, _STDINT_MAX): New macros.
13908         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
13909         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
13910         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
13911         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
13912         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
13913         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
13914         macros, not typedefs; this simplifies things quite a bit.
13915         Use long int for all types narrower than int64_t.
13916         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
13917         Define in terms of long long int or int64_t or long int,
13918         not int64_t or int32_t.  This saves some compile-time testing.
13919         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
13920         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
13921         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
13922         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
13923         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
13924         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
13925         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
13926         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
13927         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
13928         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
13929         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
13930         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
13931         undef any previous version and define our own version, for
13932         simplicity and consistency with the new macros for types.
13933         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
13934         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
13935         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
13936         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
13937         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
13938         @WINT_T_SUFFIX@ to keep things simple here.
13939         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
13940         Simplify by assuming typical 8/16/32/64 host, since we're
13941         already doing that elsewhere anyway.
13942         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
13943         and assume long long int is 64 bits if available.  This
13944         speeds up 'configure'.
13945
13946 2006-07-01  Eric Blake  <ebb9@byu.net>
13947
13948         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
13949         Reported by Andreas Buening.
13950
13951 2006-07-01  Eric Blake  <ebb9@byu.net>
13952
13953         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
13954
13955 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
13956
13957         * lib/getaddrinfo.c: fixed typo
13958
13959 2006-06-29  Jim Meyering  <jim@meyering.net>
13960
13961         * modules/strftime (Maintainer): Add my name, since with the
13962         FPRINTFTIME changes strftime.c has forked from glibc.
13963
13964 2006-06-29  Eric Blake  <ebb9@byu.net>
13965
13966         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
13967
13968 2006-06-29  Eric Blake  <ebb9@byu.net>
13969
13970         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
13971
13972 2006-06-29  Eric Blake  <ebb9@byu.net>
13973
13974         * lib/stat_.h: New file.
13975
13976 2006-06-29  Eric Blake  <ebb9@byu.net>
13977
13978         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
13979         unused static function.
13980
13981 2006-06-29  Eric Blake  <ebb9@byu.net>
13982
13983         * doc/functions.texi (Function Portability): Document missing lstat
13984         on mingw.
13985
13986 2006-06-29  Eric Blake  <ebb9@byu.net>
13987
13988         * MODULES.html.sh: Add sys_stat.
13989         * modules/sys_stat: New module.
13990         * modules/mkstemp (Depends-on): Add sys_stat.
13991
13992 2006-06-29  Derek R. Price  <derek@ximbiot.com>
13993
13994         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
13995
13996 2006-06-29  Derek R. Price  <derek@ximbiot.com>
13997
13998         * m4/c-bs-a.m4: Removed.
13999
14000 2006-06-29  Derek R. Price  <derek@ximbiot.com>
14001
14002         * lib/strftime.c: Assume strftime() exists.
14003
14004 2006-06-29  Derek Price  <derek@ximbiot.com>
14005
14006         * modules/c-bs-a: Removed - \a is C89.
14007         * MODULES.html.sh: Remove c-bs-a.
14008
14009 2006-06-29  Bruno Haible  <bruno@clisp.org>
14010
14011         * modules/wcwidth (License): Change to LGPL.
14012
14013 2006-06-28  Simon Josefsson  <jas@extundo.com>
14014
14015         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
14016         on _WIN32.
14017
14018         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
14019         getnameinfo.
14020
14021 2006-06-28  Simon Josefsson  <jas@extundo.com>
14022
14023         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
14024
14025 2006-06-28  Simon Josefsson  <jas@extundo.com>
14026
14027         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
14028         functions there.  It will succeed on Windows XP, but on Windows
14029         2000 and (presumably) earlier, it will fail, and use the internal
14030         re-implementation.
14031         (use_win32_p): New function.
14032         (getaddrinfo): Use strtoul on servname, to support numeric ports.
14033         Support AI_NUMERICSERV to disable getservbyname.
14034         (getnameinfo): New function, only supports
14035         NI_NUMERICHOST|NI_NUMERICSERV for now.
14036
14037         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
14038         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
14039         getnameinfo.
14040
14041 2006-06-28  Eric Blake  <ebb9@byu.net>
14042
14043         * modules/wcwidth: New file.
14044         * modules/mbchar (Depends-on): Add wcwidth.
14045         * modules/mbswidth (Depends-on): Add wcwidth.
14046         * MODULES.html.sh: Add wcwidth.
14047
14048 2006-06-28  Eric Blake  <ebb9@byu.net>
14049
14050         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
14051         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
14052
14053 2006-06-28  Eric Blake  <ebb9@byu.net>
14054
14055         * lib/xvasprintf.h: Fix comments.
14056
14057 2006-06-28  Eric Blake  <ebb9@byu.net>
14058
14059         * lib/mbchar.h (wcwidth): Include wcwidth.h.
14060         * lib/mbswidth.c (wcwidth): Move from here...
14061         * lib/wcwidth.h: ...to this new file.
14062
14063 2006-06-28  Derek R. Price  <derek@ximbiot.com>
14064
14065         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
14066
14067         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
14068         it's obsolete.
14069         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
14070
14071 2006-06-28  Derek R. Price  <derek@ximbiot.com>
14072
14073         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
14074         Autoconf 2.60 says this stuff was obsolete.
14075
14076 2006-06-28  Bruno Haible  <bruno@clisp.org>
14077
14078         * modules/wcwidth (Files): Add m4/wchar_t.m4.
14079
14080 2006-06-28  Bruno Haible  <bruno@clisp.org>
14081
14082         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
14083         gt_TYPE_WCHAR_T.
14084
14085 2006-06-28  Bruno Haible  <bruno@clisp.org>
14086
14087         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
14088         declaration for wcwidth.
14089         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
14090
14091 2006-06-28  Bruno Haible  <bruno@clisp.org>
14092
14093         * lib/mkdtemp.c [MINGW]: Include <io.h>.
14094         (mkdir): Define using _mkdir.
14095
14096 2006-06-28  Bruno Haible  <bruno@clisp.org>
14097
14098         * lib/getaddrinfo.h: Fix POSIX URL.
14099         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
14100         _WIN32.
14101         (use_win32_p): Make static.
14102         (getaddrinfo): Reject service name if it is empty or does not consist
14103         solely of decimal digits, or if its value is > 65535.
14104         (getnameinfo): Remove useless casts.
14105
14106 2006-06-27  Simon Josefsson  <jas@extundo.com>
14107
14108         * modules/sys_select: New file, suggested by Bruno Haible, Paul
14109         Eggert and Martin Lambers.
14110
14111 2006-06-27  Simon Josefsson  <jas@extundo.com>
14112
14113         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
14114         Eggert and Martin Lambers.
14115
14116 2006-06-27  Bruno Haible  <bruno@clisp.org>
14117
14118         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
14119         result to 0, not to empty.
14120         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
14121
14122 2006-06-27  Bruno Haible  <bruno@clisp.org>
14123
14124         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
14125
14126 2006-06-26  Simon Josefsson  <jas@extundo.com>
14127
14128         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
14129         present.
14130
14131 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
14132
14133         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
14134         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
14135         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
14136
14137 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
14138
14139         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
14140
14141 2006-06-26  Bruno Haible  <bruno@clisp.org>
14142
14143         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
14144
14145 2006-06-26  Bruno Haible  <bruno@clisp.org>
14146
14147         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
14148
14149 2006-06-26  Bruno Haible  <bruno@clisp.org>
14150
14151         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
14152         SGI C compiler in pre-C99 mode.
14153         Suggested by Mark D. Baushke and Larry Jones.
14154
14155 2006-06-26  Bruno Haible  <bruno@clisp.org>
14156
14157         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
14158         WCHAR_MAX.
14159         Reported by Mark D. Baushke and Larry Jones.
14160
14161 2006-06-26  Bruno Haible  <bruno@clisp.org>
14162
14163         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
14164         in pre-C99 mode.
14165         Suggested by Mark D. Baushke and Larry Jones.
14166
14167 2006-06-23  Simon Josefsson  <jas@extundo.com>
14168             Bruno Haible  <bruno@clisp.org>
14169
14170         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
14171         Emit mostlyclean-local rule.
14172         (func_emit_tests_Makefile_am): Likewise.
14173         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
14174
14175 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
14176
14177         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
14178
14179 2006-06-23  Bruno Haible  <bruno@clisp.org>
14180
14181         * tests/test-stdint.c: Update to match ISO C 99 Technical
14182         Corrigendum 1.
14183
14184 2006-06-23  Bruno Haible  <bruno@clisp.org>
14185
14186         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
14187
14188 2006-06-23  Bruno Haible  <bruno@clisp.org>
14189
14190         * lib/stdint_.h: Treat IRIX like OpenBSD.
14191
14192 2006-06-23  Bruno Haible  <bruno@clisp.org>
14193
14194         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
14195         ISO C 99 Technical Corrigendum 1.
14196
14197 2006-06-22  Simon Josefsson  <jas@extundo.com>
14198
14199         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
14200         MinGW.
14201
14202 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
14203
14204         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
14205         needed.  Some compiler complained about some of them.  Problem reported
14206         by Larry Jones in
14207         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
14208
14209 2006-06-21  Simon Josefsson  <jas@extundo.com>
14210
14211         * tests/test-getaddrinfo.c: New file.
14212
14213         * modules/getaddrinfo-tests: New file.
14214
14215         * MODULES.html.sh: Add inet_pton.
14216
14217         * modules/inet_pton: New file.
14218
14219 2006-06-21  Simon Josefsson  <jas@extundo.com>
14220
14221         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
14222         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
14223         of using the (limited) gnulib implementation on Windows XP.
14224
14225         * m4/inet_pton.m4: New file.
14226
14227 2006-06-21  Simon Josefsson  <jas@extundo.com>
14228
14229         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
14230         variable.
14231
14232         * lib/socket_.h: Don't define WINVER.
14233
14234         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
14235         slightly modified to work in gnulib.
14236
14237 2006-06-21  Simon Josefsson  <jas@extundo.com>
14238
14239         * doc/gnulib.texi (Windows sockets): Add.
14240
14241 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
14242
14243         * lib/read-file.c (fread_file): Start with buffer allocation of
14244         0 bytes rather than 1 byte; this simplifies the code.
14245         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
14246         code to free buffer and save/restore errno.
14247         (internal_read_file): Remove unused local.
14248
14249 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
14250
14251         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
14252         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
14253         Problem reported by Denis Excoffier in
14254         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
14255
14256 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
14257
14258         * modules/sys_socket, modules/socklen: Include sys/types since
14259         FreeBSD 4.x's sys/socket.h needs it.
14260
14261 2006-06-19  Simon Josefsson  <jas@extundo.com>
14262
14263         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
14264
14265 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
14266
14267         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
14268
14269 2006-06-19  Bruno Haible  <bruno@clisp.org>
14270
14271         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
14272         and FULL_PATH_INTTYPES_H in angle brackets.
14273         Reported by Mark D. Baushke <mdb@gnu.org>.
14274
14275 2006-06-17  Eric Blake  <ebb9@byu.net>
14276
14277         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
14278         errno.
14279
14280 2006-06-17  Bruno Haible  <bruno@clisp.org>
14281
14282         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
14283         <sys/inttypes.h>.
14284
14285 2006-06-17  Bruno Haible  <bruno@clisp.org>
14286
14287         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
14288         whether errno is declared. Assume <errno.h> declares errno.
14289
14290 2006-06-17  Bruno Haible  <bruno@clisp.org>
14291
14292         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
14293
14294 2006-06-17  Bruno Haible  <bruno@clisp.org>
14295
14296         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
14297         problem on Solaris 2.5.1.
14298
14299 2006-06-16  Eric Blake  <ebb9@byu.net>
14300
14301         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
14302         * lib/unicodeio.c [!defined errno]: Likewise.
14303         * lib/strtol.c [!defined errno]: Likewise.
14304         * lib/strtod.c [!defined errno]: Likewise.
14305
14306 2006-06-15  Eric Blake  <ebb9@byu.net>
14307
14308         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
14309
14310 2006-06-15  Eric Blake  <ebb9@byu.net>
14311
14312         * config/srclist.txt (ssize_t.m4): Lose sync.
14313
14314 2006-06-15  Bruno Haible  <bruno@clisp.org>
14315
14316         * modules/stdint (Files): Include m4/full-header-path.m4,
14317         m4/size_max.m4, m4/wchar_t.m4.
14318         (Makefile.am): Many more substitutions.
14319         * modules/stdint-tests: New file.
14320         * tests/test-stdint.c: New file.
14321
14322 2006-06-15  Bruno Haible  <bruno@clisp.org>
14323
14324         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
14325         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
14326         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
14327         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
14328         gl_CHECK_TYPE_SAME): New macros.
14329
14330 2006-06-15  Bruno Haible  <bruno@clisp.org>
14331
14332         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
14333
14334 2006-06-15  Bruno Haible  <bruno@clisp.org>
14335
14336         * lib/stdint_.h: Rewritten to be fully auto-configured.
14337         Fixes bug on HP-UX/IA64.
14338
14339 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
14340
14341         * lib/getdate.y (__attribute__): Don't define if already defined.
14342         Problem reported by Larry Jones.
14343         * lib/utimens.c (__attribute__): Likewise.
14344
14345 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
14346
14347         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
14348         reported by Andreas Schwab.
14349
14350 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14351             Bruno Haible  <bruno@clisp.org>
14352
14353         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
14354         check for the declaration of strnlen and a run test that exposes the
14355         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
14356         rpl_strndup.
14357
14358 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14359             Bruno Haible  <bruno@clisp.org>
14360
14361         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
14362
14363 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14364
14365         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
14366         compile test, for Tru64 4.0D.
14367
14368 2006-05-28  Karl Berry  <karl@gnu.org>
14369
14370         * config/srclist.txt (printf-args.c): lose sync.
14371
14372 2006-05-26  Martin Lambers  <marlam@marlam.de>
14373
14374         * lib/getpass.c: Updates the test for the native W32 API, and adds
14375         missing includes, thus fixing compilation warnings.
14376
14377 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
14378
14379         * lib/exclude.c (exclude_fnmatch): New function.
14380         (excluded_file_name): Call exclude_fnmatch.
14381         * lib/exclude.h (excluded_file_name): New prototype
14382
14383 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
14384
14385         * lib/tempname.c (small_open, large_open): New macros.
14386         (__open, __open64) [!_LIBC]: Remove.
14387         (__gen_tempname): Use small_open and large_open instead of __open
14388         and __open64.  This fixes a portability bug on HP-UX 11.11i
14389         reported by Simon Wing-Tang in
14390         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
14391
14392 2006-05-24  Bruno Haible  <bruno@clisp.org>
14393
14394         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
14395         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
14396         Reported by Thorsten Maerz <torte@netztorte.de> via
14397         Aaron Stone <aaron@serendipity.cx>.
14398
14399 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
14400
14401         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
14402         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
14403         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
14404         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
14405         not really conditional on the cache.
14406         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
14407
14408 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
14409
14410         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
14411         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
14412         (my_usleep): Don't mishandle maximum value.
14413
14414 2006-05-19  Jim Meyering  <jim@meyering.net>
14415
14416         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
14417
14418 2006-05-17  Bruno Haible  <bruno@clisp.org>
14419
14420         Cygwin portability.
14421         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
14422
14423 2006-05-17  Bruno Haible  <bruno@clisp.org>
14424
14425         * lib/stdint_.h: Fix recognition of Cygwin.
14426
14427 2006-05-15  Bruno Haible  <bruno@clisp.org>
14428
14429         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
14430         on libtool patch by Ralf Wildenhues.
14431
14432 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
14433
14434         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
14435         test for C99 conformance; (bool) 0.5 is an integer constant
14436         expression, but (bool) -0.5 is not.  Problem reported by Fedor
14437         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
14438
14439 2006-05-11  Simon Josefsson  <jas@extundo.com>
14440
14441         * m4/xvasprintf.m4: Fix obvious typo.
14442
14443 2006-05-11  Jim Meyering  <jim@meyering.net>
14444
14445         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
14446         James Lemley.
14447
14448 2006-05-10  Simon Josefsson  <jas@extundo.com>
14449
14450         * lib/md4.c: Typo fix, update copyright years.
14451         (K1, K2): Don't use L because it turn computations into 64-bit on
14452         64-bit platforms.
14453
14454 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
14455
14456         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
14457         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
14458         unwanted sign propagation, e.g., on hosts with 64-bit int.
14459         There still are some problems with reeelly weird theoretical hosts
14460         (e.g., 33-bit int) but it's not worth worrying about now.
14461         * lib/sha1.c (rol): Likewise.
14462         (K1, K2, K3, K4): Remove unnecessary L suffix.
14463
14464 2006-05-10  Bruno Haible  <bruno@clisp.org>
14465
14466         * lib/des.c: Cast to avoid warnings.
14467
14468 2006-05-09  Bruno Haible  <bruno@clisp.org>
14469
14470         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
14471         (Depends-on): Depend also on xsize, stdarg.
14472         (configure.ac): Add gl_XVASPRINTF.
14473
14474 2006-05-09  Bruno Haible  <bruno@clisp.org>
14475
14476         * m4/xvasprintf.m4: New file.
14477
14478 2006-05-09  Bruno Haible  <bruno@clisp.org>
14479
14480         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
14481         (EOVERFLOW): Define fallback value.
14482         (xstrcat): New function.
14483         (xvasprintf): Recognize the special case of a string concatenation.
14484
14485 2006-05-08  Eric Blake  <ebb9@byu.net>
14486
14487         * gnulib-tool (func_version): Base copyright year on CVS date.
14488         (func_emit_copyright_notice): New function.
14489         (func_emit_lib_Makefile_am): Use it.
14490         (func_emit_tests_Makefile_am): Likewise.
14491         (func_import): Likewise.
14492
14493 2006-05-08  Bruno Haible  <bruno@clisp.org>
14494
14495         * modules/stdarg: New file.
14496         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
14497
14498 2006-05-08  Bruno Haible  <bruno@clisp.org>
14499
14500         * m4/stdarg.m4: New file, from GNU gettext.
14501
14502 2006-05-08  Bruno Haible  <bruno@clisp.org>
14503
14504         * config/srclist.txt (build-aux/config.rpath): different from latest
14505         release.
14506
14507 2006-05-08  Bruno Haible  <bruno@clisp.org>
14508
14509         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
14510
14511 2006-05-05  Jim Meyering  <jim@meyering.net>
14512
14513         * m4/warning.m4: New file, derived from bison's file by the same name.
14514
14515 2006-05-03  Bruno Haible  <bruno@clisp.org>
14516
14517         * lib/stdint_.h: Shorter URL.
14518         * lib/inttypes.h: Likewise.
14519
14520 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14521
14522         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
14523
14524 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14525
14526         * lib/verify.h: Document the internals better.  Most of this change
14527         was written by Bruno Haible.
14528
14529 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14530
14531         * doc/verify.texi: New file, partly based on a proposal by
14532         Bruno Haible.
14533
14534 2006-05-02  Bruno Haible  <bruno@clisp.org>
14535
14536         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
14537         test from here...
14538         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
14539
14540 2006-04-29  Bruno Haible  <bruno@clisp.org>
14541
14542         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
14543         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
14544
14545 2006-04-29  Bruno Haible  <bruno@clisp.org>
14546
14547         * gnulib-tool: Make --update option actually work.
14548
14549 2006-04-29  Bruno Haible  <bruno@clisp.org>
14550
14551         * doc/gcd.texi: New file.
14552         * doc/gnulib.texi: Include it.
14553
14554 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
14555
14556         * lib/getdate.y (get_date): When adding relative date, start with the
14557         initial time, not with the result of the first mktime call.
14558
14559 2006-04-25  Bruno Haible  <bruno@clisp.org>
14560
14561         * gnulib-tool (func_import): Output the include directives in three
14562         blocks, sorted separately.
14563         Reported by Ben Pfaff <blp@cs.stanford.edu>.
14564
14565 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
14566
14567         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
14568         to define main with arguments, for C++.  Reported by Eric Blake.
14569         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
14570         Prefer 'int main ()' to 'int main (void)', for C++.
14571         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
14572         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
14573         for 'main', for C99 and C++.
14574
14575 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
14576
14577         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
14578         Don't assume that exit status -1 is valid.
14579         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
14580         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
14581         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
14582         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
14583         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
14584         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
14585         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
14586         functions can be used without declaring them, or that you can
14587         exit with status -1.
14588         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
14589
14590 2006-04-24  Karl Berry  <karl@gnu.org>
14591
14592         * config/srclist.txt (longdouble.m4): sync lost.
14593
14594 2006-04-24  Eric Blake  <ebb9@byu.net>
14595
14596         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
14597
14598 2006-04-24  Bruno Haible  <bruno@clisp.org>
14599
14600         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
14601         poll() implementation in AIX.
14602         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14603
14604 2006-04-24  Bruno Haible  <bruno@clisp.org>
14605
14606         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
14607         assigned exactly once.
14608
14609 2006-04-23  Claudio Fontana  <claudio@gnu.org>
14610             Bruno Haible  <bruno@clisp.org>
14611
14612         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
14613         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
14614         for AM_CPPFLAGS.
14615
14616 2006-04-23  Bruno Haible  <bruno@clisp.org>
14617
14618         * modules/copy-file: Depend on unistd.
14619         * modules/execute: Likewise.
14620         * modules/fatal-signal: Likewise.
14621         * modules/findprog: Likewise.
14622         * modules/mkdtemp : Likewise.
14623         * modules/pipe: Likewise.
14624         * modules/wait-process: Likewise.
14625
14626 2006-04-23  Bruno Haible  <bruno@clisp.org>
14627
14628         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
14629         condition was already detected.
14630         Reported by Ben Pfaff <blp@cs.stanford.edu>.
14631
14632 2006-04-23  Bruno Haible  <bruno@clisp.org>
14633
14634         * lib/copy-file.c: Include <unistd.h> unconditionally.
14635         * lib/execute.c: Likewise.
14636         * lib/fatal-signal.c: Likewise.
14637         * lib/findprog.c: Likewise.
14638         * lib/mkdtemp.c: Likewise.
14639         * lib/pipe.h: Likewise.
14640         * lib/pipe.c: Likewise.
14641         * lib/wait-process.h: Likewise.
14642
14643 2006-04-23  Bruno Haible  <bruno@clisp.org>
14644
14645         * gnulib-tool (func_usage): Fix --import description. Document
14646         --update.
14647         (func_import): Create temporary file in a temporary directory, if
14648         --dry-run is specified. Silence errors from 'grep' when there are no
14649         m4 files in $m4dir.
14650         (func_create_testdir): Silence errors from 'grep' when there are no
14651         m4 files in $m4dir.
14652         Reported by Karl Berry <karl@freefriends.org>.
14653
14654 2006-04-20  Bruno Haible  <bruno@clisp.org>
14655
14656         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
14657         one argument, so that the code will be portable to Autoconf 2.60.
14658         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
14659         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
14660         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
14661
14662 2006-04-19  Derek Price  <derek@ximbiot.com>
14663             Eric Blake  <ebb9@byu.net>
14664
14665         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
14666         rather than "/full/path.h".  Update comment to match.  Shorten &
14667         generalize m4_translit call via AS_TR_CPP.
14668
14669 2006-04-19  Derek Price  <derek@ximbiot.com>
14670             Eric Blake  <ebb9@byu.net>
14671
14672         * lib/inttypes.h: Correct grammar in comment.
14673
14674 2006-04-18  Derek Price  <derek@ximbiot.com>
14675             Paul Eggert  <eggert@cs.ucla.edu>
14676
14677         * modules/inttypes: New file.
14678         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
14679
14680 2006-04-18  Derek Price  <derek@ximbiot.com>
14681             Paul Eggert  <eggert@cs.ucla.edu>
14682
14683         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
14684         New files.
14685
14686 2006-04-18  Derek Price  <derek@ximbiot.com>
14687             Paul Eggert  <eggert@cs.ucla.edu>
14688
14689         * lib/inttypes.h: New file.
14690         * lib/strtoimax.c: Assume <inttypes.h>.
14691
14692 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
14693
14694         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
14695         isn't mounted.  Problem reported by Kir Kolyshkin.
14696
14697 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
14698
14699         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
14700         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
14701         Derek R. Price.
14702         * lib/regex.h (RE_DUP_MAX): Update comment to match current
14703         implementation.
14704
14705 2006-04-12  Eric Blake  <ebb9@byu.net>
14706
14707         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
14708         is now done automatically by the corresponding Autoconf macro.
14709
14710 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
14711
14712         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
14713         time_r.h.
14714
14715 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14716
14717         Merge regex changes from libc, removing some of our
14718         POSIX-conformance changes that were rejected and redoing them in a
14719         less-intrusive way.
14720
14721         * lib/regcomp.c (re_compile_internal, init_dfa):
14722         Length arg is now size_t, not Idx.  All uses changed.
14723         (peek_token): Forward decl now says internal_function.
14724         (__re_error_msgid, __re_error_msgid_idx):
14725         Now static rather than extern with attribute_hidden.
14726         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
14727         For some reason libc prefers K&R style defns for external functions.
14728         (regerror) [!defined _LIBC]: Likewise.
14729         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
14730         (seek_collating_symbol_entry, lookup_collation_sequence_value):
14731         (build_range_exp, build_collating_symbol):
14732         Use K&R-style defn.
14733         (re_compile_fastmap): Use '\0' to memset, not 0.
14734         (utf8_sb_map): Make the calculations more obvious.
14735         (init_dfa, parse_bracket_exp, build_charclass_op):
14736         Call calloc and cast result, as glibc does.
14737         (init_word_char, fetch_token, peek_token, peek_token_bracket):
14738         (build_range_exp, build_collating_symbol):
14739         Now internal functions.
14740
14741         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
14742
14743         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
14744         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
14745         Don't depend on VMS; depend on __VMS instead, for POSIX
14746         namespace cleanness.
14747         (regoff_t): Define to ssize_t, not long int.
14748
14749         Remove the REG_ macros named below.  Instead, make the old names
14750         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
14751         __USE_GNU_REGEX.
14752         (REG_BACKSLASH_ESCAPE_IN_LISTS):
14753         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
14754         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
14755         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
14756         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
14757         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
14758         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
14759         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
14760         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
14761         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
14762         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
14763         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
14764         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
14765         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
14766         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
14767         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
14768         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
14769         (REG_NREGS):
14770         Remove.  All uses replaced by the old RE_* names.
14771         (RE_BACKSLASH_ESCAPE_IN_LISTS):
14772         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
14773         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
14774         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
14775         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
14776         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
14777         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
14778         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
14779         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
14780         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
14781         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
14782         Don't bother having these macros be independent of each others'
14783         values, since they no longer exist in the POSIX name space.
14784
14785         Rename the following member names back to their old names,
14786         unless !__USE_GNU_REGEX.  All uses changed back.
14787         (buffer): Renamed from re_buffer.
14788         (allocated): Renamed from re_allocated.
14789         (used): Renamed from re_used.
14790         (syntax): Renamed from re_syntax.
14791         (fastmap): Renamed from re_fastmap.
14792         (translate): Renamed from re_translate.
14793         (can_be_null): Renamed from re_can_be_null.
14794         (regs_allocated): Renamed from re_regs_allocated.
14795         (fastmap_accurate): Renamed from re_fastmap_accurate.
14796         (no_sub): Renamed from re_no_sub.
14797         (not_bol): Renamed from re_not_bol.
14798         (not_eol): Renamed from re_not_eol.
14799         (newline_anchor): Renamed from re_newline_anchor.
14800         (num_regs): Renamed from rm_num_regs.
14801         (start): Renamed from rm_start.
14802         (end): Renamed from rm_end.
14803
14804         (free_state): Move up a bit.
14805
14806         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
14807         #define to be empty.
14808         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
14809         when that is what is intended.
14810         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
14811         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
14812         (MAX): New macro.
14813         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
14814         All uses changed back to re_malloc, etc.  It's now the caller's
14815         responsibility to check for overflow; all callers changed.
14816         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
14817         (re_x2nrealloc): Remove.
14818         (free_state): Remove decl.
14819
14820         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
14821         (re_set_registers, re_exec):
14822         Use K&R-style defn.
14823
14824         2006-01-31  Roland McGrath  <roland@redhat.com>
14825
14826         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
14827         Reported by Mike Frysinger <vapier@gentoo.org>.
14828
14829         2006-01-15  Andreas Jaeger  <aj@suse.de>
14830
14831         [BZ #1950]
14832         * lib/regex_internal.c (re_string_reconstruct): Adjust for
14833         build_wcs_upper_buffer change.
14834         (build_wcs_upper_buffer): Change return type.
14835
14836         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
14837
14838         * lib/regex_internal.h: Include <stdint.h> if available.
14839
14840         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
14841
14842         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
14843
14844         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
14845
14846         * lib/regcomp.c: Adjust for changed secondary hash function.
14847
14848         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
14849
14850         * lib/regex.h: Pretty printing.
14851         Clean up namespace a bit.
14852
14853         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
14854
14855         * lib/regexec.c (update_cur_sifted_state, check_arrival,
14856         check_arrival_add_next_nodes): Avoid using uninitialized variable.
14857
14858         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
14859                     Ulrich Drepper  <drepper@redhat.com>
14860
14861         [BZ #1302]
14862         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
14863         changed.
14864         (bitset_word_t): Renamed from bitset_word.  All uses changed.
14865
14866         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
14867
14868         [BZ #281]
14869         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
14870         * lib/regcomp.c: Remove unnecessary uses of
14871         unsigned RE_TRANSLATE_TYPE.
14872         * lib/regex_internal.h: Likewise.
14873         * lib/regex_internal.c: Likewise.
14874         * lib/regexec.c: Likewise.
14875         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
14876
14877         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
14878
14879         * lib/regexec.c (find_recover_state): Remove unnecessary
14880         initialization.
14881         (transit_state_bkref): Make DFA a const pointer.
14882         (get_subexp): Likewise.
14883         (check_arrival): Likewise.
14884         (update_cur_sifted_state): Likewise.
14885         (re_search_internal): Likewise.
14886         (prune_impossible_nodes): Likewise.
14887         (acquire_init_state_context): Likewise.
14888         (proceed_next_node): Likewise.
14889         (set_regs): Likewise.
14890         (free_fail_stack_return): Likewise.
14891         (check_arrival_expand_ecl): Mark DFA parameter as const.
14892         (check_arrival_expand_ecl_sub): Likewise.
14893         (check_subexp_limits): Likewise.
14894         (sub_epsilon_src_nodes):  Likewise.
14895         (add_epsilon_src_nodes):  Likewise.
14896         (merge_state_array): Likewise.
14897         (update_regs): Likewise.
14898         (build_trtable): Likewise.
14899         (sift_states_backward): Mark MCTX parameter as const.
14900         (build_sifted_states): Likewise.
14901         (update_cur_sifted_state): Likewise.
14902         (sift_states_mkref): Likewise.
14903         (check_arrival_expand_ecl): Mark eclosure as const.
14904         (check_dst_limits_calc_pos_1): Likewise.
14905         * lib/regex_internal.h (re_match_context_t): Make dfa a const
14906         pointer.
14907
14908         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
14909
14910         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
14911         (transit_state_sb): Likewise.
14912         (transit_state_mb): Likewise.
14913         (sift_states_iter_mb): Likewise.
14914         (check_arrival_add_next_nodes): Likewise.
14915         (check_node_accept_bytes): Change first parameter to pointer-to-const.
14916         [_LIBC] (re_search_2_stub): Use mempcpy.
14917
14918         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
14919         mbrtowc for very simple UTF-8 case.
14920
14921         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
14922         a pointer-to-const.
14923         (re_acquire_state_context): Likewise.
14924         * lib/regex_internal.h: Adjust prototypes.
14925
14926         * lib/regex.c: Prevent using C++ compilers.
14927
14928         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
14929         (re_acquire_state_context): Likewise.
14930
14931 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14932
14933         * modules/regex (Depends-on): Add ssize_t.
14934
14935 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14936
14937         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
14938         translation table.
14939
14940 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14941
14942         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
14943
14944 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
14945             Bruno Haible  <bruno@clisp.org>
14946
14947         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
14948         <sys/types.h> and <inttypes.h>.
14949
14950 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14951
14952         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
14953         `__error_t_defined', so argp.h will not typedef the former.
14954
14955 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
14956
14957         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
14958         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
14959         glibc names.  Even if glibc is changed to conform to POSIX, the
14960         traditional names will be available anyway, since regex depends on
14961         the extensions module.  Also, fix a longstanding typo in the
14962         implementation of Spencer ERE test #75 from grep 2.3.  Problems
14963         reported by Emanuele Giaquinta.  Also, change sense of cached
14964         variable, so that the message makes sense.
14965
14966 2006-03-24  Simon Josefsson  <jas@extundo.com>
14967
14968         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
14969         including some doc fixes.
14970         (base64_encode_alloc): Fix +1 bug on allocation failures.
14971
14972 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14973
14974         * lib/base64.c (base64_encode): Do not read past end of array with
14975         unsanitized input on systems with CHAR_BIT > 8.
14976
14977 2006-03-24  Eric Blake  <ebb9@byu.net>
14978
14979         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
14980
14981 2006-03-22  Karl Berry  <karl@gnu.org>
14982
14983         * config/srclist.txt (*setenv.[ch]): get from coreutils.
14984         * config/srclistvars.sh (COREUTILS): new var.
14985
14986 2006-03-17  Jim Meyering  <jim@meyering.net>
14987
14988         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
14989         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
14990
14991 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
14992
14993         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
14994         no longer needs it.  Instead, check that regoff_t is as least
14995         as wide as ptrdiff_t.
14996
14997         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
14998         so that our regex.h stays compatible with the installed regex.
14999         This is helpful for installers who configure --without-included-regex.
15000         Problem reported by Emanuele Giaquinta.
15001
15002 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
15003
15004         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
15005         Typedef to long int, not to off_, as POSIX will likely change
15006         in that direction.
15007
15008 2006-03-15  Eric Blake  <ebb9@byu.net>
15009
15010         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
15011
15012 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
15013
15014         * lib/argp-help.c (validate_uparams): Fix typo
15015         * lib/argp-parse.c (argp_default_options): Consistently begin help
15016         messages with a lowercase letter.
15017
15018 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
15019
15020         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
15021         overrun buffers and shouldn't be used (much as gets shouldn't be
15022         used).
15023         * lib/time_r.c (asctime_r, ctime_r): Likewise.
15024
15025 2006-03-08  Simon Josefsson  <jas@extundo.com>
15026
15027         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
15028         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15029
15030 2006-03-08  Simon Josefsson  <jas@extundo.com>
15031
15032         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
15033         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15034
15035 2006-03-08  Simon Josefsson  <jas@extundo.com>
15036
15037         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
15038         signal that configure disabled the device.
15039
15040 2006-03-08  Simon Josefsson  <jas@extundo.com>
15041
15042         * build-aux/maint.mk: Fix refresh-po, to handle no translated
15043         languages.
15044
15045 2006-03-07  Simon Josefsson  <jas@extundo.com>
15046
15047         * modules/getopt (Depends-on): Add unistd.
15048
15049         * modules/unistd: New file.
15050
15051 2006-03-07  Simon Josefsson  <jas@extundo.com>
15052
15053         * modules/gc-random: New file.
15054
15055 2006-03-07  Simon Josefsson  <jas@extundo.com>
15056
15057         * m4/unistd_h.m4: New file.
15058
15059 2006-03-07  Simon Josefsson  <jas@extundo.com>
15060
15061         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
15062         test to be side-effect free by storing the result in the cache
15063         variable gl_cv_lib_readline, and moving the assignment of
15064         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
15065         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15066
15067 2006-03-07  Simon Josefsson  <jas@extundo.com>
15068
15069         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
15070         error on missing devices (the functions will return an error).
15071
15072         * m4/gc.m4: Move random stuff to gc-random.m4
15073
15074 2006-03-07  Simon Josefsson  <jas@extundo.com>
15075
15076         * lib/unistd_.h: New file.
15077
15078 2006-03-07  Simon Josefsson  <jas@extundo.com>
15079
15080         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
15081
15082 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
15083
15084         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
15085         Problem reported by Juan Manuel Guerrero.
15086
15087 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
15088
15089         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
15090         the unistd module.
15091         * lib/getlogin_r.c: Likewise.
15092         * lib/getlogin_r.h: Likewise.
15093         * lib/glob.c: Likewise.
15094         * lib/pagealign_alloc.c: Likewise.
15095         * lib/unistd_.h: Remove; no longer needed.
15096
15097 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
15098
15099         * MODULES.html.sh (Support for systems lacking POSIX:2001):
15100         Add unistd.
15101         * modules/c-stack (Depends-on): Add unistd.
15102         * modules/getlogin_r: Likewise.
15103         * modules/glob: Likewise.
15104         * modules/pagealign_alloc: Likewise.
15105         * modules/unistd (Files): Remove lib/unistd_.h.
15106         (EXTRA_DIST): Remove.
15107         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
15108         need unistd_.h.
15109         (MOSTLYCLEANFILES): Remove unistd.h-t.
15110
15111 2006-03-03  Simon Josefsson  <jas@extundo.com>
15112
15113         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
15114
15115 2006-03-03  Simon Josefsson  <jas@extundo.com>
15116
15117         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
15118         libidn and bison.
15119
15120 2006-03-03  Simon Josefsson  <jas@extundo.com>
15121
15122         * build-aux/maint.mk: Add indent target.
15123
15124 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
15125
15126         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
15127         our replacement poll.h in any case, to avoid a differing
15128         declaration from a system header.  Seen on AIX.
15129
15130 2006-03-01  Simon Josefsson  <jas@extundo.com>
15131
15132         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
15133         <kasal@ucw.cz>.
15134
15135 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
15136
15137         * modules/gettime (Depends-on): Add extensions module.
15138         * modules/nanosleep (Depends-on): Likewise.
15139         * modules/settime (Depends-on): Likewise.
15140
15141 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
15142
15143         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
15144         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
15145         pedantically.
15146         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
15147         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
15148
15149         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
15150         not "==".  Reported by Ralf Wildenhues.
15151
15152 2006-03-01  Karl Berry  <karl@gnu.org>
15153
15154         * doc/Copyright/request-*: new files, synced from gnuorg.
15155
15156 2006-03-01  Karl Berry  <karl@gnu.org>
15157
15158         * config/srclist.txt (Copyright/*): new entries.
15159
15160 2006-02-28  Simon Josefsson  <jas@extundo.com>
15161
15162         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
15163
15164 2006-02-27  Simon Josefsson  <jas@extundo.com>
15165
15166         * lib/base64.h: Indent #define's.  From Jim Meyering
15167         <jim@meyering.net>.
15168
15169 2006-02-27  Jim Meyering  <jim@meyering.net>
15170
15171         Revert the change of 2006-02-24, so these files can continue
15172         to be sync'd from gettext.
15173         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
15174         of `config.h'.
15175
15176 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
15177
15178         * modules/intprops: New file.
15179         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
15180         Add intprops.
15181         * modules/getloadavg (Files): Remove lib/intprops.h.
15182         (Depends-on): Add intprops.
15183         * modules/human: Likewise.
15184         * modules/inttostr: Likewise.
15185         * modules/openat: Likewise.
15186         * modules/sig2str: Likewise.
15187         * modules/userspec: Likewise.
15188         * modules/utimecmp: Likewise.
15189         * modules/xnanosleep: Likewise.
15190         * modules/xstrtol: Likewise.
15191
15192 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
15193
15194         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
15195         * modules/lock-tests (TESTS): Use $(EXEEXT).
15196         * modules/tls-tests: Likewise.
15197         * modules/argp-tests: Likewise.
15198         (check_PROGRAMS): New var, replacing...
15199         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
15200
15201 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15202
15203         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
15204         `config.h'.
15205
15206 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
15207
15208         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
15209
15210 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15211
15212         Sync from coreutils.
15213         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
15214         gl_CHDIR_SAFER.
15215
15216 2006-02-22  Jim Meyering  <jim@meyering.net>
15217
15218         Sync from coreutils.
15219         * m4/chdir-safer.m4: New file.
15220
15221 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
15222
15223         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
15224         AT_FDCWD exceeds INT_MAX.
15225         * lib/openat.h (AT_FDCWD): Likewise.
15226
15227 2006-02-17  Eric Blake  <address@hidden>
15228
15229         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
15230
15231 2006-02-16  Simon Josefsson  <jas@extundo.com>
15232
15233         * modules/getaddrinfo (Depends-on): Add sys_socket.
15234
15235 2006-02-15  Simon Josefsson  <jas@extundo.com>
15236
15237         * build-aux/maint.mk: Add dsyntax-check rule.
15238
15239 2006-02-15  Eric Blake  <ebb9@byu.net>
15240
15241         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
15242         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
15243         'present but cannot compile' warnings on cygwin.
15244         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
15245         use ws2tcpip.h if sys/socket.h works.
15246         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
15247         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
15248
15249 2006-02-14  Simon Josefsson  <jas@extundo.com>
15250
15251         * modules/maintainer-makefile (Files): Rename.
15252
15253         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
15254         and (the local) Makefile.cfg to maint-cfg.mk.
15255
15256         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
15257         to the latter.
15258
15259         * modules/maintainer-makefile: New module.
15260
15261         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
15262         severaly stripped to make it possible to build it up from scratch
15263         with reliable tests.
15264
15265         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
15266         fixes to permit overriding the default actions when configure and
15267         makefile are not available.
15268
15269 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
15270
15271         Sync from coreutils.
15272         * modules/lstat (Depends-on): Don't depend on xalloc.
15273         (License): Change from GPL to LGPL, since this is now simply a
15274         replacement for a libc function.
15275
15276 2006-02-14  Jim Meyering  <jim@meyering.net>
15277
15278         Sync from coreutils.
15279
15280         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
15281         failure on deficient systems, and simplify gnulib lgpl dependencies.
15282         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
15283         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
15284
15285         * lib/xalloc-die.c: Remove unused definition of N_.
15286
15287 2006-02-14  Jim Meyering  <jim@meyering.net>
15288
15289         Sync from coreutils.
15290         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
15291         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
15292         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
15293         double-quote uses of that variable, to accommodate the rare case in
15294         which getmntent is available in none of the libraries checked.  This
15295         happens at least on FreeBSD 5.0.
15296
15297 2006-02-13  Simon Josefsson  <jas@extundo.com>
15298
15299         * gnulib-tool (Usage): Fix --import, from
15300         karl@freefriends.org (Karl Berry).
15301
15302 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
15303
15304         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
15305
15306 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
15307
15308         * lib/argp-namefrob.h: Restore changes accidentally lost during the
15309         "autoupdate" on 2005-12-12.
15310
15311 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
15312
15313         * modules/closeout (Depends-on): Remove atexit.
15314
15315 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
15316
15317         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
15318         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
15319
15320 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
15321
15322         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
15323         __EXTENSIONS__ if this causes compilation to fail.  Problem
15324         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
15325         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
15326
15327 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
15328
15329         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
15330         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
15331         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
15332         All uses changed.
15333
15334 2006-01-26  Simon Josefsson  <jas@extundo.com>
15335
15336         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
15337         prototype is visible on mingw32.
15338
15339         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
15340         for mingw32.
15341
15342         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
15343         mingw32).
15344
15345 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
15346
15347         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
15348         attempt to open for write; this always fails, at least on POSIX
15349         hosts.  This reinstates the 2006-01-09 change, which was
15350         inadvertently removed.
15351
15352 2006-01-26  Bruno Haible  <bruno@clisp.org>
15353
15354         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
15355         Reported by Paul Eggert.
15356
15357 2006-01-26  Bruno Haible  <bruno@clisp.org>
15358             Paul Eggert  <eggert@cs.ucla.edu>
15359
15360         * lib/stdbool_.h (_Bool)
15361         [(! (defined __cplusplus || defined __BEOS__)
15362           && !defined __GNUC__
15363           && !(defined __HP_cc || defined __xlc__
15364                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
15365                || defined __sgi))]:
15366         #define to signed char in these cases too; this simplifies
15367         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
15368         etc., separately) and makes it more conservative.
15369
15370 2006-01-25  Simon Josefsson  <jas@extundo.com>
15371
15372         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
15373         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
15374         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
15375
15376 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
15377
15378         * lib/argp-namefrob.h: Bugfix. Remove stray #
15379
15380 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
15381
15382         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
15383         so that we test the test.
15384         Check for yet another HP-UX cc bug involving *bool |= bool.
15385
15386 2006-01-25  Karl Berry  <karl@gnu.org>
15387
15388         * config/srclist.txt (vasnprintf.c): sync lost.
15389
15390 2006-01-25  Jim Meyering  <jim@meyering.net>
15391
15392         Sync from the stable (b5) branch of coreutils:
15393
15394         * lib/fts.c (fts_children): Don't let close() clobber errno from
15395         failed fchdir().
15396
15397         * lib/fts.c (fts_stat): When following a symlink-to-directory,
15398         don't necessarily interpret stat-fails+lstat-succeeds as indicating
15399         a dangling symlink.  That can also happen at least for ELOOP.
15400         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
15401         FYI, this bug predates the inclusion of fts.c in coreutils.
15402
15403         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
15404         in their own block, so pre-c99 compilers don't object.
15405
15406         Avoid the double-free (first in fts_read, second in fts_close) that
15407         would occur when an `active' directory is made inaccessible (e.g.,
15408         via chmod a-x) during a traversal.
15409         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
15410         before returning.  Reproduce this failure by
15411         mkdir -p a/b; cd a; chmod a-x . b
15412         Reported by Stavros Passas.
15413
15414 2006-01-25  Jim Meyering  <jim@meyering.net>
15415
15416         * lib/fileblocks.c: Remove more useless parentheses.
15417         * lib/readutmp.h: Likewise.
15418
15419 2006-01-25  Bruno Haible  <bruno@clisp.org>
15420
15421         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
15422         warnings.
15423         Reported by Paul Eggert.
15424
15425 2006-01-25  Bruno Haible  <bruno@clisp.org>
15426
15427         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
15428         rid of a trap command. For Solaris sh.
15429         Reported by Mark D. Baushke <mdb@gnu.org>.
15430
15431 2006-01-24  Simon Josefsson  <jas@extundo.com>
15432
15433         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
15434         Bruno.
15435
15436 2006-01-24  Karl Berry  <karl@gnu.org>
15437
15438         * config/srclist.txt (argp-namefrob.h): sync lost.
15439
15440 2006-01-24  Jim Meyering  <jim@meyering.net>
15441
15442         * modules/openat (Files): Add lib/intprops.h.
15443         From Mark D. Baushke.
15444
15445 2006-01-24  Jim Meyering  <jim@meyering.net>
15446
15447         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
15448         Reported by Mark D. Baushke.
15449
15450 2006-01-24  Jim Meyering  <jim@meyering.net>
15451
15452         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
15453
15454 2006-01-24  Bruno Haible  <bruno@clisp.org>
15455
15456         * modules/strnlen (Maintainer): Change from glibc to all.
15457
15458 2006-01-24  Bruno Haible  <bruno@clisp.org>
15459
15460         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
15461         Patch by Paul Eggert.
15462
15463 2006-01-24  Bruno Haible  <bruno@clisp.org>
15464
15465         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
15466         already has it.
15467         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
15468         2005-11-26.
15469
15470         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
15471         'signed char' to avoid problems with the built-in _Bool type.
15472         Reported by Paul Eggert on 2005-11-26.
15473
15474 2006-01-24  Bruno Haible  <bruno@clisp.org>
15475
15476         * gnulib-tool (func_import): Avoid constructing complicated sed
15477         expressions inside backquote.
15478         Report and solution by Mark D. Baushke <mdb@gnu.org>.
15479
15480 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
15481
15482         These changes imported from libc.
15483         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
15484         test and two separate function calls.
15485         * lib/strndup.c (__strndup): Add libc_hidden_def.
15486
15487 2006-01-23  Simon Josefsson  <jas@extundo.com>
15488
15489         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
15490         Remove the test_*_SOURCES variable: automake infers it by default.
15491         * modules/tls-tests: Likewise.
15492
15493 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15494
15495         Work around porting bugs reported by Dieter in
15496         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
15497         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
15498         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
15499         Include "getopt.h" first, to check interface.
15500         (getenv): Declare only if defined HAVE_DECL_GETENV &&
15501         !HAVE_DECL_GETENV.
15502         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
15503         (__strndup): Revert to K&R-style function dfns, the glibc style.
15504         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
15505         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
15506         Include strnlen.h first, to get prototype properly.
15507         (strnlen): Renamed from __strnlen.
15508         Remove weak alias.
15509
15510 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15511
15512         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
15513
15514 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15515
15516         * config/srclist.txt: Adjust to reflect glibc reorganization.
15517         This affects only comments.
15518
15519 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
15520
15521          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
15522          Reported by Bruce Korb <bkorb@gnu.org>.
15523
15524 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
15525
15526         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
15527         to pacify gcc -Wswitch-default.
15528
15529 2006-01-22  Bruno Haible  <bruno@clisp.org>
15530
15531         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
15532         temporary buffer for sprintf, take into account the precision also
15533         for 'd', 'i', 'u', 'o', 'x', 'X'.
15534
15535 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
15536
15537         * modules/argp-tests: New module
15538         * tests/test-argp.c: New file
15539         * tests/test-argp-2.sh: New file
15540
15541 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
15542
15543         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
15544         (__argp_base_name): Removed
15545         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
15546         typo.
15547         (__argp_base_name): Provide macro definition or extern declaration
15548         depending on the configuration
15549
15550 2006-01-20  Simon Josefsson  <jas@extundo.com>
15551
15552         * modules/inet_ntop (Depends-on): Depend on sys_socket.
15553
15554 2006-01-20  Simon Josefsson  <jas@extundo.com>
15555
15556         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
15557
15558 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
15559
15560         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
15561         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
15562         Suggested by Bruno Haible.
15563
15564 2006-01-20  Karl Berry  <karl@gnu.org>
15565
15566         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
15567         until changes propagate, I guess.
15568
15569 2006-01-19  Simon Josefsson  <jas@extundo.com>
15570
15571         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
15572
15573 2006-01-19  Simon Josefsson  <jas@extundo.com>
15574
15575         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
15576
15577 2006-01-19  Simon Josefsson  <jas@extundo.com>
15578
15579         * gnulib-tool: Set check_PROGRAMS.
15580
15581         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
15582         modules/des-tests, modules/gc-arcfour-tests,
15583         modules/gc-arctwo-tests, modules/gc-des-tests,
15584         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
15585         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
15586         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
15587         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
15588         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
15589         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
15590         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
15591         test_*_SOURCES.
15592
15593 2006-01-18  Simon Josefsson  <jas@extundo.com>
15594
15595         * modules/socklen (Depends-on): Depend on sys_socket.
15596
15597 2006-01-18  Simon Josefsson  <jas@extundo.com>
15598
15599         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
15600         modules/des-tests, modules/gc-arcfour-tests,
15601         modules/gc-arctwo-tests, modules/gc-des-tests,
15602         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
15603         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
15604         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
15605         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
15606         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
15607         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
15608         $(EXEEXT) to automake TESTS variable, for mingw32.
15609
15610 2006-01-17  Simon Josefsson  <jas@extundo.com>
15611
15612         * modules/socklen (Include): Need sys/socket.h.
15613
15614 2006-01-17  Bruno Haible  <bruno@clisp.org>
15615
15616         * modules/ssize_t (Include): Add <sys/types.h>.
15617
15618 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
15619
15620         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
15621         it's not portable and it doesn't work with cross-compiles.
15622         Problem reported by Bruno Haible.  Fix missing-$ typo in
15623         'test "gl_cv_ignore_unused_libraries" ...' that prevented
15624         -zignore from being used with Sun's C compiler.
15625
15626 2006-01-12  Simon Josefsson  <jas@extundo.com>
15627
15628         * lib/base64.c: Fix warning, reported by Bruno Haible
15629         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
15630
15631 2006-01-12  Bruno Haible  <bruno@clisp.org>
15632
15633         * modules/ldd: New file.
15634         * build-aux/ldd.sh.in: New file.
15635         * MODULES.html.sh (Support for building libraries and executables): Add
15636         ldd.
15637
15638 2006-01-12  Bruno Haible  <bruno@clisp.org>
15639
15640         * m4/ldd.m4: New file.
15641
15642 2006-01-12  Bruno Haible  <bruno@clisp.org>
15643
15644         * gnulib-tool (func_import, func_create_testdir): Don't go into an
15645         endless loop while replacing $auxdir with build-aux.
15646
15647 2006-01-11  Simon Josefsson  <jas@extundo.com>
15648
15649         * lib/stdint_.h (SIZE_MAX): Add missing (.
15650
15651 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
15652
15653         Sync from coreutils.
15654         * lib/md5.c: Fix commentary typos.
15655         (alignof, UNALIGNED_P): No need for a GCC-specific version.
15656         * lib/md5.h (__attribute__): Remove; unused.
15657         * lib/sha1.c: Fix commentary to match md5 better.
15658         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
15659         so that we don't need to worry about alignment.  All uses changed.
15660         This merges the 2005-10-28 md5 change into sha1.
15661
15662 2006-01-11  Jim Meyering  <jim@meyering.net>
15663
15664         Sync from coreutils.
15665         * lib/md5.c (OP): Fix spacing.
15666
15667 2006-01-11  Bruno Haible  <bruno@clisp.org>
15668
15669         Ensure automatic ordering between gl_LOCK and gl_ARGP.
15670         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
15671         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
15672
15673 2006-01-11  Bruno Haible  <bruno@clisp.org>
15674
15675         Ensure automatic ordering between gl_LOCK and gl_ARGP.
15676         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
15677         the "early" section as well.
15678
15679 2006-01-11  Bruno Haible  <bruno@clisp.org>
15680
15681         Avoid "ar: no archive members specified" error on MacOS X.
15682         * gnulib-tool (func_modules_add_dummy): New function.
15683         (func_import, func_create_testdir): Invoke it.
15684
15685 2006-01-11  Bruno Haible  <bruno@clisp.org>
15686
15687         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
15688         with $auxdir in AC_CONFIG_FILES statements.
15689
15690 2006-01-11  Bruno Haible  <bruno@clisp.org>
15691
15692         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
15693         Initialize also noinst_HEADERS to empty.
15694
15695 2006-01-11  Bruno Haible  <bruno@clisp.org>
15696
15697         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
15698         variables.
15699         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
15700         autoreconf.
15701
15702 2006-01-11  Bruno Haible  <bruno@clisp.org>
15703
15704         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
15705         overridable by the user.
15706         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15707
15708 2006-01-10  Simon Josefsson  <jas@extundo.com>
15709
15710         * modules/sys_socket: New file.
15711
15712 2006-01-10  Simon Josefsson  <jas@extundo.com>
15713
15714         * m4/sys_socket_h.m4: New file.
15715
15716 2006-01-10  Simon Josefsson  <jas@extundo.com>
15717
15718         * lib/socket_.h: New file.
15719
15720 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15721
15722         * modules/readutmp (Maintainer): Add myself.
15723
15724 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15725
15726         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
15727         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
15728         People who are still concerned with buggy memcmp implementations
15729         can invoke gl_FUNC_MEMCMP themselves.
15730
15731 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15732
15733         * lib/regex_internal.h (BITSET_WORD_BITS):
15734         Work around a bug in 64-bit PGC (before version 6.1-2), where the
15735         preprocessor mishandles large unsigned values as if they were signed.
15736         Problem reported by Claudio Fontana in
15737         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
15738
15739 2006-01-10  Jim Meyering  <jim@meyering.net>
15740
15741         Avoid the double-free (first in fts_read, second in fts_close) that
15742         would occur when an `active' directory is made inaccessible (e.g.,
15743         via chmod a-x) during a traversal.
15744         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
15745         before returning.  Reproduce this failure by
15746         mkdir -p a/b; cd a; chmod a-x . b
15747         Reported by Stavros Passas.
15748
15749         Sync from coreutils.
15750         * lib/sha1.c: Tweak grammar in a comment.
15751
15752 2006-01-10  Jim Meyering  <jim@meyering.net>
15753
15754         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
15755         Patch by Joerg Sonnenberger.
15756
15757 2006-01-10  Bruno Haible  <bruno@clisp.org>
15758
15759         * modules/readutmp: Depend on module free.
15760         * modules/strtok_r: Depend on module restrict.
15761
15762 2006-01-10  Bruno Haible  <bruno@clisp.org>
15763
15764         * modules/gettext (configure.ac): Add an invocation of
15765         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
15766
15767 2006-01-10  Bruno Haible  <bruno@clisp.org>
15768
15769         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
15770         Reported by Werner Lemberg <wl@gnu.org>.
15771
15772 2006-01-10  Bruno Haible  <bruno@clisp.org>
15773
15774         * lib/localcharset.c: Update from GNU gettext.
15775
15776 2006-01-10  Bruno Haible  <bruno@clisp.org>
15777
15778         * lib/argp.h (__const): Remove macro. Use const instead.
15779         * lib/argp-fmtstream.h (__const): Likewise.
15780         * lib/glob_.h (__const): Remove macro.
15781         * lib/glob-libc.h: Use const instead of __const.
15782
15783 2006-01-10  Bruno Haible  <bruno@clisp.org>
15784
15785         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
15786         variable.
15787         Needed to avoid an automake error regarding the 'gettext' module.
15788
15789 2006-01-09  Simon Josefsson  <jas@extundo.com>
15790
15791         * modules/inet_ntop (Depends-on): Add restrict.
15792
15793 2006-01-09  Simon Josefsson  <jas@extundo.com>
15794
15795         * modules/gc-rijndael-tests (License): Put under LGPL.
15796
15797         * modules/gc-des-tests (License): Likewise.
15798
15799         * modules/gc-arcfour-tests (License): Likewise.
15800
15801         * modules/gc-arctwo-tests (License): Likewise.
15802
15803         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
15804
15805         * modules/gc-hmac-sha1-tests (Files): Likewise.
15806
15807         * modules/gc-hmac-md5-tests (License): Likewise.
15808
15809         * modules/gc-sha1-tests (License): Likewise.
15810
15811         * modules/gc-md5-tests (License): Likewise.
15812
15813         * modules/gc-md4-tests (License): Likewise.
15814
15815         * modules/gc-md2-tests (License): Likewise.
15816
15817         * modules/gc-tests (License): Likewise.
15818
15819         * modules/des-tests (License): Likewise.
15820
15821         * modules/md4-tests (License): Likewise.
15822
15823         * modules/md2-tests (License): Likewise.
15824
15825 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15826
15827         Sync from coreutils:
15828
15829         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
15830         * modules/lib-ignore: New file.
15831         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
15832         chdir-safer.m4, lchmod.m4.
15833         * modules/openat: Add mkdirat.c, openat-priv.h.
15834
15835 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15836
15837         Sync from coreutils.
15838         * m4/lib-ignore.m4: New file.
15839         * m4/lchmod.m4: New file.
15840
15841 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15842
15843         Sync from coreutils.
15844         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
15845         for write access: POSIX says that must fail.
15846         * lib/fts.c (diropen): Likewise.
15847         * lib/save-cwd.c (save_cwd): Likewise.
15848         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
15849         well, for minor improvements on hosts that lack O_DIRECTORY.
15850         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
15851         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
15852         Fall back on chown if open failed with EACCES.
15853
15854         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
15855         Report an error at compile-time if only a 1-second nominal clock
15856         resolution is found.
15857
15858         * lib/lchmod.h: New file.
15859         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
15860         (make_dir_parents): Use lchown rather than chown, and
15861         lchmod rather than chmod.
15862
15863         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
15864         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
15865         "proc" reported by n0dalus.
15866
15867         * lib/mountlist.c: Include <limits.h>.
15868         (dev_from_mount_options)
15869         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
15870         New function.  It no longer assumes "dev=" has the System V meaning
15871         on Linux (since it doesn't).  It also parses "dev=" more carefully.
15872         (read_file_system_list)
15873         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
15874         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
15875         dev= in that case.
15876
15877         * lib/posixtm.h (PDS_PRE_2000): New macro.
15878         * lib/posixtm.c (year): Arg is now syntax_bits rather than
15879         allow_century.  All usages changed.  Reject dates outside the range
15880         1969-1999 if PDS_PRE_2000 is used.
15881
15882 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
15883
15884         Sync from coreutils.
15885         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
15886         (Time of day items): Mention the possibility of leap seconds.
15887         Problem reported by Dr. David Alan Gilbert.
15888
15889 2006-01-09  Jim Meyering  <jim@meyering.net>
15890
15891         Sync from coreutils.
15892
15893         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
15894
15895         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
15896
15897         * lib/modechange.c (mode_compile): Reject an invalid mode string
15898         that starts with an octal digit.  From Andreas Gruenbacher.
15899
15900         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
15901         and dup to open_safer and dup_safer, respectively.
15902         (openat_permissive): Fix typo in comment.
15903
15904         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
15905         "gettext.h"; either no longer needed or are guaranteed by openat.h.
15906         (_): Remove; no longer needed.
15907         (openat): Renamed from rpl_openat; no need for rpl_openat
15908         since openat.h renames openat for us.
15909         Replace most of the body with a call to openat_permissive,
15910         to avoid duplicate code.
15911         Port to (probably hypothetical) environments were mode_t is
15912         wider than int.
15913         (openat_permissive): Require mode arg, so that we can check
15914         types better.  Put it just after flags.  Change cwd failure
15915         indicator from pointer-to-bool to pointer-to-errno-value.
15916         All callers changed.
15917         Invoke openat_save_fail and/or openat_restore_fail if
15918         cwd_errno is null, so that openat can call us.
15919         (openat_permissive, fdopendir, fstatat, unlinkat):
15920         Simplify errno handling to avoid some duplicate code,
15921         as it's OK to set errno on success.
15922         * lib/openat.h: Revamp code so that function macros depend on
15923         __OPENAT_PREFIX only, not also on AT_FDCWD.
15924         (openat_ro): Remove.  Caller changed to use openat_permissive.
15925         (openat_permissive): Now a macro, if not a function.
15926         (openat_restore_fail, openat_save_fail): Now always functions,
15927         since mkdirat needs them even if __OPENAT_PREFIX is defined.
15928
15929         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
15930         and openat.c.
15931         * lib/mkdirat.c: Include openat-priv.h.
15932         Remove definitions of macros defined therein.
15933         * lib/openat.c: Likewise.
15934
15935         * lib/mkdirat.c (mkdirat): New file and function.
15936         * lib/openat.h (mkdirat): Declare.
15937
15938         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
15939
15940         * lib/openat.h (openat_permissive): Declare.
15941         (openat_ro): Define.
15942
15943         * lib/openat.c (EXPECTED_ERRNO): New macro.
15944         (openat_permissive): New function -- used in remove.c rewrite.
15945         (all functions): Set errno just before returning, only if there
15946         was an actual failure.
15947         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
15948
15949         Emulate openat-family functions using Linux's procfs, if possible.
15950         Idea and some code based on Ulrich Drepper's glibc changes.
15951
15952         * lib/openat.c: (BUILD_PROC_NAME): New macro.
15953         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
15954         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
15955         before falling back on save_cwd and restore_cwd.
15956         (fdopendir, fstatat, unlinkat): Likewise.
15957
15958         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
15959         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
15960
15961         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
15962         as second argument to va_arg.  Otherwise, some versions of gcc
15963         warn that `if this code is reached, the program will abort'.
15964
15965 2006-01-09  Jim Meyering  <jim@meyering.net>
15966
15967         Sync from coreutils.
15968         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
15969         Require openat-priv.h.
15970
15971 2006-01-09  Bruno Haible  <bruno@clisp.org>
15972
15973         * modules/strnlen (Include): Use strnlen.h.
15974
15975 2006-01-09  Bruno Haible  <bruno@clisp.org>
15976
15977         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
15978
15979 2006-01-09  Bruno Haible  <bruno@clisp.org>
15980
15981         * lib/sysexit_.h (EX_OK): New macro.
15982         Suggested by Martin Lambers <marlam@marlam.de>.
15983
15984 2006-01-09  Bruno Haible  <bruno@clisp.org>
15985
15986         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
15987         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
15988
15989 2006-01-09  Bruno Haible  <bruno@clisp.org>
15990
15991         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
15992         numbers.
15993
15994 2006-01-09  Bruno Haible  <bruno@clisp.org>
15995
15996         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
15997         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
15998         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
15999         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
16000
16001 2006-01-09  Bruno Haible  <bruno@clisp.org>
16002
16003         * build-aux/javacomp.sh.in: New file, moved from lib/.
16004         * modules/javacomp-script (Files): Update.
16005         (configure.ac): Add AC_CONFIG_FILES invocation.
16006         (EXTRA_DIST): Remove variable.
16007
16008         * build-aux/javaexec.sh.in: New file, moved from lib/.
16009         * modules/javaexec (Files): Update.
16010         (configure.ac): Add AC_CONFIG_FILES invocation.
16011         (EXTRA_DIST): Remove javaexec.sh.in.
16012
16013         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
16014         * modules/csharpcomp-script (Files): Update.
16015         (configure.ac): Add AC_CONFIG_FILES invocation.
16016         (EXTRA_DIST): Remove variable.
16017
16018         * build-aux/csharpexec.sh.in: New file, moved from lib/.
16019         * modules/csharpexec (Files): Update.
16020         (configure.ac): Add AC_CONFIG_FILES invocation.
16021         (EXTRA_DIST): Remove csharpexec.sh.in.
16022
16023 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
16024
16025         Sync from coreutils.
16026
16027         Add POSIX ACL support
16028         * lib/acl.h (copy_acl, set_acl): Add declarations.
16029         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
16030         systems other than Linux.
16031         (chmod_or_fchmod): New function: use fchmod when possible,
16032         and chmod otherwise.
16033         (file_has_acl): Add a POSIX ACL implementation, with a
16034         Linux-specific subcase.
16035         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
16036         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
16037         acls are unsupported.
16038         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
16039         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
16040         are unsupported.
16041
16042 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
16043
16044         Sync from coreutils.
16045         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
16046
16047 2006-01-07  Bruno Haible  <bruno@clisp.org>
16048
16049         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
16050         gl_EARLY.
16051
16052 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
16053
16054         * lib/strftime.c (tzname): Don't declare if it is already #defined.
16055         Problem reported for Mingw by Mark Junker.
16056
16057 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
16058
16059         * README: Gnulib normally doesn't generate a tarball.
16060
16061 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
16062
16063         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
16064         long int, not int, for nanosecond counts, so that people who are
16065         used to POSIX struct timespec won't be surprised.  Reported by Jim
16066         Meyering.
16067
16068 2005-12-28  Bruno Haible  <bruno@clisp.org>
16069
16070         * build-aux/config.rpath: Update from GNU gettext.
16071
16072 2005-12-16  Jim Meyering  <jim@meyering.net>
16073
16074         * modules/fprintftime: New module.
16075         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
16076
16077 2005-12-16  Jim Meyering  <jim@meyering.net>
16078
16079         * m4/fprintftime.m4: New file.
16080
16081 2005-12-16  Jim Meyering  <jim@meyering.net>
16082
16083         * lib/fprintftime.c, lib/fprintftime.h: New files.
16084
16085 2005-12-15  Simon Josefsson  <jas@extundo.com>
16086
16087         * modules/socklen (configure.ac): Fix M4 macro name, to align with
16088         new m4/socklen.m4.
16089
16090 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
16091
16092         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
16093         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
16094
16095 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
16096
16097         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
16098         * lib/argp-help.c (fill_in_uparams): Check if the constructed
16099         struct uparams is valid. Fall back to the default values if it is
16100         not.
16101
16102 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16103
16104         * modules/argp (Files): Add argp-pin.c
16105         (Depends-on): dirname
16106         (lib_SOURCES): Add argp-pin.c
16107
16108 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16109
16110         * m4/argp.m4:  Check if program_invocation_name and
16111         program_invocation_short_name are declared and define appropriate
16112         macros if they are not.
16113
16114 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16115
16116         * lib/argp-help.c (__argp_base_name): New function
16117         (__argp_short_program_name): Rewrite using __argp_base_name
16118         * lib/argp-namefrob.h: Define program_invocation_name and
16119         program_invocation_short_name if requested
16120         (__argp_base_name): Add prototype
16121         * lib/argp-parse.c (argp_def): Use gettext wrappers
16122         (argp_default_parser): Use __argp_base_name
16123         * lib/argp-pin.c: New file. Defines program_invocation_name and
16124         program_invocation_short_name on systems that lack them.
16125
16126 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
16127
16128         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
16129         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
16130         porting problem reported by Georg Schwarz in
16131         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
16132
16133 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
16134
16135         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
16136         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
16137         porting problem reported by Georg Schwarz in
16138         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
16139
16140 2005-12-05  Bruno Haible  <bruno@clisp.org>
16141
16142         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
16143         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
16144         Reported by Mark Junker <mjscod@gmx.de>.
16145
16146 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
16147
16148         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
16149         Use implementation from Albert Chin, with some
16150         comments/corrections by Stepan Kasal and myself.
16151
16152 2005-12-02  Bruno Haible  <bruno@clisp.org>
16153
16154         * gnulib-tool (func_import): Accept GPLed build tool modules when
16155         --lgpl is given.
16156         * modules/csharpcomp-script: New file.
16157         * modules/csharpcomp: Depend on it.
16158         * modules/javacomp-script: New file.
16159         * modules/javacomp: Depend on it.
16160         Suggested by Simon Josefsson.
16161
16162 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
16163
16164         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
16165         statement, to work around an HP-UX 10.20 compiler bug reported by
16166         Peter O'Gorman.
16167
16168 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
16169
16170         * modules/savedir (Depends-on): Add openat.
16171
16172 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
16173
16174         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
16175         (uintmax_t) [defined uintmax_t]: Do not declare.
16176         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
16177         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
16178         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
16179         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
16180         sake of portability to weird hosts that C allows (though we don't
16181         know of any practical examples).
16182
16183         * lib/savedir.h (fdsavedir): New decl.
16184         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
16185         contains most of the former guts of savedir.
16186         (savedir): Use savedirstream.
16187         Include "openat.h".
16188
16189 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
16190
16191         * modules/obstack (Files): Add m4/ulonglong.m4.
16192         Problem reported by Davide Angelocola.
16193
16194 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
16195
16196         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
16197         coreutils no longer futzes with rounding modes.
16198
16199 2005-11-14  Jim Meyering  <jim@meyering.net>
16200
16201         * lib/mkstemp-safer.c: Include <config.h>, required for possible
16202         replacement of mkstemp.
16203
16204 2005-11-10  Simon Josefsson  <jas@extundo.com>
16205
16206         * lib/readline.c: Remove EOL.
16207
16208 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
16209
16210         * modules/gethrxtime (Depends-on): Add gettime.
16211
16212 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
16213
16214         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
16215         or gettimeofday; no longer needed.
16216
16217 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
16218
16219         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
16220         time business.
16221         (gethrxtime) [! (HAVE_NANOUPTIME
16222         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
16223         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
16224         our own approximation.
16225
16226 2005-11-08  Eric Blake  <ebb9@byu.net>
16227
16228         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
16229
16230 2005-11-08  Eric Blake  <ebb9@byu.net>
16231
16232         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
16233
16234 2005-11-04  Bruno Haible  <bruno@clisp.org>
16235
16236         * gnulib-tool: Implement --update mode.
16237
16238 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16239
16240         Fix porting problem reported by Theodoros V. Kalamatianos.
16241         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
16242         Don't assume that futimes failing means we must fail.
16243
16244 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16245
16246         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
16247         variables to suggest the intended function of the PATH_MAX check.
16248
16249 2005-10-30  Kean Johnston  <jkj@sco.com>
16250
16251         Trivial changes to support SCO systems.
16252         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
16253         as PATH_MAX.
16254         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
16255         where __ptr is null when no I/O is pending.
16256
16257 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
16258
16259         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
16260         leave errno alone.  Problem reported by Dmitry V. Levin.
16261
16262 2005-10-28  Simon Josefsson  <jas@extundo.com>
16263
16264         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
16265         Test more.
16266
16267         * tests/test-gc-md2.c, tests/test-md2.c: New files.
16268
16269         * modules/md2, modules/md2-tests: New files.
16270
16271 2005-10-28  Simon Josefsson  <jas@extundo.com>
16272
16273         * m4/inet_ntop.m4: More tests.
16274
16275         * m4/gc-md2.m4, md2.m4: New file.
16276
16277 2005-10-28  Simon Josefsson  <jas@extundo.com>
16278
16279         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
16280         "restrict" keywords, as per POSIX.  Protect the function
16281         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
16282         Don't use K&R prototypes.  Check the sprintf return values.
16283         Re-define EAFNOSUPPORT if not present.  Indent.
16284
16285         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
16286         suggested by Bruno Haible <bruno@clisp.org>.
16287
16288         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
16289
16290         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
16291
16292         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
16293         libgcrypt).
16294
16295         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
16296
16297         * lib/md2.h, lib/md2.c: New files.
16298
16299 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
16300
16301         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
16302         errno alone.  Problem reported by Frederic Jolliton.
16303
16304 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
16305
16306         * modules/verify (License): Change from GPL to LGPL.  This is a
16307         tiny module and there are apparently near-equivalents that are
16308         under the BSD license.
16309
16310 2005-10-24  Simon Josefsson  <jas@extundo.com>
16311
16312         * modules/sha1: Relicense to LGPL.
16313
16314 2005-10-24  Simon Josefsson  <jas@extundo.com>
16315
16316         * lib/md4.h: Shrink buffer size, now that we changed the type.
16317
16318 2005-10-23  Simon Josefsson  <jas@extundo.com>
16319
16320         * gnulib-tool (func_import): Fix --tests-base.
16321
16322 2005-10-22  Simon Josefsson  <jas@extundo.com>
16323
16324         * modules/arcfour (Depends-on): Need stdint.
16325
16326 2005-10-22  Simon Josefsson  <jas@extundo.com>
16327
16328         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
16329         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
16330
16331 2005-10-22  Simon Josefsson  <jas@extundo.com>
16332
16333         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
16334         suggested by Bruno Haible <bruno@clisp.org>.
16335
16336 2005-10-22  Simon Josefsson  <jas@extundo.com>
16337
16338         * lib/crc.h: Include stddef.h, for size_t.
16339
16340 2005-10-22  Simon Josefsson  <jas@extundo.com>
16341
16342         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
16343         arcfour_context struct (simplify test vector testing in GNU
16344         Shishi).
16345
16346 2005-10-21  Simon Josefsson  <jas@extundo.com>
16347
16348         * modules/des, modules/des-tests: New files.
16349
16350         * modules/gc-des, modules/gc-des-tests: New files.
16351
16352         * tests/test-des.c, tests/test-gc-des.c: New file.
16353
16354 2005-10-21  Simon Josefsson  <jas@extundo.com>
16355
16356         * modules/arctwo, modules/arctwo-tests: New files.
16357
16358         * tests/test-arctwo.c: New file.
16359
16360         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
16361
16362         * tests/test-gc-arctwo.c: New file.
16363
16364 2005-10-21  Simon Josefsson  <jas@extundo.com>
16365
16366         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
16367         Bruno Haible <bruno@clisp.org>.
16368
16369         * m4/gc-des.m4: New file.
16370
16371 2005-10-21  Simon Josefsson  <jas@extundo.com>
16372
16373         * m4/arctwo.m4: New file.
16374
16375         * m4/gc-arctwo.m4: New file.
16376
16377 2005-10-21  Simon Josefsson  <jas@extundo.com>
16378
16379         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
16380         block.
16381
16382 2005-10-21  Simon Josefsson  <jas@extundo.com>
16383
16384         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
16385         <bruno@clisp.org>.
16386
16387         * lib/hmac-sha1.c (hmac_sha1): Likewise.
16388
16389         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
16390         Bruno Haible <bruno@clisp.org>.
16391
16392         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
16393         <bruno@clisp.org>.
16394
16395 2005-10-21  Simon Josefsson  <jas@extundo.com>
16396
16397         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
16398
16399 2005-10-21  Simon Josefsson  <jas@extundo.com>
16400
16401         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
16402
16403 2005-10-21  Simon Josefsson  <jas@extundo.com>
16404
16405         * lib/des.h, lib/des.c: New files.
16406
16407         * lib/gc-gnulib.c: Support DES.c
16408
16409 2005-10-21  Simon Josefsson  <jas@extundo.com>
16410
16411         * lib/arctwo.h, lib/arctwo.c: New files.
16412
16413         * lib/gc-gnulib.c: Support ARCTWO.
16414
16415 2005-10-21  Simon Josefsson  <jas@extundo.com>
16416
16417         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
16418         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
16419
16420 2005-10-21  Simon Josefsson  <jas@extundo.com>
16421
16422         * gnulib-tool (func_import, func_create_testdir): Define automake
16423         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
16424         Makefile.am snippet),
16425         suggested by Bruno Haible <bruno@clisp.org>.
16426
16427         * modules/gc (Makefile.am): Use it.
16428
16429 2005-10-21  Bruno Haible  <bruno@clisp.org>
16430
16431         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
16432         patch.
16433
16434 2005-10-19  Simon Josefsson  <jas@extundo.com>
16435
16436         * tests/test-gc-rijndael.c: New file.
16437
16438         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
16439
16440 2005-10-19  Simon Josefsson  <jas@extundo.com>
16441
16442         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
16443         interface too.
16444
16445 2005-10-19  Simon Josefsson  <jas@extundo.com>
16446
16447         * tests/test-gc-arcfour.c: New file.
16448
16449         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
16450
16451 2005-10-19  Simon Josefsson  <jas@extundo.com>
16452
16453         * modules/gc-md4, modules/gc-md4-tests: New file.
16454
16455         * tests/test-gc-md4.c: New file.
16456
16457 2005-10-19  Simon Josefsson  <jas@extundo.com>
16458
16459         * m4/gc-md4.m4: New file.
16460
16461 2005-10-19  Simon Josefsson  <jas@extundo.com>
16462
16463         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
16464         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
16465         <kasal@ucw.cz>.
16466
16467 2005-10-19  Simon Josefsson  <jas@extundo.com>
16468
16469         * m4/gc-arcfour.m4: New file.
16470
16471         * m4/gc-rijndael.m4: New file.
16472
16473 2005-10-19  Simon Josefsson  <jas@extundo.com>
16474
16475         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
16476
16477 2005-10-19  Simon Josefsson  <jas@extundo.com>
16478
16479         * lib/gc-gnulib.c: Support ARCFOUR.
16480
16481 2005-10-19  Simon Josefsson  <jas@extundo.com>
16482
16483         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
16484         support.
16485
16486         * lib/gc.h: Add ECB enum type.
16487
16488         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
16489
16490 2005-10-18  Simon Josefsson  <jas@extundo.com>
16491
16492         * tests/test-md5.c: New file.
16493
16494         * modules/md5-tests: New file.
16495
16496 2005-10-18  Simon Josefsson  <jas@extundo.com>
16497
16498         * tests/test-md4.c: New file.
16499
16500         * modules/md4, modules/md4-tests: New files.
16501
16502 2005-10-18  Simon Josefsson  <jas@extundo.com>
16503
16504         * m4/md4.m4: New file.
16505
16506 2005-10-18  Simon Josefsson  <jas@extundo.com>
16507
16508         * lib/md4.h, lib/md4.c: New files, based on md5.?.
16509
16510 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
16511
16512         * gnulib-tool (func_create_testdir): Omit the second check whether
16513         BUILT_SOURCES in nonempty.
16514
16515 2005-10-17  Simon Josefsson  <jas@extundo.com>
16516
16517         * tests/test-rijndael.c: New file.
16518
16519 2005-10-17  Simon Josefsson  <jas@extundo.com>
16520
16521         * modules/sha1: Depend on stdint instead of md5.
16522
16523         * modules/md5: Depend on stdint, remove uint32_t.
16524
16525 2005-10-17  Simon Josefsson  <jas@extundo.com>
16526
16527         * modules/gc-sha1-tests: New file.
16528
16529         * tests/test-gc-sha1.c: New file.
16530
16531 2005-10-17  Simon Josefsson  <jas@extundo.com>
16532
16533         * m4/md5.m4: Remove call to uint32_t.m4.
16534
16535 2005-10-17  Simon Josefsson  <jas@extundo.com>
16536
16537         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
16538
16539         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
16540         md5.h.
16541
16542         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
16543
16544         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
16545
16546 2005-10-17  Simon Josefsson  <jas@extundo.com>
16547
16548         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
16549
16550 2005-10-17  Simon Josefsson  <jas@extundo.com>
16551
16552         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
16553
16554 2005-10-17  Simon Josefsson  <jas@extundo.com>
16555
16556         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
16557
16558         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
16559
16560 2005-10-17  Bruno Haible  <bruno@clisp.org>
16561
16562         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
16563         that it can also be used in a test.
16564
16565 2005-10-16  Bruno Haible  <bruno@clisp.org>
16566
16567         * gnulib-tool (func_emit_tests_Makefile_am): Also define
16568         TESTS_ENVIRONMENT, so that individual tests can augment it.
16569
16570         * gnulib-tool (func_create_testdir): Use an intermediate target for
16571         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
16572         macros, like $(ALLOCA_H), which cannot be passed through the command
16573         line.
16574
16575 2005-10-15  Simon Josefsson  <jas@extundo.com>
16576
16577         * modules/rijndael-tests: New file.
16578
16579         * modules/rijndael: New file.
16580
16581 2005-10-15  Simon Josefsson  <jas@extundo.com>
16582
16583         * m4/rijndael.m4: New file.
16584
16585 2005-10-15  Simon Josefsson  <jas@extundo.com>
16586
16587         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
16588
16589         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
16590
16591 2005-10-14  Simon Josefsson  <jas@extundo.com>
16592
16593         * tests/test-arcfour.c: New file.
16594
16595         * modules/arcfour, modules/arcfour-tests: New files.
16596
16597 2005-10-14  Simon Josefsson  <jas@extundo.com>
16598
16599         * m4/arcfour.m4: New file.
16600
16601 2005-10-14  Simon Josefsson  <jas@extundo.com>
16602
16603         * lib/arcfour.h, lib/arcfour.c: New files.
16604
16605 2005-10-14  Roland McGrath  <roland@redhat.com>
16606
16607         Import from libc.  [BZ #1331]
16608         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
16609         macro argument.
16610         Reported by Matej Vela <vela@debian.org>.
16611
16612 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
16613
16614         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
16615         include <wchar.h>; no longer needed.
16616
16617 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
16618
16619         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
16620
16621 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
16622         and  Ulrich Drepper  <drepper@redhat.com>
16623
16624         Import from libc.
16625         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
16626         instead of inline stream orientation test and two separate
16627         function calls.  Pay no attention to USE_IN_LIBIO.
16628
16629 2005-10-13  Simon Josefsson  <jas@extundo.com>
16630
16631         * modules/gc-hmac-md5-tests: New file.
16632
16633         * tests/test-gc-hmac-sha1.c: New file.
16634
16635         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
16636
16637         * modules/gc-hmac-md5-tests: New file.
16638
16639         * tests/test-gc-md5.c: New file.
16640
16641         * modules/gc-md5-tests: New file.
16642
16643 2005-10-13  Simon Josefsson  <jas@extundo.com>
16644
16645         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
16646         Move memory allocation outside of loop.
16647
16648 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
16649
16650         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
16651         intermediate directory is in a read-only file system.  Problem
16652         reported by Eric Blake.
16653
16654 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
16655
16656         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
16657
16658 2005-10-12  Simon Josefsson  <jas@extundo.com>
16659
16660         * tests/test-hmac-sha1.c: New file.
16661
16662         * modules/hmac-sha1-tests: New file.
16663
16664         * modules/hmac-sha1: New file.
16665
16666 2005-10-12  Simon Josefsson  <jas@extundo.com>
16667
16668         * modules/gc-sha1: New file.
16669
16670 2005-10-12  Simon Josefsson  <jas@extundo.com>
16671
16672         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
16673
16674         * tests/test-gc-pbkdf2-sha1.c: New file.
16675
16676 2005-10-12  Simon Josefsson  <jas@extundo.com>
16677
16678         * modules/gc-md5, modules/gc-hmac-md5: New files.
16679
16680         * modules/gc (Files): Remove md5, memxor and hmac files.
16681
16682 2005-10-12  Simon Josefsson  <jas@extundo.com>
16683
16684         * m4/gc-pbkdf2-sha1.m4: New file.
16685
16686         * m4/gc-hmac-sha1.m4: New file.
16687
16688         * m4/gc-sha1: New file.
16689
16690         * m4/hmac-sha1.m4: New file.
16691
16692 2005-10-12  Simon Josefsson  <jas@extundo.com>
16693
16694         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
16695
16696         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
16697
16698 2005-10-12  Simon Josefsson  <jas@extundo.com>
16699
16700         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
16701         suggested by Bruno Haible <bruno@clisp.org>.
16702
16703 2005-10-12  Simon Josefsson  <jas@extundo.com>
16704
16705         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
16706
16707 2005-10-12  Simon Josefsson  <jas@extundo.com>
16708
16709         * lib/gc-pbkdf2-sha1.c: New file.
16710
16711         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
16712
16713 2005-10-12  Simon Josefsson  <jas@extundo.com>
16714
16715         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
16716
16717         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
16718
16719 2005-10-12  Simon Josefsson  <jas@extundo.com>
16720
16721         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
16722         GC_USE_HMAC_MD5, respectively.
16723
16724         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
16725         (gc_md5): Fix typo.
16726
16727         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
16728
16729         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
16730
16731         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
16732
16733 2005-10-12  Bruno Haible  <bruno@clisp.org>
16734
16735         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
16736         Reported by Stepan Kasal <kasal@ucw.cz>.
16737
16738 2005-10-11  Simon Josefsson  <jas@extundo.com>
16739
16740         * tests/test-crc.c: New file.
16741
16742         * modules/crc, modules/crc-tests: New files.
16743
16744 2005-10-11  Simon Josefsson  <jas@extundo.com>
16745
16746         * m4/crc.m4: New file.
16747
16748 2005-10-11  Simon Josefsson  <jas@extundo.com>
16749
16750         * lib/gc.h: Add gc_hash and gc_hash_buffer.
16751
16752         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
16753
16754         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
16755
16756 2005-10-11  Simon Josefsson  <jas@extundo.com>
16757
16758         * lib/crc.h, lib/crc.c: New files.
16759
16760         * lib/gc.h (gc_hash_buffer): Add doc.
16761
16762 2005-10-11  Bruno Haible  <bruno@clisp.org>
16763
16764         * modules/c-strcasestr: New file.
16765         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
16766
16767 2005-10-11  Bruno Haible  <bruno@clisp.org>
16768
16769         * modules/c-strcase: New file.
16770         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
16771
16772 2005-10-11  Bruno Haible  <bruno@clisp.org>
16773
16774         * lib/strcasecmp.c: Include limits.h.
16775         (strcasecmp): Avoid integer overflow on exotic platforms.
16776         * lib/strncasecmp.c: Include limits.h.
16777         (strncasecmp): Avoid integer overflow on exotic platforms.
16778         Reported by Paul Eggert.
16779
16780 2005-10-11  Bruno Haible  <bruno@clisp.org>
16781
16782         * lib/c-strcasestr.h: New file, from GNU gettext.
16783         * lib/c-strcasestr.c: New file, from GNU gettext.
16784
16785 2005-10-11  Bruno Haible  <bruno@clisp.org>
16786
16787         * lib/c-strcase.h: New file, from GNU gettext.
16788         * lib/c-strcasecmp.c: New file, from GNU gettext.
16789         * lib/c-strncasecmp.c: New file, from GNU gettext.
16790
16791 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
16792
16793         * modules/mempcpy (License): GPL -> LGPL.
16794         * modules/strchrnul (License): Likewise.
16795         * modules/sysexits (License): Likewise.
16796
16797 2005-10-08  Simon Josefsson  <jas@extundo.com>
16798
16799         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
16800
16801 2005-10-07  Simon Josefsson  <jas@extundo.com>
16802
16803         * m4/memxor.m4: Remove gl_C_RESTRICT call.
16804
16805 2005-10-06  Simon Josefsson  <jas@extundo.com>
16806
16807         * tests/test-hmac-md5.c: New file.
16808
16809         * modules/hmac-md5-tests: New file.
16810
16811         * modules/hmac-md5: New file.
16812
16813 2005-10-06  Simon Josefsson  <jas@extundo.com>
16814
16815         * m4/hmac-md5.m4: New file.
16816
16817         * m4/memxor.m4: Require gl_C_RESTRICT.
16818
16819 2005-10-06  Simon Josefsson  <jas@extundo.com>
16820
16821         * lib/memxor.c (memxor): Avoid casts and warnings.
16822
16823 2005-10-06  Simon Josefsson  <jas@extundo.com>
16824
16825         * lib/hmac-md5.c: New file.
16826
16827         * lib/hmac.h: New file.
16828
16829 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
16830
16831         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
16832         promotes to int, not unsigned int, to catch the AIX 5.3
16833         compiler bug.
16834
16835 2005-10-05  Simon Josefsson  <jas@extundo.com>
16836
16837         * modules/memxor: New file.
16838
16839         * modules/iconv (Files): Move config.rpath to havelib, it is used
16840         there.
16841
16842         * modules/havelib (Files): Add config.rpath.
16843
16844 2005-10-05  Simon Josefsson  <jas@extundo.com>
16845
16846         * m4/memxor.m4: New file.
16847
16848 2005-10-05  Simon Josefsson  <jas@extundo.com>
16849
16850         * lib/memxor.c (memxor): Fix compiler error.
16851
16852         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
16853         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
16854
16855         * lib/memxor.h, lib/memxor.c: New files.
16856
16857         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
16858         we assume all systems have it, suggested by Jim Meyering
16859         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
16860         any systems lack sys/socket.h; mingw32 is known to lack it, but we
16861         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
16862         same reasons.
16863
16864 2005-10-05  Simon Josefsson  <jas@extundo.com>
16865
16866         * config/srclist.txt: Add glibc bug 1423 for md5.h.
16867
16868 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
16869
16870         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
16871         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
16872         needed, since the source code now assumes these .h files.
16873
16874 2005-10-05  Derek Price  <derek@ximbiot.com>
16875
16876         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
16877
16878 2005-10-05  Bruno Haible  <bruno@clisp.org>
16879
16880         * modules/stdint (License): Change to LGPL.
16881
16882 2005-10-04  Simon Josefsson  <jas@extundo.com>
16883
16884         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
16885         D. Baushke" <mdb@gnu.org>.
16886
16887 2005-10-04  Bruno Haible  <bruno@clisp.org>
16888
16889         * lib/verify.h (verify_true): Provide alternative definition for C++.
16890
16891 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
16892
16893         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
16894         (SSIZE_MAX): New macro, if not already defined.
16895         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
16896         than 2 GiB.
16897
16898 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
16899
16900         Sync from coreutils.
16901         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
16902         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
16903         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
16904         ULLONG_MAX doesn't work with 2.7.2.1.
16905
16906 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
16907
16908         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
16909         From Ben Pfaff.
16910
16911         * modules/exclude (Depends-on): Depend on verify.
16912         * modules/strtoimax (Depends-on): Likewise.
16913         * modules/utimecmp (Depends-on): Likewise.
16914
16915 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
16916
16917         * lib/exclude.c: Include verify.h.
16918         (verify): Remove.  All callers changed to use verify.h's version.
16919         * lib/strtoimax.c: Likewise.
16920         * lib/utimecmp.c: Likewis.e
16921
16922         Sync from coreutils.
16923         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
16924         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
16925         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
16926         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
16927         bother returning ENOSYS if settimeofday or stime fails; just let
16928         them return whatever errno they want to return.
16929         * lib/utimens.c: Include unistd.h, for dup2.
16930         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
16931         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
16932
16933 2005-10-02  Jim Meyering  <jim@meyering.net>
16934
16935         Sync from coreutils.
16936         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
16937         from glibc-2.2.5 that fails for read-only files.
16938
16939 2005-10-02  Jim Meyering  <jim@meyering.net>
16940
16941         Sync from coreutils.
16942         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
16943         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
16944         `#if HAVE_CONFIG_H'.
16945         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
16946         Remove AT_FDCWD test.
16947         Do not consume the fd unless successful.
16948         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
16949         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
16950         block, so that we don't even try to compile it if settimeofday is
16951         available.  This works around a compilation failure on OSF1 V5.1,
16952         due to stime requiring a `long int*' while tv_sec is `int'.
16953
16954 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
16955
16956         Sync from coreutils.
16957         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
16958         against `yes', rather than just testing for nonempty.
16959
16960 2005-10-01  Simon Josefsson  <jas@extundo.com>
16961
16962         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
16963         and Darwin.
16964
16965         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
16966         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
16967         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
16968         freeaddrinfo and gai_strerror are declared by the POSIX headers.
16969         Check if struct addrinfo is declared.
16970
16971 2005-10-01  Simon Josefsson  <jas@extundo.com>
16972
16973         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
16974         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
16975         AI_* and EAI_* definitions.  Protect function declarations.
16976
16977 2005-10-01  Jim Meyering  <jim@meyering.net>
16978
16979         Sync from coreutils.
16980
16981         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
16982         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
16983         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
16984         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
16985         in the inet and nsl libraries.  Required on Solaris 5.7.
16986
16987 2005-10-01  Jim Meyering  <jim@meyering.net>
16988
16989         Sync from coreutils.
16990         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
16991         in the inet and nsl libraries.  Required on Solaris 5.7.
16992
16993 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
16994
16995         * lib/getdelim.c (getdelim): Remove unused variables.
16996
16997 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
16998
16999         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
17000         so that the code works even with ancient cpp.  Portability problem
17001         with GCC 2.7.2.1 reported by Thomas M.Ott.
17002
17003 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
17004
17005         * modules/regex (Depends-on): Add strcase.
17006
17007         * modules/gethostname (Licence): Change from GPL to LGPL, since
17008         gethostname.c is a trivial implementation of a standard library
17009         function.
17010         * modules/poll (License): Change from GPL to LGPL, since it's
17011         derived from LGPL code.
17012
17013 2005-09-27  Jim Meyering  <jim@meyering.net>
17014
17015         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
17016         HAVE_CONFIG_H.
17017
17018         * lib/intprops.h (signed_type_or_expr__): Define.
17019         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
17020         for unsigned types.
17021
17022 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
17023
17024         * lib/verify.h (verify_expr): Remove, replacing with:
17025         (verify_true): New macro that returns true instead of void.
17026         (verify_type__): Remove.
17027         (verify): Use verify_true rather than verify_type__.
17028
17029 2005-09-26  Bruno Haible  <bruno@clisp.org>
17030
17031         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
17032         is necessary.
17033         (lib_SOURCES): Remove mbchar.c.
17034         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
17035         (Files): Add m4/mbrtowc.m4.
17036         * modules/mbiter: Likewise.
17037         * modules/mbuiter: Likewise.
17038
17039 2005-09-26  Bruno Haible  <bruno@clisp.org>
17040
17041         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
17042         compile mbchar.c if they are not both present.
17043         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
17044         * m4/mbiter.m4 (gl_MBITER): Likewise.
17045         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
17046         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
17047         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
17048
17049 2005-09-25  Jim Meyering  <jim@meyering.net>
17050
17051         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
17052         also uses socklen_t.
17053
17054 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
17055
17056         * lib/utimens.c (ENOSYS): Define if not already defined.
17057         (futimens): Support having a null PATH if the file descriptor
17058         is nonnegative.
17059
17060         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
17061         Remove.
17062         (__attribute): Define to empty unless GCC 3.1 or later.
17063         This works around a core dump on OpenBSD 3.4, which has GCC
17064         2.95.3, which dumps core when given __attribute__(()).  It also
17065         simplifies other tests, since we really don't want to bother with
17066         worrying about which ancient version of GCC supported what.
17067         Original problem reported by Yoann Vandoorselaere, with part of
17068         the fix suggested by Derek Price.
17069
17070 2005-09-24  Jim Meyering  <jim@meyering.net>
17071
17072         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
17073         so we can once again use a positive bitfield width of 1 -- now we
17074         don't have to explain why we were using a bitfield width of 2.
17075
17076 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
17077
17078         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
17079         and similarly for the other external symbols.  Problem reported
17080         by James Gallager.
17081
17082         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
17083         bug reported by Jim Meyering.
17084
17085         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
17086         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
17087         not needed, since socklen is a prerequisite module.
17088
17089 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
17090
17091         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
17092         Problem reported by Eric Blake.
17093         (getaddrinfo): Initialize se so that it's not garbage.
17094         Redo internal storage allocation so that it doesn't make unportable
17095         assumptions about alignment.
17096         Fix a memory leak.
17097
17098         * lib/utimens.c (futimens): Use futimesat if available.
17099         Prefer it to futimes since it doesn't have the futimes bug.
17100
17101         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
17102         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
17103         Instead, declare a function that returns a pointer to an array,
17104         and use verify_type__ to declare the size of the array.
17105         Problem and germ of a solution reported by Bruno Haible.
17106         (verify_type__): Use 2, not 1, for bitfield size, to avoid
17107         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
17108
17109 2005-09-23  Jim Meyering  <jim@meyering.net>
17110
17111         Sync from coreutils.
17112         Correct build failure (socklen_t not defined) on at least
17113         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
17114         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
17115
17116 2005-09-23  Jim Meyering  <jim@meyering.net>
17117
17118         * modules/getaddrinfo (Depends-on): Add socklen.
17119
17120 2005-09-23  Bruno Haible  <bruno@clisp.org>
17121
17122         * tests/test-verify.c: New file.
17123
17124 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17125
17126         Sync from coreutils.
17127
17128         * modules/argmatch (Depends-on): Add verify.
17129         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
17130         unistd-safer.
17131         * modules/save-cwd (Depends-on): Likewise.
17132
17133         * modules/openat (Files): Add lib/openat-die.c.
17134         (Depends-on): Remove error, exitfail.
17135         Add dirname.
17136
17137         * modules/verify: New file.
17138         * MODULES.html.sh (Diagnostics <assert.h>): New section,
17139         with "verify" module.
17140
17141 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17142
17143         Sync from coreutils.
17144
17145         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
17146         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
17147         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
17148         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
17149         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
17150         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
17151         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
17152         Don't bother checking for string.h, stdlib.h, unistd.h.
17153         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
17154         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
17155         module's job.
17156         * m4/jm-macros.m4 (gl_MACROS): Likewise.
17157         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
17158
17159         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
17160         (gl_GETDATE): Use it.
17161
17162         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
17163
17164 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17165
17166         Sync from coreutils.
17167
17168         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
17169         stat-time.h.
17170         * lib/argmatch.h: Include verify.h
17171         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
17172         (ARGMATCH_ASSERT): Remove; unused.
17173         * lib/canonicalize.c: Assume STDC_HEADERS.
17174         * lib/exclude.c: Include "strcase.h".
17175         * lib/regex_internal.h [!defined _LIBC]: Likewise.
17176         * lib/getusershell.c: Include stdio--.h rather than stdio.h
17177         and stdio-safer.h.
17178         (getusershell): Call fopen, not fopen_safer.
17179         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
17180         Do not include unistd-safer.h.
17181         (save_cwd): Don't call fd_safer; no longer needed
17182         now that we include fcntl--.h.
17183
17184         * lib/getdate.y (relative_time): New type.
17185         (RELATIVE_TIME_0): New constant.
17186         (parser_control): Use relative_time instead of doing it ourselves.
17187         (%union): Add new relative_time rel member.
17188         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
17189         Now typeless.
17190         (relunit, relunit_snumber): Now of type rel.
17191         (zone, rel, relunit, get_date): Adjust to above changes.
17192
17193         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
17194         Do not include unistd-safer.h.
17195         (getloadavg): Don't call fd_safer; no longer needed
17196         now that we include fcntl--.h.
17197
17198         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
17199         (make_dir_parents): Treat ENOSYS like EEXIST.
17200
17201         Improve quality of diagnostics on restore_cwd failure.
17202         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
17203         (make_dir_parents): Last arg is now int * (for errno), not bool *.
17204         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
17205         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
17206         each time through the loop.  Do not diagnose restore_cwd failure;
17207         that is the caller's job (and perhaps the caller does not care).
17208
17209         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
17210         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
17211         If the file already exists but is not a directory, don't bother
17212         to try to make its parents.
17213         Close potential file descriptor leak if we can't chdir("/") (!).
17214         Don't always return true if chdir($PWD) fails; return true only
17215         if the requested action was done successfully (except for the
17216         chdir($PWD)).
17217         Don't log final directory unless we actually made it.
17218         Refactor to avoid duplicate code to fix up permissions.
17219         Don't attempt to fix up parent permissions if chdir($PWD) fails.
17220
17221         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
17222         to make it a bit faster and (I hope) clearer.
17223         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
17224         Fix bug in formats like %2N.
17225
17226         * lib/verify.h: New file.
17227
17228 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17229
17230         Sync from coreutils.
17231         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
17232
17233 2005-09-22  Jim Meyering  <jim@meyering.net>
17234
17235         Sync from coreutils.
17236
17237         * m4/lstat.m4 (gl_FUNC_LSTAT):
17238         Use AC_LIBSOURCES to require lstat.c and lstat.h.
17239         Remove obsolete comment.
17240         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
17241         * m4/xstrtod.m4: Likewise.
17242
17243         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
17244
17245 2005-09-22  Jim Meyering  <jim@meyering.net>
17246
17247         Sync from coreutils.
17248
17249         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
17250
17251         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
17252         the .tm_year member, since otherwise gcc-4.0 would now warn about
17253         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
17254
17255         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
17256         order to avoid an unsuppressible warning from gcc on 64-bit systems.
17257
17258         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
17259         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
17260         when run in a time zone for which daylight savings time is in effect
17261         for the starting date.
17262
17263         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
17264         stop us from restricting permissions of just-created absolute-named
17265         directories.
17266         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
17267         to restore initial working directory.
17268         * lib/mkdir-p.c (make_dir_parents): New parameter:
17269         different_working_dir, to tell caller if/when we change the working
17270         directory and are unable to return to the initial one.
17271         * lib/mkdir-p.h (make_dir_parents): Update prototype.
17272         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
17273         `return false'.  This fixes a bug introduced on 2004-07-30.
17274
17275         * lib/openat.c (fdopendir): Be sure to close the supplied
17276         file descriptor before returning.  This makes our replacement
17277         implementation a little closer to Solaris's, where fdopendir
17278         ties the file descriptor to the returned DIR* pointer.
17279         * lib/openat.c (unlinkat): New function.
17280         * lib/openat.h (unlinkat): Add prototype.
17281         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
17282         (openat_restore_fail): Rename from openat_restore_die.
17283         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
17284
17285         Provide an alternative to exiting immediately upon save_cwd or
17286         restore_cwd failure.  Now, an application can arrange e.g.,
17287         to perform a longjump in that case.
17288         * lib/openat.c: Include dirname.h.
17289         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
17290         (rpl_openat, fdopendir, fstatat): Call openat_save_die
17291         and openat_restore_die rather than calling error directly.
17292         Don't include "error.h" or "exitfail.h"; they're no longer needed.
17293
17294         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
17295         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
17296         define.
17297
17298         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
17299         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
17300                             int utc, int nanoseconds);
17301         Background:
17302         date should not have to allocate a megabyte of virtual memory to
17303         handle a format argument like +%1048575T.  When implemented with
17304         strftime, it must allocate such a buffer, use strftime to fill it
17305         in, print it, then free it.
17306         With fprintftime, it simply prints everything and exits.
17307         With no need for memory allocation, that's one fewer way to fail.
17308         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
17309         optional field width, not before, so we accept %9:z, not %:9z.
17310         (my_strftime): Be sure to use L_('x') for literals.
17311
17312         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
17313         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
17314         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
17315         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
17316         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
17317         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
17318         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
17319         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
17320         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
17321         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
17322         * lib/xgethostname.c, lib/xreadlink.c:
17323         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
17324
17325         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
17326         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
17327         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
17328         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
17329         and don't include <sys/file.h>).
17330
17331 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
17332
17333         Sync from coreutils.
17334
17335         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
17336         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
17337         [!LDAV_DONE]: Avoid unused variable warning.
17338
17339 2005-09-21  Bruno Haible  <bruno@clisp.org>
17340
17341         * lib/unicodeio.h (unicode_to_mb): New declaration.
17342
17343 2005-09-20  Derek Price  <derek@ximbiot.com>
17344
17345         * lib/getaddrinfo.c: Don't include <netdb.h> included from
17346         getaddrinfo.h.
17347
17348 2005-09-20  Bruno Haible  <bruno@clisp.org>
17349
17350         * gnulib-tool: Remove trailing slashes from the values specified for
17351         --source-base, --m4-base, --tests-base, --aux-dir.
17352         Suggested by Simon Josefsson <jas@extundo.com>.
17353
17354 2005-09-20  Bruno Haible  <bruno@clisp.org>
17355
17356         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
17357         func_modules_to_filelist, func_import, func_create_testdir): Make all
17358         sorting results locale-independent, so that gnulib-cache.m4 doesn't
17359         change when gnulib-tool is invoked in a different locale.
17360
17361 2005-09-19  Simon Josefsson  <jas@extundo.com>
17362
17363         * m4/socklen.m4: Fix typo.
17364
17365 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
17366
17367         Use a consistent style for including <config.h>.
17368         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
17369         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
17370         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
17371         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
17372         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
17373         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
17374         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
17375         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
17376         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
17377         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
17378         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
17379         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
17380         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
17381         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
17382         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
17383         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
17384         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
17385         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
17386         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
17387         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
17388         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
17389         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
17390         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
17391         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
17392         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
17393         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
17394         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
17395         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
17396         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
17397         lib/xstrtoumax.c, lib/yesno.c:
17398         Standardize inclusion of config.h.
17399         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
17400         lib/inttostr.h:  Removed inclusion of config.h from header files.
17401         * lib/inttostr.c:  Adjusted in-tree users.
17402         * lib/timespec.h: Remove superfluous warning to include config.h.
17403         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
17404         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
17405         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
17406         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
17407         config.h with HAVE_CONFIG_H.
17408
17409 2005-09-19  Jim Meyering  <jim@meyering.net>
17410
17411         * modules/pathmax (License): Change to LGPL.
17412
17413 2005-09-19  Derek Price  <derek@ximbiot.com>
17414
17415         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
17416
17417 2005-09-19  Bruno Haible  <bruno@clisp.org>
17418
17419         * gnulib-tool (import): Provide default for --tests-base.
17420
17421 2005-09-19  Bruno Haible  <bruno@clisp.org>
17422
17423         * doc/quote.texi: New file, extracted from gnulib.texi.
17424         * doc/ctime.texi: New file, extracted from gnulib.texi.
17425         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
17426         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
17427         * doc/gnulib.texi: Include them.
17428
17429 2005-09-18  Bruno Haible  <bruno@clisp.org>
17430
17431         Portability fix.
17432         * gnulib-tool (func_readlink): New function.
17433         (func_ln_if_changed): Use it.
17434
17435 2005-09-18  Bruno Haible  <bruno@clisp.org>
17436
17437         * gnulib-tool: Support --with-tests also with --import.
17438         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
17439         (func_import): Use variables $testsbase and $inctests. Emit a
17440         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
17441         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
17442         SUBDIRS += $testsdir.
17443         (func_create_testdir): Update.
17444
17445 2005-09-18  Bruno Haible  <bruno@clisp.org>
17446
17447         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
17448         instead of $dry_run.
17449         (func_cp_if_changed, func_mv_if_changed): Remove functions.
17450         (func_ln_if_changed): Don't handle dry-run here.
17451         (func_import): In dry-run mode, detect more precisely which actions
17452         would be performed, and don't use "...ing" verbs.
17453
17454 2005-09-18  Bruno Haible  <bruno@clisp.org>
17455
17456         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
17457         (func_import): Use join on two temporary files instead of three nested
17458         loops, in order to determine which files are new or old.
17459
17460 2005-09-18  Bruno Haible  <bruno@clisp.org>
17461
17462         * gnulib-tool (func_import): Comment out code that spits out the
17463         new files with --dry-run.
17464
17465 2005-09-18  Bruno Haible  <bruno@clisp.org>
17466
17467         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
17468
17469 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
17470
17471         * lib/stat-time.h: New file.
17472         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
17473         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
17474         in a different way.
17475         (timespec_cmp): New function.
17476         * lib/utimecmp.c: Include stat-time.h.
17477         (SYSCALL_RESOLUTION): Depend on whether various struct stat
17478         members exist, not on the obsolescent ST_MTIM_NSEC.
17479         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
17480
17481 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
17482
17483         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
17484
17485 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
17486
17487         * MODULES.html.sh (File system functions): Add stat-time.
17488         * modules/stat-time: New file.
17489         * modules/timespec (Files): Remove m4/st_mtim.m4; this
17490         is now done in a different way, by the stat-time module.
17491         * modules/utimecmp (Depends-on): Add stat-time.
17492
17493 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
17494
17495         * m4/st_mtim.m4: Remove.  Superseded by...
17496         * m4/stat-time.m4: New file.
17497         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
17498         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
17499
17500 2005-09-15  Derek Price  <derek@ximbiot.com>
17501
17502         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
17503
17504 2005-09-15  Derek Price  <derek@ximbiot.com>
17505
17506         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
17507         * lib/regex_internal.c: Ditto, using this...
17508         (__GNUC_PREREQ): ...new macro.
17509         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
17510         using...
17511         (__GNUC_PREREQ): ...this new macro.
17512
17513         * lib/strstr.h: Include string.h. Define strstr as a macro here.
17514
17515 2005-09-15  Derek Price  <derek@ximbiot.com>
17516             Paul Eggert  <eggert@cs.ucla.edu>
17517
17518         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
17519         changes, consolidating in...
17520         * lib/regex_internal.h: ...this file.
17521
17522 2005-09-13  Jim Meyering  <jim@meyering.net>
17523
17524         * lib/canon-host.c: Filter through gnu indent and reword comments
17525         slightly.
17526         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
17527
17528 2005-09-13  Derek Price  <derek@ximbiot.com>
17529
17530         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
17531         failure.
17532         Reported by Jim Meyering  <jim@meyering.net>.
17533
17534 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
17535
17536         * lib/base64.c: Typo.
17537         (base64_encode): Put b64str in initialized data section.
17538
17539 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
17540
17541         Merge glibc and coreutils changes into gnulib, plus a few
17542         extra fixes.
17543         * lib/md5.c: Use #error rather than a string.
17544         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
17545         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
17546         (__attribute__): Define to empty for non recent-GCC.
17547         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
17548         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
17549         Renamed from their non-__ counterparts, with new macros replacing
17550         them if not _LIBC.  Add __THROW attribute.
17551         (rol): Remove.
17552         (struct md5_ctx): Align buffer if using GCC.
17553         * lib/sha1.h (struct sha1_ctx): Likewise.
17554         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
17555         The old name was backwards.
17556         (NOTSWAP): Remove; not used.
17557         (rol): New macro, moved here from md5.h.
17558         (sha1_process_block): Remove a FIXME that doesn't make sense.
17559
17560 2005-09-12  Derek Price  <derek@ximbiot.com>
17561
17562         Return usable errors from canon-host.
17563         * lib/canon-host.h: New file.
17564         * lib/canon-host.c (canon_host): Wrap...
17565         (canon_host_r): ...this new function, which now relies exclusively on
17566         getaddrinfo.
17567         (ch_strerror): New function.
17568         (last_cherror): New global.
17569         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
17570         interface.
17571         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
17572         void *.
17573         (freeaddrinfo): Free ai->ai_canonname when set.
17574
17575 2005-09-12  Derek Price  <derek@ximbiot.com>
17576
17577         Make canon-host require getaddrinfo.
17578         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
17579         AC_LIBSOURCE canon-host.h.  Call...
17580         (gl_PREREQ_CANON_HOST): ...this new function, which requires
17581         gl_GETADDRINFO.
17582         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
17583
17584 2005-09-12  Derek Price  <derek@ximbiot.com>
17585
17586         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
17587         LGPL.
17588         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
17589
17590 2005-09-12  Derek Price  <derek@ximbiot.com>
17591
17592         * lib/gai_strerror.c: Include config.h when available.  Include
17593         getaddrinfo.h before other headers to test interface.
17594         Reported by Larry Jones <lawrence.jones@ugs.com>.
17595
17596 2005-09-12  Derek Price  <derek@ximbiot.com>
17597             Paul Eggert  <eggert@cs.ucla.edu>
17598
17599         * modules/glob (Files): Add glob-libc.h.
17600
17601 2005-09-12  Derek Price  <derek@ximbiot.com>
17602             Paul Eggert  <eggert@cs.ucla.edu>
17603
17604         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
17605         glob_.h, glob-libc.h.
17606         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
17607
17608 2005-09-12  Derek Price  <derek@ximbiot.com>
17609             Paul Eggert  <eggert@cs.ucla.edu>
17610
17611         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
17612         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
17613         protecting things that should be done only in gnulib contexts.
17614         * lib/glob_.h: New file, containing only the glob things needed for
17615         gnulib.
17616         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
17617         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
17618         (glob, globfree, glob_pattern_p): Now defined simply in terms of
17619         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
17620         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
17621         and to respect the namespace rules better.
17622
17623 2005-09-08  Simon Josefsson  <jas@extundo.com>
17624
17625         * modules/socklen: New file.
17626
17627 2005-09-08  Simon Josefsson  <jas@extundo.com>
17628
17629         * m4/socklen.m4: New file.
17630
17631 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17632
17633         * modules/utimens (Files): Add m4/utimbuf.m4, since
17634         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
17635         Reported by Sergey Poznyakoff.
17636
17637 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17638
17639         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
17640         definitions, since that's the preferred style in glibc.
17641         Fix a minor spacing issue, and update copyright notice to match
17642         glibc's.
17643
17644 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17645
17646         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
17647
17648 2005-09-06  Simon Josefsson  <jas@extundo.com>
17649
17650         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
17651         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
17652
17653 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
17654
17655         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
17656         warning.
17657
17658 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
17659
17660         * config/srclist.txt: Add glibc bug 1302.
17661
17662 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
17663
17664         Change bitset word type from unsigned int to unsigned long int,
17665         as this has better performance on typical 64-bit hosts.
17666         Port bitset code to hosts with unusual word sizes.
17667         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
17668         (build_collating_symbol):
17669         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
17670         argument is a bitset.  This is merely a style issue, but it makes
17671         it clearer that an entire array is expected.
17672         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
17673         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
17674         Port to the case where bitset_word is not the same as unsigned int.
17675         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
17676         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
17677         Likewise.
17678         * lib/regexec.c (check_dst_limits_calc_pos_1,
17679         check_subexp_matching_top):
17680         (build_trtable, group_nodes_into_DFAstates):
17681         Likewise.
17682         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
17683         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
17684         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
17685         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
17686         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
17687         * lib/regcomp.c (optimize_subexps, lower_subexp):
17688         Work even if bitset_word has holes in its bitwise representation.
17689         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
17690         * lib/regexec.c (check_dst_limits_calc_pos_1,
17691         check_subexp_matching_top):
17692         Likewise.
17693         * lib/regex_internal.c (re_string_reconstruct):
17694         Don't assume UCHAR_MAX == 255.
17695         * lib/regex_internal.h (bitset_set_all): Likewise.
17696         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
17697         All uses changed.
17698         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
17699         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
17700         All uses changed.
17701         (BITSET_WORD_MAX): New macro.
17702         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
17703         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
17704         (bitset_empty, bitset_copy):
17705         Prefer sizeof (bitset) to multiplying it out ourselves.
17706         (bitset_not_merge): Remove; unused.
17707         (bitset_contain): Return bool, not unsigned int with one bit on.
17708         All callers changed.
17709         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
17710         alignment than re_node_set; do this by defining a new internal
17711         type struct dests_alloc and using it to allocate memory.
17712
17713 2005-09-05  Bruno Haible  <bruno@clisp.org>
17714
17715         * gnulib-tool (func_import): Fix comparison in handling of symbolic
17716         links.
17717
17718 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
17719
17720         * modules/size_max (Makefile.am): Add size_max.h
17721
17722 2005-09-04  Derek Price  <derek@ximbiot.com>
17723
17724         * gnulib-tool (func_import): Fix reversed $symbolic logic.
17725
17726 2005-09-03  Simon Josefsson  <jas@extundo.com>
17727
17728         * gnulib-tool: Fix typo.
17729
17730 2005-09-03  Simon Josefsson  <jas@extundo.com>
17731
17732         * config/srclist.txt: Add glibc bug 1293.
17733
17734 2005-09-03  Derek Price  <derek@ximbiot.com>
17735
17736         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
17737         From Larry Jones <lawrence.jones@ugs.com>.
17738
17739 2005-09-02  Simon Josefsson  <jas@extundo.com>
17740
17741         * modules/socklen: New file.
17742
17743 2005-09-02  Simon Josefsson  <jas@extundo.com>
17744
17745         * modules/havelib: New module.
17746
17747         * modules/gettext, modules/iconv, modules/lock, modules/readline:
17748         Use havelib.
17749
17750 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
17751
17752         Check for arithmetic overflow when calculating sizes, to prevent
17753         some buffer-overflow issues.  These patches are conservative, in the
17754         sense that when I couldn't determine whether an overflow was possible,
17755         I inserted a run-time check.
17756         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
17757         macros.
17758         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
17759         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
17760         (re_xnrealloc, re_x2nrealloc): New inline functions.
17761         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
17762         parse_bracket_exp):
17763         (build_equiv_class, build_charclass): Check for arithmetic overflow
17764         in size expression calculations.
17765         * lib/regex_internal.c (re_string_realloc_buffers):
17766         (build_wcs_upper_buffer, re_node_set_add_intersect):
17767         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
17768         (re_dfa_add_node, register_state): Likewise.
17769         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
17770         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
17771         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
17772         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
17773
17774 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
17775
17776         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
17777         m4/ulonglong.m4.  Problem reported by Martin Lambers.
17778
17779 2005-09-02  Bruno Haible  <bruno@clisp.org>
17780
17781         Support for lib vs. lib64 distinction on biarch platforms.
17782         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
17783         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
17784         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
17785
17786 2005-09-02  Bruno Haible  <bruno@clisp.org>
17787
17788         * gnulib-tool (import): In the other first-use case, provide defaults
17789         as well.
17790
17791 2005-09-02  Bruno Haible  <bruno@clisp.org>
17792
17793         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
17794         patches not yet found in the latest gettext release.
17795
17796 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
17797
17798         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
17799         to avoid a collision with bits/local_lim.h in glibc.
17800         All uses changed.  Problem reported by Dmitry V. Levin in
17801         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
17802
17803         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
17804         bugs in int versus size_t comparisons.
17805         (re_string_context_at): Fix bug where the code assumed that
17806         Idx is signed.
17807
17808         Use bool where appropriate.
17809         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
17810         All callers changed.
17811         (calc_eclosure_iter): Likewise, for ROOT arg.
17812         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
17813         (build_charclass_op): Likewise, for NON_MATCH arg.
17814         * lib/regex_internal.c (re_string_allocate, re_string_construct):
17815         (re_string_construct_common): Likewise, for ICASE arg.
17816         * lib/regexec.c (re_search_2_stub, re_search_stub):
17817         Likewise, for RET_LEN arg.
17818         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
17819         (set_regs): Likewise, for FL_BACKTRACK arg.
17820         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
17821         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
17822         (calc_eclosure_iter, parse_bracket_exp):
17823         Use bool for internal variables that are booleans.
17824         * lib/regexec.c (re_search_internal, check_matching,
17825         proceed_next_node):
17826         (set_regs, build_sifted_states, sift_states_bkref):
17827         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
17828         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
17829         (find_collation_sequence_value):
17830         Likewise.
17831         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
17832         (re_node_set_compare):
17833         Return bool, not int. All callers changed.
17834         * lib/regexec.c (check_halt_node_context, check_dst_limits):
17835         (build_trtable, check_node_accept): Likewise.
17836         * lib/regex_internal.h: Include stdbool.h.
17837
17838         Fix bugs uncovered when converting to bool.
17839         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
17840         failure instead of charging ahead blindly.
17841         * lib/regex_internal.c (register_state): Likewise.
17842         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
17843         for freeing internal storage.
17844         (group_nodes_into_DFA_states): Use unsigned int, not int, for
17845         bitset pieces used as boolean, to avoid undefined behavior
17846         on hosts that do int overflow checking.
17847
17848 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
17849
17850         * config/srclist.txt: Add glibc bugs 1285-1287.
17851
17852 2005-09-01  Jim Meyering  <jim@meyering.net>
17853
17854         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
17855         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
17856         Require gl_STAT_MACROS, too.
17857
17858 2005-09-01  Bruno Haible  <bruno@clisp.org>
17859
17860         * gnulib-tool (import): In the first-use case, provide defaults.
17861
17862 2005-09-01  Bruno Haible  <bruno@clisp.org>
17863
17864         * gnulib-tool (func_import): Remove the .tmp files.
17865
17866 2005-09-01  Bruno Haible  <bruno@clisp.org>
17867
17868         * gnulib-tool (func_import): Fix handling of symbolic links.
17869
17870 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17871
17872         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
17873         old glibc regex code mishandles strings longer than 2**31 bytes.
17874         This patch fixes this when the regex code is used in gnulib
17875         (i.e., outside glibc).
17876
17877         This patch should not affect the use of the regex code inside
17878         glibc.  No doubt this problem also needs to be handled for glibc
17879         as well, but the result will be an incompatible change to the
17880         glibc ABI, and the old ABI will have to be supported too.  That
17881         can be the the subject for another patch.
17882
17883         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
17884         governing whether the rest of this patch is active.  By default,
17885         the macro is disabled and the patch has no effect.
17886         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
17887         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
17888         (struct re_pattern_buffer, re_search, re_search_2, re_match):
17889         (re_match_2, re_set_registers): Use the new types.
17890         * lib/regex_internal.h (Idx, re_hashval_t): New types.
17891         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
17892         New macros.
17893         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
17894         (re_string_context_at, bin_tree_t, re_dfastate_t):
17895         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
17896         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
17897         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
17898         (re_string_char_size_at, re_string_wchar_at):
17899         (re_string_elem_size_at):
17900         Use the new types and macros to port to 64-bit hosts.
17901         Use unsigned types for internal values, so that the code
17902         mostly works even for arrays larger than SSIZE_MAX.
17903         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
17904         (search_duplicated_node, calc_eclosure_iter, fetch_number):
17905         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
17906         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
17907         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
17908         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
17909         (calc_inveclosure, parse_dup_op, build_range_exp):
17910         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
17911         (fetch_number, create_token_tree, mark_opt_subexp):
17912         Likewise.
17913         * lib/regex_internal.c (re_string_construct_common,
17914         create_ci_newstate):
17915         (create_cd_newstate, re_string_allocate, re_string_construct):
17916         (re_string_realloc_buffers, build_wcs_upper_buffer):
17917         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
17918         (re_string_reconstruct, re_string_peek_byte_case):
17919         (re_string_fetch_byte_case, re_string_context_at):
17920         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
17921         (re_node_set_init_copy, re_node_set_add_intersect):
17922         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
17923         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
17924         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
17925         (re_acquire_state, re_acquire_state_context, register_state):
17926         Likewise.
17927         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
17928         search_cur_bkref_entry):
17929         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
17930         (re_search_internal, re_search_2_stub, re_search_stub)
17931         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
17932         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
17933         (update_cur_sifted_state, check_dst_limits):
17934         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
17935         (check_subexp_limits, sift_states_bkref, merge_state_array):
17936         (check_subexp_matching_top, get_subexp, get_subexp_sub):
17937         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
17938         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
17939         (expand_bkref_cache, check_node_accept_bytes):
17940         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
17941         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
17942         (acquire_init_state_context, check_halt_node_context):
17943         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
17944         (sift_states_backward, clean_state_log_if_needed):
17945         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
17946         (find_recover_state, transit_state_sb, transit_state_mb):
17947         (transit_state_bkref, build_trtable, match_ctx_clean):
17948         Likewise.
17949         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
17950         to work around an assumption that REG_MISSING is negative.
17951
17952         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
17953         (seek_collating_symbol_entry) [defined _LIBC]:
17954         (lookup_collation_sequence_value) [defined _LIBC]:
17955         (build_range_exp, build_collating_symbol) [defined _LIBC]:
17956         Use prototypes rather than old-style function definitions.
17957         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
17958         (transit_state_sb) [0]:
17959         (find_collation_sequence_value) [defined _LIBC]: Likewise.
17960
17961         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
17962         rm_eo.
17963
17964         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
17965         (optimize_subexps, lower_subexp):
17966         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
17967         since the signed shift might overflow.  Use 1u<<31 instead.
17968         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
17969         Likewise.
17970         * lib/regexec.c (check_dst_limits_calc_pos_1,
17971         check_subexp_matching_top): Likewise.
17972
17973         * lib/regcomp.c (optimize_subexps, lower_subexp):
17974         Use CHAR_BIT rather than 8, for clarity.
17975         * lib/regexec.c (check_dst_limits_calc_pos_1):
17976         (check_subexp_matching_top): Likewise.
17977         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
17978         have to worry about portability issues when shifting it left.
17979         Remove no-longer-needed test for table_size > 0.
17980         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
17981         in a word, as the resulting behavior is undefined.
17982         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
17983         in one case, a <= should have been an <, and in another case the
17984         whole test was missing.
17985         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
17986         the standard name CHAR_BIT.
17987         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
17988         this is not true on one's complement and signed-magnitude hosts.
17989
17990         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
17991         next_last_offset.
17992         (struct re_dfa_t): Remove unused member states_alloc.
17993         * lib/regcomp.c (init_dfa): Don't initialize unused members.
17994
17995 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
17996
17997         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
17998         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
17999         and large-file glibc and in 32-bit large-file Solaris.
18000
18001 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
18002
18003         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
18004         lengths fit in regoff_t; this isn't true if regoff_t is the same
18005         width as size_t.
18006         * lib/regex.c (re_search_internal): 5th arg is LAST_START
18007         (= START + RANGE) instead of RANGE.  This avoids overflow
18008         problems when regoff_t is the same width as size_t.
18009         All callers changed.
18010         (re_search_2_stub): Check for overflow when adding the
18011         sizes of the two strings.
18012         (re_search_stub): Check for overflow when adding START
18013         to RANGE; if it occurs, substitute the extreme value.
18014
18015 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
18016
18017         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
18018
18019 2005-08-31  Jim Meyering  <jim@meyering.net>
18020
18021         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
18022         a pointer-to-const.
18023         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
18024         (register_state): Likewise.
18025         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
18026         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
18027         (group_nodes_into_DFAstates): Likewise.
18028
18029 2005-08-31  Jim Meyering  <jim@meyering.net>
18030
18031         * check-module: Add a FIXME comment.
18032
18033 2005-08-31  Eric Blake  <ebb9@byu.net>
18034
18035         * modules/unistd-safer (Files): Add unistd--.h.
18036         * modules/stdio-safer (Files): Add stdio--.h.
18037
18038 2005-08-31  Derek Price  <derek@ximbiot.com>
18039
18040         * lib/getdelim.c (getdelim): Return EOF on EOF.
18041         Reported by Larry Jones <lawrence.jones@ugs.com>.
18042
18043 2005-08-31  Bruno Haible  <bruno@clisp.org>
18044
18045         Avoid unnecessary diffs in the generated lib/Makefile.am.
18046         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
18047         the generated files.
18048         (func_import): Don't set cmd.
18049
18050 2005-08-31  Bruno Haible  <bruno@clisp.org>
18051
18052         * lib/strstr.c: Include <stddef.h>, for NULL.
18053         * lib/strcasestr.c: Likewise.
18054         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
18055
18056 2005-08-31  Bruno Haible  <bruno@clisp.org>
18057
18058         * gnulib-tool: New option --macro-prefix.
18059         (func_import): Use macro_prefix.
18060         (import): Handle option --macro-prefix.
18061
18062 2005-08-31  Bruno Haible  <bruno@clisp.org>
18063
18064         * gnulib-tool (import): Rename most ac_* variables to cached_*.
18065         Also use new variables cached_lgpl, cached_libtool.
18066
18067 2005-08-31  Bruno Haible  <bruno@clisp.org>
18068
18069         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
18070         always instantiating them.
18071
18072 2005-08-31  Bruno Haible  <bruno@clisp.org>
18073
18074         * gnulib-tool (func_import): Read the previous cached settings
18075         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
18076         earlier added by gnulib but are now dropped. Warn when a gnulib file
18077         overwrites a non-gnulib file.
18078
18079 2005-08-31  Bruno Haible  <bruno@clisp.org>
18080
18081         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
18082         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
18083         projects that don't keep autogenerated files in CVS. Put into
18084         actioncmd only the specified modules, not the transitive closure.
18085
18086 2005-08-31  Bruno Haible  <bruno@clisp.org>
18087
18088         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
18089         Create directories that shall be filled.
18090         (import): Don't look for gl_* macros in configure.ac. Recurse across
18091         all directories containing a gnulib-cache.m4 files, if meaningful.
18092
18093 2005-08-31  Bruno Haible  <bruno@clisp.org>
18094
18095         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
18096         (import): Set seen_libtool when we see gl_LIBTOOL.
18097
18098 2005-08-31  Bruno Haible  <bruno@clisp.org>
18099
18100         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
18101         declaration macro definitions from generated gnulib.m4.
18102
18103 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
18104
18105         * lib/iconvme.h: Add prototype for iconv_alloc.
18106
18107 2005-08-29  Simon Josefsson  <jas@extundo.com>
18108
18109         * lib/iconvme.c: Fix errno.
18110
18111 2005-08-29  Bruno Haible  <bruno@clisp.org>
18112
18113         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
18114         that it works when the directory contains spaces.
18115
18116 2005-08-29  Bruno Haible  <bruno@clisp.org>
18117
18118         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
18119
18120 2005-08-29  Bruno Haible  <bruno@clisp.org>
18121
18122         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
18123         Emit more advice.
18124
18125 2005-08-29  Bruno Haible  <bruno@clisp.org>
18126         and Stepan Kasal  <kasal@ucw.cz>
18127
18128         * check-module: If more parameters are given, check each of them
18129         separately; add more exceptions, as noted by Jim Meyering.
18130         (check_module): New procedure.
18131         (%exempt_header): Now contains all exceptions.
18132
18133 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
18134
18135         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
18136
18137 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
18138
18139         * lib/iconvme.c: Split iconv_string into iconv_alloc.
18140
18141 2005-08-28  Bruno Haible  <bruno@clisp.org>
18142
18143         * m4/gnulib-tool.m4: New file.
18144
18145 2005-08-27  Jim Meyering  <jim@meyering.net>
18146
18147         * modules/unistd-safer (Files): Add pipe-safer.c.
18148         * modules/fcntl-safer (Files): Add creat-safer.c.
18149
18150 2005-08-27  Jim Meyering  <jim@meyering.net>
18151
18152         * m4/stdlib-safer.m4: New file.  From coreutils.
18153         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
18154         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
18155         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
18156         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
18157         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
18158
18159 2005-08-27  Jim Meyering  <jim@meyering.net>
18160
18161         * lib/fopen-safer.c: Merge minor changes from coreutils.
18162         * lib/dup-safer.c: Likewise.
18163         * lib/fd-safer.c: Likewise.
18164
18165         Merge from coreutils.
18166         * lib/stdio--.h: New file.
18167         * lib/stdlib--.h: New file.
18168         * lib/mkstemp-safer.c: New file.
18169
18170         GNU tar needs these.
18171         * lib/pipe-safer.c: New file.
18172         * lib/creat-safer.c: New file.
18173         * lib/fcntl--.h (creat): Define to creat_safer.
18174         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
18175         * lib/unistd--.h (pipe): Define to pipe_safer.
18176         * lib/unistd-safer.h: Declare pipe_safer.
18177
18178 2005-08-26  Simon Josefsson  <jas@extundo.com>
18179
18180         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
18181         Haible <bruno@clisp.org>.
18182
18183 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
18184
18185         * lib/regex_internal.h: Remove all references to
18186         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
18187         or better.
18188         (bitset_not, bitset_merge, bitset_not_merge):
18189         (bitset_mask, re_string_allocate, re_string_construct):
18190         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
18191         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
18192         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
18193         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
18194         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
18195         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
18196         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
18197         (re_acquire_state_context):
18198         Remove unnecessary forward decls.
18199         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
18200         Put __attribute at function definition,
18201         now that the function decl has been removed.
18202         * lib/regex_internal.c (re_string_peek_byte_case):
18203         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
18204         Likewise.
18205
18206 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
18207
18208         * m4/regex.m4: Add AC_PREREQ(2.50).
18209         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
18210
18211 2005-08-25  Simon Josefsson  <jas@extundo.com>
18212
18213         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
18214         __fsetlocking.
18215
18216 2005-08-25  Simon Josefsson  <jas@extundo.com>
18217
18218         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
18219         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
18220         GLIBC specific code.
18221
18222 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18223
18224         Make regex safe for g++.  This fixes one real bug (an "err"
18225         that should have been "*err").  g++ problem reported by
18226         Sam Steingold.
18227         * lib/regex_internal.h (re_calloc): New macro, consistent with
18228         re_malloc etc.  All callers of calloc changed to use re_calloc.
18229         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
18230         not int.  All callers changed.
18231         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
18232         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
18233         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
18234         (find_recover_state): Change "err" to "*err"; this fixes what
18235         appears to be a real bug.
18236         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
18237         versus int.
18238
18239 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18240
18241         * modules/regex (Depends-on): Add malloc, since the code
18242         assumes that !malloc(0) means failure.
18243
18244 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18245
18246         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
18247
18248         alloca modernization/simplification for regex.
18249         * lib/regex.c: Remove portability cruft for alloca.  This no longer
18250         needs to be at the start of the file, and can be moved into
18251         regex_internal.h and simplified.
18252         * lib/regex_internal.h: Include <alloca.h>.
18253         (__libc_use_alloca) [!defined _LIBC]: New macro.
18254         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
18255         now works outside glibc.
18256
18257 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18258
18259         * config/srclist.txt: Add glibc bugs 1241, 1245.
18260
18261 2005-08-25  Jim Meyering  <jim@meyering.net>
18262
18263         * lib/open-safer.c: Include <config.h>.
18264         Otherwise, we'd lose LARGEFILE support in any file using
18265         e.g. "fcntl--.h"
18266
18267 2005-08-25  Bruno Haible  <bruno@clisp.org>
18268
18269         * m4/minmax.m4: Require autoconf 2.52.
18270         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
18271         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
18272         alternatives of translit over the alphabet.
18273         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
18274
18275 2005-08-24  Simon Josefsson  <jas@extundo.com>
18276
18277         * tests/test-getpass.c: New file.
18278
18279 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
18280
18281         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
18282         for GNU regex features.
18283
18284 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
18285
18286         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
18287         * lib/regex.h (regerror): Likewise.
18288
18289         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
18290         requires this.  (The code never needed it.)
18291
18292         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
18293         All uses of recently-renamed identifiers changed to use the new,
18294         POSIX-compliant names.  The code will build and run just fine
18295         without these changes, but it's better to eat our own dog food
18296         and use the standard-conforming names.
18297
18298         * lib/regex.h: Fix a multitude of POSIX name space violations.
18299         These changes have an effect only for programs that define
18300         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
18301         do not change anything for programs compiled in the normal way.
18302         Also, there is no effect on the ABI.
18303
18304         (_REGEX_SOURCE): New macro.
18305         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
18306         defined and _GNU_SOURCE is not; this fixes a name space violation.
18307
18308         Rename the following macros to obey POSIX requirements.
18309         The old names are still visible as macros if _REGEX_SOURCE is defined.
18310         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
18311         RE_BACKSLASH_ESCAPE_IN_LISTS.
18312         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
18313         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
18314         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
18315         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
18316         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
18317         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
18318         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
18319         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
18320         (REG_INTERVALS): renamed from RE_INTERVALS.
18321         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
18322         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
18323         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
18324         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
18325         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
18326         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
18327         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
18328         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
18329         RE_UNMATCHED_RIGHT_PAREN_ORD.
18330         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
18331         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
18332         (REG_DEBUG): renamed from RE_DEBUG.
18333         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
18334         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
18335         unusual, since we can't clash with the POSIX REG_ICASE.
18336         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
18337         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
18338         (REG_NO_SUB): renamed from RE_NO_SUB.
18339         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
18340         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
18341         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
18342         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
18343         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
18344         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
18345         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
18346         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
18347         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
18348         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
18349         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
18350         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
18351         RE_SYNTAX_POSIX_MINIMAL_BASIC.
18352         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
18353         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
18354         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
18355         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
18356         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
18357         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
18358         (REG_FIXED): Renamed from REGS_FIXED.
18359         (REG_NREGS): Renamed from RE_NREGS.
18360
18361         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
18362         of other REG_* macros, since POSIX says the user is allowed to
18363         #undef these macros selectively.
18364
18365         (reg_errcode_t): Update comment stating what other tables need
18366         to be consistent.
18367
18368         Rename the following enum values to obey POSIX requirements.
18369         The old names are still visible as macros.
18370         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
18371         is not defined, since GNU is supposed to be a superset of POSIX as
18372         much as possible, and since we want reg_errcode_t to be a signed
18373         type for implementation consistency.
18374         (_REG_NOERROR): Renamed from REG_NOERROR.
18375         (_REG_NOMATCH): Renamed from REG_NOMATCH.
18376         (_REG_BADPAT): Renamed from REG_BADPAT.
18377         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
18378         (_REG_ECTYPE): Renamed from REG_ECTYPE.
18379         (_REG_EESCAPE): Renamed from REG_EESCAPE.
18380         (_REG_ESUBREG): Renamed from REG_ESUBREG.
18381         (_REG_EBRACK): Renamed from REG_EBRACK.
18382         (_REG_EPAREN): Renamed from REG_EPAREN.
18383         (_REG_EBRACE): Renamed from REG_EBRACE.
18384         (_REG_BADBR): Renamed from REG_BADBR.
18385         (_REG_ERANGE): Renamed from REG_ERANGE.
18386         (_REG_ESPACE): Renamed from REG_ESPACE.
18387         (_REG_BADRPT): Renamed from REG_BADRPT.
18388         (_REG_EEND): Renamed from REG_EEND.
18389         (_REG_ESIZE): Renamed from REG_ESIZE.
18390         (_REG_ERPAREN): Renamed from REG_ERPAREN.
18391         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
18392         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
18393         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
18394         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
18395
18396         (_REG_RE_NAME, _REG_RM_NAME): New macros.
18397         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
18398         changed.  But support the old name if the new one is not defined
18399         and if _REGEX_SOURCE.
18400
18401         Change the following member names in struct re_pattern_buffer.
18402         The old names are still supported if !_REGEX_SOURCE.
18403         The new names are always supported, regardless of _REGEX_SOURCE.
18404         (re_buffer): Renamed from buffer.
18405         (re_allocated): Renamed from allocated.
18406         (re_used): Renamed from used.
18407         (re_syntax): Renamed from syntax.
18408         (re_fastmap): Renamed from fastmap.
18409         (re_translate): Renamed from translate.
18410         (re_can_be_null): Renamed from can_be_null.
18411         (re_regs_allocated): Renamed from regs_allocated.
18412         (re_fastmap_accurate): Renamed from fastmap_accurate.
18413         (re_no_sub): Renamed from no_sub.
18414         (re_not_bol): Renamed from not_bol.
18415         (re_not_eol): Renamed from not_eol.
18416         (re_newline_anchor): Renamed from newline_anchor.
18417
18418         Change the following member names in struct re_registers.
18419         The old names are still supported if !_REGEX_SOURCE.
18420         The new names are always supported, regardless of _REGEX_SOURCE.
18421         (rm_num_regs): Renamed from num_regs.
18422         (rm_start): Renamed from start.
18423         (rm_end): Renamed from end.
18424
18425         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
18426         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
18427         Prepend __ to parameter names.
18428
18429         Undo yesterday's changes.
18430
18431 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
18432
18433         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
18434         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
18435         lib/regex.c.
18436
18437 2005-08-24  Jim Meyering  <jim@meyering.net>
18438
18439         Sync from coreutils.
18440         * m4/fcntl-safer.m4: New file.
18441
18442         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
18443         and object files for this module.
18444
18445 2005-08-24  Jim Meyering  <jim@meyering.net>
18446
18447         Sync from coreutils.
18448         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
18449
18450 2005-08-24  Jim Meyering  <jim@meyering.net>
18451
18452         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
18453         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
18454
18455 2005-08-24  Jim Meyering  <jim@meyering.net>
18456
18457         * modules/fcntl-safer: New module.
18458         * modules/fts (Depends-on): Add fcntl-safer.
18459         * MODULES.html.sh (File descriptor based Input/Output):
18460         Add fcntl-safer.
18461
18462 2005-08-24  Bruno Haible  <bruno@clisp.org>
18463
18464         Support for unit test modules.
18465         * modules/README: Mention tests modules.
18466         * modules/TEMPLATE-TESTS: New file.
18467         * gnulib-tool: New options --extract-tests-module, --with-tests and
18468         --tests-base (unused for the moment).
18469         (testsbase, inctests): New variables.
18470         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
18471         (func_verify_module): Exclude TEMPLATE-TESTS.
18472         (func_verify_nontests_module, func_verify_tests_module): New functions.
18473         (func_get_dependencies): Add implicit dependency for tests modules.
18474         (func_get_tests_module): New function.
18475         (func_modules_transitive_closure): When --with-tests was specified,
18476         include the unit tests as well, unless explicitly avoided.
18477         (func_emit_lib_Makefile_am): Ignore the tests modules here.
18478         (func_emit_tests_Makefile_am): New function.
18479         (func_create_testdir): When --with-tests was specified, emit a
18480         tests/ directory.
18481         * MODULES.html.sh (Future developments): Update.
18482
18483 2005-08-24  Bruno Haible  <bruno@clisp.org>
18484
18485         * modules/tls-tests: New file.
18486         * tests/test-tls.c: New file, from GNU gettext.
18487
18488 2005-08-24  Bruno Haible  <bruno@clisp.org>
18489
18490         * modules/lock-tests: New file.
18491         * tests/test-lock.c: New file, from GNU gettext.
18492
18493 2005-08-24  Bruno Haible  <bruno@clisp.org>
18494
18495         * lib/lock.h: Add multiple inclusion guard.
18496         * lib/tls.h: Add multiple inclusion guard.
18497
18498 2005-08-24  Bruno Haible  <bruno@clisp.org>
18499
18500         * gnulib-tool: Add support for the --aux-dir option to
18501         --create-testdir, --create-megatestdir, --test, --megatest.
18502         (func_create_testdir, func_create_megatestdir): Optionally emit a
18503         AC_CONFIG_AUX_DIR directive.
18504         (create-testdir, create-megatestdir, test, megatest): Provide a
18505         default value for $auxdir.
18506
18507 2005-08-24  Bruno Haible  <bruno@clisp.org>
18508
18509         * gnulib-tool (import): Use compound statement instead of subshell
18510         where possible.
18511
18512 2005-08-24  Bruno Haible  <bruno@clisp.org>
18513
18514         * gnulib-tool (import): Change --aux-dir default to "build-aux".
18515
18516 2005-08-24  Bruno Haible  <bruno@clisp.org>
18517
18518         * gnulib-tool (func_version): Update.
18519
18520 2005-08-24  Bruno Haible  <bruno@clisp.org>
18521
18522         * gnulib-tool (func_import, func_create_testdir,
18523         func_create_megatestdir): Quote all autoconf macro arguments.
18524
18525 2005-08-24  Bruno Haible  <bruno@clisp.org>
18526
18527         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
18528         option --force, because --force causes the aclocal.m4 of each
18529         subdirectory to be newer than the corresponding config.h.in.
18530
18531 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18532
18533         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
18534         All contents moved to gl_REGEX.
18535         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
18536         assume that it does.
18537
18538 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18539
18540         * lib/regex.h (REG_NOSYS)
18541         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
18542         Define, since POSIX requires it as of 2001.
18543         (_REG_ENOSYS)
18544         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
18545         New private symbol, used to keep the enum signed in all cases.
18546         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
18547         Youngman in
18548         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
18549
18550         * lib/regex_internal.c (re_string_skip_chars, register_state):
18551         (calc_state_hash):
18552         Remove forward decls; no longer needed now that we use prototypes.
18553         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
18554         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
18555         (clean_state_log_if_needed): Likewise.
18556
18557 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18558
18559         * config/srclist.txt: Add glibc bugs 1231-1233.
18560
18561 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18562
18563         Fix problems reported by Sam Steingold in
18564         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
18565         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
18566         assumed that reg_errcode_t is a signed type, which is not
18567         necessarily true if _XOPEN_SOURCE is not defined.
18568         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
18569         since some compilers warn about it otherwise.
18570
18571 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18572
18573         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
18574         (init_word_char, create_initial_state, duplicate_node_closure):
18575         (fetch_token, peek_token_bracket, build_range_exp):
18576         (build_collating_symbol): Remove forward decls; no longer needed
18577         now that we use prototypes.
18578
18579         * lib/regcomp.c:
18580         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
18581         (re_compile_fastmap_iter, regcomp, regerror, regfree):
18582         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
18583         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
18584         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
18585         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
18586         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
18587         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
18588         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
18589         (build_range_exp, build_collating_symbol, parse_bracket_exp):
18590         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
18591         (build_charclass, build_charclass_op, fetch_number, create_tree):
18592         (create_token_tree, mark_opt_subexp, duplicate_tree):
18593         Use prototypes rather than old-style definitions.
18594
18595         * lib/regex_internal.c:
18596         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
18597         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
18598         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
18599         (re_string_reconstruct, re_string_peek_byte_case):
18600         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
18601         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
18602         (re_node_set_init_copy, re_node_set_add_intersect):
18603         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
18604         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
18605         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
18606         (re_acquire_state, re_acquire_state_context, register_state):
18607         (create_ci_newstate, create_cd_newstate, free_state):
18608         Likewise.
18609         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
18610         re_search_2):
18611         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
18612         (re_search_internal, prune_impossible_nodes):
18613         (acquire_init_state_context, check_matching, static):
18614         (check_halt_node_context, check_halt_state_context, proceed_next_node):
18615         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
18616         (update_regs, sift_states_backward, build_sifted_states):
18617         (clean_state_log_if_needed, merge_state_array):
18618         (update_cur_sifted_state, add_epsilon_src_nodes):
18619         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
18620         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
18621         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
18622         (find_recover_state, check_subexp_matching_top, transit_state_mb):
18623         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
18624         (check_arrival, check_arrival_add_next_nodes):
18625         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
18626         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
18627         (check_node_accept_bytes, check_node_accept, extend_buffers):
18628         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
18629         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
18630         (sift_ctx_init):
18631         Likewise.
18632
18633         * lib/regex_internal.h:
18634         (re_string_allocate, re_string_construct, re_string_reconstruct):
18635         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
18636         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
18637         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
18638         (re_string_context_at, re_string_peek_byte_case):
18639         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
18640         is defined, since we now use prototypes always.
18641
18642         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
18643         C89 or better.  All uses removed.
18644
18645 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18646
18647         * config/srclist.txt: Add glibc bugs 1220-1227.
18648
18649 2005-08-20  Jim Meyering  <jim@meyering.net>
18650
18651         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
18652         of unused local, dfa.
18653
18654 2005-08-20  Bruno Haible  <bruno@clisp.org>
18655
18656         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
18657
18658 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18659
18660         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
18661         (re_node_set_insert_last, re_dfa_add_node):
18662         Rename local variables to avoid GCC shadowing warnings.
18663
18664 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18665
18666         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
18667         [defined lint]: Suppress bogus uninitialized-variable warnings.
18668
18669         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
18670         and let the caller return REG_ESPACE if out of space.  This
18671         removes an uninitialied-variable warning with GCC 4.0.1, and also
18672         avoids taking the address of a local variable.  All callers
18673         changed.
18674
18675 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18676
18677         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
18678         $LIBCSRC/posix/regexec.c.
18679         Add glibc bug 1217 for regcomp.c.
18680
18681 2005-08-19  Jim Meyering  <jim@meyering.net>
18682
18683         * lib/regexec.c (proceed_next_node): Redo local variables to
18684         avoid GCC shadowing warnings.
18685
18686 2005-08-18  Bruno Haible  <bruno@clisp.org>
18687
18688         * lib/strstr.c (strstr): Fix return value in multibyte case.
18689         * lib/strcasestr.c (strcasestr): Likewise.
18690
18691 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
18692
18693         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
18694
18695 2005-08-17  Jim Meyering  <jim@meyering.net>
18696
18697         Make the %s format (seconds since the epoch) work for a negative
18698         number and when used with a zero-padded field width, e.g. %015s.
18699
18700         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
18701         label so that it precedes the code to set `digits'.  Otherwise,
18702         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
18703         print `00-22'.  Now, it prints `-0022', as it should.
18704
18705 2005-08-17  Bruno Haible  <bruno@clisp.org>
18706
18707         * modules/strstr (Files): Add m4/mbrtowc.m4.
18708         (Depends-on): Add mbuiter.
18709
18710 2005-08-17  Bruno Haible  <bruno@clisp.org>
18711
18712         * modules/strcasestr: New file.
18713         * MODULES.html.sh (String handling, based on ANSI C 89): Add
18714         strcasestr.
18715
18716 2005-08-17  Bruno Haible  <bruno@clisp.org>
18717
18718         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
18719
18720 2005-08-17  Bruno Haible  <bruno@clisp.org>
18721
18722         * modules/mbuiter: New file.
18723         * MODULES.html.sh (Extended multibyte and wide character utilities):
18724         Add mbuiter.
18725
18726 2005-08-17  Bruno Haible  <bruno@clisp.org>
18727
18728         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
18729         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
18730
18731 2005-08-17  Bruno Haible  <bruno@clisp.org>
18732
18733         * m4/strcasestr.m4: New file.
18734
18735 2005-08-17  Bruno Haible  <bruno@clisp.org>
18736
18737         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
18738         * lib/strstr.c: Completely rewritten, with multibyte locale support.
18739
18740 2005-08-17  Bruno Haible  <bruno@clisp.org>
18741
18742         * lib/strcasestr.h: New file.
18743         * lib/strcasestr.c: New file.
18744
18745 2005-08-17  Bruno Haible  <bruno@clisp.org>
18746
18747         * lib/strcasecmp.c: Use mbuiter.h.
18748
18749 2005-08-17  Bruno Haible  <bruno@clisp.org>
18750
18751         * lib/mbuiter.h: New file.
18752
18753 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
18754
18755         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
18756         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
18757         and gl_GETOPT are both invoked via different paths (as happens
18758         with GNU tar CVS because it uses both argp and getopt), the former
18759         wins.
18760
18761 2005-08-16  Bruno Haible  <bruno@clisp.org>
18762
18763         * modules/tls: New file.
18764         * MODULES.html.sh (Multithreading): Add tls.
18765
18766 2005-08-16  Bruno Haible  <bruno@clisp.org>
18767
18768         * modules/strnlen1: New file.
18769         * MODULES.html.sh (String handling): Add strnlen1.
18770
18771 2005-08-16  Bruno Haible  <bruno@clisp.org>
18772
18773         * modules/strcase (Files): Add m4/mbrtowc.m4.
18774         (Depends-on): Add strnlen1, mbchar.
18775
18776 2005-08-16  Bruno Haible  <bruno@clisp.org>
18777
18778         * modules/mbiter: New file.
18779         * MODULES.html.sh (Extended multibyte and wide character utilities):
18780         Add mbiter.
18781
18782 2005-08-16  Bruno Haible  <bruno@clisp.org>
18783
18784         * modules/mbfile: New file.
18785         * MODULES.html.sh (Extended multibyte and wide character utilities):
18786         Add mbfile.
18787
18788 2005-08-16  Bruno Haible  <bruno@clisp.org>
18789
18790         * modules/mbchar: New file.
18791         * MODULES.html.sh (Extended multibyte and wide character utilities):
18792         New section.
18793
18794 2005-08-16  Bruno Haible  <bruno@clisp.org>
18795
18796         * m4/tls.m4: New file, from GNU gettext.
18797
18798 2005-08-16  Bruno Haible  <bruno@clisp.org>
18799
18800         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
18801         always.
18802         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
18803
18804 2005-08-16  Bruno Haible  <bruno@clisp.org>
18805
18806         * m4/mbiter.m4: New file.
18807
18808 2005-08-16  Bruno Haible  <bruno@clisp.org>
18809
18810         * m4/mbfile.m4: New file.
18811
18812 2005-08-16  Bruno Haible  <bruno@clisp.org>
18813
18814         * m4/mbchar.m4: New file.
18815
18816 2005-08-16  Bruno Haible  <bruno@clisp.org>
18817
18818         * lib/tls.h: New file, from GNU gettext.
18819         * lib/tls.c: New file, from GNU gettext.
18820
18821 2005-08-16  Bruno Haible  <bruno@clisp.org>
18822
18823         * lib/strnlen1.h: New file.
18824         * lib/strnlen1.c: New file.
18825
18826 2005-08-16  Bruno Haible  <bruno@clisp.org>
18827
18828         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
18829         (mbi_init): Update.
18830         (mbi_avail, mbi_advance): Let the iteration end before the terminating
18831         NUL byte, not after it.
18832
18833 2005-08-16  Bruno Haible  <bruno@clisp.org>
18834
18835         * lib/strcase.h (strcasecmp): Add note in comments.
18836         * lib/strncasecmp.c: Use code from strcasecmp.c.
18837         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
18838         (strcasecmp): Work correctly in multibyte locales.
18839
18840 2005-08-16  Bruno Haible  <bruno@clisp.org>
18841
18842         * lib/mbiter.h: New file.
18843
18844 2005-08-16  Bruno Haible  <bruno@clisp.org>
18845
18846         * lib/mbfile.h: New file.
18847
18848 2005-08-16  Bruno Haible  <bruno@clisp.org>
18849
18850         * lib/mbchar.h: New file.
18851         * lib/mbchar.c: New file.
18852
18853 2005-08-16  Bruno Haible  <bruno@clisp.org>
18854
18855         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
18856         the valid ones. Makes the comparison operations transitive:
18857         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
18858         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
18859
18860 2005-08-15  Simon Josefsson  <jas@extundo.com>
18861
18862         * modules/ssize_t (License): Change to 'unlimited'.
18863
18864         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
18865
18866 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
18867
18868         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
18869         Add comments for each pending glibc patch.
18870
18871 2005-08-15  Bruno Haible  <bruno@clisp.org>
18872
18873         * lib/regex.h (__restrict_arr): Don't define to __restrict if
18874         __cplusplus is defined.
18875
18876 2005-08-14  Jim Meyering  <jim@meyering.net>
18877
18878         Sync from coreutils.
18879
18880         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
18881         Use the hash-table-based cycle-detection code not just when
18882         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
18883         Reported by James Youngman in
18884         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
18885         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
18886         FTS_TIGHT_CYCLE_CHECK.
18887         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
18888         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
18889         once again.
18890         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
18891         * lib/fts.c (fd_safer): Remove decl.
18892         Include fcntl--.h rather than unistd-safer.h
18893         (fts_safe_changedir): Don't call fd_safer; no longer needed
18894         now that we include fcntl--.h.
18895
18896 2005-08-12  Simon Josefsson  <jas@extundo.com>
18897
18898         * modules/getndelim2: Use ssize_t module.
18899         * modules/getnline: Likewise.
18900         * modules/safe-read: Likewise.
18901         * modules/xreadlink: Likewise.
18902
18903         * modules/ssize_t: New file.
18904
18905 2005-08-12  Simon Josefsson  <jas@extundo.com>
18906
18907         * m4/readline.m4: Look for termcap, curses or ncurses if required.
18908
18909 2005-08-12  Simon Josefsson  <jas@extundo.com>
18910
18911         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18912         ssize_t.
18913
18914 2005-08-12  Simon Josefsson  <jas@extundo.com>
18915
18916         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
18917         readline, getdelim and check_version.
18918         (Support for systems lacking ISO C 99: Sizes of integer types):
18919         Add size_max.
18920
18921 2005-08-12  Bruno Haible  <bruno@clisp.org>
18922
18923         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
18924
18925 2005-08-11  Simon Josefsson  <jas@extundo.com>
18926
18927         * modules/readline: New file.
18928
18929         * modules/strnlen (Files): Add strnlen.h.
18930
18931 2005-08-11  Simon Josefsson  <jas@extundo.com>
18932
18933         * m4/readline.m4: New file.
18934
18935 2005-08-11  Simon Josefsson  <jas@extundo.com>
18936
18937         * lib/readline.h, readline.c: New file.
18938
18939 2005-08-11  Simon Josefsson  <jas@extundo.com>
18940
18941         * doc/gnulib.texi (Initial import, Finishing touches): Mention
18942         gl_AVOID.
18943
18944 2005-08-11  Bruno Haible  <bruno@clisp.org>
18945
18946         * lib/strnlen.h (strnlen): Change parameter name to match comment.
18947
18948 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
18949
18950         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
18951
18952 2005-08-10  Simon Josefsson  <jas@extundo.com>
18953
18954         * tests/test-iconvme.c: New file.
18955
18956 2005-08-10  Simon Josefsson  <jas@extundo.com>
18957
18958         * m4/strnlen.m4: New file.
18959
18960         * m4/strndup.m4: Don't check for strnlen declaration, done in
18961         strnlen.m4.
18962
18963 2005-08-10  Simon Josefsson  <jas@extundo.com>
18964
18965         * lib/strndup.c: Use strnlen.h.
18966
18967         * lib/strnlen.h: New file.
18968
18969 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
18970
18971         * README: Typos.
18972
18973 2005-08-02  Simon Josefsson  <jas@extundo.com>
18974
18975         * modules/readline: New file.
18976
18977 2005-08-02  Simon Josefsson  <jas@extundo.com>
18978
18979         * modules/getdelim: New file.
18980
18981         * modules/getline: Rewrite, don't use getndelim2.
18982
18983 2005-08-02  Simon Josefsson  <jas@extundo.com>
18984
18985         * m4/getline.m4: Separate out getdelim stuff into separate module.
18986
18987         * m4/getdelim.m4: New file.
18988
18989 2005-08-02  Simon Josefsson  <jas@extundo.com>
18990
18991         * lib/getline.h, getline.c: Rewrite.
18992
18993         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
18994
18995 2005-07-31  Bruno Haible  <bruno@clisp.org>
18996
18997         * lib/lock.h (gl_lock_initializer): New macro.
18998         (gl_lock_define_initialized): Use it.
18999         (gl_rwlock_initializer): New macro.
19000         (gl_rwlock_define_initialized): Use it.
19001         (gl_recursive_lock_initializer): New macro.
19002         (gl_recursive_lock_define_initialized): Use it.
19003
19004 2005-07-30  Karl Berry  <karl@gnu.org>
19005
19006         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
19007         Report from Ben Pfaff, regarding getopt.
19008
19009 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
19010
19011         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
19012         normal way.
19013         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
19014         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
19015         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
19016         (gl_GETOPT): Use the new macros.  Most of the implementation
19017         is moved to the new macros.  This is for programs like Emacs
19018         that don't want all the functionality of gl_GETOPT.
19019
19020 2005-07-26  Bruno Haible  <bruno@clisp.org>
19021
19022         * m4/lock.m4: Update from GNU gettext.
19023
19024 2005-07-26  Bruno Haible  <bruno@clisp.org>
19025
19026         * lib/lock.h: Update from GNU gettext.
19027         * lib/lock.c: Update from GNU gettext.
19028
19029 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
19030
19031         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
19032         obsolescent AC_TRY_RUN.  Include the default includes files, for
19033         'exit'.
19034
19035 2005-07-24  Bruno Haible  <bruno@clisp.org>
19036
19037         * modules/visibility: New file.
19038         * MODULES.html.sh (Misc): Add visibility.
19039
19040 2005-07-24  Bruno Haible  <bruno@clisp.org>
19041
19042         * m4/visibility.m4: New file.
19043
19044 2005-07-24  Bruno Haible  <bruno@clisp.org>
19045
19046         * doc/visibility.texi: New file.
19047
19048 2005-07-22  Bruno Haible  <bruno@clisp.org>
19049
19050         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
19051         $(ALLOCA_H), redundant through BUILT_SOURCES.
19052         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
19053         redundant through BUILT_SOURCES.
19054         * modules/byteswap (Makefile.am): Remove explicit dependency on
19055         $(BYTESWAP_H), redundant through BUILT_SOURCES.
19056         * modules/fnmatch (Makefile.am): Remove explicit dependency on
19057         $(FNMATCH_H), redundant through BUILT_SOURCES.
19058         * modules/getopt (Makefile.am): Remove explicit dependency on
19059         $(GETOPT_H), redundant through BUILT_SOURCES.
19060         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
19061         redundant through BUILT_SOURCES.
19062         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
19063         redundant through BUILT_SOURCES.
19064         * modules/stdbool (Makefile.am): Remove explicit dependency on
19065         $(STDBOOL_H), redundant through BUILT_SOURCES.
19066         * modules/stdint (Makefile.am): Remove explicit dependency on
19067         $(STDINT_H), redundant through BUILT_SOURCES.
19068         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
19069         Remove explicit dependency on $(SYSEXITS_H).
19070         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
19071
19072 2005-07-18  Simon Josefsson  <jas@extundo.com>
19073
19074         * lib/check-version.c (check_version): Accept identical versions too.
19075
19076 2005-07-18  Bruno Haible  <bruno@clisp.org>
19077
19078         * modules/lock: New file.
19079         * MODULES.html.sh (Multithreading): New section.
19080
19081 2005-07-18  Bruno Haible  <bruno@clisp.org>
19082
19083         * m4/lock.m4: New file, from GNU gettext.
19084
19085 2005-07-18  Bruno Haible  <bruno@clisp.org>
19086
19087         * lib/lock.h: New file, from GNU gettext.
19088         * lib/lock.c: New file, from GNU gettext.
19089
19090 2005-07-18  Bruno Haible  <bruno@clisp.org>
19091
19092         * lib/lock.h (gl_once_t): New type.
19093         (gl_once_define, gl_once): New macros.
19094         * lib/lock.c (fresh_once): New variable.
19095         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
19096         functions.
19097
19098 2005-07-16  Simon Josefsson  <jas@extundo.com>
19099
19100         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
19101         workaround, suggested by Bruno.
19102
19103 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
19104
19105         * modules/xalloc (Depends-on): Add xalloc-die.
19106         * modules/xvasprintf (Depends-on): Add xalloc-die.
19107
19108 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
19109
19110         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
19111         with a minor change.
19112
19113 2005-07-15  Bruno Haible  <bruno@clisp.org>
19114
19115         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
19116         When using lib/poll.c, define poll as rpl_poll.
19117
19118 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
19119
19120         * modules/argp (Depends-on): Remove unlocked-io.
19121
19122 2005-07-14  Derek Price  <derek@ximbiot.com>
19123
19124         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
19125         for glob symlink bug.
19126
19127 2005-07-14  Bruno Haible  <bruno@clisp.org>
19128
19129         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
19130         Instead, test for *_unlocked function declarations directly.
19131
19132 2005-07-11  Simon Josefsson  <jas@extundo.com>
19133
19134         * modules/size_max: New file.
19135
19136         * modules/xsize: Depend on size_max module for size_max.m4.
19137
19138 2005-07-11  Simon Josefsson  <jas@extundo.com>
19139
19140         * lib/size_max.h: New file.
19141
19142 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
19143
19144         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
19145         copyright symbol and the year.
19146         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
19147         (version_etc_va): Use parameterized copyright notice.
19148         Reword to conform to the current GNU coding standards.
19149
19150 2005-07-11  Karl Berry  <karl@gnu.org>
19151
19152         * doc/gnulib.texi (Quoting): new node.
19153         (Initial import): more info, from Patrice.
19154
19155 2005-07-11  Bruno Haible  <bruno@clisp.org>
19156
19157         * gnulib-tool (func_usage): Document option --avoid.
19158         (Command line options): Handle --avoid.
19159         (func_acceptable): New function.
19160         (func_modules_transitive_closure): Use it.
19161
19162 2005-07-11  Bruno Haible  <bruno@clisp.org>
19163
19164         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
19165         Reported by Jim Meyering.
19166
19167 2005-07-10  Bruno Haible  <bruno@clisp.org>
19168
19169         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
19170         Needed when size_t is smaller than 'unsigned int'.
19171         Reported by Paul Eggert.
19172
19173 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
19174
19175         * modules/argp (Depends-on): Add unlocked-io
19176
19177 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
19178
19179         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
19180         block of defines.
19181
19182 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
19183
19184         * config/srclist.txt: Comment out regcomp.c, since we have a porting
19185         fix now.
19186
19187 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
19188         and Paul Eggert  <eggert@cs.ucla.edu>
19189
19190         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
19191         in wint_t, not wchar_t.  Remove now-unnecessary cast.
19192
19193 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19194
19195         * modules/regex (Files): Add lib/regex_internal.c,
19196         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
19197         (Depends-on): Add extensions.
19198         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
19199
19200 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19201
19202         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
19203         pathconf.
19204         * m4/same.m4 (gl_SAME): Likewise.
19205         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
19206
19207         * m4/regex.m4: Adjust to new libc regex implementation.
19208         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
19209         all the .c and .h parts of (the new) regex.
19210         Quote the m4 stuff better.
19211         Check for RE_ICASE bug of old gnulib.
19212         Check for REG_STARTEND of recent libc.
19213         Rename local variables from jm_* to gl_*.
19214         Quote operand of "test -f".
19215         Say "recent enough" version of libc, not "version 2".
19216         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
19217         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
19218         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
19219         Remove check for btowc, isascii.
19220         Require AM_LANGINFO_CODESET.
19221
19222 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19223
19224         * lib/regex.c, regex.h: Sync from libc.
19225         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
19226         * lib/regexec.c:
19227         New files, synced from libc, except that regex_internal.h
19228         currently has a small porting fix.
19229
19230 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19231
19232         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
19233         regex_internal.c, regexec.c.
19234         Add regex_internal.h too, but as a comment, since the libc version
19235         is currently broken in gnulib mode.
19236
19237 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
19238
19239         Support programs like Emacs that use gnulib but not gettext.
19240         * MODULES.html.sh (Internationalization functions): Add gettext-h.
19241         * modules/gettext-h: New file.
19242         * modules/gettext (Files): Remove lib/gettext.h.
19243         (Depends-on): Add gettext-h.
19244         (Makefile.am): Remove lib_SOURCES.
19245         * modules/argmatch, modules/c-stack, modules/closeout:
19246         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
19247         * modules/execute, modules/file-type, modules/getaddrinfo:
19248         * modules/getopt, modules/human, modules/javacomp:
19249         * modules/javaexec, modules/mkdir-p, modules/obstack:
19250         * modules/openat, modules/pagealign_alloc, modules/pipe:
19251         * modules/quotearg, modules/regex, modules/rpmatch:
19252         * modules/unicodeio, modules/userspec, modules/version-etc:
19253         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
19254         * modules/xsetenv:
19255         Depend on gettext-h, not gettext.
19256
19257 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
19258
19259         * gnulib-tool (func_import): Add support for 'public domain' license.
19260         * modules/alloca, modules/atexit, modules/memmove:
19261         Now public domain, not GPL.
19262         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
19263         * modules/realloc, modules/strerror, modules/strtod:
19264         Now LGPL, not GPL.
19265
19266 2005-07-05  Bruno Haible  <bruno@clisp.org>
19267
19268         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
19269         autoconf CVS. Needed for mingw.
19270
19271 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
19272
19273         Remove the dependency of the strftime module on the tzset module.
19274         * modules/strftime (Depends-on): Remove dependency on tzset.
19275
19276 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
19277
19278         Remove the dependency of the strftime module on the tzset module.
19279         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
19280         gl_FUNC_TZSET_CLOBBER.
19281
19282 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
19283
19284         Remove the dependency of the strftime module on the tzset module.
19285         * lib/strftime.c (my_strftime)
19286         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
19287         Copy the input structure, to work around some of the bug with
19288         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
19289         Solaris releases, you should also use the tzset module, but we won't
19290         require it as a dependency any more since we don't want LGPLed code
19291         to depend on GPLed code.
19292
19293 2005-07-02  Jim Meyering  <jim@meyering.net>
19294
19295         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
19296         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
19297         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
19298         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
19299
19300 2005-07-02  Jim Meyering  <jim@meyering.net>
19301
19302         * lib/backupfile.c (backup_args): Change a `0' to NULL.
19303
19304 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
19305
19306         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
19307         declares only 'struct timespec;' (!).
19308
19309 2005-07-01  Jim Meyering  <jim@meyering.net>
19310
19311         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
19312         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
19313         * lib/save-cwd.c, tempname.c:
19314         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
19315         and don't include <sys/file.h>).
19316
19317 2005-06-29  Jim Meyering  <jim@meyering.net>
19318
19319         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
19320         type name.  Use the variable name instead.
19321         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
19322         Likewise.
19323
19324 2005-06-28  Simon Josefsson  <jas@extundo.com>
19325
19326         * modules/check-version (Files): Add check-version.m4.
19327
19328 2005-06-28  Simon Josefsson  <jas@extundo.com>
19329
19330         * m4/check-version.m4: New file, suggested by Jim Meyering
19331         <jim@meyering.net>.
19332
19333 2005-06-28  Simon Josefsson  <jas@extundo.com>
19334
19335         * lib/check-version.h, lib/check-version.c: New files.
19336
19337 2005-06-28  Simon Josefsson  <jas@extundo.com>
19338
19339         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
19340         collision with global variable.  Better indentation.  Don't
19341         increment buffer pointer beyond buffer end.  Based on comments
19342         from Paul Eggert <eggert@cs.ucla.edu>.
19343
19344         * lib/base64.h: Indent.
19345
19346 2005-06-28  Simon Josefsson  <jas@extundo.com>
19347
19348         * doc/gnulib.texi (Library version handling): New section.
19349
19350 2005-06-28  Jim Meyering  <jim@meyering.net>
19351
19352         * check-module (find_included_lib_files): Hard-code another
19353         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
19354         but modules/fts-lgpl (correctly) does not list those files.
19355
19356         * modules/canonicalize (Files): Add lib/pathmax.h.
19357
19358 2005-06-25  Simon Josefsson  <jas@extundo.com>
19359
19360         * modules/check-version: New file.
19361
19362 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
19363
19364         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
19365         initializer of struct addrinfo, as an indication that we don't
19366         care how many members the structure has.
19367
19368 2005-06-24  Derek Price  <derek@ximbiot.com>
19369         and Bruno Haible  <bruno@clisp.org>
19370
19371         Remove stat module & update lstat.
19372         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
19373         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
19374         * m4/stat.m4: Remove this file.
19375
19376 2005-06-24  Derek Price  <derek@ximbiot.com>
19377         and Bruno Haible  <bruno@clisp.org>
19378
19379         Remove stat module & update lstat.
19380         * lib/stat.c: Remove this file...
19381         (slash_aware_lstat): ...moving this content and its support...
19382         * lib/lstat.c (rpl_lstat): ...into here.
19383         * lib/lstat.h: New file.
19384
19385 2005-06-24  Derek Price  <derek@ximbiot.com>
19386         and Bruno Haible  <bruno@clisp.org>
19387
19388         Remove stat module & update lstat.
19389         * config/srclist.txt (libc sources): Remove stat.
19390
19391 2005-06-24  Derek Price  <derek@ximbiot.com>
19392         and Bruno Haible  <bruno@clisp.org>
19393
19394         Remove stat module & update lstat.
19395         * MODULES.html.sh (stat): Remove.
19396         * MODULES.html: Regenerated.
19397         * modules/lstat (Description): Correct function name.
19398         (Files): Add "lstat.h".
19399         (Depends-on): Remove stat, add xalloc, stat-macros.
19400         * modules/stat: Remove this file.
19401         (Include): Add "lstat.h", remove <sys/stat.h>.
19402
19403 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
19404
19405         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
19406         (ranged_convert): Don't save conversion in a temporary struct.
19407         This causes a warning with GCC 4.0.0, and anyway in the typical
19408         case it's not worth the extra 100 bytes or so of code.
19409         (ranged_convert, __mktime_internal): When calling a function via a
19410         pointer P, use P () rather than (*P) (), as we now assume C89 or
19411         better.
19412
19413 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19414
19415         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
19416         "who -r" failed to give output.  Problem reported by Tim Waugh.
19417
19418         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
19419         (xcalloc): Use it to avoid needless tests.
19420         Problem reported by Jim Meyering.
19421
19422 2005-06-20  Derek Price  <derek@ximbiot.com>
19423
19424         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
19425         unnecessary for Autoconfs > 2.59c.
19426
19427 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19428
19429         * lib/argp.h (__option_is_short): Check upper limit of
19430         __key. Isprint() requires its argument to have the value
19431         of an unsigned char or EOF.
19432
19433 2005-06-16  Jim Meyering  <jim@meyering.net>
19434
19435         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
19436         when either N or S is zero.
19437
19438 2005-06-16  Derek Price  <derek@ximbiot.com>
19439
19440         * m4/bison.m4: Declare YACC & YFLAGS precious.
19441
19442 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
19443
19444         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
19445         multibyte string or pattern, fall back on unibyte matching.
19446         Problem reported by James Youngman.
19447
19448 2005-06-08  Bruno Haible  <bruno@clisp.org>
19449
19450         * modules/csharpcomp: New file.
19451         * MODULES.html.sh (C#): Add csharpcomp.
19452
19453 2005-06-08  Bruno Haible  <bruno@clisp.org>
19454
19455         * m4/csharpcomp.m4: New file, from GNU gettext.
19456
19457 2005-06-08  Bruno Haible  <bruno@clisp.org>
19458
19459         * lib/csharpcomp.h: New file, from GNU gettext.
19460         * lib/csharpcomp.c: New file, from GNU gettext.
19461         * lib/csharpcomp.sh.in: New file, from GNU gettext.
19462
19463 2005-06-08  Bruno Haible  <bruno@clisp.org>
19464
19465         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
19466         warning on mingw.
19467
19468 2005-06-07  Derek Price  <derek@ximbiot.com>
19469
19470         Sync from CVS.
19471         * lib/glob_.h: Indent nested #ifdef.
19472
19473 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19474
19475         Sync from coreutils.
19476         Use "file name" when talking about file names, instead of "filename"
19477         or "path", as per the GNU coding standards.
19478         * lib/mkdir-p.c: Renamed from makepath.c.
19479         (make_dir_parents): Renamed from make_path.  All callers changed.
19480         * lib/mkdir-p.h: Likewise.  All includers changed.
19481         * lib/filenamecat.c: Renamed from path-concat.c.
19482         (file_name_concat): Renamed from path_concat.  All callers changed.
19483         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
19484         * lib/filenamecat.h: Likewise.  All includers changed.
19485         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
19486         in comments or local variable names.
19487         * lib/basename.c: Likewise.
19488         * lib/canonicalize.c, canonicalize.h: Likewise.
19489         * lib/dirname.c, dirname.h: Likewise.
19490         * lib/euidaccess.c: Likewise.
19491         * lib/exclude.c: Likewise
19492         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
19493         * lib/fsusage.c, fsuage.h: Likewise.
19494         * lib/fts.c, fts_.h: Likewise.
19495         * lib/getcwd.c: Likewise.
19496         * lib/getloadavg.c: Likewise.
19497         * lib/mkstemp.c: Likewise.
19498         * lib/mountlist.c, mountlist.h: Likewise.
19499         * lib/openat.c, openat.h: Likewise.
19500         * lib/readlink-stub.c: Likewise.
19501         * lib/readutmp.c, readutmp.h: Likewise.
19502         * lib/rename.c: Likewise.
19503         * lib/rmdir.c: Likewise.
19504         * lib/same.c: Likewise.
19505         * lib/savedir.c: Likewise.
19506         * lib/stripslash.c: Likewise.
19507         * lib/tempname.c: Likewise.
19508         * lib/xreadlink.c: Likewise.
19509         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
19510         All uses changed.
19511         * lib/exclude.h: Likewise.
19512
19513         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
19514         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19515         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
19516         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19517         * lib/pathmax.h: Include <limits.h> unconditionally, since other
19518         files have been getting away with it for years (MORE/BSD 4.3
19519         is extinct now).
19520         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
19521         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19522
19523         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
19524         Define to 256, not 255, as per modern POSIX.
19525
19526 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19527
19528         Sync from coreutils.
19529         Use "file name" when talking about file names, instead of "filename"
19530         or "path", as per the GNU coding standards.
19531         * MODULES.html.sh: mkdir-p renamed from makepath.
19532         filenamecat renamed from path-concat.
19533         * modules/filenamecat: Renamed from modules/path-concat.
19534         (Files): filenamecat.h and filenamecat.c renamed from
19535         path-concat.h and path-concat.c.
19536         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
19537         (Include): filenamecat.h, not path-concat.h.
19538         * modules/mkdir-p: Renamed from modules/makepath.
19539         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
19540         makepath.c.
19541         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
19542         (Include): mkdir-p.h, not makepath.h.
19543
19544 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19545
19546         Sync from coreutils.
19547         * m4/mkdir-p.m4: Renamed from makepath.m4.
19548         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
19549         Rename files from makepath.c to mkdir-p.c, and from
19550         makepath.h to mkdir-p.h.
19551         * m4/filenamecat.m4: Renamed from path-concat.m4.
19552         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
19553         Rename files from path-concat.c to filenamecat.c,
19554         and from path-concat.h to filenamecat.h.
19555         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
19556         "file name" in local variables or comments.
19557         * m4/rename.m4: Likewise.
19558
19559 2005-06-01  Bruno Haible  <bruno@clisp.org>
19560
19561         * modules/csharpexec: New file.
19562         * MODULES.html.sh (C#): New section.
19563
19564 2005-06-01  Bruno Haible  <bruno@clisp.org>
19565
19566         * m4/csharp.m4: New file, from GNU gettext.
19567         * m4/csharpexec.m4: New file, from GNU gettext.
19568
19569 2005-06-01  Bruno Haible  <bruno@clisp.org>
19570
19571         * lib/csharpexec.h: New file, from GNU gettext.
19572         * lib/csharpexec.c: New file, from GNU gettext.
19573         * lib/csharpexec.sh.in: New file, from GNU gettext.
19574
19575 2005-05-31  Derek Price  <derek@ximbiot.com>
19576             Paul Eggert  <eggert@cs.ucla.edu>
19577
19578         Sync from cvs.
19579         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
19580
19581 2005-05-31  Derek Price  <derek@ximbiot.com>
19582             Paul Eggert  <eggert@cs.ucla.edu>
19583
19584         Sync from cvs.
19585         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
19586
19587 2005-05-29  Derek Price  <derek@ximbiot.com>
19588
19589         * config/srclist.txt (glob_.h, glob.c): Add these files.
19590
19591 2005-05-29  Derek Price  <derek@ximbiot.com>
19592
19593         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
19594         * modules/glob: New file.
19595         * modules/getlogin_r: Add link to POSIX spec in description.
19596
19597 2005-05-29  Derek Price  <derek@ximbiot.com>
19598             Paul Eggert  <eggert@cs.ucla.edu>
19599
19600         * m4/glob.m4: New file.
19601
19602 2005-05-29  Derek Price  <derek@ximbiot.com>
19603             Paul Eggert  <eggert@cs.ucla.edu>
19604
19605         * lib/glob_.h, lib/glob.c: New files.
19606
19607 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19608
19609         * modules/fts (Files): Remove m4/inttypes-pri.m4.
19610         * modules/fts-lgpl (Depends-on): Remove gettext.
19611
19612 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19613
19614         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
19615         and don't require gt_INTTYPES_PRI.
19616
19617 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19618
19619         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
19620
19621         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
19622         the configuration hassle isn't worth it.
19623         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
19624         (LONGEST_MODIFIER, PRIuMAX): Remove.
19625
19626 2005-05-27  Bruno Haible  <bruno@clisp.org>
19627
19628         * lib/getlogin_r.h: Remove second include of <stddef.h>.
19629
19630 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
19631
19632         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
19633         _POSIX_PTHREAD_SEMANTICS for Solaris.
19634
19635 2005-05-25  Derek Price  <derek@ximbiot.com>
19636
19637         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
19638
19639 2005-05-25  Derek Price  <derek@ximbiot.com>
19640             Paul Eggert  <eggert@cs.ucla.edu>
19641
19642         * modules/getlogin_r, m4/getlogin_r.m4: New files.
19643         * lib/getlogin_r.c, getlogin_r.h: New files.
19644
19645 2005-05-25  Bruno Haible  <bruno@clisp.org>
19646             Derek Price  <derek@ximbiot.com>
19647
19648         * lib/getlogin_r.h: Simplify API documentation.
19649
19650 2005-05-23  Derek Price  <derek@ximbiot.com>
19651
19652         * modules/minmax (Files): Add m4/minmax.m4.
19653         (configure.ac): Add gl_MINMAX.
19654
19655 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
19656
19657         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
19658         so that unistd-safer.h (GPL'ed code) need not be included.
19659
19660 2005-05-22  Bruno Haible  <bruno@clisp.org>
19661
19662         * m4/minmax.m4: New file.
19663         Based on a patch by Derek Price <derek@ximbiot.com>.
19664
19665 2005-05-22  Bruno Haible  <bruno@clisp.org>
19666
19667         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
19668         (INT64_MIN): Fix definition.
19669         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
19670
19671         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
19672         NEED_SIGNED_INT_TYPES.
19673
19674         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
19675         HAVE_SYSTEM_INTTYPES.
19676
19677 2005-05-22  Bruno Haible  <bruno@clisp.org>
19678
19679         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
19680         Also include <sys/param.h> if it defines MIN, MAX.
19681         Based on a patch by Derek Price <derek@ximbiot.com>.
19682
19683 2005-05-21  Jim Meyering  <jim@meyering.net>
19684
19685         * modules/fts (Files): Add m4/inttypes-pri.m4.
19686         (Depends-on): Add lstat and remove gettext.  Alphabetize.
19687
19688 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19689
19690         New fts module.
19691         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
19692         (setup_dir, free_dir): New functions.
19693         (enter_dir, leave_dir): Define trivial
19694         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
19695         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
19696         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
19697         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
19698         Move to fts-cycle.c.
19699         (fts_open): Use setup_dir.
19700         (fts_close): Use free_dir.
19701         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
19702         This adds a label and some gotos, but the alternatives were messier.
19703         Check for memory allocation failure when entering a dir.
19704         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
19705         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
19706         (FTS): New member fts_cycle, that is a union that contains the
19707         old active_dir_ht and cycle_state.  All uses changed to mention
19708         fts_cycle.ht and fts_cycle.state.
19709         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
19710         fts.c, with the following changes:
19711         (setup_dir, free_dir): New functions.
19712         (enter_dir): Now returns bool.  Return true if successful, false
19713         if memory exhausted.  All callers changed.
19714         Do not bother partly cleaning up on
19715         memory allocation failure; that is free_dir's job.
19716         However, free ad if hash_insert fails, to avoid memory leak.
19717         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
19718         fts->fts_options to see which union member to use.
19719
19720 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19721
19722         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
19723         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
19724
19725 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19726
19727         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
19728
19729 2005-05-20  Jim Meyering  <jim@meyering.net>
19730
19731         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
19732         Now a macro, to pacify GCC.
19733
19734 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
19735
19736         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
19737         of -1.
19738
19739 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
19740
19741         * lib/chown.c (rpl_chown): Return -1 on failure.
19742
19743 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
19744
19745         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
19746         Don't check for stddef.h.
19747         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
19748         don't use its results.
19749         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
19750         since we include them unconditionally.  Don't require
19751         AM_STDBOOL_H, since stdbool is a prerequisite.
19752         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
19753         since we assume C89 or better.
19754         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
19755         as we don't use their results.
19756         Don't check for fchdir, memmove, memset, strrchr, as we use
19757         them unconditionally.
19758         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
19759         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
19760
19761 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
19762
19763         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
19764         Include <stddef.h> unconditionally, since we assume C89 now.
19765         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
19766         * lib/fts.c: Include fts_.h first, to check interface.
19767         Do not include intprops.h; no longer needed.
19768         Include cycle-check.h and hash.h, since fts_.h no longer does.
19769         Remove unnecessary casts of closedir to void.
19770         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
19771         decide whether to decrement nlinks.
19772         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
19773         (FTS): Use struct hash_table * instead of Hash_table, so that
19774         we no longer need to include hash.h here.
19775
19776 2005-05-18  Jim Meyering  <jim@meyering.net>
19777
19778         * modules/dirfd (License): Change to LGPL.  Most of the code
19779         is already in the public domain.
19780
19781 2005-05-18  Jim Meyering  <jim@meyering.net>
19782
19783         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
19784         Reported by Yoann Vandoorselaere.
19785
19786 2005-05-17  Jim Meyering  <jim@meyering.net>
19787
19788         * m4/fts.m4: New file, from coreutils.
19789
19790 2005-05-17  Jim Meyering  <jim@meyering.net>
19791
19792         * lib/fts.c, lib/fts_.h: New files, from coreutils.
19793
19794 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
19795
19796         Sync from coreutils.
19797         * m4/unlinkdir.m4: New file.
19798
19799 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
19800
19801         Sync from coreutils.
19802         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
19803         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
19804         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
19805         White space changes only.
19806         * lib/makepath.c (make_path): Port to hosts where leading "//" is
19807         special.
19808         * lib/yesno.c: Include getline.h, not ctype.h.
19809         (yesno): Don't remove leading white space; POSIX doesn't allow it.
19810         Use getline to remove arbitrary restriction on response length.
19811
19812 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
19813
19814         * config/srclist-update: Spell out "Street" in FSF postal
19815         mail address; this is the style the FSF seems to prefer.
19816
19817         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
19818         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
19819         this updates FSF postal mail address.
19820
19821         Sync from coreutils.
19822         * modules/unlinkdir: New file.
19823         * modules/yesno (Depends-on): Add getline.
19824         * MODULES.html.sh (File system functions): Add unlinkdir.
19825
19826 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19827
19828         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
19829         lib/strsep.h:
19830         Change the initial comment to refer to GPL, not LGPL.
19831         gnulib-tool will change it to LGPL as needed.
19832
19833         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
19834         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
19835         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
19836         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
19837         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
19838         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
19839         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
19840         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
19841         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
19842         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
19843         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
19844         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
19845         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
19846         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
19847         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
19848         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
19849         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
19850         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
19851         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
19852         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
19853         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
19854         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
19855         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
19856         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
19857         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
19858         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
19859         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
19860         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
19861         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
19862         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
19863         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
19864         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
19865         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
19866         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
19867         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
19868         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
19869         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
19870         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
19871         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
19872         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
19873         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
19874         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
19875         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
19876         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
19877         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
19878         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
19879         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
19880         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
19881         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
19882         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
19883         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
19884         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
19885         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
19886         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
19887         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
19888         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
19889         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
19890         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
19891         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
19892         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
19893         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
19894         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
19895         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
19896         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
19897         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
19898         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
19899         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
19900         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
19901         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
19902         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
19903         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
19904         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
19905         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
19906         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
19907         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
19908         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
19909         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
19910         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
19911         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
19912         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
19913         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
19914         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
19915         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
19916         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
19917         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
19918         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
19919         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
19920         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
19921         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
19922         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
19923         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
19924         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
19925         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
19926         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
19927         lib/yesno.c, lib/yesno.h:
19928         Update FSF postal mail address.
19929
19930 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
19931
19932         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
19933         tests/test-memmem.c, tests/test-stpncpy.c:
19934         Update FSF postal mail address.
19935
19936 2005-05-13  Bruno Haible  <bruno@clisp.org>
19937
19938         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
19939         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
19940         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
19941         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
19942         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
19943         Add support for 64-bit integers in the MSVC compiler.
19944
19945 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19946
19947         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
19948
19949 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
19950
19951         * gnulib-tool (func_import): Sort and uniquify recommended includes.
19952
19953 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
19954
19955         * doc/getdate.texi (General date syntax): Don't say that date
19956         date --iso-8601=ns generates acceptable dates; it doesn't yet.
19957         Problem reported by Nic Ferrier.
19958
19959 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19960
19961         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
19962         specified in ai_socktype. Fix invalid ai_protocol
19963         check. ai_protocol is usually set to 0 or depending on
19964         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
19965         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
19966         ai_socktype / ai_protocol in the returned addrinfo structure.
19967
19968 2005-05-10  Simon Josefsson  <jas@extundo.com>
19969
19970         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
19971         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
19972
19973 2005-05-10  Karl Berry  <karl@gnu.org>
19974
19975         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
19976         (from http://www.gnu.org/licenses).
19977         * doc/COPYING.LIB: also rename to COPYING.LESSER.
19978         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
19979         fdl.texi suffices.
19980
19981 2005-05-10  Karl Berry  <karl@gnu.org>
19982
19983         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
19984         (COPYING.DOC): remove.
19985
19986         * config/srclist-update: new FSF address.
19987
19988 2005-05-10  Derek Price  <derek@ximbiot.com>
19989
19990         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
19991         possible.
19992
19993 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
19994             Bruno Haible  <bruno@clisp.org>
19995
19996         * modules/inet_ntop: New file.
19997         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
19998         inet_ntop.
19999
20000 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
20001             Bruno Haible  <bruno@clisp.org>
20002
20003         * m4/inet_ntop.m4: New file.
20004
20005 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
20006             Bruno Haible  <bruno@clisp.org>
20007
20008         * lib/inet_ntop.h: New file.
20009         * lib/inet_ntop.c: New file, from glibc with modifications.
20010
20011 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
20012
20013         * modules/time_r (License): Change to LGPL.
20014         * modules/extensions (License): Change to LGPL.  Actually,
20015         the license is more permissive than that, but currently gnulib-tool
20016         doesn't know how to handle more-permissive licenses.
20017
20018         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
20019         Problem reported by Dave Love.
20020
20021 2005-05-08  Jim Meyering  <jim@meyering.net>
20022
20023         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
20024         blank.
20025
20026 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
20027
20028         * modules/argmatch (Depends-on): Add stdbool.
20029         * modules/backupfile (Depends-on): Likewise.
20030         * modules/chdir-long (Depends-on): Likewise.
20031         * modules/closeout (Depends-on): Likewise.
20032         * modules/cycle-check (Depends-on): Likewise.
20033         * modules/dirname (Depends-on): Likewise.
20034         * modules/fnmatch (Depends-on): Likewise.
20035         * modules/fsusage (Depends-on): Likewise.
20036         * modules/fwriteerror (Depends-on): Likewise.
20037         * modules/getcwd (Depends-on): Likewise.
20038         * modules/getloadavg (Depends-on): Likewise.
20039         * modules/hard-locale (Depends-on): Likewise.
20040         * modules/makepath (Depends-on): Likewise.
20041         * modules/mountlist (Depends-on): Likewise.
20042         * modules/nanosleep (Depends-on): Likewise.
20043         * modules/posixtm (Depends-on): Likewise.
20044         * modules/quotearg (Depends-on): Likewise.
20045         * modules/readtokens (Depends-on): Likewise.
20046         * modules/readtokens0 (Depends-on): Likewise.
20047         * modules/readutmp (Depends-on): Likewise.
20048         * modules/save-cwd (Depends-on): Likewise.
20049         * modules/strftime (Depends-on): Likewise.
20050         * modules/userspec (Depends-on): Likewise.
20051         * modules/utimecmp (Depends-on): Likewise.
20052         * modules/xgetcwd (Depends-on): Likewise.
20053         * modules/xnanosleep (Depends-on): Likewise.
20054         * modules/xstrtod (Depends-on): Likewise.
20055         * modules/yesno (Depends-on): Likewise.
20056
20057 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
20058
20059         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
20060         needless checks.
20061
20062 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20063
20064         Merge from coreutils.  Among other things,
20065         add bulletproofing for cases where stdin, stdout, or stderr are closed.
20066         * lib/fd-safer.c: New file.
20067         * lib/fcntl-safer.h, open-safer.c: Remove.
20068         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
20069         * lib/dup-safer.c: Include unistd-safer.h first.
20070         Don't include errno.h.
20071         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
20072         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
20073         * lib/file-type.c: Rely on file-type.h change.
20074         * lib/getloadavg.c: Include unistd-safer.h.
20075         (getloadavg): Use safer open.
20076         * lib/getusershell.c: Include "stdio-safer.h".
20077         (getusershell): Use safer fopen.
20078         * lib/long-options.c (long_options): Use NULL rather than 0.
20079         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
20080         'free'.
20081         * lib/modechange.c: Likewise.
20082         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
20083         (MODE_DONE): New constant.
20084         (struct mode_change): Remove 'next' member.
20085         (make_node_op_equals): New function; like the old one of the
20086         same name, except it allocates an array.
20087         (mode_compile, mode_create_from_ref): Use it.
20088         (mode_compile): Allocate result as an array, not a linked list.
20089         Parse octal string ourself, so that we catch mistakes like "+0".
20090         (mode_adjust): Arg is an array, not a linked list.
20091         * lib/modechange.c: Include stat-macros.h, xalloc.h.
20092         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
20093         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
20094         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
20095         Remove.  This is now stat-macros.h's job.
20096         (talloc): Remove.  All callers replaced by xalloc, so that
20097         our invokers don't have to worry about reporting memory failures.
20098         (make_node_op_equals): Remove.
20099         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
20100         New constants.
20101         (struct mode_change): Moved here from modechange.h.
20102         (mode_append_entry): Remove.
20103         (mode_compile): Remove MASKED_OPS arg, since it encouraged
20104         apps to have incorrect behavior.  Use simpler algorithm for head
20105         and tail.  Don't futz with umask; that's now the job of mode_adjust.
20106         Detect more invalid usages rather than having somewhat-random behavior.
20107         Don't insert an "a=" action, as that leads to incorrect behavior.
20108         (mode_compile, mode_create_from_ref): Return NULL on error instead
20109         of an enum, since now there's only one way to have an error.  All
20110         callers changed.
20111         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
20112         at the correct time.  Simplify calculation of "+u" and its ilk.
20113         Don't mishandle "+X".
20114         (mode_free): Remove "register" and localize decls.
20115         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
20116         (struct mode_change): Move to modechange.c; callers don't
20117         need to see this stuff.
20118         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
20119         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
20120         (mode_change, mode_adjust): Reflect the new signatures noted above.
20121         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
20122         that might redefine system include files.
20123         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
20124         (my_usleep): Use NULL rather than (void *) 0.
20125         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
20126         Use siginterrupt to specify that system calls should be interrupted.
20127         (rpl_nanosleep): Move initialization of suspended closer to call of
20128         my_usleep.
20129         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
20130         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
20131         (desirable_utmp_entry): New function.
20132         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
20133         using x2nrealloc, to simplify logic.
20134         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
20135         size calculation.  Do not assume utmp file is a regular file.
20136         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
20137         (READ_UTMP_CHECK_PIDS): New constant.
20138         * lib/save-cwd.c: Include unistd-safer.h.
20139         (save_cwd): Use fd_safer.
20140         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
20141         [!_LIBC] Include "stat-macros.h" instead.
20142         * lib/unistd-safer.h (fd_safer): New decl.
20143
20144 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20145
20146         * modules/getloadavg (Depends-on): Add unistd-safer.
20147         * modules/getusershell (Depends-on): Add stdio-safer.
20148         * modules/lstat (Depends-on): Remove xalloc.
20149         * modules/mkstemp (Depends-on): Add stat-macros.
20150         * modules/modechange (Depends-on): Remove xstrtol.
20151         Add stat-macros, xalloc.
20152         * modules/save-cwd (Depends-on): Add unistd-safer.
20153         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
20154         * modules/unistd-safer (Files): Add lib/fd-safer.c
20155         (Makefile.am): Remove lib_SOURCES.
20156
20157         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
20158         Remove fcntl-safer; unistd-safer supersedes it.
20159
20160 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20161
20162         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
20163         AC_HEADER_STAT.
20164         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
20165         (gl_PREREQ_CHOWN): Remove.
20166         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
20167         it.  Don't require AC_HEADER_STAT.
20168         (gl_PREREQ_LSTAT): Remove.
20169         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
20170         Don't require AC_HEADER_STAT.
20171         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
20172         (gl_PREREQ_RMDIR): Remove.
20173         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
20174         mention stat-macros.h or AC_HEADER_STAT, since we'll make
20175         the stat-macros module a prerequisite.
20176         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
20177         * m4/filemode.m4 (gl_FILEMODE): Likewise.
20178         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
20179         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
20180         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
20181         variable names.
20182         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
20183         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
20184         variable prefixes.
20185         * m4/fcntl-safer.m4: Remove.
20186         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
20187         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
20188         Invoke gl_PREREQ_FD_SAFER.
20189         (gl_PREREQ_FD_SAFER): New macro.
20190         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
20191         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
20192         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
20193         Remove duplicate call to AC_LIBOBJ(readutmp).
20194         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
20195
20196         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
20197         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
20198
20199 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20200
20201         * MODULES.html.sh (Misc): Add byteswap.
20202
20203 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20204
20205         * modules/getcwd (Depends-on): Add extensions.
20206         * modules/openat (Depends-on): Likewise.
20207
20208 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20209
20210         * modules/byteswap: New file.
20211
20212 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20213
20214         * m4/byteswap.m4: New file.
20215
20216 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20217
20218         * lib/byteswap_.h: New file.
20219
20220 2005-04-25  Karl Berry  <karl@gnu.org>
20221
20222         * m4/gettext.m4: Update from GNU gettext 0.14.4.
20223
20224 2005-04-25  Albert Chin  <china@thewrittenword.com>
20225
20226         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
20227         Toolkit C bug.
20228
20229 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
20230
20231         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
20232         (func_ln_if_changed) Remove forcibly for no error message
20233         in case file does not exist.
20234
20235 2005-04-19  Simon Josefsson  <jas@extundo.com>
20236
20237         * gnulib-tool (Options): Make --symlink mean --symbolic.
20238
20239 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
20240
20241         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
20242
20243 2005-04-16  Simon Josefsson  <jas@extundo.com>
20244
20245         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
20246
20247 2005-04-15  Simon Josefsson  <jas@extundo.com>
20248
20249         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
20250
20251 2005-04-15  Simon Josefsson  <jas@extundo.com>
20252
20253         * gnulib-tool: Rename --symlink to --symbolic.
20254
20255 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
20256
20257         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
20258         symbolic links to files instead of copying/moving.  Add --aux-dir,
20259         specifying directory relative --dir where auxiliary build tools
20260         are placed.
20261
20262 2005-04-14  Bruno Haible  <bruno@clisp.org>
20263
20264         * modules/allocsa (License): Change to LGPL.
20265         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
20266
20267 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
20268
20269         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
20270         that "UTC +1 second" continues to work.  Problem reported
20271         by Dmitry V. Levin.
20272         (relunit_snumber): New rule.
20273         (relunit): Use it.
20274
20275 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
20276
20277         * lib/getdate.y (universal_time_zone_table): New constant.
20278         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
20279         universal_time_zone_table.
20280         (lookup_zone): Prefer universal_time_zone_table to
20281         local_time_zone_table, so that "GMT" time stamps are allowed in
20282         London during the summer.  Problem reported by Ian Abbott.
20283
20284 2005-04-12  Jim Meyering  <jim@meyering.net>
20285
20286         * lib/human.c (humblock): Set *options even when returning due to
20287         xstrtoumax conversion failure.  Thanks to a used-uninitialized
20288         warning from gcc-4.
20289
20290 2005-04-09  Jim Meyering  <jim@meyering.net>
20291
20292         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
20293         -Wuninitialized: initialize tm0.tm_year.
20294
20295 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
20296
20297         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
20298         count, since there's no maximum.  All uses changed.
20299         Add member dsts_seen.
20300         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
20301         not being INT_MAX.
20302         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
20303         Use pc_rels_seen to decide whther a date is absolute.
20304
20305         * lib/getdate.y (number): Don't overwrite year.
20306         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
20307         check.
20308
20309 2005-04-02  Simon Josefsson  <jas@extundo.com>
20310
20311         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
20312         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
20313
20314 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
20315
20316         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
20317         where no absolute path name can be longer than PATH_MAX.
20318
20319 2005-03-27  Jim Meyering  <jim@meyering.net>
20320
20321         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
20322
20323 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
20324
20325         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
20326         "one's complement" -> "ones' complement" in comment, as per Knuth.
20327         "value of type" -> "type or expression" in comment.
20328         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
20329
20330 2005-03-26  Jim Meyering  <jim@meyering.net>
20331
20332         Comment nits.
20333         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
20334         Correct typos: s/or/of/.
20335
20336 2005-03-26  Jim Meyering  <jim@meyering.net>
20337
20338         * modules/check-include-files: Move to ../ and rename to...
20339         * check-module: ...this.
20340
20341 2005-03-25  Jim Meyering  <jim@meyering.net>
20342
20343         * modules/xvasprintf (Files): Add xalloc.h.
20344
20345 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
20346
20347         * modules/gettext (Files): config/config.rpath ->
20348         build-aux/config.rpath
20349         * modules/iconv (Files): Likewise.
20350         Problem reported by Oskar Liljeblad.
20351
20352 2005-03-23  Jim Meyering  <jim@meyering.net>
20353
20354         * modules/check-include-files: New script to check for
20355         missing dependencies, multiple includes, etc.
20356
20357         * modules/c-strtold (Depends-on): Add xalloc.
20358         * modules/c-strtod (Depends-on): Add xalloc.
20359         * modules/hash (Depends-on): Add xalloc.
20360         (Files): Remove lib/xalloc.h.
20361
20362         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
20363         * modules/userspec (Files): Add lib/inttostr.h.
20364
20365 2005-03-23  Jim Meyering  <jim@meyering.net>
20366
20367         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
20368
20369 2005-03-22  Jim Meyering  <jim@meyering.net>
20370
20371         * modules/stat-macros: New module.
20372         * modules/canonicalize, modules/euidaccess, modules/file-type,
20373         * modules/filemode, modules/lchown, modules/makepath,
20374         * modules/rmdir, modules/stat: Depend on new stat-macros module
20375         rather than listing lib/stat-macros.h manually.
20376         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
20377
20378 2005-03-22  Jim Meyering  <jim@meyering.net>
20379
20380         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
20381
20382 2005-03-22  Bruno Haible  <bruno@clisp.org>
20383
20384         * config/srclist.txt: Replace target directory 'config' with
20385         'build-aux'.
20386         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
20387         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
20388         ../build-aux/.
20389
20390 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
20391
20392         * modules/chdir-long (Depends-on): Add mempcpy.
20393
20394         * modules/acl, modules/backupfile, modules/c-strtod,
20395         modules/c-strtold, modules/canon-host, modules/canonicalize,
20396         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
20397         modules/exclude, modules/exitfail, modules/file-type,
20398         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
20399         modules/getdate, modules/getline, modules/getpagesize,
20400         modules/getpass, modules/getugroups, modules/group-member,
20401         modules/hard-locale, modules/hash, modules/human, modules/idcache,
20402         modules/inttostr, modules/long-options, modules/makepath,
20403         modules/md5, modules/memcasecmp, modules/memcoll,
20404         modules/modechange, modules/mountlist, modules/path-concat,
20405         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
20406         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
20407         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
20408         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
20409         modules/strftime, modules/strndup, modules/strverscmp,
20410         modules/timespec, modules/unlocked-io, modules/userspec,
20411         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
20412         modules/yesno:
20413         Remove lib_SOURCES line from Makefile.am section, as this is now
20414         done automatically by the corresponding Autoconf macro.
20415
20416 2005-03-21  Jim Meyering  <jim@meyering.net>
20417
20418         Changes imported from coreutils.
20419
20420         * lib/cycle-check.c: Don't include xalloc.h.
20421
20422         * lib/path-concat.c: Don't include assert.h.
20423         (path_concat): Remove assertion that would have triggered
20424         for ABASE starting with more than one slash.
20425         Reported by Andreas Schwab.
20426
20427         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
20428         properly when ABASE is an absolute file name.
20429         Correct the description of this function.
20430         Include <assert.h>.
20431         Add an assertion and a test driver.
20432         This fixes a bug introduced on 2004-07-02.
20433         Andreas Schwab reported the resulting failure of cp --parents:
20434         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
20435
20436 2005-03-21  Jim Meyering  <jim@meyering.net>
20437
20438         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
20439         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
20440
20441 2005-03-21  Jim Meyering  <jim@meyering.net>
20442         and  Paul Eggert  <eggert@cs.ucla.edu>
20443
20444         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
20445         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
20446         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
20447         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
20448         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
20449         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
20450         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
20451         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
20452         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
20453         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
20454         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
20455         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
20456         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
20457         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
20458         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
20459         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
20460         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
20461         for these modules.
20462
20463 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
20464
20465         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
20466         (which shouldn't happen), generate nothing instead of returning 0
20467         immediately, so that nstrftime (NULL, ...) doesn't return 0.
20468
20469 2005-03-16  Bruno Haible  <bruno@clisp.org>
20470
20471         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
20472         HAVE_LONGLONG_64BIT.
20473
20474 2005-03-16  Bruno Haible  <bruno@clisp.org>
20475
20476         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
20477         HAVE_LONGLONG_64BIT.
20478
20479 2005-03-16  Bruno Haible  <bruno@clisp.org>
20480
20481         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
20482         HAVE_LONGLONG_64BIT.
20483
20484 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
20485
20486         * lib/strftime.c (my_strftime): Prepend space to format so that we can
20487         reliably distinguish strftime failure from empty output on POSIX
20488         hosts.
20489
20490 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
20491
20492         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
20493         (iconv_string): Don't guess a size-zero buffer, as that might cause
20494         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
20495         result would be 'too large', where 'too large' is (heuristically)
20496         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
20497         overflow concerns.  This will prevent some unwanted malloc failures
20498         when the inputs are very large.
20499
20500 2005-03-15  Karl Berry  <karl@gnu.org>
20501
20502         * config/srclist.txt (config.rpath): from gettext.
20503         * config/config.rpath: update.
20504
20505 2005-03-15  Bruno Haible  <bruno@clisp.org>
20506
20507         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
20508         to 'negate'.
20509
20510         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
20511         variable.
20512
20513         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
20514         results.
20515
20516 2005-03-14  Simon Josefsson  <jas@extundo.com>
20517
20518         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
20519         <fx@gnu.org>.
20520
20521 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
20522
20523         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
20524         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
20525         intprops.h.
20526         * lib/strtol.c: Likewise.
20527
20528 2005-03-14  Jim Meyering  <jim@meyering.net>
20529
20530         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
20531         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
20532         to be nonzero so that we (and caller) can detect the difference
20533         between a valid zero-length expansion and an error return, even
20534         when the underlying strftime fails before writing anything into
20535         that location.
20536
20537 2005-03-14  Bruno Haible  <bruno@clisp.org>
20538
20539         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
20540         Update from GNU gettext 0.14.3.
20541
20542 2005-03-10  Jim Meyering  <jim@meyering.net>
20543
20544         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
20545
20546 2005-03-10  Jim Meyering  <jim@meyering.net>
20547
20548         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
20549         so that this module works on systems without fchdir.
20550
20551 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
20552
20553         Factor int-properties macros into a single file, except for
20554         glibc-related files.
20555         * lib/intprops.h: New file.
20556         * lib/getloadavg.c: Include it instead of limits.h.
20557         (INT_STRLEN_BOUND): Remove.
20558         * lib/human.c: Include intprops.h.
20559         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
20560         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
20561         302/1000.
20562         * lib/inttostr.h: Include intprops.h instead of limits.h.
20563         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
20564         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
20565         for consistency with intprops.h.
20566         (time_t_is_integer, twos_complement_arithmetic): Use them.
20567         * lib/sig2str.h: Include <signal.h>, intprops.h.
20568         (INT_STRLEN_BOUND): Remove.
20569         * lib/strftime.c (TYPE_SIGNED): Remove.
20570         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
20571         * lib/strtol.c: Adjust comments to match intprops.h.
20572         * lib/userspec.c: Include intprops.h.
20573         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
20574         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
20575         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
20576         instead of rolling our own expressions.
20577         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
20578
20579         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
20580         instead of int.
20581         (my_strftime): Do not mishandle years close to INT_MAX, by doing
20582         the right thing even if adding 1900 would overflow.  Similarly
20583         for tm_mon + 1 and tm_yday + 1.
20584         Make %Y always equivalent to %C%y, and similarly for %G and %g.
20585         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
20586         (DO_SIGNED_NUMBER): New macro.
20587         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
20588
20589 2005-03-07  Bruno Haible  <bruno@clisp.org>
20590
20591         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
20592
20593 2005-03-07  Bruno Haible  <bruno@clisp.org>
20594
20595         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
20596
20597 2005-03-04  Derek R. Price  <derek@ximbiot.com>
20598
20599         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
20600         (func_import): Only replace files via --import when they have actually
20601         changed.
20602
20603 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20604
20605         * m4/mmap-anon.m4: New file.
20606         * m4/pagealign_alloc.m4: New file.
20607
20608 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20609             Bruno Haible  <bruno@clisp.org>
20610
20611         * modules/pagealign_alloc: New file.
20612         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
20613
20614 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20615             Bruno Haible  <bruno@clisp.org>
20616
20617         * lib/pagealign_alloc.h: New file.
20618         * lib/pagealign_alloc.c: New file.
20619
20620 2005-03-03  Bruno Haible  <bruno@clisp.org>
20621
20622         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
20623         Use an all-permissive copyright notice, recommended by RMS.
20624
20625 2005-03-02  Bruno Haible  <bruno@clisp.org>
20626
20627         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
20628         of AIX, the replacement has to be done only after <string.h> is
20629         included, therefore not in config.h. stpncpy.h does the replacement,
20630         and stpncpy.c uses it.
20631
20632 2005-03-02  Bruno Haible  <bruno@clisp.org>
20633
20634         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
20635         stpncpy.c uses it.
20636
20637 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20638
20639         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
20640         The workaround isn't strictly needed for POSIX conformance, and
20641         it's too much of a pain to configure and maintain.  We'll ask
20642         people to fix their kernels instead.
20643         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
20644         (NANOSLEEP_BUG_WORKAROUND): Remove.
20645         (xnanosleep): Remove the workaround.
20646
20647 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20648
20649         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
20650         Reported by Derek Price.
20651         (Include): Add "timespec.h".
20652
20653         * modules/xnanosleep (Depends-on): Remove gethrxtime.
20654
20655 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20656
20657         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
20658         to detect nanosleep bug.
20659
20660 2005-03-01  Bruno Haible  <bruno@clisp.org>
20661
20662         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
20663
20664 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
20665
20666         * modules/gethrxtime: New file.
20667         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
20668         (Depends-on): Add gethrxtime.
20669         (configure.ac): Add gl_XNANOSLEEP.
20670         (Makefile.am): Remove lib_SOURCES line.
20671
20672 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
20673
20674         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
20675         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
20676
20677 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
20678
20679         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
20680         * lib/timespec.h (gettime): Return void, since it always
20681         succeeds now.  All uses changed.
20682         * lib/gettime.c (gettime) Likewise.
20683         [HAVE_NANOTIME]: Prefer nanotime.
20684         Assume gettimeofday succeeds, as POSIX requires.
20685         Assime time () succeeds, since other code already does.
20686         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
20687         (timespec_subtract): Remove.
20688         (NANOSLEEP_BUG_WORKAROUND): New constant.
20689         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
20690         things considerably.  Use it only on GNU/Linux hosts, since the
20691         workaround shouldn't be needed elsewhere.
20692
20693 2005-02-24  Bruno Haible  <bruno@clisp.org>
20694
20695         * modules/gettext (Files): Add m4/glibc2.m4.
20696
20697 2005-02-24  Bruno Haible  <bruno@clisp.org>
20698
20699         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
20700         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
20701         * m4/progtest.m4:
20702         Update from GNU gettext 0.14.2.
20703         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
20704
20705 2005-02-24  Bruno Haible  <bruno@clisp.org>
20706
20707         * lib/localcharset.c: Update from GNU gettext 0.14.2.
20708         * lib/config.charset: Update from GNU gettext 0.14.2.
20709
20710 2005-02-24  Bruno Haible  <bruno@clisp.org>
20711
20712         * lib/gettext.h: Update from GNU gettext 0.14.2.
20713
20714 2005-02-23  Simon Josefsson  <jas@extundo.com>
20715
20716         * m4/iconvme.m4: New file.
20717
20718 2005-02-23  Jim Meyering  <jim@meyering.net>
20719
20720         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
20721         change.
20722         Thanks to Bruno Haible for catching it.
20723
20724 2005-02-22  Simon Josefsson  <jas@extundo.com>
20725
20726         * modules/iconvme: New file.
20727
20728         * MODULES.html.sh: Add iconvme.
20729
20730 2005-02-22  Simon Josefsson  <jas@extundo.com>
20731
20732         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
20733
20734 2005-02-22  Simon Josefsson  <jas@extundo.com>
20735
20736         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
20737
20738 2005-02-22  Jim Meyering  <jim@meyering.net>
20739
20740         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
20741         s/ifndef/ifdef/.
20742
20743 2005-02-20  Neil Conway  <neilc@samurai.com>
20744
20745         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
20746         returned by OSX/Darwin if the specified buffer is not large
20747         enough for the hostname.
20748
20749 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20750
20751         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
20752         pass it to _help, otherwise the latter coredumps trying to
20753         dereference state.root_argp.
20754
20755 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20756
20757         * modules/chdir-long (Depends-on): Add memrchr.
20758         * modules/memrchr (Files): Add lib/memrchr.h.
20759         (Include): "memrchr.h".
20760
20761 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20762
20763         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
20764
20765 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20766
20767         * lib/memrchr.h: New file.
20768         * lib/chdir-long.c: Include it.
20769         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
20770         Don't bother including stddef.h.
20771
20772 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
20773
20774         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
20775         inclusion.
20776         Include <sys/types.h>, for dev_t.
20777         (ME_DUMMY, ME_REMOTE): Move from here....
20778         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
20779         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
20780         Dmitry V. Levin.
20781         Include mountlist.h first, to test the interface.
20782
20783 2005-01-29  Bruno Haible  <bruno@clisp.org>
20784
20785         * lib/progname.c (program_name): Initialize.
20786         Needed when linking statically on MacOS X.
20787
20788 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
20789
20790         Sync from coreutils.
20791         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
20792         (Depends-on): Add c-strtod.
20793         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
20794
20795 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
20796
20797         Sync from coreutils.
20798         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
20799
20800         Remove files that are specific to coreutils.
20801         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
20802
20803 2005-01-28  Bruno Haible  <bruno@clisp.org>
20804
20805         * modules/javacomp: New file.
20806         * MODULES.html.sh (Java): Add javacomp.
20807
20808 2005-01-28  Bruno Haible  <bruno@clisp.org>
20809
20810         * m4/javacomp.m4: New file, from GNU gettext.
20811
20812 2005-01-28  Bruno Haible  <bruno@clisp.org>
20813
20814         * lib/javacomp.sh.in: New file, from GNU gettext.
20815         * lib/javacomp.h: New file, from GNU gettext.
20816         * lib/javacomp.c: New file, from GNU gettext.
20817
20818 2005-01-26  Simon Josefsson  <jas@extundo.com>
20819
20820         * lib/gai_strerror.c: Use GPL in header.
20821
20822 2005-01-26  Bruno Haible  <bruno@clisp.org>
20823
20824         * modules/javaexec: New file.
20825         * MODULES.html.sh (Java): Add javaexec.
20826
20827 2005-01-26  Bruno Haible  <bruno@clisp.org>
20828
20829         * m4/javaexec.m4: New file, from GNU gettext.
20830
20831 2005-01-26  Bruno Haible  <bruno@clisp.org>
20832
20833         * lib/javaexec.sh.in: New file, from GNU gettext.
20834         * lib/javaexec.h: New file, from GNU gettext.
20835         * lib/javaexec.c: New file, from GNU gettext.
20836
20837 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20838
20839         * modules/lchown (Depends-on): Remove lchown.h
20840
20841 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20842
20843         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
20844         must be defined if the header file was not found, in order
20845         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
20846
20847 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20848
20849         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
20850         initializers for struct pentry_state.
20851         (__argp_error): Check return value of __asprintf
20852         (__argp_failure): Translate error message
20853
20854         * lib/argp-parse.c: Removed braces around the expansion of N_()
20855
20856 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
20857
20858         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
20859         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
20860         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
20861         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
20862         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
20863         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
20864         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
20865         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
20866         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
20867         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
20868         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
20869         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
20870         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
20871         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
20872         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
20873         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
20874         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
20875         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
20876         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
20877         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
20878         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
20879         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
20880         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
20881         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
20882         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
20883         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
20884         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
20885         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
20886         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
20887         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
20888         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
20889         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
20890         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
20891         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
20892         xstrtol.m4, xstrtoumax.m4, yesno.m4:
20893         Use an all-permissive copyright notice, recommended by RMS.
20894
20895 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
20896
20897         * modules/chdir-long (Depends-on): Remove mempcpy.
20898
20899 2005-01-21  Jim Meyering  <jim@meyering.net>
20900
20901         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
20902         same value as for Solaris 9.
20903
20904         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
20905         component length.  This included changing the parameter to be
20906         of type `char *' rather than `char const *'.
20907         * lib/chdir-long.h (chdir_long): Update prototype.
20908
20909         * lib/openat.c (fdopendir, fstatat): New functions.
20910         * lib/openat.h: Include headers required for use of DIR and struct
20911         stat.
20912         [AT_SYMLINK_NOFOLLOW]: Define.
20913         (fdopendir, fstatat): Add prototypes.
20914
20915 2005-01-21  Bruno Haible  <bruno@clisp.org>
20916
20917         * modules/classpath: New file.
20918         * MODULES.html.sh (Java): Add classpath.
20919
20920 2005-01-21  Bruno Haible  <bruno@clisp.org>
20921
20922         * lib/classpath.h: New file, from GNU gettext.
20923         * lib/classpath.c: New file, from GNU gettext.
20924
20925 2005-01-20  Simon Josefsson  <jas@extundo.com>
20926
20927         * modules/version-etc-fsf: New file.
20928
20929 2005-01-20  Simon Josefsson  <jas@extundo.com>
20930
20931         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
20932         * lib/version-etc.c: Remove version_etc_copyright.
20933         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
20934         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
20935
20936 2005-01-20  Simon Josefsson  <jas@extundo.com>
20937
20938         * lib/base64.h (isbase64): Add.
20939
20940         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
20941         using a unsigned prototype, don't inline.
20942         (base64_decode): Use it.
20943
20944 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
20945
20946         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
20947         it.
20948
20949 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
20950
20951         * lib/save-cwd.c (save_cwd): Remove code to support the case
20952         where fchdir is missing or flaky.
20953
20954 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
20955
20956         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
20957
20958 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
20959
20960         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
20961         AC_LIBSOURCES now does this.
20962         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
20963         with new ullong_max module.
20964
20965 2005-01-19  Bruno Haible  <bruno@clisp.org>
20966
20967         * modules/sh-quote: New file.
20968         * MODULES.html.sh (Executing programs): Add sh-quote.
20969
20970 2005-01-19  Bruno Haible  <bruno@clisp.org>
20971
20972         * lib/sh-quote.h: New file, from GNU gettext.
20973         * lib/sh-quote.c: New file, from GNU gettext.
20974
20975 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
20976
20977         Merge from coreutils.
20978         * m4/ullong_max.m4: New file.
20979         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
20980         (gl_MACROS): Assume localeconv exists.
20981
20982 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
20983
20984         Merge changes from coreutils, as described below in several
20985         changelogs dated today.
20986
20987         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
20988         (O_DIRECTORY): Remove; not needed here, since "." must be
20989         a directory.  All uses removed.
20990         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
20991         universal on Suns, and we also need to test for IRIX.
20992         Revamp code to use 'if' rather than '#if'.
20993         Avoid unnecessary comparison of cwd->desc to 0.
20994
20995         * lib/utimens.c (futimens): Robustify the previous patch, by checking
20996         for known valid error numbers rather than observed invalid ones.
20997
20998 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
20999
21000         * modules/ullong_max: New file.
21001
21002         * modules/chdir-long, modules/openat: New files.
21003         * modules/save-cwd (Depends-on): Depend on chdir-long.
21004         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
21005
21006 2005-01-18  Jim Meyering  <jim@meyering.net>
21007
21008         Merge from coreutils.
21009         * m4/chdir-long.m4, m4/openat.m4: New files.
21010         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
21011         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
21012         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
21013         is sane and DOES follow symlinks.  Besides, testing 20 different
21014         systems found no broken chown implementations.
21015         Prompted by a change in rsync's copy of this macro.
21016         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
21017
21018         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
21019
21020         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
21021         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
21022         NULL-means-set-to-current-time semantics.
21023         Remove temporary file immediately, rather than waiting
21024         for configure's at-exit trap code to do it.
21025
21026 2005-01-18  Jim Meyering  <jim@meyering.net>
21027
21028         * lib/version-etc.c (version_etc_copyright): Update copyright date.
21029
21030         * lib/utimens.c (futimens): Account for the fact that futimes
21031         can also fail with errno == ENOSYS or errno == ENOENT.
21032         Patch from Dmitry V. Levin.
21033
21034         Change the name of the robust chdir function from chdir to chdir_long.
21035         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
21036         (restore_cwd): Use chdir_long, not chdir.
21037         * lib/chdir-long.c: Renamed from chdir.c.
21038         * lib/chdir-long.h: Renamed from chdir.h.
21039         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
21040         Hurd.
21041
21042 2005-01-18  Bruno Haible  <bruno@clisp.org>
21043
21044         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
21045         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
21046         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
21047         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
21048         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
21049         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
21050         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
21051         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
21052         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
21053         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
21054         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
21055         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
21056         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
21057         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
21058         Use an all-permissive copyright notice, recommended by RMS.
21059
21060 2005-01-18  Bob Proulx  <bob@proulx.com>
21061
21062         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
21063         simplify offsetof() macro construct to avoid compile failure with
21064         native HP-UX 11.0 ANSI C compiler.
21065
21066 2005-01-17  Bruno Haible  <bruno@clisp.org>
21067
21068         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
21069         redundant because stpncpy.m4 takes care of it.
21070
21071 2005-01-17  Bruno Haible  <bruno@clisp.org>
21072
21073         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
21074
21075 2005-01-17  Bruno Haible  <bruno@clisp.org>
21076
21077         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
21078         used.
21079
21080 2005-01-17  Bruno Haible  <bruno@clisp.org>
21081
21082         * lib/fwriteerror.h (fwriteerror): Change specification to include
21083         fclose.
21084         * lib/fwriteerror.c: Include <stdbool.h>.
21085         (fwriteerror): At the end, close the file stream. Record whether
21086         stdout was already closed.
21087
21088 2005-01-17  Bruno Haible  <bruno@clisp.org>
21089
21090         * lib/execute.c (environ): Declare if needed.
21091         * lib/pipe.c (environ): Likewise.
21092         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
21093
21094 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21095
21096         * modules/argp: Depend on vsnprintf
21097
21098 2005-01-10  Jim Meyering  <jim@meyering.net>
21099
21100         * modules/closeout (Depends-on): Add atexit.
21101
21102 2005-01-06  Bruno Haible  <bruno@clisp.org>
21103
21104         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
21105
21106 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
21107
21108         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
21109         definitions to be after all include files, to avoid collisions.
21110         Problem reported by Bob Proulx.
21111
21112 2005-01-04  Jim Meyering  <jim@meyering.net>
21113
21114         Changes imported from coreutils.
21115         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
21116         as the mkstemp template, use a temporary directory and an
21117         8.3-friendly template to avoid trouble on systems like DJGPP.
21118         Reported by Juan M. Guerrero via Stepan Kasal.
21119         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
21120         close. Remove the temporary directory right away, rather than waiting
21121         for configure's at-exit trap code to do it.
21122         Suggestion from Stepan Kasal.
21123
21124 2005-01-01  Simon Josefsson  <jas@extundo.com>
21125
21126         * gnulib-tool: Print #include directives when --import'ing.
21127
21128 2004-12-28  Simon Josefsson  <jas@extundo.com>
21129
21130         * tests/test-base64.c: Include required header files.  Remove
21131         unused variables.
21132
21133 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
21134
21135         * modules/error (Depends-on): Remove gettext.
21136
21137 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
21138
21139         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
21140         not needed.  This removes a dependency on the gettext module.
21141         [defined _LIBC]: Do not include <libintl.h>; not needed.
21142
21143 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
21144
21145         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
21146         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
21147
21148 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
21149
21150         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
21151         HAVE_DECL_STRTOLD.
21152
21153 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
21154
21155         * modules/getdate (Depends-on): Remove alloca-opt.
21156
21157 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
21158
21159         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
21160
21161 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
21162
21163         * lib/argp-parse.c: Include <stddef.h>.
21164         (alignof, alignto): New macros.
21165         (parser_init): Don't assume that void * is aligned sufficiently
21166         for struct option.
21167
21168         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
21169         need to extend the stack.
21170         (YYINITDEPTH): New macro, so that the initial stack isn't overly
21171         large.
21172
21173 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21174
21175         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
21176
21177 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
21178
21179         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
21180         (2004-10-24) change.  Apparently this was a false alarm.
21181
21182         * modules/getdate: Depend on alloca-opt, not alloca.
21183
21184 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
21185
21186         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
21187         Remove now-obsolete comment about AIX.
21188         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
21189         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
21190         (YYMAXDEPTH): New macro.
21191
21192 2004-12-18  Simon Josefsson  <jas@extundo.com>
21193
21194         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
21195
21196 2004-12-18  Bruno Haible  <bruno@clisp.org>
21197
21198         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
21199
21200 2004-12-18  Bruno Haible  <bruno@clisp.org>
21201
21202         * lib/fatal-signal.c (fatal_signals): Make non-const.
21203         (init_fatal_signals): New function.
21204         (uninstall_handlers, install_handlers): Ignore signals that were set to
21205         SIG_IGN.
21206         (at_fatal_signal): Call init_fatal_signals.
21207         (init_fatal_signal_set): Likewise. Ignore signals that were set to
21208         SIG_IGN.
21209         Reported by Paul Eggert.
21210
21211 2004-12-18  Bruno Haible  <bruno@clisp.org>
21212
21213         * doc/alloca.texi: New file.
21214         * doc/alloca-opt.texi: New file.
21215
21216 2004-12-17  Jim Meyering  <jim@meyering.net>
21217
21218         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
21219         Otherwise, install-sh could exit with improper exit status when
21220         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
21221
21222 2004-12-16  Simon Josefsson  <jas@extundo.com>
21223
21224         * tests/test-base64.c: Add license.
21225
21226 2004-12-15  Stepan Kasal  <address@hidden>
21227
21228         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
21229
21230 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
21231
21232         * modules/getcwd (Files): Add m4/d-ino.m4.
21233         Suggested by Mark D. Baushke.
21234
21235 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
21236
21237         * lib/getdate.y (textint): New member "negative".
21238         (time_zone_hhmm): New function.
21239         Expect 14 shift-reduce conflicts, not 13.
21240         (o_colon_minutes): New rule.
21241         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
21242         (yylex): Set the "negative" member of signed numbers.
21243
21244 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
21245
21246         * doc/getdate.texi (Time of day items, Time zone items):
21247         Describe new formats +00:00, UTC+00:00.
21248
21249 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
21250
21251         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
21252         spurious "-l"s.  Problem reported by Stepan Kasal.
21253
21254 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
21255
21256         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
21257         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
21258
21259 2004-12-04  Simon Josefsson  <jas@extundo.com>
21260
21261         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
21262         Vandoorselaere <yoann@prelude-ids.org>.
21263
21264 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
21265
21266         Changes imported from coreutils.
21267         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
21268         exist.
21269         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
21270
21271 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
21272
21273         Changes imported from coreutils.
21274         * lib/hard-locale.c: Assume <locale.h> exists.
21275         Include "strdup.h".
21276         (GLIBC_VERSION): New macro.
21277         (hard_locale): Assume setlocale exists.
21278         Rewrite to avoid #ifdef.
21279         Use strdup rather than malloc + strcpy.
21280         * lib/human.c: Assume <locale.h> exists.
21281         (human_readable): Assume localeconv exists.
21282
21283 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
21284
21285         * modules/hard-locale (Depends-on): Add strdup.
21286
21287 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
21288
21289         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
21290         convert T2, not T.  (Imported from libc.)
21291
21292 2004-11-30  Simon Josefsson  <jas@extundo.com>
21293
21294         * modules/restrict (License): Change to LGPL.
21295
21296 2004-11-30  Simon Josefsson  <jas@extundo.com>
21297
21298         * m4/restrict.m4: Add copyright and copying conditions.
21299
21300 2004-11-30  Simon Josefsson  <jas@extundo.com>
21301
21302         * m4/base64.m4: New file.
21303
21304 2004-11-30  Simon Josefsson  <jas@extundo.com>
21305
21306         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
21307         base64.
21308
21309         * tests/test-base64.c: New file.
21310
21311         * modules/base64: New file.
21312
21313 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
21314
21315         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
21316         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
21317
21318         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
21319
21320 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
21321
21322         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
21323         (__getcwd.c): Don't restore errno; glibc doesn't.
21324         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
21325         first, falling back to our code only if its results look suspicious.
21326         Ensure that the resulting buffer is only as large as necessary.
21327
21328         * lib/readutmp.c: Include readutmp.h first.
21329         Include <errno.h>, since readutmp.h no longer does that.
21330         * lib/readutmp.h: Don't include <errno.h>,
21331         <sys/param.h>, <time.h>; not needed to establish interface.
21332         (errno): Remove decl.
21333         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
21334         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
21335         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
21336
21337 2004-11-28  Simon Josefsson  <jas@extundo.com>
21338
21339         * lib/base64.h, base64.c: New file.
21340
21341 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
21342
21343         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
21344
21345 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
21346
21347         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
21348         (Depends-on): Remove pathmax, same.  Add mempcpy.
21349         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
21350         (Makefile.am): Append getcwd.h to lib_SOURCES.
21351         (Include): Add getcwd.h.
21352         (Maintainer): Change from Jim Meyering to "all, glibc",
21353         since getdate now uses intended-for-glibc code.
21354         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
21355         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
21356
21357 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
21358
21359         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
21360         HP's ANSI C compiler.
21361         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
21362         Declaring int functions causes warnings on some modern systems and
21363         shouldn't be needed to compile on ancient ones.
21364         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
21365         defined.
21366
21367         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
21368         with the following changes.
21369         (__set_errno): Parenthesize properly.
21370         Include <stdbool.h>.
21371         (MIN, MAX, MATCHING_INO): New macros.
21372         (__getcwd): Define with prototype, not K&R form.
21373         Use heuristics to allocate default buffer on stack if possible.
21374         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
21375         behavior, and to avoid the PATH_MAX limit when computing
21376         ../../../../...
21377         Use MATCHING_INO to compare inode number to file.
21378         Check for arithmetic overflow in size calculations.
21379         Fix bug in reallocation of dot array that caused getcwd to fail
21380         on directories nested deeper than 75.
21381         Be more careful about saving errno on error.
21382         Do not use realloc; use only free+malloc, as this is a bit
21383         more flexible and avoids a needless copy operation.
21384         Do not inspect st_dev and st_ino for symbolic links; POSIX
21385         doesn't specify the latter.
21386         Check for closedir errors.
21387         Avoid needless casts.
21388         Use "#ifdef weak_alias" around weak_alias, to be like other
21389         glibc code.
21390         The following changes to getcwd.c have effect only when used in
21391         gnulib; they have no effect inside glibc proper.
21392         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
21393         as alloca isn't used.
21394         (alloca, __alloca): Likewise.
21395         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
21396         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
21397         unconditionally, as gnulib assumes C89 or better.
21398         Do not include <sys/param.h>.
21399         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
21400         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
21401         better.
21402         (NULL) [!defined NULL]: Remove; we assume C89 or better.
21403         Include <dirent.h> in a way that is compatible with modern Autoconf.
21404         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
21405         New macros, if not already defined.
21406         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
21407         Use "_LIBC", not "defined _LIBC", for consistency.
21408         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
21409         a mempcpy module.
21410         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
21411         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
21412         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
21413         credit only to Jim Meyering and adjust the copyright dates.
21414         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
21415         <stdlib.h>, <unistd.h>, "pathmax.h".
21416         Instead, include "xgetcwd.h" (first) and "getcwd.h".
21417         (INITIAL_BUFFER_SIZE): Remove.
21418         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
21419
21420 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
21421
21422         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
21423         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
21424         Use the _ONCE methods, for efficiency.
21425         Check for fcntl.h.  In test program, include <errno.h>
21426         and <fcntl.h> if available.  Remove old K&R cruft from
21427         test program.  Check for common errors in GNU/Linux,
21428         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
21429         don't do AC_LIBOBJ, as that's getcwd.m4's job.
21430         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
21431         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
21432         name accordingly.
21433         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
21434         accommodate new getcwd.c.
21435         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
21436         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
21437         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
21438         that's all we need now.
21439
21440 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21441
21442         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
21443         argp-parse.c depends on getopt internals, that means we should
21444         always use our getopt, to be on the safe side.
21445         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
21446         order not to spoil the result of an eventual previous invocation
21447         of gl_GETOPT_SUBSTITUTE.
21448
21449 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21450
21451         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
21452         redefinition warnings. To avoid them, include the defines
21453         in `#if !defined __need_getopt ... #endif'. The only place
21454         where __getopt_argv_const is used is in definitions
21455         of getopt_long and getopt_long_only below, which are as well
21456         protected by `#ifndef __need_getopt'.
21457         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
21458         __need_getopt after including <stdio.h> and <unistd.h> These
21459         headers might have defined it.
21460
21461 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
21462
21463         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
21464
21465 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
21466
21467         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
21468         (futimens): New function, which uses futimes if available.
21469         (futimens, utimens): Support timespec==NULL, with same semantics
21470         as utime and utimens.
21471         * lib/utimens.h (futimens): New decl.
21472
21473 2004-11-23  Jim Meyering  <jim@meyering.net>
21474
21475         * lib/getopt_.h: Remove trailing blanks.
21476
21477 2004-11-23  Jim Meyering  <jim@meyering.net>
21478
21479         * lib/__fpending.c: Add comment.
21480
21481 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
21482
21483         * modules/canonicalize (Depends-on): Add xreadlink.
21484         Problem reported by James Youngman.
21485
21486 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
21487
21488         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
21489         New macros.
21490         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
21491         optopt): Use them instead of invoking ## directly; otherwise, the
21492         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
21493
21494 2004-11-19  Bruno Haible  <bruno@clisp.org>
21495
21496         * lib/strtok_r.c: Move comments from here...
21497         * lib/strtok_r.h: ... to here.
21498
21499 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
21500
21501         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
21502         implementations that mishandle size_t overflow.
21503
21504 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
21505
21506         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
21507         might fail.  Problem reported by Yoann Vandoorselaere.
21508         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
21509         implementations that mishandle size_t overflow.
21510
21511 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21512
21513         * modules/canon-host (Depends-on): Add strdup.
21514
21515 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21516
21517         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
21518
21519 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21520
21521         * lib/canon-host.c: Include "strdup.h".
21522         (canon_host): Use getaddrinfo if available, so that IPv6 works.
21523         Use strdup instead of malloc/strcpy to duplicate strings.
21524
21525         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
21526         (human_space_before_unit): New constant.
21527         * lib/human.c (human_readable): Support it.
21528
21529         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
21530         (xgetcwd): Set errno correctly when failing.
21531         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
21532         the failure is actually due to a PATH_MAX problem.
21533
21534         Further getopt changes to make it more likely that glibc will
21535         buy the changes back.
21536         * lib/getopt.c (POSIXLY_CORRECT): New constant.
21537         (getopt): Use it, so to preserve glibc semantic
21538         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
21539         when compiling for libc.
21540         * lib/getopt_.h (__getopt_argv_const): Bring it back.
21541         (getopt_long, getopt_long_only): Use it.
21542
21543         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
21544         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
21545         (getopt): Argv is now char * const *, as per standard.
21546         (_getopt_internal_r, _getopt_internal): Argv is now char **,
21547         not char *__getopt_argv_const *.
21548         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
21549         _getopt_long_only_r): Likewise.
21550         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
21551         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
21552         _getopt_long_r, _getopt_long_only_r): Likewise.
21553         * lib/getopt_.h (__getopt_argv_const): Remove.
21554         (getopt): Argv is now char * const *, as per standard.
21555
21556         * lib/getdate.y (tORDINAL): New token.
21557         (day, relunit): Allow it for relative times.
21558         (relative_time_table): Use tORDINAL for ordinals.
21559
21560 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21561
21562         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
21563         Document that "second" isn't allowed as an ordinal number.
21564
21565 2004-11-16  Jim Meyering  <jim@meyering.net>
21566
21567         * modules/closeout (Depends-on): Add fpending.
21568
21569 2004-11-15  Jim Meyering  <jim@meyering.net>
21570
21571         * lib/closeout.c: Include "__fpending.h" once again.
21572         Include <stdbool.h>.
21573         (close_stdout): Don't fail just because stdout was closed initially,
21574         since some programs don't write to stdout in the normal course of
21575         operation (other than --version and --help), and we don't want this
21576         function to make e.g. `touch file >&-' fail.
21577         But do fail if it was closed and someone has tried to write to it.
21578         E.g., `printf foo >&-' must fail.
21579
21580 2004-11-13  Jim Meyering  <jim@meyering.net>
21581
21582         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
21583
21584 2004-11-12  Simon Josefsson  <jas@extundo.com>
21585
21586         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
21587         small doc fix is still pending.
21588
21589 2004-11-11  Simon Josefsson  <jas@extundo.com>
21590
21591         * modules/strtok_r: New file.
21592
21593         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21594         strtok_r.
21595
21596 2004-11-11  Simon Josefsson  <jas@extundo.com>
21597
21598         * m4/strtok_r.m4: New file.
21599
21600         * m4/getopt.m4: Replace opterr.
21601
21602 2004-11-11  Simon Josefsson  <jas@extundo.com>
21603
21604         * lib/strtok_r.h, strtok_r.c: New file.
21605
21606 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
21607
21608         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
21609         of replacing opterr, getopt, etc.  This should handle the
21610         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
21611
21612 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
21613
21614         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
21615         we can stop lying to compilers about the constness of argv when we
21616         are compiled outside glibc.
21617         (getopt, getopt_long, getopt_long_only): Use it.
21618         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
21619         _getopt_internal, getopt): Likewise.
21620         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
21621         _getopt_long_only_r): Likewise.
21622         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
21623         _getopt_long_r, _getopt_long_only_r): Likewise.
21624
21625         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
21626         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
21627         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
21628         the other external symbols.
21629         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
21630         declaration, since the above renaming now works around collisions.
21631
21632 2004-11-11  Jim Meyering  <jim@meyering.net>
21633
21634         * lib/linebreak.c: Remove trailing blanks.
21635         * lib/alloca_.h: Likewise.
21636         * lib/acosl.c: Likewise.
21637         * lib/euidaccess.c: Likewise.
21638         * lib/allocsa.h: Likewise.
21639
21640 2004-11-10  Simon Josefsson  <jas@extundo.com>
21641
21642         * m4/getaddrinfo.m4: New file.
21643
21644 2004-11-10  Simon Josefsson  <jas@extundo.com>
21645
21646         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
21647
21648 2004-11-10  Simon Josefsson  <jas@extundo.com>
21649
21650         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21651         getaddrinfo.
21652
21653         * modules/getaddrinfo: New file.
21654
21655 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
21656
21657         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
21658
21659 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
21660
21661         * lib/mktime.c (SHR): New macro, which is a portable
21662         substitute for >> that should work even on Crays.
21663         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
21664         Problem reported by Mark D. Baushke in
21665         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
21666         * lib/getdate.y (SHR): Likewise.
21667         (tm_diff): Use it.
21668         * lib/strftime.c (SHR): Likewise.
21669         (tm_diff): Use it.
21670         * lib/quotearg.c (struct quoting_options): Use unsigned int for
21671         quote_these_too, so that right shifts are well defined.  All uses
21672         changed.
21673
21674 2004-11-10  Jim Meyering  <jim@meyering.net>
21675
21676         Ensure that no close failure goes unreported.
21677         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
21678         return early when it seems there's nothing to flush.
21679         Don't include __fpending.h.
21680
21681 2004-11-10  Jim Meyering  <jim@meyering.net>
21682
21683         * modules/closeout (Depends-on): Remove fpending.
21684
21685 2004-11-10  Jim Meyering  <jim@meyering.net>
21686
21687         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
21688
21689 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
21690
21691         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
21692         gl_FUNC_STRFTIME.
21693         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
21694         and AC_REQUIRE when possible, to avoid duplicate checks.
21695         Check for <wchar.h>.
21696
21697 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
21698
21699         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
21700
21701 2004-11-09  Bruno Haible  <bruno@clisp.org>
21702
21703         * m4/sockpfaf.m4: New file.
21704
21705 2004-11-05  Bruno Haible  <bruno@clisp.org>
21706
21707         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
21708         Reported by Mark D. Baushke <mdb@cvshome.org>.
21709
21710 2004-11-04  Bruno Haible  <bruno@clisp.org>
21711
21712         2004-09-11  Bruno Haible  <bruno@clisp.org>
21713                 * allocsa.valgrind: New file.
21714         2004-02-06  Bruno Haible  <bruno@clisp.org>
21715                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
21716                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
21717                 Reported by Christopher Seip <chris.seip@hp.com>.
21718
21719 2004-11-04  Bruno Haible  <bruno@clisp.org>
21720
21721         * modules/allocsa (Files): Add lib/allocsa.valgrind.
21722         (Makefile.am): Distribute it.
21723
21724 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
21725
21726         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
21727         with errno == ERANGE if the buffer is too small.
21728         Problem reported by Mark D. Baushke.
21729
21730 2004-11-03  Albert Chin  <china@thewrittenword.com>
21731             Paul Eggert  <eggert@cs.ucla.edu>
21732
21733         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
21734         equivalent, substitute $ac_type for equivalent type rather than
21735         blindly using uint32_t *always* which won't work if uint32_t is not
21736         available.  Define _UINT32_T to work around typedef of uint32_t if
21737         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
21738         2.5.1.
21739
21740 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21741
21742         * m4/jm-macros.m4: Sync from coreutils.
21743         (gl_MACROS): Check for mbrlen, for pathchk.
21744         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
21745
21746 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21747
21748         * lib/xreadlink.c (MAXSIZE): New macro.
21749         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
21750         size does not exceed MAXSIZE.  Avoid cast.
21751         As suggested by Mark D. Baushke in
21752         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
21753         if readlink fails with buffer size just under MAXSIZE, try again
21754         with MAXSIZE.
21755
21756 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21757
21758         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
21759
21760 2004-11-02  Derek R. Price  <derek@ximbiot.com>
21761         and  Paul Eggert  <eggert@cs.ucla.edu>
21762
21763         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
21764         (get_date): Overparenthesize to avoid GCC warning.
21765
21766 2004-11-02  Bruno Haible  <bruno@clisp.org>
21767
21768         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
21769         returns void.
21770
21771 2004-11-02  Bruno Haible  <bruno@clisp.org>
21772
21773         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
21774         function returns void.
21775
21776 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
21777
21778         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
21779         fflush_unlocked, flockfile, funlockfile, funlockfile,
21780         fputs_unlocked, putc_unlocked.
21781
21782 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
21783
21784         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
21785         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
21786         already declared.
21787
21788 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
21789
21790         * modules/getdate (Files): Add doc/getdate.texi.
21791         (Depends-on): Add setenv, xalloc.
21792
21793 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
21794
21795         * lib/getdate.y: Add support for TZ="foo" within a date string.
21796         Fix some bugs near time_t boundaries.  Reject dates with
21797         out-of-range components, e.g., "Sept 31".
21798         Include <stdlib.h>, "setenv.h", "xalloc.h".
21799         (ISDIGIT_LOCALE): Remove; unused.
21800         Note that the TZ and time functions used here are not reentrant.
21801         (mktime_ok, get_tz): New functions.
21802         (TZBUFSIZE): New constant.
21803         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
21804         This requires that we sometimes generate our own TZ="XXX..." setting.
21805
21806 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
21807
21808         * doc/getdate.texi: New file, from coreutils with modifications for
21809         the new TZ parsing.
21810
21811 2004-10-27  Derek R. Price  <derek@ximbiot.com>
21812
21813         * lib/mktime.c (not_equal_tm): Remove redundant check.
21814
21815 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
21816
21817         * modules/regex (lib_SOURCES): Add regex.c.
21818         Reported by James Youngman in
21819         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
21820
21821 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
21822
21823         * lib/getdate.y: Use Bison 1.875 features, and some minor
21824         code cleanups.  This change does not affect semantics.
21825         Don't include <stdlib.h>; no longer needed.
21826         Don't include unlocked-io.h; only the "#if TEST" code uses
21827         stdio, and performance isn't crucial there.
21828         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
21829         Bison 1.875 features as described below.
21830         All uses of "PC." replaced by "pc->".
21831         (YYSTYPE): Add a forward declaration.
21832         (yylex, yyerror): Use full prototypes in forward decls.
21833         Use "%pure-parser" rather than obsolescent "%pure_parser".
21834         Use %parse-param and %lex-param instead of obsolescent
21835         YYPARSE_PARAM and YYLEX_PARAM.
21836         (meridian_table, month_and_day_table, time_units_table,
21837         relative_time_table, time_zone_table, military_table,
21838         lookup_zone, lookup_word, get_date):
21839         Use NULL instead of 0 where appropriate.
21840         (to_hour): Avoid abort (), to avoid a dependency on
21841         stdlib.h.
21842         (yyerror, yylex): Now accepts parser_control * arg.
21843         (main) [TEST]: Use '\0' rather than 0 for char.
21844
21845 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
21846
21847         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
21848
21849 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
21850
21851         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
21852         It's now the caller's responsibility to handle the case where
21853         !HAVE_GETPAGESIZE && !defined getpagesize.
21854
21855         * lib/mktime.c (leapyear): Arg is long int, not int.
21856
21857 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
21858
21859         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
21860
21861 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
21862
21863         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
21864         missing.  Problem reported by James Youngman.
21865
21866 2004-10-16  Simon Josefsson  <jas@extundo.com>
21867
21868         * gnulib-tool: Fix comments.  Fix parse problem.
21869         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
21870
21871 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
21872
21873         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
21874         implementation of getopt_long.  Problem reported by Alexander Taler in:
21875         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
21876
21877 2004-10-15  Bruno Haible  <bruno@clisp.org>
21878
21879         * gnulib-tool: Untabify. Initialize supplied_libname.
21880         (func_usage): More homogenous output.
21881         (func_modules_transitive_closure, func_modules_to_filelist,
21882         func_emit_lib_Makefile_am): New functions.
21883         (func_import): New function, extracted from big case statement. Use
21884         func_get_license, func_modules_transitive_closure,
21885         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
21886         opt_lgpl. Don't use test -a, as it's not portable.
21887         (func_create_testdir): Use func_modules_transitive_closure,
21888         func_modules_to_filelist, func_emit_lib_Makefile_am.
21889
21890 2004-10-15  Bruno Haible  <bruno@clisp.org>
21891
21892         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
21893
21894 2004-10-15  Bruno Haible  <bruno@clisp.org>
21895
21896         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
21897         the portions belonging to each module.
21898         Suggested by Derek Robert Price <derek@ximbiot.com>.
21899
21900 2004-10-12  Simon Josefsson  <jas@extundo.com>
21901
21902         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
21903         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
21904         to real functions.
21905
21906 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21907
21908         * modules/vsnprintf: New file.
21909
21910 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21911
21912         * m4/vsnprintf.m4: New file.
21913
21914 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21915
21916         * lib/vsnprintf.h: New file.
21917         * lib/vsnprintf.c: New file.
21918
21919 2004-10-11  Bruno Haible  <bruno@clisp.org>
21920
21921         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
21922         vsnprintf.
21923
21924 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
21925
21926         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
21927
21928 2004-10-07  Bruno Haible  <bruno@clisp.org>
21929
21930         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
21931         fits into the provided buffer.
21932
21933 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
21934
21935         * lib/diacrit.c, diacrit.h: Add GPL notice.
21936
21937         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
21938         notice.
21939         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
21940         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
21941         This avoids a potential constant-folding bug.
21942
21943 2004-10-05  Bruno Haible  <bruno@clisp.org>
21944
21945         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
21946         for the declaration of strsep.
21947
21948 2004-10-05  Bruno Haible  <bruno@clisp.org>
21949
21950         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
21951
21952 2004-10-04  Simon Josefsson  <jas@extundo.com>
21953
21954         * modules/memmem: New file.
21955         * tests/test-memmem.c: New file.
21956         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
21957
21958 2004-10-04  Simon Josefsson  <jas@extundo.com>
21959
21960         * m4/memmem.m4: New file.
21961
21962 2004-10-04  Simon Josefsson  <jas@extundo.com>
21963
21964         * lib/memmem.h: New file.
21965         * lib/memmem.c: New file, taken from glibc.
21966
21967 2004-10-04  Simon Josefsson  <jas@extundo.com>
21968
21969         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
21970         '#ifdef USE_UNLOCKED_IO'.
21971
21972 2004-10-04  Simon Josefsson  <jas@extundo.com>
21973
21974         * config/srclist.txt: Add memmem from glibc.
21975
21976 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21977
21978         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
21979
21980         * modules/argmatch, modules/argp, modules/closeout, modules/error,
21981         modules/exclude, modules/getdate, modules/getline,
21982         modules/getndelim2, modules/getpass, modules/getpass-gnu,
21983         modules/getusershell, modules/linebuffer, modules/md5,
21984         modules/mountlist, modules/posixtm, modules/readtokens,
21985         modules/readutmp, modules/regex, modules/sha1,
21986         modules/version-etc, modules/yesno:
21987         Remove dependency on unlocked-io.
21988
21989 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21990
21991         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
21992
21993         * m4/unlocked-io.m4: Add copyright notice.
21994         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
21995
21996 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
21997
21998         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
21999         * lib/xmalloc.c (xmemdup): Likewise.
22000         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
22001         XFREE): Remove these long-obsolescent macros.
22002         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
22003         * lib/xstrdup.c: Remove.
22004
22005         * lib/regex.c (re_comp): Cast gettext return value to char *,
22006         Problem reported by Martin Neitzel via Mark D. Baushke.
22007
22008 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
22009
22010         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
22011         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
22012         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
22013         regex.c, sha1.c, version-etc.c, yesno.c:
22014         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
22015         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
22016         the includer's responsibility.
22017
22018         Sync from coreutils.
22019
22020         * lib/modechange.c (mode_compile): Don't decrement a pointer that
22021         points to the start of a string, as the C Standard says the
22022         resulting behavior is undefined.
22023
22024         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
22025         simple -> simple_backups, numbered_existing ->
22026         numbered_existing_backups, numbered -> numbered_backups
22027         to avoid shadowing problems.  All uses changed.
22028         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
22029         * lib/backupfile.c (check_extension, numbered_backup):
22030         Rename locals to avoid shadowing 'basename'.
22031         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
22032         once.
22033
22034         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
22035         * lib/.cvsignore: Add getopt.h.
22036
22037 2004-10-04  Bruno Haible  <bruno@clisp.org>
22038
22039         * modules/README: New file.
22040         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
22041         not a module.
22042
22043 2004-10-02  Jim Meyering  <jim@meyering.net>
22044
22045         * lib/dirfd.h, getpagesize.h: Add copyright notice.
22046
22047 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22048
22049         * modules/strsep: New file.
22050
22051 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22052
22053         * m4/strsep.m4: New file.
22054
22055 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22056
22057         * lib/strsep.h: New file.
22058         * lib/strsep.c: New file.
22059
22060 2004-10-01  Simon Josefsson  <jas@extundo.com>
22061
22062         * lib/snprintf.c (snprintf): Handle size==0.
22063
22064 2004-10-01  Simon Josefsson  <jas@extundo.com>
22065             Bruno Haible  <bruno@clisp.org>
22066
22067         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
22068         (snprintf): Declare 'args'.
22069
22070 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
22071
22072         * lib/snprintf.c: Remove comments as to why each header is needed.
22073
22074 2004-10-01  Bruno Haible  <bruno@clisp.org>
22075
22076         * MODULES.html.sh: Add strsep.
22077
22078 2004-09-30  Simon Josefsson  <jas@extundo.com>
22079
22080         * modules/snprintf: New file.
22081
22082 2004-09-30  Simon Josefsson  <jas@extundo.com>
22083
22084         * m4/snprintf.m4: New file.
22085
22086 2004-09-30  Simon Josefsson  <jas@extundo.com>
22087
22088         * lib/snprintf.h, lib/snprintf.c: New files.
22089
22090 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
22091
22092         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
22093         (hol_entry_help): Never translate an empty string.
22094         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
22095         * lib/argp.h (OPTION_NO_TRANS): New option.
22096
22097 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
22098
22099         * modules/argp (Maintainer): Replace Simon Josefsson
22100         by Sergey Poznyakoff.
22101
22102 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
22103
22104         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
22105         changes merged back into glibc.
22106
22107 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
22108
22109         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
22110
22111 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
22112
22113         * lib/xvasprintf.c: Include xalloc.h.
22114         (xvasprintf): Use xalloc_die, not xmalloc_die.
22115
22116 2004-09-29  Bruno Haible  <bruno@clisp.org>
22117
22118         * modules/alloca-opt: New file, derived from modules/alloca.
22119         * modules/allocsa: Depend on alloca-opt instead of alloca.
22120         * modules/setenv: Likewise.
22121         * modules/vasnprintf: Likewise.
22122         * MODULES.html.sh: Add alloca-opt.
22123
22124 2004-09-28  Simon Josefsson  <jas@extundo.com>
22125
22126         * gnulib-tool: New parameter --lgpl, to asseert that modules are
22127         LGPL, and to replace license template from GPL to LGPL.
22128
22129 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
22130
22131         * modules/dummy: Change license to LGPL.
22132
22133 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
22134
22135         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
22136
22137 2004-09-24  Simon Josefsson  <jas@extundo.com>
22138
22139         * modules/minmax (License): Change from GPL to LGPL.
22140
22141 2004-09-23  Simon Josefsson  <jas@extundo.com>
22142
22143         * gnulib-tool (--import): Typo.
22144
22145 2004-09-23  Simon Josefsson  <jas@extundo.com>
22146
22147         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
22148
22149 2004-09-22  Bruno Haible  <bruno@clisp.org>
22150
22151         * modules/*: Add 'License' field.
22152         * gnulib-tool: Accept --extract-license option.
22153         (func_get_license): New function.
22154
22155 2004-09-21  Bruno Haible  <bruno@clisp.org>
22156
22157         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
22158         Reported by Simon Josefsson.
22159
22160 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
22161
22162         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
22163         gl_AC_TYPE_LONG_LONG.
22164
22165 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
22166
22167         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
22168
22169 2004-09-18  Simon Josefsson  <jas@extundo.com>
22170         and  Paul Eggert  <eggert@cs.ucla.edu>
22171
22172         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
22173         calls with autoreconf.  Define GL_LIB.
22174
22175 2004-09-14  Karl Berry  <karl@gnu.org>
22176
22177         * config/srclist.txt: unsync setenv.c, sigh.
22178
22179 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
22180
22181         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
22182         Problem reported by Bruno Haible in:
22183         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
22184
22185 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
22186
22187         * config/srclist.txt: Comment out argp-pvh.c.
22188
22189 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
22190
22191         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
22192         in case some system header has #define'd it.  Problem reported by
22193         Soeren D. Schulze in
22194         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
22195
22196 2004-09-09  Karl Berry  <karl@gnu.org>
22197
22198         * regex.[ch]: delete from the root.  These were supposed to be
22199                 synced with emacs cvs, but this has not happened for about
22200                 a year, and anyway nothing else uses emacs regex.[ch].
22201                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
22202                 lib/regex[.ch] is untouched.
22203
22204 2004-09-09  Bruno Haible  <bruno@clisp.org>
22205
22206         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
22207
22208 2004-09-09  Bruno Haible  <bruno@clisp.org>
22209
22210         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
22211         modifications.
22212         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
22213
22214 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
22215
22216         * modules/xvasprintf: New file.
22217         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
22218
22219 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
22220
22221         * lib/xvasprintf.h: New file.
22222         * lib/xvasprintf.c: New file.
22223         * lib/xasprintf.c: New file.
22224
22225 2004-09-08  Bruno Haible  <bruno@clisp.org>
22226
22227         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
22228
22229 2004-09-08  Bruno Haible  <bruno@clisp.org>
22230
22231         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
22232         length is > INT_MAX.
22233         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
22234         more.
22235
22236 2004-09-08  Bruno Haible  <bruno@clisp.org>
22237
22238         * lib/stdint_.h: New file, taken from GNU clisp.
22239
22240 2004-09-08  Bruno Haible  <bruno@clisp.org>
22241             Oskar Liljeblad  <oskar@osk.mine.nu>
22242
22243         * modules/stdint: New file.
22244         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
22245
22246 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
22247
22248         Import from coreutils.
22249         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
22250         strings on unbounded length.  alloca's performance benefits aren't
22251         that important here.
22252         (V_STRDUP): Remove.
22253         (parse_with_separator): New function, with most of the internals
22254         of the old parse_user_spec.  Allow user to omit both user and group,
22255         for compatibility with FreeBSD.
22256         Clone only the user name, not the entire spec.
22257         Do not set *uid, *gid unless entirely successful.
22258         Avoid memory leak in some failing cases.
22259         Fix regression for USER.GROUP reported by Dmitry V. Levin in
22260         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
22261         (parse_user_spec): Rewrite to use parse_with_separator.
22262
22263 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
22264
22265         * modules/userspec: Don't depend on alloca.
22266
22267 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
22268
22269         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
22270
22271 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
22272
22273         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
22274         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
22275         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
22276
22277 2004-08-16  Simon Josefsson  <jas@extundo.com>
22278
22279         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
22280         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
22281         Add --dry-run for --import.
22282         Let user provided command line parameters override configure.ac
22283         settings.
22284
22285 2004-08-12  Simon Josefsson  <jas@extundo.com>
22286
22287         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
22288         as discussed with Paul Eggert in threads rooted at
22289         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
22290         and
22291         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
22292         Before, the test was empty, and relied on ELIDE_CODE in source
22293         code.)
22294         (gl_PREREQ_GETOPT): New macro.
22295         (gl_GETOPT): Use them.
22296
22297 2004-08-12  Simon Josefsson  <jas@extundo.com>
22298
22299         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
22300         * lib/getopt_.h: Renamed from getopt.h.
22301
22302 2004-08-12  Simon Josefsson  <jas@extundo.com>
22303
22304         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
22305         Change default library name from libfoo to libgnu.
22306         Now, if you have a configure.ac that says:
22307                 gl_SOURCE_BASE(gl)
22308                 gl_M4_BASE(gl/m4)
22309                 gl_MODULES(error getopt etcetera)
22310                 gl_INIT
22311         you can import all you need by running:
22312                 ../gnulib/gnulib-tool --import
22313
22314         * modules/getopt (Files): Rename getopt.h to getopt_.h.
22315         (Makefile.am): Rewrite, use logic from argz.
22316         (Include): Use <getopt.h> instead of "getopt.h".
22317
22318 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22319
22320         * modules/argp (Files): Add m4/unlocked-io.m4.
22321         (Depends-on): Add extensions.
22322
22323 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22324
22325         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
22326         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
22327         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
22328         Check for program_invocation_name, program_invocation_short_name,
22329         flockfile, funlockfile, features.h, _getopt_long_only_r.
22330
22331 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22332
22333         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
22334         its complicated substitute.
22335         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
22336         and program_invocation_name.
22337         (__argp_basename) [!_LIBC]: Remove; the only use was
22338         replaced by its body.
22339         (__argp_short_program_name): Change condition from
22340         !defined __argp_short_program_name to
22341         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
22342         to match argp-namefrob.h.
22343         (__argp_failure): Don't assume strerror_r returns char *.
22344         * lib/argp-parse.c (N_): Define unconditionally.
22345         (argp_default_options): Fill out initializers with 0 to avoid
22346         gcc warnings.
22347
22348 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22349
22350         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
22351         getopt1.c.
22352
22353 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
22354
22355         Merge from coreutils.
22356
22357         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
22358
22359         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
22360         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
22361
22362 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
22363
22364         Merge from coreutils.
22365
22366         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
22367         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
22368         for Reliant Unix 5.43.
22369
22370         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
22371         (union fooround): Use uintmax_t, not long int.
22372         The rest is a merge from libc:
22373         [defined _LIBC]: Include <shlib-compat.h>.
22374         (_obstack) [defined _LIBC]: Remove after 2.3.4.
22375
22376         * lib/settime.c (settime): Recode to avoid warning with
22377         Sun Forte C 6U2.
22378
22379         * lib/strverscmp.c: Convert to UTF-8.
22380
22381 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
22382
22383         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
22384         m4/uintmax_t.m4.
22385
22386 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
22387
22388         * modules/xalloc-die: New file.
22389         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
22390
22391         * modules/md5 (Files): Add m4/uint32_t.m4.
22392         * modules/sha1: Renamed from modules/sha.
22393         (Files):
22394         Rename lib/sha.h to lib/sha1.h.
22395         Rename lib/sha.c to lib/sha1.c.
22396         Rename m4/sha.m4 to m4/sha1.m4.
22397         (lib_SOURCES): Likewise.
22398         (configure.ac): Rename gl_SHA to gl_SHA1.
22399         (Include): sha.h -> sha1.h.
22400
22401 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
22402
22403         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
22404         * m4/sha1.m4: Renamed from sha.m4.
22405         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
22406
22407 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
22408
22409         * lib/obstack.h (obstack_empty_p):
22410         Don't assume that chunk->contents is suitably aligned.
22411         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
22412         Likewise. Problem reported by Benno in
22413         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
22414
22415         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
22416         readable.  This could be improved further but it'd take some work.
22417
22418 2004-08-08  Simon Josefsson  <jas@extundo.com>
22419
22420         * modules/xgethostname (Depends-on): Remove exit and error (not
22421         used).
22422
22423         * modules/getpass-gnu: Add getpass.h.
22424         (Depends-on): Add stdbool.
22425         * modules/getpass: Add getpass.h.
22426
22427 2004-08-08  Simon Josefsson  <jas@extundo.com>
22428
22429         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
22430         Check getpass declaration.
22431
22432 2004-08-08  Simon Josefsson  <jas@extundo.com>
22433
22434         * lib/xgethostname.c: Don't include error.h (not used).
22435
22436         * lib/getpass.h: Add.
22437         * lib/getpass.c: Include getpass.h first.
22438
22439 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
22440
22441         * lib/xalloc-die.c: New file.
22442         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
22443         All uses removed.
22444         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
22445         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
22446         xalloc-die.c.
22447         (_, N_, xalloc_die): Move to xalloc-die.c.
22448         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
22449         so that we needn't mess with xalloc_msg_memory_exhausted.
22450
22451         * lib/sha1.h: Renamed from sha.h.
22452         (SHA1_H): Renamed from _SHA_H.
22453         (sha1_ctx): Renamed from sha_ctx.
22454         (sha1_init_ctx): Renamed from sha_init_ctx.
22455         (sha1_process_block): Renamed from sha_process_block.
22456         (sha1_process_bytes): Renamed from sha_process_bytes.
22457         (sha1_finish_ctx): Renamed from sha_finish_ctx.
22458         (sha1_read_ctx): Renamed from sha_read_ctx.
22459         (sha1_stream): Renamed from sha_stream.
22460         (sha1_buffer): Renamed from sha_buffer.
22461         * lib/sha1.c: Likewise; renamed from sha.c.
22462         Do not include <sys/types.h>.
22463         Include <stddef.h> rather than <stdlib.h>.
22464
22465 2004-08-08  Bruno Haible  <bruno@clisp.org>
22466
22467         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
22468         FILESYSTEM_PREFIX_LEN.
22469         * lib/progreloc.c: Likewise.
22470         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
22471
22472 2004-08-06  Simon Josefsson  <jas@extundo.com>
22473
22474         * modules/progname (Depends-on): Don't depend on stdbool.
22475
22476 2004-08-06  Simon Josefsson  <jas@extundo.com>
22477
22478         * modules/getsubopt: New file.
22479         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
22480         getsubopt.
22481
22482 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22483
22484         More merge from coreutils.
22485
22486         * m4/utimens.m4, m4/utimecmp.m4: New files.
22487         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
22488         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
22489         prereq.m4, sha.m4: Import changes from coreutils.
22490
22491 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22492
22493         More merge from coreutils.
22494         * modules/raise, modules/readtokens0, modules/utimens:
22495         * modules/utimecmp, module/xnanosleep: New files.
22496         * modules/strftime: Add lib/strftime.h.
22497         Change include from <time.h> to "strftime.h".
22498         * modules/yesno: Add lib/yesno.h.
22499         * modules/backupfile: Remove lib/addext.c.
22500         * modules/euidaccess: Add stat-macros.h.
22501         * modules/canonicalize, modules/euidaccess,
22502         modules/filemode, modules/lchown, modules/makepath,
22503         modules/rmdir, modules/stat: Likewise.
22504
22505 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22506
22507         Merge from tar.
22508         * lib/argp-help.c (make_hol, hol_append): Don't assume that
22509         SIZE_MAX is a valid preprocessor constant.
22510         (__argp_basename): Change from "#ifndef _LIBC"
22511         to "#ifndef __argp_short_program_name", so that
22512         we don't compile these functions for tar.
22513
22514         More merges from coreutils.
22515         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
22516         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
22517         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
22518         * lib/addext.c: Remove; no longer needed.
22519         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
22520         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
22521         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
22522         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
22523         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
22524         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
22525         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
22526         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
22527         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
22528         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
22529         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
22530         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
22531         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
22532         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
22533         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
22534         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
22535         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
22536         Import changes from coreutils.
22537
22538 2004-08-05  Simon Josefsson  <jas@extundo.com>
22539
22540         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
22541
22542 2004-08-05  Simon Josefsson  <jas@extundo.com>
22543
22544         * m4/getsubopt.m4: New file.
22545
22546 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22547
22548         Merge from coreutils.
22549
22550         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
22551         * m4/getcwd-path-max.m4: New files.
22552
22553         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
22554         FILESYSTEM_PREFIX_LEN ->
22555         FILE_SYSTEM_PREFIX_LEN.
22556         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
22557         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
22558         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
22559         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
22560
22561         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
22562         prerequisite modules now handle the DOS stuff.
22563         Don't check for unistd.h.
22564
22565 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22566
22567         Merge from coreutils.
22568
22569         * lib/.gdb-history: Remove; this doesn't belong here.
22570
22571         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
22572         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
22573         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
22574         * lib/getcwd.c: New files.
22575
22576         * lib/dirname.h: Include <stdbool.h>.
22577         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
22578         for consistency with POSIX terminology.  All uses changed.
22579         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
22580         (strip_trailing_slashes): Use bool for booleans.
22581         * lib/stripslash.c (strip_trailing_slashes): Likewise.
22582
22583         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
22584         sometimes returns a positive errno value even when it succeeds.
22585         (print_errno_message) [!LIBC]: Fall back on strerror if
22586         __strerror_r fails.
22587
22588         * lib/path-concat.c (mempcpy): Don't define if a system header defines
22589         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
22590         (longest_relative_suffix): New function.
22591         (path_concat): Use it.  Assume first argument is not NULL.
22592         Port to DOS.  Omit redundant separators.
22593         Report an error instead of returning NULL.
22594         Use mempcpy instead of memcpy.
22595         (xpath_concat): Remove: not declared or used.
22596
22597         * lib/same.h: Include <stdbool.h>
22598         (same_name): Return bool, not int.
22599         * lib/same.c (same_name): Likewise.
22600         (errno): Don't declare; we assume C89 or better now.
22601
22602         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
22603         if not already defined.
22604
22605         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
22606         * lib/dup-safer.c (errno): Likewise.
22607
22608 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22609
22610         Merge from coreutils.
22611         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
22612         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
22613         * modules/path-concat: Don't depend on strdup.
22614
22615 2004-08-03  Simon Josefsson  <jas@extundo.com>
22616
22617         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
22618         * lib/progname.h: Don't include stdbool.h.
22619
22620 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22621
22622         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
22623         * MODULES.html.sh (func_all_modules): Remove fatal.
22624
22625 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22626
22627         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
22628
22629 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22630
22631         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
22632         working.
22633
22634 2004-08-02  Simon Josefsson  <jas@extundo.com>
22635
22636         * lib/getsubopt.h: New file, with comments from Bruno Haible.
22637         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
22638         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
22639
22640 2004-08-01  Simon Josefsson  <jas@extundo.com>
22641
22642         * lib/xgetdomainname.c: Include stdlib.h, for free().
22643
22644 2004-07-19  Bruno Haible  <bruno@clisp.org>
22645
22646         * MODULES.html.sh (func_all_modules): Add dummy.
22647
22648 2004-07-16  Simon Josefsson  <jas@extundo.com>
22649
22650         * modules/dummy: New file.
22651
22652 2004-07-16  Simon Josefsson  <jas@extundo.com>
22653
22654         * lib/dummy.c: New file.
22655
22656 2004-07-16  Bruno Haible  <bruno@clisp.org>
22657
22658         * lib/backupfile.h: Add extern "C" for C++.
22659         * lib/closeout.h: Likewise.
22660         * lib/copy-file.h: Likewise.
22661         * lib/findprog.h: Likewise.
22662         * lib/full-write.h: Likewise.
22663         * lib/pathname.h: Likewise.
22664         * lib/progname.h: Likewise.
22665         * lib/stpcpy.h: Likewise.
22666         * lib/stpncpy.h: Likewise.
22667         * lib/strcase.h: Likewise.
22668         * lib/strstr.h: Likewise.
22669         * lib/xalloc.h: Likewise.
22670
22671         * lib/mbswidth.h: Add extern "C" for C++.
22672         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
22673
22674 2004-07-13  Robert Millan  <robertmh@gnu.org>
22675
22676         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
22677
22678 2004-07-09  Simon Josefsson  <jas@extundo.com>
22679
22680         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
22681         failed without this.)
22682
22683 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
22684
22685         * modules/chown (Files): Add lib/fchown-stub.c, since
22686         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
22687
22688 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
22689
22690         * lib/fchown-stub.c: New file.
22691
22692 2004-06-24  Jim Meyering  <jim@meyering.net>
22693
22694         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
22695
22696 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22697
22698         * modules/argz: Omit "#include".
22699
22700         * MODULES.html.sh (func_all_modules): Add calloc, to match
22701         2004-06-01 addition of calloc module.
22702
22703 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22704
22705         * m4/argz.m4: New file, which is autoupdated from libtool.
22706
22707 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22708
22709         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
22710         libtool.
22711
22712 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22713
22714         * config/srclist-update: Don't insist on "USA." before the
22715         close-comment, as libtool omits the period and puts the */ on a
22716         separate line.
22717         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
22718         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
22719
22720 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
22721
22722         * modules/argz: New file.
22723         * MODULES.html.sh (func_all_modules): Add argz.
22724
22725 2004-06-12  Jim Meyering  <jim@meyering.net>
22726         and  Paul Eggert  <eggert@cs.ucla.edu>
22727
22728         * modules/hash (Files): Add lib/xalloc.h.
22729         * modules/pipe (Depends-on): Add wait-process.
22730         * modules/stat (Depends-on): Add xalloc.
22731         * modules/userspec (Files): Add lib/userspec.h.
22732         * modules/xstrto
22733
22734         Upgrade from gettext-0.13.
22735         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
22736         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
22737         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
22738
22739 2004-06-10  Jim Meyering  <jim@meyering.net>
22740
22741         * lib/calloc.c: New file.
22742
22743 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
22744
22745         * lib/getdate.y (yylex): Allow space between sign and number.
22746         Problem reported by Dan Jacobson.
22747
22748 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
22749
22750         Merge from coreutils CVS.
22751
22752         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
22753         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
22754         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
22755         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
22756         xstrtol.m4: Fix copyright date and/or serial number.
22757
22758         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
22759         See if we need an fchown replacement.
22760         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
22761         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
22762         and use the replacement function if we detect either defect.
22763
22764         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
22765         gl_UTIMECMP.
22766
22767 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
22768         and  Jim Meyering  <jim@meyering.net>
22769
22770         Merge from coreutils CVS.
22771
22772         * lib/stat-macros.h: New file, with contents from file-type.h
22773         and coreutils' system.h.
22774         * lib/file-type.c: Include "stat-macros.h".
22775         * lib/file-type.h (file_type): Move all macro definitions to new file,
22776         stat-macros.h.
22777
22778         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
22779         Wrap old code with this conditional.
22780         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
22781         function that does not dereference symlinks.
22782         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
22783
22784         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
22785         dependency problems.
22786         (xreadlink): Accept new arg SIZE, for efficiency.
22787         All decls and uses changed.
22788         * lib/xreadlink.h: Include <stddef.h>, for size_t.
22789
22790         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
22791         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
22792
22793         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
22794         sysexits.h.
22795
22796 2004-06-01  Jim Meyering  <jim@meyering.net>
22797
22798         * m4/calloc.m4: New file.
22799
22800 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
22801
22802         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
22803         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
22804         Also, fix a typo in a diagnostic.
22805
22806 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
22807
22808         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
22809         or AC_FUNC_REALLOC.
22810
22811 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
22812
22813         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
22814         macros to be defined.
22815         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
22816         the allocator returns NULL because the requested size is zero.
22817
22818 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
22819
22820         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
22821         var.  Add comment explaining why libc still defines it.  This
22822         merges the following patch from glibc:
22823         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
22824
22825 2004-05-20  Andreas Schwab  <schwab@suse.de>
22826
22827         * m4/free.m4: Replace free if it not known to work, not the other
22828         way round.
22829
22830 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
22831
22832         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
22833         present in glibc since revision 1.1 of this file.
22834         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
22835         obstack_alignment_mask, obstack_alloc, obstack_base,
22836         obstack_blank, obstack_blank_fast, obstack_chunk_size,
22837         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
22838         obstack_grow0, obstack_init, obstack_int_grow,
22839         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
22840         obstack_next_free, obstack_object_size, obstack_ptr_grow,
22841         obstack_ptr_grow_fast, obstack_room): Remove declarations of
22842         nonexistent functions.
22843
22844 2004-05-18  Karl Berry  <karl@gnu.org>
22845
22846         * config/srclist.txt: break link for vasnprintf.c.
22847
22848 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
22849
22850         Port obstack to the AS/400, where pointers are 16 bytes wide and
22851         you cannot cast an integer to a valid pointer.  This patch is
22852         currently waiting to be integrated into glibc; see
22853         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
22854
22855         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
22856         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
22857         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
22858         (struct obstack): temp member is now a union of a pointer and
22859         an integer, instead of an integer.  All integer uses changed.
22860         This does not affect the physical layout of struct obstack,
22861         except on hosts (like the AS/400) where the size or alignment of
22862         void * is greater than that of ptrdiff_t.
22863         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
22864         __STDC__)]: Store temporary in pointer member of union, not
22865         integer member.
22866         * lib/obstack.c: Include <stddef.h>, for offsetof.
22867         (struct fooalign): Remove; it doesn't need a name.
22868         (union fooround): Change double to long double, and add void *.
22869         (DEFAULT_ALIGNMENT): Use offsetof to compute.
22870         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
22871         not a macro.  Hence the values are always int; so remove all
22872         casts-to-int in uses.
22873
22874 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
22875
22876         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
22877         we can get this patch merged into glibc.
22878
22879 2004-05-17  Derek R. Price  <derek@ximbiot.com>
22880             Paul Eggert  <eggert@cs.ucla.edu>
22881
22882         * m4/argp: Depend on alloca.
22883
22884 2004-05-17  Derek R. Price  <derek@ximbiot.com>
22885             Paul Eggert  <eggert@cs.ucla.edu>
22886
22887         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
22888         freecoding.
22889
22890 2004-05-17  Bruno Haible  <bruno@clisp.org>
22891
22892         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
22893         precision that consists of a '.' followed by an empty digit string.
22894         Patch by Tor Lillqvist <tml@iki.fi>.
22895
22896 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
22897
22898         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
22899         for backward compatibility with older code.  We need our own
22900         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
22901         it under some other name, and our alloca.h will define it.
22902
22903 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
22904             Derek Price  <derek@ximbiot.com>
22905
22906         * lib/alloca.c: Include <alloca.h>, to get our interface.
22907         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
22908         include <alloca.h> first.  Use C89 prototype for alloca; this
22909         requires including <stddef.h> for size_t.  Use extern "C" if C++.
22910         Use #elif for simplicity, since we can assume C89 now.
22911         Don't try to source the system alloca.h since it will not be found
22912         and to prevent recursively including its replacement.
22913         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
22914         * lib/regex.c: Likewise.
22915
22916 2004-05-16  Derek Price  <derek@ximbiot.com>
22917             Paul Eggert  <eggert@cs.ucla.edu>
22918
22919         getline cleanup.  This changes the getndelim2 API: both order of
22920         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
22921         no delimiter).
22922
22923         * lib/getline.c: Don't include stddef.h or stdio.h, since our
22924         interface does that.
22925         (getline): Always use getdelim, so that we don't have two
22926         copies of this code.
22927         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
22928         if available.
22929         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
22930         (GETNDELIM2_MAXIMUM): New macro.
22931         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
22932         instead of the old practice of delim2==0.  All callers changed.
22933         Return -1 on overflow, instead of returning junk.
22934         Do not set *linesize unless allocation succeeds.
22935         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
22936         that we include sys/types.h.
22937         * lib/getnline.h: Likewise.
22938         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
22939         (getndelim2): Reorder arguments.
22940         * lib/getnline.c (getnline, getndelim):
22941         Don't discard the NMAX argument.
22942         (getnline): Invoke getndelim, to avoid code duplication.
22943         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
22944         of (size_t) -1 by callers of the getnline family.
22945
22946 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
22947
22948         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
22949         Check for gettimeofday.
22950         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
22951         Check for settimeofday, stime.
22952
22953 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
22954
22955         * lib/nanosleep.c (suspended): Change its type from int to
22956         sig_atomic_t volatile.
22957         (first_call): Make it private to rpl_nanosleep, and have it
22958         be zero initially as that's a bit faster.
22959         (my_usleep): Round up fractional times instead of truncating them,
22960         as this is the usual meaning for 'sleep'.
22961
22962         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
22963         doesn't work.
22964         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
22965         (ENOSYS): Define if not defined.
22966         (settime): Fall back on stime if it exists and settimeofday fails.
22967         But don't bother with fallbacks if a method fails with errno == EPERM.
22968
22969 2004-05-11  Jim Meyering  <jim@meyering.net>
22970
22971         Prior to this change, the save_cwd caller required read access to the
22972         current directory on most systems (ones with the fchdir function).
22973
22974         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
22975         fails, try write-only, and finally, resort to using xgetcwd.
22976
22977 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
22978
22979         * lib/obstack.c, obstack.h: Import changes from libc.
22980
22981 2004-04-28  Bruno Haible  <bruno@clisp.org>
22982
22983         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
22984         also implicitly appends .exe to executables.
22985         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
22986         accepts Windows pathnames.
22987         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
22988         Treat Cygwin like Windows, since it now accepts Windows pathnames.
22989         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
22990         Treat Cygwin like Windows, since it now accepts Windows pathnames.
22991         Reported by Derek Robert Price <derek@ximbiot.com>.
22992
22993 2004-04-21  Karl Berry  <karl@gnu.org>
22994
22995         * config/srclist.txt (localcharset.c): break sync.
22996
22997 2004-04-20  Paul Eggert  <eggert@twinsun.com>
22998
22999         * m4/host-os.m4: Add a copyright notice.
23000
23001 2004-04-20  Jim Meyering  <jim@meyering.net>
23002
23003         Change UTILS_ to gl_ in AC_DEFINE'd names.
23004         Change utils_- and jm_-prefixed variables, too.
23005         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
23006         UTILS_FUNC_MKDIR_TRAILING_SLASH.
23007         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
23008
23009         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
23010         Don't emit trailing blanks.
23011         Also rename jm_-prefixed variables to have gl_ prefix.
23012
23013         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
23014         Also rename jm_-prefixed variables to have gl_ prefix.
23015
23016         * m4/jm-macros.m4: Reflect the renamings.
23017         * m4/prereq.m4: Likewise.
23018
23019 2004-04-20  Jim Meyering  <jim@meyering.net>
23020
23021         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
23022         memory.
23023
23024 2004-04-20  Jim Meyering  <jim@meyering.net>
23025             Bruno Haible  <bruno@clisp.org>
23026
23027         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
23028         memory when realloc fails.
23029
23030 2004-04-19  Jim Meyering  <jim@meyering.net>
23031
23032         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
23033         now that readutmp.c may call `free (0)'.
23034
23035 2004-04-19  Bruno Haible  <bruno@clisp.org>
23036
23037         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
23038         * m4/inttypes_h.m4: Likewise.
23039         * m4/stdint_h.m4: Likewise.
23040         * m4/intmax_t.m4: Likewise.
23041         * m4/uintmax_t.m4: Likewise.
23042
23043 2004-04-18  Jim Meyering  <jim@meyering.net>
23044
23045         * m4/prereq.m4: Don't forbid jm_ prefix.
23046
23047         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
23048         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
23049         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
23050         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
23051         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
23052         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
23053         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
23054         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
23055         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
23056         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
23057         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
23058         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
23059         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
23060         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
23061         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
23062         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
23063         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
23064         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
23065         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
23066
23067 2004-04-18  Jim Meyering  <jim@meyering.net>
23068
23069         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
23070         failure, don't leak memory and do call END_UTMP_ENT.
23071
23072 2004-04-16  Jim Meyering  <jim@meyering.net>
23073
23074         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
23075         coreutils' stat program.
23076         (gl_PREREQ): Don't require jm_PREREQ_STAT.
23077
23078 2004-04-11  Paul Eggert  <eggert@twinsun.com>
23079
23080         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
23081         C89.
23082         (CHAR_BIT): Remove, since we assume C89.
23083         Include <stdint.h> if available, as per current Autoconf CVS advice.
23084
23085 2004-03-31  Jim Meyering  <jim@meyering.net>
23086
23087         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
23088         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
23089         * m4/xalloc.m4: Likewise.
23090
23091 2004-03-30  Paul Eggert  <eggert@twinsun.com>
23092
23093         Merge from coreutils.
23094
23095         * m4/inttostr.m4: New file.
23096         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
23097         Require AM_STDBOOL_H and gl_TIMESPEC instead.
23098         Require gl_CLOCK_TIME.
23099         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
23100
23101 2004-03-30  Paul Eggert  <eggert@twinsun.com>
23102
23103         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
23104         not bool, to be more consistent with Unix conventions.
23105         Suggested by Bruno Haible.
23106
23107         Merge from coreutils.
23108
23109         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
23110         * lib/umaxtostr.c: New files.
23111
23112         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
23113         the usual <time.h> dance.
23114         (get_date): Change signature to support fractional time stamps.
23115         All callers changed.
23116         * lib/getdate.y: Include "getdate.h" first, as we can now
23117         assume C89 and don't need to worry about 'const'.
23118         Similarly, include "unlocked-io.h" near start, not in middle.
23119         Include <limits.h>.
23120         (textint.value): Use long int rather than int.
23121         (textint.digits): Use size_t rather than int.
23122         (BILLION, LOG10_BILLION): New constants.
23123         (parser_control): New member rel_ns.  Members day_ordinal,
23124         time_zone, month, day, hour, minutes, rel_year, rel_month,
23125         rel_day, rel_hour, rel_minutes, rel_seconds
23126         are now long int, not int.  Member seconds is now struct timespec,
23127         not int.  New member timespec_seen.  Members dates_seen, days_seen,
23128         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
23129         not int.
23130         (%union.intval): Now long int, not int.
23131         New member timespec.
23132         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
23133         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
23134         (spec): Now is a timespec or an item list.
23135         (timespec, items): New nonterminals.
23136         (time, rel, relunit, number, get_date):
23137         Add support for fractional seconds.
23138         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
23139         (gmtime, localtime, mktime): Remove decls; not needed with C89.
23140         (to_hour): First arg is now long int, not int.
23141         (to_year): Returns long int, not int.
23142         Don't treat year -70 like 70.
23143         (tm_diff): Returns long int, not int.
23144         (lookup_word): Use bool instead of int when appropriate.
23145         (yylex): Use size_t for count, not int.
23146         Detect overflow when parsing large integer constants.
23147         Add support for fractions.
23148         (get_date): Make pointers 'const' if possible.
23149         Use more-portable code to detect integer overflow.
23150         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
23151         Don't use ctime; it's not reliable if the year has >4 digits.
23152
23153         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
23154         This is for compatibility with BSD.
23155
23156         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
23157         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
23158         From coreutils' system.h.
23159
23160         * lib/userspec.c: Don't include "posixver.h".
23161         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
23162         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
23163         compatible extension.  Simplify code by removing a boolean int
23164         that was always nonzero if a string was nonnull.
23165
23166 2004-03-30  Jim Meyering  <jim@meyering.net>
23167
23168         Merge from coreutils.
23169
23170         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
23171         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
23172         on some systems one must include <grp.h> before it.
23173         Reported by Christian Krackowizer.
23174
23175 2004-03-30  Jim Meyering  <jim@meyering.net>
23176
23177         Merge from coreutils.
23178
23179         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
23180
23181         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
23182         an empty input stream.
23183
23184         * lib/readtokens.c: Include <stdbool.h>.
23185         (readtoken): Use `size_t' rather than int/long.
23186         All callers adjusted.
23187         Use `bool' rather than `int' where appropriate.
23188         Use memset rather than an explicit loop.
23189         Use x2nrealloc rather than xrealloc.
23190         Allow the use of `\0' as a delimiter.
23191         (readtokens): Likewise.
23192         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
23193
23194 2004-03-30  Jim Meyering  <jim@meyering.net>
23195
23196         * m4/realloc.m4: Remove file, since now it does no more than
23197         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
23198         the `configure.ac' section of module/realloc.
23199         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
23200
23201 2004-03-30  Bruno Haible  <bruno@clisp.org>
23202
23203         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
23204         nonnull.
23205
23206 2004-03-29  Paul Eggert  <eggert@twinsun.com>
23207
23208         Merge changes to getloadavg.c from coreutils and Emacs.
23209
23210         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
23211         Define to an expression, not to the empty string.
23212         Include cloexec.h and xalloc.h.
23213         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
23214         Use set_cloexec_flag rather than rolling our own.
23215         * lib/cloexec.c, lib/cloexec.h: New files.
23216
23217 2004-03-29  Paul Eggert  <eggert@twinsun.com>
23218
23219         * m4/cloexec.m4: New file.
23220
23221 2004-03-18  Paul Eggert  <eggert@twinsun.com>
23222
23223         * lib/getopt.h: Sync with libc CVS.
23224
23225 2004-03-18  Paul Eggert  <eggert@twinsun.com>
23226             Bruno Haible  <bruno@clisp.org>
23227
23228         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
23229         mbswidth.
23230
23231 2004-03-18  Paul Eggert  <eggert@twinsun.com>
23232             Bruno Haible  <bruno@clisp.org>
23233
23234         * lib/mbswidth.h: Include <wchar.h> only if
23235         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
23236         <wchar.h>.
23237         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
23238
23239 2004-03-09  Paul Eggert  <eggert@twinsun.com>
23240
23241         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
23242         Sync with libc CVS.
23243         * lib/getopt_int.h: New file, also synced from libc.
23244
23245 2004-03-09  Paul Eggert  <eggert@twinsun.com>
23246
23247         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
23248         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
23249         Bring back getopt.c, getopt.h, getopt1.c.
23250
23251 2004-03-07  Paul Eggert  <eggert@twinsun.com>
23252
23253         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
23254         All uses changed.  Check for sa_sigaction member; this fixes
23255         a bug first reported by Jason Andrade in
23256         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
23257
23258 2004-03-07  Paul Eggert  <eggert@twinsun.com>
23259
23260         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
23261         '#if' expressions.  Unlike the code it replaces, it does not
23262         depend on (defined _SC_PAGESIZE).  However, it does depend on
23263         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
23264         first reported by Jason Andrade in
23265         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
23266
23267 2004-02-25  Simon Josefsson  <jas@extundo.com>
23268
23269         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
23270
23271 2004-02-25  Simon Josefsson  <jas@extundo.com>
23272
23273         * lib/strdup.h: New file.
23274         * lib/strdup.c: Include it.
23275         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
23276         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
23277
23278 2004-02-23  Karl Berry  <karl@gnu.org>
23279
23280         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
23281         (from fencepost.gnu.org:/gd/gnuorg).
23282
23283 2004-02-23  Karl Berry  <karl@gnu.org>
23284
23285         * config/srclistvars.sh (GNUORG) [karl]: redefine.
23286         * config/srclist.txt: add maintain/standards documents.
23287
23288 2004-02-18  Bruno Haible  <bruno@clisp.org>
23289
23290         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
23291         Reported by Derek Robert Price <derek@ximbiot.com>.
23292
23293 2004-02-16  Karl Berry  <karl@gnu.org>
23294
23295         * config/mkinstalldirs, install-sh: update from automake.
23296
23297 2004-02-06  Karl Berry  <karl@gnu.org>
23298
23299         * m4/po.m4: update from gettext 0.14.1.
23300
23301 2004-02-06  Karl Berry  <karl@gnu.org>
23302
23303         * lib/config.charset: update from gettext 0.14.1.
23304
23305 2004-02-05  Paul Eggert  <eggert@twinsun.com>
23306
23307         Add comments and code, prompted by suggestions from Bruno Haible
23308         for sh-quote.
23309         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
23310         describing the enum quoting_style values.
23311         * lib/quotearg.c (quotearg_alloc): New function.
23312         (quotearg_buffer_restyled): Treat lone { and } as special.
23313         Treat = as special.  Work around bug with older shells
23314         that "see" a '\' that is really the 2nd byte of a multibyte char.
23315         Quote empty string with shell_quoting_style.
23316
23317 2004-02-03  Bruno Haible  <bruno@clisp.org>
23318
23319         * m4/pipe.m4: New file, from GNU gettext.
23320
23321 2004-02-03  Bruno Haible  <bruno@clisp.org>
23322
23323         * lib/pipe.h: New file, from GNU gettext.
23324         * lib/pipe.c: New file, from GNU gettext.
23325
23326 2004-01-27  Bruno Haible  <bruno@clisp.org>
23327
23328         * m4/execute.m4: New file, from GNU gettext.
23329
23330 2004-01-27  Bruno Haible  <bruno@clisp.org>
23331
23332         * lib/execute.h: New file, from GNU gettext.
23333         * lib/execute.c: New file, from GNU gettext.
23334         * lib/w32spawn.h: New file, from GNU gettext.
23335
23336 2004-01-24  Paul Eggert  <eggert@twinsun.com>
23337
23338         Merge from diffutils.
23339
23340         * lib/file-type.c (file_type): Add typed memory objects.
23341         * lib/file-type.h (S_TYPEISTMO): New macro.
23342
23343         * lib/c-stack.h (c_stack_action): Remove argv argument.
23344         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
23345         (die): Don't calculate message unless segv_action returns.
23346         (get_stack_location, min_address_from_argv, max_address_from_argv,
23347         volatile stack_base, volatile_stack_size): Remove.
23348         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
23349         that every segmentation violation is a stack overflow.  (Ouch!)
23350         See Debian bug 136249 (still outstanding) for more info about why
23351         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
23352
23353 2004-01-24  Paul Eggert  <eggert@twinsun.com>
23354
23355         Exit-status fix from coreutils.
23356
23357         Use exit_failure consistently in place of EXIT_FAILURE,
23358         so that program exit statuses are consistent on failure.
23359
23360         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
23361         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
23362         * lib/argmatch.h: Comment fix to match the above.
23363         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
23364         Now a macro referring to exit_failure, instead of a separate
23365         variable.  Include "exitfail.h" to get it.
23366         * lib/xstrtol.h: Include "exitfail.h".
23367         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
23368
23369         * lib/long-options.c (parse_long_options): Use prototype
23370         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
23371         for clarity.
23372
23373 2004-01-21  Jim Meyering  <jim@meyering.net>
23374
23375         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
23376         so as not to conflict with a different-sized __mktime_internal
23377         function in GNU libc.
23378         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
23379         Problem building statically-linked `ls' reported by Michael Brunnbauer.
23380
23381 2004-01-20  Karl Berry  <karl@gnu.org>
23382
23383         * config/config.guess: update from config.
23384
23385         * config/srclistvars.sh: GNUWWWLICENSES for karl.
23386
23387 2004-01-20  Bruno Haible  <bruno@clisp.org>
23388
23389         Safer stack allocation.
23390         * lib/setenv.c: Include allocsa.h.
23391         (alloca): Remove fallback definition.
23392         (freea): Remove macro.
23393         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
23394         instead of freea.
23395
23396 2004-01-20  Bruno Haible  <bruno@clisp.org>
23397
23398         * m4/eealloc.m4: New file, from GNU gettext.
23399
23400 2004-01-20  Bruno Haible  <bruno@clisp.org>
23401
23402         * m4/allocsa.m4: New file, from GNU gettext.
23403
23404 2004-01-20  Bruno Haible  <bruno@clisp.org>
23405
23406         * lib/xallocsa.h: New file, from GNU gettext.
23407         * lib/xallocsa.c: New file, from GNU gettext.
23408
23409 2004-01-20  Bruno Haible  <bruno@clisp.org>
23410
23411         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
23412
23413 2004-01-20  Bruno Haible  <bruno@clisp.org>
23414
23415         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
23416         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
23417         specially.
23418
23419 2004-01-20  Bruno Haible  <bruno@clisp.org>
23420
23421         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
23422         patch.
23423
23424 2004-01-20  Bruno Haible  <bruno@clisp.org>
23425
23426         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
23427
23428 2004-01-20  Bruno Haible  <bruno@clisp.org>
23429
23430         * lib/eealloc.h: New file.
23431
23432 2004-01-20  Bruno Haible  <bruno@clisp.org>
23433
23434         * lib/binary-io.h: Avoid warnings on Cygwin.
23435
23436 2004-01-20  Bruno Haible  <bruno@clisp.org>
23437
23438         * lib/allocsa.h: New file, from GNU gettext.
23439         * lib/allocsa.c: New file, from GNU gettext.
23440
23441 2004-01-18  Karl Berry  <karl@gnu.org>
23442
23443         * doc/gpl.texi, doc/lgpl.texi: new files.
23444
23445 2004-01-18  Karl Berry  <karl@gnu.org>
23446
23447         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
23448         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
23449
23450 2004-01-15  Paul Eggert  <eggert@twinsun.com>
23451
23452         Merge from coreutils.
23453
23454         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
23455         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
23456         (gl_DEFAULT_POSIX2_VERSION): Move
23457         the documentation from 'configure' into 'config.hin',
23458         so that 'configure --help' isn't burdened by it and
23459         we don't have to worry about its formatting there.
23460         Reword the documentation so that it's more succinct
23461         and can be run together into a single paragraph.
23462         * m4/same.m4 (gl_SAME): Check for pathconf.
23463
23464 2004-01-15  Paul Eggert  <eggert@twinsun.com>
23465
23466         Merge from coreutils.
23467
23468         * lib/posixver.c: Include posixver.h.
23469
23470         * lib/same.c: Include <stdbool.h>, <limits.h>.
23471         (_POSIX_NAME_MAX): Define if not defined.
23472         (MIN): New macro.
23473         (same_name): If file names are silently truncated, report
23474         that the file names are the same if they are the same after
23475         the silent truncation.
23476
23477         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
23478         conversion function.
23479         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
23480         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
23481         longer needed.
23482
23483 2004-01-15  Jim Meyering  <jim@meyering.net>
23484
23485         Merge from coreutils.
23486
23487         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
23488         if no library is required.
23489         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
23490         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
23491         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
23492         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
23493         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
23494         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
23495         value, $ac_cv_search_crypt, if it's "none required".
23496         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
23497         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
23498         not gl_FUNC_GETLOADAVG.
23499         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
23500         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
23501
23502 2004-01-15  Jim Meyering  <jim@meyering.net>
23503
23504         Merge from coreutils.
23505
23506         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
23507         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
23508         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
23509
23510         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
23511         optional configure-time default.
23512
23513         * lib/version-etc.c (version_etc_copyright): Update copyright date.
23514
23515         * lib/xreadlink.c (xreadlink): Correct outdated comment.
23516
23517 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
23518
23519         Merge from coreutils.
23520
23521         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
23522         value, $ac_cv_search_nanosleep, if it's "none required".
23523
23524 2004-01-14  Paul Eggert  <eggert@twinsun.com>
23525
23526         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
23527         with like-named macro in fnmatch.c.
23528         (EXT): Use an internal constant instead.
23529
23530         Merge fnmatch patches from glibc.
23531         * lib/fnmatch.c (mbsinit): Remove define.
23532         Add libc_hidden_ver (__fnmatch, fnmatch).
23533         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
23534         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
23535
23536 2004-01-14  Karl Berry  <karl@gnu.org>
23537
23538         * config/install-sh: update from automake.
23539
23540 2004-01-13  Karl Berry  <karl@gnu.org>
23541
23542         * config/install-sh: update from automake.
23543
23544 2004-01-09  Karl Berry  <karl@gnu.org>
23545
23546         * config/install-sh: update from automake.
23547
23548 2004-01-05  Karl Berry  <karl@gnu.org>
23549
23550         * config/config.{sub,guess}: update from config.
23551
23552 2003-12-31  Karl Berry  <karl@gnu.org>
23553
23554         * config/depcomp: update from automake.
23555
23556 2003-12-14  Karl Berry  <karl@gnu.org>
23557
23558         * lib/config.charset: update from gettext-runtime.
23559
23560 2003-12-03  Paul Eggert  <eggert@twinsun.com>
23561
23562         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
23563         Bug reported by Alfred M. Szmidt.
23564
23565 2003-12-03  Bruno Haible  <bruno@clisp.org>
23566
23567         * m4/gettext.m4: Upgrade from gettext-0.13.
23568         * m4/po.m4: Upgrade from gettext-0.13.
23569         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
23570         * m4/intmax.m4: New file, from gettext-0.13.
23571         * m4/printf-posix.m4: New file, from gettext-0.13.
23572
23573 2003-11-29  Karl Berry  <karl@gnu.org>
23574
23575         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
23576
23577 2003-11-25  Paul Eggert  <eggert@twinsun.com>
23578             Bruno Haible  <bruno@clisp.org>
23579
23580         * lib/printf-parse.h: Don't include sys/types.h.
23581         (ARG_NONE): New macro.
23582         (char_directive): Change type of *arg_index fields to size_t.
23583         * lib/printf-parse.c: Don't include sys/types.h.
23584         (SSIZE_MAX): Remove macro.
23585         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
23586         Remove unnecessary overflow check.
23587         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
23588         fields.
23589
23590 2003-11-25  Bruno Haible  <bruno@clisp.org>
23591
23592         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
23593
23594 2003-11-25  Bruno Haible  <bruno@clisp.org>
23595
23596         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
23597         gt_TYPE_SSIZE_T.
23598
23599 2003-11-24  Paul Eggert  <eggert@twinsun.com>
23600
23601         * modules/alloca: Remove dependency on xalloc.
23602
23603 2003-11-24  Paul Eggert  <eggert@twinsun.com>
23604
23605         * lib/alloca.c: Remove dependency on xalloc module.
23606         (xalloc_die): Remove.
23607         (memory_full) [!defined emacs]: New macro.
23608         [!defined emacs]: Don't include xalloc.h.
23609         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
23610         address arithmetic overflows.  Change datatypes a bit to avoid
23611         unnecessary casts.
23612
23613 2003-11-22  Jim Meyering  <jim@meyering.net>
23614
23615         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
23616         s/size/size_t/.
23617
23618 2003-11-21  Karl Berry  <karl@gnu.org>
23619
23620         * config/config.{sub,guess}: update from config.
23621
23622 2003-11-18  Karl Berry  <karl@gnu.org>
23623
23624         * config/config.{sub,guess}: update from config.
23625
23626         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
23627
23628 2003-11-17  Paul Eggert  <eggert@twinsun.com>
23629
23630         * README: Mention that S+T cannot overflow if S is the size of
23631         an existing object and T is sufficiently small.
23632
23633 2003-11-17  Jim Meyering  <jim@meyering.net>
23634
23635         On systems without utime and without a utimes function capable of
23636         dealing with a NULL struct utimbuf* argument, this utime replacement
23637         could -- in unusual circumstances -- leak a file descriptor.
23638         * lib/utime.c: Include <unistd.h> and <errno.h>.
23639         (utime_null): Be sure to close `fd' and to preserve errno.
23640         Reported by Geoff Collyer via Arnold Robbins.
23641
23642 2003-11-17  Bruno Haible  <bruno@clisp.org>
23643
23644         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
23645         (Depends-on): Add xsize.
23646
23647 2003-11-17  Bruno Haible  <bruno@clisp.org>
23648
23649         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
23650
23651 2003-11-17  Bruno Haible  <bruno@clisp.org>
23652
23653         * lib/vasnprintf.c (alloca): Remove fallback definition.
23654         (freea): Remove definition.
23655         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
23656         Reported by Paul Eggert.
23657
23658 2003-11-16  Paul Eggert  <eggert@twinsun.com>
23659             Bruno Haible  <bruno@clisp.org>
23660
23661         Protect against address arithmetic overflow.
23662         * lib/printf-args.h: Include stddef.h.
23663         (arguments): Change type of field 'count' to size_t.
23664         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
23665         'unsigned int' where appropriate.
23666         * lib/printf-parse.h: Include sys/types.h.
23667         (char_directive): Change type of *arg_index fields to ssize_t.
23668         (char_directives): Change type of fields 'count', max_*_length to
23669         size_t.
23670         * lib/printf-parse.c: Include sys/types.h and xsize.h.
23671         (SSIZE_MAX): Define fallback value.
23672         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
23673         instead of 'int' where appropriate. Check a_allocated, d_allocated
23674         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
23675         * lib/vasnprintf.c: Include xsize.h.
23676         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
23677         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
23678         overflow. Avoid wraparound when converting a width or precision from
23679         decimal to binary.
23680
23681 2003-11-16  Bruno Haible  <bruno@clisp.org>
23682
23683         Update from GNU gettext.
23684         * lib/printf-parse.c: Generalize to it can be compiled for wide
23685         strings.
23686         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
23687         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
23688         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
23689         SNPRINTF): New macros.
23690         Don't include <alloca.h> if the file is used inside libintl.
23691         (local_wcslen): New function, for Solaris 2.5.1.
23692         (VASNPRINTF): Use it instead of wcslen.
23693
23694 2003-11-16  Bruno Haible  <bruno@clisp.org>
23695
23696         * lib/xsize.h (xmax): New function.
23697         (xsum, xsum3, xsum4): Declare as "pure" functions.
23698
23699 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23700
23701         * modules/xalloc (Files): Undo latest change, since xalloc.h
23702         no longer needs SIZE_MAX or PTRDIFF_MAX.
23703
23704 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23705
23706         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
23707         gl_PTRDIFF_MAX.
23708
23709 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23710
23711         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
23712         "return", to pacify some unknown compiler.  Problem reported
23713         by Joerg Schilling.
23714
23715 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23716
23717         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
23718         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
23719         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
23720         heuristic is just as accurate as far as we know, and it removes a
23721         dependency on size_max.m4 and ptrdiff_max.m4.
23722
23723 2003-11-11  Bruno Haible  <bruno@clisp.org>
23724
23725         * modules/xsize (Files): Add m4/size_max.m4.
23726         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
23727
23728 2003-11-11  Bruno Haible  <bruno@clisp.org>
23729
23730         * m4/size_max.m4: New file.
23731         * m4/ptrdiff_max.m4: New file.
23732         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
23733         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
23734         (gl_XALLOC): Invoke it.
23735
23736 2003-11-11  Bruno Haible  <bruno@clisp.org>
23737
23738         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
23739         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
23740         defined.
23741
23742 2003-11-10  Paul Eggert  <eggert@twinsun.com>
23743
23744         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
23745         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
23746         rejected some allocations of exactly SIZE_MAX - 2 bytes.
23747         From Bruno Haible.
23748         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
23749         not (size_t) -1, since it's defined here.
23750
23751 2003-11-09  Karl Berry  <karl@gnu.org>
23752
23753         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
23754
23755 2003-11-06  Paul Eggert  <eggert@twinsun.com>
23756
23757         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
23758         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
23759         Reject sizes of exactly SIZE_MAX bytes.
23760         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
23761         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
23762
23763 2003-11-05  Bruno Haible  <bruno@clisp.org>
23764
23765         * lib/xsize.h: Include limits.h, to avoid a possible collision with
23766         SIZE_MAX defined in <limits.h> on Solaris.
23767
23768 2003-11-04  Jim Meyering  <jim@meyering.net>
23769
23770         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
23771         variable names, rather than @VAR@.
23772         * modules/poll: Likewise.
23773
23774 2003-11-04  Bruno Haible  <bruno@clisp.org>
23775
23776         * modules/xsize: New file.
23777         * modules/linebreak: Depend on xsize.
23778         * MODULES.html.sh (func_all_modules): Add xsize.
23779
23780 2003-11-04  Bruno Haible  <bruno@clisp.org>
23781
23782         * m4/xsize.m4: New file.
23783
23784 2003-11-04  Bruno Haible  <bruno@clisp.org>
23785
23786         * lib/xsize.h: New file.
23787         * lib/linebreak.c: Include xsize.h.
23788         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
23789         argument for overflow.
23790         Suggested by Paul Eggert.
23791
23792 2003-11-03  Karl Berry  <karl@gnu.org>
23793
23794         * config/config.{guess,sub}: update from config.
23795
23796 2003-11-03  Jim Meyering  <jim@meyering.net>
23797
23798         * modules/userspec (lib_SOURCES): Add userspec.h.
23799         (Include): Add "userspec.h".
23800         Improve description.
23801
23802 2003-11-03  Jim Meyering  <jim@meyering.net>
23803
23804         * lib/userspec.c: Include "userspec.h".
23805         * lib/userspec.h: New file.
23806
23807 2003-11-03  Bruno Haible  <bruno@clisp.org>
23808
23809         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
23810
23811 2003-11-03  Bruno Haible  <bruno@clisp.org>
23812
23813         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
23814         available, to avoid (extremely rare) race condition.
23815         Suggested by Paul Eggert.
23816
23817 2003-11-02  Karl Berry  <karl@gnu.org>
23818
23819         * config/srclist.txt (vasprintf.c): sync broken, sigh.
23820
23821 2003-10-31  Paul Eggert  <eggert@twinsun.com>
23822
23823         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
23824         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
23825         (read_filesystem_list): Set and use me_type_malloced.
23826         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
23827         whatever the type happens to be), for brevity and consistency.
23828         Check for size calculation overflow on Alphas running OSF/1.
23829
23830 2003-10-31  Jim Meyering  <jim@meyering.net>
23831
23832         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
23833
23834         * lib/linebuffer.c: Include <string.h> for declaration of memset.
23835
23836 2003-10-30  Paul Eggert  <eggert@twinsun.com>
23837             Bruno Haible  <bruno@clisp.org>
23838
23839         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
23840         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
23841
23842 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
23843
23844         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
23845         netbsd*-gnu*.  Suggested by Robert Millan.
23846
23847 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23848
23849         * modules/group-member: Depend on stdbool.
23850
23851 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23852
23853         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
23854
23855 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23856
23857         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
23858         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
23859         after the 'gnu' in these cases.  This fixes some bugs in the
23860         previous change, and is based on suggestions by Robert Millan.
23861
23862 2003-10-29  Paul Eggert  <eggert@twinsun.com>
23863
23864         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
23865         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
23866         no longer needed.
23867         * lib/quotearg.c (quotearg_n_options): Use it.
23868         * lib/group-member.c: Include <stdbool.h>.
23869         (free_group_info): Arg is now const *; don't free arg.
23870         (get_group_info): Now returns bool and accepts struct group_info *,
23871         rather than returning a malloc'ed struct group_info *.
23872         All uses changed.  Check for overflow in internal size calculation.
23873
23874         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
23875         rather than xmalloc/xrealloc.
23876         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
23877         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
23878         conformance bug: the old code used a pointer after freeing the
23879         storage that it addressed.
23880         * lib/hash.c (hash_initialize): Simplify the code by using
23881         xalloc_oversized rather than doing it by hand.
23882         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
23883         the buffer preserved.  Use free and xmalloc instead.
23884         * lib/quotearg.c (quotearg_n_options): Likewise.
23885         Use a simpler test for size overflow.  Don't use xalloc_oversized
23886         because unsigned int might be wider than size_t (!); this suggests
23887         that we should switch from unsigned int to size_t for slot numbers.
23888
23889 2003-10-28  Paul Eggert  <eggert@twinsun.com>
23890
23891         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
23892         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
23893         NetBSD kernels.  Requested by Richard Stallman.
23894
23895 2003-10-27  Paul Eggert  <eggert@twinsun.com>
23896
23897         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
23898         to allocate the returned structure.  Do not allocate a subarray,
23899         as x2nrealloc will do that.
23900         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
23901         instead of xnrealloc.
23902         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
23903
23904 2003-10-27  Bruno Haible  <bruno@clisp.org>
23905
23906         * lib/stdbool_.h: Better support for BeOS.
23907
23908 2003-10-26  Paul Eggert  <eggert@twinsun.com>
23909
23910         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
23911         now uses inline.
23912
23913 2003-10-26  Paul Eggert  <eggert@twinsun.com>
23914
23915         * lib/xalloc.h (xalloc_oversized): New static inline function, for
23916         callers that want to do their own size-overflow checking.  Include
23917         <stdbool.h>, since xalloc_oversized returns bool.
23918         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
23919         to use xalloc_oversized.
23920
23921         Add two functions x2realloc, x2nrealloc, for programs that grow
23922         arrays dynamically by doubling their sizes.
23923         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
23924         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
23925         New functions.
23926
23927         Port to C99 semantics for 'inline' of external functions.
23928         Bug reported by Bruno Haible.
23929         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
23930         with the old contents of xnmalloc.
23931         (xnmalloc, xmalloc): Use it.
23932         (xnrealloc_inline): New static inline function,
23933         with the old contents of xnrealloc.
23934         (xnrealloc, xrealloc): Use it.
23935
23936         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
23937         that.
23938
23939 2003-10-26  Karl Berry  <karl@gnu.org>
23940
23941         * config/srclist.txt (COPYING.DOC): no longer available from
23942         /gd/gnuorg; don't know where the ultimate source is.
23943
23944 2003-10-25  Paul Eggert  <eggert@twinsun.com>
23945
23946         Fix several address-calculation bugs in the hash modules,
23947         plus some minor code cleanup.
23948
23949         * lib/hash.h: Include <stdbool.h>, for bool.
23950         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
23951         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
23952         hash_get_n_entries, hash_get_max_bucket_length,
23953         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
23954         hash_rehash): Use size_t rather than unsigned.
23955         * lib/hash.c (struct hash_table, hash_get_n_buckets,
23956         hash_get_n_buckets_used, hash_get_n_entries,
23957         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
23958         hash_get_entries, hash_do_for_each, hash_string, is_prime,
23959         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
23960         Likewise.
23961         (SIZE_MAX): Define if not defined.
23962         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
23963         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
23964         hash_print):
23965         Use const * when possible.
23966         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
23967         (check_tuning): Fix bug: if tuning parameters were very close to
23968         0 or 1, rounding errors could have caused subscript violations.
23969         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
23970         (hash_initialize): Add 'fail:' label
23971         to free table and return NULL, and use it to simplify code.
23972         Use calloc rather than clearing the storage ourself.
23973         (hash_initialize, hash_rehash): Check for arithmetic overflow in
23974         buffer size calculations.
23975         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
23976         Include <stddef.h>, for size_t.
23977         * lib/hash-pjw.c (hash_pjw): Likewise.
23978         Switch to method described by Bruno Haible.
23979         Include <limits.h>, for CHAR_BIT.
23980         (SIZE_BITS): New macro.
23981
23982 2003-10-23  Paul Eggert  <eggert@twinsun.com>
23983
23984         * m4/getline.m4 (AM_FUNC_GETLINE):
23985         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
23986         hosts.  Problem reported by Derek Robert Price in
23987         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
23988         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
23989         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
23990
23991 2003-10-21  Paul Eggert  <eggert@twinsun.com>
23992
23993         * lib/getndelim2.c (getndelim2): When size calculation overflows,
23994         ceiling the allocation at NMAX bytes rather than silently
23995         discarding input bytes before NMAX is reached.  This makes
23996         a difference only if NMAX exceeds SIZE_MAX / 2.
23997
23998         * lib/obstack.c: Merge from glibc.
23999         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
24000         Add libc_hidden_def (_obstack_newchunk).
24001         (_obstack_free) [! defined _LIBC]: Remove.
24002         [defined _LIBC]: Make a strong alias from obstack_free, rather than
24003         a clone of the function body.
24004         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
24005         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
24006
24007         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
24008         glibc.
24009         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
24010         arg to memcpy.
24011
24012         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
24013         (obstack_ptr_grow_fast, obstack_int_grow_fast):
24014         Don't use lvalue casts, as GCC plans to remove support for them
24015         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
24016         was also present in the non-GCC version, indicating that this
24017         code had always been buggy and had never been widely used.
24018         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
24019         Use the fast variant of each macro, rather than copying the
24020         definiens of the fast variant; that way, we'll be more likely to
24021         catch future bugs in the fast variants.
24022
24023 2003-10-20  Bruno Haible  <bruno@clisp.org>
24024
24025         * modules/wait-process: New file.
24026         * MODULES.html.sh (func_all_modules): Add wait-process.
24027
24028 2003-10-20  Bruno Haible  <bruno@clisp.org>
24029
24030         * m4/wait-process.m4: New file.
24031
24032 2003-10-20  Bruno Haible  <bruno@clisp.org>
24033
24034         * lib/wait-process.h: New file, from GNU gettext.
24035         * lib/wait-process.c: New file, from GNU gettext.
24036
24037 2003-10-19  Jim Meyering  <jim@meyering.net>
24038
24039         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
24040         HPUX 10.20.
24041
24042 2003-10-18  Karl Berry  <karl@gnu.org>
24043
24044         * config/config.guess: update from config.
24045
24046 2003-10-16  Paul Eggert  <eggert@twinsun.com>
24047
24048         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
24049         (getgroups): First arg is int, not size_t.
24050         Don't let 'free' mangle errno.
24051
24052 2003-10-16  Paul Eggert  <eggert@twinsun.com>
24053
24054         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
24055
24056 2003-10-16  Karl Berry  <karl@gnu.org>
24057
24058         * config/config.{guess,sub}: update from config.
24059
24060 2003-10-16  Jim Meyering  <jim@meyering.net>
24061
24062         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
24063         memcpy.
24064
24065 2003-10-15  Paul Eggert  <eggert@twinsun.com>
24066
24067         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
24068         (SIZE_MAX): Remove.
24069         (new_exclude, add_exclude_file): Initial size no longer needs to
24070         be a power of 2.
24071         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
24072         our own address arithmetic overflow checking.
24073
24074         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
24075         (fnmatch): Do not alloca more than 2000 wide characters;
24076         instead, use malloc for large buffers.
24077         Check for address arithmetic overflow, and return -1
24078         with errno set to ENOMEM in that case.
24079         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
24080         (NEW_PATTERN): Do not alloca more than 8000 bytes;
24081         instead, return -1.  Check for address arithmetic overflow.
24082
24083 2003-10-14  Paul Eggert  <eggert@twinsun.com>
24084
24085         Handle invalid suffixes and overflow independently, so that
24086         callers can treat them independently as needed.  Fix some bugs in
24087         suffix handling, e.g., "100k@" was not diagnosed as an invalid
24088         suffix for a human-readable blocksize.  The major caller-visible
24089         change is the addition of a new
24090         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
24091         that both overflow and suffix chars were found.
24092
24093         * lib/human.c (humblock): Don't check separately for invalid suffix
24094         char; that is xstrtoumax's job (now that its bug is fixed).
24095         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
24096         INTMAX_MAX]: New macros.
24097         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
24098         TYPE_MAXIMUM): New macros.
24099         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
24100         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
24101         if overflow occurs, as it's what __strtol does and it's more useful
24102         in practice.
24103         (__xstrtol): If __strtol reports some error other than ERANGE,
24104         reflect it to the caller as LONGINT_INVALID.  If it reports
24105         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
24106         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
24107         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
24108         value.
24109         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
24110         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
24111         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
24112         [defined UINTMAX_MAX]: New macros.
24113
24114 2003-10-14  Bruno Haible  <bruno@clisp.org>
24115
24116         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
24117
24118 2003-10-14  Bruno Haible  <bruno@clisp.org>
24119
24120         * m4/sig_atomic_t: New file, from GNU gettext.
24121         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
24122
24123 2003-10-14  Bruno Haible  <bruno@clisp.org>
24124
24125         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
24126         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
24127         Also use volatile where needed.
24128
24129 2003-10-12  Paul Eggert  <eggert@twinsun.com>
24130
24131         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
24132         Change maintainer from Bruno Haible to 'all'.
24133
24134 2003-10-12  Paul Eggert  <eggert@twinsun.com>
24135
24136         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
24137
24138 2003-10-12  Paul Eggert  <eggert@twinsun.com>
24139
24140         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
24141         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
24142         and define in terms of the other primitives.
24143         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
24144         (SIZE_MAX): Define if not already defined.
24145         (array_size_overflow): New function.
24146         (xalloc_die): Abort instead of exiting if 'error' returns.
24147         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
24148         (xmalloc, xrealloc): Use them.
24149         (xcalloc): Check for address arithmetic overflow.
24150         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
24151         a bit faster than strcpy.
24152
24153 2003-10-10  Simon Josefsson  <jas@extundo.com>
24154
24155         * modules/argp (Depends-on): Add restrict and strcase.
24156
24157 2003-10-10  Simon Josefsson  <jas@extundo.com>
24158
24159         * m4/argp.m4: Add AC_C_INLINE.
24160
24161 2003-10-08  Paul Eggert  <eggert@twinsun.com>
24162
24163         Merge getpass from libc, plus a few fixes.
24164
24165         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
24166         Include <stdbool.h>.
24167         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
24168         __fsetlocking to empty.
24169         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
24170         do include <bits/libc-lock.h>.
24171         Do not include <fcntl.h>; not needed.
24172         [_LIBC]: Include <wchar.h>.
24173         (NOTCANCEL_MODE): New macro.
24174         (flockfile, funlockfile) [_LIBC]: New macros.
24175         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
24176         [!_LIBC]: New macros.
24177         (call_fclose): New function.
24178         (getpass): Use it.  Save tty stream separately; this simplifies the
24179         code and makes it more reliable if stdin happens to equal stdout.
24180         Invoke __fsetlocking on tty.
24181         Handle thread cancellation if needed.
24182         Namespace cleanup (use __tcgetattr, __getline).
24183         Use bool for Booleans.
24184         [USE_IN_LIBIO]: Handle wide streams.
24185         [!_LIBC]: Unconditionally do the fseek, since we don't know what
24186         stream might go where.
24187
24188         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
24189         doesn't have to include <stdio.h> before us.
24190         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
24191         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
24192         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
24193         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
24194         if not declared, so that we can use getpass.c code from libc without
24195         rewriting it.
24196         (flockfile, ftrylockfile, funlockfile): New macros.
24197
24198 2003-10-08  Paul Eggert  <eggert@twinsun.com>
24199
24200         * modules/getpass: Depend on stdbool.
24201
24202 2003-10-08  Paul Eggert  <eggert@twinsun.com>
24203
24204         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
24205
24206 2003-10-07  Karl Berry  <karl@gnu.org>
24207
24208         * config/config.{guess,sub}: update from config.
24209
24210 2003-10-06  Jim Meyering  <jim@meyering.net>
24211             Bruno Haible  <bruno@clisp.org>
24212
24213         This lets translators provide better translations for the
24214         "Written by ..." part of --version output.
24215         * lib/version-etc.h: Include stdarg.h.
24216         (version_etc_copyright): Declare as readonly.
24217         (version_etc): Make this function variadic with a NULL-terminated list
24218         of author name strings.
24219         (version_etc_va): New declaration.
24220         * lib/version-etc.c: Include stdarg.h, stdlib.h.
24221         (version_etc_copyright): Declare as readonly.
24222         (version_etc_va): New function. Provide a different translatable string
24223         for each possible number of authors < 10. Abbreviate when there are 10
24224         authors or more.
24225         (version_etc): Make this function variadic. Call version_etc_va.
24226         Suggestion from Gary V. Vaughan.
24227
24228         * lib/long-options.h (parse_long_options): Change prototype: the
24229         authors string is moved to the end and becomes variadic.
24230         * lib/long-options.c: Include stdarg.h.
24231         (parse_long_options): Make this function variadic, too.
24232         Call version_etc_va, not version_etc.
24233
24234 2003-10-06  Bruno Haible  <bruno@clisp.org>
24235
24236         * modules/version-etc-2: Remove file.
24237         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
24238
24239 2003-10-06  Bruno Haible  <bruno@clisp.org>
24240
24241         * modules/fatal-signal: New file.
24242         * MODULES.html.sh (func_all_modules): Add fatal-signal.
24243
24244 2003-10-06  Bruno Haible  <bruno@clisp.org>
24245
24246         * m4/fatal-signal.m4: New file.
24247         * m4/signalblocking.m4: New file, from GNU gettext.
24248
24249 2003-10-06  Bruno Haible  <bruno@clisp.org>
24250
24251         * lib/version-etc-2.h: Remove file.
24252         * lib/version-etc-2.c: Remove file.
24253
24254 2003-10-06  Bruno Haible  <bruno@clisp.org>
24255
24256         * lib/fatal-signal.h: New file, from GNU gettext.
24257         * lib/fatal-signal.c: New file, from GNU gettext.
24258
24259 2003-10-05  Paul Eggert  <eggert@twinsun.com>
24260
24261         * README: Rework advice for preventing empty .o files.
24262         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
24263         not <sys/types.h>.
24264
24265 2003-10-04  Karl Berry  <karl@gnu.org>
24266
24267         * lib/argp*: update from libc.
24268
24269 2003-10-04  Karl Berry  <karl@gnu.org>
24270
24271         * config/config.{guess,sub}: update from config.
24272
24273 2003-10-02  Bruno Haible  <bruno@clisp.org>
24274
24275         * modules/lchown (Include): Add lchown.h.
24276         * modules/time_r (Include): Use "..." syntax.
24277         * modules/xgetdomainname (Include): Add xgetdomainname.h.
24278
24279 2003-10-01  Simon Josefsson  <jas@extundo.com>
24280
24281         * MODULES.html.sh (func_all_modules): Move gethostname from section
24282         'based on' to section 'lacking' POSIX:2001.
24283
24284 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
24285
24286         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
24287         to output mode on the same stream.
24288
24289 2003-09-29  Paul Eggert  <eggert@twinsun.com>
24290
24291         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
24292         Fix arg typo in previous patch.
24293
24294 2003-09-28  Jim Meyering  <jim@meyering.net>
24295
24296         * lib/error.c: Correct cpp indentation.
24297
24298 2003-09-27  Paul Eggert  <eggert@twinsun.com>
24299
24300         * modules/free: New file.
24301
24302 2003-09-27  Paul Eggert  <eggert@twinsun.com>
24303
24304         * m4/free.m4: New file.
24305
24306 2003-09-27  Paul Eggert  <eggert@twinsun.com>
24307
24308         * lib/minmax.h (MIN, MAX)
24309         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
24310         Omit the special code that used __typeof__, since we worry that
24311         it could be more trouble than it's worth.  See:
24312         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
24313         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
24314
24315         * lib/free.c: New file.
24316
24317 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
24318
24319         Trivial fixes to Makefile.am parts of module listings.
24320         * modules/strstr: Append strstr.h to lib_SOURCES.
24321         * modules/strcase: Likewise, for strcase.h.
24322
24323 2003-09-27  Karl Berry  <karl@gnu.org>
24324
24325         * config/mkinstalldirs: update from automake.
24326
24327 2003-09-26  Paul Eggert  <eggert@twinsun.com>
24328
24329         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
24330         (error_tail): Do not loop, reallocating temporary buffer, since
24331         the output cannot contain more wide characters than the input
24332         contains bytes, the size must be big enough already.  This avoids
24333         one potential size overflow calculation.  Check for size overflow
24334         when calculating temporary buffer size.  Free temporary buffer
24335         when done, if it was allocated with malloc; this plugs a memory
24336         leak.  Remove casts from void * to pointers, that are no longer
24337         needed now that we're assuming C89 or better.
24338
24339         Merge error changes from glibc.
24340
24341         * lib/error.c, error.h: Update copyright notice header to match glibc.
24342         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
24343         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
24344         Disable cancellation while printing error.
24345         * lib/error.h: Prepend __ to parameter names.
24346
24347 2003-09-26  Jim Meyering  <jim@meyering.net>
24348
24349         * lib/error.c (error_tail): Move some declarations
24350         into inner scope where the local variables are used.
24351
24352 2003-09-26  Bruno Haible  <bruno@clisp.org>
24353
24354         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
24355         stpncpy().
24356         Don't define stpncpy through config.h; it's now done through stpncpy.h.
24357
24358 2003-09-26  Bruno Haible  <bruno@clisp.org>
24359
24360         * lib/stpncpy.h (gnu_stpncpy): New declaration.
24361         (stpncpy): Define as alias for gnu_stpncpy.
24362         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
24363
24364 2003-09-25  Simon Josefsson  <jas@extundo.com>
24365
24366         * lib/xgetdomainname.h: New file.
24367         * lib/xgetdomainname.c: New file.
24368
24369 2003-09-25  Simon Josefsson  <jas@extundo.com>
24370             Bruno Haible  <bruno@clisp.org>
24371
24372         * modules/getdomainname: New file.
24373         * modules/xgetdomainname: New file.
24374         * MODULES.html.sh (func_all_modules): Add getdomainname,
24375         xgetdomainname.
24376
24377 2003-09-25  Simon Josefsson  <jas@extundo.com>
24378             Bruno Haible  <bruno@clisp.org>
24379
24380         * m4/getdomainname.m4: New file.
24381
24382 2003-09-25  Simon Josefsson  <jas@extundo.com>
24383             Bruno Haible  <bruno@clisp.org>
24384
24385         * lib/getdomainname.h: New file.
24386         * lib/getdomainname.c: New file.
24387
24388 2003-09-25  Karl Berry  <karl@gnu.org>
24389
24390         * lib/argp-fmtstream.c, argp-help.c: update from libc.
24391
24392 2003-09-25  Karl Berry  <karl@gnu.org>
24393
24394         * config/install-sh: update from automake.
24395
24396 2003-09-25  Bruno Haible  <bruno@clisp.org>
24397
24398         * modules/version-etc-2: New file, from modules/version-etc with
24399         modifications.
24400         * MODULES.html.sh (func_all_modules): Add version-etc-2.
24401
24402 2003-09-25  Bruno Haible  <bruno@clisp.org>
24403
24404         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
24405         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
24406
24407 2003-09-24  Simon Josefsson  <jas@extundo.com>
24408
24409         * modules/xgethostname: Add xgethostname.h.
24410
24411 2003-09-24  Paul Eggert  <eggert@twinsun.com>
24412
24413         * lib/linebuffer.c (freebuffer): Don't free the argument, just
24414         the buffer associated with the argument.  Bug reported by
24415         Simon Josefsson.
24416
24417 2003-09-24  Paul Eggert  <eggert@twinsun.com>
24418
24419         * README: Document assumptions that 'int' is at least 32 bits
24420         wide, that integer arithmetic is 2's complement without overflow,
24421         that there are no holes in integer values, that adding sizes of
24422         two nonoverlapping objects can't overflow, and that all-bits-zero
24423         yields scalar zero.  Fix spelling and capitalization typos.
24424
24425 2003-09-19  Karl Berry  <karl@gnu.org>
24426
24427         * lib/argp.h: update from libc.
24428
24429 2003-09-17  Paul Eggert  <eggert@twinsun.com>
24430
24431         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
24432         to avoid spurious warnings like "AC_RUN_IFELSE was called before
24433         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
24434
24435 2003-09-17  Paul Eggert  <eggert@twinsun.com>
24436
24437         * gnulib-tool: Use "test -h", not "test -L", for portability
24438         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
24439         (tags_regexp): Remove, since \| doesn't conform to POSIX.
24440         (sed_extract_prog): Issue s commands one-by-one, rather than
24441         using \| in one s command.
24442
24443 2003-09-16  Paul Eggert  <eggert@twinsun.com>
24444
24445         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
24446         input error, instead of returning NULL the next time we are called
24447         (and therefore losing track of errno).
24448
24449 2003-09-16  Bruno Haible  <bruno@clisp.org>
24450
24451         * gnulib-tool (func_create_testdir): Warn about duplicated
24452         dependencies.
24453
24454 2003-09-15  Paul Eggert  <eggert@twinsun.com>
24455
24456         * modules/argmatch, modules/fatal, modules/obstack,
24457         modules/xalloc, modules/xgethostname: Sort dependencies by
24458         importance, not alphabetically.
24459
24460 2003-09-15  Paul Eggert  <eggert@twinsun.com>
24461
24462         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
24463         fails, so that the caller gets the proper errno.
24464
24465         * lib/readutmp.c (read_utmp): Likewise.
24466         Check for fstat error.  Close stream and free storage
24467         when failing.
24468
24469 2003-09-14  Karl Berry  <karl@gnu.org>
24470
24471         * config/srclist.txt (strdup.c): disable for c89 changes.
24472
24473 2003-09-14  Jim Meyering  <jim@meyering.net>
24474
24475         * lib/getloadavg.c: Correct cpp indentation.
24476         * lib/strdup.c: Likewise.
24477         * lib/vasnprintf.c: Likewise.
24478
24479 2003-09-14  Bruno Haible  <bruno@clisp.org>
24480
24481         * modules/fwriteerror: New file.
24482         * MODULES.html.sh (func_all_modules): Add fwriteerror.
24483
24484 2003-09-14  Bruno Haible  <bruno@clisp.org>
24485
24486         * lib/fwriteerror.h: New file.
24487         * lib/fwriteerror.c: New file.
24488
24489 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24490
24491         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
24492         modules/xgethostname, modules/xalloc: Depend on exit.
24493
24494 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24495
24496         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
24497
24498         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
24499         and AC_MINIX, too, so that their extensions are available.
24500
24501         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
24502         This macro has been superseded by gl_BACKUPFILE.
24503
24504         More patches to assume C89 or better.
24505
24506         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
24507
24508         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
24509         unconditionally.
24510         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
24511         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
24512         Include <string.h>, <stdlib.h> unconditionally.
24513         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
24514         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
24515         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
24516         headers or for string.h.
24517         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
24518         or strtoul.
24519
24520         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
24521         headers.
24522         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
24523         * m4/userspec.m4 (gl_USERSPEC): Likewise.
24524         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
24525         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
24526         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
24527         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
24528         memcpy, memset.
24529         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
24530         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
24531         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
24532         strtol.
24533         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
24534         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
24535         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
24536         strtoul.
24537
24538 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24539
24540         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
24541         * lib/obstack.c [!defined _LIBC]: Likewise.
24542         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
24543         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
24544         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
24545
24546         More changes to assume C89 or better.
24547
24548         * lib/error.c (error_tail): Assume vprintf.
24549
24550         * lib/argmatch.c (getenv): Remove decl.
24551         * lib/progreloc.c (get_full_program_name): Define via prototype.
24552         * lib/setenv.c (clearenv): Likewise.
24553         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
24554         needed.
24555         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
24556         (malloc, memcpy): Remove decls.
24557         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
24558         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
24559         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
24560         (memcpy): Remove macro.
24561         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
24562         (__P): Remove.  All uses removed.
24563         (PTR): Remove.  All uses changed to void *.
24564         (CHAR_BIT, NULL): Remove.
24565         (spaces, zeros, memset_space, memset_zero)
24566         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
24567         Remove.
24568         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
24569         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
24570         Define with prototype.
24571         Remove now-unnecessary prototype decl.
24572         (extra_args_spec): Assume ANSI C.  All uses changed.
24573         (extra_args_spec_iso): Remove.
24574         (my_strftime, emacs_strftimeu): Define via prototype.
24575         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
24576         unconditionally.
24577         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
24578         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
24579         (strtoul, strtol): Remove decls.
24580         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
24581         LONG_MAX): Remove.
24582         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
24583         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
24584         (LOCALE_PARAM_PROTO): New macro.
24585         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
24586         (INTERNAL (strtol), strtol): Define with a prototype.
24587         (PARAMS): Remove.  All uses removed.
24588         * lib/tempname.c: Include <string.h> unconditionally.
24589         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
24590         * lib/xgethostname.c (main): Define with a prototype.
24591         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
24592         Include <stdlib.h> unconditionally.
24593         (calloc, malloc, realloc, free): Remove decls.
24594         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
24595         Include <stdlib.h> unconditionally.  Sort include file names.
24596         (strtod): Remove.
24597         (xstrtod): Define with a prototype.
24598         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
24599         (strtol, strtoul): Remove decls.
24600
24601 2003-09-11  Paul Eggert  <eggert@twinsun.com>
24602
24603         More patches to assume C89 or better.
24604         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
24605         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
24606         string.h, memchr, STDC_HEADERS.
24607
24608 2003-09-11  Paul Eggert  <eggert@twinsun.com>
24609
24610         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
24611         Include <stdlib.h>, <string.h> unconditionally.
24612         Remove now-unnecessary cast to char *.
24613         * lib/strnlen.c: Include <string.h> unconditionally.
24614         * lib/yesno.c (yesno): Define with a prototype.
24615
24616 2003-09-11  Bruno Haible  <bruno@clisp.org>
24617
24618         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
24619
24620 2003-09-10  Jim Meyering  <jim@meyering.net>
24621
24622         * lib/error.c: Correct indentation of cpp directives.
24623
24624 2003-09-10  Bruno Haible  <bruno@clisp.org>
24625
24626         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
24627         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
24628         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
24629         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
24630         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
24631         <stdlib.h> and <string.h> checks.
24632         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
24633         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
24634
24635 2003-09-10  Bruno Haible  <bruno@clisp.org>
24636
24637         * lib/strcspn.c: Include <string.h> unconditionally.
24638         * lib/strpbrk.c: Include <string.h> unconditionally.
24639         * lib/strstr.c: Include <string.h> unconditionally.
24640         * lib/unicodeio.c: Include <string.h> unconditionally.
24641         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
24642         * lib/unsetenv.c: Likewise.
24643         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
24644         * lib/yesno.c: Include <stdlib.h> unconditionally.
24645         (rpmatch): Add prototype.
24646
24647 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24648
24649         More patches to assume C89 or better.
24650         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
24651         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
24652         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
24653         or for string.h.
24654         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
24655         stdlib.h.
24656         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
24657         C headers.
24658         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
24659         string.h.
24660         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
24661         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
24662         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
24663         or for string.h.
24664         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
24665         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
24666         C headers.
24667         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
24668         memcpy.
24669         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
24670         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
24671         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
24672         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
24673         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
24674         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
24675         string.h, free.
24676         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
24677         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
24678         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
24679         C headers, or for string.h.
24680         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
24681         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
24682         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
24683         headers, memory.h, stdlib.h, string.h, strings.h.
24684         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
24685         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
24686         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
24687         strchr.
24688         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
24689         headers, memory.h, string.h.
24690         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
24691         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
24692         free.
24693         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
24694         headers.
24695         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
24696         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
24697         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
24698         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
24699         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
24700
24701 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24702
24703         More K&R removal.
24704
24705         * lib/acosl.c (main): Use a prototype.
24706         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
24707         tanl.c: Likewise.
24708
24709         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
24710
24711         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
24712         (getopt, etopt_long, getopt_long_only, _getopt_internal)
24713         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
24714         with a prototype.
24715         * lib/getopt.c (const): Remove macro.
24716         Include <string.h> unconditionally.
24717         (my_index): Remove; all uses changed to strchr.
24718         (strlen): Remove decl.
24719         (exchange): Remove forward decl; no longer needed.
24720         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
24721         Define with prototype.
24722         * lib/getopt1.c (const): Remove macro.
24723         (getopt_long, getopt_long_only, main): Define with prototype.
24724
24725         * lib/getugroups.c: Include <string.h> unconditionally.
24726
24727         * lib/getusershell.c: Include <stdlib.h> unconditionally.
24728         (getusershell, setusershell, endusershell, readname, main):
24729         Define with prototypes.
24730
24731         * lib/group-member.c: Include group-member.h first.
24732         Include <stdlib.h> unconditionally.
24733
24734         * lib/hard-locale.c: Include hard-locale.h first.
24735         Include <stdlib.h>, <string.h> unconditionally.
24736
24737         * lib/hash.c (free, malloc): Remove decls.
24738         Include <stdlib.h> unconditionally.
24739
24740         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
24741         (getenv): Do not declare.
24742
24743         * lib/idcache.c: Include <string.h> unconditionally.
24744
24745         * lib/long-options.c: Include long-options.h first, to test interface.
24746         Include <stdlib.h> unconditionally.
24747
24748         * lib/makepath.c: Include makepath.h first, to test interface.
24749         Include <stdlib.h> and <string.h> unconditionally.
24750
24751         * lib/linebuffer.c: Include <stdlib.h>.
24752         (free): Remove decl.
24753
24754         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
24755         stddef.h. rpl_malloc returns void *, not char *.
24756         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
24757         prototype.
24758
24759         * lib/md5.h: Include <limits.h> unconditionally.
24760         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
24761         (__P): Remove; all uses removed.
24762         * lib/md5.c: Include "md5.h" first.
24763         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
24764         md5_buffer, md5_process_bytes, md5_process_block):
24765         Define with prototypes.
24766         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
24767         * lib/sha.c: Include "sha.h" first.
24768         Include <stdlib.h>, <string.h> unconditionally.
24769
24770         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
24771         * lib/memcmp.c (__ptr_t): Likewise.
24772         * lib/memrchr.c (__ptr_t): Likewise.
24773         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
24774         Include <string.h> unconditionally.
24775         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
24776         * lib/memchr.c: Include <stdlib.h> unconditionally.
24777         * lib/memchr.c (LONG_MAX): Remove.
24778         * lib/memrchr.c (LONG_MAX): Likewise.
24779         * lib/memchr.c (__memchr): Define via a prototype.
24780         * lib/memrchr.c (__memrchr): Likewise.
24781         * lib/memcmp.c (__P): Remove, and remove all uses.
24782         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
24783         Remove forward decls; no longer needed.
24784         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
24785         Use types required by C89 in prototype.
24786
24787         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
24788         * lib/savedir.c: Likewise.
24789         * lib/mkdir.c (free): Remove decl.
24790         * lib/rmdir.c (rmdir): Define with a prototype.
24791         * lib/savedir.c: Include savedir.h first, to test interface.
24792
24793         * lib/mktime.c (STDC_HEADERS): Remove.
24794         Include <stdlib.h>, <string.h> unconditionally.
24795
24796         * lib/modechange.c: Include <stdlib.h> unconditionally.
24797         (malloc): Remove decl.
24798
24799         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
24800         (free): Remove decl.
24801
24802         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
24803         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
24804         (This type really should be intptr_t, but that's a C99ism.)
24805         (_obstack_memcpy): Remove: all uses changed to memcpy.
24806         Include <string.h> unconditionally.
24807         (struct obstack): Assume __STDC__ for types of members
24808         chunkfun, freefun, extra_arg.
24809         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
24810         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
24811         obstack_begin, obstack_specify_allocation,
24812         obstack_specify_allocation_with_arg, obstack_chunkfun,
24813         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
24814         Remove unprototyped decls and the macros that use them.
24815         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
24816         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
24817         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
24818         (defined __STDC__ && __STDC__)]:
24819         Remove nonprototyped code.
24820         Include <stdlib.h> unconditionally.
24821         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
24822         _obstack_allocated_p, _obstack_free, obstack_free,
24823         _obstack_memory_used, print_and_abort):
24824         Define using prototypes.
24825         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
24826         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
24827         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
24828         obstack_next_free, obstack_object_size, obstack_room) [0]:
24829         Remove unused, unprototyped code.
24830
24831         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
24832
24833         * lib/physmem.c (physmem_total, physmem_available, main): Define
24834         with prototypes.
24835
24836         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
24837         (main): Define with a prototype.
24838
24839         * lib/posixver.c (getenv): Remove decl.
24840
24841         * lib/putenv.c (malloc): Returns void *, not char *.
24842         Include <string.h> unconditionally.
24843         (strchr, memcpy, NULL): Do not define.
24844
24845         * lib/readtokens.c: Include readtokens.h first, to test interface.
24846         Include <stdlib.h>, <string.h> unconditionally.
24847         (init_tokenbuffer): Define with a prototype.
24848
24849         * lib/regex.c (PARAMS): Remove.  All uses removed.
24850         All uses of _RE_ARGS removed, too.
24851         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
24852         unconditionally.
24853         (bzero): Assume memset exists.
24854         (memcmp, memcpy, NULL): Remove.
24855         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
24856         char, or assignments to local vars of type signed char.
24857         (init_syntax_once, PREFIX(extract_number_and_incr),
24858         PREFIX(print_partial_compiled_pattern),
24859         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
24860         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
24861         PREFIX(regex_grow_registers), PREFIX(regex_compile),
24862         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
24863         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
24864         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
24865         wcs_compile_range, byte_compile_range, truncate_wchar,
24866         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
24867         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
24868         count_mbs_length, wcs_re_match_2_internal,
24869         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
24870         PREFIX(alt_match_null_string_p),
24871         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
24872         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
24873         regfree, PREFIX(extract_number)): Define with prototype.  Remove
24874         now-unnecessary declaration, if any.
24875         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
24876         regcomp, regexec):
24877         Remove now-unnecessary casts among pointer types.
24878         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
24879
24880         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
24881         (free): Remove decl.
24882
24883         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
24884
24885         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
24886         (free): Remove decl.
24887
24888         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
24889         * lib/xgetcwd.c: Likewise.
24890
24891         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
24892         (free): Remove decl.
24893
24894         * lib/strchrnul.c (strchrnul): Define with a prototype.
24895         Fix bug: c_in was not converted to char before searching.
24896
24897         The following changes are not K&R related:
24898
24899         * lib/group-member.h: Include <sys/types.h>, so that this file is
24900         self-contained.
24901         * lib/makepath.h: Likewise.
24902
24903         * lib/getusershell.c (readname, default_index, line_size, readname):
24904         Use size_t, not int, for sizes.
24905         (readname): If the size overflows, report an error instead of
24906         looping forever.
24907
24908 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24909
24910         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
24911         libc.
24912
24913 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24914
24915         * README: New section: portability guidelines.
24916
24917 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
24918
24919         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
24920         C89 spec.
24921
24922 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
24923
24924         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
24925
24926 2003-09-08  Paul Eggert  <eggert@twinsun.com>
24927
24928         Assume C89 or better; remove K&R cruft.
24929         A few of these changes were first proposed by Derek Robert Price
24930         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
24931
24932         * lib/addext.c: Include <string.h> unconditionally.
24933         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
24934         Don't declare getenv or malloc.
24935
24936         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
24937         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
24938         (NULL): Remove.
24939         (find_stack_direction, alloca): Use prototypes.
24940
24941         * lib/atexit.c (atexit): Define using a prototype.
24942
24943         * lib/basename.c, dirname.c, stripslash.c:
24944         Include <string.h> unconditionally.
24945
24946         * lib/bcopy.c: Include <stddef.h>.
24947         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
24948
24949         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
24950
24951         * lib/error.h (error, error_at_line, error_print_progname)
24952         [! (defined (__STDC__) && __STDC__)]: Remove decls.
24953         * lib/error.c: Include error.h first, to check interface.
24954         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
24955         (VA_START): Remove; all uses changeed to va_start.
24956         (exit, strerror): Remove decls.
24957         (error_print_progname): Prototype uncondionally.
24958         Don't include <errno.h>; no longer needed.
24959         (private_strerror): Remove.
24960         (error_tail): Always define.
24961         (error, error_at_line): Assume C89 or better; always use prototypes.
24962         * lib/fatal.c: Include "fatal.h" first, to test interface.
24963         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
24964         (VA_START): Remove; all uses changed to va_start.
24965         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
24966         this case.
24967         (exit): Remove decl.
24968         (fatal): Prototype unconditionally.  Assume va_start works.
24969         Abort at end, to pacify gcc.
24970
24971         * lib/euidaccess.c (main): Define with a prototype.
24972
24973         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
24974
24975         * lib/exitfail.c: Include <stdlib.h> unconditionally.
24976
24977         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
24978         prototypes.
24979         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
24980         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
24981         (getenv): Remove decl.
24982         (fnmatch): Define using a prototype.
24983         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
24984         (FCT): Define using a prototype.
24985
24986         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
24987
24988         * lib/gethostname.c: Include <stddef.h>.
24989         (gethostname): Define with prototype.  Length is size_t, not int.
24990
24991 2003-09-08  Paul Eggert  <eggert@twinsun.com>
24992
24993         Assume C89 or better; remove K&R cruft.
24994         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
24995         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
24996         string.h, getenv, malloc.
24997         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
24998         headers.
24999         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
25000         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
25001         do not check for strerror.
25002         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
25003         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
25004         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
25005         do not check for doprnt or vprintf.
25006         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
25007         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
25008
25009 2003-09-08  Paul Eggert  <eggert@twinsun.com>
25010
25011         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
25012         getversion.c should have been removed then, but was accidentally
25013         preserved.
25014
25015         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
25016         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
25017
25018 2003-09-08  Karl Berry  <karl@gnu.org>
25019
25020         * config/config.sub, config.guess, srclistvars.sh: update from savannah
25021                 config, forget about prep.
25022
25023         * config/depcomp, missing: update from automake.
25024
25025 2003-09-07  Paul Eggert  <eggert@twinsun.com>
25026
25027         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
25028         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
25029
25030 2003-09-07  Paul Eggert  <eggert@twinsun.com>
25031
25032         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
25033         copy_tm_result.  Bug reported by Simon Josefsson in
25034         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
25035
25036 2003-09-06  Paul Eggert  <eggert@twinsun.com>
25037
25038         * m4/time_r.m4: New file.
25039         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
25040         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
25041         is. Check for timegm declaration.
25042         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
25043         Do not check for gmtime_r.
25044         Replace mktime if __mktime_internal does not exist and if mktime
25045         hasn't been replaced already.
25046
25047 2003-09-06  Paul Eggert  <eggert@twinsun.com>
25048
25049         * lib/time_r.c, lib/time_r.h: New files.
25050
25051         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
25052         __localtime_r.
25053         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
25054         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
25055
25056         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
25057         __gmtime_r.
25058         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
25059         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
25060         Include <time_r.h>.
25061
25062         * lib/timegm.c: Switch to glibc implementation, with the following
25063         changes:
25064         [defined HAVE_CONFIG_H]: Include <config.h>.
25065         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
25066         (__mktime_internal) [!defined _LIBC]: New decl.
25067         (__gmtime_r) [!defined _LIBC]: New macro and function.
25068         (timegm): Use a prototype, since gnulib assumes C89.
25069         Do not bother declaring tmp to be const, as it's not really usefu.
25070         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
25071         (timegm): Declare only if HAVE_DECL_TIMEGM.
25072
25073 2003-09-06  Paul Eggert  <eggert@twinsun.com>
25074
25075         * MODULES.html.sh (func_all_modules): Add time_r.
25076         * modules/time_r: New file.
25077         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
25078         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
25079
25080 2003-09-03  Paul Eggert  <eggert@twinsun.com>
25081
25082         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
25083         Bug reported by Lute Kamstra in
25084         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
25085
25086         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
25087         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
25088         course with correspondingly smaller numbers for tomorrow and
25089         yesterday.  From Tadayoshi Funaba.  Originally installed into
25090         sh-utils on 1999-08-07, but the patch got lost (I guess during the
25091         coreutils merge?).
25092
25093 2003-08-31  Simon Josefsson  <jas@extundo.com>
25094
25095         * modules/timegm: New file.
25096         * MODULES.html.sh (func_all_modules): Add timegm.
25097
25098 2003-08-31  Simon Josefsson  <jas@extundo.com>
25099
25100         * m4/timegm.m4: New file.
25101
25102 2003-08-31  Simon Josefsson  <jas@extundo.com>
25103
25104         * lib/timegm.h: New file.
25105         * lib/timegm.c: New file.  Based on
25106         wget-1.8.2/src/http.c:mktime_from_utc.
25107
25108 2003-08-31  Karl Berry  <karl@gnu.org>
25109
25110         * lib/argp.h: update from libc.
25111
25112 2003-08-28  Bruno Haible  <bruno@clisp.org>
25113
25114         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
25115         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
25116         followed by '#define fnmatch fnmatch_posix' gives an error.
25117
25118 2003-08-28  Bruno Haible  <bruno@clisp.org>
25119
25120         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
25121         warning on QNX, which defines O_BINARY to 000000.
25122
25123 2003-08-27  Jim Meyering  <jim@meyering.net>
25124
25125         * m4/mkstemp.m4: Require that the system mkstemp be able to create
25126         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
25127         would fail after 32.  Reported by Danny Levinson.  Details here:
25128         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
25129
25130 2003-08-24  Bruno Haible  <bruno@clisp.org>
25131
25132         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
25133         MSVC7 <stdio.h> is included later.
25134
25135 2003-08-22  Simon Josefsson  <jas@extundo.com>
25136
25137         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
25138
25139 2003-08-20  Karl Berry  <karl@gnu.org>
25140
25141         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
25142
25143 2003-08-20  Bruno Haible  <bruno@clisp.org>
25144
25145         * modules/progname: New file.
25146         * MODULES.html.sh (func_all_modules): Add progname.
25147
25148 2003-08-20  Bruno Haible  <bruno@clisp.org>
25149
25150         * lib/progname.h: New file, from GNU gettext.
25151         * lib/progname.c: New file, from GNU gettext.
25152         * lib/progreloc.c: New file, from GNU gettext.
25153
25154 2003-08-19  Jim Meyering  <jim@meyering.net>
25155
25156         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
25157         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
25158
25159 2003-08-19  Bruno Haible  <bruno@clisp.org>
25160
25161         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
25162         more.
25163
25164 2003-08-19  Bruno Haible  <bruno@clisp.org>
25165
25166         * lib/xstrdup.c: Assume <string.h> exists.
25167
25168 2003-08-18  Paul Eggert  <eggert@twinsun.com>
25169
25170         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
25171         in makefile rules.
25172
25173 2003-08-18  Jim Meyering  <jim@meyering.net>
25174
25175         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
25176         * m4/lib-ld.m4: Likewise.
25177
25178 2003-08-18  Jim Meyering  <jim@meyering.net>
25179
25180         * lib/setenv.h: Indent nested cpp directive.
25181         * lib/vasnprintf.c: Remove trailing blanks.
25182
25183 2003-08-17  Simon Josefsson  <jas@extundo.com>
25184
25185         * modules/xstrndup: New file.
25186         * MODULES.html.sh (func_all_modules): Add xstrndup.
25187
25188 2003-08-17  Simon Josefsson  <jas@extundo.com>
25189
25190         * modules/argp: Fix autoconf macro name. Add more dependencies.
25191
25192 2003-08-17  Simon Josefsson  <jas@extundo.com>
25193
25194         * m4/xstrndup.m4: New file.
25195
25196 2003-08-17  Simon Josefsson  <jas@extundo.com>
25197
25198         * m4/argp.m4: New file.
25199
25200 2003-08-17  Simon Josefsson  <jas@extundo.com>
25201             Bruno Haible  <bruno@clisp.org>
25202
25203         * lib/xstrndup.h: New file.
25204         * lib/xstrndup.c: New file.
25205
25206 2003-08-17  Bruno Haible  <bruno@clisp.org>
25207
25208         * modules/strndup (Files, Include): Add lib/strndup.h.
25209
25210 2003-08-17  Bruno Haible  <bruno@clisp.org>
25211
25212         * modules/euidaccess (Files): Add lib/euidaccess.h.
25213
25214 2003-08-17  Bruno Haible  <bruno@clisp.org>
25215
25216         * lib/strndup.h: New file.
25217
25218 2003-08-17  Bruno Haible  <bruno@clisp.org>
25219
25220         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
25221         like AC_GNU_SOURCE.
25222         * modules/extensions (configure.ac): Comment out the invocation of
25223         gl_USE_SYSTEM_EXTENSIONS.
25224
25225 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25226
25227         Merges from coreutils, etc.
25228         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
25229         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
25230         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
25231         fixing a typo.
25232         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
25233         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
25234
25235 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25236
25237         Document merge from coreutils.
25238         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
25239         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
25240         * modules/utime: Add m4/utimes-null.m4.
25241
25242 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25243
25244         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
25245         space, undoing this 2003-08-12 change:
25246         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
25247
25248 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25249
25250         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
25251         strtoul.c from libc, undoing this 2003-08-12 change:
25252         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
25253
25254 2003-08-16  Jim Meyering  <jim@meyering.net>
25255
25256         Merges from coreutils.
25257         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
25258         prefix.  Adjust cache variables similarly.  Create 500 rather than
25259         just 300 files, to exercise bug on Darwin6.5, too.
25260         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
25261         $missing_dir.
25262         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
25263         AM_SYS_POSIX_TERMIOS.
25264         Reported by mkc@mathdogs.com.
25265         Also change use of $am_cv_sys_posix_termios
25266         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
25267         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
25268         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
25269         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
25270         in /proc/mounts until it finds one with matching device number.  This
25271         is unnecessary when the FILE argument *is* a mount point.  No stat call
25272         is necessary in that case.  So, disable the statvfs-testing code on
25273         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
25274         as RedHat bug# 84846.
25275         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
25276         to 1MB, so as not to render systems with no stack size limit (e.g.,
25277         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
25278         Include <unistd.h>.  On some systems,
25279         it is required for the definition of _SC_PAGESIZE.
25280
25281 2003-08-16  Jim Meyering  <jim@meyering.net>
25282
25283         Merge from coreutils.
25284         * lib/xstrtoimax.c: #else #if -> #elif.
25285         * lib/xstrtoumax.c: Likewise.
25286
25287 2003-08-16  Jim Meyering  <jim@meyering.net>
25288
25289         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
25290         * m4/utimes.m4: Removed.
25291         * m4/utimes-null.m4: Renamed from utimes.m4.
25292
25293         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
25294         to 1MB, so as not to render systems with no stack size limit (e.g.,
25295         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
25296         Include <unistd.h>.  On some systems,
25297         it is required for the definition of _SC_PAGESIZE.
25298
25299 2003-08-16  Jim Meyering  <jim@meyering.net>
25300         and Paul Eggert  <eggert@cs.ucla.edu>
25301
25302         Merges from coreutils, etc.
25303
25304         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
25305         using the latest version from cvs.  This avoids problems with #line
25306         directives using a vendor (Sun) compiler.
25307         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
25308         Don't set GETGROUPS_LIB here; now it's
25309         done via getgroups.m4's wrapper function.
25310         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
25311         rather than just in sh-util/configure.in, so that the
25312         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
25313         same.
25314         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
25315         AC_FUNC_GETLOADAVG where to find getloadavg.c.
25316         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
25317         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
25318         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
25319         Remove code that is now done by the newly-required macros.
25320         Append $(EXEEXT) to DF_PROG.
25321         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
25322         Do not invoke or require the following here,
25323         since prereq.m4 or some gnulib .m4 now does this for us:
25324         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
25325         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
25326         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
25327         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
25328         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
25329         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
25330         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
25331         AC_FUNC_OBSTACK.
25332         Do not replace the following functions, as this is now the job
25333         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
25334         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
25335         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
25336         atexit getpass, strdup, getpagesize.
25337         Replace 'raise'.
25338         Do not check for the following functions, as this is now the job
25339         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
25340         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
25341         setregid.
25342         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
25343         Check for sys/sysctl.h.
25344         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
25345         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
25346         of checking for ssize_t ourselves.
25347
25348         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
25349         Require every macro that gnulib/modules/* suggests for us.
25350         (jm_PREREQ_ADDEXT): New macro.
25351         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
25352         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
25353
25354         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
25355         (gl_PHYSMEM): Use it.
25356         Also check for `table' function.
25357         Check for new headers and functions.
25358         Add check for sys/sysmp.h.
25359         With suggestions from Kaveh Ghazi.
25360         Ignore headers that are present but cannot be compiled.  This
25361         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
25362         C 5.4.
25363
25364 2003-08-15  Paul Eggert  <eggert@twinsun.com>
25365
25366         Document merge from coreutils.
25367         * modules/userspec: Depend on posixver.
25368         * modules/strftime: Depend on tzset.
25369
25370 2003-08-15  Paul Eggert  <eggert@twinsun.com>
25371
25372         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
25373         rather than tab, after '#' in shell-script copyright notices.
25374         Suggested by Bruno Haible.
25375
25376 2003-08-15  Paul Eggert  <eggert@twinsun.com>
25377
25378         * config/srclist-update: Use three spaces, rather than tab, after '#'
25379         in shell-script copyright notices.  Suggested by Bruno Haible.
25380         Remove unnecessary parenthesization in regular expression.
25381
25382 2003-08-15  Jim Meyering  <jim@meyering.net>
25383
25384         Merge from coreutils.
25385         * lib/xgethostname.c: Include <stdlib.h>.
25386         (xghostname): Don't exit for anything other than memory-related
25387         failure; just return NULL.
25388         * lib/userspec.c: Include "posixver.h".
25389         (parse_user_spec): Accept `.' as a separator only
25390         in pre-POSIX-200112 mode.
25391         * lib/strtoimax.c: Use #elif rather than #else #if.
25392         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
25393         Remove function, now that we can rely on a working tzset function.
25394         [!_LIBC]: Ensure that the required autoconf test has been run.
25395         [!defined _NL_CURRENT && HAVE_STRFTIME]:
25396         Use underlying_strftime for %r.
25397         * lib/sha.c: Merge in some clean-up and optimization changes from
25398         glibc.
25399         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
25400         Ensure that it is a multiple of 64.
25401         Rearrange loop exit tests so as to avoid performing an
25402         additional fread after encountering an error or EOF.
25403         * lib/realloc.c: Update copyright date.
25404
25405 2003-08-15  Jim Meyering  <jim@meyering.net>
25406         and Paul Eggert  <eggert@twinsun.com>
25407
25408         Merge from coreutils.
25409         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
25410         member but strut utmpx does not.  Needed for AIX 4.3.3.
25411         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
25412
25413 2003-08-15  Jim Meyering  <jim@meyering.net>
25414         and Paul Eggert  <eggert@cs.ucla.edu>
25415
25416         Merges from coreutils, etc.
25417         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
25418         Require gl_FUNC_TZSET_CLOBBER.
25419         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
25420         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
25421         members.
25422
25423 2003-08-14  Paul Eggert  <eggert@twinsun.com>
25424
25425         Help the merge from coreutils.
25426         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
25427         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
25428         * m4/tzset.m4: Use it too.
25429
25430 2003-08-14  Paul Eggert  <eggert@twinsun.com>
25431
25432         * modules/tzset: New file.
25433
25434 2003-08-14  Jim Meyering  <jim@meyering.net>
25435
25436         Merges from coreutils.
25437         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
25438         variable names, rather than @FNMATCH_H@.
25439         * modules/alloca: Likewise for $(ALLOCA_H).
25440
25441         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
25442         the three copies of the literal target, `fnmatch.h'.
25443         * modules/alloca (alloca.h): Likewise.
25444
25445 2003-08-14  Jim Meyering  <jim@meyering.net>
25446
25447         Merge from coreutils.
25448         * m4/tzset.m4: New file.
25449         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
25450         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
25451         otherwise, AIX 5.1 systems would end up using the latter.
25452         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
25453         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
25454         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
25455         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
25456
25457 2003-08-14  Jim Meyering  <jim@meyering.net>
25458
25459         Merge from coreutils.
25460         * lib/obstack.h: Whitespace changes.
25461         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
25462         and xcalloc return values.
25463         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
25464         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
25465         hang on OSF/1 5.1 for DIR on both local and remote file systems.
25466         Reported by (and fix confirmed by) Nelson H. F. Beebe.
25467         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
25468         error from mntctl.
25469         Use mntctl's return value to drive the entry-processing loop, since
25470         we can't rely on the value of the vmt_length member in the last
25471         entry.  On some systems doing so could result in exhausting
25472         virtual memory.  Based in part on a patch from Mike Jetzer.
25473
25474 2003-08-14  Jim Meyering  <jim@meyering.net>
25475         and Paul Eggert  <eggert@twinsun.com>
25476
25477         Merges from coreutils, plus other fixes.
25478         * lib/physmem.c: Merge in portability changes from gcc/libiberty
25479         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
25480         for credits and details.  Thanks to Kaveh Ghazi for helping
25481         to keep these files in sync.
25482         (ARRAY_SIZE): Define it.
25483         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
25484         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
25485         (memcasecmp): Don't assume size_t fits in unsigned int.
25486         Remove casts and duplicate code.
25487         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
25488         (memcpy): Remove definition.
25489         Merge in some clean-up and optimization changes from glibc.
25490         [BLOCKSIZE]: Move definition to top of file.
25491         Ensure that it is a multiple of 64.
25492         Rearrange loop exit tests so as to avoid performing an
25493         additional fread after encountering an error or EOF.
25494         * lib/md5.h (md5_uintptr): Define.
25495         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
25496         return to the initial working directory.  Preserve errno
25497         for caller.
25498         * lib/idcache.c: Include "xalloc.h".
25499         (xmalloc, xrealloc): Remove decls.
25500         (getuser): Remove casts no longer required in C89.
25501         * lib/human.c: Include stdio.h, for sprintf.
25502         * lib/group-member.c: Include "xalloc.h".
25503         (xmalloc, xrealloc): Remove decls.
25504         (get_group_info): Remove casts no longer required in C89.
25505         * lib/getusershell.c (readname): Remove casts no longer required in
25506         C89.
25507         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
25508         * lib/getline.c: Whitespace fix, from coreutils.
25509
25510 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25511
25512         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
25513         Check for isascii.
25514
25515         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
25516         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
25517         Undo previous (whitespace-only) change.
25518
25519 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25520
25521         * lib/exclude.c: Include <ctype.h>
25522         (IN_CTYPE_DOMAIN): New macro.
25523         (is_space): New fn.
25524         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
25525         and empty lines.
25526
25527         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
25528         Undo previous (whitespace-only) change.
25529
25530 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25531
25532         * config/srclist-update: Change update back to the old behavior,
25533         leaving whitespace alone.  Use one 'sed' command rather than a
25534         pipeline.
25535         (fixlicense): Now a variable, not a function.
25536         (remove_trailing_blanks): Remove.
25537         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
25538         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
25539         Undo previous (whitespace-only) change.
25540
25541 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25542
25543         Merge from coreutils.
25544         * modules/euidaccess: Add lib_SOURCES, include for new
25545         file euidaccess.h
25546
25547 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25548
25549         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
25550         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
25551         Normalize leading white space and remove trailing white space.
25552
25553         Merge from coreutils
25554         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
25555
25556         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
25557         0.12.1.  These files are now being upgraded automatically by
25558         ../config/srclist-update.
25559
25560 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25561
25562         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
25563         Normalize leading white space and remove trailing white space.
25564         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
25565         notice, as per ../config/srclist-update.
25566
25567         Merge from coreutils.
25568         * lib/euidaccess.h: New file.
25569         * lib/euidaccess.c: Include it.
25570         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
25571         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
25572         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
25573
25574 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25575
25576         * config/srclist-update: Add copyright notice.
25577         (remove_id_lines, remove_trailing_blanks): New constants.
25578         (fixfile): Use them to normalize spacing a bit in copied files.
25579         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
25580         Normalize leading white space and remove trailing white space.
25581
25582         * config/texinfo.tex: Sync with texinfo.
25583
25584         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
25585         strtoul.c from libc, to merge coreutils whitespace changes.
25586
25587         * config/srclist.txt: Get the following m4 files from gettext:
25588         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
25589         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
25590         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
25591         wint_t.m4.
25592
25593 2003-08-12  Karl Berry  <karl@gnu.org>
25594
25595         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
25596         been made.
25597
25598 2003-08-11  Paul Eggert  <eggert@twinsun.com>
25599
25600         * modules/gnu-source, m4/gnu-source.m4:
25601         Remove; we're assuming Autoconf 2.54 or later now.
25602         Suggested by Bruno Haible.
25603         * MODULES.html.sh (func_all_modules): Remove gnu-source.
25604
25605 2003-08-11  Bruno Haible  <bruno@clisp.org>
25606
25607         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
25608
25609 2003-08-11  Bruno Haible  <bruno@clisp.org>
25610
25611         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
25612         (vasnprintf): Use it instead of wcslen.
25613
25614 2003-08-11  Bruno Haible  <bruno@clisp.org>
25615
25616         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
25617         value to ensure that _Bool promotes to int. Use #define for _Bool when
25618         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
25619
25620 2003-08-10  Karl Berry  <karl@gnu.org>
25621
25622         * lib/regex.h: update from libc (whitespace fix).
25623
25624 2003-08-09  Paul Eggert  <eggert@twinsun.com>
25625
25626         Merge some files from coreutils.  These changes were
25627         originally made by Jim Meyering.
25628         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
25629         many older Unixes require this.
25630         * lib/alloca.c (alloca): Remove cast to argument of free;
25631         no longer needed in C89.
25632         * lib/alloca_.h, regex.h: Fix white space to match
25633         what GNU indent does.
25634
25635 2003-08-09  Paul Eggert  <eggert@twinsun.com>
25636
25637         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
25638         apparently Emacs's Unicode mode got confused before my 2003-08-05
25639         checkin.
25640
25641 2003-08-08  Paul Eggert  <eggert@twinsun.com>
25642
25643         * m4/extensions.m4: New file.
25644         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
25645         Require gl_USE_SYSTEM_EXTENSIONS.
25646         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
25647         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
25648
25649 2003-08-08  Paul Eggert  <eggert@twinsun.com>
25650
25651         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
25652         * modules/extensions, modules/gnu-source: New files.
25653         * modules/timespec, modules/unlocked-io: Depend on extensions.
25654
25655 2003-08-07  Paul Eggert  <eggert@twinsun.com>
25656
25657         * modules/restrict: New file.
25658         * MODULES.html.sh (func_all_modules): Add restrict.
25659         * modules/regex: Depend on restrict.
25660
25661 2003-08-07  Paul Eggert  <eggert@twinsun.com>
25662
25663         * m4/restrict.m4: New file.
25664         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
25665
25666 2003-08-07  Bruno Haible  <bruno@clisp.org>
25667
25668         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
25669         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
25670
25671 2003-08-07  Bruno Haible  <bruno@clisp.org>
25672
25673         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
25674         makes the module 'getndelim2' compatible with the module 'getline'.
25675
25676 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25677
25678         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
25679         byte with "\201" to avoid glitches when editing that source file
25680         with multi-gnome-terminal.
25681
25682 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25683
25684         * lib/bumpalloc.h: Remove.
25685
25686 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25687
25688         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
25689         * modules/bumpalloc: Remove.
25690
25691 2003-08-04  Paul Eggert  <eggert@twinsun.com>
25692
25693         * lib/getloadavg.c: Change copyright notice and spacing to conform to
25694         GNU coding style.
25695
25696         Merge from coreutils.
25697         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
25698         1. From glibc.
25699         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
25700         from Karl Berry, implemented by Jim Meyering.
25701         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
25702         from Dmitry V. Levin.
25703         Remove anachronistic cast of xrealloc.
25704         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
25705         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
25706         type. Otherwise, it wouldn't compile with at least /bin/cc on
25707         ymp-cray-unicos9.0.2.X.
25708         Combine two mostly-identical uses of alloca into one.
25709         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
25710
25711 2003-08-04  Dave Love  <d.love@dl.ac.uk>
25712
25713         [From Emacs.]
25714
25715         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
25716         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
25717         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
25718         obsolete NLIST_NAME_UNION.
25719         [__GNU__]: Undef BSD and FSCALE.
25720         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
25721
25722 2003-08-03  Paul Eggert  <eggert@twinsun.com>
25723
25724         * lib/stdbool_.h (_Bool): Make it signed char, instead of
25725         an enum type, so that it's guaranteed to promote to int.  See:
25726         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
25727
25728 2003-08-03  Karl Berry  <karl@gnu.org>
25729
25730         * config/depcomp: update from automake.
25731
25732 2003-07-31  Paul Eggert  <eggert@twinsun.com>
25733
25734         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
25735         (strerror): Don't assume that a printable int fits in 14 bytes.
25736
25737 2003-07-31  Bruno Haible  <bruno@clisp.org>
25738
25739         * modules/getpass-gnu: New file.
25740         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
25741
25742 2003-07-31  Bruno Haible  <bruno@clisp.org>
25743
25744         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
25745
25746 2003-07-24  Karl Berry  <karl@gnu.org>
25747
25748         * config/missing: update from automake.
25749
25750 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
25751             Bruno Haible  <bruno@clisp.org>
25752
25753         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
25754         * lib/getline.c (getline, getdelim): Likewise.
25755         Remove _GNU_SOURCE define; now it's defined in config.h through
25756         m4/getline.m4.
25757
25758 2003-07-23  Karl Berry  <karl@gnu.org>
25759
25760         * config/config.sub: update from prep.
25761
25762 2003-07-22  Paul Eggert  <eggert@twinsun.com>
25763
25764         * modules/xalloc (Depends-on): Add exitfail.
25765         * modules/xmemcoll: Likewise.
25766
25767 2003-07-22  Paul Eggert  <eggert@twinsun.com>
25768
25769         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
25770         over-parenthesization in macros.
25771
25772         Sync with coreutils.
25773
25774         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
25775         required by C99.
25776
25777         Use `exit_failure' for xalloc and xmemcoll instead of their own
25778         private exit-failure variables.
25779         * lib/xalloc.h (xalloc_exit_failure): Remove.
25780         * lib/xmalloc.c: Likewise.  Include exitfail.h.
25781         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
25782         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
25783         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
25784         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
25785
25786 2003-07-20  Jim Meyering  <jim@meyering.net>
25787
25788         * modules/closeout (Depends-on): Add exitfail.
25789         Suggestion from Bruno Haible.
25790
25791 2003-07-19  Karl Berry  <karl@gnu.org>
25792
25793         * config/config.sub: update from prep.
25794
25795 2003-07-18  Paul Eggert  <eggert@twinsun.com>
25796
25797         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
25798         Remove.
25799         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
25800         to test that it can stand by itself.  Include "exitfail.h".
25801         Clients should set exit_failure instead.
25802         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
25803
25804 2003-07-18  Bruno Haible  <bruno@clisp.org>
25805
25806         * modules/getndelim2: New file.
25807         * modules/getline: Share files with module getndelim2.
25808         * modules/getnline: Depend on getndelim2 instead of sharing files with
25809         it. Add getnline.c to lib_SOURCES.
25810         * MODULES.html.sh (func_all_modules): Add getndelim2.
25811
25812 2003-07-18  Bruno Haible  <bruno@clisp.org>
25813
25814         * m4/getndelim2.m4: New file.
25815         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
25816         invoke gl_PREREQ_GETNDELIM2.
25817         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
25818         gl_PREREQ_GETNDELIM2.
25819         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
25820         gl_GETNDELIM2.
25821
25822 2003-07-18  Bruno Haible  <bruno@clisp.org>
25823
25824         * lib/getndelim2.h: New file.
25825         * lib/getndelim2.c: Make into a module of its own. Include config.h,
25826         getndelim2.h.
25827         (getndelim2): Make non-static. Change return type to ssize_t.
25828         * lib/getline.h: Change argument names.
25829         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
25830         * lib/getnline.c: Include getndelim2.h.
25831
25832 2003-07-18  Andreas Schwab  <schwab@suse.de>
25833
25834         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
25835
25836 2003-07-17  Karl Berry  <karl@gnu.org>
25837
25838         * config/config.sub: update from prep.
25839
25840 2003-07-17  Bruno Haible  <bruno@clisp.org>
25841
25842         * modules/getnline: New file.
25843         * modules/getline: Add lib/getndelim2.c to source file list.
25844         * MODULES.html.sh (func_all_modules): Add getnline.
25845
25846 2003-07-17  Bruno Haible  <bruno@clisp.org>
25847
25848         * m4/getnline.m4: New file.
25849
25850 2003-07-17  Bruno Haible  <bruno@clisp.org>
25851
25852         * m4/Makefile.am.in: Remove file.
25853         * m4/Makefile.am: Remove file.
25854         * m4/Makefile.in: Remove file.
25855
25856 2003-07-17  Bruno Haible  <bruno@clisp.org>
25857
25858         * lib/getnline.h: New file.
25859         * lib/getnline.c: New file.
25860         * lib/getndelim2.c: New file, extracted from getline.c.
25861         (getndelim2): Renamed from getdelim2, with added nmax argument.
25862         * lib/getline.c: Include getndelim2.c.
25863         (getdelim2): Moved out to getndelim2.c.
25864         (getline, getdelim): Update.
25865
25866 2003-07-17  Bruno Haible  <bruno@clisp.org>
25867
25868         * lib/Makefile.am: Remove file.
25869         * lib/Makefile.in: Remove file.
25870
25871 2003-07-17  Bruno Haible  <bruno@clisp.org>
25872
25873         * configure.in: Remove file.
25874         * Makefile.in: Remove file.
25875
25876 2003-07-17  Bruno Haible  <bruno@clisp.org>
25877
25878         * MODULES.html.sh: Put the </BODY> right before </HTML>.
25879
25880 2003-07-16  Karl Berry  <karl@gnu.org>
25881
25882         * config/srclist-update: was running fixlicense twice, which caused
25883                 texinfo.tex to be nullified for some reason.  Simplify,
25884                 $gplsrc is no longer needed as far as I can see?
25885
25886 2003-07-16  Jim Meyering  <jim@meyering.net>
25887
25888         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
25889
25890 2003-07-15  Paul Eggert  <eggert@twinsun.com>
25891
25892         * config/srclist.txt: Get the following files from gettext-runtime/intl
25893         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
25894         ref-del.sin.  From Bruno Haible.
25895         * config/srclist-update (fixfile): Change grep pattern again, since the
25896         previous fix didn't work (there was another trailing $).  Use
25897         '[$]' to escape the $s.
25898
25899 2003-07-15  Karl Berry  <karl@gnu.org>
25900
25901         * lib/vasnprintf.c: update from gettext.
25902
25903 2003-07-15  Karl Berry  <karl@gnu.org>
25904
25905         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
25906         gets expanded when surrounded by '$'.
25907
25908 2003-07-15  Jim Meyering  <jim@meyering.net>
25909
25910         * modules/save-cwd: Don't depend on error.  From Derek Price.
25911
25912 2003-07-15  Jim Meyering  <jim@meyering.net>
25913
25914         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
25915
25916 2003-07-14  Simon Josefsson  <jas@extundo.com>
25917
25918         * modules/mempcpy: New file.
25919         * MODULES.html.sh (func_all_modules): Add mempcpy.
25920
25921 2003-07-14  Simon Josefsson  <jas@extundo.com>
25922
25923         * m4/mempcpy.m4: New file.
25924
25925 2003-07-14  Simon Josefsson  <jas@extundo.com>
25926
25927         * lib/mempcpy.h: New file.
25928         * lib/mempcpy.c: New file.
25929
25930 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25931
25932         * modules/getdate, modules/posixtm: Depend on mktime.
25933
25934 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25935
25936         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
25937         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
25938         unicodeio.c, unicodeio.h, unlocked-io.h:
25939         Switch from LGPL to GPL.
25940
25941 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25942
25943         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
25944         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
25945         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
25946         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
25947         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
25948         updated automatically by ../config/srclist-update.  This changes
25949         their license from LPGL to GPL.
25950
25951 2003-07-14  Paul Eggert  <eggert@twinsun.com>
25952
25953         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
25954         assumed to refer to the root of the most recent stable gettext version.
25955         * config/srclistvars.sh: Add defaults for eggert.
25956         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
25957         Match "This program" as well as "The program".  This is needed
25958         for gettext.
25959
25960 2003-07-14  Jim Meyering  <jim@meyering.net>
25961
25962         Don't emit diagnostics.  Let callers do that.
25963         * lib/save-cwd.c: Don't include "error.h".
25964         (save_cwd): Don't call error.  Ensure that errno is valid
25965         when returning nonzero.
25966
25967         * lib/save-cwd.h (restore_cwd): Update prototype.
25968         * lib/save-cwd.c (restore_cwd): Remove two parameters.
25969         Simplify.  Don't call error upon failure.  Let callers do that.
25970         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
25971         when auditing is enabled.  But don't bother updating the #if.
25972
25973 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
25974
25975         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
25976         it breaks C++ compilation.
25977         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
25978
25979 2003-07-10  Simon Josefsson  <jas@extundo.com>
25980
25981         * modules/strchrnul (Makefile.am): Add strchrnul.h.
25982
25983 2003-07-10  Jim Meyering  <jim@meyering.net>
25984
25985         * m4/clock_time.m4: Remove trailing blank.
25986         * m4/intmax_t.m4: Likewise.
25987
25988 2003-07-10  Jim Meyering  <jim@meyering.net>
25989
25990         * lib/vasnprintf.c: Remove trailing blanks.
25991         Make cpp indentation consistent.
25992
25993 2003-07-09  Paul Eggert  <eggert@twinsun.com>
25994
25995         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
25996         posixver.c, strftime.c, strnlen.c, strverscmp.c:
25997         Switch from LGPL to GPL.
25998
25999 2003-07-09  Paul Eggert  <eggert@twinsun.com>
26000
26001         * config/srclist.txt: Sort sublists.  Add
26002         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
26003         that differ from gnulib for one reason or another; we'd like this list
26004         to be smaller but for now let's document what we have.
26005
26006 2003-07-08  Paul Eggert  <eggert@twinsun.com>
26007
26008         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
26009         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
26010         and sweeter "eval x=$x".
26011         * config/srclist.txt: Get lib/argp* from glibc.
26012
26013 2003-07-07  Paul Eggert  <eggert@twinsun.com>
26014
26015         * lib/mktime.c: Fix some boundary cases and remove need for floating
26016         point.
26017
26018         Issue a compile-time diagnostic if time_t is floating point, or if
26019         two's complement arithmetic is not in effect, or if arithmetic
26020         right shift does not propagate the sign.  These assumptions were
26021         all in the original code but they weren't checked.
26022
26023         (TIME_T_MIDPOINT, verify): New macros.
26024         (__isleap): Remove; it has integer overflow problems.
26025         (leapyear): New function, without those problems.
26026         (ydhms_tm_diff): Remove; splitting into two parts.
26027         (ydhms_diff): New function, containing the arithmetic part of
26028         the old ydhms_tm_diff function.  Issue a compile-time
26029         diagnostic if we are not using C99 integer division.
26030         Avoid casts when possible.
26031         (guess_time_tm): New function, containing the checking part of
26032         the old ydhms_tm_diff function.  Return the new value, rather than
26033         the difference between it and the old.  Accept a new argument T
26034         so that *T specifies the old value.  Check for overflow in the result.
26035
26036         (__mktime_internal): Use a time_t offset, not a long int offset.
26037         This undoes the 2003-06-04 change, which is no longer needed now
26038         that we have better overflow checking.
26039         (localtime_offset): Likewise.
26040
26041         (__mktime_internal): Avoid harmful overflow on hosts where time_t
26042         and long are 64-bit but int is only 32-bit.
26043         (ydhms_diff): Use long int to store year1 and yday1.
26044         Issue a compile-time diagnostic if long int is not wide enough.
26045
26046         (__mktime_internal): Use long int to store adjusted year and yday.
26047         Use plain C rather than preprocessor commands, if that doesn't
26048         affect efficiency.
26049         Check for overflow (and try to repair) after each probe
26050         rather than checking only at the very end.  This avoids some bugs
26051         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
26052         does not equal GMT offset at maximum time).
26053         Use integer to check for overflow rather than floating point; this
26054         is more portable to non-IEEE hosts, and is a tad faster.
26055         When we detect that we are oscillating between two values,
26056         don't check whether tm_isdst has the requested value, since
26057         we already know the answer.  When tm_isdst has the wrong value,
26058         use a different heuristic to find the right one, based on the
26059         extreme values actually observed in practice in tz2003a,
26060         rather than the (overly optimistic) "previous 3 calendar quarters".
26061
26062         (not_equal_tm, print_tm, check_result): Use "const T" rather than
26063         "T const" to accommodate glibc style.
26064         (check_result): Use less-confusing report format.  "long" -> "long int.
26065         (main): Likewise.
26066         Don't loop if the iteration overflows time_t.
26067         Allow a negative step in the iteration.
26068
26069 2003-07-06  Karl Berry  <karl@gnu.org>
26070
26071         * config/depcomp: update from automake.
26072         * config/config.sub: update from prep.
26073
26074 2003-07-03  Karl Berry  <karl@gnu.org>
26075
26076         * config/config.guess: update from prep.
26077
26078 2003-07-01  Paul Eggert  <eggert@twinsun.com>
26079
26080         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
26081         xreadlink.c now includes it unconditionally.
26082
26083 2003-07-01  Paul Eggert  <eggert@twinsun.com>
26084
26085         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
26086         having it depend on HAVE_SYS_TYPES_H.
26087
26088 2003-07-01  Bruno Haible  <bruno@clisp.org>
26089
26090         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
26091         <sys/types.h> should be sufficient.
26092         Reported by Paul Eggert.
26093
26094 2003-06-26  Karl Berry  <karl@gnu.org>
26095
26096         * config/depcomp: update from automake.
26097
26098 2003-06-26  Bruno Haible  <bruno@clisp.org>
26099
26100         * modules/human: Depend on module stdbool.
26101
26102 2003-06-25  Bruno Haible  <bruno@clisp.org>
26103
26104         * modules/readlink: New file.
26105         * modules/xreadlink: Depend on it.
26106         * MODULES.html.sh (func_all_modules): Add readlink.
26107
26108 2003-06-25  Bruno Haible  <bruno@clisp.org>
26109
26110         * m4/readlink.m4: New file.
26111
26112 2003-06-25  Bruno Haible  <bruno@clisp.org>
26113
26114         * lib/readlink.c: New file.
26115
26116 2003-06-22  Karl Berry  <karl@gnu.org>
26117
26118         * config/srclist.txt: update mkinstalldirs from automake.
26119         * config/mkinstalldirs: update.
26120
26121 2003-06-22  Bruno Haible  <bruno@clisp.org>
26122
26123         Portability to mingw32.
26124         * m4/ssize_t.m4: New file, from GNU gettext.
26125         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
26126         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
26127
26128 2003-06-22  Bruno Haible  <bruno@clisp.org>
26129
26130         * modules/safe-read: Add m4/ssize_t.m4.
26131         * modules/xreadlink: Add m4/ssize_t.m4.
26132
26133 2003-06-20  Bruno Haible  <bruno@clisp.org>
26134
26135         Assume C89, so PARAMS isn't needed.
26136         * lib/unicodeio.h (PARAMS): Remove.
26137         * lib/unicodeio.c: Don't use PARAMS.
26138
26139 2003-06-18  Karl Berry  <karl@gnu.org>
26140
26141         * config/config.{guess,sub}: update from prep.
26142
26143 2003-06-18  Jim Meyering  <jim@meyering.net>
26144
26145         Merge changes from coreutils.
26146         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
26147         Remove explicit declarations of xmalloc and realloc.
26148         Include xalloc.h.
26149         (read_utmp): Remove anachronistic cast of xmalloc.
26150
26151 2003-06-17  Paul Eggert  <eggert@twinsun.com>
26152
26153         Assume C89, so PARAMS isn't needed.
26154         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
26155         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
26156         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
26157         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
26158         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
26159         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
26160         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
26161         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
26162         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
26163         lib/xstrtod.h, lib/xstrtol.h: Likewise.
26164         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
26165         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
26166         no longer needed. Anyway, config.h should always be included before any
26167         other file.
26168
26169 2003-06-11  Simon Josefsson  <jas@extundo.com>
26170
26171         * modules/sysexits: New file.
26172         * MODULES.html.sh (func_all_modules): Add sysexits.
26173
26174 2003-06-11  Simon Josefsson  <jas@extundo.com>
26175
26176         * lib/sysexit_.h: New file.
26177
26178 2003-06-11  Derek Price  <derek@ximbiot.com>
26179
26180         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
26181         necessary.
26182
26183 2003-06-11  Bruno Haible  <bruno@clisp.org>
26184
26185         * m4/sysexits.m4: New file.
26186
26187 2003-06-10  Simon Josefsson  <jas@extundo.com>
26188
26189         * lib/argp.h: New file, from glibc.
26190         * lib/argp-ba.c: New file, from glibc.
26191         * lib/argp-eexst.c: New file, from glibc.
26192         * lib/argp-fmtstream.c: New file, from glibc.
26193         * lib/argp-fmtstream.h: New file, from glibc.
26194         * lib/argp-fs-xinl.c: New file, from glibc.
26195         * lib/argp-help.c: New file, from glibc.
26196         * lib/argp-namefrob.h: New file, from glibc.
26197         * lib/argp-parse.c: New file, from glibc.
26198         * lib/argp-pv.c: New file, from glibc.
26199         * lib/argp-pvh.c: New file, from glibc.
26200         * lib/argp-xinl.c: New file, from glibc.
26201
26202 2003-06-10  Simon Josefsson  <jas@extundo.com>
26203
26204         * modules/strchrnul: New file.
26205
26206 2003-06-10  Simon Josefsson  <jas@extundo.com>
26207
26208         * modules/argp: New file.
26209
26210 2003-06-10  Simon Josefsson  <jas@extundo.com>
26211
26212         * m4/strchrnul.m4: New file.
26213
26214 2003-06-10  Simon Josefsson  <jas@extundo.com>
26215
26216         * lib/strchrnul.h: New file.
26217         * lib/strchrnul.c: New file.
26218
26219 2003-06-10  Bruno Haible  <bruno@clisp.org>
26220
26221         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
26222
26223 2003-06-07  Karl Berry  <karl@gnu.org>
26224
26225         * config/config.{guess,sub}: update from prep.
26226
26227 2003-06-07  Jim Meyering  <jim@meyering.net>
26228
26229         * modules/strtod: Use $(...) notation, not @...@ for
26230         AC_REPLACE'd variables.
26231         * modules/localcharset: Likewise.
26232
26233 2003-06-07  Jim Meyering  <jim@meyering.net>
26234
26235         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
26236         in place of my name in the copyright comment.
26237         Remove definition and uses of __P.
26238
26239         From coreutils.
26240         * lib/stat.c: Don't declare xmalloc explicitly.
26241         Instead, include "xalloc.h".
26242         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
26243         xrealloc, and xcalloc return values.
26244         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
26245         Improve comment.
26246         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
26247
26248 2003-06-07  Bruno Haible  <bruno@clisp.org>
26249
26250         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
26251         avoid AC_CONFIG_LINKS.
26252         * modules/fnmatch (Makefile.am): Use explicit creation rule for
26253         fnmatch.h, to avoid AC_CONFIG_LINKS.
26254         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
26255
26256 2003-06-07  Bruno Haible  <bruno@clisp.org>
26257
26258         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
26259         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
26260         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
26261         directory.
26262         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
26263         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
26264         directory.
26265
26266 2003-06-06  Jim Meyering  <jim@meyering.net>
26267
26268         Merge from coreutils.
26269         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
26270         Consolidate declarations and initializations of *_base* locals.
26271
26272         Merge from coreutils.
26273         This avoids a core dump on systems without GNU putenv,
26274         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
26275         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
26276         (unsetenv): New static function, from GNU libc.
26277         (rpl_putenv): Use it.
26278
26279         * lib/modechange.c: Remove trailing blanks.
26280
26281         Merge from coreutils.
26282         * lib/fsusage.c: Remove declaration of statfs.
26283         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
26284
26285         * lib/posixtm.c: Include <stdbool.h> unconditionally.
26286
26287 2003-06-06  Jim Meyering  <jim@meyering.net>
26288
26289         * lib/stdbool_.h: Renamed from stdbool.h.in.
26290
26291 2003-06-06  Jim Meyering  <jim@meyering.net>
26292             Bruno Haible  <bruno@clisp.org>
26293
26294         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
26295         Adjust Makefile.am snippet not to redirect directly to target.
26296         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
26297
26298 2003-06-05  Paul Eggert  <eggert@twinsun.com>
26299
26300         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
26301         mismatch, look in future quarters as well as past.  This fixes a
26302         bug when processing fall-backwards gaps immediately after a long
26303         period of daylight-saving time.
26304
26305         * lib/mktime.c: Assume freestanding C89 or better.
26306         (HAVE_LIMITS_H): Remove.  Assume it's 1.
26307         (__P): Remove; not used.
26308         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
26309         (mktime, not_equal_tm, print_tm, check_result,
26310         main): Use prototypes.  Use const * where appropriate.
26311         (main): Fix typo in testing code that uncovered by above changes.
26312         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
26313
26314 2003-06-04  Paul Eggert  <eggert@twinsun.com>
26315
26316         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
26317         locale.h, localeconv.  This merges changes from coreutils.
26318
26319         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
26320         It can be removed after the next Autoconf is released.
26321         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
26322         needed.
26323
26324 2003-06-04  Paul Eggert  <eggert@twinsun.com>
26325
26326         * lib/mktime.c: Fix Debian bug 177940
26327         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
26328         (localtime_offset): Now long int, not time_t, because we want it
26329         to be guaranteed to be signed.  All uses changed.
26330         (__mktime_internal): If overflow would occur when adding offset,
26331         don't add it.
26332
26333         Merge 'human' changes from coreutils.  Rewrite to support
26334         locale-specific notations like thousands separators.
26335         * lib/human.c: Simplify authorship notice.
26336         Include human.h immediately after config.h.
26337         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
26338         <limits.h>: Do not include, since human.h does.
26339         (SIZE_MAX, UINTMAX_MAX): New macros.
26340         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
26341         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
26342         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
26343         (power_letter): Renamed from suffixes.
26344         (generate_suffix_backwards): Remove.
26345         (adjust_value): Now takes int style (because of human.h changes)
26346         and long double value (for greater precision on some platforms).
26347         (group_number): New function.
26348         (human_readable): Use it.  Use integer options, not enum.
26349         Put the options before the sizes in the arg list.
26350         Support all the new options.
26351         The old human_readable function has been removed;
26352         use inttostr.h instead.
26353         (human_readable, default_block_size, humblock):
26354         Use uintmax_t, not int, for block sizes.
26355         (human_readable_inexact, block_size_types): Remove.
26356         (block_size_opts): New constant.
26357         (human_options): Renamed from human_block_size, with new signature
26358         that allows block sizes up to UINTMAX_MAX.  All callers changed.
26359         * lib/human.h: Add copyright and authorship notice.
26360         Include <limits.h> and <stdbool.h> unconditionally.
26361         (PARAMS): Remove.  All uses removed.
26362         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
26363         (enum human_inexact_style): Remove tag; now a nameless enum.
26364         (human_floor, human_ceiling, human_round_to_even): Now have
26365         values 2, 0, 1 rather than -1, 1, 0.
26366         (human_group_digits, human_suppress_point_zero, human_autoscale,
26367         human_base_1024, human_SI, human_B): New constants.
26368         (human_readable_inexact, human_block_size): Remove.
26369         (human_readable): Size args are now uintmax_t, not int.
26370         (human_options): New decl.
26371
26372         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
26373         unnecessary now that we assume C89 or better.  This change
26374         imported from coreutils.
26375
26376         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
26377         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
26378         in the 2003-05-30 sync from glibc.
26379
26380         .h files should stand alone, but we shouldn't include <sys/types.h>
26381         if we can get away with just <stddef.h>.
26382
26383         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
26384         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
26385         rather than <sys/types.h>, as we merely need size_t.
26386         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
26387         to get size_t.
26388         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
26389         Include <stdio.h>, to get FILE.
26390         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
26391         memcasecmp.h has included <stddef.h> and all we need is size_t.
26392         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
26393         our interface, instead of including <sys/types.h>
26394
26395 2003-06-04  Paul Eggert  <eggert@twinsun.com>
26396
26397         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
26398         now, as glibc mktime is buggy on non-glibc systems.
26399
26400 2003-06-03  Karl Berry  <karl@gnu.org>
26401
26402         * config/config.sub: update from prep.
26403
26404 2003-06-02  Paul Eggert  <eggert@twinsun.com>
26405
26406         [from coreutils]
26407         Fix some minor time-related bugs with POSIX time arguments.
26408         Some valid time stamps were being rejected (notably -1, and
26409         time stamps before 1900 on 64-bit hosts).  And some invalid
26410         time stamps were being accepted, e.g. September 31.
26411
26412         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
26413         that we can return (time_t) -1 successfully.
26414         * lib/posixtm.c: Likewise.
26415         [HAVE_STDBOOL_H]: Include <stdbool.h>.
26416         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
26417         (t): Remove static var.
26418         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
26419         of static var.  All uses changed.
26420         (year): Do not reject years before 1900; they can occur with
26421         64-bit time_t.
26422         (posix_time_parse): Do not check for out-of-range components;
26423         that is now the caller's responsibility, since our checks were
26424         only approximations.
26425         (posixtime): Use mktime to check for out-of-range components,
26426         since it knows them exactly.
26427         If mktime returns (time_t) -1, check whether an error actually occurred
26428         by invoking localtime on -1.
26429         (main) [TEST_POSIXTIME]: Check for input data errors, and report
26430         posixtime failures better.
26431         Improve the test data (in comments only).
26432
26433 2003-06-02  Karl Berry  <karl@gnu.org>
26434
26435         * config/mkinstalldirs (version): new variable.
26436         (--version): new option.
26437         (usage): improve message.
26438
26439 2003-05-30  Karl Berry  <karl@gnu.org>
26440
26441         * lib/mktime.c: update from libc.
26442
26443 2003-05-30  Bruno Haible  <bruno@clisp.org>
26444
26445         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
26446         * config/config.rpath: Upgrade to gettext-0.12.1.
26447
26448 2003-05-30  Bruno Haible  <bruno@clisp.org>
26449
26450         * m4/gettext.m4: Upgrade to gettext-0.12.1.
26451         * m4/nls.m4: New file, from gettext-0.12.1.
26452         * m4/po.m4: New file, from gettext-0.12.1.
26453         * m4/progtest.m4: Upgrade to gettext-0.12.1.
26454
26455 2003-05-30  Bruno Haible  <bruno@clisp.org>
26456
26457         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
26458         * lib/localcharset.h: Likewise.
26459         * lib/localcharset.c: Likewise.
26460
26461 2003-05-29  Karl Berry  <karl@gnu.org>
26462
26463         * config/config.rpath: update from gettext.
26464
26465 2003-05-28  Paul Eggert  <eggert@twinsun.com>
26466
26467         Assume the headers required for C89 freestanding compilers.
26468         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
26469         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
26470         * m4/human.m4 (gl_HUMAN): Likewise.
26471         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
26472         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
26473         * m4/userspec.m4 (gl_USERSPEC): Likewise.
26474         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
26475         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
26476         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
26477
26478 2003-05-28  Paul Eggert  <eggert@twinsun.com>
26479
26480         Assume the headers required for C89 freestanding compilers.
26481         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
26482         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
26483         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
26484         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
26485         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
26486         define, since <limits.h> is guaranteed to do that.
26487         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
26488         * lib/exclude.c: Include <stdbool.h> unconditionally.
26489         * lib/tempname.c: Include <stddef.h> unconditionally.
26490         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
26491         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
26492         <stddef.h> does that.
26493         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
26494         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
26495         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
26496         needed.
26497         * lib/xstrtol.c: Likewise.
26498         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
26499         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
26500
26501         * lib/addext.c (addext): Use assignment rather than cast, to avoid
26502         warnings on some platforms.
26503
26504         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
26505         arbitrarily.
26506
26507 2003-05-26  Jim Meyering  <jim@meyering.net>
26508
26509         Merge in a change from coreutils:
26510         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
26511         that is guaranteed to be `no'.  Use `no_such_member' to indicate
26512         that condition, rather than `-1' which is slightly misleading.
26513         Change the name of the cache variable to have the gl_ prefix.
26514         Prompted by a patch from Richard Dawe for DJGPP.
26515
26516 2003-05-24  Karl Berry  <karl@gnu.org>
26517
26518         * config/config.guess: update from prep.
26519
26520 2003-05-22  Karl Berry  <karl@gnu.org>
26521
26522         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
26523
26524 2003-05-20  Karl Berry  <karl@gnu.org>
26525
26526         * config/config.guess: update from prep.
26527
26528 2003-05-18  Karl Berry  <karl@gnu.org>
26529
26530         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
26531         might actually be set by the user.
26532
26533         * config/depcomp, install-sh, mdate-sh: update from automake.
26534
26535 2003-05-17  Bruno Haible  <bruno@clisp.org>
26536
26537         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
26538         invalid expansion for AC_EGREP_CPP.
26539         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
26540         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
26541         Suggested by Akim Demaille <akim@epita.fr> in
26542         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
26543
26544 2003-05-12  Jim Meyering  <jim@meyering.net>
26545
26546         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
26547         the space-padded-by-default conversion specifiers, %e, %k, %l.
26548
26549 2003-05-12  Bruno Haible  <bruno@clisp.org>
26550
26551         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
26552         the string is longer than 4 KB.
26553
26554 2003-05-11  Karl Berry  <karl@gnu.org>
26555
26556         * config/config.{guess,sub}: update from prep.
26557
26558 2003-05-09  Bruno Haible  <bruno@clisp.org>
26559
26560         * modules/error: Add m4/strerror_r.m4 to file list.
26561
26562 2003-05-03  Bruno Haible  <bruno@clisp.org>
26563
26564         Upgrade to Unicode-4.0.
26565         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
26566         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
26567         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
26568         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
26569         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
26570         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
26571         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
26572         Change width of U+E0100..U+E01EF from 1 to 0.
26573
26574 2003-04-25  Jim Meyering  <jim@meyering.net>
26575
26576         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
26577         of type size_t, not int.
26578
26579 2003-04-25  Bruno Haible  <bruno@clisp.org>
26580
26581         * lib/copy-file.c: Include <stddef.h>, for size_t.
26582
26583 2003-04-21  Paul Eggert  <eggert@twinsun.com>
26584
26585         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
26586         code which expansion is under static control.  Patch imported from
26587         Akim Demaille's patch to Bison; see
26588         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
26589
26590 2003-04-14  Bruno Haible  <bruno@clisp.org>
26591
26592         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
26593
26594 2003-04-11  Jim Meyering  <jim@meyering.net>
26595
26596         Merge changes from Coreutils.
26597
26598         2003-03-22  Jim Meyering  <jim@meyering.net>
26599
26600         * lib/strftime.c (widen): Cast alloca return value to proper type.
26601
26602         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
26603
26604         From GNU libc.
26605         * lib/strftime.c (my_strftime): Handle very large width
26606         specifications for numeric values correctly.  Improve checks for
26607         overflow.
26608
26609         2003-01-19  Jim Meyering  <jim@meyering.net>
26610
26611         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
26612         definitions.
26613         (nl_get_alt_digit) [! defined my_strftime]: Define.
26614         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
26615         _nl_get_alt_digit and _nl_get_walt_digit.
26616
26617         * lib/strftime.c (my_strftime): Merge in locale-related changes from
26618         libc. These changes have no effect outside of _LIBC.
26619
26620 2003-04-10  Bruno Haible  <bruno@clisp.org>
26621
26622         * modules/findprog: New file.
26623         * MODULES.html.sh (func_all_modules): Add it.
26624
26625 2003-04-10  Bruno Haible  <bruno@clisp.org>
26626
26627         * m4/findprog.m4: New file.
26628         * m4/eaccess.m4: New file.
26629
26630 2003-04-10  Bruno Haible  <bruno@clisp.org>
26631
26632         * lib/findprog.h: New file, from GNU gettext.
26633         * lib/findprog.c: New file, from GNU gettext.
26634
26635 2003-04-05  Jim Meyering  <jim@meyering.net>
26636
26637         Merge changes from Coreutils.
26638
26639         * lib/exclude.h (PARAMS): Remove definition and uses.
26640         * lib/exclude.c: Remove uses of `PARAMS'.
26641
26642         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
26643         Add test-cases for DOS filenames. Declare program_name.
26644         (main): Set up program_name.  Patch by Rich Dawe.
26645
26646         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
26647         error from mntctl.
26648         Use mntctl's return value to drive the entry-processing loop, since
26649         we can't rely on the value of the vmt_length member in the last
26650         entry.  On some systems doing so could result in exhausting
26651         virtual memory.  Based in part on a patch from Mike Jetzer.
26652
26653 2003-04-04  Bruno Haible  <bruno@clisp.org>
26654
26655         * modules/linebreak: New file.
26656         * MODULES.html.sh (func_all_modules): Add it.
26657
26658 2003-04-04  Bruno Haible  <bruno@clisp.org>
26659
26660         * m4/linebreak.m4: New file.
26661
26662 2003-04-04  Bruno Haible  <bruno@clisp.org>
26663
26664         * lib/linebreak.h: New file, from GNU gettext.
26665         * lib/linebreak.c: New file, from GNU gettext with slight
26666         modifications.
26667         * lib/lbrkprop.h: New file, from GNU gettext.
26668
26669 2003-04-03  Bruno Haible  <bruno@clisp.org>
26670
26671         * modules/utf8-ucs4: New file.
26672         * modules/utf16-ucs4: New file.
26673         * modules/ucs4-utf8: New file.
26674         * modules/ucs4-utf16: New file.
26675         * MODULES.html.sh (func_all_modules): Add them.
26676
26677 2003-04-03  Bruno Haible  <bruno@clisp.org>
26678
26679         * m4/utf-ucs4.m4: New file.
26680         * m4/ucs4-utf.m4: New file.
26681
26682 2003-04-03  Bruno Haible  <bruno@clisp.org>
26683
26684         * lib/utf8-ucs4.h: New file, from GNU gettext.
26685         * lib/utf16-ucs4.h: New file, from GNU gettext.
26686         * lib/ucs4-utf8.h: New file, from GNU gettext.
26687         * lib/ucs4-utf16.h: New file, from GNU gettext.
26688
26689 2003-04-02  Bruno Haible  <bruno@clisp.org>
26690
26691         * modules/binary-io: New file.
26692         * MODULES.html.sh (func_all_modules): Add it.
26693
26694 2003-04-02  Bruno Haible  <bruno@clisp.org>
26695
26696         * lib/binary-io.h: New file, from GNU gettext.
26697
26698 2003-04-01  Bruno Haible  <bruno@clisp.org>
26699
26700         * modules/pathname: New file.
26701         * MODULES.html.sh (func_all_modules): Add it.
26702
26703 2003-04-01  Bruno Haible  <bruno@clisp.org>
26704
26705         * lib/pathname.h: New file, from GNU gettext.
26706         * lib/concatpath.c: New file, from GNU gettext.
26707
26708 2003-03-30  Bruno Haible  <bruno@clisp.org>
26709
26710         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
26711
26712 2003-03-30  Bruno Haible  <bruno@clisp.org>
26713
26714         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
26715         function chown() doesn't exist.
26716
26717 2003-03-28  Bruno Haible  <bruno@clisp.org>
26718
26719         * modules/copy-file: New file.
26720         * MODULES.html.sh (func_all_modules): Add it.
26721
26722 2003-03-28  Bruno Haible  <bruno@clisp.org>
26723
26724         * m4/copy-file.m4: New file.
26725
26726 2003-03-28  Bruno Haible  <bruno@clisp.org>
26727
26728         * lib/copy-file.h: New file, from GNU gettext.
26729         * lib/copy-file.c: New file, from GNU gettext.
26730
26731 2003-03-18  Jim Meyering  <jim@meyering.net>
26732
26733         * lib/quote.c (quote_n): Fix typo in comment.
26734
26735 2003-03-18  Bruno Haible  <bruno@clisp.org>
26736
26737         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
26738         checking.
26739         * m4/onceonly_2_57.m4: Likewise.
26740
26741 2003-03-17  Bruno Haible  <bruno@clisp.org>
26742
26743         * m4/onceonly.m4: Require autoconf 2.54 or newer.
26744         (m4_quote): Remove macro.
26745         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
26746
26747 2003-03-14  Jim Meyering  <jim@meyering.net>
26748
26749         Merge changes from Coreutils.
26750         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
26751         to be const, in order to avoid warnings.
26752         (obstack_room): Likewise.
26753         (obstack_empty_p): Likewise.
26754
26755 2003-03-14  Bruno Haible  <bruno@clisp.org>
26756
26757         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
26758         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
26759
26760 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26761
26762         Merge changes from Bison.
26763         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
26764         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
26765         when compiling Bison 1.875's `bitset bset = obstack_alloc
26766         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
26767         * lib/hash.c: Include <stdbool.h> unconditionally.
26768
26769 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26770
26771         * m4/onceonly.m4 (m4_quote): New macro.
26772         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
26773         Quote AC_FOREACH variable-expansions properly.
26774
26775 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26776
26777         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
26778
26779 2003-03-09  Paul Eggert  <eggert@twinsun.com>
26780
26781         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
26782         Reported by Bruce Becker; see:
26783         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
26784
26785 2003-03-03  Paul Eggert  <eggert@twinsun.com>
26786             Bruno Haible  <bruno@clisp.org>
26787
26788         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
26789         Reported by John Hughes, see
26790         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
26791
26792 2003-02-20  Bruno Haible  <bruno@clisp.org>
26793
26794         * MODULES.html.sh (func_all_modules): Add poll.
26795
26796 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
26797
26798         * modules/poll: New file.
26799
26800 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
26801
26802         * lib/poll_.h: New file.
26803         * lib/poll.c: New file.
26804
26805 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
26806
26807         * m4/poll.m4: New file.
26808
26809 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
26810
26811         * modules/mathl: New file.
26812
26813 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
26814
26815         * lib/mathl.h: New file.
26816         * lib/acosl.c: New file.
26817         * lib/asinl.c: New file.
26818         * lib/atanl.c: New file.
26819         * lib/ceill.c: New file.
26820         * lib/cosl.c: New file.
26821         * lib/expl.c: New file.
26822         * lib/floorl.c: New file.
26823         * lib/frexpl.c: New file.
26824         * lib/ldexpl.c: New file.
26825         * lib/logl.c: New file.
26826         * lib/sincosl.c: New file.
26827         * lib/sinl.c: New file.
26828         * lib/sqrtl.c: New file.
26829         * lib/tanl.c: New file.
26830         * lib/trigl.c: New file.
26831         * lib/trigl.h: New file.
26832
26833 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
26834
26835         * m4/mathl.m4: New file.
26836
26837 2003-02-18  Bruno Haible  <bruno@clisp.org>
26838
26839         * MODULES.html.sh (func_all_modules): Add mathl.
26840
26841 2003-02-17  Bruno Haible  <bruno@clisp.org>
26842
26843         * modules/mkdtemp: New module.
26844         * MODULES.html.sh (func_all_modules): Add it.
26845
26846 2003-02-17  Bruno Haible  <bruno@clisp.org>
26847
26848         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
26849
26850 2003-02-17  Bruno Haible  <bruno@clisp.org>
26851
26852         * lib/mkdtemp.h: New file, from GNU gettext.
26853         * lib/mkdtemp.c: New file, from GNU gettext.
26854
26855 2003-02-02  Jim Meyering  <jim@meyering.net>
26856
26857         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
26858         e.g. glibc-2.2.93.
26859
26860 2003-01-31  Bruno Haible  <bruno@clisp.org>
26861
26862         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
26863         'rpl_rename'.
26864         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
26865         'rpl_strnlen'.
26866         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
26867         'rpl_strtod'.
26868         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
26869         'rpl_utime'.
26870
26871 2003-01-31  Bruno Haible  <bruno@clisp.org>
26872
26873         * lib/rename.c: #undef rename before defining rpl_rename.
26874         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
26875
26876 2003-01-30  Bruno Haible  <bruno@clisp.org>
26877
26878         * modules/vasnprintf, modules/vasprintf: New modules.
26879         * MODULES.html.sh (func_all_modules): Add them.
26880
26881 2003-01-30  Bruno Haible  <bruno@clisp.org>
26882
26883         * m4/signed.m4: New file, from GNU gettext.
26884         * m4/longdouble.m4: New file, from GNU gettext.
26885         * m4/wchar_t.m4: New file, from GNU gettext.
26886         * m4/wint_t.m4: New file, from GNU gettext.
26887         * m4/vasnprintf.m4: New file.
26888         * m4/vasprintf.m4: New file.
26889
26890 2003-01-30  Bruno Haible  <bruno@clisp.org>
26891
26892         * lib/printf-args.h: New file, from GNU gettext.
26893         * lib/printf-args.c: New file, from GNU gettext.
26894         * lib/printf-parse.h: New file, from GNU gettext.
26895         * lib/printf-parse.c: New file, from GNU gettext.
26896         * lib/vasnprintf.h: New file, from GNU gettext.
26897         * lib/vasnprintf.c: New file, from GNU gettext.
26898         * lib/asnprintf.c: New file, from GNU gettext.
26899         * lib/vasprintf.h: New file, from GNU gettext with modifications.
26900         * lib/vasprintf.c: New file, from GNU gettext.
26901         * lib/asprintf.c: New file, from GNU gettext.
26902
26903 2003-01-29  Bruno Haible  <bruno@clisp.org>
26904
26905         * modules/stpncpy: New module.
26906         * MODULES.html.sh (func_all_modules): Add it.
26907
26908 2003-01-29  Bruno Haible  <bruno@clisp.org>
26909
26910         * m4/stpncpy.m4: New file.
26911
26912 2003-01-29  Bruno Haible  <bruno@clisp.org>
26913
26914         * lib/stpncpy.h: New file, from GNU gettext with modifications.
26915         * lib/stpncpy.c: New file, from GNU gettext with modifications.
26916
26917 2003-01-28  Bruno Haible  <bruno@clisp.org>
26918
26919         * modules/c-ctype: New module.
26920         * MODULES.html.sh (func_all_modules): Add it.
26921
26922 2003-01-28  Bruno Haible  <bruno@clisp.org>
26923
26924         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
26925         Paul Eggert.
26926         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
26927         Paul Eggert.
26928
26929 2003-01-27  Bruno Haible  <bruno@clisp.org>
26930
26931         * modules/xsetenv: New module.
26932         * MODULES.html.sh (func_all_modules): Add it.
26933
26934 2003-01-27  Bruno Haible  <bruno@clisp.org>
26935
26936         * lib/xsetenv.h: New file, from GNU gettext.
26937         * lib/xsetenv.c: New file, from GNU gettext.
26938
26939 2003-01-23  Jim Meyering  <jim@meyering.net>
26940
26941         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
26942         from working on systems without dirfd (at least Irix and OSF1/Tru64).
26943
26944 2003-01-23  Bruno Haible  <bruno@clisp.org>
26945
26946         * modules/minmax: New module.
26947         * MODULES.html.sh (func_all_modules): Add it.
26948
26949 2003-01-23  Bruno Haible  <bruno@clisp.org>
26950
26951         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
26952         Eggert.
26953
26954 2003-01-22  Bruno Haible  <bruno@clisp.org>
26955
26956         * modules/exit: New module.
26957         * MODULES.html.sh (func_all_modules): Add it.
26958
26959 2003-01-22  Bruno Haible  <bruno@clisp.org>
26960
26961         * lib/exit.h: New file, from GNU gettext.
26962
26963 2003-01-19  Bruno Haible  <bruno@clisp.org>
26964
26965         * gnulib-tool: Recognize option --extract-maintainer.
26966         (func_get_maintainer): New function.
26967         * modules/*: Add Maintainer entry.
26968
26969 2003-01-16  Jim Meyering  <jim@meyering.net>
26970
26971         * m4/regex.m4: The `regex' struct is both input and output.
26972         Initialize it before each use.  Patch by Tim Waugh.
26973
26974 2003-01-16  Bruno Haible  <bruno@clisp.org>
26975
26976         * MODULES.html.sh: Add a table of contents. Add the module name as
26977         leftmost column. Add hyperlinks.
26978
26979 2003-01-15  Bruno Haible  <bruno@clisp.org>
26980
26981         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
26982
26983 2003-01-15  Bruno Haible  <bruno@clisp.org>
26984
26985         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
26986         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
26987         suffix.
26988
26989 2003-01-15  Bruno Haible  <bruno@clisp.org>
26990
26991         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
26992
26993 2003-01-15  Bruno Haible  <bruno@clisp.org>
26994
26995         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
26996         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
26997
26998 2003-01-14  Jim Meyering  <jim@meyering.net>
26999
27000         * lib/same.c (same_name): Tweak a comment.
27001
27002 2003-01-14  Bruno Haible  <bruno@clisp.org>
27003
27004         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
27005         when a string comparison is sufficient.
27006
27007 2003-01-14  Bruno Haible  <bruno@clisp.org>
27008
27009         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
27010         'unsigned int'.
27011
27012 2003-01-14  Bruno Haible  <bruno@clisp.org>
27013
27014         * lib/hash-pjw.c: Add comment about low quality of this function.
27015
27016 2003-01-13  Bruno Haible  <bruno@clisp.org>
27017
27018         * modules/stpcpy: Distribute lib/stpcpy.h.
27019         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
27020
27021 2003-01-13  Bruno Haible  <bruno@clisp.org>
27022
27023         * modules/*: Add a description.
27024         * modules/strpbrk: Fix Makefile.am snippet.
27025         * modules/strtoimax: Fix dependencies.
27026         * modules/strtoumax: Likewise.
27027
27028 2003-01-13  Bruno Haible  <bruno@clisp.org>
27029
27030         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
27031         * modules/alloca (Makefile.am): All object files depend on alloca.h.
27032         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
27033
27034 2003-01-13  Bruno Haible  <bruno@clisp.org>
27035
27036         * gnulib-tool (func_create_testdir): Store config/* files in the main
27037         directory.
27038         * config.rpath: Move to ...
27039         * config/config.rpath: ... here.
27040         * modules/gettext: Contains config/config.rpath, not config.rpath.
27041         * modules/iconv: Likewise.
27042
27043 2003-01-12  Paul Eggert  <eggert@twinsun.com>
27044
27045         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
27046         to avoid collisions with libcurses and libreadline.
27047
27048         * m4/getstr.m4: Remove.
27049         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
27050
27051 2003-01-12  Paul Eggert  <eggert@twinsun.com>
27052
27053         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
27054         to avoid collisions with libcurses and libreadline.
27055
27056         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
27057         * lib/getstr.h, getstr.c: Remove.
27058         * lib/getline.c: Include "getline.h", to check interface.
27059         Move body of old getstr.c here: this defines MIN_CHUNK and
27060         declares getdelim2, which is renamed from getstr.
27061         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
27062
27063         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
27064         All uses changed.
27065         * lib/linebuffer.h: Likewise.
27066         (readline): Remove backward-compatibility macro.
27067
27068 2003-01-12  Paul Eggert  <eggert@twinsun.com>
27069
27070         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
27071         to avoid collisions with libcurses and libreadline.
27072         * getstr: Remove.
27073         * MODULES.html.sh: Remove getstr.
27074         * modules/getline: Depend on unlocked-io, not getstr.
27075
27076 2003-01-12  Jim Meyering  <jim@meyering.net>
27077
27078         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
27079
27080 2003-01-10  Bruno Haible  <bruno@clisp.org>
27081
27082         * modules/alloca: Change Makefile.am requirements. Simplify Include
27083         requirements. Add lib/alloca_.h to file list.
27084
27085 2003-01-10  Bruno Haible  <bruno@clisp.org>
27086
27087         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
27088
27089 2003-01-10  Bruno Haible  <bruno@clisp.org>
27090
27091         * lib/alloca_.h: New file.
27092         * lib/getdate.y: Unconditionally include alloca.h.
27093         * lib/makepath.c: Likewise.
27094         * lib/setenv.c: Likewise.
27095         * lib/userspec.c: Likewise.
27096
27097 2003-01-09  Karl Berry  <karl@gnu.org>
27098
27099         * MODULES.html.sh: include `dirname $0` in PATH, to find
27100         gnulib-tool.
27101
27102 2003-01-09  Bruno Haible  <bruno@clisp.org>
27103
27104         * modules/stdbool: Change configure.ac, Makefile.am requirements.
27105         Simplify Include requirements. Add lib/stdbool.h.in to file list.
27106
27107 2003-01-09  Bruno Haible  <bruno@clisp.org>
27108
27109         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
27110
27111 2003-01-09  Bruno Haible  <bruno@clisp.org>
27112
27113         * lib/stdbool.h.in: New file.
27114
27115 2003-01-09  Bruno Haible  <bruno@clisp.org>
27116
27117         * gnulib-tool (func_all_modules): Ignore files ending in ~.
27118         * MODULES.html.sh: Likewise.
27119
27120 2003-01-08  Jim Meyering  <jim@meyering.net>
27121
27122         * lib/full-write.c: Undefine and define-away `const' after inclusion
27123         of errno.h, not before.  Suggestion from Bruno Haible.
27124
27125 2003-01-08  Bruno Haible  <bruno@clisp.org>
27126
27127         * modules/full-read: Depend on full-write.
27128
27129 2003-01-08  Bruno Haible  <bruno@clisp.org>
27130
27131         * lib/safe-read.c: Include specification header first, to ensure its
27132         selfcontainedness.
27133         * lib/full-write.c: Likewise.
27134
27135 2003-01-07  Jim Meyering  <jim@meyering.net>
27136
27137         * lib/full-write.c: Rework so that it may serve to define full_read,
27138         too.
27139         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
27140
27141 2003-01-07  Bruno Haible  <bruno@clisp.org>
27142
27143         * lib/strtoimax.c: Include <stdint.h> as an alternative to
27144         <inttypes.h>.
27145         * lib/xstrtol.h: Likewise.
27146         * lib/xstrtoimax.c: Likewise.
27147         * lib/xstrtoumax.c: Likewise.
27148         * lib/human.h: Likewise.
27149
27150         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
27151         on systems that have <inttypes.h> but not <stdint.h>.
27152
27153 2003-01-07  Bruno Haible  <bruno@clisp.org>
27154
27155         * MODULES.html.sh: Add copyright notice.
27156         (missed_files): Omit CVS directory entries.
27157         (func_module): Make it work with sed-3.02.
27158         * MODULES.txt: Remove file.
27159
27160 2003-01-06  Jim Meyering  <jim@meyering.net>
27161
27162         * lib/version-etc.c: Update year in translatable copyright string.
27163
27164 2003-01-03  Karl Berry  <karl@gnu.org>
27165
27166         * config/config.{guess,sub}: update from prep.
27167
27168 2003-01-02  Karl Berry  <karl@gnu.org>
27169
27170         * doc/COPYING.DOC: belatedly updated to 1.2.
27171
27172 2003-01-01  Karl Berry  <karl@gnu.org>
27173
27174         * gnulib-tool (func_verify_module): report module name $module in
27175         error message, not $1.
27176         * gnulib-tool (create-testdir): don't complain if destdir couldn't
27177         be created, only if it doesn't exist.
27178         * gnulib-tool (last_checkin_date): don't expand the $Date here.
27179
27180 2002-12-31  Paul Eggert  <eggert@twinsun.com>
27181
27182         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
27183
27184 2002-12-31  Paul Eggert  <eggert@twinsun.com>
27185
27186         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
27187         memcmp if strcoll doesn't work.
27188
27189 2002-12-31  Bruno Haible  <bruno@clisp.org>
27190
27191         * lib/utime.c (utime_null): No need to call ftruncate if the file was
27192         nonempty.
27193
27194 2002-12-31  Bruno Haible  <bruno@clisp.org>
27195
27196         * lib/memcoll.c (STRCOLL): New macro.
27197         (memcoll): Use it.
27198
27199 2002-12-31  Bruno Haible  <bruno@clisp.org>
27200
27201         * lib/localcharset.h: New file.
27202         * lib/localcharset.c: Include it.
27203         * lib/unicodeio.c: Likewise.
27204
27205 2002-12-31  Bruno Haible  <bruno@clisp.org>
27206
27207         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
27208         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
27209
27210 2002-12-31  Bruno Haible  <bruno@clisp.org>
27211
27212         * lib/getline.h: Include <stddef.h>, for size_t.
27213
27214         * lib/unicodeio.h: Include <stddef.h>, for size_t.
27215         * lib/unicodeio.c: Don't include <stddef.h>.
27216
27217 2002-12-31  Bruno Haible  <bruno@clisp.org>
27218
27219         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
27220         HAVE_TM_ZONE.
27221
27222 2002-12-24  Karl Berry  <karl@gnu.org>
27223
27224         * config/config.guess: update from prep.
27225
27226 2002-12-24  Bruno Haible  <bruno@clisp.org>
27227
27228         General infrasructure.
27229         * m4/README: Rewritten.
27230         * m4/onceonly.m4: New file.
27231         * m4/onceonly_2_57.m4: New file.
27232
27233         Module atexit.
27234         * m4/atexit.m4: New file.
27235
27236         Module strtod.
27237         * m4/strtod.m4: New file.
27238
27239         Module strtol.
27240         * m4/strtol.m4: New file.
27241
27242         Module strtoul.
27243         * m4/strtoul.m4: New file.
27244
27245         Module memchr.
27246         * m4/memchr.m4: New file.
27247
27248         Module memcmp.
27249         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
27250         (jm_FUNC_MEMCMP): Invoke it.
27251
27252         Module memcpy.
27253         * m4/memcpy.m4: New file.
27254
27255         Module memmove.
27256         * m4/memmove.m4: New file.
27257
27258         Module memset.
27259         * m4/memset.m4: New file.
27260
27261         Module strcspn.
27262         * m4/strcspn.m4: New file.
27263
27264         Module strpbrk.
27265         * m4/strpbrk.m4: New file.
27266
27267         Module strstr.
27268         * m4/strstr.m4: New file.
27269
27270         Module strerror.
27271         * m4/strerror.m4: New file.
27272
27273         Module mktime.
27274         * m4/mktime.m4: Renamed from jm-mktime.m4.
27275         (gl_PREREQ_MKTIME): New macro.
27276         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
27277
27278         Module malloc.
27279         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
27280         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
27281         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
27282
27283         Module realloc.
27284         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
27285         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
27286         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
27287
27288         Module strftime.
27289         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
27290         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
27291         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
27292         gl_TM_GMTOFF.
27293         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
27294
27295         Module xalloc.
27296         * m4/xalloc.m4: New file.
27297
27298         Module alloca.
27299         * m4/alloca.m4: New file.
27300
27301         Module putenv.
27302         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
27303         (jm_FUNC_PUTENV): Invoke it.
27304
27305         Module setenv.
27306         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
27307         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
27308         when invoked twice.
27309         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
27310         gt_FUNC_SETENV.
27311
27312         Module memrchr.
27313         * m4/memrchr.m4: New file.
27314
27315         Module stpcpy.
27316         * m4/stpcpy.m4: New file.
27317
27318         Module strcase.
27319         * m4/strcase.m4: New file.
27320
27321         Module strdup.
27322         * m4/strdup.m4: New file.
27323
27324         Module strnlen.
27325         * m4/strnlen.m4: New file.
27326
27327         Module strndup.
27328         * m4/strndup.m4: New file.
27329
27330         Module xstrtod.
27331         * m4/xstrtod.m4: New file.
27332
27333         Module xstrtol.
27334         * m4/xstrtol.m4: New file.
27335
27336         Module getdate.
27337         * m4/getdate.m4: New file.
27338
27339         Module unlocked-io.
27340         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
27341         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
27342         * m4/jm-glibc-io.m4n: Remove file.
27343
27344         Module long-options.
27345         * m4/long-options.m4: New file.
27346
27347         Module md5.
27348         * m4/md5.m4: New file.
27349
27350         Module sha.
27351         * m4/sha.m4: New file.
27352
27353         Module getstr.
27354         * m4/getstr.m4: New file.
27355
27356         Module getline.
27357         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
27358         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
27359         <sys/types.h>, for size_t. Use the function name gnu_getline, not
27360         simply getline. Infoke gl_PREREQ_GETLINE.
27361
27362         Module obstack.
27363         * m4/obstack.m4: New file.
27364
27365         Module hash.
27366         * m4/hash.m4: New file.
27367
27368         Module readtokens.
27369         * m4/readtokens.m4: New file.
27370
27371         Module strverscmp.
27372         * m4/strverscmp.m4: New file.
27373
27374         Module stdbool.
27375         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
27376         OSF/1.
27377
27378         Module strtoll.
27379         * m4/strtoll.m4: New file.
27380
27381         Module strtoull.
27382         * m4/strtoull.m4: New file.
27383
27384         Module strtoimax.
27385         * m4/strtoimax.m4: New file.
27386
27387         Module strtoumax.
27388         * m4/strtoumax.m4: New file.
27389
27390         Module xstrtoimax.
27391         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
27392         jm_AC_PREREQ_XSTRTOIMAX.
27393         Moved the strtol prerequisites to strtol.m4.
27394         Moved the strtoll prerequisites to strtoll.m4.
27395         Moved the strtoimax prerequisites to strtoimax.m4.
27396
27397         Module xstrtoumax.
27398         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
27399         jm_AC_PREREQ_XSTRTOUMAX.
27400         Moved the strtoul prerequisites to strtoul.m4.
27401         Moved the strtoull prerequisites to strtoull.m4.
27402         Moved the strtoumax prerequisites to strtoumax.m4.
27403
27404         Module chown.
27405         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
27406         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
27407
27408         Module dup2.
27409         * m4/dup2.m4: New file.
27410
27411         Module ftruncate.
27412         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
27413         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
27414
27415         Module getgroups.
27416         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
27417         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
27418
27419         Module gettimeofday.
27420         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
27421         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
27422         gl_PREREQ_GETTIMEOFDAY.
27423
27424         Module mkdir.
27425         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
27426         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
27427
27428         Module mkstemp.
27429         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
27430         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
27431         jm_AC_TYPE_UINTMAX_T.
27432         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
27433
27434         Module stat.
27435         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
27436         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
27437
27438         Module lstat.
27439         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
27440         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
27441
27442         Module timespec.
27443         * m4/timespec.m4 (gl_TIMESPEC): New macro.
27444         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
27445         * m4/st_mtim.m4: Indentation.
27446
27447         Module nanosleep.
27448         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
27449         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
27450         gl_PREREQ_NANOSLEEP.
27451
27452         Module regex.
27453         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
27454         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
27455         (gl_REGEX): New macro.
27456
27457         Module rename.
27458         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
27459         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
27460
27461         Module rmdir.
27462         * m4/rmdir.m4: New file.
27463
27464         Module utime.
27465         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
27466         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
27467         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
27468
27469         Module dirname.
27470         * m4/dirname.m4: New file.
27471
27472         Module getopt.
27473         * m4/getopt.m4: New file.
27474
27475         Module unistd-safer.
27476         * m4/unistd-safer.m4: New file.
27477
27478         Module fnmatch.
27479         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
27480         declaration.
27481         (gl_PREREQ_FNMATCH_EXTRA): New macro.
27482         (gl_FUNC_FNMATCH_POSIX): New macro.
27483         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
27484         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
27485         simply fnmatch.
27486
27487         Module exclude.
27488         * m4/exclude.m4: New file.
27489
27490         Module human.
27491         * m4/human.m4: New file.
27492
27493         Module acl.
27494         * m4/acl.m4: Nop.
27495
27496         Module backupfile.
27497         * m4/backupfile.m4: New file.
27498         * m4/d-ino.m4: Indentation.
27499
27500         Module fsusage.
27501         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
27502         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
27503         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
27504
27505         Module dirfd.
27506         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
27507         requirements.
27508
27509         Module euidaccess.
27510         * m4/euidaccess.m4: New file.
27511
27512         Module file-type.
27513         * m4/file-type.m4: New file.
27514
27515         Module fileblocks.
27516         * m4/fileblocks.m4: New file.
27517
27518         Module filemode.
27519         * m4/filemode.m4: New file.
27520
27521         Module isdir.
27522         * m4/isdir.m4: New file.
27523
27524         Module lchown.
27525         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
27526         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
27527
27528         Module makepath.
27529         * m4/makepath.m4: New file.
27530
27531         Module modechange.
27532         * m4/modechange.m4: New file.
27533
27534         Module mountlist.
27535         * m4/mountlist.m4: New file.
27536         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
27537         Indentation.
27538
27539         Module path-concat.
27540         * m4/path-concat.m4: New file.
27541
27542         Module pathmax.
27543         * m4/pathmax.m4: New file.
27544
27545         Module same.
27546         * m4/same.m4: New file.
27547
27548         Module save-cwd.
27549         * m4/save-cwd.m4: New file.
27550
27551         Module savedir.
27552         * m4/savedir.m4: New file.
27553
27554         Module xgetcwd.
27555         * m4/xgetcwd.m4: New file.
27556         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
27557
27558         Module xreadlink.
27559         * m4/xreadlink.m4: New file.
27560
27561         Module safe-read.
27562         * m4/safe-read.m4: New file.
27563
27564         Module safe-write.
27565         * m4/safe-write.m4: New file.
27566
27567         Module closeout.
27568         * m4/closeout.m4: New file.
27569
27570         Module stdio-safer.
27571         * m4/stdio-safer.m4: New file.
27572
27573         Module getpass.
27574         * m4/getpass.m4: New file.
27575
27576         Module getugroups.
27577         * m4/getugroups.m4: New file.
27578
27579         Module group-member.
27580         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
27581         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
27582
27583         Module idcache.
27584         * m4/idcache.m4: New file.
27585
27586         Module userspec.
27587         * m4/userspec.m4: New file.
27588
27589         Module gettime.
27590         * m4/clock_time.m4: New file.
27591         * m4/gettime.m4: New file.
27592
27593         Module settime.
27594         * m4/settime.m4: New file.
27595
27596         Module posixtm.
27597         * m4/posixtm.m4: New file.
27598
27599         Module gethostname.
27600         * m4/gethostname.m4: New file.
27601
27602         Module canon-host.
27603         * m4/canon-host.m4: New file.
27604
27605         Module gettext.
27606         * m4/codeset.m4: New file, from gettext-0.11.5.
27607         * m4/gettext.m4: New file, from gettext-0.11.5.
27608         * m4/glibc21.m4: New file, from gettext-0.11.5.
27609         * m4/iconv.m4: New file, from gettext-0.11.5.
27610         * m4/intdiv0.m4: New file, from gettext-0.11.5.
27611         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
27612         * m4/inttypes.m4: New file, from gettext-0.11.5.
27613         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
27614         * m4/isc-posix.m4: New file, from gettext-0.11.5.
27615         * m4/lcmessage.m4: New file, from gettext-0.11.5.
27616         * m4/lib-ld.m4: New file, from gettext-0.11.5.
27617         * m4/lib-link.m4: New file, from gettext-0.11.5.
27618         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
27619         * m4/progtest.m4: New file, from gettext-0.11.5.
27620         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
27621         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
27622         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
27623
27624         Module localcharset.
27625         * m4/localcharset.m4: New file.
27626
27627         Module hard-locale.
27628         * m4/hard-locale.m4: New file.
27629
27630         Module mbswidth.
27631         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
27632         onceonly macros.
27633         * m4/mbrtowc.m4: Add comment.
27634
27635         Module memcasecmp.
27636         * m4/memcasecmp.m4: New file.
27637
27638         Module memcoll.
27639         * m4/memcoll.m4: New file.
27640
27641         Module unicodeio.
27642         * m4/unicodeio.m4: New file.
27643
27644         Module rpmatch.
27645         * m4/rpmatch.m4: New file.
27646
27647         Module yesno.
27648         * m4/yesno.m4: New file.
27649
27650         Module exitfail.
27651         * m4/exitfail.m4: New file.
27652
27653         Module c-stack.
27654         * m4/c-stack.m4 (gl_C_STACK): New macro.
27655         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
27656
27657         Module error.
27658         * m4/error.m4 (gl_ERROR): New macro.
27659         (jm_PREREQ_ERROR): Use onceonly macros.
27660
27661         Module fatal.
27662         * m4/fatal.m4: New file.
27663
27664         Module getloadavg.
27665         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
27666         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
27667
27668         Module getpagesize.
27669         * m4/getpagesize.m4: New file.
27670
27671         Module getusershell.
27672         * m4/getusershell.m4: New file.
27673
27674         Module physmem.
27675         * m4/physmem.m4: New file.
27676
27677         Module posixver.
27678         * m4/posixver.m4: New file.
27679
27680         Module quotearg.
27681         * m4/quotearg.m4: New file.
27682
27683         Module quote.
27684         * m4/quote.m4: New file.
27685
27686         Module readutmp.
27687         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
27688
27689         Module sig2str.
27690         * m4/sig2str.m4: New file.
27691
27692         Other.
27693         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
27694         ulonglong.m4.
27695         * m4/intmax_t.m4: New file.
27696         * m4/d-type.m4: Indentation.
27697         * m4/jm-macros.m4: Update.
27698         * m4/prereq.m4 (jm_PREREQ): Update.
27699         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
27700         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
27701         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
27702         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
27703         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
27704         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
27705         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
27706         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
27707         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
27708         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
27709         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
27710         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
27711         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
27712         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
27713         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
27714         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
27715         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
27716         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
27717         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
27718
27719 2002-12-24  Bruno Haible  <bruno@clisp.org>
27720
27721         * MODULES.txt: Update according to m4/ changes.
27722
27723         Module gettext.
27724         * config.rpath: New file, from gettext-0.11.5.
27725
27726         * modules/*: New module descriptions.
27727         * gnulib-tool: New file.
27728         * MODULES.html.sh: New file.
27729
27730 2002-12-21  Karl Berry  <karl@gnu.org>
27731
27732         * doc/fdl.texi: update to version 1.2.
27733
27734 2002-12-19  Karl Berry  <karl@gnu.org>
27735
27736         * config/config.guess: update from prep.
27737
27738 2002-12-18  Bruno Haible  <bruno@clisp.org>
27739
27740         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
27741         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
27742
27743 2002-12-17  Bruno Haible  <bruno@clisp.org>
27744
27745         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
27746         stdlib.h, string.h.
27747
27748 2002-12-17  Bruno Haible  <bruno@clisp.org>
27749
27750         * lib/canon-host.c (strdup): Remove unused declaration.
27751
27752         * lib/fsusage.c: Include full_read.h.
27753         (get_fs_usage): Use full_read instead of safe_read.
27754
27755         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
27756
27757 2002-12-12  Karl Berry  <karl@gnu.org>
27758
27759         * config/config.guess: update from prep.
27760
27761 2002-12-11  Bruno Haible  <bruno@clisp.org>
27762
27763         * m4/setenv.m4: New file, from gettext-0.11.5.
27764
27765 2002-12-11  Bruno Haible  <bruno@clisp.org>
27766
27767         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
27768         not unsetenv().
27769         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
27770         modifications:
27771
27772         2002-12-11  Bruno Haible  <bruno@clisp.org>
27773
27774                 * setenv.c (alloca): Fall back to malloc.
27775                 (freea): New macro.
27776                 (setenv): Use freea() to free memory allocated with alloca().
27777
27778         2002-11-13  Bruno Haible  <bruno@clisp.org>
27779
27780                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
27781                 function declarations.
27782                 * unsetenv.c (unsetenv): Likewise.
27783
27784         2002-03-04  Bruno Haible  <bruno@clisp.org>
27785
27786                 Portability to AIX 4.3.3.
27787                 * unsetenv.c: New file, extracted from setenv.c.
27788                 * setenv.c: Move the unsetenv() function to unsetenv.c.
27789
27790         2001-12-20  Bruno Haible  <bruno@clisp.org>
27791
27792                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
27793                 use malloc instead. For SunOS 4.
27794
27795         2001-12-11  Bruno Haible  <bruno@clisp.org>
27796
27797                 * setenv.c: Declare alloca.
27798                 (compar_fn_t): New typedef.
27799                 (KNOWN_VALUE, STORE_VALUE): Use it.
27800
27801         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
27802         setenv.h.
27803
27804 2002-12-10  Paul Eggert  <eggert@twinsun.com>
27805
27806         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
27807         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
27808         Choose values that are less likely to collide with system fnmatch
27809         options.
27810         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
27811         defined (e.g., a pure POSIX system).
27812         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
27813         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
27814
27815 2002-12-06  Paul Eggert  <eggert@twinsun.com>
27816
27817         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
27818         a pain in practice to deal with generated m4 files.  This change
27819         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
27820
27821         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
27822         and jm-glibc-io.m4, as they are no longer a special case.
27823         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
27824         kludge and the auto-generation stuff.  Check only whether the
27825         functions are declared, not whether they exist, since older hosts
27826         that don't declare the functions can't use the optimization anyway.
27827
27828 2002-12-06  Jim Meyering  <jim@meyering.net>
27829
27830         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
27831
27832         Merge in changes from libc's misc/error.c, in preparation
27833         for the merge of gnulib's changes back into libc.
27834
27835         * lib/error.c (_): Define only if not already defined.
27836         Move definition to follow all #include directives.
27837         Include unlocked-io.h only if !_LIBC.
27838         [_LIBC]: Include <libio/libioP.h>.
27839         [USE_IN_LIBIO]: Include <libio/iolibio.h>
27840         (fflush): Tweak definition to use INTUSE.
27841         (putc): Define.
27842
27843 2002-12-05  Paul Eggert  <eggert@twinsun.com>
27844
27845         * lib/alloca.c [defined emacs]: Include "lisp.h".
27846         (xalloc_die) [defined emacs]: New macro.
27847         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
27848         [! defined emacs]: Include <xalloc.h>.
27849         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
27850         (pointer): Typedef to POINTER_TYPE *.
27851         (malloc): Remove decl; we now always use xmalloc.
27852         (alloca): Use old-style definition, since Emacs needs this.
27853         Check for arithmetic overflow when computing combined size.
27854
27855 2002-12-04  Paul Eggert  <eggert@twinsun.com>
27856
27857         Do not generate unlocked-io.h automatically, since it's easier to
27858         maintain it by hand.
27859
27860         * lib/unlocked-io.h: New file, from GNU diffutils,
27861         but with proper copyright notice and attribution.
27862         * lib/gen-uio: Remove.
27863         * lib/Makefile.am: Add copyright notice.
27864         (libfetish_a_SOURCES): Add unlocked-io.h.
27865         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
27866         (DISTCLEANFILES, io_functions): Remove macros.
27867         (EXTRA_DIST): Remove gen_uio.
27868         (unlocked-io.h): Remove rule.
27869
27870 2002-12-04  Jim Meyering  <jim@meyering.net>
27871
27872         Reflect the fact that stat.c and lstat.c are no longer generated.
27873         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
27874         (DISTCLEANFILES): Likewise.
27875         (EXTRA_DIST): Likewise.
27876         (all_local): Don't depend on stat.c or lstat.c.
27877         (stat.c, lstat.c): Remove rules.
27878         (EXTRA_DIST): Remove xstat.in.
27879
27880         * lib/xstat.in: Remove file.  Contents moved into stat.c.
27881         * lib/stat.c: New file.  Contents mostly from xstat.in.
27882         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
27883         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
27884
27885         * lib/safe-read.c: Rework so that it may serve to define safe_write,
27886         too.
27887         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
27888
27889 2002-12-03  Jim Meyering  <jim@meyering.net>
27890
27891         * lib/safe-read.c, safe-write.c: Change variable names and comments,
27892         but not semantics, to minimize the differences between these two files.
27893         (safe_read): Change comment to mention SAFE_READ_ERROR.
27894
27895         * lib/safe-read.c (IS_EINTR): Define.
27896         (safe_read): Use IS_EINTR in place of in-function cpp directives.
27897
27898 2002-12-02  Jim Meyering  <jim@meyering.net>
27899
27900         * lib/safe-read.c (EINTR): Define.
27901         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
27902         (INT_MAX): Provide fallback.
27903         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
27904
27905         * lib/safe-read.h (SAFE_READ_ERROR): Define.
27906
27907 2002-12-02  Bruno Haible  <bruno@clisp.org>
27908
27909         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
27910         Define, taken from safe-read.c.
27911         (INT_MAX): Provide fallback.
27912         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
27913         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
27914
27915         * lib/safe-read.c (EINTR): Remove definition.
27916         (safe_read): Don't use EINTR if it is absent.
27917
27918 2002-12-01  Jim Meyering  <jim@meyering.net>
27919
27920         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
27921         zero.
27922         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
27923
27924 2002-11-27  Paul Eggert  <eggert@twinsun.com>
27925
27926         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
27927         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
27928         with `if (! (value < limit)) abort ();', for readability.
27929
27930 2002-11-26  Karl Berry  <karl@gnu.org>
27931
27932         * lib/strdup.c: copy from libc again, with jim's ok.
27933         * lib/.cppi-disable: re-add strdup.c
27934
27935 2002-11-25  Karl Berry  <karl@gnu.org>
27936
27937         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
27938         instead of "strtol.c".
27939
27940 2002-11-25  Karl Berry  <karl@gnu.org>
27941
27942         * config/install-sh: update from automake for variable quoting, $0 in
27943         error msgs, etc.
27944
27945         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
27946         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
27947         entry.
27948
27949 2002-11-25  Jim Meyering  <jim@meyering.net>
27950
27951         * lib/mktime.c: Sync from libc, now that it has the latest fix.
27952
27953 2002-11-24  Karl Berry  <karl@gnu.org>
27954
27955         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
27956         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
27957
27958 2002-11-24  Jim Meyering  <jim@meyering.net>
27959
27960         Update from coreutils:
27961
27962         * lib/mktime.c: Merge in changes from libc.
27963
27964         Avoid a link-time failure on some Linux systems.
27965         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
27966         (otherwise).
27967         (__mon_yday): Declare with the STATIC attribute.
27968         (__mktime_internal): Likewise.
27969         Based on a report from Greg Schafer.
27970
27971 2002-11-23  Jim Meyering  <jim@meyering.net>
27972
27973         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
27974         Use `unsigned', not `int', as type of index.
27975
27976         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
27977
27978         * lib/fsusage.c: Remove unneeded parentheses around operands of
27979         `defined'.
27980
27981 2002-11-22  Paul Eggert  <eggert@twinsun.com>
27982
27983         * lib/quotearg.h: Allow multiple inclusion by surrounding with
27984         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
27985         so that we can be included first.
27986         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
27987         * lib/quotearg.c: Include quotearg.h immediately after config.h.
27988         No need to include stddef.h or sys/types.h any more.
27989         Surround local include files with "", not "<>".
27990         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
27991         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
27992         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
27993         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
27994         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
27995         (ISPRINT): Remove; no longer needed now that we assume C89.
27996
27997         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
27998         Preserve errno.
27999
28000         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
28001         quotearg_char): Use SIZE_MAX rather than
28002         (size_t) -1 when we are talking about "infinity".
28003
28004         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
28005
28006 2002-11-22  Paul Eggert  <eggert@twinsun.com>
28007
28008         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
28009         hint that one should use `if (! x) abort ();' rather than `assert
28010         (x);', and anyway it's one less thing to worry about configuring.
28011         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
28012         hash_rehash, hash_insert): Use abort rather than assert.
28013
28014 2002-11-22  Bruno Haible  <bruno@clisp.org>
28015
28016         * lib/safe-read.h: Assume C89. Add comments.
28017         (safe_read): Change return type to size_t.
28018         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
28019         byte counts > SSIZE_MAX correctly.
28020         * lib/safe-write.h: New file.
28021         * lib/safe-write.c: New file.
28022         * lib/full-read.h: New file.
28023         * lib/full-read.c: New file.
28024         * lib/full-write.h: Assume C89. Add comments.
28025         * lib/full-write.c: Include safe-write.h.
28026         (full_write): Rewritten to use safe_write.
28027         Suggested by Jim Meyering and Paul Eggert.
28028
28029 2002-11-21  Jim Meyering  <jim@meyering.net>
28030
28031         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
28032
28033         Merge in changes from the coreutils.
28034
28035         2002-09-25  Paul Eggert  <eggert@twinsun.com>
28036         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
28037         <stdint.h>.
28038         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
28039         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
28040         int.  Work more efficiently if X is the same width as uintmax_t.
28041         Do not compare X to -1, to avoid bogus compiler warning.
28042         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
28043         Don't assume that f_frsize and f_bsize are the same type.
28044
28045         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
28046         warning on FreeBSD.
28047
28048         * lib/makepath.c (make_path): Restore umask *before* creating the final
28049         component.
28050         (make_path): Minor reformatting.
28051
28052         * lib/xmalloc.c: Adjust to work with new autoconf macros,
28053         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
28054         HAVE_MALLOC/HAVE_REALLOC.
28055
28056         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
28057         dummy ones.  At least on GNU/Linux systems, `auto' means something
28058         else.
28059         From Michael Stone.
28060
28061 2002-11-21  Bruno Haible  <bruno@clisp.org>
28062
28063         Remove case insensitive option matching.
28064         * lib/argmatch.h (argcasematch): Remove declaration.
28065         (ARGCASEMATCH): Remove macro.
28066         (__xargmatch_internal): Remove case_sensitive argument.
28067         (XARGMATCH): Update.
28068         (XARGCASEMATCH): Remove macro.
28069         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
28070         case_sensitive argument.
28071         (argcasematch): Remove function.
28072         (__xargmatch_internal): Remove case_sensitive argument.
28073         (main): Use XARGMATCH instead of XARGCASEMATCH.
28074
28075         * lib/xmalloc.c: Change compile-time error message. Add comment about
28076         required autoconf version.
28077
28078 2002-11-20  Paul Eggert  <eggert@twinsun.com>
28079
28080         Merge argmatch cleanups from Bison.  Assume C89.
28081
28082         * lib/argmatch.c: Include config.h here, not in argmatch.h.
28083         Include stdlib.h, for EXIT_FAILURE.
28084         Always include <string.h>, since we assume C89.
28085         (EXIT_FAILURE): Remove pre-C89 bug workaround.
28086         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
28087         Include <stddef.h> instead, since it's all we need for size_t.
28088         (PARAMS): Remove.  All uses removed.
28089         (ARRAY_CARDINALITY): Do not bother to #undef.
28090         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
28091         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
28092         Remove unnecessary parentheses.
28093         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
28094         Insert necessary parentheses.
28095         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
28096         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
28097
28098 2002-11-19  Bruno Haible  <bruno@clisp.org>
28099
28100         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
28101         * lib/mbswidth.h: Include <stddef.h>, for size_t.
28102
28103         * lib/mbswidth.h (PARAMS): Remove macro.
28104         (mbswidth, mbsnwidth): Use ANSI C function declarations.
28105         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
28106
28107         * lib/gcd.h (PARAMS): Remove macro.
28108         (gcd): Use ANSI C function declarations.
28109         * lib/gcd.c (gcd): Likewise.
28110
28111 2002-11-15  Bruno Haible  <bruno@clisp.org>
28112
28113         * lib/strcspn.c: Include <stddef.h>.
28114         (strcspn): Use ANSI C function declaration. Change return type to
28115         size_t. Use NULL.
28116         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
28117         (strpbrk): Use NULL.
28118         * lib/strpbrk.h (PARAMS): Remove macro.
28119         (strpbrk): Use ANSI C function declaration.
28120         * lib/strstr.c: Don't include <sys/types.h>.
28121         * lib/strstr.h (PARAMS): Remove macro.
28122         (strstr): Use ANSI C function declarations.
28123
28124 2002-11-14  Karl Berry  <karl@gnu.org>
28125
28126         * config/mkinstalldirs: `do' on separate line, instead of
28127         `for var; do'.
28128
28129 2002-11-06  Bruno Haible  <bruno@clisp.org>
28130
28131         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
28132         * lib/gcd.c (gcd): Likewise.
28133
28134 2002-11-05  Bruno Haible  <bruno@clisp.org>
28135
28136         * lib/gcd.h: New file, from gettext-0.11.5.
28137         * lib/gcd.c: New file, from gettext-0.11.5.
28138
28139 2002-11-05  Bruno Haible  <bruno@clisp.org>
28140
28141         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28142         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28143         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28144         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28145
28146         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
28147         <libintl.h>.
28148         * lib/makepath.c: Include gettext.h instead of <locale.h> and
28149         <libintl.h>.
28150
28151         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
28152         * lib/human.c: Include gettext.h instead of <libintl.h>.
28153         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
28154         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
28155         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
28156         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
28157         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
28158         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
28159         (textdomain): Remove definition.
28160         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
28161
28162         * lib/long-options.c: Remove include of <libintl.h> and definition of
28163         _.
28164         * lib/same.c: Remove include of <libintl.h> and definition of _.
28165
28166 2002-11-04  Owen Taylor  <otaylor@redhat.com>
28167
28168         * lib/config.charset: A few additions for Solaris.
28169
28170 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
28171
28172         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
28173         * lib/localcharset.c (locale_charset): Declare as extern "C".
28174
28175 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
28176
28177         * lib/config.charset: msdos in uk_UA uses CP1125.
28178
28179 2002-11-04  Bruno Haible  <bruno@clisp.org>
28180
28181         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
28182         * lib/strcase.h: New file, from GNU gettext-0.11.5.
28183         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
28184         * lib/strstr.h: New file, from GNU gettext-0.11.5.
28185         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
28186
28187 2002-11-04  Bruno Haible  <bruno@clisp.org>
28188
28189         * lib/localcharset.c (locale_charset): Don't return an empty string.
28190
28191 2002-11-04  Bruno Haible  <bruno@clisp.org>
28192
28193         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
28194         aliases.
28195
28196 2002-11-04  Bruno Haible  <bruno@clisp.org>
28197
28198         * lib/config.charset: Update for newest glibc. Add canonical names
28199         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
28200
28201 2002-11-04  Bruno Haible  <bruno@clisp.org>
28202
28203         * lib/config.charset: Add support for NetBSD.
28204
28205 2002-11-04  Bruno Haible  <bruno@clisp.org>
28206
28207         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
28208
28209 2002-11-01  Bruno Haible  <bruno@clisp.org>
28210
28211         * configure.in: Add AC_CONFIG_AUX_DIR call.
28212         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
28213         test/Makefile.
28214         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
28215
28216 2002-09-28  Karl Berry  <karl@gnu.org>
28217
28218         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
28219         installed automake until the next release, since changes have been
28220         made.
28221
28222 2002-09-25  Karl Berry  <karl@gnu.org>
28223
28224         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
28225         * lib/getopt*: copy from libc/posix.
28226         * lib/gettext.h: copy from gettext.
28227         * lib/.cppi-disable: add strdup.c, gettext.h.
28228
28229 2002-09-25  Karl Berry  <karl@gnu.org>
28230
28231         * config/srclist.txt: enable gettext.h check.
28232         * config/config.{guess,sub}: update from prep.
28233         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
28234                 from automake 1.6.3.
28235         See srclist*.
28236
28237 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
28238
28239         * regex.c (PATFETCH): Remove the translating fetch.
28240         (PATFETCH_RAW): Rename to PATFETCH.
28241         (set_image_of_range): New fun.
28242         (SET_RANGE_TABLE_WORK_AREA): Use it.
28243         (regex_compile): Don't translate the pattern chars so eagerly.
28244         Only do it when inserting an `exactn' bytecode or when handling
28245         a char-range.
28246         (mutually_exclusive_p): Avoid empty statement.
28247
28248 2002-07-06  Jim Meyering  <meyering@lucent.com>
28249
28250         * m4/README: Don't mention Makefile.am.in.
28251         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
28252
28253 2002-07-01  Jim Meyering  <meyering@lucent.com>
28254
28255         * lib/c-stack.c: Include sys/time.h.
28256         From Volker Borchert.
28257
28258 2002-06-26  Paul Eggert  <eggert@twinsun.com>
28259
28260         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
28261
28262 2002-06-26  Paul Eggert  <eggert@twinsun.com>
28263
28264         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
28265         New macro.  Use it uniformly instead of
28266         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
28267         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
28268         reported by Vin Shelton.
28269
28270 2002-06-22  Paul Eggert  <eggert@twinsun.com>
28271
28272         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
28273         Do not assume SA_SIGINFO behavior.
28274         Bug reported by Jim Meyering on NetBSD 1.5.2.
28275
28276 2002-06-22  Jim Meyering  <meyering@lucent.com>
28277
28278         * m4/c-stack.m4: New file, from diffutils-2.8.2.
28279         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
28280
28281         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
28282         now that configure.ac uses AC_GNU_SOURCE.
28283         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
28284         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
28285
28286         Update to latest tools.  Suggestions from Paul Eggert.
28287         * m4/stdbool.m4: New file, from diffutils-2.8.2.
28288         * m4/gnu-source.m4: Update from diffutils-2.8.2.
28289         * m4/fnmatch.m4: Likewise.
28290         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
28291         to AC_HEADER_STDBOOL
28292
28293 2002-06-22  Jim Meyering  <meyering@lucent.com>
28294
28295         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
28296         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
28297
28298 2002-06-22  Jim Meyering  <meyering@lucent.com>
28299
28300         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
28301
28302         * lib/exitfail.c, exitfail.h: Likewise.
28303         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
28304
28305         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
28306         of fnmatch.h.
28307         (EXTRA_DIST): Add fnmatch_loop.c.
28308         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
28309
28310         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
28311         * lib/fnmatch.c: Update from diffutils-2.8.2.
28312         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
28313         * lib/fnmatch.h: Remove file.
28314
28315 2002-06-21  Jim Meyering  <meyering@lucent.com>
28316
28317         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
28318         * m4/mbrtowc.m4: Likewise.
28319
28320         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
28321         * m4/mbswidth.m4: Reflect name change:
28322         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
28323         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
28324
28325         * m4/lib-link.m4: Update from gettext-0.11.2.
28326         * m4/gettext.m4: Likewise.
28327
28328         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
28329         From Alfred M. Szmidt.
28330
28331 2002-06-18  Paul Eggert  <eggert@twinsun.com>
28332
28333         * lib/file-type.h: Report an error if neither S_ISREG nor
28334         S_IFREG is defined, instead of using a test specific to glibc
28335         2.2.  This should be safe, since POSIX requires S_ISREG and
28336         Unix Version 7 had S_IFREG.  We don't need to check for
28337         <sys/types.h> since we don't use any symbols that it defines.
28338
28339 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
28340
28341         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
28342         $@-t, so that each temporary file name is unique and valid in the first
28343         8 characters, for operation under DOS.
28344
28345 2002-06-15  Paul Eggert  <eggert@twinsun.com>
28346
28347         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
28348
28349 2002-06-15  Jim Meyering  <meyering@lucent.com>
28350
28351         Work even with DJGPP 2.03, which lacks support for symlinks.
28352         From Richard Dawe.
28353         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
28354         is defined.
28355         * lib/lchown.c (S_ISLNK): Likewise.
28356
28357 2002-06-15  Jim Meyering  <meyering@lucent.com>
28358
28359         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
28360         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
28361         have been included before this file.
28362
28363 2002-06-14  Jim Meyering  <meyering@lucent.com>
28364
28365         * lib/file-type.h: Use the version from diffutils-2.8.2.
28366         * lib/file-type.c: Likewise.
28367
28368 2002-06-07  Jim Meyering  <meyering@lucent.com>
28369
28370         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
28371         They're needed at least for NetBSD 1.5.2.
28372         ($statxfs_includes): Include those same headers.
28373         ($statxfs_includes): Include sys/vfs.h if available.
28374         ($statxfs_includes): Likewise for sys/statvfs.h.
28375         Check for the following members in both structs statfs and statvfs:
28376         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
28377
28378 2002-06-01  Jim Meyering  <meyering@lucent.com>
28379
28380         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
28381         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
28382
28383 2002-05-28  Jim Meyering  <meyering@lucent.com>
28384
28385         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
28386         Reported by Volker Borchert.
28387
28388 2002-05-27  Jim Meyering  <meyering@lucent.com>
28389
28390         Fix a problem seen only on nonconforming systems whereby ls.c's
28391         use of localtime, and then of gettimeofday would cause trouble:
28392         the localtime call used to initialize rpl_gettimeofday's save
28393         mechanism would clobber ls's current local time information so
28394         that in any long listing the first file would always be listed
28395         with date 1970-01-01.  Analysis by Volker Borchert.
28396
28397         * lib/gettimeofday.c (localtime): Undefine.
28398         (rpl_localtime): New function.
28399
28400 2002-05-27  Jim Meyering  <meyering@lucent.com>
28401
28402         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
28403         localtime.
28404
28405         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
28406         use the replacement function; it wouldn't resolve at link time.
28407         Reported by Volker Borchert.
28408
28409 2002-05-22  Jim Meyering  <meyering@lucent.com>
28410
28411         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
28412         file-type.h.
28413         * lib/file-type.h: New file.
28414         * lib/file-type.c (file_type): New file/function.  Extracted from
28415         diffutils.
28416
28417 2002-04-30  Jim Meyering  <meyering@lucent.com>
28418
28419         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
28420
28421 2002-04-29  Paul Eggert  <eggert@twinsun.com>
28422
28423         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
28424
28425 2002-04-29  Paul Eggert  <eggert@twinsun.com>
28426
28427         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
28428         Do not check for alloca.h (no longer used) or stdbool.h (was never
28429         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
28430
28431 2002-04-29  Paul Eggert  <eggert@twinsun.com>
28432
28433         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
28434
28435 2002-04-29  Jim Meyering  <meyering@lucent.com>
28436
28437         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
28438         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
28439         Use AC_FUNC_STRNLEN here instead.
28440
28441         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
28442         With autoconf-2.53a, it's part of AC_PROG_CC.
28443
28444 2002-04-28  Paul Eggert  <eggert@twinsun.com>
28445
28446         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
28447         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
28448
28449 2002-04-28  Paul Eggert  <eggert@twinsun.com>
28450
28451         * lib/sig2str.h, lib/sig2str.c: New files.
28452         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
28453
28454 2002-04-28  Paul Eggert  <eggert@twinsun.com>
28455
28456         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
28457         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
28458         of 127, since 64 is the largest conceivable number for ancient
28459         nonstandard hosts.
28460         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
28461
28462 2002-04-28  Jim Meyering  <meyering@lucent.com>
28463
28464         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
28465
28466 2002-04-24  Jim Meyering  <meyering@lucent.com>
28467
28468         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
28469         (jm_PREREQ): Use it.
28470
28471         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
28472         mach/mach.h fcntl.h.
28473         Check for this function: setlocale.
28474
28475 2002-04-24  Jim Meyering  <meyering@lucent.com>
28476
28477         * lib/gettext.h: New file, from Gettext.
28478         * lib/Makefile.am (INCLUDES): Remove -I../intl.
28479         (libfetish_a_SOURCES): Add gettext.h.
28480
28481 2002-04-16  Jim Meyering  <meyering@lucent.com>
28482
28483         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
28484         ut_pid, ut_id, ut_exit.
28485
28486 2002-04-16  Jim Meyering  <meyering@lucent.com>
28487
28488         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
28489         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
28490         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
28491
28492 2002-04-12  Jim Meyering  <meyering@lucent.com>
28493
28494         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
28495         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
28496         existence of the getmntinfo function.  Needed for Darwin 5.3.
28497
28498         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
28499         This is necessary at least on Darwin 5.3.
28500
28501         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
28502         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
28503         strnlen.o in the library, and that makes some versions of ranlib
28504         object.
28505
28506 2002-04-12  Jim Meyering  <meyering@lucent.com>
28507
28508         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
28509
28510 2002-04-09  Jim Meyering  <meyering@lucent.com>
28511
28512         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
28513         to be more precise.  Rather than saying we're checking whether the
28514         function `works', say what we're testing.
28515         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
28516         Reported by Bruno Haible.
28517
28518 2002-03-10  Jim Meyering  <meyering@lucent.com>
28519
28520         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
28521         Suggestion from Santiago Vila.
28522
28523 2002-03-08  Jim Meyering  <meyering@lucent.com>
28524
28525         * lib/rename.c: Mention that this wrapper is needed also on
28526         mips-dec-ultrix4.4 systems.
28527
28528 2002-03-02  Jim Meyering  <meyering@lucent.com>
28529
28530         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
28531         not HAVE_CLOCK_SETTIME.
28532
28533 2002-02-27  Paul Eggert  <eggert@twinsun.com>
28534
28535         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
28536         Check for clock_settime.
28537
28538 2002-02-27  Paul Eggert  <eggert@twinsun.com>
28539
28540         * lib/nanosleep.h: Rename to....
28541         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
28542
28543         * lib/gettime.c: New file.
28544         * lib/settime.c: New file.
28545         * lib/stime.c: Remove.
28546
28547         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
28548         timespec.h.  Remove nanosleep.h.
28549
28550 2002-02-25  Paul Eggert  <eggert@twinsun.com>
28551
28552         * m4/acl.m4: New file.
28553         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
28554         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
28555
28556 2002-02-25  Paul Eggert  <eggert@twinsun.com>
28557
28558         * lib/acl.c, lib/acl.h: New files.
28559         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
28560
28561 2002-02-24  Jim Meyering  <meyering@lucent.com>
28562
28563         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
28564         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
28565         cause trouble.  Reported by Nelson Beebe.
28566
28567 2002-02-23  Paul Eggert  <eggert@twinsun.com>
28568
28569         * lib/path-concat.c (xpath_concat): Reorder code to pacify
28570         compilers that don't know that xalloc_die never returns.
28571
28572 2002-02-20  Jim Meyering  <meyering@lucent.com>
28573
28574         * lib/getdate.c: Regenerate using bison-1.33.
28575
28576 2002-02-17  Jim Meyering  <meyering@lucent.com>
28577
28578         * config/config.guess (main): Don't use `head -1'; it's no longer
28579         portable. Use `sed 1q' instead.
28580
28581 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
28582
28583         * m4/codeset.m4: Upgrade to gettext-0.11.
28584         * m4/gettext.m4: Upgrade to gettext-0.11.
28585         * m4/glibc21.m4: Upgrade to gettext-0.11.
28586         * m4/iconv.m4: Upgrade to gettext-0.11.
28587         * m4/isc-posix.m4: Upgrade to gettext-0.11.
28588         * m4/lcmessage.m4: Upgrade to gettext-0.11.
28589         * m4/lib-ld.m4: New file, from gettext-0.11.
28590         * m4/lib-link.m4: New file, from gettext-0.11.
28591         * m4/lib-prefix.m4: New file, from gettext-0.11.
28592         * m4/progtest.m4: Upgrade to gettext-0.11.
28593
28594 2002-02-15  Paul Eggert  <eggert@twinsun.com>
28595
28596         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
28597         (jm_PREREQ): Use it.
28598
28599 2002-02-15  Paul Eggert  <eggert@twinsun.com>
28600
28601         * lib/posixver.c, lib/posixver.h: New files.
28602         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
28603
28604 2002-02-02  Paul Eggert  <eggert@twinsun.com>
28605             Bruno Haible  <bruno@clisp.org>
28606
28607         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
28608         (fwrite_success_callback): New declaration.
28609         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
28610         print_unicode_char. Call failure callback instead of error.
28611         (fwrite_success_callback): New function.
28612         (exit_failure_callback): New function.
28613         (fallback_failure_callback): New function.
28614         (print_unicode_char): Call unicode_to_mb.
28615
28616 2002-01-26  Jim Meyering  <meyering@lucent.com>
28617
28618         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
28619         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
28620
28621 2002-01-26  Jim Meyering  <meyering@lucent.com>
28622
28623         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
28624
28625 2002-01-22  Paul Eggert  <eggert@twinsun.com>
28626
28627         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
28628
28629 2002-01-22  Jim Meyering  <meyering@lucent.com>
28630
28631         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
28632         Otherwise, some versions of automake would omit the rule that makes
28633         Makefile from Makefile.in.
28634
28635 2002-01-21  Paul Eggert  <eggert@twinsun.com>
28636
28637         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
28638         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
28639         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
28640         (memcoll): Set errno to zero if there is no error.
28641
28642         * lib/quotearg.c (quotearg_buffer_restyled):
28643         Fix bug with quoting buffers containing NUL when backslashing escapes.
28644         This bug was exposed by the other changes in this patch.
28645         (quotearg_n_options): New arg ARGSIZE.
28646         All callers changed.
28647         (quoting_options_from_style): New function.
28648         (quotearg_n_style): Use it.
28649         (quotearg_n_style_mem): New function.
28650
28651         * lib/quotearg.h (quotearg_n_style_mem): New function.
28652
28653 2002-01-19  Jim Meyering  <meyering@lucent.com>
28654
28655         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
28656         Remove useless quotes: DF_PROG="df".
28657         * m4/strnlen.m4: New file.
28658
28659 2002-01-16  Paul Eggert  <eggert@twinsun.com>
28660
28661         * lib/backupfile.c (ISDIGIT): Comment fix.
28662         * lib/getdate.y (ISDIGIT): Likewise.
28663         * lib/posixtm.c (ISDIGIT, year): Likewise.
28664         * lib/strverscmp.c (ISDIGIT): Likewise.
28665         * lib/userspec.c (ISDIGIT): Likewise.
28666
28667 2002-01-16  Jim Meyering  <meyering@lucent.com>
28668
28669         * lib/getdate.y: Add three semicolons, each just before a closing
28670         brace. Bison (as of version 1.31) no longer papers over that mistake.
28671
28672 2002-01-05  Jim Meyering  <meyering@lucent.com>
28673
28674         * lib/version-etc.c (version_etc_copyright): Update copyright year.
28675
28676 2001-12-19  Paul Eggert  <eggert@twinsun.com>
28677
28678         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
28679         not silently exit merely because the output buffer happens to
28680         have nothing pending.
28681
28682 2001-12-18  Paul Eggert  <eggert@twinsun.com>
28683
28684         See the big note in ../ChangeLog.
28685         * lib/human.c (suffixes): Prefer K to k for 1024.
28686         (generate_suffix_backwards): New function.
28687         (human_readable_inexact): Use it.
28688         * lib/xstrtol.c (__xstrtol): If there is no number but there
28689         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
28690         Accept 'K' as well as 'k'.
28691
28692 2001-12-15  Jim Meyering  <meyering@lucent.com>
28693
28694         * lib/regex.h (__restrict_arr): Update from libc.
28695
28696         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
28697         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
28698         (STREQ): Define.
28699
28700 2001-12-14  Jim Meyering  <meyering@lucent.com>
28701
28702         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
28703         Suggestion from Bruno Haible.
28704
28705 2001-12-10  Jim Meyering  <meyering@lucent.com>
28706
28707         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
28708         xrealloc, Instead, include "xalloc.h".
28709         (initbuffer): Don't cast xmalloc return value to char*.
28710         (readline): Reword comment.
28711         Don't cast xrealloc return value to char*
28712         Return NULL, not 0.
28713
28714 2001-12-09  Jim Meyering  <meyering@lucent.com>
28715
28716         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
28717         about `signed and unsigned type in conditional expression'.
28718         * lib/posixtm.c (posix_time_parse): Likewise.
28719
28720         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
28721
28722         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
28723         to avoid a pedantic warning.
28724
28725         * lib/getstr.c: Don't include assert.h.
28726         (getstr): Remove warning-evoking assertions.
28727         Return -1 if offset parameter is out of bounds.
28728         Change the type of a local from int to size_t.
28729
28730         * lib/strftime.c (my_strftime_localtime_r): Include this function
28731         definition in the `#if ! HAVE_TM_GMTOFF' block.
28732
28733         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
28734         Include xalloc.h instead.
28735
28736 2001-12-02  Jim Meyering  <meyering@lucent.com>
28737
28738         * lib/tempname.c: Don't declare getenv, thus reverting the change of
28739         2001-11-18.  It's no longer necessary, now that stdlib.h is always
28740         included.
28741
28742         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
28743         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
28744
28745 2001-11-30  Akim Demaille  <akim@epita.fr>
28746
28747         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
28748         before being defined.
28749
28750 2001-11-27  Paul Eggert  <eggert@twinsun.com>
28751
28752         * lib/quotearg.h (quotearg_n, quotearg_n_style):
28753         First arg is int, not unsigned.
28754         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
28755         (SIZE_MAX, UINT_MAX): New macros.
28756         (quotearg_n_options): Abort if N is negative.
28757         Avoid overflow check on hosts where size_t is 64 bits and int
28758         is 32 bits, as overflow is impossible there.
28759         Fix off-by-one typo that caused unnecessary reallocation.
28760
28761 2001-11-27  Jim Meyering  <meyering@lucent.com>
28762
28763         * lib/tempname.c: Merge with version from libc.
28764         * lib/regex.c: Likewise.
28765
28766         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
28767         systems for which STDC_HEADERS is 0, it was not included, resulting in
28768         a warning about an integer-to-pointer conversion problem with getenv.
28769         Reported by Volker Borchert.
28770
28771 2001-11-26  Jim Meyering  <meyering@lucent.com>
28772
28773         * lib/gtod.h: Remove file.
28774         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
28775         * lib/gettimeofday.c: Don't include gtod.h.
28776         (GTOD_init): Remove function.
28777         (rpl_gettimeofday): Do its job here instead, rather than aborting.
28778         Suggestion from Volker Borchert.
28779
28780 2001-11-23  Jim Meyering  <meyering@lucent.com>
28781
28782         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
28783         it.
28784         * lib/hash.c (struct hash_table): Define it here instead.
28785
28786 2001-11-22  Jim Meyering  <meyering@lucent.com>
28787
28788         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
28789
28790 2001-11-20  Jim Meyering  <meyering@lucent.com>
28791
28792         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
28793         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
28794
28795 2001-11-19  Jim Meyering  <meyering@lucent.com>
28796
28797         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
28798         directory.  Use "conftestXXXXXX" as the template.
28799         Suggestion from Paul Eggert.
28800
28801         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
28802         immediately, so the test doesn't mistakenly hit the max-open-files
28803         limit.
28804
28805 2001-11-18  Paul Eggert  <eggert@twinsun.com>
28806
28807         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
28808         (TEMPORARIES): New macro.
28809         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
28810         removes an artificial limitation (e.g. HP-UX 10.20, where
28811         TMP_MAX is 17576).
28812
28813 2001-11-18  Jim Meyering  <meyering@lucent.com>
28814
28815         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
28816
28817 2001-11-18  Jim Meyering  <meyering@lucent.com>
28818
28819         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
28820         on SunOS 4.
28821
28822         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
28823         files will be created before anything else.
28824
28825 2001-11-17  Paul Eggert  <eggert@twinsun.com>
28826
28827         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
28828         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
28829
28830 2001-11-17  Jim Meyering  <meyering@lucent.com>
28831
28832         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
28833         Prompted by a report from Bob Proulx.
28834
28835         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
28836         Instead, require UTILS_FUNC_MKSTEMP.
28837
28838 2001-11-17  Jim Meyering  <meyering@lucent.com>
28839
28840         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
28841         Now, that's done as part of AC_FUNC_STRTOD.
28842
28843 2001-11-17  Jim Meyering  <meyering@lucent.com>
28844
28845         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
28846         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
28847         rather than group writable.  Patch by Juan F. Codagnone.
28848
28849         * lib/readtokens.c: Remove explicit declarations of xmalloc and
28850         xrealloc, Instead, include "xalloc.h".
28851
28852         * lib/mountlist.c: Include unlocked-io.h after all system headers.
28853         Remove explicit declarations of xmalloc, xrealloc,
28854         and xstrdup.  Instead, include "xalloc.h".
28855
28856         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
28857         unlocked-io.h.
28858         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
28859         Likewise.
28860         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
28861
28862         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
28863         Reported by Padraig Brady.
28864
28865         * lib/mkstemp.c: #undef mkstemp.
28866         Include config.h.
28867         (rpl_mkstemp): Rename from mkstemp.
28868         Protoize.
28869
28870 2001-11-16  Jim Meyering  <meyering@lucent.com>
28871
28872         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
28873         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
28874         determine the amount of total physical memory, use pstat_getstatic.
28875         HPUX-11 doesn't define _SC_PHYS_PAGES.
28876         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
28877         If sysconf couldn't be used to determine the amount of available
28878         physical memory, use both pstat_getstatic and pstat_getdynamic.
28879         Based on a patch from Bob Proulx.
28880
28881 2001-11-10  Jim Meyering  <meyering@lucent.com>
28882
28883         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
28884         (jm_PREREQ): Use it.
28885
28886 2001-11-09  Jim Meyering  <meyering@lucent.com>
28887
28888         * m4/jm-macros.m4: Require autoconf-2.52f.
28889         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
28890         Use these AC_-prefixed names, not the AM_-prefixed ones.
28891
28892         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
28893
28894 2001-11-05  Jim Meyering  <meyering@lucent.com>
28895
28896         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
28897
28898 2001-11-04  Jim Meyering  <meyering@lucent.com>
28899
28900         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
28901         $DEFS.
28902
28903 2001-11-03  Jim Meyering  <meyering@lucent.com>
28904
28905         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
28906         of AC_DEFUN.
28907
28908         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
28909         know the name of the variable in the macro definition.
28910
28911 2001-11-03  Jim Meyering  <meyering@lucent.com>
28912
28913         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
28914         in argmatch_to_argument call.
28915
28916         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
28917         argument.
28918
28919         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
28920         e.g., a fault due to an attempt to free a NULL pointer.
28921
28922 2001-11-01  Jim Meyering  <meyering@lucent.com>
28923
28924         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
28925         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
28926
28927 2001-11-01  Jim Meyering  <meyering@lucent.com>
28928
28929         * lib/dirfd.c, lib/dirfd.h: New files.
28930         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
28931
28932         * lib/hash.c (hash_print) [TESTING]: Clean up.
28933
28934 2001-10-22  Paul Eggert  <eggert@twinsun.com>
28935
28936         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
28937         to avoid a warning if -Wall.
28938
28939 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
28940
28941         * README: New file
28942         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
28943         (per RMS's instructions, this is now the canonical source)
28944         * lgpl/, gpl/: New directories.
28945
28946 2001-10-21  Paul Eggert  <eggert@twinsun.com>
28947
28948         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
28949
28950 2001-10-21  Jim Meyering  <meyering@lucent.com>
28951
28952         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
28953         this code would end up calling gettext even in packages built
28954         with --disable-nls.
28955         * lib/getopt.c (_): Likewise.
28956         * lib/regex.c (_): Likewise.
28957
28958 2001-10-20  Paul Eggert  <eggert@twinsun.com>
28959
28960         * m4/error.m4 (jm_PREREQ_ERROR):
28961         Do not invoke AC_CHECK_FUNCS with strerror_r, as
28962         AC_FUNC_STRERROR_R does that.
28963         Check for strerror declaration.
28964
28965         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
28966         are supposed to have them these days.
28967         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
28968         Merge changes from latest Autoconf CVS.
28969         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
28970         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
28971         POSIX decided to standardize on the int flavor of strerror_r.
28972
28973 2001-10-20  Paul Eggert  <eggert@twinsun.com>
28974
28975         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
28976         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
28977         Use strerror_r that is only a macro, even if it is not a function.
28978         (strerror): Check for HAVE_DECL_STRERROR before declaring.
28979         (private_strerror): Use prototypes, not old-style function definition.
28980         (print_errno_message): New function.
28981         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
28982         char*-flavored one.
28983         (error_tail, error, error_at_line): Use it.
28984
28985 2001-10-11  Jim Meyering  <meyering@lucent.com>
28986
28987         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
28988         and quote_n (1, ... to avoid clobbering a buffer.
28989
28990 2001-10-05  Jim Meyering  <meyering@lucent.com>
28991
28992         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
28993         hash-pjw.h.
28994         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
28995         * lib/hash-pjw.h: New file.
28996
28997 2001-09-30  Jim Meyering  <meyering@lucent.com>
28998
28999         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
29000         `struct fsstat' has the `f_fstypename' member.
29001         Use that to define FS_TYPE, which is now used to make
29002         the getfsstat link test tighter.
29003
29004 2001-09-30  Jim Meyering  <meyering@lucent.com>
29005
29006         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
29007         Include <sys/ucred.h>, for Apple Darwin.
29008         Include sys/mount.h and sys/fs_types.h only if available.
29009         (FS_TYPE): Define.
29010         (read_filesystem_list): Use FS_TYPE.
29011
29012 2001-09-29  Paul Eggert  <eggert@twinsun.com>
29013
29014         * lib/exclude.c (excluded_filename): 0 -> false, since it's
29015         a boolean context.
29016
29017 2001-09-29  Jim Meyering  <meyering@lucent.com>
29018
29019         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
29020         [one-argument getmntent function]): Include stdio.h before mntent.h.
29021         SunOS 4.1.x needs it for the declaration of `FILE'.
29022         Patch by Volker Borchert.
29023
29024         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
29025         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
29026         sys/fs_types.h, and make the link-test for getfsstat guard #include
29027         directives with appropriate #if HAVE_*_H tests so that we can
29028         detect getfsstat on Apple Darwin1.3.7 systems.
29029         Reported by Nelson Beebe.
29030         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
29031
29032 2001-09-28  Paul Eggert  <eggert@twinsun.com>
29033
29034         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
29035         #defines strtoimax.  Also treat the other strto* functions
29036         like strtoimax.
29037
29038         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
29039         Check for strtoul and strtoumax,
29040         as those declarations are made even in the signed case.
29041         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
29042         Likewise, for strtol and strtoimax.
29043
29044 2001-09-28  Paul Eggert  <eggert@twinsun.com>
29045
29046         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
29047         #defines strtoimax.  Also treat the other strto* functions
29048         like strtoimax.
29049
29050         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
29051         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
29052         (strtoimax, strtoumax): Do not declare if already defined as a macro.
29053
29054 2001-09-26  Jim Meyering  <meyering@lucent.com>
29055
29056         Most macros in unlocked-io.h had the wrong number of arguments.
29057         * lib/gen-uio: New script.
29058         (USE_UNLOCKED_IO): Define to 1 if not already defined.
29059         * lib/unlocked-io.hin: Remove file.
29060         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
29061         rather than trying to embed it here.
29062         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
29063         Reported by Padraig Brady.
29064
29065 2001-09-25  Volker Borchert  <bt@teknon.de>
29066
29067         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
29068         `result'.
29069
29070 2001-09-24  Jim Meyering  <meyering@lucent.com>
29071
29072         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
29073
29074 2001-09-23  Jim Meyering  <meyering@lucent.com>
29075
29076         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
29077         instead of the mere test for existence of mntent.h.  The latter
29078         would get a false-positive on AIX 3.4 systems.
29079         In the outer getmntent if-block, don't die if neither of the getmntent
29080         tests succeeds.  Instead, just fall through and continue with the
29081         remaining tests.
29082
29083 2001-09-23  Jim Meyering  <meyering@lucent.com>
29084
29085         * lib/mountlist.c: Remove useless parentheses in #if directives.
29086         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
29087         the deprecated MOUNTED symbol is no longer defined in mntent.h.
29088
29089 2001-09-22  Jim Meyering  <meyering@lucent.com>
29090
29091         * m4/gettext.m4: New file.  From gettext.
29092         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
29093         * m4/progtest.m4: Likewise
29094         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
29095         * m4/glibc21.m4: Likewise.
29096
29097         * m4/libintl.m4: Remove.  No longer used.
29098
29099 2001-09-22  Jim Meyering  <meyering@lucent.com>
29100
29101         * lib/localcharset.c: Update from latest gettext.
29102         * lib/config.charset: Likewise.
29103
29104 2001-09-20  Jim Meyering  <meyering@lucent.com>
29105
29106         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
29107         strtoimax.
29108         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
29109         strtoumax.
29110
29111 2001-09-20  Jim Meyering  <meyering@lucent.com>
29112
29113         * lib/xstrtol.c (strtoimax): Guard declaration with
29114         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
29115         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
29116         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
29117         (strtoumax): Likewise, for completeness (it wasn't necessary).
29118
29119 2001-09-17  Paul Eggert  <eggert@twinsun.com>
29120
29121         * lib/strtoimax.c (HAVE_LONG_LONG):
29122         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
29123         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
29124         to work around bug in IBM C compiler.
29125
29126 2001-09-17  Jim Meyering  <meyering@lucent.com>
29127
29128         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
29129         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
29130         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
29131         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
29132         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
29133         whenever the right hand side need not be expanded by the shell.
29134
29135 2001-09-16  Paul Eggert  <eggert@twinsun.com>
29136
29137         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
29138         library.  It's not correct, as some older glibcs are buggy.
29139         fnmatch wasn't fixed until glibc 2.2.
29140
29141         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
29142         special shell magic here.
29143
29144 2001-09-16  Jim Meyering  <meyering@lucent.com>
29145
29146         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
29147         * m4/jm-macros.m4: Require it.
29148
29149 2001-09-16  Jim Meyering  <meyering@lucent.com>
29150
29151         * lib/mkdir.c: New file.
29152
29153 2001-09-15  Jim Meyering  <meyering@lucent.com>
29154
29155         * m4/jm-macros.m4: Check for help2man.
29156
29157 2001-09-11  Jim Meyering  <meyering@lucent.com>
29158
29159         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
29160         The body, by Paul Eggert, was moved here from configure.in.
29161         * m4/jm-macros.m4: Require UTILS_HOST_OS.
29162
29163 2001-09-04  Paul Eggert  <eggert@twinsun.com>
29164
29165         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
29166         (jm_PREREQ): Use it.
29167
29168 2001-09-04  Paul Eggert  <eggert@twinsun.com>
29169
29170         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
29171         Use ssize_t, not int, to store result of readlink.
29172         Check for ssize_t overflow as well as size_t overflow,
29173         as POSIX says the result of readlink is implementation-defined
29174         when ssize_t overflows.
29175         Remove unnecessary cast to char*.
29176         Use free+malloc instead of realloc, as the storage doesn't need
29177         to be preserved and it's clearer and can be more efficient that way.
29178         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
29179         * lib/xreadlink.h (xreadlink): Update prototype.
29180
29181 2001-09-04  Paul Eggert  <eggert@twinsun.com>
29182
29183         * lib/xgetcwd.c: Revert some of the previous change; intead,
29184         fix the HAVE_GETCWD_NULL code to behave more like the
29185         !HAVE_GETCWD_NULL code used to.
29186
29187         Include "xalloc.h".
29188         (xgetcwd): Do not return NULL when memory is exhausted; instead,
29189         invoke xalloc_die.
29190
29191 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29192
29193         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
29194         sys/param.h, as pathmax.h includes them.
29195
29196 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29197
29198         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
29199         (jm_PREREQ_XGETCWD): New macro.
29200
29201         * m4/getcwd.m4: New file.
29202
29203 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29204
29205         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
29206         like the HAVE_GETCWD_NULL code.
29207         Include pathmax.h if not HAVE_GETCWD.
29208         Do not include xalloc.h.
29209         (INITIAL_BUFFER_SIZE): New symbol.
29210         Do not use xmalloc / xrealloc, since the caller is responsible for
29211         handling errors.  Preserve errno around `free' during failure.
29212         Do not overrun buffer when using getwd.
29213
29214 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29215
29216         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
29217         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
29218         getcwd (NULL, 0).
29219
29220 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29221
29222         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
29223         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
29224         spotted by Jim Meyering.
29225
29226 2001-09-03  Jim Meyering  <meyering@lucent.com>
29227
29228         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
29229         failure.
29230
29231 2001-09-02  Jim Meyering  <meyering@lucent.com>
29232
29233         * lib/error.c: Update from GNU libc.
29234
29235 2001-09-01  Jim Meyering  <meyering@lucent.com>
29236
29237         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
29238         Used by df.
29239
29240 2001-09-01  Jim Meyering  <meyering@lucent.com>
29241
29242         * lib/xreadlink.c: New file.
29243         * lib/xreadlink.h: New file.
29244         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
29245         xreadlink.h.
29246
29247         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
29248         doesn't conflict with sparc Solaris 7's definition in
29249         /usr/include/sys/int_types.h.
29250
29251         * lib/exclude.c: Use `""', not `<>' to #include non-system header
29252         files.
29253         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
29254         and strncasecmp as r-values.  Unixware didn't have declarations.
29255
29256 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29257
29258         * lib/xstrtol.h: Add copyright notice.
29259         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
29260         LONGINT_INVALID_SUFFIX_CHAR.
29261
29262 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29263
29264         * lib/xstrtol.c (strtoimax): New decl.
29265
29266 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29267
29268         * lib/xgetcwd.c: Don't include pathmax.h.
29269         Include stdlib.h and unistd.h if available.
29270         Include xalloc.h.
29271         (xmalloc, xstrdup, free): Remove decls.
29272         (xgetcwd): Don't assume sizes fit in unsigned.
29273         Check for overflow when computing sizes.
29274         Simplify reallocation code.
29275
29276 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29277
29278         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
29279         a directory's st_size can have an arbitrary value, so the old
29280         usage could waste an arbitrary amount of memory.  All uses
29281         changed.
29282         * lib/savedir.h: Update prototype.
29283
29284 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29285
29286         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
29287
29288         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
29289         old strtoimax.c.
29290
29291         Also, make the following further changes to make this file's
29292         configuration more similar to that of strtol.c:
29293         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
29294         (strtoumax, uintmax_t, strtoull, strtol): Remove.
29295         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
29296         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
29297         changed to signed values.
29298
29299         And make the following changes as well:
29300         Fix copyright notice, as 1999 was missing.
29301         (verify): New macro.
29302         (strtoimax): Check sizes at compile-time, not run-time.
29303         Prefer strtol to strtoll if both work.
29304         (main): Remove; it was not that useful and was a pain to maintain.
29305
29306         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
29307
29308 2001-08-31  Jim Meyering  <meyering@lucent.com>
29309
29310         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
29311         Use an initial, malloc'd, buffer of length 128 rather than
29312         a statically allocated one of length 1024.
29313
29314 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29315
29316         Simplify code, partly by assuming autoconf 2.52 semantics.
29317
29318         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
29319
29320         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
29321         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
29322         All uses removed.
29323         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
29324         Move AC_REQUIRE to next-to-top level, to avoid confusion.
29325         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
29326         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
29327         jm_AC_HEADER_INTTYPES_H.
29328         * m4/jm-macros.m4 (jm_MACROS): Likewise.
29329
29330         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
29331
29332         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
29333         Quote first arg of AC_DEFUN.
29334         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
29335         since they are needed to parse the include file even if we need
29336         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
29337         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
29338         but with opposite signedness.
29339
29340 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29341
29342         Merge 'exclude' changes from tar 1.13.22.
29343         This fixes one or two unlikely storage allocation overflow bugs,
29344         but doesn't change user-visible behavior otherwise.
29345
29346 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29347
29348         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
29349         (jm_PREREQ_EXCLUDE): New macro.
29350
29351 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29352
29353         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
29354         tm to be declared.
29355
29356 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29357
29358         * lib/hash.c: Remove '2001' from copyright notice.
29359
29360 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29361
29362         * lib/full-write.h: New file.
29363         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
29364         * lib/full-write.c: Correct credits, as cccp.c no longer
29365         exists and anyway it was so heavily changed from the old cccp
29366         code as to be unrecognizable.  Include full-write.h.
29367         (full_write) Return size_t, with short writes meaning failure.
29368         All callers changed.  This fixes a bug with large buffers
29369         on 64-bit hosts.
29370         * lib/utime.c: Include full-write.h.
29371
29372 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29373
29374         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
29375         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
29376         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
29377         Include if available.
29378         (<xalloc.h>): Include
29379         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
29380         (verify): New macro.  Use it to verify that EXCLUDE macros do not
29381         collide with FNM macros.
29382         (struct patopts): New struct.
29383         (struct exclude): Use it, as exclude patterns now come with options.
29384         (new_exclude): Support above changes.
29385         (new_exclude, add_exclude_file):
29386         Initial size must now be a power of two to simplify overflow checking.
29387         (free_exclude, fnmatch_no_wildcards): New function.
29388         (excluded_filename): No longer requires options arg, as the options
29389         are determined by add_exclude.  Now returns bool, not int.
29390         (excluded_filename, add_exclude):
29391         Add support for the fancy new exclusion options.
29392         (add_exclude, add_exclude_file): Now takes int options arg.
29393         Check for arithmetic overflow when computing sizes.
29394         (add_exclude_file): xrealloc might modify errno, so don't
29395         realloc until after errno might be used.
29396
29397         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
29398         New macros.
29399         (free_exclude): New decl.
29400         (add_exclude, add_exclude_file): Now takes int options arg.
29401         (excluded_filename): No longer requires options arg, as the options
29402         are determined by add_exclude.  Now returns bool, not int.
29403
29404 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29405
29406         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
29407
29408 2001-08-27  Jim Meyering  <meyering@lucent.com>
29409
29410         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
29411
29412         * lib/version-etc.c (N_): Remove definition.
29413         Revert most of last change.
29414         Instead, simply don't mark the `Copyright...' string for translation.
29415         Based on advice from Paul Eggert.
29416
29417         * lib/strtoxmax.c: Tweak comment.
29418
29419 2001-08-26  Jim Meyering  <meyering@lucent.com>
29420
29421         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
29422
29423         * m4/xstrtoimax.m4: New file.
29424         * m4/xstrtoumax.m4: Add comments explaining why we
29425         AC_REPLACE_FUNCS(strtol).
29426
29427 2001-08-26  Jim Meyering  <meyering@lucent.com>
29428
29429         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
29430         of copyright with `%s' so translators don't get an untranslated
29431         message in 2002.
29432         (COPYRIGHT_YEAR): Define.
29433         (version_etc): Use fprintf rather than fputs.
29434         Suggestion from Ulrich Drepper.
29435
29436         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
29437
29438         * lib/strtoll.c: New file, from GNU libc.
29439         * lib/xstrtoimax.c: New file.
29440
29441         * lib/xstrtol.h: Add xstrtoimax.
29442         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
29443         * lib/strtoimax.c: New file.  Likewise, but first define
29444         STRTOUXMAX_SIGNED.
29445
29446         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
29447         ...
29448         * lib/strtoxmax.c: ... then renamed to this.
29449
29450 2001-08-18  Paul Eggert  <eggert@twinsun.com>
29451
29452         * m4/inttypes.m4: Add AC_PREREQ(2.13).
29453         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
29454         (jm_AC_TYPE_INTMAX_T): New macro.
29455         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
29456
29457         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
29458
29459         * m4/longlong.m4: Renamed from ulonglong.m4.
29460         * m4/inttypes.m4: Renamed from inttypes_h.m4.
29461         * m4/uintmax_t.m4: Removed.
29462
29463 2001-08-13  Paul Eggert  <eggert@twinsun.com>
29464
29465         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
29466         Port to Solaris 8, where 'sed' requires a space after the 'r'
29467         command, and where sh dislikes "$/".  Clean up the spacing a bit.
29468         Redirect output to $tmp just once.
29469
29470 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
29471
29472         * lib/addext.c (<errno.h>): Include.
29473         (errno): Declare if not defined.
29474         (addext): Work correctly when pathconf returns -1 and leaves
29475         errno alone because there is no limit.  Also, work even if
29476         pathconf returns a value greater than SIZE_MAX.
29477
29478 2001-08-12  Jim Meyering  <meyering@lucent.com>
29479
29480         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
29481         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
29482         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
29483         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
29484         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
29485         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
29486         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
29487         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
29488         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
29489         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
29490         utime.m4, utimes.m4, xstrtoumax.m4:
29491         Quote the first argument in each use of AC_DEFUN.
29492
29493 2001-08-12  Jim Meyering  <meyering@lucent.com>
29494
29495         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
29496         Simply `return getcwd (NULL, 0);'.
29497         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
29498         Use 1300 as initial value for length, not PATH_MAX.
29499
29500         * lib/pathmax.h: Clean up cpp syntax.
29501
29502 2001-08-12  Jim Meyering  <meyering@lucent.com>
29503
29504         * lib/gettimeofday.c: New file.
29505         * lib/gtod.h: New file.
29506         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
29507
29508 2001-08-05  Jim Meyering  <meyering@lucent.com>
29509
29510         * m4/jm-macros.m4: Require autoconf-2.52.
29511
29512 2001-08-04  Jim Meyering  <meyering@lucent.com>
29513
29514         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
29515         stmt, to get in sync with glibc.
29516
29517 2001-08-03  Paul Eggert  <eggert@twinsun.com>
29518
29519         The following changes are from gettext 0.10.39 as maintained by
29520         Bruno Haible.
29521
29522         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
29523         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
29524         with inverted sense.  All uses changed.
29525
29526         * lib/mbswidth.c: Don't include <limits.h>.
29527         Include <stdlib.h> and <string.h> unconditionally.
29528         (iswcntrl, mbsinit, ISCNTRL): New macros.
29529         (mbsnwidth): Use K&R style function declarations.
29530         Don't bother checking for MB_LEN_MAX == 1, since the compiler
29531         can optimize it when MB_CUR_MAX == 1.
29532         The width of control characters is zero, not 1.
29533
29534 2001-08-03  Paul Eggert  <eggert@twinsun.com>
29535
29536         The following changes are from gettext 0.10.39 as maintained by
29537         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
29538
29539         * m4/codeset.m4: Upgrade to serial AM1.
29540         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
29541         all uses changed.  Quote first arg of AC_DEFUN.
29542         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
29543
29544         * m4/iconv.m4: Upgrade to serial AM2.
29545         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
29546         Add --with-libconv-prefix.
29547         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
29548         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
29549         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
29550         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
29551         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
29552
29553         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
29554         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
29555         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
29556         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
29557         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
29558         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
29559         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
29560         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
29561         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
29562
29563         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
29564         string.h any more.
29565
29566         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
29567         not the default value.
29568
29569         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
29570         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
29571         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
29572         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
29573         Also check for iswcntrl, used for wcwidth fallback.
29574         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
29575         to Autoconf 2.13.
29576
29577 2001-08-03  Jim Meyering  <meyering@lucent.com>
29578
29579         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
29580         as it was in the original.  Reported by Paul Eggert.
29581
29582 2001-07-16  Jim Meyering  <meyering@lucent.com>
29583
29584         * m4/gettimeofday.m4: New file.
29585         Prompted by a report from Bernhard Baehr.
29586
29587 2001-07-15  Jim Meyering  <meyering@lucent.com>
29588
29589         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
29590         stuff. Now it's in ../Makefile.cfg.
29591
29592 2001-07-15  Jim Meyering  <meyering@lucent.com>
29593
29594         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
29595         (BUILT_SOURCES): Add unlocked-io.h.
29596         (io_functions): Define.
29597         (unlocked-io.h): New rule.
29598         (DISTCLEANFILES): Add unlocked-io.h.
29599         (all-local): Depend on unlocked-io.h, to ensure it is created.
29600
29601         * lib/unlocked-io.hin: New file
29602
29603         * lib/regex.c: Update from glibc.
29604
29605 2001-07-05  Jim Meyering  <meyering@lucent.com>
29606
29607         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
29608         recommendation.
29609         (libfetish_a_SOURCES): Put all .h files here instead.
29610         Remove a thus-exposed (better checks in automake) duplicate and
29611         two unnecessary .h files.
29612
29613 2001-07-04  Jim Meyering  <meyering@lucent.com>
29614
29615         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
29616         that generates jm-glibc-io.m4 so that it doesn't trigger any make
29617         distcheck failure.
29618
29619 2001-07-02  Jim Meyering  <meyering@lucent.com>
29620
29621         The following changes were prompted by suggestions from Bruno Haible.
29622
29623         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
29624         is now generated.
29625         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
29626         definition of EXTRA_DIST.
29627         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
29628         ensure that the generated file is created/updated whenever the list
29629         of $(unlocked_functions) is changed.
29630         (jm-glibc-io.m4): New rule.
29631         (unlocked-io.h): New rule -- currently unused.
29632
29633 2001-06-24  Jim Meyering  <meyering@lucent.com>
29634
29635         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
29636         unmatched right bracket, rather than kludging it with an extra,
29637         falsely-matching quote in a comment.  Patch by Akim Demaille.
29638
29639 2001-06-11  Jim Meyering  <meyering@lucent.com>
29640
29641         * lib/regex.c: Update from GNU libc.
29642
29643 2001-05-27  Jim Meyering  <meyering@lucent.com>
29644
29645         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
29646         Check for ut_type in struct utmp.
29647
29648 2001-05-27  Jim Meyering  <meyering@lucent.com>
29649
29650         * lib/readutmp.h (UT_TYPE): Define.
29651
29652 2001-05-24  Jim Meyering  <meyering@lucent.com>
29653
29654         * lib/argmatch.c: Include "quote.h".
29655         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
29656         quote function.  Reported by Göran Uddeborg.
29657
29658 2001-05-22  Jim Meyering  <meyering@lucent.com>
29659
29660         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
29661         now that we use the package-supplied version unconditionally.
29662         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
29663
29664 2001-05-21  Jim Meyering  <meyering@lucent.com>
29665
29666         * m4/regex.m4: Change a couple backticks to single quotes to avoid
29667         shell syntax errors.
29668
29669 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
29670
29671         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
29672
29673 2001-05-20  Paul Eggert  <eggert@twinsun.com>
29674
29675         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
29676         Don't bother to check library strftime, since
29677         we'll be using our own my_strftime function anyway.
29678         Define my_strftime instead of strftime.
29679
29680 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
29681
29682         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
29683         which is not yet declared.
29684
29685 2001-05-15  Jim Meyering  <meyering@lucent.com>
29686
29687         * m4/regex.m4: Use proper quoting so brackets appear in the test
29688         program.
29689         Reported by, and with help from, Bruno Haible.
29690
29691 2001-05-13  Jim Meyering  <meyering@lucent.com>
29692
29693         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
29694         undefined.
29695
29696 2001-05-11  Paul Eggert  <eggert@twinsun.com>
29697
29698         dirname code cleanup.  base_name now behaves more compatibly
29699         with POSIX basename when given file names that have trailing
29700         slashes, and similarly for dir_name.  Add new primitives
29701         base_len and dir_len.  Put the directory-name-related decls
29702         into dirname.h.
29703
29704         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
29705         * lib/backupfile.c (base_name): Likewise.
29706         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
29707         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
29708         * lib/makepath.c (strip_trailing_slashes): Likewise.
29709         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
29710         ISSLASH): Likewise.
29711         * lib/rename.c (strip_trailing_slashes): Likewise.
29712         * lib/same.c (base_name): Likewise.
29713         * lib/stripslash.c (ISSLASH): Likewise.
29714
29715         * lib/addext.c: Include <dirname.h> after size_t is defined.
29716         * lib/backupfile.c: Likewise.
29717
29718         * lib/addext.c (addext): Use base_len to trim redundant
29719         trailing slashes instead of doing it ourselves.
29720         But do not trim the last slash if it is not redundant.
29721
29722         * lib/backupfile.c (find_backup_file_name,
29723         max_backup_version): Use base_len instead of rolling it ourselves.
29724         Handle the case of "" and (on DOS) "C:" correctly.
29725
29726         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
29727         needed. Include <string.h>, <dirname.h>.
29728         (base_name): Allow file names ending in slashes, other than names
29729         that are all slashes.  In this case, return the basename followed
29730         by the slashes.  This is more general, and can be used in places
29731         where the original base_name purposely had an assertion failure.
29732         (base_len): New function.
29733
29734         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
29735         Do not include <assert.h>; no longer needed.
29736         Include xalloc.h.
29737         (memrchr): Remove decl.
29738         (dir_name_r): Remove.
29739         (dir_len): Renamed from dirlen.  All callers changed.
29740         Rewrite in terms of base_name, for simplicity and consistency.
29741         (dir_name): Never return NULL.  All callers changed.
29742         Do not include <stdlib.h> in test program; no longer needed.
29743         return 0; is fine for test program.
29744
29745         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
29746         New macros.
29747         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
29748
29749         * lib/path-concat.c (path_concat): Use base_len to compute
29750         base length, not strlen; this means we cannot rely on memcpy
29751         to null-terminate.
29752
29753         * lib/same.c (STREQ): Remove.
29754         (same_name): Handle the case where the basename ends in trailing '/'.
29755
29756         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
29757         a slash was stripped.  Do not strip the last slash after a
29758         file system prefix.
29759
29760 2001-05-11  Paul Eggert  <eggert@twinsun.com>
29761
29762         * lib/Makefile.am (libfetish_a_SOURCES):
29763         Add strftime.c, since we now compile it on all hosts.
29764
29765         * lib/strftime.c (my_strftime):
29766         Define to nstrftime if emacs, but only if my_strftime is not defined.
29767         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
29768         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
29769         Add one more extra argument: a nanoseconds value.
29770         All uses changed.
29771         (ns): New macro.
29772         (my_strftime function): Add %N format.
29773         (emacs_strftimeu): Renamed from emacs_strftime,
29774         with extra ut argument.
29775
29776 2001-05-09  Paul Eggert  <eggert@twinsun.com>
29777
29778         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
29779
29780 2001-04-21  Jim Meyering  <meyering@lucent.com>
29781
29782         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
29783         doesn't interfere.
29784
29785 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
29786
29787         * m4/ftruncate.m4: Check for chsize.
29788         Link with ftruncate.o unconditionally if ftruncate is missing.
29789         This was required when cross-compiling to i586-mingw32msvc.
29790
29791 2001-04-08  Jim Meyering  <meyering@lucent.com>
29792
29793         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
29794         recomputed; that's necessary when the offset spans a DST transition.
29795         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
29796
29797 2001-04-02  Jim Meyering  <meyering@lucent.com>
29798
29799         * lib/regex.h, regex.c: Update from GNU libc.
29800
29801 2001-03-24  Jim Meyering  <meyering@lucent.com>
29802
29803         * m4/jm-macros.m4: Require autoconf-2.49d.
29804
29805 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
29806
29807         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
29808
29809 2001-03-19  Paul Eggert  <eggert@twinsun.com>
29810
29811         * lib/version-etc.c (version_etc_copyright): Update to 2001.
29812
29813 2001-03-17  Jim Meyering  <meyering@lucent.com>
29814
29815         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
29816         now that the version in autoconf is equivalent.
29817         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
29818
29819         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
29820         Suggestion from Akim Demaille.
29821
29822         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
29823         (jm_PREREQ_TEMPNAME): New function.
29824
29825 2001-03-16  Paul Eggert  <eggert@twinsun.com>
29826
29827         * lib/tempname.c (uint64_t): Define to uintmax_t if
29828         not defined, and if UINT64_MAX is not defined.
29829         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
29830         Reported by John David Anglin.
29831
29832 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
29833
29834         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
29835         resolve alias if codeset is empty.
29836         * lib/config.charset (BeOS): Use wildcard syntax.
29837
29838 2001-03-13  Jim Meyering  <meyering@lucent.com>
29839
29840         * lib/path-concat.c (path_concat)
29841         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
29842         concatenating e.g., `C:' and `foo'.
29843         From Bruno Haible.
29844
29845 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
29846
29847         * lib/localcharset.c (locale_charset): Don't use
29848         setlocale(LC_CTYPE,NULL). Don't return NULL.
29849         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
29850
29851 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
29852
29853         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
29854         support for DOS/DJGPP.
29855
29856 2001-03-01  Paul Eggert  <eggert@twinsun.com>
29857
29858         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
29859         lacks mkstemp.  Compile our own tempname.c if we compile our own
29860         mkstemp.c, as mkstemp relies on tempname.
29861
29862 2001-03-01  Jim Meyering  <meyering@lucent.com>
29863
29864         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
29865         AH_VERBATIM really does output its argument verbatim.
29866
29867 2001-02-28  Paul Eggert  <eggert@twinsun.com>
29868
29869         * lib/Makefile.am (libfetish_a_SOURCES):
29870         Add dup-safer.c, fopen-safer.c.
29871         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
29872
29873         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
29874         * lib/unistd-safer.h: New files.
29875
29876 2001-02-25  Paul Eggert  <eggert@twinsun.com>
29877
29878         The mkstemp replacement is taken from glibc 2.2.2, with some
29879         portability fixes for use outside glibc, as follows:
29880
29881         * lib/tempname.c (struct_stat64): New macro.
29882         (direxists, __gen_tempname): Use it.
29883         This avoids a portability problem with Solaris 8.
29884
29885         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
29886         (<stddef.h>, <stdint.h>, <string.h>):
29887         Include only if STDC_HEADERS || _LIBC.
29888         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
29889         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
29890         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
29891         (__set_errno): Define this macro if <errno.h> doesn't.
29892         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
29893         Define these macros if <stdio.h> doesn't.
29894         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
29895         Define these macros if <sys/stat.h>
29896         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
29897         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
29898         __xstat64): Define if not _LIBC.
29899         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
29900         (__gen_tempname): Invoke gettimeofday only if
29901         HAVE_GETTIMEOFDAY || _LIBC;
29902         otherwise, fall back on plain "time".
29903         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
29904
29905         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
29906
29907         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
29908
29909 2001-02-18  Paul Eggert  <eggert@twinsun.com>
29910
29911         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
29912
29913 2001-02-17  Paul Eggert  <eggert@twinsun.com>
29914
29915         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
29916         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
29917         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
29918         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
29919
29920 2001-02-17  Paul Eggert  <eggert@twinsun.com>
29921
29922         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
29923         Remove workaround macros for hosts that have mbrtowc but not
29924         mbstate_t, as we now insist on proper declarations for both
29925         before using mbrtowc.
29926
29927 2001-02-17  Jim Meyering  <meyering@lucent.com>
29928
29929         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
29930         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
29931         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
29932         UnixWare 7.1.1.
29933
29934         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
29935         rather than AC_CACHE_VAL.
29936
29937 2001-02-17  Jim Meyering  <meyering@lucent.com>
29938
29939         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
29940         around included file name.
29941
29942         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
29943
29944         * lib/strftime.c: Update from GNU libc (the only changes were to
29945         comments).
29946
29947 2001-02-17  Jim Meyering  <meyering@lucent.com>
29948
29949         * lib/regex.c: Update from libc.
29950
29951 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
29952
29953         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
29954         clash.
29955
29956 2001-02-16  Paul Eggert  <eggert@twinsun.com>
29957
29958         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
29959         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
29960         Reported by Mark Hounschell via Paul Eggert.
29961
29962 2001-02-07  Jim Meyering  <meyering@lucent.com>
29963
29964         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
29965
29966 2001-02-05  Jim Meyering  <meyering@lucent.com>
29967
29968         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
29969         it includes the patch required for `large file' support with at least
29970         HP-UX's 10.20 /bin/cc.
29971
29972 2001-02-03  Jim Meyering  <meyering@lucent.com>
29973
29974         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
29975         AS_IF, now that it works once again (mysteriously).
29976         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
29977
29978 2001-01-30  Jim Meyering  <meyering@lucent.com>
29979
29980         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
29981         * m4/chown.m4: Rename conftestchown to conftest.chown.
29982         * m4/rename.m4: s/conftestdir/conftest.d1/ and
29983         s/conftestdir2/conftest.d2/.
29984         * m4/utimes.m4: s/conftestdata/conftest.data/
29985         Inspired by Pavel Roskin's change in autoconf.
29986
29987 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
29988
29989         * lib/config.charset: Update for FreeBSD 4.2.
29990
29991 2001-01-27  Jim Meyering  <meyering@lucent.com>
29992
29993         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
29994         a use of AS_IF.
29995         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
29996
29997 2001-01-26  Jim Meyering  <meyering@lucent.com>
29998
29999         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
30000         quotearg.c includes it.
30001
30002 2001-01-26  Jim Meyering  <meyering@lucent.com>
30003
30004         * lib/quotearg.c: Include stddef.h.
30005         * lib/quote.c: Include stddef.h.
30006         Reported by Axel Kittenberger.
30007
30008         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
30009         line in double quotes so that it evokes a better diagnostic.
30010         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
30011         Reported by Axel Kittenberger.
30012
30013 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
30014
30015         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
30016         as if it was a `charset'.
30017
30018 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
30019
30020         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
30021         has const.
30022
30023 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
30024
30025         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
30026         to avoid a warning.  Add back 'const' to inptr.
30027
30028 2001-01-20  Jim Meyering  <meyering@lucent.com>
30029
30030         Be sure that headers are checked before used in code compiled
30031         for the type checks.
30032         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
30033         In place of that, invoke jm_CHECK_ALL_TYPES.
30034         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
30035         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
30036         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
30037         The check for ssize_t was mistakenly run before the test for unistd.h.
30038
30039         The configure-time check for stdbool.h was missing.
30040         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
30041         (jm_PREREQ_HASH): New function.
30042
30043 2001-01-17  Jim Meyering  <meyering@lucent.com>
30044
30045         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
30046         for autoconf-2.49c.
30047         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
30048
30049 2001-01-16  Jim Meyering  <meyering@lucent.com>
30050
30051         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
30052         From Bruno Haible.
30053
30054 2001-01-14  Jim Meyering  <meyering@lucent.com>
30055
30056         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
30057         foo and bar.  Create conftestdir/ in the script, not in the C code.
30058         Remove directories in the script, not in the C code.
30059         Remove conftestdir{,2} before trying to create the directory.
30060         Make the entire configure script fail if the mkdir fails.
30061
30062 2001-01-14  Jim Meyering  <meyering@lucent.com>
30063
30064         * lib/rename.c: New file.  From Volker Borchert.
30065         Include stdlib.h, string.h or strings.h, and xalloc.h.
30066         Use strip_trailing_slashes rather than open-coding it.
30067
30068 2001-01-03  Paul Eggert  <eggert@twinsun.com>
30069
30070         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
30071
30072 2001-01-03  Jim Meyering  <meyering@lucent.com>
30073
30074         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
30075         of local `inptr' to avoid warning with some system declarations of
30076         iconv.
30077
30078 2001-01-02  Volker Borchert  <bt@teknon.de>
30079
30080         * m4/rename.m4: New file.
30081         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
30082
30083 2001-01-01  Jim Meyering  <meyering@lucent.com>
30084
30085         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
30086         even on systems with utmpx.h.  It's necessary for the declaration of
30087         utmp's ut_user member.  Reported by Andreas Jaeger.
30088
30089         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
30090         available. They are required for the declarations of getgrgid and
30091         getpwuid resp.
30092         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
30093         Reported by Andreas Jaeger.
30094
30095 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
30096
30097         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
30098         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
30099         so `make install' also works in VPATH builds.
30100
30101 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
30102
30103         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
30104         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
30105         can be used in subdirectories.
30106
30107 2000-12-29  Paul Eggert  <eggert@twinsun.com>
30108
30109         * lib/modechange.c: Do not assume that mode_t uses the
30110         traditional octal encoding.  E.g. "chmod 1 FOO" should set
30111         the other-execute bit of FOO even if S_IXOTH != 1.
30112
30113         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
30114         WOTH, XOTH, ALLM): New macros.
30115         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
30116          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
30117         Use them.
30118         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
30119         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
30120         (mode_compile):
30121         No need to use uintmax_t; unsigned long is long enough.
30122         Don't bother to get suffix since we don't use it.
30123
30124 2000-12-26  Jim Meyering  <meyering@lucent.com>
30125
30126         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
30127         better with autoheader.
30128
30129 2000-12-24  Jim Meyering  <meyering@lucent.com>
30130
30131         * lib/hash.c (is_prime): Return explicit boolean values.
30132         (hash_get_first): Return NULL to appease Irix5.6's 89.
30133         Reported by Nelson Beebe.
30134
30135 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
30136
30137         * lib/localcharset.c (locale_charset): Add support for Win32.
30138
30139 2000-12-18  Paul Eggert  <eggert@twinsun.com>
30140
30141         * lib/physmem.h, lib/physmem.c: New files.
30142
30143         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
30144         (noinst_HEADERS): Add physmem.h.
30145
30146         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
30147         't' for compatibility with Solaris 8 sort.
30148
30149 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
30150
30151         * lib/config.charset: Add support for BeOS.
30152
30153 2000-12-17  Jim Meyering  <meyering@lucent.com>
30154
30155         * m4/dos.m4 (jm_AC_DOS): New file and macro.
30156         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
30157
30158 2000-12-16  Jim Meyering  <meyering@lucent.com>
30159
30160         This bug had a serious impact on chown: `chown N:M FILE' (for integer
30161         N and M) would have treated it like `chown N:N FILE'.
30162
30163         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
30164
30165 2000-12-16  Jim Meyering  <meyering@lucent.com>
30166
30167         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
30168         SHELLS_FILE to a file name that's useful on djgpp systems.
30169         Include stdlib.h.
30170         (ADDITIONAL_DEFAULT_SHELLS): Define.
30171         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
30172         Based mostly on a patch from Prashant TR.
30173
30174 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
30175
30176         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
30177         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
30178         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
30179
30180 2000-12-08  Andreas Schwab  <schwab@suse.de>
30181
30182         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
30183         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
30184
30185 2000-12-07  Jim Meyering  <meyering@lucent.com>
30186
30187         * lib/stripslash.c (ISSLASH): Define.
30188         (strip_trailing_slashes): Use ISSLASH rather than comparing against
30189         `/'.
30190         From Prashant TR.
30191
30192         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
30193         (dir_name_r): Declare this function as static.
30194         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
30195         manifest itself on a name containing a mix of slashes and
30196         backslashes.
30197         Make this function work with names starting with a DOS-style
30198         drive letter and colon prefix.
30199         (dir_name): Append `.' if necessary.
30200         Based mostly on patches from Prashant TR and Eli Zaretskii.
30201
30202         * lib/dirname.h (dir_name_r): Remove prototype.
30203
30204 2000-12-06  Paul Eggert  <eggert@twinsun.com>
30205
30206         * m4/off_t-format.m4: Remove this file.
30207         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
30208
30209 2000-12-06  Jim Meyering  <meyering@lucent.com>
30210
30211         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
30212         replacement strtoull, we may well need the replacement strtoul, too.
30213         Check for declarations of strtoul and strtoull.
30214         Check for strtol.  Mainly as a cue to cause automake to include
30215         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
30216         Check for limits.h -- strtol.c needs it.
30217
30218 2000-12-05  Jim Meyering  <meyering@lucent.com>
30219
30220         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
30221
30222 2000-12-04  Jim Meyering  <meyering@lucent.com>
30223
30224         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
30225         Also include memory.h, stdlib.h, unistd.h if appropriate.
30226         Reported by Andreas Jaeger (conflicting declaration of malloc).
30227
30228 2000-12-02  Jim Meyering  <meyering@lucent.com>
30229
30230         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
30231         * m4/jm-macros.m4 (jm_MACROS): require it.
30232
30233 2000-12-02  Jim Meyering  <meyering@lucent.com>
30234
30235         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
30236
30237 2000-12-01  Paul Eggert  <eggert@twinsun.com>
30238
30239         * lib/memrchr.c: Include <config.h> before any system include file.
30240
30241 2000-11-30  Jim Meyering  <meyering@lucent.com>
30242
30243         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
30244
30245 2000-11-30  Jim Meyering  <meyering@lucent.com>
30246
30247         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
30248
30249 2000-11-29  Paul Eggert  <eggert@twinsun.com>
30250
30251         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
30252
30253 2000-11-26  Jim Meyering  <meyering@lucent.com>
30254
30255         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
30256
30257 2000-11-22  Paul Eggert  <eggert@twinsun.com>
30258
30259         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
30260         size of (size_t) -1; it's not portable.
30261
30262 2000-11-17  Jim Meyering  <meyering@lucent.com>
30263
30264         * lib/strstr.c: Update from GNU libc.
30265
30266 2000-11-17  Akim Demaille  <akim@epita.fr>
30267
30268         * lib/obstack.h: Formatting changes.
30269         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
30270         prevent type checking.
30271         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
30272         cast the value to (void *): assigning a `foo *' to a `void *'
30273         variable is valid.
30274         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
30275
30276 2000-11-16  Jim Meyering  <meyering@lucent.com>
30277
30278         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
30279
30280 2000-11-11  Jim Meyering  <meyering@lucent.com>
30281
30282         * lib/error.c: Add a couple #includes, merging from GNU libc version.
30283
30284 2000-11-10  Jim Meyering  <meyering@lucent.com>
30285
30286         * lib/obstack.h: Update from GNU libc.
30287         * lib/obstack.c: Likewise.
30288
30289 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
30290
30291         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
30292
30293 2000-11-06  Paul Eggert  <eggert@twinsun.com>
30294
30295         * lib/getusershell.c (setusershell): Use rewind rather than
30296         fseek/fseeko, to avoid configuration hassles with fseeko.
30297         Don't bother opening SHELLS_FILE if shellstream is NULL;
30298         it's not necessary.
30299
30300 2000-11-05  Jim Meyering  <meyering@lucent.com>
30301
30302         * lib/makepath.h (make_dir): Declare.
30303         * lib/makepath.c (make_dir): Remove `static' attribute.
30304         Tweak a comment.
30305
30306 2000-11-04  Jim Meyering  <meyering@lucent.com>
30307
30308         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
30309
30310 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
30311
30312         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
30313         last one in a bucket, advance to the next bucket.
30314
30315 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
30316
30317         * lib/fnmatch.c: Do not comment out all the code if we are using
30318         the GNU C library, because in some cases we are replacing buggy
30319         code in the GNU C library itself.
30320
30321 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
30322
30323         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
30324         (regex_compile): Catch bogus \(\1\).
30325
30326 2000-10-30  Paul Eggert  <eggert@twinsun.com>
30327
30328         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
30329         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
30330         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
30331
30332 2000-10-30  Paul Eggert  <eggert@twinsun.com>
30333
30334         * lib/error.h, getline.h, modechange.h:
30335         Remove "2000" from Copyright line, as the file hasn't been
30336         changed this year other than in the copyright notice.
30337
30338         * lib/xalloc.h: Add "2000" to Copyright line, as this file
30339         was changed this year.
30340
30341 2000-10-29  Jim Meyering  <meyering@lucent.com>
30342
30343         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
30344         renaming.
30345         * m4/ls-mntd-fs.m4: Likewise
30346
30347 2000-10-29  Jim Meyering  <meyering@lucent.com>
30348
30349         * lib/xstat.in: Fix grammar in comment.
30350
30351 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
30352
30353         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
30354         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
30355         doesn't define __restrict_arr.
30356
30357 2000-10-28  Jim Meyering  <meyering@lucent.com>
30358
30359         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
30360         (jm_PREREQ_MEMCHR): New function.
30361
30362 2000-10-28  Jim Meyering  <meyering@lucent.com>
30363
30364         * lib/memchr.c: Update from libc.
30365         Adjust for portability:
30366         [HAVE_STDLIB_H]: Include stdlib.h.
30367         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
30368         Undef __memchr, too.
30369         [!weak_alias]: Define __memchr to memchr.
30370
30371         * lib/regex.c: Update from libc.
30372         * lib/regex.h: Likewise.
30373         * lib/getopt1.c: Likewise.
30374         * lib/memcmp.c: Likewise.
30375
30376         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
30377         Avoid using fseek, when possible -- it's broken by design.
30378         Patch by Ulrich Drepper.
30379
30380 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
30381
30382         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
30383         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
30384         Giving in to popular pressure to shut up the compiler with casts.
30385
30386 2000-10-26  Jim Meyering  <meyering@lucent.com>
30387
30388         * lib/strftime.c: Update from libc.
30389
30390 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
30391
30392         * regex.c: More `unsigned char' -> `re_char' changes.
30393         Also change several `int' into `re_wchar_t'.
30394         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
30395         (PUSH_FAILURE_POINTER): Don't cast any more.
30396         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
30397         We want GCC to complain, since this piece of code makes
30398         re_match non-reentrant, which *should* be fixed.
30399         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
30400         (EXTEND_BUFFER): Use RETALLOC.
30401         (SET_LIST_BIT): Don't cast.
30402         (re_wchar_t): New type.
30403         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
30404         that those two functions will always properly return.
30405         (IMMEDIATE_QUIT_CHECK): Cast to void.
30406         (analyse_first): Use recursion rather than an explicit stack.
30407         (re_compile_fastmap): Can't fail anymore.
30408         (re_search_2): Don't check re_compile_fastmap for failure.
30409         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
30410         Now also sets the new value (passed in a new argument).
30411         (re_match_2_internal): Use it.
30412         Also, use a new var `reg' of type size_t when looping through regs
30413         rather than reuse the inappropriate `mcnt'.
30414
30415 2000-10-25  Jim Meyering  <meyering@lucent.com>
30416
30417         * lib/obstack.c: Update from libc.
30418
30419 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
30420
30421         * regex.c (regex_compile): Change the way of handling a range from
30422         a char less than 256 to a char not less than 256.
30423
30424 2000-10-24  Andrew Innes  <andrewi@gnu.org>
30425
30426         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
30427         NT-Emacs only.
30428         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
30429         so that re_search functions only quit when callers expect them to.
30430
30431 2000-10-23  Jim Meyering  <meyering@lucent.com>
30432
30433         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
30434         wrong.  That set_locale call must not have any side effects.
30435         From Paul Eggert.
30436
30437 2000-10-22  Jim Meyering  <meyering@lucent.com>
30438
30439         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
30440         [CYCLIC]: Remove now-unused definition.
30441
30442         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
30443         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
30444         Suggestion from Ulrich Drepper.
30445
30446 2000-10-21  Jim Meyering  <meyering@lucent.com>
30447
30448         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
30449         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
30450         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
30451
30452 2000-10-21  Jim Meyering  <meyering@lucent.com>
30453
30454         * lib/dirname.c (memrchr): Declare if necessary.
30455         (dir_name): Remove the restriction that there be no
30456         trailing slashes.  Now, this code skips past them, effectively
30457         ignoring them.
30458         [TEST_DIRNAME] (main): New unit tests.
30459
30460         * lib/memrchr.c: New file from GNU libc.
30461         Undef __memrchr, too.
30462         [!weak_alias]: Define __memrchr to memrchr.
30463         Guard weak_alias use with `#ifdef weak_alias'.
30464
30465 2000-10-21  Jim Meyering  <meyering@lucent.com>
30466
30467         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
30468         (dir_name): Use dir_name_r.
30469         * lib/dirname.h (dir_name_r): Declare it.
30470
30471 2000-10-17  Jim Meyering  <meyering@lucent.com>
30472
30473         * lib/quote.h (PARAMS): Define and use.
30474         Reported by Akim Demaille.
30475
30476         * lib/getopt.c: Update from libc.
30477
30478 2000-10-16  Jim Meyering  <meyering@lucent.com>
30479
30480         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
30481         setlocale.
30482         From Jan Fedak.
30483
30484 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
30485
30486         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
30487
30488 2000-09-25  Jim Meyering  <meyering@lucent.com>
30489
30490         * lib/md5.h (rol): Define (from GnuPG).
30491
30492         * lib/sha.c: Give credit (GnuPG) where due.
30493         (M): Use rol rather than open-coding it.
30494         Add a FIXME comment.
30495
30496 2000-09-21  Jim Meyering  <meyering@lucent.com>
30497
30498         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
30499         Reported by Michael Stone.
30500
30501 2000-09-20  Jim Meyering  <meyering@lucent.com>
30502
30503         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
30504         (noinst_HEADERS): Add sha.h.
30505         Based on code from Scott G. Miller and from GnuPG.
30506
30507 2000-09-18  Jim Meyering  <meyering@lucent.com>
30508
30509         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
30510         LIBS. Otherwise, everyone ends up linking with -lelf for some
30511         configurations.
30512         Reported by Mike Stone.
30513
30514 2000-09-15  Jim Meyering  <meyering@lucent.com>
30515
30516         * lib/regex.c: Update from libc.
30517
30518 2000-09-10  Jim Meyering  <meyering@lucent.com>
30519
30520         * lib/getopt.c (_getopt_internal): Update from glibc.
30521
30522 2000-09-09  Jim Meyering  <meyering@lucent.com>
30523
30524         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
30525         think it should be used as a general replacement for isascii.
30526         * lib/fnmatch.c: Likewise.
30527         * lib/mbswidth.c: Likewise
30528         * lib/regex.c: Likewise.
30529
30530         Don't use atoi.
30531         * lib/userspec.c: Include sys/param.h and limits.h.
30532         Include xstrtol.h.
30533         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
30534         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
30535         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
30536         UID, GID.  Check range.
30537
30538 2000-09-06  Jim Meyering  <meyering@lucent.com>
30539
30540         * lib/getopt.c (_getopt_internal): Update from glibc.
30541
30542 2000-08-30  Jim Meyering  <meyering@lucent.com>
30543
30544         * lib/strftime.c: Merge in changes from GNU libc.
30545
30546 2000-08-26  Jim Meyering  <meyering@lucent.com>
30547
30548         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
30549         * m4/fpending.m4: New file.
30550
30551 2000-08-26  Jim Meyering  <meyering@lucent.com>
30552
30553         * lib/closeout.c: Include "__fpending.h".
30554         (close_stdout_status): Return right away if there's nothing to flush.
30555
30556         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
30557         * lib/__fpending.c: New file.
30558         * lib/__fpending.h: New file.
30559
30560 2000-08-20  Jim Meyering  <meyering@lucent.com>
30561
30562         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
30563         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
30564         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
30565
30566 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
30567
30568         Improve fileutils installation on systems where running
30569         programs (like install) can't be unlinked.
30570         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
30571         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
30572
30573 2000-08-07  Paul Eggert  <eggert@twinsun.com>
30574
30575         Standardize on "memory exhausted" instead of "Memory exhausted"
30576         or "virtual memory exhausted".
30577         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
30578         "virtual memory exhausted".
30579         * lib/same.c (same_name): Invoke xalloc_die instead of printing
30580         our own message.
30581         * lib/userspec.c (parse_user_spec): Likewise.
30582         * lib/bumpalloc.h: comment fix
30583         * lib/same.c, userspec.c: Include xalloc.h.
30584
30585         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
30586         not char *const and pointing to a constant array.
30587         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
30588         (xrealloc): Comment fix.
30589
30590         * lib/userspec.c (parse_user_spec):
30591         Don't translate a message until just before returning,
30592         to avoid unnecessary translation.
30593
30594 2000-08-07  Jim Meyering  <meyering@lucent.com>
30595
30596         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
30597         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
30598         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
30599         getgroups.c, gethostname.c, getopt.h, group-member.c,
30600         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
30601         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
30602         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
30603         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
30604         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
30605         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
30606         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
30607         yesno.c: Back out Copyright date changes for each file with no change
30608         this year.  This eases coordination with other programs using the same
30609         source code modules.  From Paul Eggert.
30610
30611 2000-08-06  Paul Eggert  <eggert@twinsun.com>
30612
30613         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
30614         not char, for compatibility with glibc 2.1.3 strftime.c.
30615
30616 2000-08-03  Greg McGary  <greg@mcgary.org>
30617
30618         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
30619         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
30620         (EXTEND_BUFFER): Use them.
30621
30622 2000-08-01  Jim Meyering  <meyering@lucent.com>
30623
30624         * lib/dirname.c (ISSLASH): Define.
30625         (BACKSLASH_IS_PATH_SEPARATOR): Define.
30626         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
30627         both `\' and `/' may be use as path separators.
30628         Based on a patch from Prashant TR.
30629
30630 2000-07-31  Paul Eggert  <eggert@twinsun.com>
30631
30632         * lib/quotearg.c (quotearg_n_options): Don't make the initial
30633         slot vector a constant, since it might get modified.
30634
30635 2000-07-31  Jim Meyering  <meyering@lucent.com>
30636
30637         * lib/xmalloc.c: Use `virtual memory exhausted', not
30638         `Memory exhausted'.
30639         * lib/obstack.c (print_and_abort): Likewise.
30640
30641 2000-07-30  Paul Eggert  <eggert@twinsun.com>
30642
30643         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
30644         buffer, so that the caller can always quote one small
30645         component of a "memory exhausted" message in slot 0.
30646         From a suggestion by Jim Meyering.
30647
30648 2000-07-30  Jim Meyering  <meyering@lucent.com>
30649
30650         * lib/makepath.c (make_path): Quote the other instance, too.
30651
30652         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
30653         (STATIC_BUF_SIZE): Define.
30654         (quotearg_n_options): Use only statically allocated storage when
30655         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
30656         than STATIC_BUF_SIZE.
30657
30658 2000-07-29  Jim Meyering  <meyering@lucent.com>
30659
30660         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
30661         * lib/dirname.c (dir_name): Likewise.
30662
30663         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
30664         `/'.
30665
30666         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
30667         (dir_name): Assert that there are no trailing slashes.
30668
30669 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
30670
30671         * lib/mbswidth.h (mbswidth): Add a flags argument.
30672         (mbswidth): New declaration.
30673         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
30674         * lib/mbswidth.c (mbswidth): Add a flags argument.
30675         (mbsnwidth): New function.
30676
30677 2000-07-24  Jim Meyering  <meyering@lucent.com>
30678
30679         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
30680
30681 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30682
30683         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
30684
30685 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30686
30687         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
30688         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
30689         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
30690         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
30691         invoke multibyte primitives.
30692
30693 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30694
30695         * lib/quotearg.c:
30696         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
30697         so that mbstate_t is always defined.
30698
30699         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
30700         be 1 in at least one GCC installation, and this configuration
30701         error is likely to be common.  Ignoring MB_LEN_MAX hurts
30702         performance on hosts that have mbrtowc but have only unibyte
30703         locales, but I assume these hosts are rare.
30704
30705 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30706
30707         * lib/mbswidth.c (_XOPEN_SOURCE):
30708         Don't define; this causes problems on Solaris 7.
30709         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
30710
30711 2000-07-23  Jim Meyering  <meyering@lucent.com>
30712
30713         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
30714         too: getgrgid, getpwuid, getuid.
30715
30716 2000-07-23  Jim Meyering  <meyering@lucent.com>
30717
30718         * lib/basename.c (base_name): Add an assertion.
30719
30720 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
30721
30722         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
30723         shadow its mbsinit function.
30724
30725 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
30726
30727         * lib/mbswidth.h: New file.
30728         * lib/mbswidth.c: New file.
30729         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
30730         (noinst_HEADERS): Add mbswidth.h.
30731
30732 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
30733
30734         * lib/config.charset: Add support for FreeBSD. Improve support for
30735         HP-UX and IRIX 6.
30736
30737 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
30738
30739         * m4/mbswidth.m4: New file.
30740         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
30741
30742 2000-07-15  Jim Meyering  <meyering@lucent.com>
30743
30744         * lib/makepath.c: Include quote.h.
30745         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
30746         corresponding argument in a `quote (...)' call.
30747         Give better diagnostics.
30748
30749         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
30750         (noinst_HEADERS): Add quote.h.
30751
30752         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
30753         from tar's src/misc.c.
30754         * lib/quote.h: New file.  Prototypes for same.
30755
30756 2000-07-14  Paul Eggert  <eggert@twinsun.com>
30757
30758         From a suggestion by Bruno Haible.
30759         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
30760         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
30761         to decide whether to define the BeOS workaround macro;
30762         this adjusts to the change to AC_MBSTATE_T.
30763
30764 2000-07-14  Jim Meyering  <meyering@lucent.com>
30765
30766         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
30767         jm_AC_TYPE_UINTMAX_T.
30768
30769 2000-07-13  Paul Eggert  <eggert@twinsun.com>
30770
30771         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
30772
30773         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
30774         quotearg_buffer_restyled): Add support for
30775         clocale_quoting_style.  Undo previous change to
30776         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
30777         and "{RIGHT QUOTATION MARK}" msgids.
30778
30779 2000-07-10  Paul Eggert  <eggert@twinsun.com>
30780
30781         From a suggestion by Bruno Haible.
30782         * m4/mbstate_t.m4 (AC_MBSTATE_T):
30783         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
30784         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
30785         and mbstate_t, to a single-part test that simply defines mbstate_t.
30786         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
30787         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
30788
30789 2000-07-10  Jim Meyering  <meyering@lucent.com>
30790
30791         * m4/strerror_r.m4: Mirror the correction made in autoconf.
30792
30793         * m4/gnu-source.m4: Output to confdefs.h directly.
30794         Suggestion from Akim Demaille.
30795
30796 2000-07-09  Paul Eggert  <eggert@twinsun.com>
30797
30798         The old behavior of quoting `like this' doesn't look good with
30799         newer, ISO-style fonts.  See:
30800         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
30801
30802         Instead, quote "like this" by default.  Let the translator
30803         tailor the locale-specific quoting behavior by providing
30804         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
30805
30806         * lib/quotearg.c (N_): New macro.
30807         (gettext_default): New function.
30808         (quotearg_buffer_restyled): Use
30809         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
30810         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
30811
30812 2000-07-09  Jim Meyering  <meyering@lucent.com>
30813
30814         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
30815         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
30816
30817         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
30818         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
30819
30820 2000-07-09  Jim Meyering  <meyering@lucent.com>
30821
30822         * lib/Most files: Update copyright dates to include 2000.
30823
30824 2000-07-08  Jim Meyering  <meyering@lucent.com>
30825
30826         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
30827         if not defined.
30828         (xgethostname): Remove now-unnecessary #ifdef.
30829         Move declaration of `err' into loop where it's used.
30830
30831 2000-07-05  Paul Eggert  <eggert@twinsun.com>
30832         and Bruno Haible  <haible@clisp.cons.org>
30833
30834         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
30835         only if the test for an object-type mbstate_t fails.  This
30836         prevents us from mistakenly reporting that mbstate_t is a
30837         system object type after we "#define mbstate_t int" to work
30838         around its lack.
30839
30840 2000-07-05  Paul Eggert  <eggert@twinsun.com>
30841         and Bruno Haible  <haible@clisp.cons.org>
30842
30843         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
30844
30845 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
30846
30847         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
30848         to strerror_r.
30849         Include <ctype.h> for use of isalpha.
30850
30851 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
30852
30853         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
30854         by allocating a larger buffer. Test the gethostname return value for
30855         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
30856         returns an error and ENAMETOOLONG isn't defined.
30857
30858 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
30859
30860         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
30861         dimension.
30862
30863 2000-07-04  Jim Meyering  <meyering@lucent.com>
30864
30865         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
30866         of the deprecated AC_CHECKING.
30867
30868 2000-07-04  Jim Meyering  <meyering@lucent.com>
30869
30870         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
30871         Reported by Bruno Haible.
30872
30873 2000-07-04  Jim Meyering  <meyering@lucent.com>
30874
30875         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
30876         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
30877         lacks mbrtowc.
30878
30879 2000-07-03  Paul Eggert  <eggert@twinsun.com>
30880
30881         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
30882         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
30883
30884 2000-07-03  Paul Eggert  <eggert@twinsun.com>
30885         and Bruno Haible  <haible@clisp.cons.org>
30886
30887         * lib/quotearg.c (mbrtowc):
30888         Assign to *pwc, and return 1 only if result is nonzero.
30889         (iswprint): Use ISPRINT when substituting our own mbrtowc.
30890
30891 2000-07-03  Jim Meyering  <meyering@lucent.com>
30892
30893         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
30894
30895 2000-07-03  Jim Meyering  <meyering@lucent.com>
30896
30897         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
30898         This is necessary to get a definition of e.g., UTMP_FILE on
30899         HP-UX 10.20.
30900         From Bob Proulx.
30901
30902 2000-07-02  Jim Meyering  <meyering@lucent.com>
30903
30904         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
30905
30906         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
30907         AC_LIBOBJ(function_name).
30908         * m4/chown.m4: Likewise.
30909         * m4/fnmatch.m4: Likewise.
30910         * m4/ftruncate.m4: Likewise.
30911         * m4/getgroups.m4: Likewise.
30912         * m4/getline.m4: Likewise.
30913         * m4/group-member.m4: Likewise.
30914         * m4/jm-macros.m4: Likewise.
30915         * m4/lstat.m4: Likewise.
30916         * m4/malloc.m4: Likewise.
30917         * m4/memcmp.m4: Likewise.
30918         * m4/nanosleep.m4: Likewise.
30919         * m4/putenv.m4: Likewise.
30920         * m4/realloc.m4: Likewise.
30921         * m4/regex.m4: Likewise.
30922         * m4/stat.m4: Likewise.
30923         * m4/strftime.m4: Likewise.
30924
30925 2000-07-02  Jim Meyering  <meyering@lucent.com>
30926
30927         * lib/quotearg.c (mbstate_t): Don't define here.
30928
30929 2000-07-02  Jim Meyering  <meyering@lucent.com>
30930
30931         * lib/nanosleep.c (SIGCONT): Define if not already defined.
30932
30933 2000-07-01  Jim Meyering  <meyering@lucent.com>
30934
30935         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
30936
30937 2000-07-01  Jim Meyering  <meyering@lucent.com>
30938
30939         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
30940         problem.
30941
30942 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
30943
30944         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
30945         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
30946
30947 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
30948
30949         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
30950         per change in ../m4/ls-mntd-fs.m4.
30951         (read_filesystem_list): Ignore symbolic links.
30952
30953 2000-06-29  Jim Meyering  <meyering@lucent.com>
30954
30955         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
30956         for declaration of strcmp.
30957
30958         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
30959
30960         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
30961         Avoid warning by casting result to `char *' to remove `const'.
30962
30963 2000-06-28  Jim Meyering  <meyering@lucent.com>
30964
30965         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
30966         included by quotearg.c, for which we perform this test.  From
30967         Bruno Haible.
30968
30969 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
30970
30971         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
30972         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
30973         <utmpx.h> exists, put readutmp.o into LIBOBJS.
30974
30975 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
30976
30977         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
30978
30979 2000-06-26  Paul Eggert  <eggert@twinsun.com>
30980
30981         savedir now sets errno on failure and invokes xmalloc to get memory.
30982         Fix a couple of other minor bugs while we're at it.
30983
30984         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
30985         (NAMLEN): Remove macro.
30986         (malloc, realloc): Remove decls.
30987         (stpcpy): Likewise.
30988         ("xalloc.h"): Include.
30989         (NAME_SIZE_DEFAULT): New macro.
30990         (savedir): Use xmalloc / xrealloc to allocate memory.
30991         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
30992         Skip "" directory entries.
30993         Use strlen to calculate directory entry length, since the old method
30994         is rarely used these days and isn't worth supporting.
30995         Don't use a pointer after freeing it.
30996         Check for integer overflow when calculating allocation size.
30997         Use memcpy to copy entries, instead of stpcpy.
30998         Set errno properly when returning NULL.
30999         Check for readdir error.
31000
31001 2000-06-26  Jim Meyering  <meyering@lucent.com>
31002
31003         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
31004
31005 2000-06-25  Jim Meyering  <meyering@lucent.com>
31006
31007         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
31008         Linux header bug when _XOPEN_SOURCE is defined to 500.
31009
31010 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
31011
31012         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
31013         deficiency.
31014
31015 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
31016
31017         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
31018         Include xalloc.h.
31019         Don't include <stdlib.h>.  Don't declare malloc, realloc.
31020
31021 2000-06-24  Jim Meyering  <meyering@lucent.com>
31022
31023         * m4/strerror_r.m4: Revive this file -- to try out an experimental
31024         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
31025         for which strerror does return char*, but which lacks a conveniently
31026         accessible declaration of the function.  If the compile-test says
31027         strerror_r doesn't work, then resort to a `run'-test that works on
31028         BeOS and segfaults on DEC Unix.
31029
31030 2000-06-24  Jim Meyering  <meyering@lucent.com>
31031
31032         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
31033
31034 2000-06-23  Paul Eggert  <eggert@twinsun.com>
31035
31036         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
31037         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
31038
31039 2000-06-23  Paul Eggert  <eggert@twinsun.com>
31040
31041         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
31042         (mbrtowc, mbstate_t): Define substitutes if
31043         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
31044         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
31045         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
31046
31047 2000-06-23  Jim Meyering  <meyering@lucent.com>
31048
31049         * m4/afs.m4: Add missing AC_MSG_RESULT.
31050         Reported by Bruno Haible.
31051
31052         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
31053         Suggestion from Bruno Haible.
31054
31055 2000-06-23  Jim Meyering  <meyering@lucent.com>
31056
31057         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
31058
31059 2000-06-21  Jim Meyering  <meyering@lucent.com>
31060
31061         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
31062
31063 2000-06-21  Jim Meyering  <meyering@lucent.com>
31064
31065         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
31066         (noinst_HEADERS): Add getstr.h.
31067
31068         * lib/getline.c (getstr): Move into a separate file.
31069         * lib/getstr.c (getstr): New file, extracted from getline.c, with
31070         the following changes: new parameter, delim2; both delim[12]
31071         parameters have type `int', not `char'.  The latter would lose
31072         with 8-bit delimiters.
31073         * lib/getstr.h: New file.
31074
31075 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
31076
31077         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
31078         than 1024, return a memory chunk of least possible size, instead
31079         of size PATH_MAX + 2. In the loop, increment the size proportionally.
31080         Use free/xmalloc instead of xrealloc to avoid copying for very long
31081         paths.
31082
31083 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
31084
31085         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
31086         the empty string.
31087
31088 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
31089
31090         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
31091         address, not strdup.  Include <stdlib.h> and don't declare free().
31092
31093 2000-06-19  Jim Meyering  <meyering@lucent.com>
31094
31095         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
31096
31097 2000-06-18  Jim Meyering  <meyering@lucent.com>
31098
31099         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
31100
31101         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
31102         `checking whether...' message to be consistent with that of the
31103         lstat test.
31104
31105 2000-06-18  Jim Meyering  <meyering@lucent.com>
31106
31107         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
31108         Besides, these days every porting target provides a mkdir function.
31109
31110         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
31111         needed. (this snippet comes from src/system.h).
31112
31113 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
31114
31115         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
31116
31117 2000-06-15  Paul Eggert  <eggert@twinsun.com>
31118
31119         * lib/human.c (adjust_value): New function.
31120         (human_readable_inexact): Apply rounding style even when
31121         printing approximate values.
31122
31123 2000-06-14  Paul Eggert  <eggert@twinsun.com>
31124
31125         * lib/human.c (human_readable_inexact): Allow an input block
31126         size that is not a multiple of the output block size, and vice versa.
31127         Reported by Piergiorgio Sartor.
31128
31129 2000-06-14  Paul Eggert  <eggert@twinsun.com>
31130
31131         * lib/getdate.y (get_date): Apply relative times after time
31132         zone indicator, not before.  Reported by Todd A. Jacobs.
31133
31134 2000-06-13  Jim Meyering  <meyering@lucent.com>
31135
31136         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
31137
31138         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
31139
31140 2000-06-12  Paul Eggert  <eggert@twinsun.com>
31141
31142         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
31143
31144 2000-06-12  Jim Meyering  <meyering@lucent.com>
31145
31146         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
31147         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
31148         optional argument.
31149         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
31150         the optional argument, `lib'.
31151
31152 2000-06-08  Jim Meyering  <meyering@lucent.com>
31153
31154         * m4/largefile.m4: Remove file (now that it's part of autoconf).
31155
31156 2000-06-04  Paul Eggert  <eggert@twinsun.com>
31157
31158         Rewrite largefile configuration so that we don't need to run
31159         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
31160         AC_CANONICAL_HOST in configure.in -- jmm]
31161
31162         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
31163         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
31164         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
31165         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
31166         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
31167         All uses changed.
31168         Instead of inspecting the output of getconf, try to compile the
31169         test program without and with the macro definition.
31170         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
31171         for getconf.  Instead, check for the needed flags by compiling
31172         test programs.
31173
31174 2000-06-04  Paul Eggert  <eggert@twinsun.com>
31175
31176         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
31177
31178 2000-06-04  Jim Meyering  <meyering@lucent.com>
31179
31180         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
31181         SunOS 4.1.4 for which gid_t is an unsigned type.
31182
31183 2000-06-03  Jim Meyering  <meyering@lucent.com>
31184
31185         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
31186         now that autoconf requires that.
31187
31188         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
31189         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
31190         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
31191
31192 2000-06-03  Jim Meyering  <meyering@lucent.com>
31193
31194         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
31195
31196 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
31197
31198         * m4/glibc21.m4: New file.
31199         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
31200
31201 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
31202
31203         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
31204         newer, don't install charset.alias.
31205         * lib/config.charset: Change the Linux/glibc rules so they become empty
31206         on glibc-2.1 or newer.
31207
31208 2000-06-02  Jim Meyering  <meyering@lucent.com>
31209
31210         * lib/mountlist.c: Back out last change.  Instead, do this...
31211         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
31212         me_dummy member using the same `ignore'-testing code.
31213         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
31214         fs_type strings.
31215         From Mark D. Roth.
31216
31217 2000-05-29  Jim Meyering  <meyering@lucent.com>
31218
31219         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
31220         mounts with the `ignore' attribute.  Based on a patch from
31221         Mark D. Roth.
31222
31223 2000-05-28  Jim Meyering  <meyering@lucent.com>
31224
31225         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
31226         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
31227         * m4/stat.m4: Likewise.
31228         * m4/lstat.m4: Likewise.
31229         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
31230
31231         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
31232         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
31233
31234 2000-05-26  Jim Meyering  <meyering@lucent.com>
31235
31236         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
31237
31238 2000-05-24  Jim Meyering  <meyering@lucent.com>
31239
31240         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
31241         autoconf requires that.
31242         * m4/lib-check.m4: Likewise.
31243         * m4/jm-macros.m4: Likewise.
31244         * m4/strftime.m4: Likewise.
31245
31246         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
31247         AC_CHECK_DECLS, now that autoconf requires that.
31248
31249 2000-05-22  Jim Meyering  <meyering@lucent.com>
31250
31251         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
31252         * m4/lstat.m4: Likewise.
31253
31254 2000-05-22  Jim Meyering  <meyering@lucent.com>
31255
31256         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
31257
31258 2000-05-20  Jim Meyering  <meyering@lucent.com>
31259
31260         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
31261         (jm_PREREQ): Use it.
31262
31263 2000-05-18  Jim Meyering  <meyering@lucent.com>
31264
31265         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
31266         back, too, since it may have been modified by allocate_entry.
31267         (hash_delete): Rewrite to use neither the assignment operator
31268         nor the comma operator in an if-expression.
31269
31270 2000-05-15  Paul Eggert  <eggert@twinsun.com>
31271
31272         * lib/closeout.c:
31273         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
31274         Remove; no longer needed.
31275         "quotearg.h": Add include.
31276         (file_name): Do not bother to explicitly initialize to NULL; it's less
31277         efficient on some hosts.
31278         (close_stdout_status): Remove test as to whether stdout was already
31279         closed; it breaks for the case "echo x | sort >&-".
31280         Quote file name colons.
31281         Do not assume that _("write error") lacks format strings.
31282
31283 2000-05-15  Jim Meyering  <meyering@lucent.com>
31284
31285         * lib/version-etc.c (version_etc_copyright): Update the copyright
31286         string used in all --version output.
31287
31288 2000-05-14  Jim Meyering  <meyering@lucent.com>
31289
31290         * lib/closeout.c (close_stdout_set_file_name): New function.
31291         (close_stdout_status): Use new file-scoped global.
31292         Return right away if fstat says the stdout file descriptor is invalid.
31293         * lib/closeout.h (close_stdout_set_file_name): Declare.
31294
31295 2000-05-10  Jim Meyering  <meyering@lucent.com>
31296
31297         * lib/closeout.c [default_exit_status]: New file-scoped variable.
31298         (close_stdout_set_status): New function.
31299         * lib/closeout.h (close_stdout_set_status): Declare.
31300
31301 2000-05-09  Jim Meyering  <meyering@lucent.com>
31302
31303         * m4/gettext.m4: Rename this...
31304         * m4/libintl.m4: ...to this.
31305
31306 2000-05-08  Jim Meyering  <meyering@lucent.com>
31307
31308         * lib/long-options.c: Don't include closeout.h.
31309         (parse_long_options): Don't call close_stdout for --version.
31310
31311 2000-05-06  Paul Eggert  <eggert@twinsun.com>
31312
31313         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
31314         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
31315         2.1.3 bug.  This avoids a clash when files like regex.c define
31316         _GNU_SOURCE.
31317
31318 2000-05-06  Jim Meyering  <meyering@lucent.com>
31319
31320         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
31321         (AC_REPLACE_FUNCS): Add strnlen.
31322
31323         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
31324         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
31325
31326         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
31327         AC_SEARCH_LIBS call for nanosleep.
31328         (LIB_NANOSLEEP): Set and AC_SUBST.
31329
31330 2000-05-06  Jim Meyering  <meyering@lucent.com>
31331
31332         * lib/strnlen.c: Undefine __strnlen and strnlen.
31333         [!weak_alias]: Define __strnlen to strnlen.
31334
31335         * lib/atexit.c: New file, from libiberty.
31336
31337 2000-05-06  Jim Meyering  <meyering@lucent.com>
31338
31339         * lib/closeout.c (close_stdout_status): Also check for errors on the
31340         stderr stream.
31341
31342 2000-05-05  Jim Meyering  <meyering@lucent.com>
31343
31344         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
31345         AC_SEARCH_LIBS call for clock_gettime.
31346         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
31347
31348         * m4/search-libs.m4: Update from autoconf.
31349
31350         su doesn't work on Solaris 2.6.
31351         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
31352         <shadow.h>.  Reported by Dragos Harabor.
31353
31354 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
31355
31356         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
31357         memcpy instead of xmalloc, xrealloc, path_concat.
31358         (locale_charset): Treat empty environment variables as absent.
31359         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
31360
31361 2000-05-04  Jim Meyering  <meyering@lucent.com>
31362
31363         * lib/getopt.c: Update from glibc.
31364         * lib/obstack.c: Likewise.
31365         * lib/obstack.h: Likewise.
31366         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
31367         file
31368
31369         * lib/regex.h: Likewise.
31370         * lib/strndup.c: Likewise.
31371         * lib/strnlen.c: New file, from glibc.
31372
31373 2000-05-03  Jim Meyering  <meyering@lucent.com>
31374
31375         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
31376
31377 2000-05-02  Paul Eggert  <eggert@twinsun.com>
31378
31379         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
31380         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
31381         compile-time test, rather than inspecting host and OS, to
31382         decide whether to define _LARGEFILE_SOURCE.
31383
31384 2000-05-01  Jim Meyering  <meyering@lucent.com>
31385
31386         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
31387
31388         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
31389         Based on a patch from Bruno Haible.
31390
31391 2000-05-01  Jim Meyering  <meyering@lucent.com>
31392
31393         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
31394
31395 2000-04-29  Jim Meyering  <meyering@lucent.com>
31396
31397         * lib/path-concat.c: Declare strdup only if it's not defined.
31398         * lib/canon-host.c: Likewise.
31399
31400 2000-04-28  Jim Meyering  <meyering@lucent.com>
31401
31402         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
31403         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
31404         is included first, then limits.h is included by locale.h by libintl.h.
31405         From John David Anglin.
31406
31407 2000-04-25  Jim Meyering  <meyering@lucent.com>
31408
31409         * lib/makepath.c (S_IRWXUGO): Define.
31410         (make_path): Always perform explicit chmod if MODE specifies any
31411         of the `special' permission bits.  Prompted by a bug report against
31412         install from Mate Wierdl and Joost van Baal.
31413
31414 2000-04-18  Jim Meyering  <meyering@lucent.com>
31415
31416         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
31417         (jm_PREREQ): Use it.
31418
31419 2000-04-18  Jim Meyering  <meyering@lucent.com>
31420
31421         * lib/README: New file.
31422
31423         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
31424         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
31425
31426 2000-04-17  Jim Meyering  <meyering@lucent.com>
31427
31428         Get it right :-)
31429         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
31430         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
31431         Suggestion from Akim Demaille.
31432
31433 2000-04-17  Jim Meyering  <meyering@lucent.com>
31434
31435         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
31436         the definition of it to rpl_strftime also defined-away the system's
31437         declaration.
31438
31439 2000-04-15  Jim Meyering  <meyering@lucent.com>
31440
31441         Use `C' to denote so-called `contiguous' files, the same way
31442         that tar does.
31443         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
31444         (ftypelet): Use S_ISCTG.
31445         From Michael Deutschmann.
31446
31447 2000-04-14  Jim Meyering  <meyering@lucent.com>
31448
31449         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
31450         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
31451         clobbered.
31452
31453 2000-04-14  Jim Meyering  <meyering@lucent.com>
31454
31455         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
31456
31457 2000-04-13  Jim Meyering  <meyering@lucent.com>
31458
31459         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
31460         AH_VERBATIM to insert required #ifndef into config.h.in.
31461         Suggestion from Akim Demaille.
31462
31463 2000-04-12  Jim Meyering  <meyering@lucent.com>
31464
31465         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
31466         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
31467         Christian Krackowizer.
31468
31469         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
31470         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
31471         (AC_SYS_LARGEFILE): Require.
31472         (AM_C_PROTOTYPES): Require.
31473
31474 2000-04-08  Jim Meyering  <meyering@lucent.com>
31475
31476         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
31477         names don't conflict.  Reported by Eli Zaretskii.
31478
31479 2000-04-07  Jim Meyering  <meyering@lucent.com>
31480
31481         * lib/putenv.c: Move inclusion of errno.h so it follows that of
31482         sys/types.h, to work around system header problems on AIX 3.2.5.
31483         From Bruno Haible.
31484
31485 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
31486
31487         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
31488         bug.  Deal with the different error behavior of Irix iconv.
31489
31490 2000-04-05  Paul Eggert  <eggert@twinsun.com>
31491
31492         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
31493         IRIX if the installer said otherwise.
31494
31495 2000-04-05  Jim Meyering  <meyering@lucent.com>
31496
31497         Portability tweaks required for ultrix4.3.
31498         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
31499         (jm_CHECK_DECLS): Add getutent to the list of functions.
31500         (_jm_DECL_HEADERS): Add utmpx.h.
31501         From John David Anglin.
31502
31503         * m4/strftime.m4: Back out the 2000-04-02 change.
31504         Instead of that change, simply undefine putenv in the test program.
31505
31506 2000-04-05  Jim Meyering  <meyering@lucent.com>
31507
31508         Portability tweaks required for ultrix4.3.
31509         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
31510         getutent.
31511         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
31512         * lib/canon-host.c: Declare strdup.
31513         * lib/path-concat.c: Likewise.
31514         From John David Anglin.
31515
31516 2000-04-04  Jim Meyering  <meyering@lucent.com>
31517
31518         Be more DOS 8.3-friendly.
31519         * lib/ref-add.sin: Renamed from ref-add.sed.in.
31520         * lib/ref-del.sin: Renamed from ref-del.sed.in.
31521         * lib/Makefile.am: Reflect renaming.
31522         Reported by Eli Zaretskii.
31523
31524         Use a temporary file name that won't clash with `charset.alias'
31525         in the DOS 8.3 name space.
31526         * lib/Makefile.am (charset_tmp): Define.
31527         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
31528         (uninstall-local): Likewise.
31529         Reported by Eli Zaretskii.
31530
31531 2000-04-03  Jim Meyering  <meyering@lucent.com>
31532
31533         * m4/gettext.m4: Fix typo in comment.
31534
31535         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
31536         textutils/configure.in).  Suggestion from Paul Eggert.
31537         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
31538
31539 2000-04-02  Paul Eggert  <eggert@twinsun.com>
31540
31541         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
31542         variable in the shell rather than using putenv, which isn't
31543         portable.  This avoids the configure-time inter-test dependency
31544         on the potentially-renamed putenv function.
31545
31546 2000-03-30  Paul Eggert  <eggert@twinsun.com>
31547
31548         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
31549         before checking struct stat.st_blksize, so that
31550         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
31551
31552 2000-03-29  Paul Eggert  <eggert@twinsun.com>
31553
31554         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
31555         since strftime.c uses HAVE_STRFTIME to decide whether to use
31556         the underlying strftime.
31557
31558 2000-03-29  Paul Eggert  <eggert@twinsun.com>
31559
31560         * lib/time/strftime.c (my_strftime): Make sure we call the system
31561         strftime, not ourselves, when invoking the underlying strftime.
31562
31563 2000-03-24  Jim Meyering  <meyering@lucent.com>
31564
31565         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
31566         (charset_alias): Define.
31567         (install-exec-local): Factor out common code.
31568         (uninstall-local): Split lines longer than 80.
31569         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
31570         (SUFFIXES): Define.
31571         (.sed.in.sed): New rule.  Don't redirect directly to $@.
31572         (CLEANFILES): Add ref-add.sed and ref-del.sed.
31573
31574 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
31575
31576         * lib/config.charset: Output a line containing "Packages using this
31577         file".
31578         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
31579         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
31580         ref-del.sed): New rules.
31581
31582 2000-03-17  Jim Meyering  <meyering@lucent.com>
31583
31584         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
31585         Otherwise, include <strings.h>
31586
31587 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
31588
31589         * lib/unicodeio.c (utf8_wctomb): New function.
31590         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
31591         format instead of in UCS-4 with platform dependent endianness.
31592
31593 2000-03-10  Jim Meyering  <meyering@lucent.com>
31594
31595         * m4/lib-check.m4: Look for getspnam in -lgen, too.
31596         From Marco Franzen.
31597
31598 2000-03-07  Paul Eggert  <eggert@twinsun.com>
31599
31600         * lib/savedir.c (savedir): Work even if directory size is
31601         negative; this can happen with some screwy NFS configurations.
31602
31603 2000-03-06  Jim Meyering  <meyering@lucent.com>
31604
31605         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
31606         if it's NULL (because we ran out of memory).  From Bruno Haible.
31607
31608 2000-03-05  Jim Meyering  <meyering@lucent.com>
31609
31610         * lib/localcharset.c ("path-concat.h"): Include.
31611         (get_charset_aliases): Use path_concat instead of ANSI string
31612         concatenation.
31613
31614         * lib/unicodeio.h (PARAMS): Define.
31615         Use it to guard prototype.
31616
31617 2000-03-04  Jim Meyering  <meyering@lucent.com>
31618
31619         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
31620         for lib/localcharset.c.
31621
31622 2000-03-04  Jim Meyering  <meyering@lucent.com>
31623
31624         * lib/Makefile.am (install-exec-local): Create $(libdir) before
31625         installing into it.
31626         (uninstall-local): Uncomment this rule so `make distcheck' works
31627         once again.
31628
31629         * lib/unicodeio.c (<errno.h>): Include it.
31630         (errno): Declare if not defined.
31631
31632         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
31633
31634         * lib/config.charset: New version, incorporating remarks from a linux
31635         i18n mailing list.  From Bruno Haible.
31636
31637 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
31638
31639         * m4/codeset.m4: New file.
31640         * m4/iconv.m4: New file.
31641         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
31642
31643 2000-03-03  Jim Meyering  <meyering@lucent.com>
31644
31645         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
31646
31647 2000-03-02  Jim Meyering  <meyering@lucent.com>
31648
31649         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
31650         the messages come out on separate lines.
31651
31652         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
31653         rather than jm_CHECK_DECLARATIONS.
31654         * m4/decl.m4: Remove now-unused file.
31655
31656         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
31657         geteuid.
31658
31659 2000-03-02  Jim Meyering  <meyering@lucent.com>
31660
31661         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
31662
31663 2000-03-01  Jim Meyering  <meyering@lucent.com>
31664
31665         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
31666         * lib/unicodeio.c: Likewise.
31667
31668 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
31669
31670         * lib/config.charset: New file.
31671         * lib/localcharset.c: New file.
31672         * lib/unicodeio.h, lib/unicodeio.c: New files.
31673         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
31674         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
31675         (noinst_HEADERS): Add unicodeio.h.
31676         (all-local, install-exec-local, charset.alias): New targets.
31677
31678 2000-02-28  Paul Eggert  <eggert@twinsun.com>
31679
31680         * lib/quotearg.c (ALERT_CHAR): New macro.
31681         (quotearg_buffer_restyled): Use it.
31682
31683 2000-02-27  Jim Meyering  <meyering@lucent.com>
31684
31685         * m4/check-decl.m4: Add getenv to the list.
31686
31687 2000-02-27  Jim Meyering  <meyering@lucent.com>
31688
31689         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
31690         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
31691
31692         * lib/backupfile.c: Guard inclusion of stdlib.h with
31693         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
31694         Declare malloc if needed.
31695
31696         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
31697         `#ifndef HAVE_DECL..'
31698         now that autoconf always defines the HAVE_DECL_ symbols.
31699         * lib/human.c: Likewise.
31700         * lib/same.c: Likewise.
31701         * lib/strtoumax.c: Likewise.
31702
31703         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
31704         declaration check was not run.
31705         * lib/hash.c: Likewise.
31706         * lib/human.c: Likewise.
31707         * lib/same.c: Likewise.
31708         * lib/strtoumax.c: Likewise.
31709
31710         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
31711         `.', then first look up the entire `.'-containing string as a login
31712         name.
31713
31714 2000-02-23  Jim Meyering  <meyering@lucent.com>
31715
31716         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
31717         in place of my hack.
31718
31719 2000-02-18  Paul Eggert  <eggert@twinsun.com>
31720
31721         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
31722         (textint): New typedef.
31723         (parser_control): Member year changed from int to textint.
31724         All uses changed.
31725         (YYSTYPE): Removed; replaced by %union with int and textint members.
31726         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
31727         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
31728         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
31729         (tSNUMBER, tUNUMBER): Now of type <textintval>.
31730         (date, number, to_year): Use width of number in digits, not its value,
31731         to determine whether it's a 2-digit year, or a 2-digit time.
31732         (yylex): Store number of digits of numeric tokens.
31733         Reported by John Kendall.
31734
31735         (parser_control): Changed from struct parser_control to typedef (for
31736         consistency).  All uses changed.
31737
31738         (tID): Removed; not used.
31739         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
31740
31741 2000-02-14  Paul Eggert  <eggert@twinsun.com>
31742
31743         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
31744         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
31745
31746 2000-02-12  Jim Meyering  <meyering@lucent.com>
31747
31748         * lib/userspec.c (ISDIGIT): Define it.
31749         (isdigit): Remove definition.
31750         (is_number): Use ISDIGIT, not isdigit.
31751         <libintl.h>: Include.
31752         (_ and N_): Define.
31753         (parse_user_spec): Mark translatable strings.
31754
31755 2000-02-10  Jim Meyering  <meyering@lucent.com>
31756
31757         With these changes, nanosleep.[ch] are finally enough like the other
31758         lib/* replacement files to compile on a few more losing systems.
31759
31760         * lib/nanosleep.h: Don't include config.h.
31761         Remove prototype from declaration of nanosleep.
31762         (PARAMS): Remove now-unneeded definition.
31763         * lib/nanosleep.c: #undef nanosleep.
31764         (rpl_nanosleep): Rename from nanosleep.
31765
31766 2000-02-10  Jim Meyering  <meyering@lucent.com>
31767
31768         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
31769         gnu_nanosleep to rpl_nanosleep.
31770
31771 2000-02-09  Jim Meyering  <meyering@lucent.com>
31772
31773         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
31774         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
31775
31776 2000-02-08  Akim Demaille  <akim@epita.fr>
31777
31778         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
31779         `[' and `]' and remove uses of `changequote'.
31780         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
31781         (AC_SYS_LARGEFILE): Likewise.
31782         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
31783         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
31784         of changequote.
31785         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
31786         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
31787         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
31788         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
31789
31790 2000-02-05  Jim Meyering  <meyering@lucent.com>
31791
31792         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
31793         Remove explicit use of AC_HEADER_TIME.  It is required by
31794         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
31795         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
31796         in autoconf whereby the expansion of the latter ended up preceding
31797         the expansion of its prerequisite, AC_HEADER_TIME.
31798         Reported by Volker Borchert.
31799
31800 2000-02-03  Jim Meyering  <meyering@lucent.com>
31801
31802         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
31803
31804 2000-02-03  Jim Meyering  <meyering@lucent.com>
31805
31806         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
31807         rather than with `#if HAVE_UTMPNAME'.
31808
31809 2000-02-02  Jim Meyering  <meyering@lucent.com>
31810
31811         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
31812         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
31813         Reported by Eli Zaretskii.
31814
31815 2000-02-01  Jim Meyering  <meyering@lucent.com>
31816
31817         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
31818
31819 2000-01-31  Jim Meyering  <meyering@lucent.com>
31820
31821         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
31822         functions.  Add the time.h and sys/time.h headers along with the
31823         AC_REQUIRE'ment of AC_HEADER_TIME.
31824
31825 2000-01-31  Jim Meyering  <meyering@lucent.com>
31826
31827         * lib/nanosleep.h (nanosleep): Guard declaration with
31828         `#if ! HAVE_DECL_NANOSLEEP'.
31829         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
31830         the declaration in that vendor's sys/timers.h.
31831         Reported by Christian Krackowizer.
31832
31833         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
31834         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
31835         (ISPRINT): Likewise.
31836         Reported by Tom Tromey.
31837
31838 2000-01-30  Jim Meyering  <meyering@lucent.com>
31839
31840         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
31841
31842         * m4/prereq.m4 (utmp_includes): Define.
31843         Check for ut_user and ut_name members in both struct utmpx
31844         and struct utmp.
31845
31846 2000-01-30  Jim Meyering  <meyering@lucent.com>
31847
31848         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
31849         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
31850         header files where only utmpx.ut_user is declared.
31851
31852         * lib/readutmp.h (UT_USER): Define.
31853
31854 2000-01-29  Jim Meyering  <meyering@lucent.com>
31855
31856         * m4/lib-check.m4: New file containing library-related checks from
31857         fileutils and sh-utils (textutils had none).
31858
31859 2000-01-28  Jim Meyering  <meyering@lucent.com>
31860
31861         * m4/perl.m4: Change format of warning message to look more like that
31862         from the missing script.  Suggestion from François Pinard.
31863
31864 2000-01-25  Jim Meyering  <meyering@lucent.com>
31865
31866         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
31867         well as time.h in the compile check.
31868         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
31869         Fix typo in cross-compiling case: s/yes/no/.
31870
31871 2000-01-23  Jim Meyering  <meyering@lucent.com>
31872
31873         * m4/jm-macros.m4: Move df-related tests here from
31874         fileutils/configure.in
31875
31876         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
31877         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
31878
31879         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
31880         s/space/ac_fsusage_space/.
31881         (jm_FILE_SYSTEM_USAGE): Take two parameters.
31882
31883         * m4/ftruncate.m4: New file (derived from part of
31884         fileutils/configure.in).
31885         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
31886         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
31887
31888         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
31889         AC_SUBST these here, rather than just in sh-util/configure.in, so
31890         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
31891         all the same.
31892         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
31893         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
31894         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
31895         (AC_SUBST(POW_LIBM)): Likewise.
31896         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
31897
31898 2000-01-23  Jim Meyering  <meyering@lucent.com>
31899
31900         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
31901         obstack.c.
31902
31903 2000-01-22  Jim Meyering  <meyering@lucent.com>
31904
31905         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
31906
31907         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
31908
31909         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
31910         configure.in
31911         (AC_CHECK_HEADERS): Likewise for sh-utils.
31912         (AC_CHECK_HEADERS): Likewise for textutils.
31913         Merge the three lists of headers.
31914
31915         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
31916         from fileutils' configure.in.
31917
31918         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
31919         code. Moved tests into their own function (_jm_DECL_HEADERS) in
31920         check-decl.m4.
31921
31922         * m4/check-decl.m4: Use #if rather than #ifdef.
31923         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
31924         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
31925         (_jm_DECL_HEADERS): Define new function.
31926         (jm_CHECK_DECLARATIONS): Require it.
31927
31928 2000-01-22  Jim Meyering  <meyering@lucent.com>
31929
31930         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
31931         [! HAVE_DECL_STRTOULL]: Declare strtoull.
31932         Required for some AIX systems.  Reported by Christian Krackowizer.
31933         [TESTING] (main): New function.
31934
31935         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
31936         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
31937         letters.
31938
31939         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
31940         iswprint.
31941
31942         * lib/strverscmp.c (ISDIGIT): Define.
31943         (strverscmp): Use ISDIGIT, not isdigit.
31944
31945 2000-01-19  Jim Meyering  <meyering@lucent.com>
31946
31947         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
31948         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
31949         defines `struct timespec' in <sys/time.h>
31950
31951         * m4/c-bs-a.m4: Remove uses of changequote altogether.
31952         Thanks to Akim for explaining.
31953
31954 2000-01-17  Paul Eggert  <eggert@twinsun.com>
31955
31956         * lib/nanosleep.c (nanosleep):
31957         Don't use SA_INTERRUPT to decide whether to call sigaction, as
31958         POSIX.1 doesn't require SA_INTERRUPT and some systems
31959         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
31960         it's been part of POSIX.1 since day 1 (in 1988).
31961
31962 2000-01-17  Jim Meyering  <meyering@lucent.com>
31963
31964         * lib/interlock: Remove unused file.  Reported by François Pinard.
31965
31966 2000-01-16  Paul Eggert  <eggert@twinsun.com>
31967
31968         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
31969         alert, backslash, formfeed, and vertical tab unnecessarily in
31970         shell quoting style.
31971
31972 2000-01-16  Jim Meyering  <meyering@lucent.com>
31973
31974         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
31975         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
31976         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
31977         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
31978
31979 2000-01-16  Jim Meyering  <meyering@lucent.com>
31980
31981         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
31982         because the latter didn't work.
31983
31984 2000-01-15  Jim Meyering  <meyering@lucent.com>
31985
31986         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
31987         (AC_REPLACE_FUNCS): Add memcpy and memset.
31988         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
31989         Add strpbrk.
31990         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
31991
31992 2000-01-12  Jim Meyering  <meyering@lucent.com>
31993
31994         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
31995         (jm_PREREQ): Use it.
31996         (jm_PREREQ_READUTMP): New macro.
31997         (jm_PREREQ): Use it.
31998
31999 2000-01-11  Paul Eggert  <eggert@twinsun.com>
32000
32001         Quote multibyte characters correctly.
32002         * m4/c-bs-a.m4: New file.
32003         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
32004         (jm_PREREQ): Use it.
32005
32006 2000-01-11  Paul Eggert  <eggert@twinsun.com>
32007
32008         * m4/uintmax_t.m4: Port to autoconf 2.13.
32009
32010 2000-01-08  Jim Meyering  <meyering@ascend.com>
32011
32012         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
32013         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
32014
32015 2000-01-04  Jim Meyering  <meyering@ascend.com>
32016
32017         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
32018         jm_STRUCT_DIRENT_D_TYPE.
32019         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
32020         jm_STRUCT_DIRENT_D_INO.
32021         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
32022         jm_STRUCT_UTIMBUF.
32023         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
32024         renamings.
32025         * m4/utime.m4: Likewise.
32026
32027         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
32028         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
32029
32030 2000-01-03  Paul Eggert  <eggert@twinsun.com>
32031
32032         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
32033         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
32034
32035 2000-01-02  Jim Meyering  <meyering@ascend.com>
32036
32037         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
32038         remember if this is necessary.
32039
32040 1999-12-26  Jim Meyering  <meyering@ascend.com>
32041
32042         * m4/jm-macros.m4: Use it here.
32043         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
32044
32045 1999-12-23  Jim Meyering  <meyering@ascend.com>
32046
32047         * m4/jm-macros.m4: Check for clock_gettime (moved from
32048         fileutils/configure.in)
32049         Check for gettimeofday.
32050
32051 1999-12-20  Jim Meyering  <meyering@ascend.com>
32052
32053         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
32054         autoconf-2.14a-1999-12-20.
32055
32056 1999-12-19  Jim Meyering  <meyering@ascend.com>
32057
32058         * m4/lstat-slash.m4: New file.
32059         * m4/jm-macros.m4: Use the new macro:
32060         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
32061
32062 1999-12-07  Jim Meyering  <meyering@ascend.com>
32063
32064         * m4/perl.m4: Require that File::Compare be available, too.
32065         Too many systems seem to lack it.
32066
32067         * m4/strftime.m4: Add checks for most of the cpp macros tested in
32068         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
32069
32070 1999-11-18  Paul Eggert  <eggert@twinsun.com>
32071
32072         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
32073         problem with the QNX 4.25 shell, which doesn't propagate exit
32074         status of failed commands inside shell assignments.
32075
32076 1999-11-17  Jim Meyering  <meyering@ascend.com>
32077
32078         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
32079
32080 1999-11-07  Jim Meyering  <meyering@ascend.com>
32081
32082         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
32083
32084 1999-11-06  Jim Meyering  <meyering@ascend.com>
32085
32086         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
32087         * m4/jm-macros.m4 (jm_MACROS): Use it here.
32088
32089 1999-11-05  Jim Meyering  <meyering@ascend.com>
32090
32091         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
32092         configure.in of textutils, fileutils, and sh-utils into this one
32093         (shared between those packages) file.
32094         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
32095         AC_STRUCT_ST_BLKSIZE.
32096
32097 1999-11-03  Jim Meyering  <meyering@ascend.com>
32098
32099         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
32100         of AC_CHECK_TYPE checks includes unistd.h.
32101         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
32102         Suggestion from Akim Demaille.
32103
32104 1999-10-30  Jim Meyering  <meyering@ascend.com>
32105
32106         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
32107         m4-quoted string.
32108         * m4/ls-mntd-fs.m4: Likewise.
32109         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
32110         * m4/jm-winsz1.m4: Likewise.
32111
32112         * m4/const.m4: Remove file, since the fix made it into the experimental
32113         version of autoconf.
32114         * m4/mktime.m4: Likewise.
32115
32116         * m4/check-type.m4: Remove file, now that the latest version of
32117         AC_CHECK_TYPE takes a third arg to specify additional #includes.
32118
32119         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
32120         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
32121         AC_CHECK_TYPE.
32122
32123 1999-10-04  Jim Meyering  <meyering@ascend.com>
32124
32125         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
32126
32127 1999-09-22  Paul Eggert  <eggert@twinsun.com>
32128
32129         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
32130         2.95.1 bug with HP-UX 10.20.
32131
32132 1999-09-17  Jim Meyering  <meyering@ascend.com>
32133
32134         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
32135         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
32136         due to missing strdup (against sh-utils-2.0).
32137
32138 1999-08-29  Jim Meyering  <meyering@ascend.com>
32139
32140         * m4/jm-macros.m4: Require jm_BISON.
32141         * m4/bison.m4: New file.
32142
32143 1999-08-17  Paul Eggert  <eggert@twinsun.com>
32144
32145         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
32146         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
32147
32148 1999-08-05  Jim Meyering  <meyering@ascend.com>
32149
32150         * m4/getline.m4: Rename test file from conftestdata to conftest.data
32151         to avoid conflicts with `conftest' on 8+3 filesystems.
32152         Suggestion from Eli Zaretskii.
32153
32154 1999-08-04  Jim Meyering  <meyering@ascend.com>
32155
32156         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
32157         fileutils and sh-utils (textutils's getline test was inadequate).
32158         (AM_FUNC_GETLINE): Run this test.
32159         (AC_CHECK_FUNCS): Check for getdelim.
32160         Reported by Bob Proulx.
32161
32162 1999-08-02  Jim Meyering  <meyering@ascend.com>
32163
32164         * m4/jm-macros.m4: Add a comment.
32165
32166 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32167
32168         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
32169         <inttypes.h> defines strtoumax as a macro (and not as a
32170         function).
32171
32172 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32173
32174         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
32175         that we can shift, multiply and divide unsigned long long
32176         values; Ultrix cc can't do it.
32177
32178 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32179
32180         * m4/mktime.m4: New file, which is a preview of what should appear
32181         in the next public autoconf release.
32182
32183 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32184
32185         * m4/lfs.m4: Remove this file.
32186         * m4/largefile.m4: New file.  It contains the old contents of
32187         lfs.m4, except that all names with prefix AC_LFS have been
32188         changed to use the prefix AC_SYS_LARGEFILE instead, to be
32189         compatible with future autoconf versions.  Also, some minor m4
32190         quoting problems have been fixed.
32191
32192 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32193
32194         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
32195         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
32196         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
32197         and simplify the shell code.
32198
32199 1999-08-01  Jim Meyering  <meyering@ascend.com>
32200
32201         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
32202         m4.
32203
32204 1999-07-20  Jim Meyering  <meyering@ascend.com>
32205
32206         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
32207
32208 1999-07-15  Jim Meyering  <meyering@ascend.com>
32209
32210         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
32211
32212 1999-05-22  Jim Meyering  <meyering@ascend.com>
32213
32214         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
32215
32216 1999-05-20  Jim Meyering  <meyering@ascend.com>
32217
32218         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
32219         Add a colon after each `then' in case $4 is empty.
32220
32221 1999-05-16  Jim Meyering  <meyering@ascend.com>
32222
32223         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
32224
32225 1999-05-10  Jim Meyering  <meyering@ascend.com>
32226
32227         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
32228
32229         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
32230         AC_FUNC_MKTIME.
32231
32232 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
32233
32234         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
32235
32236 1999-05-04  Paul Eggert  <eggert@twinsun.com>
32237
32238         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
32239         not CPPFLAGS, so that linking works correctly in IRIX.
32240
32241 1999-04-30  Paul Eggert  <eggert@twinsun.com>
32242
32243         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
32244
32245 1999-04-20  Paul Eggert  <eggert@twinsun.com>
32246
32247         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
32248         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
32249         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
32250         jm_AC_TYPE_UNSIGNED_LONG_LONG.
32251         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
32252
32253         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
32254
32255 1999-04-20  Jim Meyering  <meyering@ascend.com>
32256
32257         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
32258         AC_REPLACE xstroull if necessary.  From Paul Eggert.
32259         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
32260
32261 1999-04-18  Jim Meyering  <meyering@ascend.com>
32262
32263         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
32264         * m4/jm-macros.m4: Use it.
32265
32266 1999-04-06  Jim Meyering  <meyering@ascend.com>
32267
32268         * m4/strftime.m4: Remove test for %f.
32269
32270 1999-03-29  Jim Meyering  <meyering@ascend.com>
32271
32272         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
32273         superset of the AC_TYPE_* checks in the textutils, fileutils,
32274         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
32275         AC_TYPE_PID_T.
32276
32277 1999-03-28  Jim Meyering  <meyering@ascend.com>
32278
32279         * m4/jm-macros.m4: Define GNU_PACKAGE here.
32280         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
32281         replaced e.g., in the *.sh files of the sh-utils.
32282
32283 1999-03-20  Jim Meyering  <meyering@ascend.com>
32284
32285         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
32286         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
32287         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
32288
32289 1999-03-19  Jim Meyering  <meyering@ascend.com>
32290
32291         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
32292
32293 1999-03-12  Jim Meyering  <meyering@ascend.com>
32294
32295         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
32296
32297 1999-03-07  Jim Meyering  <meyering@ascend.com>
32298
32299         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
32300         declared.
32301
32302 1999-02-17  Jim Meyering  <meyering@ascend.com>
32303
32304         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
32305         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
32306
32307 1999-02-07  Jim Meyering  <meyering@ascend.com>
32308
32309         * m4/group-member.m4: New file -- extracted from sh-utils'
32310         configure.in.
32311
32312         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
32313         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
32314
32315 1999-02-06  Jim Meyering  <meyering@ascend.com>
32316
32317         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
32318         * m4/fnmatch.m4: Likewise.
32319         * m4/getgroups.m4: Likewise.
32320         * m4/lstat.m4: Likewise.
32321         * m4/malloc.m4: Likewise.
32322         * m4/putenv.m4: Likewise.
32323         * m4/realloc.m4: Likewise.
32324         * m4/regex.m4: Likewise.
32325         * m4/stat.m4: Likewise.
32326         * m4/strftime.m4: Likewise.
32327         Suggestion from Alain Magloire.
32328
32329         * m4/chown.m4: Use `.$ac_objext', not `.o'.
32330         * m4/fnmatch.m4: Likewise.
32331         * m4/getgroups.m4: Likewise.
32332         * m4/getline.m4: Likewise.
32333         * m4/lstat.m4: Likewise.
32334         * m4/malloc.m4: Likewise.
32335         * m4/memcmp.m4: Likewise.
32336         * m4/putenv.m4: Likewise.
32337         * m4/realloc.m4: Likewise.
32338         * m4/regex.m4: Likewise.
32339         * m4/stat.m4: Likewise.
32340         * m4/strftime.m4: Likewise.
32341         Suggestion from Alain Magloire.
32342
32343         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
32344         an argument.
32345
32346         * m4/regex.m4: Add a run-time Test for proper operation of
32347         re_compile_pattern.
32348
32349 1999-01-31  Jim Meyering  <meyering@ascend.com>
32350
32351         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
32352
32353 1999-01-30  Jim Meyering  <meyering@ascend.com>
32354
32355         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
32356
32357         * m4/jm-mktime.m4: Make this a wrapper around the official
32358         AM_FUNC_MKTIME rather than my private copy, now that the official one
32359         is up to date.
32360         * m4/mktime.m4: Remove file.
32361
32362         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
32363         * m4/uptime.m4: Likewise.
32364         * m4/uintmax_t.m4: Likewise.
32365
32366 1999-01-28  Jim Meyering  <meyering@ascend.com>
32367
32368         * m4/jm-macros.m4: Use jm_AFS.
32369         * m4/afs.m4: New file (from fileutils' configure.in).
32370
32371         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
32372         * m4/chown.m4: Likewise.
32373         * m4/d-ino.m4: Likewise.
32374         * m4/d-type.m4: Likewise.
32375         * m4/fnmatch.m4: Likewise.
32376         * m4/getgroups.m4: Likewise.
32377         * m4/gettext.m4: Likewise.
32378         * m4/jm-mktime.m4: Likewise.
32379         * m4/jm-winsz2.m4: Likewise.
32380         * m4/lcmessage.m4: Likewise.
32381         * m4/ls-mntd-fs.m4: Likewise.
32382         * m4/malloc.m4: Likewise.
32383         * m4/memcmp.m4: Likewise.
32384         * m4/putenv.m4: Likewise.
32385         * m4/realloc.m4: Likewise.
32386         * m4/st_mtim.m4: Likewise.
32387         * m4/strftime.m4: Likewise.
32388
32389 1999-01-16  Jim Meyering  <meyering@ascend.com>
32390
32391         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
32392         (ARGMATCH_DIE_DECL): Define.
32393
32394 1999-01-12  Jim Meyering  <meyering@ascend.com>
32395
32396         * m4/Makefile.am.in: Rewrite to avoid using fmt.
32397         Reported by Lars Hecking.
32398
32399 1999-01-10  Jim Meyering  <meyering@ascend.com>
32400
32401         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
32402         gross kludge.
32403         * m4/inttypes_h.m4: Likewise.
32404         * m4/lstat.m4: Likewise.
32405         * m4/malloc.m4: Likewise.
32406         * m4/readdir.m4: Likewise.
32407         * m4/realloc.m4: Likewise.
32408         * m4/st_dm_mode.m4: Likewise.
32409         * m4/stat.m4: Likewise.
32410         * m4/utimbuf.m4: Likewise.
32411         * m4/utimes.m4: Likewise.
32412
32413         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
32414         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
32415         comments in config.h.in are meaningful.
32416
32417         * m4/jm-macros.m4: Require autoconf-2.13 here.
32418
32419         * m4/regex.m4: By default, don't use the included regex.c on systems
32420         with glibc 2.  Suggestion from Uli Drepper.
32421
32422 1999-01-02  Jim Meyering  <meyering@ascend.com>
32423
32424         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
32425
32426 1998-12-18  Jim Meyering  <meyering@ascend.com>
32427
32428         * m4/Makefile.am.in (Makefile.am): Simplify rule.
32429         Based on a suggestion from Lars Hecking.
32430
32431 1998-11-16  Paul Eggert  <eggert@twinsun.com>
32432
32433         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
32434
32435 1998-11-16  Jim Meyering  <meyering@ascend.com>
32436
32437         * m4/lfs.m4: Double-quote the `uname...` expression.
32438
32439 1998-11-14  Jim Meyering  <meyering@ascend.com>
32440
32441         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
32442         * m4/stat.m4: Likewise.
32443
32444 1998-11-03  Jim Meyering  <meyering@ascend.com>
32445
32446         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
32447         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
32448
32449 1998-10-18  Jim Meyering  <meyering@ascend.com>
32450
32451         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
32452
32453 1998-10-17  Jim Meyering  <meyering@ascend.com>
32454
32455         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
32456         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
32457         calls for those previously hard-coded headers.  Instead, take a new
32458         parameter.
32459         (jm_CHECK_DECLARATIONS): Reflect interface change.
32460         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
32461         (jm_CHECK_DECL_LOCALTIME_R): New macro.
32462
32463         * m4/mktime.m4: Test for spring-forward gap before long-running test.
32464
32465 1998-10-14  Jim Meyering  <meyering@ascend.com>
32466
32467         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
32468         instead of "TZ=America/Vancouver".  From Paul Eggert.
32469
32470 1998-10-11  Jim Meyering  <meyering@ascend.com>
32471
32472         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
32473         This adds a test for a recently added compatibility fix for mktime.c.
32474         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
32475
32476 1998-09-27  Jim Meyering  <meyering@ascend.com>
32477
32478         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
32479
32480         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
32481         ../configure.in, including a change from Gordon Matzigkeit to allow
32482         cross-compiling for the Hurd.
32483
32484         * m4/glibc.m4: New file/macro to test for the GNU C Library
32485         versions 1 and 2.  From Gordon Matzigkeit.
32486         Indent.
32487
32488 1998-09-21  Jim Meyering  <meyering@ascend.com>
32489
32490         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
32491
32492 1998-08-18  Paul Eggert  <eggert@twinsun.com>
32493
32494         Port nanosecond-resolution times to UnixWare 2.1.2 and
32495         pedantic Solaris 2.6.
32496
32497         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
32498         AC_STRUCT_ST_MTIM.
32499         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
32500         Generate name of ns member, instead of just 1 or undef.
32501         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
32502
32503 1998-08-15  Jim Meyering  <meyering@ascend.com>
32504
32505         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
32506         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
32507         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
32508         instead of jm_TYPE_SSIZE_T.
32509
32510 1998-08-12  Jim Meyering  <meyering@ascend.com>
32511
32512         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
32513
32514 1998-08-02  Jim Meyering  <meyering@ascend.com>
32515
32516         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
32517         in acconfig.h manually.
32518
32519 1998-07-31  Paul Eggert  <eggert@twinsun.com>
32520
32521         * m4/st_mtim.m4: New file.
32522
32523 1998-07-28  Jim Meyering  <meyering@ascend.com>
32524
32525         * m4/utimes.m4: Undef stat.
32526
32527 1998-07-25  Jim Meyering  <meyering@ascend.com>
32528
32529         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
32530         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
32531
32532 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
32533
32534         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
32535         uid and gid actually remain unchanged.
32536
32537 1998-07-07  Jim Meyering  <meyering@ascend.com>
32538
32539         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
32540
32541 1998-07-04  Jim Meyering  <meyering@ascend.com>
32542
32543         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
32544         to prove that this macro can be used in packages without regex.c.
32545
32546 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
32547
32548         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
32549         is to be used.
32550
32551 1998-07-03  Jim Meyering  <meyering@ascend.com>
32552
32553         * m4/gettext.m4: Add -lintl if it's found to be necessary.
32554
32555         * m4/gettext.m4: New file -- from gettext-0.10.35.
32556         * m4/lcmessage.m4: Likewise.
32557         * m4/progtest.m4: Likewise.
32558
32559         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
32560         * m4/jm-macros.m4: Require the new macro.
32561
32562 1998-06-29  Jim Meyering  <meyering@ascend.com>
32563
32564         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
32565         for the definition of NGROUPS (used in a system header included
32566         by sys/mount.h).
32567
32568 1998-06-28  Jim Meyering  <meyering@ascend.com>
32569
32570         * m4/ls-mntd-fs.m4: New file.
32571         * m4/fstypename.m4: New file.
32572
32573         * m4/jm-macros.m4: Require the new macro.
32574         * m4/jm-glibc-io.m4: New file.
32575
32576 1998-05-19  Jim Meyering  <meyering@ascend.com>
32577
32578         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
32579         * m4/lchown.m4: New file.
32580
32581         * m4/Makefile.am.in: New file.
32582         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
32583
32584 1998-05-14  Jim Meyering  <meyering@ascend.com>
32585
32586         * m4/Makefile.am (EXTRA_DIST): Add them.
32587         * m4/jm-macros.m4: New file.
32588         * m4/utimbuf.m4: New file.
32589
32590 1998-05-12  Jim Meyering  <meyering@ascend.com>
32591
32592         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
32593
32594 1998-05-11  Jim Meyering  <meyering@ascend.com>
32595
32596         * m4/isc-posix.m4: New file.
32597
32598 1998-05-10  Jim Meyering  <meyering@ascend.com>