4fab78f25fe89c087f3a290b758702be56ba86ea
[gnulib.git] / ChangeLog
1 2007-09-08  Bruno Haible  <bruno@clisp.org>
2
3         * m4/inttypes-h.m4: Remove stub file.
4
5 2007-09-07  Simon Josefsson  <simon@josefsson.org>
6
7         * doc/headers/stdint.texi: Discuss #include_next issue.
8
9 2007-09-06  Paul Eggert  <eggert@cs.ucla.edu>
10
11         * build-aux/bootstrap: Remove obsolete comment about wget --help.
12
13 2007-09-06  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
14
15         * m4/time_h.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Fix misspelling
16         in variable name.
17
18 2007-09-03  Jim Meyering  <jim@meyering.net>
19
20         New module: git-version-gen.
21         * modules/git-version-gen: New file.
22
23         Import changes from coreutils for bootstrap script.
24
25         * build-aux/bootstrap (WGET_COMMAND): Remove code to set this variable.
26
27         bootstrap: uses rsync to download the .po files
28         * build-aux/bootstrap (po_download_command_format): New global.
29         (download_po_files): Use rsync.
30         (update_po_files): Don't remove .po files after download,
31         so future rsync runs can take advantage of the copies.
32
33         * build-aux/bootstrap (gnulib_tool): Make sha1sum check quietly.
34
35         Solve the unnecessary-.po-file-regeneration problem once and for all.
36         * build-aux/bootstrap (download_po_files): New function, renamed from
37         get_translations.  Now, downloads, but doesn't update LINGUAS.
38         (update_po_files): New function.
39
40         bootstrap: Ignore more.
41         * build-aux/bootstrap (symlink_to_dir): Add a directory name like
42         uniwidth to e.g., lib/.gitignore.
43         (slurp): Handle the sys_stat_.h -> sys mapping, too.
44
45         * build-aux/bootstrap: New setting: vc_ignore.
46         (insert_sorted_if_absent): Create $file if absent.
47         Adapt to new, possibly empty, list: $vc_ignore.
48
49         bootstrap: generate more ignorable names
50         * build-aux/bootstrap (slurp): When generating ignorable names,
51         also map .sin to .sed, .gperf to .c, and .y to .c.
52
53 2007-09-03  Jim Meyering  <jim@meyering.net>
54
55         * build-aux/git-version-gen: New file, from coreutils.  For details, see
56         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commitdiff;h=bfe49f506
57
58 2007-09-02  Bruno Haible  <bruno@clisp.org>
59
60         Fix mis-recognition of 'mcs' on QNX 6.
61         * m4/csharpcomp.m4 (gt_CSHARPCOMP): Test whether the "mcs --version"
62         output contains the string "Mono".
63         * lib/csharpcomp.c (compile_csharp_using_mono): Likewise.
64         Reported by <kraai@ftbfs.org> at <https://savannah.gnu.org/bugs/?18337>.
65
66 2007-09-01  Bruno Haible  <bruno@clisp.org>
67
68         Fix collision between uniwidth/* and linebreak modules.
69         * lib/linebreak.h (locale_charset, uc_width, u8_width, u16_width,
70         u32_width): Remove declarations.
71         * lib/linebreak.c: Include uniwidth.h, uniwidth/cjk.h, streq.h.
72         (u32_mbtouc_unsafe, streq9, streq8, streq7, streq6, streq5, streq4,
73         streq3, streq2, streq1, streq0): Remove functions.
74         (STREQ): Remove macro.
75         (is_cjk_encoding): Remove function.
76         (nonspacing_table_data, nonspacing_table_ind): Remove constants.
77         (uc_width, u8_width, u16_width, u32_width): Remove functions.
78         * modules/linebreak (Depends-on): Add streq, uniwidth/width.
79         * NEWS: Document the change.
80
81 2007-09-01  Bruno Haible  <bruno@clisp.org>
82
83         * lib/streq.h: Add double-inclusion guard.
84
85 2007-09-01  Karl Berry  <karl@gnu.org>
86
87         * MODULES.html.sh: Rename mreadlink_with_size to areadlink_with_size.
88
89 2007-08-28  Jim Meyering  <jim@meyering.net>
90
91         Rename mreadlink_with_size to areadlink_with_size.
92         * NEWS: Document the change.
93         * lib/mreadlink-with-size.c (mreadlink_with_size): Rename this to...
94         * lib/areadlink-with-size.c (areadlink_with_size): ...this.
95         * lib/mreadlink.h: Rename this to...
96         * lib/areadlink.h: ...this.
97         * modules/mreadlink-with-size: Rename this to...
98         * modules/areadlink-with-size: ...this.
99         * lib/canonicalize.c: Reflect the renaming.
100         * modules/canonicalize: Likewise.
101
102 2007-08-26  Bruno Haible  <bruno@clisp.org>
103
104         * gnulib-tool (func_import): When deciding which files to remove,
105         consider also dangling symbolic links.
106         Reported by Eric Blake.
107
108 2007-08-26  Bruno Haible  <bruno@clisp.org>
109
110         * gnulib-tool (func_ln_if_changed): Use "test -h", not "test -L".
111
112 2007-08-23  Simon Josefsson  <simon@josefsson.org>
113
114         * lib/readline.c: Don't include getline.h, the prototype is now
115         found in stdio.h.
116
117 2007-08-23  Jim Meyering  <jim@meyering.net>
118
119         Getdelim touchup.
120         * lib/getdelim.c (getdelim): Don't bother to save/restore errno
121         around the funlockfile call, since funlockfile never sets errno.
122         Don't set errno upon failed realloc.
123
124 2007-08-22  Eric Blake  <ebb9@byu.net>
125
126         Getline touchups.
127         * lib/getdelim.c (getdelim): Revert regression that required *n to
128         be 0 when *lineptr is NULL.  Preserve errno across funlockfile.
129         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Check for declaration of
130         getdelim, rather than whether implementation is missing.
131         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise for getline.
132         * lib/stdio_.h (getline): Also declare if replacement is
133         required.
134         * doc/functions/getdelim.texi: New file.
135         * doc/functions/getline.texi: Likewise.
136         * doc/gnulib.texi (Function Substitutes): Add new files.
137         Reported by Bruno Haible.
138
139 2007-08-22  Ludovic Courtès  <ludo@gnu.org>
140
141         * users.txt: Add Guile.
142
143 2007-08-22  Eric Blake  <ebb9@byu.net>
144
145         * tests/test-getdelim.c (main): Use remove, not unlink.
146         * tests/test-getline.c (main): Likewise.
147
148         Move getline and getdelim into stdio.h, per POSIX 200x.
149         * modules/getline (Files): Remove getline.h.
150         (Depends-on): Add stdio.
151         (configure.ac): Add module indicator.
152         * modules/getdelim (Files): Remove getdelim.h.
153         (Depends-on): Add stdio.
154         (configure.ac): Add module indicator.
155         * modules/stdio (Makefile.am): Work with new indicators.
156         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add new defaults.
157         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Work with stdio needs.
158         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
159         * lib/getdelim.h: Delete.
160         * lib/getline.h: Delete.
161         * lib/stdio_.h (getdelim, getline): Declare.
162         * modules/getdelim-tests: New module.
163         * modules/getline-tests: Likewise.
164         * tests/test-getdelim.c: New file.
165         * tests/test-getline.c: Likewise.
166         * NEWS: Document the change.
167         * lib/getline.c: Update choice of header.
168         * lib/csharpcomp.c: Likewise.
169         * lib/getpass.c: Likewise.
170         * lib/javacomp.c: Likewise.
171         * lib/javaversion.c: Likewise.
172         * lib/yesno.c: Likewise.
173         * lib/getdelim.c: Likewise.
174         (getdelim): Set errno on failure, and avoid memory leak.
175
176 2007-08-19  Bruno Haible  <bruno@clisp.org>
177
178         * modules/closein (Depends-on): Add freadahead.
179         * lib/closein.c: Include freadahead.h.
180         (close_stdin): Skip the fseeko and fflush calls if freadahead(stdin)
181         is zero.
182
183 2007-08-19  Bruno Haible  <bruno@clisp.org>
184
185         * modules/freadahead-tests: New file.
186         * tests/test-freadahead.sh: New file.
187         * tests/test-freadahead.c: New file.
188
189         * modules/freadahead: New file.
190         * lib/freadahead.h: New file.
191         * lib/freadahead.c: New file.
192         * MODULES.html.sh (File stream based Input/Output): Add freadahead,
193         fbufmode, fpurge, freadable, fwritable.
194
195 2007-08-19  Eric Blake  <ebb9@byu.net>
196
197         Test yesno in combination with closein.
198         * lib/yesno.c (yesno): Document use of stdin.
199         * modules/yesno-tests (Files): New module.
200         * tests/test-yesno.c (main): New file.
201         * tests/test-yesno.sh: Likewise.
202
203 2007-08-19  Bruno Haible  <bruno@clisp.org>
204
205         * lib/fbufmode.c (fbufmode): Add tentative support for Solaris/AMD64.
206         * lib/fseeko.c (rpl_fseeko): Likewise.
207         * lib/fseterr.c (fseterr): Likewise.
208
209 2007-08-19  Bruno Haible  <bruno@clisp.org>
210
211         * tests/test-lseek.c (main): Disable a test for BeOS.
212         * doc/functions/lseek.texi: Document the BeOS bug.
213
214 2007-08-19  Bruno Haible  <bruno@clisp.org>
215             Eric Blake  <ebb9@byu.net>
216
217         * lib/lseek.c: Include <sys/stat.h>.
218         (rpl_lseek): Add workaround code also for Unix platforms.
219         Needed for BeOS.
220         * m4/lseek.m4 (gl_FUNC_LSEEK): When cross-compiling, fail on BeOS.
221         * doc/functions/lseek.texi: Document BeOS definiency.
222
223 2007-08-18  Bruno Haible  <bruno@clisp.org>
224
225         * modules/fstrcmp-tests: New file.
226         * tests/test-fstrcmp.c: New file.
227
228 2007-08-18  Bruno Haible  <bruno@clisp.org>
229
230         * modules/fstrcmp: New file, from GNU gettext with modifications.
231         * lib/fstrcmp.h: New file, from GNU gettext.
232         * lib/fstrcmp.c: New file, from GNU gettext.
233         * MODULES.html.sh (String handling): Add fstrcmp.
234
235 2007-08-18  Bruno Haible  <bruno@clisp.org>
236
237         * lib/diffseq.h (struct context): Change type of 'heuristic' field to
238         'bool'.
239         (diag, compareseq): Remove const from the ctxt argument.
240         (USE_HEURISTIC): Undefine at the end.
241
242 2007-08-18  Jim Meyering  <jim@meyering.net>
243
244         New file: lib/idcache.h
245         * NEWS: Mention the addition.
246         * modules/idcache (Files): Add lib/idcache.h
247         * lib/idcache.c: Include "idcache.h".
248         Don't include <sys/types.h>.
249         Add a FIXME comment.
250         Move file-scoped "static" declarations to the top.
251         * lib/idcache.h: New file.  Include <sys/types.h> here, instead.
252
253 2007-08-17  Bruno Haible  <bruno@clisp.org>
254         and Paul Eggert  <eggert@cs.ucla.edu>
255
256         * MODULES.html.sh: Add diffseq.
257         * modules/diffseq: New file.
258         * lib/diffseq.h: New file, from GNU gettext with a few minor changes,
259         extracted from GNU gettext's fstrcmp.c and GNU diff's analyze.c.
260
261 2007-08-15  Paul Eggert  <eggert@cs.ucla.edu>
262
263         Import changes from coreutils for bootstrap script.
264
265         2007-07-21  Paul Eggert  <eggert@cs.ucla.edu>
266
267         * build-aux/bootstrap (slurp): Work even in environments where
268         "ls" defaults to "ls -A".  Put in a FIXME, though, since the
269         current code does not slurp files whose names start with ".", and
270         this looks like it might be a troublesome area.
271
272         2007-07-11  Jim Meyering  <jim@meyering.net>
273
274         If there's a GPL vN copyright comment, require that N == 3.
275
276         2007-07-08  Jim Meyering  <jim@meyering.net>
277
278         Run the coreutils-specific code only if tests/Makefile.am.in exists.
279         * build-aux/bootstrap (mam_template): Move definition out of loop.
280
281         Create symlinks for gl/{lib,m4}/*, just as for gnulib/{lib,m4}/*.
282
283         * build-aux/bootstrap (symlink_to_dir): Rename function from
284         symlink_to_gnulib.  Add a directory parameter.  Update all
285         callers.
286         (cp_mark_as_generated): Also check for -- and link to -- files in
287         gl/.
288
289         2007-07-08  Jim Meyering  <jim@meyering.net>
290
291         Adapt to deeper hierarchy in gnulib.
292         * build-aux/bootstrap (symlink_to_dir): If the destination
293         directory doesn't exist, create it. This is required at least for
294         "lib/uniwidth/cjk.h".
295
296         2007-05-15  Jim Meyering  <jim@meyering.net>
297
298         * build-aux/bootstrap: Now that generated Makefile.am files
299         are no longer under version control, they must be created at
300         bootstrap time.
301
302 2007-08-14  Ben Pfaff  <blp@gnu.org>
303
304         * lib/count-one-bits.h: Add comments.  From Bruno Haible.
305
306 2007-08-14  Paul Eggert  <eggert@cs.ucla.edu>
307
308         * lib/count-one-bits.h: Don't include <limits.h>; no longer needed
309         given the changes below.
310         (COUNT_ONE_BITS): Use 'verify' rather than 'verify_true'.  Work
311         even on hosts that have padding bits beyond the supported 64.
312
313 2007-08-10  Paul Eggert  <eggert@cs.ucla.edu>
314
315         * NEWS: In xstrtol, remove STRTOL_FATAL_ERROR and add xstrtol_fatal.
316         * lib/xstrtol.h: Don't include exitfail.h; that's now internal to
317         xstrtol.c.  Include getopt.h, since xstrtol_fatal's signature
318         depends on it.
319         (xstrtol_error): Remove.
320         (xstrtol_fatal): New decl, replacing the functionality of xstrtol_error
321         but with a different signature.
322         (ATTRIBUTE_NORETURN, __attribute__): New macros.
323         * lib/xstrtol-error.c: Include exitfail.h.
324         (xstrtol_fatal): New function, with a different signature from the
325         old xstrtol_error, so that the caller need not worry about passing
326         in an exit status, or about storage management of the option argument.
327         (xstrtol_error): Now a static function.  Redo signature to
328         implement xstrtol_fatal.  Output the correct number of hyphens in
329         front of the option so that the caller need not worry about
330         storage management.
331         (N_): New macro.
332         (_): Remove; not used now.
333         * modules/xstrtol: Depend on getopt.
334         * tests/test-xstrtol.c (main): Use new xstrtol_error function instead
335         of old STRTOL_FATAL_ERROR macro.
336         * tests/test-xstrtol.sh (t-xstrtol.xo): Adjust to match new behavior
337         of test program.
338         * tests/test-xstrtoimax.sh (t-xstrtoimax.xo): Likewise.
339         * tests/test-xstrtoumax.sh (t-xstrtoumax.xo): Likewise.
340
341 2007-08-08  Eric Blake  <ebb9@byu.net>
342
343         * lib/xstrtol-error.c: Add missing include.
344
345         Move xstrtol messages into gnulib domain, when --pobase is used.
346         * lib/xstrtol.h (_STRTOL_ERROR): Move messages out of macro...
347         * lib/xstrtol-error.c (xstrtol_error): ...into new file.
348         * modules/xstrtol (Files): Distribute new file.
349         * m4/xstrtol.m4 (gl_XSTRTOL): Build new file.
350         * lib/xstrtol.c (TESTING_XSTRTO): Move tests...
351         * tests/test-xstrtol.c: ...into new file.
352         * tests/test-xstrtoul.c: Also test xstrtoul.
353         * tests/test-xstrtoimax.c: Also test xstrtoimax.
354         * tests/test-xstrtoumax.c: Also test xstrtoumax.
355         * tests/test-xstrtol.sh: Drive the tests.
356         * tests/test-xstrtoimax.sh: Likewise.
357         * tests/test-xstrtoumax.sh: Likewise.
358         * modules/xstrtol-tests: New module.
359         * modules/xstrtoimax-tests: Likewise.
360         * modules/xstrtoumax-tests: Likewise.
361
362 2007-08-08  Jim Meyering  <jim@meyering.net>
363
364         New function: mfile_name_concat.
365         * lib/filenamecat.c (mfile_name_concat): New function, just like
366         file_name_concat, but return NULL upon failure rather than exiting
367         with a diagnostic.
368         * lib/filenamecat.h: Declare it.
369
370 2007-08-07  Bruno Haible  <bruno@clisp.org>
371
372         * m4/inttypes.m4 (gl_INTTYPES_H): Use GL_TRIGGER_STDC_LIMIT_MACROS
373         instead of __STDC_LIMIT_MACROS_TRIGGER. This avoids a redefinition
374         warning from gcc.
375         Reported by Eric Blake.
376
377 2007-08-07  Simon Josefsson  <simon@josefsson.org>
378
379         * modules/crypto/arctwo (License): Use the synonymous term "LGPLv2+".
380         * modules/crypto/arcfour (License): Likewise.
381         * modules/crypto/des-tests (License): Likewise.
382         * modules/crypto/gc-arctwo-tests (License): Likewise.
383         * modules/crypto/gc-des-tests (License): Likewise.
384         * modules/crypto/gc-hmac-md5-tests (License): Likewise.
385         * modules/crypto/gc-hmac-sha1-tests (License): Likewise.
386         * modules/crypto/gc-md2-tests (License): Likewise.
387         * modules/crypto/gc-md4-tests (License): Likewise.
388         * modules/crypto/gc-md5-tests (License): Likewise.
389         * modules/crypto/gc-pbkdf2-sha1-tests (License): Likewise.
390         * modules/crypto/gc-rijndael-tests (License): Likewise.
391         * modules/crypto/gc-sha1-tests (License): Likewise.
392         * modules/crypto/gc-tests (License): Likewise.
393         * modules/crypto/hmac-md5 (License): Likewise.
394         * modules/crypto/hmac-sha1 (License): Likewise.
395         * modules/crypto/md2-tests (License): Likewise.
396         * modules/crypto/md4-tests (License): Likewise.
397         * modules/crypto/md5 (License): Likewise.
398         * modules/crypto/rijndael (License): Likewise.
399         * modules/crypto/sha1 (License): Likewise.
400         * modules/memxor (License): Likewise.
401
402 2007-08-06  Paul Eggert  <eggert@cs.ucla.edu>
403         and Bruno Haible  <bruno@clisp.org>
404
405         * NEWS: Describe interface changes to human, xstrtol.
406         * lib/human.h: Include <xstrtol.h>.
407         (human_options): Return enum strtol_error, not int.  Remove
408         bool arg; take int * instead.
409         * lib/human.c: Don't include "gettext.h".
410         (_): Remove; no longer used.
411         Don't include <xstrtol.h>, since human.h does it.
412         (human_options): Adjust to abovementioned interface changes.
413         Do not report error to stderr; that's now the caller's
414         responsibility.
415         * lib/xstrtol.c (main) [defined TESTING_XSTRTO]: Adjust to
416         interface change.
417         * lib/xstrtol.h (_STRTOL_ERROR): Take Option, Arg rather than
418         Str, Argument_type_string.  All uses changed.  Put " argument"
419         in diagnostics to make them clearer.  Change wording of suffix
420         message for clarity.
421         (STRTOL_FATAL_ERROR): Take Option, Arg rather than Str,
422         Argument_type_string.
423         (STRTOL_FATAL_WARN): Remove; no longer used.
424         * modules/human (Depends-on): Remove gettext-h.
425
426 2007-08-06  Simon Josefsson  <simon@josefsson.org>
427
428         * build-aux/maint.mk, build-aux/GNUmakefile: Relicense to GPLv3+.
429
430 2007-07-31  Bruno Haible  <bruno@clisp.org>
431
432         * m4/stdint.m4 (gl_STDINT_H): Test whether WCHAR_MIN and WCHAR_MAX
433         are defined by <stdint.h> (as opposed to <wchar.h>, as on Dragonfly).
434         Reported by Joerg Sonnenberger <joerg@britannica.bec.de>.
435
436 2007-07-31  Bruno Haible  <bruno@clisp.org>
437
438         * lib/fflush.c (rpl_fflush): On BSD systems, use the __SNPT flag.
439         Suggested by Joerg Sonnenberger <joerg@britannica.bec.de>.
440
441 2007-07-30  Bruno Haible  <bruno@clisp.org>
442
443         * modules/base64 (License): Use the synonymous term "LGPLv2+".
444         * modules/c-ctype (License): Likewise.
445         * modules/c-strcase (License): Likewise.
446         * modules/check-version (License): Likewise.
447         * modules/iconv (License): Likewise.
448         * modules/iconv_open (License): Likewise.
449         * modules/read-file (License): Likewise.
450         * modules/striconv (License): Likewise.
451         * modules/strverscmp (License): Likewise.
452         * modules/vasprintf (License): Likewise.
453         * modules/crypto/des (License): Likewise.
454         * modules/crypto/gc (License): Likewise.
455         * modules/crypto/gc-arcfour (License): Likewise.
456         * modules/crypto/gc-arctwo (License): Likewise.
457         * modules/crypto/gc-des (License): Likewise.
458         * modules/crypto/gc-hmac-md5 (License): Likewise.
459         * modules/crypto/gc-hmac-sha1 (License): Likewise.
460         * modules/crypto/gc-md2 (License): Likewise.
461         * modules/crypto/gc-md4 (License): Likewise.
462         * modules/crypto/gc-md5 (License): Likewise.
463         * modules/crypto/gc-pbkdf2-sha1 (License): Likewise.
464         * modules/crypto/gc-random (License): Likewise.
465         * modules/crypto/gc-rijndael (License): Likewise.
466         * modules/crypto/gc-sha1 (License): Likewise.
467         * modules/crypto/md2 (License): Likewise.
468         * modules/crypto/md4 (License): Likewise.
469
470 2007-07-30  Jim Meyering  <jim@meyering.net>
471
472         * lib/fts.c (fts_read): Upon failure to chdir into a subdirectory,
473         set fts_info to FTS_DNR, not to FTS_ERR, so that the caller knows
474         it has valid stat data.  This bug would cause du not to count the
475         sizes of inaccessible directories.
476         Patch by Bryan Mason <bmason@redhat.com>, via Jose Maria Plans
477         in <http://bugzilla.redhat.com/250077>.
478
479 2007-07-25  Peter O'Gorman  <peter@pogma.com>
480             Bruno Haible  <bruno@clisp.org>
481
482         * m4/include_next.m4 (gl_INCLUDE_NEXT): Test whether #include_next
483         really works. Needed because AIX 4.3 "xlc -E" doesn't understand
484         #include_next, gives a diagnostic about it, but reports no error in
485         the exit code.
486         Reported by Gary V. Vaughan <gary@thewrittenword.com>.
487
488 2007-07-24  Ben Pfaff  <blp@gnu.org>
489
490         Improve name: "count-one-bits" is better than "popcount".
491         * MODULES.html.sh: Update name.
492         * lib/popcount.h: Renamed lib/count-one-bits.h.
493         (popcount): Renamed count_one_bits.
494         (popcountl): Renamed count_one_bits_l.
495         (popcountll): Renamed count_one_bits_ll.
496         * m4/popcount.m4: Renamed m4/count-one-bits.m4.
497         * modules/popcount: Renamed module/count-one-bits.
498         * modules/popcount-tests: Renamed module/count-one-bits-tests.
499         * tests/test-popcount.c: Renamed tests/test-count-one-bits.c.
500
501 2007-07-23  Ben Pfaff  <blp@gnu.org>
502
503         * lib/popcount.h (popcount32): Reduce size of constants, to allow
504         better code generation, and add U to large constants to avoid
505         warnings, in non-GCC case.
506         Suggested by Bruno Haible.
507
508 2007-07-23  Ben Pfaff  <blp@gnu.org>
509
510         * lib/popcount.h: Use verify_true instead of if...abort.
511         * modules/popcount: Depend on verify module.
512         Suggested by Jim Meyering.
513
514 2007-07-23  Bruno Haible  <bruno@clisp.org>
515
516         * gnulib-tool (func_import): Create a .cvsignore file also when the
517         directory is not yet in CVS but the toplevel directory is. When
518         creating a .cvsignore file, add ".deps" and ".dirstamp" to it.
519         Reported by Karl Berry.
520
521 2007-07-22  Ben Pfaff  <blp@gnu.org>
522
523         * lib/popcount.h: Use faster, branchless algorithm for non-GCC
524         case.
525         Suggested by Eric Blake.
526
527 2007-07-22  Ben Pfaff  <blp@gnu.org>
528
529         New module: popcount.
530         * MODULES.html.sh: Add popcount.
531         * modules/popcount: New file.
532         * modules/popcount-tests: New file.
533         * tests/test-popcount.c: New file.
534         * lib/popcount.h: New file.
535         * m4/popcount.m4: New file.
536
537 2007-07-22  Paul Eggert  <eggert@cs.ucla.edu>
538
539         * build-aux/announce-gen: Update to GPLv3.
540
541         * build-aux/config.guess: Update from config.
542
543 2007-07-21  Bruno Haible  <bruno@clisp.org>
544
545         * lib/error.c (_) [ENABLE_NLS]: Define to gettext.
546         * lib/verror.c (_) [ENABLE_NLS]: Likewise.
547
548 2007-07-20  Jim Meyering  <jim@meyering.net>
549
550         * check-module: Diagnose a self-dependency.
551
552 2007-07-19  Bruno Haible  <bruno@clisp.org>
553
554         * gnulib-tool (func_import): Don't abort if pobase or po_domain is
555         empty.
556         Reported by Eric Blake.
557
558 2007-07-18  Bruno Haible  <bruno@clisp.org>
559
560         * gnulib-tool: New options --po-base, --po-domain.
561         (func_usage): Document them.
562         (pobase, po_domain): New variables.
563         (func_emit_lib_Makefile_am): Augment AM_CPPFLAGS, defining
564         DEFAULT_TEXT_DOMAIN.
565         (func_emit_po_Makevars, func_emit_po_POTFILES_in): New functions.
566         (func_import): Consider pobase and po_domain. Create a po/ directory.
567         (func_create_testdir): Set pobase and po_domain to empty.
568         * build-aux/po/Makefile.in.in: New file, from GNU gettext 0.16.1.
569         * build-aux/po/remove-potcdate.sin: New file, from GNU gettext 0.16.1.
570
571 2007-07-18  Bruno Haible  <bruno@clisp.org>
572
573         * gnulib-tool (func_get_automake_snippet): Synthesize also an
574         EXTRA_DIST augmentation for files in build-aux/.
575
576 2007-07-16  Bruno Haible  <bruno@clisp.org>
577
578         * modules/lseek (License): Use the synonymous term "LGPLv2+".
579         * modules/getdelim (License): Likewise.
580
581 2007-07-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
582
583         * modules/arpa_inet (License): Use the synonymous term LGPLv2+.
584         * modules/d-type (License): Likewise.
585         * modules/extensions (License): Likewise.
586         * modules/fnmatch (License): Likewise.
587         * modules/fseeko (License): Likewise.
588         * modules/getaddrinfo (License): Likewise.
589         * modules/getline (License): Likewise.
590         * modules/getlogin_r (License): Likewise.
591         * modules/getpass (License): Likewise.
592         * modules/gettimeofday (License): Likewise.
593         * modules/glob (License): Likewise.
594         * modules/inet_ntop (License): Likewise.
595         * modules/malloc (License): Likewise.
596         * modules/malloca (License): Likewise.
597         * modules/memmem (License): Likewise.
598         * modules/mempcpy (License): Likewise.
599         * modules/memset (License): Likewise.
600         * modules/minmax (License): Likewise.
601         * modules/mktime (License): Likewise.
602         * modules/netinet_in (License): Likewise.
603         * modules/pathmax (License): Likewise.
604         * modules/poll (License): Likewise.
605         * modules/regex (License): Likewise.
606         * modules/snprintf (License): Likewise.
607         * modules/stdbool (License): Likewise.
608         * modules/stdint (License): Likewise.
609         * modules/stdio (License): Likewise.
610         * modules/strcase (License): Likewise.
611         * modules/strcasestr (License): Likewise.
612         * modules/strdup (License): Likewise.
613         * modules/string (License): Likewise.
614         * modules/strndup (License): Likewise.
615         * modules/strnlen (License): Likewise.
616         * modules/strpbrk (License): Likewise.
617         * modules/strptime (License): Likewise.
618         * modules/strsep (License): Likewise.
619         * modules/sys_select (License): Likewise.
620         * modules/sys_socket (License): Likewise.
621         * modules/sys_stat (License): Likewise.
622         * modules/sys_time (License): Likewise.
623         * modules/time (License): Likewise.
624         * modules/time_r (License): Likewise.
625         * modules/timegm (License): Likewise.
626         * modules/unistd (License): Likewise.
627         * modules/vsnprintf (License): Likewise.
628         * modules/wctype (License): Likewise.
629
630 2007-07-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
631
632         * modules/argz (License): LGPLv2+.
633
634 2007-07-15  Karl Berry  <karl@gnu.org>
635
636         * doc/gnulib.texi: revise node structure per new fdl.texi.
637
638 2007-07-14  Bruno Haible  <bruno@clisp.org>
639
640         * lib/uniname/gen-uninames.lisp (main): Emit a "do not edit" line to
641         the output file.
642         * lib/uniname/uninames.h: Regenerated.
643
644 2007-07-14  Karl Berry  <karl@gnu.org>
645
646         * doc/*gpl*.texi, doc/fdl.texi: new versions, consistently
647         omitting sectioning and index commands.
648
649 2007-07-13  Bruno Haible  <bruno@clisp.org>
650
651         New gnulib-tool option --more-symlinks.
652         * gnulib-tool (func_usage): Document --more-symlinks.
653         (do_copyrights): New variable.
654         Recognize option --more-symlinks.
655         (func_import): Don't add a copyright notice transform to
656         sed_transform_lib_file if do_copyrights is empty.
657
658 2007-07-13  Bruno Haible  <bruno@clisp.org>
659
660         * lib/vasnprintf.c (decimal_point_char): Define also if
661         (NEED_PRINTF_LONG_DOUBLE || NEED_PRINTF_INFINITE_DOUBLE)
662         && !NEED_PRINTF_DIRECTIVE_A.
663         Reported by Clemens Koller <clemens.koller@anagramm.de> via
664         Gary V. Vaughan <gary@gnu.org>.
665
666 2007-07-13  Paul Eggert  <eggert@cs.ucla.edu>
667
668         * lib/inttypes_.h: Undo previous change, since it was fixed
669         in a different way in the 2007-07-02 fix to m4/inttypes.m4.
670
671 2007-07-13  Bruno Haible  <bruno@clisp.org>
672
673         * lib/stdint_.h: Fix typo: _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H was
674         misspelled as _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H.
675
676 2007-07-13  Jim Meyering  <jim@meyering.net>
677
678         df: Don't fail for Tru64's "file-on-file mount".
679         * m4/fsusage.m4 (gl_FSUSAGE): Reject Tru64's buggy statvfs,
680         so we fall through and use statfs instead.  Details here:
681         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/10878>
682         Reported by Albert Chin.
683
684 2007-07-13  Bruno Haible  <bruno@clisp.org>
685
686         * modules/alloca-opt (License): Use the synonymous term "LGPLv2+".
687         * modules/configmake (License): Likewise.
688         * modules/gettext (License): Likewise.
689         * modules/gettext-h (License): Likewise.
690         * modules/include_next (License): Likewise.
691         * modules/link-warning (License): Likewise.
692         * modules/localcharset (License): Likewise.
693         * modules/localename (License): Likewise.
694         * modules/lock (License): Likewise.
695         * modules/relocatable-lib-lgpl (License): Likewise.
696         * modules/size_max (License): Likewise.
697         * modules/vasnprintf (License): Likewise.
698         * modules/wchar (License): Likewise.
699         * modules/xsize (License): Likewise.
700
701 2007-07-13  Bruno Haible  <bruno@clisp.org>
702
703         * gnulib-tool (func_import): Treat LGPLv2 as synonymous to LGPL.
704         (func_create_testdir): Handle copying terms "GPLv2+" and "LGPLv2+".
705
706 2007-07-12  Bruno Haible  <bruno@clisp.org>
707
708         * doc/gnulib-intro.texi (Copyright): Clarify the license abbreviations
709         in the modules files.
710
711 2007-07-11  Karl Berry  <karl@gnu.org>
712
713         * MODULES.html.sh (func_module): use
714          sed -e '\|^'"${includefile}"'$|d'
715          instead of /.../d, to avoid errors on $includefile's containing /.
716
717 2007-07-10  Sergey Poznyakoff  <gray@gnu.org.ua>
718
719         * gnulib-tool (func_import): Avoid duplication of --avoid
720         statements
721         (func_dest_tmpfilename,func_create_testdir): Translate `-' in file
722         names to `_' in variable names.
723
724 2007-07-10  Eric Blake  <ebb9@byu.net>
725
726         * lib/version-etc.c (version_etc_va): Default to GPLv3+.
727         * NEWS: Document this change.
728
729 2007-07-08  Bruno Haible  <bruno@clisp.org>
730
731         Update to Unicode 5.0.
732         * lib/uniwidth/width.c (nonspacing_table_data): Add U+00AD,
733         U+0350..U+035F, U+05A2, U+05BA, U+05C5, U+05C7, U+0600..U+0603,
734         U+0610..U+0615, U+0656..U+065E, U+07EB..U+07F3, U+0A01, U+0AE2..U+0AE3,
735         U+0CBC. Remove U+0CBF, U+0CC6. Add U+0CE2..U+0CE3, U+135F,
736         U+17B4..U+17B5, U+17DD. Remove U+180E. Add U+1920..U+1922,
737         U+1927..U+192B, U+1932, U+1939..U+193B, U+1A17..U+1A18, U+1B00..U+1B03,
738         U+1B34, U+1B36..U+1B3A, U+1B3C, U+1B42, U+1B6B..U+1B73, U+1DC0..U+1DCA,
739         U+1DFE..U+1DFF, U+20EB..U+20EF, U+A802, U+A806, U+A80B, U+A825..U+A826,
740         U+10A01..U+10A03, U+10A05..U+10A06, U+10A0C..U+10A0F, U+10A38..U+10A3A,
741         U+10A3F, U+1D242..U+1D244.
742         (nonspacing_table_ind): Update.
743         (uc_width): Assign width 0 to U+E0100..U+E01EF. Assign width 1 to
744         U+4DC0..U+4DFF. Assign width 2 to U+2329..U+232A, U+FE10..U+FE1F.
745
746 2007-07-08  Bruno Haible  <bruno@clisp.org>
747
748         Update to Unicode 5.0.
749         * lib/uniname/gen-uninames.lisp (main): Add the range 0x12xxx to the
750         code transform. Extend the name index field of unicode_name_to_code and
751         unicode_code_to_name from 16 to 24 bits.
752         * lib/uniname/uniname.c (unicode_character_name,
753         unicode_name_character): Add the range 0x12xxx to the code transform.
754         * lib/uniname/uninames.h: Regenerated.
755         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.0.
756
757 2007-07-07  Bruno Haible  <bruno@clisp.org>
758
759         * modules/wcwidth-tests: New file.
760         * tests/test-wcwidth.c: New file.
761
762         Work around MacOS X wcwidth() bug.
763         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test against MacOS X 10.3 bug.
764         * lib/wcwidth.c: Include localcharset.h, streq.h, uniwidth.h.
765         (rpl_wcwidth): Special-case the UTF-8 locales. Fall back to the
766         original wcwidth in non-UTF-8 locales.
767         * modules/wcwidth (Depends-on): Add localcharset, streq,
768         uniwidth/width.
769         * doc/functions/wcwidth.texi: Update.
770
771 2007-07-07  Bruno Haible  <bruno@clisp.org>
772
773         * lib/wchar_.h: Include the GL_LINK_WARNING macro.
774         (wcwidth): New declaration.
775         * m4/wchar.m4 (gl_WCHAR_MODULE_INDICATOR, gl_WCHAR_H_DEFAULTS): New
776         macros.
777         (gl_WCHAR_H): Require gl_WCHAR_H_DEFAULTS. Don't set WCHAR_H to empty
778         here. Prepare for creating <wchar.h> unconditionally.
779         * modules/wchar (Depends-on): Add link-warning.
780         (Makefile.am): Substitute also GNULIB_WCWIDTH, HAVE_DECL_WCWIDTH,
781         REPLACE_WCWIDTH, and GL_LINK_WARNING.
782         * lib/wcwidth.h: Remove file.
783         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gl_WCHAR_H_DEFAULTS. Set
784         HAVE_DECL_WCWIDTH, REPLACE_WCWIDTH, WCHAR_H.
785         * modules/wcwidth (Files): Remove lib/wcwidth.h.
786         (configure.ac): Invoke gl_WCHAR_MODULE_INDICATOR.
787         (Include): Replace wcwidth.h with <wchar.h>.
788         * lib/wcwidth.c: Include <wchar.h> instead of wcwidth.h.
789         * lib/mbchar.h: Don't include wcwidth.h.
790         * lib/mbswidth.c: Likewise.
791         * NEWS: Mention the change.
792
793 2007-07-07  Bruno Haible  <bruno@clisp.org>
794
795         * lib/wcwidth.c: New file, extracted from lib/wcwidth.h.
796         * lib/wcwidth.h: Don't include wctype.h. Replace inline function
797         definition with an external declaration.
798         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Use wcwidth.c when wcwidth is not
799         defined as a function. Remove AC_C_INLINE requirement.
800         * modules/wcwidth (Files): Add lib/wcwidth.c.
801         (Makefile.am): Remove redundant statement.
802
803 2007-07-07  Bruno Haible  <bruno@clisp.org>
804
805         * MODULES.html.sh (Unicode string functions): Add the new modules.
806
807         * tests/uniwidth/test-u32-strwidth.c: New file.
808         * modules/uniwidth/u32-strwidth-tests: New file.
809
810         * lib/uniwidth/u32-strwidth.c: New file.
811         * modules/uniwidth/u32-strwidth: New file.
812
813         * tests/uniwidth/test-u16-strwidth.c: New file.
814         * modules/uniwidth/u16-strwidth-tests: New file.
815
816         * lib/uniwidth/u16-strwidth.c: New file.
817         * modules/uniwidth/u16-strwidth: New file.
818
819         * tests/uniwidth/test-u8-strwidth.c: New file.
820         * modules/uniwidth/u8-strwidth-tests: New file.
821
822         * lib/uniwidth/u8-strwidth.c: New file.
823         * modules/uniwidth/u8-strwidth: New file.
824
825         * tests/uniwidth/test-u32-width.c: New file.
826         * modules/uniwidth/u32-width-tests: New file.
827
828         * lib/uniwidth/u32-width.c: New file.
829         * modules/uniwidth/u32-width: New file.
830
831         * tests/uniwidth/test-u16-width.c: New file.
832         * modules/uniwidth/u16-width-tests: New file.
833
834         * lib/uniwidth/u16-width.c: New file.
835         * modules/uniwidth/u16-width: New file.
836
837         * tests/uniwidth/test-u8-width.c: New file.
838         * modules/uniwidth/u8-width-tests: New file.
839
840         * lib/uniwidth/u8-width.c: New file.
841         * modules/uniwidth/u8-width: New file.
842
843         * tests/uniwidth/test-uc_width.c: New file.
844         * modules/uniwidth/width-tests: New file.
845
846         * lib/uniwidth/width.c: New file, from GNU libiconv.
847         * lib/uniwidth/cjk.h: New file, from GNU libiconv.
848         * modules/uniwidth/width: New file.
849
850         * lib/uniwidth.h: New file, from GNU libiconv.
851         * modules/uniwidth/base: New file.
852
853 2007-07-07  Bruno Haible  <bruno@clisp.org>
854
855         * lib/uniname.h: New file, from GNU gettext.
856         * lib/uniname/gen-uninames.lisp: New file, from GNU gettext.
857         * lib/uniname/uninames.h: New file, from GNU gettext.
858         * lib/uniname/uniname.c: New file, from GNU gettext.
859         * tests/uniname/test-uninames.sh: New file.
860         * tests/uniname/test-uninames.c: New file, from GNU gettext.
861         * tests/uniname/UnicodeDataNames.txt: New file, from GNU gettext.
862         * modules/uniname/base: New file.
863         * modules/uniname/uniname: New file.
864         * modules/uniname/uniname-tests: New file.
865         * MODULES.html.sh (Unicode string functions): Add the new modules.
866
867 2007-07-06  Bruno Haible  <bruno@clisp.org>
868
869         * doc/Makefile (TEXI2HTML): Specify a --reference-limit.
870
871 2007-07-06  Bruno Haible  <bruno@clisp.org>
872
873         * lib/sys_time_.h: Use a recursion-safe inclusion guard rather than
874         a split double-inclusion guard. Needed for cygwin, where <sys/time.h>
875         includes <cygwin/sys_time.h> which includes <sys/select.h> which
876         include <sys/time.h>.
877         Reported by Eric Blake.
878
879 2007-07-06  Eric Blake  <ebb9@byu.net>
880
881         Fix testing canonicalize on cygwin.
882         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
883         Revert patch from 2007-06-19.
884         * tests/test-canonicalize-lgpl.c (main): Instead, skip test when
885         canonicalize module is also in use.
886         * tests/test-canonicalize.c: New file.
887         * tests/test-canonicalize.sh: Likewise.
888         * modules/canonicalize-tests: Likewise.
889
890 2007-07-06  Jim Meyering  <jim@meyering.net>
891
892         * lib/getugroups.c (getugroups): Detect getgrent failure.
893         Adjust comment to reflect reality: this function may return -1.
894
895 2007-07-05  Sergey Poznyakoff  <gray@gnu.org.ua>
896
897         * build-aux/bootstrap (TP_URL,get_translations): Update to use
898         the new TP address.
899         (usage): Fix typo
900         (gnulib_mk): New variable.
901
902 2007-07-05  Jim Meyering  <jim@meyering.net>
903
904         Don't let endgrent clobber errno, no matter how improbable.
905         * lib/getugroups.c (getugroups): Save and restore errno around
906         endgrent call.
907
908         Close the group DB even when failing with 2^31 or more members.
909         * lib/getugroups.c (getugroups): Don't return without calling endgrent.
910
911 2007-07-04  Jim Meyering  <jim@meyering.net>
912
913         * lib/getugroups.h: New file.
914         * lib/getugroups.c: Include "getugroups.h".
915         Remove uses of "register" keyword.
916         Move local variable, "cp", down into scope where used.
917         Give "username" parameter the "const" attribute.
918         * modules/getugroups (Files): Add lib/getugroups.h
919
920 2007-07-04  Karl Berry  <karl@gnu.org>
921
922         * MODULES.html.sh (func_all_modules): Complete rename of
923         gpl/lgpl to gpl-2.0 and lgpl-2.1, and add gpl-3.0.
924
925 2007-07-02  Bruno Haible  <bruno@clisp.org>
926
927         * m4/inttypes.m4 (gl_INTTYPES_H): Define __STDC_LIMIT_MACROS in C++
928         mode, when inttypes.h comes from gnulib.
929         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
930
931 2007-07-02  Simon Josefsson  <simon@josefsson.org>
932
933         * NEWS: Mention lgpl module name change.
934
935         * modules/lgpl-2.1: Renamed from lgpl.
936
937         * NEWS: Mention gpl module name change.
938
939         * modules/gpl-3.0: New file, based on gpl-2.0.
940
941         * modules/gpl-2.0: Renamed from gpl.
942
943         * modules/gpl: Fix filename, doc/gpl.texi is now found at
944         doc/gpl-2.0.texi.
945
946 2007-07-02  Paul Eggert  <eggert@cs.ucla.edu>
947
948         * lib/inttypes_.h [defined __cplusplus&&!defined __STDC_LIMIT_MACROS]:
949         #define __STDC_LIMIT_MACROS temporarily while including
950         <stdint.h>, so that __STDC_LIMIT_MACROS is defined.
951         Problem reported by Joel E. Denny in
952         <http://lists.gnu.org/archive/html/bug-gnulib/2007-07/msg00008.html>.
953
954 2007-07-01  Bruno Haible  <bruno@clisp.org>
955
956         * lib/unistdio.h: New file.
957         * lib/unistdio/u-asnprintf.h: New file.
958         * lib/unistdio/u-asprintf.h: New file.
959         * lib/unistdio/u-printf-args.c: New file.
960         * lib/unistdio/u-printf-args.h: New file.
961         * lib/unistdio/u-printf-parse.h: New file.
962         * lib/unistdio/u-snprintf.h: New file.
963         * lib/unistdio/u-sprintf.h: New file.
964         * lib/unistdio/u-vasprintf.h: New file.
965         * lib/unistdio/u-vsnprintf.h: New file.
966         * lib/unistdio/u-vsprintf.h: New file.
967         * lib/unistdio/ulc-asnprintf.c: New file.
968         * lib/unistdio/ulc-asprintf.c: New file.
969         * lib/unistdio/ulc-fprintf.c: New file, based on lib/fprintf.c.
970         * lib/unistdio/ulc-printf-parse.c: New file.
971         * lib/unistdio/ulc-snprintf.c: New file.
972         * lib/unistdio/ulc-sprintf.c: New file.
973         * lib/unistdio/ulc-vasnprintf.c: New file.
974         * lib/unistdio/ulc-vasprintf.c: New file.
975         * lib/unistdio/ulc-vfprintf.c: New file, based on lib/vfprintf.c.
976         * lib/unistdio/ulc-vsnprintf.c: New file.
977         * lib/unistdio/ulc-vsprintf.c: New file.
978         * lib/unistdio/u8-asnprintf.c: New file.
979         * lib/unistdio/u8-asprintf.c: New file.
980         * lib/unistdio/u8-printf-parse.c: New file.
981         * lib/unistdio/u8-snprintf.c: New file.
982         * lib/unistdio/u8-sprintf.c: New file.
983         * lib/unistdio/u8-vasnprintf.c: New file.
984         * lib/unistdio/u8-vasprintf.c: New file.
985         * lib/unistdio/u8-vsnprintf.c: New file.
986         * lib/unistdio/u8-vsprintf.c: New file.
987         * lib/unistdio/u8-u8-asnprintf.c: New file.
988         * lib/unistdio/u8-u8-asprintf.c: New file.
989         * lib/unistdio/u8-u8-snprintf.c: New file.
990         * lib/unistdio/u8-u8-sprintf.c: New file.
991         * lib/unistdio/u8-u8-vasnprintf.c: New file.
992         * lib/unistdio/u8-u8-vasprintf.c: New file.
993         * lib/unistdio/u8-u8-vsnprintf.c: New file.
994         * lib/unistdio/u8-u8-vsprintf.c: New file.
995         * lib/unistdio/u16-asnprintf.c: New file.
996         * lib/unistdio/u16-asprintf.c: New file.
997         * lib/unistdio/u16-printf-parse.c: New file.
998         * lib/unistdio/u16-snprintf.c: New file.
999         * lib/unistdio/u16-sprintf.c: New file.
1000         * lib/unistdio/u16-vasnprintf.c: New file.
1001         * lib/unistdio/u16-vasprintf.c: New file.
1002         * lib/unistdio/u16-vsnprintf.c: New file.
1003         * lib/unistdio/u16-vsprintf.c: New file.
1004         * lib/unistdio/u16-u16-asnprintf.c: New file.
1005         * lib/unistdio/u16-u16-asprintf.c: New file.
1006         * lib/unistdio/u16-u16-snprintf.c: New file.
1007         * lib/unistdio/u16-u16-sprintf.c: New file.
1008         * lib/unistdio/u16-u16-vasnprintf.c: New file.
1009         * lib/unistdio/u16-u16-vasprintf.c: New file.
1010         * lib/unistdio/u16-u16-vsnprintf.c: New file.
1011         * lib/unistdio/u16-u16-vsprintf.c: New file.
1012         * lib/unistdio/u32-asnprintf.c: New file.
1013         * lib/unistdio/u32-asprintf.c: New file.
1014         * lib/unistdio/u32-printf-parse.c: New file.
1015         * lib/unistdio/u32-snprintf.c: New file.
1016         * lib/unistdio/u32-sprintf.c: New file.
1017         * lib/unistdio/u32-vasnprintf.c: New file.
1018         * lib/unistdio/u32-vasprintf.c: New file.
1019         * lib/unistdio/u32-vsnprintf.c: New file.
1020         * lib/unistdio/u32-vsprintf.c: New file.
1021         * lib/unistdio/u32-u32-asnprintf.c: New file.
1022         * lib/unistdio/u32-u32-asprintf.c: New file.
1023         * lib/unistdio/u32-u32-snprintf.c: New file.
1024         * lib/unistdio/u32-u32-sprintf.c: New file.
1025         * lib/unistdio/u32-u32-vasnprintf.c: New file.
1026         * lib/unistdio/u32-u32-vasprintf.c: New file.
1027         * lib/unistdio/u32-u32-vsnprintf.c: New file.
1028         * lib/unistdio/u32-u32-vsprintf.c: New file.
1029         * tests/unistdio/test-ulc-asnprintf1.c: New file.
1030         * tests/unistdio/test-ulc-asnprintf1.h: New file.
1031         * tests/unistdio/test-ulc-printf1.h: New file.
1032         * tests/unistdio/test-ulc-vasnprintf1.c: New file.
1033         * tests/unistdio/test-ulc-vasnprintf2.c: New file.
1034         * tests/unistdio/test-ulc-vasnprintf2.sh: New file.
1035         * tests/unistdio/test-ulc-vasnprintf3.c: New file.
1036         * tests/unistdio/test-ulc-vasnprintf3.sh: New file.
1037         * tests/unistdio/test-ulc-vasprintf1.c: New file.
1038         * tests/unistdio/test-ulc-vsnprintf1.c: New file.
1039         * tests/unistdio/test-ulc-vsprintf1.c: New file.
1040         * tests/unistdio/test-u8-asnprintf1.c: New file.
1041         * tests/unistdio/test-u8-asnprintf1.h: New file.
1042         * tests/unistdio/test-u8-printf1.h: New file.
1043         * tests/unistdio/test-u8-vasnprintf1.c: New file.
1044         * tests/unistdio/test-u8-vasnprintf2.c: New file.
1045         * tests/unistdio/test-u8-vasnprintf2.sh: New file.
1046         * tests/unistdio/test-u8-vasnprintf3.c: New file.
1047         * tests/unistdio/test-u8-vasnprintf3.sh: New file.
1048         * tests/unistdio/test-u8-vasprintf1.c: New file.
1049         * tests/unistdio/test-u8-vsnprintf1.c: New file.
1050         * tests/unistdio/test-u8-vsprintf1.c: New file.
1051         * tests/unistdio/test-u16-asnprintf1.c: New file.
1052         * tests/unistdio/test-u16-asnprintf1.h: New file.
1053         * tests/unistdio/test-u16-printf1.h: New file.
1054         * tests/unistdio/test-u16-vasnprintf1.c: New file.
1055         * tests/unistdio/test-u16-vasnprintf2.c: New file.
1056         * tests/unistdio/test-u16-vasnprintf2.sh: New file.
1057         * tests/unistdio/test-u16-vasnprintf3.c: New file.
1058         * tests/unistdio/test-u16-vasnprintf3.sh: New file.
1059         * tests/unistdio/test-u16-vasprintf1.c: New file.
1060         * tests/unistdio/test-u16-vsnprintf1.c: New file.
1061         * tests/unistdio/test-u16-vsprintf1.c: New file.
1062         * tests/unistdio/test-u32-asnprintf1.c: New file.
1063         * tests/unistdio/test-u32-asnprintf1.h: New file.
1064         * tests/unistdio/test-u32-printf1.h: New file.
1065         * tests/unistdio/test-u32-vasnprintf1.c: New file.
1066         * tests/unistdio/test-u32-vasnprintf2.c: New file.
1067         * tests/unistdio/test-u32-vasnprintf2.sh: New file.
1068         * tests/unistdio/test-u32-vasnprintf3.c: New file.
1069         * tests/unistdio/test-u32-vasnprintf3.sh: New file.
1070         * tests/unistdio/test-u32-vasprintf1.c: New file.
1071         * tests/unistdio/test-u32-vsnprintf1.c: New file.
1072         * tests/unistdio/test-u32-vsprintf1.c: New file.
1073         * modules/unistdio/base: New file.
1074         * modules/unistdio/u-printf-args: New file.
1075         * modules/unistdio/ulc-asnprintf: New file.
1076         * modules/unistdio/ulc-asprintf: New file.
1077         * modules/unistdio/ulc-fprintf: New file.
1078         * modules/unistdio/ulc-printf-parse: New file.
1079         * modules/unistdio/ulc-snprintf: New file.
1080         * modules/unistdio/ulc-sprintf: New file.
1081         * modules/unistdio/ulc-vasnprintf: New file.
1082         * modules/unistdio/ulc-vasprintf: New file.
1083         * modules/unistdio/ulc-vfprintf: New file.
1084         * modules/unistdio/ulc-vsnprintf: New file.
1085         * modules/unistdio/ulc-vsprintf: New file.
1086         * modules/unistdio/u8-asnprintf: New file.
1087         * modules/unistdio/u8-asprintf: New file.
1088         * modules/unistdio/u8-printf-parse: New file.
1089         * modules/unistdio/u8-snprintf: New file.
1090         * modules/unistdio/u8-sprintf: New file.
1091         * modules/unistdio/u8-vasnprintf: New file.
1092         * modules/unistdio/u8-vasprintf: New file.
1093         * modules/unistdio/u8-vsnprintf: New file.
1094         * modules/unistdio/u8-vsprintf: New file.
1095         * modules/unistdio/u8-u8-asnprintf: New file.
1096         * modules/unistdio/u8-u8-asprintf: New file.
1097         * modules/unistdio/u8-u8-snprintf: New file.
1098         * modules/unistdio/u8-u8-sprintf: New file.
1099         * modules/unistdio/u8-u8-vasnprintf: New file.
1100         * modules/unistdio/u8-u8-vasprintf: New file.
1101         * modules/unistdio/u8-u8-vsnprintf: New file.
1102         * modules/unistdio/u8-u8-vsprintf: New file.
1103         * modules/unistdio/u16-asnprintf: New file.
1104         * modules/unistdio/u16-asprintf: New file.
1105         * modules/unistdio/u16-printf-parse: New file.
1106         * modules/unistdio/u16-snprintf: New file.
1107         * modules/unistdio/u16-sprintf: New file.
1108         * modules/unistdio/u16-vasnprintf: New file.
1109         * modules/unistdio/u16-vasprintf: New file.
1110         * modules/unistdio/u16-vsnprintf: New file.
1111         * modules/unistdio/u16-vsprintf: New file.
1112         * modules/unistdio/u16-u16-asnprintf: New file.
1113         * modules/unistdio/u16-u16-asprintf: New file.
1114         * modules/unistdio/u16-u16-snprintf: New file.
1115         * modules/unistdio/u16-u16-sprintf: New file.
1116         * modules/unistdio/u16-u16-vasnprintf: New file.
1117         * modules/unistdio/u16-u16-vasprintf: New file.
1118         * modules/unistdio/u16-u16-vsnprintf: New file.
1119         * modules/unistdio/u16-u16-vsprintf: New file.
1120         * modules/unistdio/u32-asnprintf: New file.
1121         * modules/unistdio/u32-asprintf: New file.
1122         * modules/unistdio/u32-printf-parse: New file.
1123         * modules/unistdio/u32-snprintf: New file.
1124         * modules/unistdio/u32-sprintf: New file.
1125         * modules/unistdio/u32-vasnprintf: New file.
1126         * modules/unistdio/u32-vasprintf: New file.
1127         * modules/unistdio/u32-vsnprintf: New file.
1128         * modules/unistdio/u32-vsprintf: New file.
1129         * modules/unistdio/u32-u32-asnprintf: New file.
1130         * modules/unistdio/u32-u32-asprintf: New file.
1131         * modules/unistdio/u32-u32-snprintf: New file.
1132         * modules/unistdio/u32-u32-sprintf: New file.
1133         * modules/unistdio/u32-u32-vasnprintf: New file.
1134         * modules/unistdio/u32-u32-vasprintf: New file.
1135         * modules/unistdio/u32-u32-vsnprintf: New file.
1136         * modules/unistdio/u32-u32-vsprintf: New file.
1137         * modules/unistdio/ulc-asnprintf-tests: New file.
1138         * modules/unistdio/ulc-vasnprintf-tests: New file.
1139         * modules/unistdio/ulc-vasprintf-tests: New file.
1140         * modules/unistdio/ulc-vsnprintf-tests: New file.
1141         * modules/unistdio/ulc-vsprintf-tests: New file.
1142         * modules/unistdio/u8-asnprintf-tests: New file.
1143         * modules/unistdio/u8-vasnprintf-tests: New file.
1144         * modules/unistdio/u8-vasprintf-tests: New file.
1145         * modules/unistdio/u8-vsnprintf-tests: New file.
1146         * modules/unistdio/u8-vsprintf-tests: New file.
1147         * modules/unistdio/u16-asnprintf-tests: New file.
1148         * modules/unistdio/u16-vasnprintf-tests: New file.
1149         * modules/unistdio/u16-vasprintf-tests: New file.
1150         * modules/unistdio/u16-vsnprintf-tests: New file.
1151         * modules/unistdio/u16-vsprintf-tests: New file.
1152         * modules/unistdio/u32-asnprintf-tests: New file.
1153         * modules/unistdio/u32-vasnprintf-tests: New file.
1154         * modules/unistdio/u32-vasprintf-tests: New file.
1155         * modules/unistdio/u32-vsnprintf-tests: New file.
1156         * modules/unistdio/u32-vsprintf-tests: New file.
1157         * MODULES.html.sh (Unicode string functions): Add the new modules.
1158
1159 2007-07-01  Bruno Haible  <bruno@clisp.org>
1160
1161         * lib/sprintf.c (sprintf): Limit the available length estimation,
1162         to avoid address wraparound.
1163         * lib/vsprintf.c (vsprintf): Likewise.
1164         * modules/sprintf-posix (Dependencies): Add stdint.
1165         * modules/vsprintf-posix (Dependencies): Likewise.
1166
1167 2007-07-01  Bruno Haible  <bruno@clisp.org>
1168
1169         * gnulib-tool (self_abspathname): Determine PATH_SEPARATOR and handle
1170         Windows PATH as well. Conservative double-quoting. Comments.
1171
1172 2007-07-01  Bruno Haible  <bruno@clisp.org>
1173             Eric Blake  <ebb9@byu.net>
1174             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1175
1176         * gnulib-tool (self_abspathname): Fix algorithm to cope with
1177         empty components in $PATH, denoting '.'.
1178
1179 2007-07-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1180
1181         * gnulib-tool: Fix indentation.
1182         (func_create_megatestdir): Likewise.
1183         Report by Bruno Haible.
1184
1185 2007-06-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1186
1187         Sync from Automake.
1188         * build-aux/gnupload: Fix shell portability issues with for loops.
1189         Report by Karl Berry.
1190
1191 2007-06-29  Simon Josefsson  <simon@josefsson.org>
1192
1193         * build-aux/maint.mk (POURL): Use translationproject.org.
1194
1195 2007-06-27  Simon Josefsson  <simon@josefsson.org>
1196             Bruno Haible  <bruno@clisp.org>
1197
1198         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Require gl_HEADER_SYS_SOCKET
1199         before using HAVE_WS2TCPIP_H. Check for gai_strerror through an
1200         explicit link test, rather than AC_REPLACE_FUNCS - for mingw.
1201         (gl_PREREQ_GETADDRINFO): Require gl_HEADER_SYS_SOCKET before using
1202         HAVE_SYS_SOCKET_H and HAVE_WS2TCPIP_H.
1203
1204 2007-06-27  Bruno Haible  <bruno@clisp.org>
1205
1206         * build-aux/config.rpath: Upgrade to libtool-1.5.24.
1207         * build-aux/config.libpath: Upgrade to libtool-1.5.24.
1208
1209 2007-06-26  Karl Berry  <karl@gnu.org>
1210
1211         * MODULES.html.sh: remove xreadlink-with-size.
1212
1213 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
1214
1215         * lib/time_.h: Port to Solaris 8 with Sun Studio 11, using a
1216         method that I hope also handles the double-include problem noted
1217         by Bruno Haible in
1218         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00186.html>.
1219
1220 2007-06-23  Bruno Haible  <bruno@clisp.org>
1221
1222         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
1223         Don't let the 'mostlyclean' target fail if the last subdirectory could
1224         not be removed.
1225         Reported by Karl Berry.
1226
1227 2007-06-23  Bruno Haible  <bruno@clisp.org>
1228
1229         * gnulib-tool (echo): Add a speedier workaround for ksh.
1230         * tests/test-echo.sh: Likewise.
1231
1232 2007-06-23  Bruno Haible  <bruno@clisp.org>
1233
1234         * gnulib-tool (echo): Add workarounds also for bash versions < 2.04.
1235         * tests/test-echo.sh: Likewise.
1236
1237 2007-06-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1238
1239         * gnulib-tool (IFS): Initialize early, so we don't set it to
1240         empty later.
1241         (self_abspathname): Rewrite algorithm to set it, reindent.
1242         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am)
1243         (func_create_megatestdir): Merge some sed scripts.
1244
1245 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
1246
1247         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Check some typos
1248         exposed by Sun Studio 11 cc on Solaris 8.
1249
1250 2007-06-22  Bruno Haible  <bruno@clisp.org>
1251
1252         * gnulib-tool (echo): Ensure the echo primitive does not interpret
1253         backslashes.
1254         * tests/test-echo.sh: New file.
1255
1256 2007-06-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1257
1258         * gnulib-tool (func_add_or_update, func_create_testdir): Do not
1259         simplify `sed_replace_build_aux' scripts, they are portable but
1260         echoing them with `echo' is not.
1261         Report and analysis by Fernando Ferreira <fernando.prog@netcabo.pt>.
1262
1263 2007-06-21  Karl Berry  <karl@gnu.org>
1264
1265         * config/srclist.txt: guess we can't handle the licenses via
1266         srclist at the moment.
1267
1268 2007-06-21  Paul Eggert  <eggert@cs.ucla.edu>
1269
1270         * MODULES.html.sh: Add include_next.
1271         * modules/include_next: New file.
1272
1273 2007-06-20  Paul Eggert  <eggert@cs.ucla.edu>
1274
1275         * m4/include_next.m4 (gl_INCLUDE_NEXT): Define and AC_SUBST
1276         INCLUDE_NEXT.
1277         (gl_CHECK_NEXT_HEADERS): New macro.
1278         * m4/fcntl_h.m4 (gl_FCNTL_H): use gl_CHECK_NEXT_HEADERS instead of
1279         the obsolescent gl_ABSOLUTE_HEADER.
1280         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
1281         * m4/float_h.m4 (gl_FLOAT_H): Likewise.
1282         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
1283         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
1284         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
1285         * m4/math_h.m4 (gl_MATH_H): Likewise.
1286         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
1287         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
1288         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
1289         * m4/stdint.m4 (gl_STDINT_H): Likewise.
1290         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
1291         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
1292         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
1293         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
1294         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
1295         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
1296         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
1297         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
1298         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Likewise.
1299         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
1300         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
1301         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
1302         * m4/inttypes.m4 (gl_INTTYPES_H): Define
1303         _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H to avoid the problem of unclean
1304         builds, since ABSOLUTE_INTTYPES_H is no longer being defined.
1305         * m4/stdint.m4 (gl_STDINT_H): Likewise, for
1306         _GL_JUST_INCLUDE_SYSTEM_STDINT_H.
1307         * lib/fcntl_.h: Use @INCLUDE_NEXT@ @NEXT_foo_H@
1308         rather than @HAVE_INCLUDE_NEXT@ and @ABSOLUTE_foo_H@.
1309         * lib/float_.h: Likewise.
1310         * lib/inttypes_.h: Likewise.
1311         * lib/math_.h: Likewise.
1312         * lib/search_.h: Likewise.
1313         * lib/signal_.h: Likewise.
1314         * lib/stdint_.h: Likewise.
1315         * lib/stdio_.h: Likewise.
1316         * lib/stdlib_.h: Likewise.
1317         * lib/string_.h: Likewise.
1318         * lib/sys_stat_.h: Likewise.
1319         * lib/sys_time_.h: Likewise.
1320         * lib/time_.h: Likewise.
1321         * lib/unistd_.h: Likewise.
1322         * lib/wchar_.h: Likewise.
1323         * lib/wctype_.h: Likewise.
1324         * lib/dirent_.h: Likewise.
1325         * lib/iconv_.h: Likewise.
1326         * lib/locale_.h: Likewise.
1327         * lib/netinet_in_.h: Likewise.
1328         * lib/sys_select_.h: Likewise.
1329         * lib/sys_socket_.h: Likewise.
1330         * lib/sysexits_.h: Likewise.
1331         * modules/fcntl (Depends-on): Depend on include_next, not
1332         absolute_header.
1333         (Makefile): Substitute INCLUDE_NEXT and NEXT_foo_H, not
1334         HAVE_INCLUDE_NEXT and ABSOLUTE_foo_H.
1335         * modules/fchdir: Likewise.
1336         * modules/float: Likewise.
1337         * modules/iconv_open: Likewise.
1338         * modules/inttypes: Likewise.
1339         * modules/locale: Likewise.
1340         * modules/math: Likewise.
1341         * modules/netinet_in: Likewise.
1342         * modules/search: Likewise.
1343         * modules/signal: Likewise.
1344         * modules/stdint: Likewise.
1345         * modules/stdio: Likewise.
1346         * modules/stdlib: Likewise.
1347         * modules/string: Likewise.
1348         * modules/sys_select: Likewise.
1349         * modules/sys_socket: Likewise.
1350         * modules/sys_stat: Likewise.
1351         * modules/sys_time: Likewise.
1352         * modules/sysexits: Likewise.
1353         * modules/time: Likewise.
1354         * modules/unistd: Likewise.
1355         * modules/wchar: Likewise.
1356         * modules/wctype: Likewise.
1357         * modules/sys_stat: Change maintainer to "all".
1358         * modules/unistd: Likewise.
1359
1360 2007-06-20  Karl Berry  <karl@gnu.org>
1361
1362         * config/srclist.txt: track www changes in license files.
1363
1364 2007-06-20  Sergey Poznyakoff  <gray@gnu.org.ua>
1365
1366         * build-aux/bootstrap: Remove stray dot.
1367         Make sure build_aux settings are honored when linking
1368         gnulib_extra_files.
1369
1370 2007-06-19  Eric Blake  <ebb9@byu.net>
1371
1372         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
1373         Allow compilation on cygwin.
1374
1375 2007-06-19  Jim Meyering  <jim@meyering.net>
1376
1377         xreadlink-with-size: Remove module.  No longer used.
1378         Ex-callers now use xreadlink or mreadlink-with-size.
1379         * modules/xreadlink-with-size: Remove module.
1380         * lib/xreadlink-with-size.c: Remove file.
1381         * lib/xreadlink.h (xreadlink_with_size): Remove prototype.
1382         (xreadlink): Remove inaccurate comment.  The one in xreadlink.c,
1383         just before the function definition *is* accurate.
1384
1385         Eliminate one way canonicalize_filename_mode could exit.
1386         * lib/canonicalize.c (canonicalize_filename_mode):
1387         Use mreadlink_with_size, not xreadlink_with_size.
1388
1389 2007-06-18  Paul Eggert  <eggert@cs.ucla.edu>
1390
1391         Detect porting problems to FreeBSD/arm, which has time_t wider than
1392         long int.  Original problem reported for GNU diff by Xin Li in
1393         <http://lists.gnu.org/archive/html/bug-gnu-utils/2007-06/msg00091.html>.
1394         * modules/getdate (Depends-on): Add intprops, verify.
1395         * lib/getdate.y: Include intprops.h, verify.h.  Verify that time_t
1396         is an integer type no wider than long int.
1397
1398 2007-06-18  Jim Meyering  <jim@meyering.net>
1399
1400         New module: mreadlink-with-size.
1401         * MODULES.html.sh: Add mreadlink-with-size.
1402         * modules/mreadlink-with-size: New module
1403         * modules/canonicalize (Depends-on): Depend on mreadlink-with-size,
1404         not xreadlink-with-size.
1405         * lib/mreadlink-with-size.c, lib/mreadlink.h: New files.
1406
1407 2007-06-16  Bruno Haible  <bruno@clisp.org>
1408
1409         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Catch the MacOS X 10.4 bug.
1410         * doc/functions/frexpl.texi: Document the MacOS X 10.4 bug.
1411         Reported by Gary V. Vaughan <gary@gnu.org>.
1412
1413 2007-06-15  Paul Eggert  <eggert@cs.ucla.edu>
1414
1415         Revamp lchown so that it lives in unistd.h where it belongs.
1416         * lib/lchown.h: Remove.
1417         * lib/dirchownmod.c: Don't include lib/lchown.h.
1418         * lib/fchownat.c: Likewise.
1419         * lib/openat.c: Likewise.
1420         * lib/lchown.c (REPLACE_CHOWN): Define to 0 if the system chown
1421         does not follow symlinks.
1422         (EOPNOTSUPP): Define if not defined.
1423         * lib/unistd_.h (chown): Do not replace if REPLADE_CHOWN
1424         is defined to 0.
1425         (lchown): New decl.
1426         * m4/lchown.m4 (gl_FUNC_LCHOWN): Require gl_UNISTD_H_DEFAULTS.
1427         Do not check for lchown decl.
1428         Set REPLACE_LCHOWN.
1429         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set GNULIB_LCHOWN,
1430         REPLACE_LCHOWN.
1431         * modules/chown: Make it clear it follows symlinks.
1432         * modules/lchown: Make it clear it doesn't follow symlinks.
1433         (Files): Remove lib/lchown.h
1434         (Depends-on): Add unistd.
1435         (configure.ac): Add gl_UNISTD_MODULE_INDICATOR([lchown]).
1436         (Include): Include <unistd.h>, not "lchown.h".
1437         * modules/unistd (unistd.h): Substitude GNULIB_LCHOWN and
1438         REPLACE_LCHOWN.
1439
1440 2007-06-15  Jim Meyering  <jim@meyering.net>
1441
1442         Change license (GPL to LGPL) of fsusage and dependents.
1443         * modules/fsusage (License): Change to LGPL.
1444         * modules/full-read (License): Likewise.
1445         * modules/full-write (License): Likewise.
1446         * modules/safe-read (License): Likewise.
1447         * modules/safe-write (License): Likewise.
1448
1449 2007-06-14  Ben Pfaff  <blp@gnu.org>
1450
1451         Missing part of allocsa -> malloca transition.
1452         * modules/relocatable-prog-wrapper: gl_ALLOCSA should be
1453         gl_MALLOCA.
1454
1455 2007-06-12  Bruno Haible  <bruno@clisp.org>
1456
1457         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Guess no when cross-compiling
1458         to ia64, x86_64, i386.
1459         Reported by Eric Blake.
1460
1461 2007-06-12  Bruno Haible  <bruno@clisp.org>
1462
1463         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Guess no also when
1464         cross-compiling to x86_64.
1465
1466 2007-06-12  Paul Eggert  <eggert@cs.ucla.edu>
1467
1468         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Fix POSIX sed portability
1469         glitch reported by Ralf Wildenhues in
1470         <http://lists.gnu.org/archive/html/bug-gnulib/2007-06/msg00114.html>.
1471
1472         * m4/regex.m4 (gl_REGEX): Catch a bug with [[:alnum:]_-] reported by
1473         Vin Shelton.
1474
1475 2007-06-11  Bruno Haible  <bruno@clisp.org>
1476
1477         * lib/printf-args.c (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Fix NULL
1478         replacement string.
1479         Reported by Eric Blake.
1480
1481 2007-06-10  Bruno Haible  <bruno@clisp.org>
1482
1483         Prepare vasnprintf code for use with Unicode strings.
1484         * lib/printf-args.h (PRINTF_FETCHARGS): New macro.
1485         (arg_type) [ENABLE_UNISTDIO]: Define TYPE_U8_STRING, TYPE_U16_STRING,
1486         TYPE_U32_STRING.
1487         (argument) [ENABLE_UNISTDIO]: Add a_u8_string, a_u16_string,
1488         a_u32_string variants.
1489         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
1490         * lib/printf-args.c: Don't include config.h and the specification
1491         header if PRINTF_FETCHARGS is already defined.
1492         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
1493         (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Add code for TYPE_U8_STRING,
1494         TYPE_U16_STRING, TYPE_U32_STRING.
1495         * lib/printf-parse.h [ENABLE_UNISTDIO] (u8_directive, u8_directives,
1496         u16_directive, u16_directives, u32_directive, u32_directives): New
1497         types.
1498         (ulc_printf_parse, u8_printf_parse, u16_printf_parse, u32_printf_parse):
1499         New declarations.
1500         * lib/printf-parse.c: Don't include config.h and the specification
1501         header if PRINTF_PARSE is already defined. Eliminate the set of
1502         parameters for WIDE_CHAR_VERSION; the user of this file must provide
1503         them now. Include c-ctype.h.
1504         (PRINTF_PARSE) [ENABLE_UNISTDIO]: Add code implementing the 'U'
1505         directive and CHAR_T_ONLY_ASCII.
1506         * lib/vasnprintf.c: Don't include config.h and the specification header
1507         if VASNPRINTF is already defined.
1508         (DCHAR_IS_TCHAR, DCHAR_CPY): New macros.
1509         (VASNPRINTF): Use PRINTF_FETCHARGS instead of printf_fetchargs. Use
1510         DCHAR_CPY. Handle the case that DCHAR_T and FCHAR_T are not the same
1511         type. Handle the case that TCHAR_T and FCHAR_T are not of the same
1512         size. Handle the case that DCHAR_T and TCHAR_T are not the same type,
1513         add a conversion from TCHAR_T[] to DCHAR_T[], and rework the padding
1514         code accordingly.
1515         (VASNPRINTF) [ENABLE_UNISTDIO]: Implement the 'U' directive. Enable
1516         pad_ourselves also in this case, with the 'c' and 's' directives, and
1517         with a different notion of "width".
1518         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): New macros.
1519
1520 2007-06-10  Bruno Haible  <bruno@clisp.org>
1521
1522         * modules/unistr/u32-mbsnlen: New file.
1523         * lib/unistr/u32-mbsnlen.c: New file.
1524
1525         * modules/unistr/u16-mbsnlen: New file.
1526         * lib/unistr/u16-mbsnlen.c: New file.
1527
1528         * modules/unistr/u8-mbsnlen: New file.
1529         * lib/unistr/u8-mbsnlen.c: New file.
1530
1531         * lib/unistr.h (u8_mbsnlen, u16_mbsnlen, u32_mbsnlen): New
1532         declarations.
1533
1534 2007-06-10  Bruno Haible  <bruno@clisp.org>
1535
1536         * lib/string_.h (mbsnlen): New declaration.
1537         * lib/mbsnlen.c: New file.
1538         * m4/mbsnlen.m4: New file.
1539         * modules/mbsnlen: New file.
1540         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set GNULIB_MBSNLEN.
1541         * modules/string (string.h): Substitute GNULIB_MBSNLEN.
1542         * MODULES.html.sh (Internationalization functions): Add mbsnlen.
1543
1544 2007-06-10  Bruno Haible  <bruno@clisp.org>
1545
1546         * lib/mbslen.c: Include <stdlib.h>, needed for MB_CUR_MAX.
1547
1548 2007-06-10  Bruno Haible  <bruno@clisp.org>
1549
1550         * lib/mbiter.h: Include <stddef.h>, needed for ptrdiff_t.
1551         * lib/mbuiter.h: Likewise.
1552
1553 2007-06-10  Bruno Haible  <bruno@clisp.org>
1554
1555         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Check for _snprintf
1556         declaration.
1557
1558 2007-06-10  Karl Berry  <karl@gnu.org>
1559
1560         * config/srclist.txt: remove gettext entries, Bruno prefers
1561         to update individually.
1562
1563 2007-06-10  Bruno Haible  <bruno@clisp.org>
1564
1565         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Remove variable
1566         'maxlen'. Ensure only length + width bytes are allocated, not
1567         length + 1 + width.
1568
1569 2007-06-09  Bruno Haible  <bruno@clisp.org>
1570
1571         * lib/vasnprintf.c (FCHAR_T, DCHAR_T, TCHAR_T): New macros.
1572         (CHAR_T): Remove macro.
1573         (VASNPRINTF): Update.
1574
1575 2007-06-09  Bruno Haible  <bruno@clisp.org>
1576
1577         * MODULES.html.sh (Unicode string functions): Add the new modules.
1578
1579         * modules/uniconv/u32-conv-to-enc: New file.
1580         * lib/uniconv/u32-conv-to-enc.c: New file.
1581         * modules/uniconv/u32-conv-to-enc-tests: New file.
1582         * tests/uniconv/test-u32-conv-to-enc.c: New file.
1583
1584         * modules/uniconv/u16-conv-to-enc: New file.
1585         * lib/uniconv/u16-conv-to-enc.c: New file.
1586         * lib/uniconv/u-conv-to-enc.h: New file.
1587         * modules/uniconv/u16-conv-to-enc-tests: New file.
1588         * tests/uniconv/test-u16-conv-to-enc.c: New file.
1589
1590         * modules/uniconv/u8-conv-to-enc: New file.
1591         * lib/uniconv/u8-conv-to-enc.c: New file.
1592         * modules/uniconv/u8-conv-to-enc-tests: New file.
1593         * tests/uniconv/test-u8-conv-to-enc.c: New file.
1594
1595         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
1596         u32_conv_to_encoding): New declarations.
1597
1598 2007-06-09  Bruno Haible  <bruno@clisp.org>
1599
1600         * tests/uniconv/test-u32-strconv-to-enc.c (main): Remove unused code.
1601
1602 2007-06-09  Bruno Haible  <bruno@clisp.org>
1603
1604         Rename 'allocsa' -> 'malloca', 'freesa' -> 'freea'.
1605         * modules/malloca: Renamed from modules/allocsa, updated.
1606         * lib/malloca.h: Renamed from lib/allocsa.h, updated.
1607         * lib/malloca.c: Renamed from lib/allocsa.c, updated.
1608         * lib/malloca.valgrind: Renamed from lib/allocsa.valgrind, updated.
1609         * m4/malloca.m4: Renamed from m4/allocsa.m4, updated.
1610         * modules/malloca-tests: Renamed from modules/allocsa-tests, updated.
1611         * tests/test-malloca.c: Renamed from tests/test-allocsa.c, updated.
1612         * modules/xmalloca: Renamed from modules/xallocsa, updated.
1613         * lib/xmalloca.h: Renamed from lib/xallocsa.h, updated.
1614         * lib/xmalloca.c: Renamed from lib/xallocsa.c, updated.
1615         * modules/c-strcasestr (Depends-on): Update.
1616         * lib/c-strcasestr.c: Update.
1617         * modules/c-strstr (Depends-on): Update.
1618         * lib/c-strstr.c: Update.
1619         * modules/canonicalize-lgpl (Depends-on): Update.
1620         * lib/canonicalize-lgpl.c: Update.
1621         * modules/clean-temp (Depends-on): Update.
1622         * lib/clean-temp.c: Update.
1623         * modules/csharpcomp (Depends-on): Update.
1624         * lib/csharpcomp.c: Update.
1625         * modules/csharpexec (Depends-on): Update.
1626         * lib/csharpexec.c: Update.
1627         * modules/javacomp (Depends-on): Update.
1628         * lib/javacomp.c: Update.
1629         * modules/javaexec (Depends-on): Update.
1630         * lib/javaexec.c: Update.
1631         * modules/mbscasestr (Depends-on): Update.
1632         * lib/mbscasestr.c: Update.
1633         * modules/mbsstr (Depends-on): Update.
1634         * lib/mbsstr.c: Update.
1635         * modules/setenv (Depends-on): Update.
1636         * lib/setenv.c: Update.
1637         * modules/strcasestr (Depends-on): Update.
1638         * lib/strcasestr.c: Update.
1639         * modules/striconveha (Depends-on): Update.
1640         * lib/striconveha.c: Update.
1641         * modules/relocatable-prog-wrapper (Files): Update.
1642         * lib/relocwrapper.c: Update.
1643         * build-aux/install-reloc: Update.
1644         * MODULES.html.sh (Memory management functions <stdlib.h>): Update.
1645
1646 2007-06-08  Bruno Haible  <bruno@clisp.org>
1647
1648         Port to uClibc.
1649         * lib/fbufmode.c (fbufmode): Add special code for uClibc.
1650         * lib/fpurge.c (fpurge): Likewise.
1651         * lib/freading.c (freading): Likewise.
1652         * lib/fseeko.c (rpl_fseeko): Likewise.
1653         * lib/fseterr.c (fseterr): Likewise.
1654         * lib/fwriting.c (fwriting): Likewise.
1655         * tests/test-fflush.c (main): Avoid a failure on uClibc.
1656
1657 2007-06-08  Bruno Haible  <bruno@clisp.org>
1658
1659         * m4/intlmacosx.m4: New file, extracted from gettext.m4.
1660         * m4/gettext.m4 (gt_INTL_MACOSX): Remove macro, moved to intlmacosx.m4.
1661         * modules/gettext (Files): Add m4/intlmacosx.m4.
1662
1663 2007-06-07  Bruno Haible  <bruno@clisp.org>
1664
1665         * modules/localename-tests: New file.
1666         * tests/test-localename.c: New file.
1667
1668         New module 'localename'.
1669         * lib/localename.h: New file.
1670         * lib/localename.c: New file, from GNU gettext.
1671         * m4/localename.m4: New file.
1672         * modules/localename: New file.
1673
1674 2007-06-07  Bruno Haible  <bruno@clisp.org>
1675
1676         Work around the lack of <wchar.h> on some builds of uClibc.
1677         * doc/headers/wchar.texi: Update.
1678         * lib/wchar_.h: Include <wchar.h> only if it exists.
1679         * m4/wchar.m4 (gl_WCHAR_H): Check for <wchar.h>. Set HAVE_WCHAR_H.
1680         * m4/stdint.m4 (gl_STDINT_H): Check for <wchar.h>.
1681         (gl_STDINT_TYPE_PROPERTIES): Don't try to include <wchar.h> if it
1682         doesn't exist.
1683         * modules/wchar (wchar.h): Substitute HAVE_WCHAR_H.
1684         * modules/mbfile (Depends-on): Add wchar.
1685         * modules/mbiter (Depends-on): Likewise.
1686         * modules/mbuiter (Depends-on): Likewise.
1687         Reported by Simon Josefsson.
1688
1689 2007-06-06  Paul Eggert  <eggert@cs.ucla.edu>
1690
1691         Work around problem reported by Steven M. Schweda in
1692         <http://lists.gnu.org/archive/html/bug-tar/2007-06/msg00002.html>:
1693         Tru64 5.1B with the Compaq compiler environment installed declares
1694         an 'isblank' function but does not define it in the C library.
1695         * lib/fnmatch.c (isblank): Check for HAVE_ISBLANK, too.
1696         * lib/regex_internal.h (isblank): Likewise.
1697         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for isblank existence.
1698         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
1699
1700 2007-06-05  Bruno Haible  <bruno@clisp.org>
1701
1702         Fix *printf so that it recognizes non-IEEE numbers on i386, x86_64,
1703         ia64.
1704         * modules/printf-safe: New file.
1705         * modules/fprintf-posix (Depends-on): Add printf-safe.
1706         * modules/printf-posix (Depends-on): Likewise.
1707         * modules/snprintf-posix (Depends-on): Likewise.
1708         * modules/sprintf-posix (Depends-on): Likewise.
1709         * modules/vasnprintf-posix (Depends-on): Likewise.
1710         * modules/vasprintf-posix (Depends-on): Likewise.
1711         * modules/vfprintf-posix (Depends-on): Likewise.
1712         * modules/vprintf-posix (Depends-on): Likewise.
1713         * modules/vsnprintf-posix (Depends-on): Likewise.
1714         * modules/vsprintf-posix (Depends-on): Likewise.
1715         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Require
1716         AC_C_BIGENDIAN. Define CHECK_PRINTF_SAFE if printf-safe is used. Test
1717         non-IEEE numbers on i386, x86_64, ia64. When cross-compiling, guess
1718         "no" on i386, x86_64, ia64.
1719         * tests/test-snprintf-posix.h (LDBL80_WORDS): New macro.
1720         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1721         on i386, x86_64, ia64.
1722         * tests/test-sprintf-posix.h (LDBL80_WORDS): New macro.
1723         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1724         on i386, x86_64, ia64.
1725         * tests/test-vasnprintf-posix.c: Include float.h.
1726         (LDBL80_WORDS): New macro.
1727         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1728         on i386, x86_64, ia64.
1729         * tests/test-vasprintf-posix.c: Include float.h.
1730         (LDBL80_WORDS): New macro.
1731         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1732         on i386, x86_64, ia64.
1733         * tests/test-snprintf-posix.c: Include float.h.
1734         * tests/test-sprintf-posix.c: Likewise.
1735         * tests/test-vsnprintf-posix.c: Likewise.
1736         * tests/test-vsprintf-posix.c: Likewise.
1737
1738 2007-06-05  Bruno Haible  <bruno@clisp.org>
1739
1740         Fix isnanl so that it recognizes non-IEEE numbers on i386, x86_64, ia64.
1741         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Require AC_C_BIGENDIAN. Test
1742         non-IEEE numbers on i386, x86_64, ia64.
1743         (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require AC_C_BIGENDIAN.
1744         * lib/isnan.c (FUNC): Add special code for i386, x86_64, ia64.
1745         * tests/test-isnanl.h: Include float.h.
1746         (main): Check also non-IEEE numbers on i386, x86_64, ia64.
1747
1748 2007-06-05  Bruno Haible  <bruno@clisp.org>
1749
1750         * lib/vasnprintf.c (VASNPRINTF): Do the extra handling of NaN and Inf
1751         also the %a / %A. Handle the %a / %A code before this extra handling.
1752
1753 2007-06-05  Bruno Haible  <bruno@clisp.org>
1754
1755         * lib/vasnprintf.c [NEED_PRINTF_LONG_DOUBLE ||
1756         NEED_PRINTF_INFINITE_LONG_DOUBLE]: Include fpucw.h.
1757
1758 2007-06-05  Bruno Haible  <bruno@clisp.org>
1759
1760         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): Fix
1761         typo in variable name.
1762
1763 2007-06-05  Eric Blake  <ebb9@byu.net>
1764
1765         * m4/lseek.m4 (gl_FUNC_LSEEK): Work when cross-compiling.
1766         Reported by Simon Josefsson.
1767
1768 2007-06-04  Bruno Haible  <bruno@clisp.org>
1769
1770         Avoid test failures on some PowerPC platforms.
1771         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP):
1772         Define differently for PowerPC.
1773         * tests/test-frexpl.c (MIN_NORMAL_EXP): Likewise.
1774         Reported by Gary V. Vaughan <gary@gnu.org>.
1775
1776 2007-06-02  Bruno Haible  <bruno@clisp.org>
1777
1778         Fix test-stdint failure on FreeBSD/ia64.
1779         * m4/stdint.m4 (gl_STDINT_H): Check the values of PTRDIFF_MIN,
1780         PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN,
1781         WCHAR_MAX, WINT_MIN, WINT_MAX entirely, not only for plausibility.
1782         * doc/headers/stdint.texi: Update.
1783
1784 2007-06-01  Bruno Haible  <bruno@clisp.org>
1785
1786         * tests/test-binary-io.c (main): Pass a third argument to open().
1787         Reported by Gary V. Vaughan <gary@gnu.org>.
1788
1789 2007-06-01  Bruno Haible  <bruno@clisp.org>
1790
1791         * doc/functions/frexpl.texi: Update for mingw.
1792
1793 2007-06-01  Bruno Haible  <bruno@clisp.org>
1794
1795         * tests/test-lseek.c (main): Disable test of errno for invalid third
1796         argument.
1797         * doc/functions/lseek.texi: Update.
1798         Reported by Gary V. Vaughan <gary@gnu.org>.
1799
1800 2007-05-28  Bruno Haible  <bruno@clisp.org>
1801
1802         * m4/intl.m4 (AM_INTL_SUBDIR): Substitute variables WOE32, WINDRES.
1803
1804 2007-05-31  Eric Blake  <ebb9@byu.net>
1805
1806         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Guess no on mingw when
1807         cross compiling.
1808
1809 2007-05-30  Eric Blake  <ebb9@byu.net>
1810         and Bruno Haible  <bruno@clisp.org>
1811
1812         Work around mingw test failures exposed by m4-1.4.9b.
1813         * m4/stdint.m4 (gl_STDINT_H): Detect mingw bug.
1814         * tests/test-unistd.c: Disable uid_t and git_t tests for the
1815         moment.
1816
1817 2007-05-30  Bruno Haible  <bruno@clisp.org>
1818
1819         * tests/test-lseek.c: Explicitly close file descriptors 0 and 1 before
1820         assuming that they are closed. Needed on HP-UX 11.
1821
1822 2007-05-29  Bruno Haible  <bruno@clisp.org>
1823
1824         Fix a problem with #include_next.
1825         * lib/dirent_.h: Split the double-inclusion guard.
1826         * lib/fcntl_.h: Likewise.
1827         * lib/float_.h: Likewise.
1828         * lib/iconv_.h: Likewise.
1829         * lib/inttypes_.h: Likewise.
1830         * lib/locale_.h: Likewise.
1831         * lib/math_.h: Likewise.
1832         * lib/netinet_in_.h: Likewise.
1833         * lib/search_.h: Likewise.
1834         * lib/signal_.h: Likewise.
1835         * lib/stdint_.h: Likewise.
1836         * lib/stdio_.h: Likewise.
1837         * lib/stdlib_.h: Likewise.
1838         * lib/string_.h: Likewise.
1839         * lib/sys_select_.h: Likewise.
1840         * lib/sys_socket_.h: Likewise.
1841         * lib/sys_stat_.h: Likewise.
1842         * lib/sys_time_.h: Likewise.
1843         * lib/sysexits_.h: Likewise.
1844         * lib/time_.h: Likewise.
1845         * lib/unistd_.h: Likewise.
1846         * lib/wchar_.h: Likewise.
1847         * lib/wctype_.h: Likewise.
1848
1849 2007-05-29  Bruno Haible  <bruno@clisp.org>
1850
1851         * tests/test-unistd.c: Disable the tests for useconds_t and intptr_t
1852         for the moment.
1853
1854 2007-05-29  Bruno Haible  <bruno@clisp.org>
1855
1856         * m4/isnan.m4 (gl_DOUBLE_EXPONENT_LOCATION): Silence the AC_C_BIGENDIAN
1857         invocation.
1858         Reported by Eric Blake.
1859
1860 2007-05-29  Bruno Haible  <bruno@clisp.org>
1861
1862         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Fix typo in cross-
1863         compiling case.
1864
1865 2007-05-29  Eric Blake  <ebb9@byu.net>
1866             Bruno Haible  <bruno@clisp.org>
1867
1868         * m4/isnanf.m4 (gl_FUNC_ISNANF_NO_LIBM): Avoid syntax error on
1869         cross compiles.
1870
1871 2007-05-28  Eric Blake  <ebb9@byu.net>
1872
1873         * modules/closein-tests (test_closein_LDADD): Support test on
1874         cygwin with libtool.
1875
1876 2007-05-28  Bruno Haible  <bruno@clisp.org>
1877
1878         * tests/uniconv/test-u16-conv-from-enc.c: Remove #ifdef HAVE_CONFIG_H.
1879         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
1880         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
1881         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
1882         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
1883         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
1884         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
1885         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
1886         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
1887
1888 2007-05-28  Eric Blake  <ebb9@byu.net>
1889
1890         Unconditionally include <config.h> in unit tests.
1891         * tests/test-alloca-opt.c: Remove #ifdef HAVE_CONFIG_H.
1892         * tests/test-allocsa.c, tests/test-arcfour.c,
1893         tests/test-arctwo.c, tests/test-argmatch.c, tests/test-argp.c,
1894         tests/test-array_list.c, tests/test-array_oset.c,
1895         tests/test-atexit.c, test-avltree_list.c, test-avltree_oset.c,
1896         test-avltreehash_list.c, test-base64.c, test-binary-io.c,
1897         test-c-ctype.c, test-c-strcasecmp.c, test-c-strcasestr.c,
1898         test-c-strncasecmp.c, test-c-strstr.c, test-canonicalize-lgpl.c,
1899         test-carray_list.c, test-crc.c, test-des.c, test-dirname.c,
1900         test-fflush.c, test-fprintf-posix.c, test-gc-arcfour.c,
1901         test-gc-arctwo.c, test-gc-des.c, test-gc-hmac-md5.c,
1902         test-gc-hmac-sha1.c, test-gc-md2.c, test-gc-md4.c, test-gc-md5.c,
1903         test-gc-pbkdf2-sha1.c, test-gc-rijndael.c, test-gc-sha1.c,
1904         test-gc.c, test-getpass.c, test-hmac-md5.c, test-hmac-sha1.c,
1905         test-iconv.c, test-linked_list.c, test-linkedhash_list.c,
1906         test-lock.c, test-mbscasecmp.c, test-mbscasestr1.c,
1907         test-mbscasestr2.c, test-mbscasestr3.c, test-mbscasestr4.c,
1908         test-mbschr.c, test-mbscspn.c, test-mbsncasecmp.c, test-mbspbrk.c,
1909         test-mbspcasecmp.c, test-mbsrchr.c, test-mbsspn.c, test-mbsstr1.c,
1910         test-mbsstr2.c, test-mbsstr3.c, test-md2.c, test-md4.c,
1911         test-md5.c, test-memmem.c, test-printf-posix.c,
1912         test-rbtree_list.c, test-rbtree_oset.c, test-rbtreehash_list.c,
1913         test-read-file.c, test-rijndael.c, test-snprintf-posix.c,
1914         test-snprintf.c, test-sprintf-posix.c, test-stdint.c,
1915         test-strcasestr.c, test-striconv.c, test-striconveh.c,
1916         test-striconveha.c, test-tls.c, test-vasnprintf-posix.c,
1917         test-vasnprintf-posix2.c, test-vasnprintf.c,
1918         test-vasprintf-posix.c, test-vasprintf.c, test-verify.c,
1919         test-vfprintf-posix.c, test-vprintf-posix.c,
1920         test-vsnprintf-posix.c, test-vsnprintf.c, test-vsprintf-posix.c,
1921         test-xvasprintf.c: Likewise.
1922
1923 2007-05-28  Bruno Haible  <bruno@clisp.org>
1924
1925         * gnulib-tool (func_import): Remember the --with-tests command-line
1926         option through the macro gl_WITH_TESTS in the gnulib-cache.m4.
1927         Reported by Eric Blake.
1928
1929 2007-05-28  Bruno Haible  <bruno@clisp.org>
1930
1931         * modules/ftell-tests: New file.
1932         * tests/test-ftell.c: New file, based on tests/test-ftello.c.
1933         * tests/test-ftell.sh: New file, based on tests/test-ftello.sh.
1934
1935         * lib/ftell.c: New file.
1936         * modules/ftell: New file.
1937         * m4/ftell.m4: New file.
1938         * doc/functions/ftell.texi: Update.
1939         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELL,
1940         REPLACE_FTELL.
1941         * lib/stdio_.h (rpl_ftell): New declaration.
1942         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELL,
1943         REPLACE_FTELL.
1944
1945 2007-05-28  Eric Blake  <ebb9@byu.net>
1946
1947         * lib/allocsa.h (safe_alloca): Avoid compiler warning.
1948
1949 2007-05-28  Bruno Haible  <bruno@clisp.org>
1950
1951         * modules/fseek-tests: New file.
1952         * tests/test-fseek.c: New file, based on tests/test-fseeko.c.
1953         * tests/test-fseek.sh: New file, based on tests/test-fseeko.sh.
1954
1955         * lib/fseek.c: New file.
1956         * modules/fseek: New file.
1957         * m4/fseek.m4: New file.
1958         * doc/functions/fseek.texi: Update.
1959         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEK,
1960         REPLACE_FSEEK.
1961         * lib/stdio_.h (rpl_fseek): New declaration.
1962         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEK,
1963         REPLACE_FSEEK.
1964
1965 2007-05-28  Bruno Haible  <bruno@clisp.org>
1966
1967         * lib/stdio_.h (fflush): More comments.
1968
1969 2007-05-28  Bruno Haible  <bruno@clisp.org>
1970
1971         * m4/lseek.m4 (gl_FUNC_LSEEK): When not cross-compiling, perform a real
1972         runtime test.
1973
1974 2007-05-28  Eric Blake  <ebb9@byu.net>
1975
1976         Improve lseek module.
1977         * lib/lseek.c (rpl_lseek): Detect EBADF on mingw.
1978         * lib/unistd_.h (lseek): Scale back link warning message.
1979         * tests/test-lseek.c: Beef up test.
1980         * tests/test-lseek.sh: Exercise more facets of lseek.
1981         Reported by Bruno Haible.
1982
1983 2007-05-28  Bruno Haible  <bruno@clisp.org>
1984
1985         * tests/test-unistd.c: Test all the types that <unistd.h> is expected
1986         to define.
1987
1988 2007-05-27  Bruno Haible  <bruno@clisp.org>
1989
1990         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-31 patch.
1991
1992 2007-05-27  Bruno Haible  <bruno@clisp.org>
1993
1994         * modules/openmp: New file.
1995         * m4/openmp.m4: New file, taken from autoconf's CVS with changes by
1996         Noah Misch.
1997
1998 2007-05-26  Bruno Haible  <bruno@clisp.org>
1999
2000         * modules/chdir-long (Depends-on): Add fchdir.
2001         * modules/chdir-safer (Depends-on): Likewise.
2002         * modules/fts (Depends-on): Likewise.
2003         * modules/fts-lgpl (Depends-on): Likewise.
2004         * modules/openat (Depends-on): Likewise.
2005         * modules/savewd (Depends-on): Likewise.
2006
2007 2007-05-24  Eric Blake  <ebb9@byu.net>
2008
2009         Fix lseek on mingw.
2010         * modules/lseek: New module.
2011         * m4/lseek.m4: New file.
2012         * lib/lseek.c: New file.
2013         * modules/lseek-tests: New file.
2014         * tests/test-lseek.c: New file.
2015         * tests/test-lseek.sh: New file.
2016         * MODULES.html.sh: Document lseek module.
2017         * modules/fflush (Depends-on): Add lseek, fseeko.
2018         * modules/fseeko (Depends-on): Likewise.
2019         * modules/ftello (Depends-on): Likewise.
2020         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Replace fseek[o] if lseek is
2021         broken.
2022         * m4/ftello.m4 (gl_FUNC_FTELLO): Replace ftell[o] if lseek is
2023         broken.
2024         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Trigger fseeko module.
2025         * lib/fseeko.c (rpl_fseeko): Quit early on non-seekable files.
2026         * lib/ftello.c (rpl_ftello): Likewise.
2027         * tests/test-fseeko.c (main): Test this.
2028         * tests/test-fseeko.sh: Likewise.
2029         * tests/test-ftello.c (main): Likewise.
2030         * tests/test-ftello.sh: Likewise.
2031         * lib/stdio_.h (fseek, ftell): Simplify, since missing fseeko now
2032         implies replacing fseek.
2033         * modules/stdio (Makefile.am): No longer need HAVE_FSEEKO,
2034         HAVE_FTELLO.
2035         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add lseek info.
2036         * modules/unistd (Makefile.am): Likewise.
2037         * lib/unistd_.h (lseek): Declare a replacement.
2038         * doc/functions/lseek.texi (lseek): Document this fix.
2039         * doc/functions/fseek.texi (fseek): Likewise.
2040         * doc/functions/ftell.texi (ftell): Likewise.
2041
2042 2007-05-24  Bruno Haible  <bruno@clisp.org>
2043
2044         * tests/test-vasnprintf-posix.c (test_function): Allow up to 50 bytes
2045         in the printed representation of a NaN.
2046         * tests/test-vasprintf-posix.c (test_function): Likewise.
2047         * tests/test-snprintf-posix.h (test_function): Likewise.
2048         * tests/test-sprintf-posix.h (test_function): Likewise.
2049         Reported by Eric Blake.
2050
2051 2007-05-23  Eric Blake  <ebb9@byu.net>
2052
2053         Fix fseeko/ftello on cygwin 1.5.24.
2054         * doc/functions/fseeko.texi (fseeko): Document the fix.
2055         * doc/functions/ftello.texi (ftello): Document the fix.
2056         * doc/functions/stdin.texi (stdin): Document the cygwin bug.
2057         * doc/functions/stdout.text (stdout): New file.
2058         * doc/functions/stderr.text (stderr): New file.
2059         * doc/gnulib.texi (Function Substitutes): Use new files.
2060         * tests/test-fseeko.c (main): Check for broken fseeko on cygwin
2061         prior to 1.7.0.
2062         * tests/test-ftello.c (main): Likewise for ftello.
2063         * tests/test-fseeko.sh: New file.
2064         * tests/test-ftello.sh: New file.
2065         * modules/fseeko-tests (Makefile.am): Ensure test-fseeko is run
2066         with seekable stdin.
2067         * modules/ftello-tests (Makefile.am): Likewise for test-ftello.
2068         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Detect the cygwin bug.
2069         (gl_REPLACE_FSEEKO): New macro.
2070         * m4/ftello.m4 (gl_FUNC_FTELLO, gl_REPLACE_FTELLO): Likewise.
2071         * modules/fseeko (Files): Distribute fseeko.c.
2072         * modules/ftello (Files): Distribute ftello.c.
2073         * lib/fseeko.c (rpl_fseeko) [__CYGWIN__]: Convert stdin to 64-bit
2074         mode.
2075         * lib/ftello.c (rpl_ftello): New file.
2076         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Allow replacement of
2077         fseeko, ftello.
2078         (gl_STDIN_LARGE_OFFSET): New macro.
2079         * modules/stdio (Makefile.am): Perform the replacement.
2080         * lib/stdio_.h (rpl_fseeko, rpl_ftello): Define when needed.
2081
2082 2007-05-23  Bruno Haible  <bruno@clisp.org>
2083
2084         * lib/stdio_.h (fseeko, ftello): Provide a link warning only if
2085         GNULIB_POSIXCHECK is defined.
2086
2087 2007-05-21  Bruno Haible  <bruno@clisp.org>
2088
2089         * m4/printf.m4 (gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE):
2090         Check also the output for NaN arguments. When cross-compiling, guess
2091         no on IRIX.
2092         * lib/vasnprintf.c: Update comments.
2093         * tests/test-vasnprintf-posix.c (strisnan): New function.
2094         (test_function): Use it.
2095         * tests/test-vasprintf-posix.c (strisnan): New function.
2096         (test_function): Use it.
2097         * tests/test-snprintf-posix.h (strisnan): New function.
2098         (test_function): Use it.
2099         * tests/test-sprintf-posix.h (strisnan): New function.
2100         (test_function): Use it.
2101         Reported by Eric Blake.
2102
2103 2007-05-20  Bruno Haible  <bruno@clisp.org>
2104
2105         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Add test for large finite
2106         numbers that fails on BeOS.
2107         * doc/functions/frexpl.texi: Update.
2108
2109 2007-05-20  Jim Meyering  <jim@meyering.net>
2110
2111         * NEWS: Mention the incompatible change (s/futimens/gl_futimens/)
2112         forced upon us by glibc-2.6.
2113
2114 2007-05-20  Bruno Haible  <bruno@clisp.org>
2115
2116         Fix *printf result for NaN, Inf on AIX, Solaris, OSF/1.
2117         * m4/printf.m4 (gl_PRINTF_INFINITE): Update cross-compiling guesses.
2118         (gl_PRINTF_INFINITE_LONG_DOUBLE): New macro.
2119         * lib/vasnprintf.c: Use NEED_PRINTF_INFINITE_DOUBLE instead of
2120         NEED_PRINTF_INFINITE.
2121         (is_infinitel): New function.
2122         (VASNPRINTF): Handle NEED_PRINTF_INFINITE_LONG_DOUBLE case.
2123         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE): Renamed from
2124         gl_PREREQ_VASNPRINTF_INFINITE.
2125         (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): New macro.
2126         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
2127         gl_PRINTF_INFINITE_LONG_DOUBLE and test its result. Invoke
2128         gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE and
2129         gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE instead of
2130         gl_PREREQ_VASNPRINTF_INFINITE.
2131         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
2132         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2133         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2134         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2135         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2136         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2137         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2138         * doc/functions/fprintf.texi: Update.
2139         * doc/functions/printf.texi: Update.
2140         * doc/functions/snprintf.texi: Update.
2141         * doc/functions/sprintf.texi: Update.
2142         * doc/functions/vfprintf.texi: Update.
2143         * doc/functions/vprintf.texi: Update.
2144         * doc/functions/vsnprintf.texi: Update.
2145         * doc/functions/vsprintf.texi: Update.
2146
2147 2007-05-20  Bruno Haible  <bruno@clisp.org>
2148
2149         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): Set REPLACE_FREXPL if frexpl
2150         was not found in libc.
2151         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
2152
2153 2007-05-20  Bruno Haible  <bruno@clisp.org>
2154
2155         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
2156         printed as "-nan" instead of "nan".
2157         * tests/test-vasprintf-posix.c (test_function): Likewise.
2158         * tests/test-snprintf-posix.h (test_function): Likewise.
2159         * tests/test-sprintf-posix.h (test_function): Likewise.
2160         Needed for HP-UX 11.
2161
2162 2007-05-20  Jim Meyering  <jim@meyering.net>
2163
2164         Fix buggy test for the fchownat-deref bug.
2165         * m4/openat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Create the dangling
2166         symlink required for the run-test.  Without it, this test would
2167         always declare that fchownat doesn't work, and client code would
2168         unnecessarily use the replacement function with fixed libc.
2169         (gl_FUNC_FCHOWNAT): Eliminate a variable that wasn't initialized.
2170         Reported by Greg Schafer.
2171
2172 2007-05-19  Bruno Haible  <bruno@clisp.org>
2173
2174         * m4/isnanf.m4 (gl_ISNANF_WORKS): New macro.
2175         (gl_FUNC_ISNANF_NO_LIBM): Invoke it.
2176         * lib/isnan.c (FUNC): Use run-time expressions for SGI compiler.
2177         Needed for IRIX 6.5 and Solaris 2.5.1.
2178
2179 2007-05-19  Bruno Haible  <bruno@clisp.org>
2180
2181         * tests/test-vasnprintf-posix.c (have_minus_zero): New function.
2182         (test_function): Skip tests involving -0.0 on platforms where
2183         -0.0 = 0.0.
2184         * tests/test-vasprintf-posix.c (have_minus_zero): New function.
2185         (test_function): Skip tests involving -0.0 on platforms where
2186         -0.0 = 0.0.
2187         * tests/test-snprintf-posix.h (have_minus_zero): New function.
2188         (test_function): Skip tests involving -0.0 on platforms where
2189         -0.0 = 0.0.
2190         * tests/test-sprintf-posix.h (have_minus_zero): New function.
2191         (test_function): Skip tests involving -0.0 on platforms where
2192         -0.0 = 0.0.
2193         * tests/test-fprintf-posix.h (test_function): Remove all -0.0 related
2194         tests.
2195         * tests/test-printf-posix.h (test_function): Likewise.
2196         * tests/test-printf-posix.output: Remove all -0.0 related results.
2197         Needed for IRIX 6.5.
2198
2199 2007-05-19  Bruno Haible  <bruno@clisp.org>
2200
2201         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
2202         printed as "nan0x7fffffff" instead of "nan".
2203         * tests/test-vasprintf-posix.c (test_function): Likewise.
2204         * tests/test-snprintf-posix.h (test_function): Likewise.
2205         * tests/test-sprintf-posix.h (test_function): Likewise.
2206         * tests/test-fprintf-posix.h (NaN): Remove macro.
2207         (test_function): Remove all NaN related tests.
2208         * tests/test-printf-posix.h (NaN): Remove macro.
2209         (test_function): Remove all NaN related tests.
2210         * tests/test-printf-posix.output: Remove all NaN related results.
2211         Needed for IRIX 6.5.
2212
2213 2007-05-19  Bruno Haible  <bruno@clisp.org>
2214
2215         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Fix C89 syntax error in test code.
2216         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
2217
2218 2007-05-19  Bruno Haible  <bruno@clisp.org>
2219
2220         * lib/float_.h: New file.
2221         * m4/float_h.m4: New file.
2222         * modules/float: New file.
2223         * modules/isnanl (Dependencies): Add float.
2224         * modules/isnanl-nolibm (Dependencies): Likewise.
2225         * modules/mathl (Dependencies): Likewise.
2226         * modules/printf-frexpl (Dependencies): Likewise.
2227         * modules/signbit (Dependencies): Likewise.
2228         * modules/vasnprintf (Dependencies): Likewise.
2229         * doc/headers/float.texi: Update.
2230
2231 2007-05-19  Jim Meyering  <jim@meyering.net>
2232
2233         * lib/utimens.c (gl_futimens): Rename from futimens,
2234         now that glibc-2.6 declares futimens.
2235         * lib/utimens.h: Likewise.
2236
2237 2007-05-19  Bruno Haible  <bruno@clisp.org>
2238
2239         Avoid test failures on mingw.
2240         * tests/test-fprintf-posix.sh: Convert CR/LF to LF in output.
2241         * tests/test-printf-posix.sh: Likewise.
2242         * tests/test-vfprintf-posix.sh: Likewise.
2243         * tests/test-vprintf-posix.sh: Likewise.
2244
2245 2007-05-19  Bruno Haible  <bruno@clisp.org>
2246
2247         Fix *printf result for NaN, Inf, -0.0 on mingw.
2248         * m4/printf.m4 (gl_PRINTF_INFINITE): New macro.
2249         * lib/vasnprintf.c: Include math.h and isnan.h.
2250         (is_infinite_or_zero): New function.
2251         (VASNPRINTF): Fix also the handling of infinite or zero 'double'
2252         values in the %f, %F, %e, %E, %g, %G directives.
2253         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE): New macro.
2254         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
2255         gl_PRINTF_INFINITE and test its result. Invoke
2256         gl_PREREQ_VASNPRINTF_INFINITE.
2257         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
2258         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2259         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2260         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2261         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2262         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2263         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2264         * doc/functions/fprintf.texi: Update.
2265         * doc/functions/printf.texi: Update.
2266         * doc/functions/snprintf.texi: Update.
2267         * doc/functions/sprintf.texi: Update.
2268         * doc/functions/vfprintf.texi: Update.
2269         * doc/functions/vprintf.texi: Update.
2270         * doc/functions/vsnprintf.texi: Update.
2271         * doc/functions/vsprintf.texi: Update.
2272
2273 2007-05-19  Bruno Haible  <bruno@clisp.org>
2274
2275         * lib/vasnprintf.c (convert_to_decimal): Add an extra_zeroes argument.
2276         (scale10_round_decimal_long_double): Inline scale10_round_long_double.
2277         Instead of multiplying with 10^k, set extra_zeroes to k.
2278         (scale10_round_long_double): Remove function.
2279
2280 2007-05-18  Bruno Haible  <bruno@clisp.org>
2281
2282         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Fix logic bug
2283         introduced on 2007-05-06.
2284
2285 2007-05-18  Bruno Haible  <bruno@clisp.org>
2286
2287         * tests/test-vasnprintf-posix.c (test_function): Also test the %e and
2288         %g directives.
2289         * tests/test-vasprintf-posix.c (test_function): Likewise.
2290         * tests/test-snprintf-posix.h (test_function): Likewise.
2291         * tests/test-sprintf-posix.h (test_function): Likewise.
2292
2293 2007-05-18  Bruno Haible  <bruno@clisp.org>
2294
2295         * tests/test-vasnprintf-posix.c (SIZEOF): New macro.
2296         (strmatch): New function.
2297         (test_function): Test the %f directive on numbers of various exponents.
2298         * tests/test-vasprintf-posix.c (SIZEOF): New macro.
2299         (strmatch): New function.
2300         (test_function): Test the %f directive on numbers of various exponents.
2301         * tests/test-snprintf-posix.h (strmatch): New function.
2302         (test_function): Test the %f directive on numbers of various exponents.
2303         * tests/test-sprintf-posix.h (strmatch): New function.
2304         (test_function): Test the %f directive on numbers of various exponents.
2305         * tests/test-snprintf-posix.c (SIZEOF): New macro.
2306         * tests/test-sprintf-posix.c (SIZEOF): New macro.
2307         * tests/test-vsnprintf-posix.c (SIZEOF): New macro.
2308         * tests/test-vsprintf-posix.c (SIZEOF): New macro.
2309
2310 2007-05-18  Bruno Haible  <bruno@clisp.org>
2311
2312         Add support for 'long double' number output.
2313         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE): New macro.
2314         * lib/vasnprintf.c: Include math.h and float+.h.
2315         (mp_limb_t): New type.
2316         (GMP_LIMB_BITS): New macro.
2317         (mp_twolimb_t): New type.
2318         (GMP_TWOLIMB_BITS): New macro.
2319         (mpn_t): New type.
2320         (multiply, divide, convert_to_decimal, decode_long_double,
2321         scale10_round_long_double, scale10_round_decimal_long_double,
2322         floorlog10l): New functions.
2323         (VASNPRINTF) [NEED_PRINTF_LONG_DOUBLE]: Implement 'long double' support
2324         for the %f, %F, %e, %E, %g, %G directives.
2325         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_LONG_DOUBLE): New macro.
2326         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
2327         gl_PRINTF_LONG_DOUBLE and test its result. Invoke
2328         gl_PREREQ_VASNPRINTF_LONG_DOUBLE.
2329         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
2330         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2331         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2332         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2333         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2334         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2335         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2336         * modules/fprintf-posix (Depends-on): Add frexpl-nolibm.
2337         * modules/snprintf-posix (Depends-on): Likewise.
2338         * modules/sprintf-posix (Depends-on): Likewise.
2339         * modules/vasnprintf-posix (Depends-on): Likewise.
2340         * modules/vasprintf-posix (Depends-on): Likewise.
2341         * modules/vfprintf-posix (Depends-on): Likewise.
2342         * modules/vsnprintf-posix (Depends-on): Likewise.
2343         * modules/vsprintf-posix (Depends-on): Likewise.
2344         * modules/vasnprintf (Files): Add lib/float+.h.
2345         * doc/functions/fprintf.texi: Update.
2346         * doc/functions/printf.texi: Update.
2347         * doc/functions/snprintf.texi: Update.
2348         * doc/functions/sprintf.texi: Update.
2349         * doc/functions/vfprintf.texi: Update.
2350         * doc/functions/vprintf.texi: Update.
2351         * doc/functions/vsnprintf.texi: Update.
2352         * doc/functions/vsprintf.texi: Update.
2353
2354 2007-05-18  Bruno Haible  <bruno@clisp.org>
2355
2356         * lib/vasnprintf.c (USE_SNPRINTF): Define to 0 on BeOS.
2357
2358 2007-05-18  Bruno Haible  <bruno@clisp.org>
2359
2360         * lib/vasnprintf.c (VASNPRINTF) [WIN32]: Use %I64d instead of %lld
2361         for printing 64-bit integers. Needed for mingw.
2362
2363 2007-05-18  Bruno Haible  <bruno@clisp.org>
2364
2365         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
2366         gl_FUNC_FREXPL_WORKS.
2367         * modules/printf-frexpl (Files): Add m4/frexpl.m4.
2368
2369 2007-05-18  Bruno Haible  <bruno@clisp.org>
2370
2371         * modules/frexpl-nolibm-tests: New file.
2372
2373         * modules/frexpl-nolibm: New file.
2374         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): New macro.
2375
2376 2007-05-17  Paul Eggert  <eggert@cs.ucla.edu>
2377
2378         * lib/dirent_.h: Prefer #include_next <foo.h> to #include
2379         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
2380         GCC 4.2, which otherwise issues a lot of warnings.
2381         * lib/iconv_.h, lib/locale_.h, lib/netinet_in_.h, lib/sys_select_.h:
2382         * lib/sys_socket_.h, lib/sys_stat_.h, lib/sysexits_.h, lib/unistd_.h:
2383         Likewise.
2384         * modules/fchdir (dirent.h): Substitute @HAVE_INCLUDE_NEXT@.
2385         * modules/iconv_open (iconv.h): Likewise.
2386         * modules/locale (locale.h): Likewise.
2387         * modules/netinet_in (netinet/in.h): Likewise.
2388         * modules/sys_select (sys_select.h): Likewise.
2389         * modules/sys_socket (sys/socket.h): Likewise.
2390         * modules/sys_stat (sys/stat.h): Likewise.
2391         * modules/sysexits (sysexits.h): Likewise.
2392         * modules/unistd (unistd.h): Likewise.
2393
2394 2007-05-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2395
2396         * modules/closein-tests (Makefile.am): Distribute
2397         `test-closein.sh'.
2398
2399 2007-05-17  Bruno Haible  <bruno@clisp.org>
2400
2401         * tests/test-printf-posix.output: Renamed from
2402         tests/test-fprintf-posix.out.
2403         * modules/fprintf-posix-tests: Update.
2404         * modules/printf-posix-tests: Update.
2405         * modules/vfprintf-posix-tests: Update.
2406         * modules/vprintf-posix-tests: Update.
2407         * tests/test-fprintf-posix.sh: Update.
2408         * tests/test-printf-posix.sh: Update.
2409         * tests/test-vfprintf-posix.sh: Update.
2410         * tests/test-vprintf-posix.sh: Update.
2411         Reported by Ralf Wildenhues.
2412
2413 2007-05-16  Paul Eggert  <eggert@cs.ucla.edu>
2414
2415         * lib/fcntl_.h: Prefer #include_next <foo.h> to #include
2416         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
2417         GCC 4.2, which otherwise issues a lot of warnings.
2418         * lib/inttypes_.h, lib/math_.h, lib/search_.h, lib/signal_.h:
2419         * lib/stdint_.h, lib/stdio_.h, lib/stdlib_.h, lib/string_.h:
2420         * lib/sys_time_.h, lib/time_.h, lib/wchar_.h, lib/wctype_.h: Likewise.
2421         * lib/stdlib_.h: Don't bother with #pragma GCC system_header, as
2422         it should no longer be needed.
2423         * lib/string_.h: Likewise.
2424         * modules/absolute-header (HAVE_INCLUDE_NEXT): New 'make' define.
2425         * modules/fcntl (fcntl.h): Substitute @HAVE_INCLUDE_NEXT@.
2426         * modules/inttypes (inttypes.h): Likewise.
2427         * modules/math (math.h): Likewise.
2428         * modules/search (search.h): Likewise.
2429         * modules/signal (signal.h): Likewise.
2430         * modules/stdint (stdint.h): Likewise.
2431         * modules/stdio (stdio.h): Likewise.
2432         * modules/stdlib (stdlib.h): Likewise.
2433         * modules/string (string.h): Likewise.
2434         * modules/sys_time (sys/time.h): Likewise.
2435         * modules/time (time.h): Likewise.
2436         * modules/wchar (wchar.h): Likewise.
2437         * modules/wctype (wtype.h): Likewise.
2438
2439 2007-05-16  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
2440
2441         * doc/gnulib-tool.texi (CVS Issues): Fix typo.
2442
2443 2007-05-13  Bruno Haible  <bruno@clisp.org>
2444
2445         * stpcpy.m4 (gl_FUNC_STPCPY): Require AC_C_RESTRICT.
2446         * stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
2447         * strsep.m4 (gl_FUNC_STRSEP): Likewise.
2448         * strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
2449         (gl_PREREQ_STRTOK_R): Don't require it here.
2450
2451 2007-05-13  Bruno Haible  <bruno@clisp.org>
2452
2453         * lib/stdlib_.h (mkdtemp, mkstemp): Comment out argument name. Needed
2454         when used in C++ mode.
2455
2456 2007-05-12  Bruno Haible  <bruno@clisp.org>
2457
2458         * lib/linebuffer.h: Tweak doc.
2459         * lib/linebuffer.c: Likewise.
2460
2461 2007-05-12  James Youngman  <jay@gnu.org>
2462
2463         * lib/linebuffer.c (readlinebuffer_delim): New function,
2464         like readlinebuffer, but use a caller-specified delimiter.
2465         (readlinebuffer): Just call readlinebuffer_delim with '\n'
2466         as the delimiter.
2467         * lib/linebuffer.h (readlinebuffer_delim): Declare it.
2468
2469 2007-05-12  Sergey Poznyakoff  <gray@gnu.org.ua>
2470
2471         * m4/openat.m4 (gl_FUNC_OPENAT): Do not require openat-die.
2472         * modules/openat (Files): Remove openat-die.c.
2473         (Depends-on): Add openat-die.
2474         * modules/openat-die: New module.
2475
2476 2007-05-06  Bruno Haible  <bruno@clisp.org>
2477
2478         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING, gl_VSNPRINTF_ZEROSIZE_C99):
2479         Update with info about Cygwin.
2480         * doc/functions/fprintf.texi: Update.
2481         * doc/functions/printf.texi: Update.
2482         * doc/functions/snprintf.texi: Update.
2483         * doc/functions/sprintf.texi: Update.
2484         * doc/functions/vfprintf.texi: Update.
2485         * doc/functions/vprintf.texi: Update.
2486         * doc/functions/vsnprintf.texi: Update.
2487         * doc/functions/vsprintf.texi: Update.
2488         Reported by Eric Blake.
2489
2490 2007-05-06  Bruno Haible  <bruno@clisp.org>
2491
2492         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Perform the
2493         padding ourselves for the floating-point directives.
2494         * m4/printf.m4 (gl_PRINTF_FLAG_ZERO): New macro.
2495         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ZERO): New macro.
2496         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2497         gl_PRINTF_FLAG_ZERO and test its result. Invoke
2498         gl_PREREQ_VASNPRINTF_FLAG_ZERO.
2499         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2500         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
2501         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2502         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2503         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2504         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2505         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2506         * tests/test-snprintf-posix.h (test_function): Also check the width
2507         and some flags in the %f directive.
2508         * tests/test-sprintf-posix.h (test_function): Likewise.
2509         * tests/test-vasnprintf-posix.c (test_function): Likewise.
2510         * tests/test-vasprintf-posix.c (test_function): Likewise.
2511         * doc/functions/fprintf.texi: Update.
2512         * doc/functions/printf.texi: Update.
2513         * doc/functions/snprintf.texi: Update.
2514         * doc/functions/sprintf.texi: Update.
2515         * doc/functions/vfprintf.texi: Update.
2516         * doc/functions/vprintf.texi: Update.
2517         * doc/functions/vsnprintf.texi: Update.
2518         * doc/functions/vsprintf.texi: Update.
2519
2520 2007-05-06  Bruno Haible  <bruno@clisp.org>
2521
2522         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_GROUPING]: Don't
2523         pass the ' flag character to sprintf or snprintf.
2524         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING): New macro.
2525         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_GROUPING): New macro.
2526         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2527         gl_PRINTF_FLAG_GROUPING and test its result. Invoke
2528         gl_PREREQ_VASNPRINTF_FLAG_GROUPING.
2529         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2530         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
2531         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2532         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2533         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2534         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2535         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2536         * tests/test-snprintf-posix.h (test_function): Also check the grouping
2537         flag.
2538         * tests/test-sprintf-posix.h (test_function): Likewise.
2539         * tests/test-vasnprintf-posix.c (test_function): Likewise.
2540         * tests/test-vasprintf-posix.c (test_function): Likewise.
2541         * doc/functions/fprintf.texi: Update.
2542         * doc/functions/printf.texi: Update.
2543         * doc/functions/snprintf.texi: Update.
2544         * doc/functions/sprintf.texi: Update.
2545         * doc/functions/vfprintf.texi: Update.
2546         * doc/functions/vprintf.texi: Update.
2547         * doc/functions/vsnprintf.texi: Update.
2548         * doc/functions/vsprintf.texi: Update.
2549
2550 2007-05-01  Bruno Haible  <bruno@clisp.org>
2551
2552         * tests/test-argp-2.sh (func_compare): Drop .exe suffix.
2553
2554 2007-05-03  Paul Eggert  <eggert@cs.ucla.edu>
2555
2556         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use better
2557         comment for D_INO_IN_DIRENT.  Problem reported by James Youngman.
2558
2559 2007-05-02  Paul Eggert  <eggert@cs.ucla.edu>
2560
2561         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Test whether
2562         readdir returns garbage in d_ino.  Problem reported by Kaz Sasayama in
2563         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00021.html>.
2564
2565 2007-05-02  Sergey Poznyakoff  <gray@gnu.org.ua>
2566
2567         * lib/argp-help.c (struct hol_entry): New member `ord'.
2568         (HOL_ENTRY_PTRCMP): Use ord for comparison
2569         (hol_sort): Initialize ord.
2570
2571 2007-05-01  Bruno Haible  <bruno@clisp.org>
2572
2573         * doc/functions/_Exit_C99.texi: Renamed from doc/functions/_Exit.texi.
2574         Reported by Eric Blake.
2575         * doc/gnulib.texi (Function Substitutes): Update.
2576
2577 2007-05-01  Bruno Haible  <bruno@clisp.org>
2578
2579         * doc/functions.texi: Remove file, now redundant through
2580         doc/functions/*.texi.
2581
2582 2007-05-01  Bruno Haible  <bruno@clisp.org>
2583
2584         * modules/argp (Depends-on): Add sleep.
2585
2586 2007-05-01  Bruno Haible  <bruno@clisp.org>
2587
2588         * modules/sleep-tests: New file.
2589         * tests/test-sleep.c: New file.
2590
2591         * modules/sleep: New file.
2592         * lib/sleep.c: New file.
2593         * m4/sleep.m4: New file.
2594         * lib/unistd_.h (sleep): New declaration.
2595         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_SLEEP,
2596         HAVE_SLEEP.
2597         * modules/unistd (Makefile.am): Substitute GNULIB_SLEEP, HAVE_SLEEP.
2598         * doc/functions/sleep.texi: Document the sleep module.
2599
2600 2007-05-01  Bruno Haible  <bruno@clisp.org>
2601
2602         * lib/sigprocmask.h: Remove file.
2603         * lib/signal_.h: Incorporate the previous contents of sigprocmask.h.
2604         * lib/sigprocmask.c: Include <signal.h> instead of sigprocmask.h.
2605         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Substitute GNULIB_SIGPROCMASK,
2606         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T.
2607         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
2608         gl_SIGNAL_H_DEFAULTS. Set HAVE_POSIX_SIGNALBLOCKING as a shell variable.
2609         (gl_PREREQ_SIGPROCMASK): Require gl_SIGNAL_H_DEFAULTS. Set
2610         HAVE_SIGSET_T as a shell variable.
2611         * modules/signal (Makefile.am): Substitute GNULIB_SIGPROCMASK,
2612         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T into signal.h.
2613         * modules/sigprocmask (Files): Remove lib/sigprocmask.h.
2614         (Depends-on): Add signal. Remove verify.
2615         (configure.ac): Invoke gl_SIGNAL_MODULE_INDICATOR.
2616         (Include): Mention <signal.h> instead of sigprocmask.h.
2617         * NEWS: Mention the change.
2618         * lib/fatal-signal.c: Don't include sigprocmask.h.
2619
2620 2007-05-01  Bruno Haible  <bruno@clisp.org>
2621
2622         * modules/signal: New file.
2623         * lib/signal_.h: New file.
2624         * m4/signal_h.m4: New file.
2625
2626 2007-05-01  Bruno Haible  <bruno@clisp.org>
2627
2628         * lib/wctype_.h: Test HAVE_ISWCNTRL at configure time.
2629         * m4/wctype.m4 (gl_WCTYPE_H): Substitute HAVE_ISWCNTRL.
2630         * modules/wctype (Makefile.am): Substitute HAVE_ISWCNTRL instead of
2631         HAVE_WCTYPE_CTMP_BUG into wctype.h.
2632
2633 2007-05-01  Bruno Haible  <bruno@clisp.org>
2634
2635         * lib/sys_stat_.h: Test HAVE_LSTAT, HAVE_DECL_MKDIR, HAVE_IO_H at
2636         configure time.
2637         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Substitute HAVE_LSTAT,
2638         HAVE_DECL_MKDIR, HAVE_IO_H via AC_SUBST.
2639         * modules/sys_stat (Makefile.am): Substitute their values into
2640         sys/stat.h.
2641
2642 2007-05-01  Bruno Haible  <bruno@clisp.org>
2643
2644         * lib/glob_.h: Test HAVE_SYS_CDEFS_H at configure time.
2645         * m4/glob.m4 (gl_PREREQ_GLOB): Substitute HAVE_SYS_CDEFS_H via AC_SUBST.
2646         * modules/glob (Makefile.am): Put HAVE_SYS_CDEFS_H value into glob.h.
2647
2648 2007-05-01  Bruno Haible  <bruno@clisp.org>
2649
2650         * doc/header/assert.texi: Undo last change: don't mention the gnulib
2651         'assert' module here.
2652
2653 2007-05-01  Bruno Haible  <bruno@clisp.org>
2654
2655         * doc/functions/*.texi: New files.
2656         * doc/functions/google-ranking.txt: New file.
2657         * doc/gnulib.texi (Function Substitutes): New chapter.
2658         (ctime, inet_ntoa): Remove sections.
2659         * doc/ctime.texi: Remove file.
2660         * doc/inet_ntoa.texi: Remove file.
2661         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Update
2662         dependencies.
2663         (%.info): New rule, specifying a --reference-limit.
2664
2665 2007-05-01  Bruno Haible  <bruno@clisp.org>
2666
2667         * MODULES.html.sh (posix_functions): Remove 'exec', 'toc'.
2668
2669 2007-05-01  Bruno Haible  <bruno@clisp.org>
2670
2671         * modules/mkdir (Depends-on): Add sys_stat, because sys_stat provides
2672         the portability of 'mkdir' to mingw systems.
2673
2674 2007-05-01  Bruno Haible  <bruno@clisp.org>
2675
2676         * doc/headers/google-ranking.txt: New file.
2677
2678 2007-04-30  Eric Blake  <ebb9@byu.net>
2679
2680         Prefer fseeko to fseek.
2681         * modules/getpass (Depends-on): Add fseeko.
2682         * lib/getpass.c (getpass): Use fseeko, not fseek.
2683
2684 2007-04-30  Sergey Poznyakoff  <gray@gnu.org.ua>
2685
2686         * lib/argp-help.c (hol_entry_cmp): Option sorting algorithm
2687         assumes the sorting is stable, while most qsort implementations
2688         are not.  Use argument addresses to ensure they never compare as
2689         equal.
2690
2691         * tests/test-argp-2.sh (usage-indent test): Fix output
2692         (func_compare): Restore diff options
2693         * tests/test-argp.c: Restore #include "progname.h"
2694
2695 2007-04-29  Bruno Haible  <bruno@clisp.org>
2696
2697         * m4/printf.m4 (gl_VSNPRINTF_ZEROSIZE_C99): New macro.
2698         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2699         gl_VSNPRINTF_ZEROSIZE_C99. Test gl_cv_func_vsnprintf_zerosize_c99.
2700         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2701         * modules/snprintf-posix-tests (Files): Add tests/test-snprintf.c.
2702         (configure.ac): Define CHECK_SNPRINTF_POSIX.
2703         (TESTS, check_PROGRAMS): Add test-snprintf.
2704         * modules/vsnprintf-posix-tests (Files): Add tests/test-vsnprintf.c.
2705         (configure.ac): Define CHECK_VSNPRINTF_POSIX.
2706         (TESTS, check_PROGRAMS): Add test-vsnprintf.
2707         * tests/test-snprintf.c (main) [!CHECK_SNPRINTF_POSIX]: Disable
2708         assertions that fail on HP-UX, OSF/1, or IRIX.
2709         * tests/test-vsnprintf.c (main) [!CHECK_VSNPRINTF_POSIX]: Likewise.
2710
2711 2007-04-29  Bruno Haible  <bruno@clisp.org>
2712
2713         * MODULES.html.sh (posix_functions): Remove 'contents'.
2714
2715 2007-04-29  Karl Berry  <karl@gnu.org>
2716
2717         * config/srclist.txt (gendocs_template_min): new entry.
2718
2719 2007-04-29  Bruno Haible  <bruno@clisp.org>
2720
2721         Work around fpurge bug on BSD systems.
2722         * modules/fpurge (Makefile.am): Compile fpurge.c unconditionally.
2723         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't invoke AC_LIBOBJ.
2724         * lib/fpurge.h (fpurge): Don't handle __fpurge wrapper here. Define
2725         fpurge to rpl_fpurge if the system already has this function.
2726         * lib/fpurge.c (fpurge): Handle also the __fpurge wrapper case and
2727         the case where the system already has this function. Correct invariants
2728         on BSD systems.
2729         * lib/fseeko.c (rpl_fseeko): Update recognition of preceding fflush on
2730         BSD systems.
2731
2732 2007-04-29  Sergey Poznyakoff  <gray@gnu.org.ua>
2733
2734         * lib/argp-help.c (hol_cluster_cmp): Reverse comparison.  Change
2735         proposed by Sven Verdoolaege.
2736
2737         * tests/test-argp.c: Fix option ordering.  Test deeply clustered
2738         options.
2739         * tests/test-argp-2.sh (func_compare): Use diff instead of cmp.
2740         (usage and help tests): Update
2741
2742 2007-04-29  Bruno Haible  <bruno@clisp.org>
2743
2744         * tests/test-fflush.c (main): Use a file of size 17, not 10.
2745         Print more information in case of failure. Disable a test on BeOS.
2746
2747 2007-04-29  Bruno Haible  <bruno@clisp.org>
2748
2749         * tests/**/test-*.[hc] (ASSERT): Use fprintf to show the line number.
2750         This helps debugging on systems on which no gdb is available.
2751
2752 2007-04-29  Bruno Haible  <bruno@clisp.org>
2753
2754         * lib/freading.h: Improve comments.
2755         * lib/fwriting.h: Likewise.
2756         * tests/test-freading.c (main): Don't check freading immediately after
2757         repositioning. Needed for glibc.
2758
2759 2007-04-29  Bruno Haible  <bruno@clisp.org>
2760
2761         * lib/freading.c (freading): Trivial simplification.
2762
2763 2007-04-28  Bruno Haible  <bruno@clisp.org>
2764
2765         * tests/test-fwriting.c (main): Also test the interaction between
2766         fflush and fwriting.
2767         * modules/fwriting-tests (Depends-on): Add fflush.
2768
2769         * tests/test-freading.c (main): Also test the interaction between
2770         fflush and freading.
2771         * modules/freading-tests (Depends-on): Add fflush.
2772
2773 2007-04-28  Bruno Haible  <bruno@clisp.org>
2774
2775         * lib/stdio_.h (fseek, ftell): Provide link warnings suggesting to use
2776         fseeko and ftello.
2777         Suggested by Eric Blake.
2778
2779 2007-04-28  Jim Meyering  <jim@meyering.net>
2780
2781         Avoid false-negative in gl_STDINT_H's C99 conformance test.
2782         * m4/stdint.m4 (gl_STDINT_H): When checking whether stdint.h conforms
2783         to C99, include all of gl_STDINT_INCLUDES, not just <stddef.h>.
2784
2785 2007-04-27  Eric Blake  <ebb9@byu.net>
2786
2787         * doc/headers/assert.texi (assert.h): Document assert module use.
2788
2789 2007-04-27  Bruno Haible  <bruno@clisp.org>
2790
2791         * doc/headers/*.texi: New files.
2792         * doc/gnulib.texi (Header File Substitutes): New chapter.
2793         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Specify
2794         dependencies.
2795         (standards.info ,standards.html, standards.dvi): Update dependencies.
2796         (mostlyclean, clean): New targets.
2797
2798 2007-04-27  Bruno Haible  <bruno@clisp.org>
2799
2800         * lib/sysexits_.h: Renamed from lib/sysexit_.h.
2801         * modules/sysexits (Files, Makefile.am): Update.
2802
2803         * lib/sys_socket_.h: Renamed from lib/socket_.h.
2804         * modules/sys_socket (Files, Makefile.am): Update.
2805
2806         * lib/sys_stat_.h: Renamed from lib/stat_.h.
2807         * modules/sys_stat (Files, Makefile.am): Update.
2808
2809 2007-04-27  Eric Blake  <ebb9@byu.net>
2810
2811         * lib/freading.h: Improve comments.
2812         * lib/fwriting.h: Likewise.
2813         * lib/fflush.c: Likewise.
2814
2815         Fix closein for mingw.
2816         * modules/closein-tests: Add tests for closein.
2817         * tests/test-closein.c: New file.
2818         * tests/test-closein.sh: Likewise.
2819         * lib/unistd_.h [!SEEK_CUR]: Mingw also needs stdlib.h for _exit.
2820         * lib/closein.c (close_stdin): Don't fflush non-seekable streams.
2821
2822 2007-04-27  Bruno Haible  <bruno@clisp.org>
2823
2824         * lib/inttypes_.h [_DECC]: Don't use #include_next if the compiler
2825         version is < 6.
2826         * lib/math_.h [__DECC]: Likewise.
2827         * lib/stdio_.h [__DECC]: Likewise.
2828         * lib/stdlib_.h [__DECC]: Likewise.
2829         * lib/string_.h [__DECC]: Likewise.
2830         * lib/time_.h [__DECC]: Likewise.
2831         * lib/wchar_.h [__DECC]: Likewise.
2832         * lib/wctype_.h [__DECC]: Likewise.
2833
2834 2007-04-27  Bruno Haible  <bruno@clisp.org>
2835
2836         * tests/test-fbufmode.c (main): Relax test, to avoid failure on mingw.
2837
2838 2007-04-27  Bruno Haible  <bruno@clisp.org>
2839
2840         * lib/fflush.c: Add comments.
2841         * modules/fpurge-tests (Depends-on): Add fflush.
2842         * modules/freadable-tests (Depends-on): Likewise.
2843         * modules/fwritable-tests (Depends-on): Likewise.
2844
2845 2007-04-27  Charles Wilson  <libtool@cwilson.fastmail.fm>
2846
2847         * m4/argz.m4 (gl_FUNC_ARGZ): Use !HAVE_WORKING_ARGZ instead of
2848         SYSTEM_ARGZ_IS_BROKEN.  Also, minor stylistic improvements.
2849         Report by Bruno Haible <bruno@clisp.org>.
2850
2851 2007-04-26  Eric Blake  <ebb9@byu.net>
2852
2853         Fix fflush on mingw.
2854         * modules/fflush (Depends-on): Add freading.
2855         * lib/fflush.c (rpl_fflush): Use freading to avoid losing buffered
2856         but unread data.
2857
2858 2007-04-26  Eric Blake  <ebb9@byu.net>
2859         and Bruno Haible  <bruno@clisp.org>
2860
2861         Implement freading and fwriting.
2862         * lib/freading.c: New file.
2863         * lib/freading.h: Likewise.
2864         * m4/freading.m4: Likewise.
2865         * modules/freading: Likewise.
2866         * modules/freading-tests: Likewise.
2867         * tests/test-freading.c: Likewise.
2868         * lib/fwriting.c: New file.
2869         * lib/fwriting.h: Likewise.
2870         * m4/fwriting.m4: Likewise.
2871         * modules/fwriting: Likewise.
2872         * modules/fwriting-tests: Likewise.
2873         * tests/test-fwriting.c: Likewise.
2874         * MODULES.html.sh (File stream based Input/Output): Mention them.
2875
2876 2007-04-26  Bruno Haible  <bruno@clisp.org>
2877
2878         * lib/stdio_.h (fseeko, ftello): Check that off_t has the same size as
2879         'long' when we assume it.
2880         Suggested by Eric Blake.
2881
2882 2007-04-26  Bruno Haible  <bruno@clisp.org>
2883
2884         Ensure fseeko, ftello are declared on glibc systems.
2885         * modules/fflush (configure.ac-early): Require AC_FUNC_FSEEKO.
2886         * modules/fseeko (configure.ac-early): Likewise.
2887         * modules/ftello (configure.ac-early): Likewise.
2888         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't define HAVE_FSEEKO, rely on
2889         AC_FUNC_FSEEKO for this.
2890         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Inline gl_CHECK_FSEEKO.
2891         (gl_CHECK_FSEEKO): Remove macro.
2892
2893 2007-04-26  Bruno Haible  <bruno@clisp.org>
2894
2895         * tests/test-fflush.c (main): Also check the ftell result after
2896         fflush and fseek/fseeko.
2897         * lib/fflush.c (rpl_fflush): For BSD implementations, update the
2898         file descriptor position cache in the stream.
2899         * lib/fseeko.c (rpl_fseeko): Likewise.
2900
2901 2007-04-26  Bruno Haible  <bruno@clisp.org>
2902
2903         * modules/fflush-tests (Depends-on): Add fseeko.
2904
2905 2007-04-25  Charles Wilson  <libtool@cwilson.fastmail.fm>
2906             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2907
2908         * lib/argz_.h: ensure error_t definition is obtained in same
2909         mechanism system argz.h would have.
2910         * m4/argz.m4 (gl_FUNC_ARGZ): add new test to check if $host's
2911         argz facilities are known bad.  Err on the side of caution if
2912         cross-compiling.
2913
2914 2007-04-25  Eric Blake  <ebb9@byu.net>
2915
2916         * lib/fpurge.c (includes): Use stdlib.h for free.
2917         * tests/test-fflush.c (main): Also test fflush-fseeko.
2918
2919 2007-04-25  Bruno Haible  <bruno@clisp.org>
2920
2921         Make fflush+fseek POSIX-compliant on FreeBSD and MacOS X.
2922         * lib/fseeko.c: New file.
2923         * lib/stdio_.h: Include <sys/types.h> when off_t is needed.
2924         (fseeko, fseek): Define to replacements if REPLACE_FFLUSH.
2925         * m4/fseeko.m4 (gl_CHECK_FSEEKO): New macro, extracted from
2926         gl_FUNC_FSEEKO.
2927         (gl_FUNC_FSEEKO): Invoke it.
2928         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Arrange to compile fseeko.c. Invoke
2929         gl_CHECK_FSEEKO. Define HAVE_FSEEKO.
2930         * modules/fflush (Files): Add lib/fseeko.c, m4/fseeko.m4.
2931
2932 2007-04-25  Bruno Haible  <bruno@clisp.org>
2933
2934         * modules/fflush (Depends-on): Add ftello.
2935
2936 2007-04-25  Bruno Haible  <bruno@clisp.org>
2937
2938         * modules/ftello-tests: New file.
2939         * tests/test-ftello.c: New file.
2940
2941         * modules/ftello: New file.
2942         * m4/ftello.m4: New file.
2943         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELLO,
2944         HAVE_FTELLO.
2945         * lib/stdio_.h (ftello): New declaration.
2946         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELLO,
2947         HAVE_FTELLO.
2948
2949 2007-04-25  Bruno Haible  <bruno@clisp.org>
2950
2951         * modules/fseeko-tests: New file.
2952         * tests/test-fseeko.c: New file.
2953
2954         * modules/fseeko: New file.
2955         * m4/fseeko.m4: New file.
2956         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEKO,
2957         HAVE_FSEEKO.
2958         * lib/stdio_.h (fseeko): New declaration.
2959         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEKO,
2960         HAVE_FSEEKO.
2961
2962 2007-04-25  Bruno Haible  <bruno@clisp.org>
2963
2964         * lib/stdio_.h (fflush): Add support for GNULIB_POSIXCHECK.
2965
2966 2007-04-25  Bruno Haible  <bruno@clisp.org>
2967
2968         * lib/unistd_.h: Include <stdio.h> if needed to get the SEEK_* macros.
2969         * tests/test-stdio.c: Check that the various SEEK_* macros are defined.
2970         * tests/test-unistd.c: Likewise.
2971         * tests/test-fcntl.c: Likewise.
2972
2973 2007-04-23  Eric Blake  <ebb9@byu.net>
2974
2975         * lib/fflush.c: Fix missing include.
2976         Reported by Bruno Haible.
2977
2978 2007-04-23  Bruno Haible  <bruno@clisp.org>
2979
2980         * lib/fpurge.c (fpurge) [glibc, BSD]: Free a malloc()ed ungetc buffer.
2981         Reported by Eric Blake.
2982
2983 2007-04-23  Bruno Haible  <bruno@clisp.org>
2984
2985         * lib/fbufmode.c (fbufmode): Port to Solaris/SPARC64.
2986
2987 2007-04-23  Bruno Haible  <bruno@clisp.org>
2988
2989         * lib/fseterr.c (fseterr): Don't hardcode the value of _IOERR.
2990
2991 2007-04-23  Bruno Haible  <bruno@clisp.org>
2992
2993         * tests/test-fbufmode.c (main): Be prepared to a failure of setvbuf.
2994         Needed on HP-UX 11.
2995
2996 2007-04-16  Eric Blake  <ebb9@byu.net>
2997
2998         Make fflush rely on fpurge.
2999         * lib/fflush.c (rpl_fflush): Rely on fpurge module, rather than
3000         open coding all variants.
3001         * modules/fflush (Depends-on): Add fpurge and unistd.
3002         * modules/fflush-tests (Depends-on): Unistd is no longer extra.
3003         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Simplify.
3004
3005         Fix --with-tests compilation on cygwin.
3006         * modules/argmatch-tests (Makefile.am): List gnulib library first
3007         in LDADD.
3008         * modules/argp-tests (Makefile.am): Likewise.
3009         * modules/array-list-tests (Makefile.am): Likewise.
3010         * modules/array-oset-tests (Makefile.am): Likewise.
3011         * modules/avltree-list-tests (Makefile.am): Likewise.
3012         * modules/avltree-oset-tests (Makefile.am): Likewise.
3013         * modules/avltreehash-list-tests (Makefile.am): Likewise.
3014         * modules/carray-list-tests (Makefile.am): Likewise.
3015         * modules/dirname-tests (Makefile.am): Likewise.
3016         * modules/frexp-tests (Makefile.am): Likewise.
3017         * modules/isnanl-tests (Makefile.am): Likewise.
3018         * modules/linked-list-tests (Makefile.am): Likewise.
3019         * modules/linkedhash-list-tests (Makefile.am): Likewise.
3020         * modules/lock-tests (Makefile.am): Likewise.
3021         * modules/rbtree-list-tests (Makefile.am): Likewise.
3022         * modules/rbtree-oset-tests (Makefile.am): Likewise.
3023         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
3024         * modules/tls-tests (Makefile.am): Likewise.
3025         * modules/tsearch-tests (Makefile.am): Likewise.
3026         * modules/xvasprintf-tests (Makefile.am): Likewise.
3027
3028         Fix fpurge for cygwin.
3029         * lib/fpurge.c (fpurge): Fix order of operation flub, and return a
3030         value.
3031         * modules/fpurge-tests (Depends-on): Clean up trash.
3032
3033 2007-04-16  Simon Josefsson  <simon@josefsson.org>
3034
3035         * lib/gc-libgcrypt.c (gc_hash_open): Shut up compiler warnings.
3036
3037         * m4/autobuild.m4: Re-indent.
3038
3039 2007-04-13  Bruno Haible  <bruno@clisp.org>
3040
3041         * modules/fpurge-tests: New file.
3042         * tests/test-fpurge.c: New file.
3043
3044         * modules/fpurge: New file.
3045         * lib/fpurge.h: New file.
3046         * lib/fpurge.c: New file.
3047         * m4/fpurge.m4: New file.
3048
3049 2007-04-13  Bruno Haible  <bruno@clisp.org>
3050
3051         * modules/fbufmode-tests: New file.
3052         * tests/test-fbufmode.c: New file.
3053
3054         * modules/fbufmode: New file.
3055         * lib/fbufmode.h: New file.
3056         * lib/fbufmode.c: New file.
3057         * m4/fbufmode.m4: New file.
3058
3059 2007-04-13  Bruno Haible  <bruno@clisp.org>
3060
3061         * modules/fwritable-tests: New file.
3062         * tests/test-fwritable.c: New file.
3063
3064         * modules/fwritable: New file.
3065         * lib/fwritable.h: New file.
3066         * lib/fwritable.c: New file.
3067         * m4/fwritable.m4: New file.
3068
3069 2007-04-13  Bruno Haible  <bruno@clisp.org>
3070
3071         * modules/freadable-tests: New file.
3072         * tests/test-freadable.c: New file.
3073
3074         * modules/freadable: New file.
3075         * lib/freadable.h: New file.
3076         * lib/freadable.c: New file.
3077         * m4/freadable.m4: New file.
3078
3079 2007-04-13  Bruno Haible  <bruno@clisp.org>
3080
3081         * modules/fflush-tests (Makefile.am): Remove EXTRA_DIST. Augment
3082         MOSTLYCLEANFILES.
3083
3084 2007-04-13  Paul Eggert  <eggert@cs.ucla.edu>
3085
3086         * build-aux/bootstrap (gnulib_tool_option_extras): New var, used by
3087         gzip bootstrap.conf to avoid dragging in i18n machinery.
3088         (gnulib_tool_option): Use it.
3089
3090 2007-04-13  Bruno Haible  <bruno@clisp.org>
3091
3092         * tests/test-vasnprintf-posix.c (test_function): Add tests for %f and
3093         %F directives.
3094         * tests/test-vasprintf-posix.c (test_function): Likewise.
3095         * tests/test-snprintf-posix.h (test_function): Likewise.
3096         * tests/test-sprintf-posix.h (test_function): Likewise.
3097         * tests/test-fprintf-posix.h (test_function): Likewise.
3098         * tests/test-printf-posix.h (test_function): Likewise.
3099         * tests/test-fprintf-posix.out: Likewise.
3100
3101 2007-04-13  Bruno Haible  <bruno@clisp.org>
3102
3103         * modules/lock-tests (configure.ac): For LIBSCHED, try also -lposix4.
3104         * modules/tls-tests (configure.ac): Likewise.
3105         Reported by Arto C. Nirkko <anirkko@insel.ch>.
3106
3107 2007-04-13  Bruno Haible  <bruno@clisp.org>
3108
3109         * lib/tls.c (glthread_tls_get): Fix return type.
3110         Patch by Arto C. Nirkko <anirkko@insel.ch>.
3111
3112 2007-04-12  Eric Blake  <ebb9@byu.net>
3113
3114         * modules/gettime (Depends-on): Remove gettime.
3115         Reported by Dmitry V. Levin.
3116
3117 2007-04-12  Bruno Haible  <bruno@clisp.org>
3118
3119         * modules/fflush (Include): Mention <stdio.h>.
3120         * modules/strtoimax (Include): Mention <inttypes.h>.
3121         * modules/strtoumax (Include): Likewise.
3122
3123 2007-04-12  Eric Blake  <ebb9@byu.net>
3124
3125         * .cvsignore: New file.
3126         * .gitignore: Likewise.
3127
3128 2007-04-12  Bruno Haible  <bruno@clisp.org>
3129
3130         * modules/iconv-tests (test_iconv_LDADD): Mention -liconv after LDADD,
3131         not before, since $(LDADD) often contains libgnu.a.
3132         * modules/striconv-tests (test_striconv_LDADD): Likewise.
3133         * modules/striconveh-tests (test_striconveh_LDADD): Likewise.
3134         * modules/striconveha-tests (test_striconveha_LDADD): Likewise.
3135         Needed on Cygwin.
3136
3137 2007-04-12  Eric Blake  <ebb9@byu.net>
3138
3139         Work around glibc's failure to flush stdin on fclose.
3140         * lib/closein.c (close_stdin): Flush stdin before closing.
3141
3142         Work around glibc's failure to reset seekable stdin on exit.
3143         * modules/closein: New module.
3144         * lib/closein.c: New file.
3145         * lib/closein.h: Likewise.
3146         * m4/closein.m4: Likewise.
3147         * MODULES.html.sh (File stream based Input/Output): Document it.
3148
3149 2007-04-12  Simon Josefsson  <simon@josefsson.org>
3150
3151         * gnulib-tool: Rename generated 'autobuild' script to
3152         'do-autobuild' in --create-megatestdir output.
3153
3154         * doc/gnulib.texi (Build robot for gnulib): Fix.
3155
3156 2007-04-12  Simon Josefsson  <simon@josefsson.org>
3157
3158         * modules/sysexits (Depends-on): Add absolute-header.
3159
3160 2007-04-12  Eric Blake  <ebb9@byu.net>
3161
3162         No need to preserve errno on success.
3163         * lib/fflush.c (rpl_fflush): Simplify errno tracking.
3164         Reported by Bruno Haible.
3165
3166 2007-04-12  Simon Josefsson  <simon@josefsson.org>
3167
3168         * MODULES.html.sh (Support for maintaining and releasing
3169         projects): Add autobuild.  Suggested by Eric Blake <ebb9@byu.net>.
3170
3171 2007-04-12  Simon Josefsson  <simon@josefsson.org>
3172
3173         * gnulib-tool (func_modules_add_dummy): Respect --avoid=dummy.
3174
3175 2007-04-12  Simon Josefsson  <simon@josefsson.org>
3176
3177         * modules/autobuild: New module.
3178
3179         * m4/autobuild.m4: New file.
3180
3181 2007-04-11  Bruno Haible  <bruno@clisp.org>
3182
3183         * lib/vasnprintf.c (VASNPRINTF): Implement the %F directive using the
3184         %f directive, if NEED_PRINTF_DIRECTIVE_F is defined.
3185         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): New macro.
3186         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_F): New macro.
3187         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
3188         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3189         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3190         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
3191         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3192         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3193         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Invoke
3194         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3195         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3196         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Invoke
3197         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3198         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3199         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Invoke
3200         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3201         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3202         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Invoke
3203         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3204         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3205         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Invoke
3206         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3207         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3208         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Invoke
3209         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3210         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3211         Reported by Eric Blake.
3212
3213 2007-04-11  Bruno Haible  <bruno@clisp.org>
3214
3215         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Fix test. It always failed.
3216
3217 2007-04-10  Bruno Haible  <bruno@clisp.org>
3218
3219         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
3220         for NaN and Infinity. Needed on FreeBSD 6.1.
3221         * tests/test-vasnprintf-posix.c (test_function): Undo last change
3222         regarding results for "%010a" of Infinity and NaN.
3223         * tests/test-vasprintf-posix.c (test_function): Likewise.
3224         * tests/test-snprintf-posix.h (test_function): Likewise.
3225         * tests/test-sprintf-posix.h (test_function): Likewise.
3226         * tests/test-fprintf-posix.h (test_function): Likewise.
3227         * tests/test-printf-posix.h (test_function): Likewise.
3228         * tests/test-fprintf-posix.out: Likewise.
3229
3230 2007-04-10  Bruno Haible  <bruno@clisp.org>
3231
3232         * modules/locale-tests: New file.
3233         * tests/test-locale.c: New file.
3234
3235         * modules/locale: New file.
3236         * lib/locale_.h: New file.
3237         * m4/locale_h.m4: New file.
3238
3239 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
3240             Bruno Haible  <bruno@clisp.org>
3241
3242         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
3243         be determined, test for availability of the copysignf, copysign,
3244         copysignl functions.
3245         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
3246         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
3247         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
3248
3249 2007-04-09  Eric Blake  <ebb9@byu.net>
3250
3251         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
3252         * modules/stdio (Makefile.am): Support fflush.
3253         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
3254         * modules/fflush: New file.
3255         * lib/fflush.c: Likewise.
3256         * m4/fflush.m4: Likewise.
3257         * modules/fflush-tests: New test.
3258         * tests/test-fflush.c: Likewise.
3259         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
3260
3261 2007-04-06  Bruno Haible  <bruno@clisp.org>
3262
3263         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
3264         (VASNPRINTF): Use signbit for faster determination whether to print a
3265         minus sign.
3266         * modules/vasnprintf (Files): Remove lib/float+.h.
3267         * modules/fprintf-posix (Depends-on): Add signbit.
3268         * modules/snprintf-posix (Depends-on): Likewise.
3269         * modules/sprintf-posix (Depends-on): Likewise.
3270         * modules/vasnprintf-posix (Depends-on): Likewise.
3271         * modules/vasprintf-posix (Depends-on): Likewise.
3272         * modules/vfprintf-posix (Depends-on): Likewise.
3273         * modules/vsnprintf-posix (Depends-on): Likewise.
3274         * modules/vsprintf-posix (Depends-on): Likewise.
3275
3276 2007-04-06  Bruno Haible  <bruno@clisp.org>
3277
3278         * tests/test-frexp.c (main): Test also the sign bit of zero results.
3279         * tests/test-frexpl.c (main): Likewise.
3280         * tests/test-ldexpl.c (main): Likewise.
3281         * modules/frexp-tests (Depends-on): Add signbit.
3282         * modules/frexpl-tests (Depdends-on): Likewise.
3283         * modules/ldexpl-tests (Depdends-on): Likewise.
3284
3285 2007-04-06  Bruno Haible  <bruno@clisp.org>
3286
3287         * modules/signbit-tests: New file.
3288         * tests/test-signbit.c: New file.
3289
3290         * modules/signbit: New file.
3291         * lib/signbitf.c: New file.
3292         * lib/signbitd.c: New file.
3293         * lib/signbitl.c: New file.
3294         * m4/signbit.m4: New file.
3295         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
3296         (signbit): New macro.
3297         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
3298         REPLACE_SIGNBIT.
3299         * modules/math (Makefile.am) Substibute also GNULIB_SIGNBIT and
3300         REPLACE_FREXPL into math.h.
3301
3302 2007-04-06  Bruno Haible  <bruno@clisp.org>
3303
3304         * modules/isnanf-nolibm-tests: New file.
3305         * tests/test-isnanf.c: New file.
3306
3307         * modules/isnanf-nolibm: New file.
3308         * lib/isnanf.h: New file.
3309         * lib/isnanf.c: New file.
3310         * lib/isnan.c: Consider the USE_FLOAT macro.
3311         * m4/isnanf.m4: New file.
3312
3313 2007-04-06  Bruno Haible  <bruno@clisp.org>
3314
3315         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
3316         (Link): New section.
3317
3318         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
3319
3320 2007-04-06  Bruno Haible  <bruno@clisp.org>
3321
3322         Assume the 'long double' type.
3323         * m4/longdouble.m4: Remove file.
3324         * config/srclist.txt: Don't mention longdouble.m4.
3325         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
3326         * lib/float+.h: Likewise.
3327         * lib/frexp.c: Likewise.
3328         * lib/printf-args.h: Likewise.
3329         * lib/printf-args.c: Likewise.
3330         * lib/printf-frexp.c: Likewise.
3331         * lib/printf-parse.c: Likewise.
3332         * lib/vasnprintf.c: Likewise.
3333         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
3334         * m4/intl.m4: Likewise.
3335         * m4/isnanl.m4: Likewise.
3336         * m4/printf.m4: Likewise.
3337         * m4/printf-frexpl.m4: Likewise.
3338         * m4/vasnprintf.m4: Likewise.
3339         * modules/allocsa (Files): Remove m4/longdouble.m4.
3340         * modules/gettext (Files): Likewise.
3341         * modules/relocatable-prog-wrapper (Files): Likewise.
3342         * modules/vasnprintf (Files): Likewise.
3343         * modules/isnanl (Files): Likewise.
3344         (Include): Simplify.
3345         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
3346         (Include): Simplify.
3347         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
3348         (Include): Simplify.
3349         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
3350         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3351         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
3352         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3353         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
3354         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3355         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
3356         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3357         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
3358         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3359         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
3360         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3361         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
3362         * tests/test-isnanl.c: Likewise.
3363         * tests/test-snprintf-posix.h: Likewise.
3364         * tests/test-sprintf-posix.h: Likewise.
3365         * tests/test-vasnprintf-posix.c: Likewise.
3366         * tests/test-vasnprintf-posix2.c: Likewise.
3367         * tests/test-vasprintf-posix.c: Likewise.
3368
3369 2007-04-06  Bruno Haible  <bruno@clisp.org>
3370
3371         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
3372         * lib/math_.h [__DECC]: Include the overridden include file through
3373         #include_next, outside the double-inclusion guard.
3374         * lib/stdio_.h [__DECC]: Likewise.
3375         * lib/stdlib_.h [__DECC]: Likewise.
3376         * lib/string_.h [__DECC]: Likewise.
3377         * lib/time_.h [__DECC]: Likewise.
3378         * lib/wchar_.h [__DECC]: Likewise.
3379         * lib/wctype_.h [__DECC]: Likewise.
3380         * lib/inttypes_.h [__DECC]: Likewise.
3381         Reported by Albert Chin <china@thewrittenword.com> in
3382         <http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00088.html>.
3383
3384 2007-04-04  Eric Blake  <ebb9@byu.net>
3385
3386         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
3387         1.5.x.
3388
3389 2007-04-04  Bruno Haible  <bruno@clisp.org>
3390
3391         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
3392         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
3393
3394 2007-04-04  Bruno Haible  <bruno@clisp.org>
3395
3396         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
3397         results for "%010a" of Infinity and NaN.
3398         * tests/test-vasprintf-posix.c (test_function): Likewise.
3399         * tests/test-snprintf-posix.h (test_function): Likewise.
3400         * tests/test-sprintf-posix.h (test_function): Likewise.
3401         * tests/test-fprintf-posix.h (test_function): Remove these tests.
3402         * tests/test-printf-posix.h (test_function): Likewise.
3403         * tests/test-fprintf-posix.out: Update.
3404         Needed for FreeBSD 6.1.
3405
3406 2007-04-04  Bruno Haible  <bruno@clisp.org>
3407
3408         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
3409         directly used by the gnulib modules nor by gnulib-tool.
3410
3411 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
3412
3413         * DEPENDENCIES: Give overall description of version dependency
3414         desirability.  Use more-typical names for apps.
3415         Add shell, coreutils, diffutils, grep, tar, gzip.
3416
3417 2007-04-04  Simon Josefsson  <simon@josefsson.org>
3418
3419         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
3420
3421 2007-04-04  Karl Berry  <karl@gnu.org>
3422
3423         * MODULES.html.sh (func_module): missing '.
3424
3425 2007-04-03  Bruno Haible  <bruno@clisp.org>
3426
3427         * modules/argmatch-tests (Makefile.am): New variable
3428         test_argmatch_LDADD.
3429         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
3430         * modules/array-list-tests (Makefile.am): New variable
3431         test_array_list_LDADD.
3432         * modules/array-oset-tests (Makefile.am): New variable
3433         test_array_oset_LDADD.
3434         * modules/avltree-list-tests (Makefile.am): New variable
3435         test_avltree_list_LDADD.
3436         * modules/avltree-oset-tests (Makefile.am): New variable
3437         test_avltree_oset_LDADD.
3438         * modules/avltreehash-list-tests (Makefile.am): New variable
3439         test_avltreehash_list_LDADD.
3440         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
3441         test_canonicalize_lgpl_LDADD.
3442         * modules/carray-list-tests (Makefile.am): New variable
3443         test_carray_list_LDADD.
3444         * modules/dirname-tests (Makefile.am): New variable
3445         test_dirname_LDADD.
3446         * modules/linked-list-tests (Makefile.am): New variable
3447         test_linked_list_LDADD.
3448         * modules/linkedhash-list-tests (Makefile.am): New variable
3449         test_linkedhash_list_LDADD.
3450         * modules/rbtree-list-tests (Makefile.am): New variable
3451         test_rbtree_list_LDADD.
3452         * modules/rbtree-oset-tests (Makefile.am): New variable
3453         test_rbtree_oset_LDADD.
3454         * modules/rbtreehash-list-tests (Makefile.am): New variable
3455         test_rbtreehash_list_LDADD.
3456         * modules/xvasprintf-tests (Makefile.am): New variable
3457         test_xvasprintf_LDADD.
3458         Reported by Eric Blake.
3459
3460 2007-04-03  Eric Blake  <ebb9@byu.net>
3461
3462         * DEPENDENCIES: Weaken m4 requirements.
3463
3464 2007-04-03  Bruno Haible  <bruno@clisp.org>
3465
3466         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
3467         * modules/isnanl-tests (configure.ac): Likewise.
3468
3469 2007-04-03  Ben Pfaff  <blp@gnu.org>
3470
3471         * modules/iconv_open: Add $(srcdir)/ to source directory
3472         references in Makefile fragments that call gperf, to fix VPATH
3473         builds.
3474
3475 2007-04-03  Bruno Haible  <bruno@clisp.org>
3476
3477         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
3478         * lib/ldexpl.c: Undo last change.
3479
3480 2007-04-03  Bruno Haible  <bruno@clisp.org>
3481
3482         * modules/printf-frexpl (Depends-on): Undo last change.
3483         (Files): Add m4/ldexpl.m4.
3484
3485 2007-04-03  Bruno Haible  <bruno@clisp.org>
3486
3487         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
3488         * modules/isnanl (Link): New section.
3489
3490         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
3491         * modules/frexp (Link): New section.
3492
3493         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
3494         * modules/frexpl (Link): New section.
3495
3496         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
3497         * modules/ldexpl (Link): New section.
3498
3499 2007-04-03  Bruno Haible  <bruno@clisp.org>
3500
3501         * modules/TEMPLATE-EXTENDED: New file.
3502         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
3503
3504 2007-04-03  Bruno Haible  <bruno@clisp.org>
3505
3506         * DEPENDENCIES: New file.
3507         Suggested by Simon Josefsson.
3508
3509 2007-04-03  Bruno Haible  <bruno@clisp.org>
3510
3511         * doc/gnulib.texi: Escape @.
3512
3513 2007-04-03  James Youngman  <jay@gnu.org>
3514         and Paul Eggert  <eggert@cs.ucla.edu>
3515
3516         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
3517         birthtime on all systems that have birthtime, not just those which
3518         use st_birthtimensec rather than st_birthtim.  Putting zero in
3519         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
3520         that the birth time is not available for files on an NFS mount.
3521
3522 2007-04-03  Simon Josefsson  <simon@josefsson.org>
3523
3524         * modules/memxor: Move back from crypto/, suggested by Bruno.
3525         * modules/crypto/hmac-sha1: Fix memxor dependency.
3526
3527         * modules/crypto/gc: Moved from ../.
3528
3529 2007-04-02  Eric Blake  <ebb9@byu.net>
3530
3531         * lib/ldexpl.c (includes): Avoid libm.
3532
3533         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
3534
3535 2007-04-02  Bruno Haible  <bruno@clisp.org>
3536
3537         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
3538         on IRIX.
3539
3540 2007-04-02  Bruno Haible  <bruno@clisp.org>
3541
3542         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
3543         x86 or x86_64 platforms running MacOS X.
3544         Reported by Ryan Schmidt <@ryandesign.com>.
3545
3546 2007-04-02  Bruno Haible  <bruno@clisp.org>
3547
3548         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
3549         i386.
3550
3551 2007-04-01  Simon Josefsson  <simon@josefsson.org>
3552
3553         * modules/crypto/arcfour: Moved from ../.
3554         * modules/crypto/arcfour-tests: Moved from ../.
3555         * modules/crypto/arctwo: Moved from ../.
3556         * modules/crypto/arctwo-tests: Moved from ../.
3557         * modules/crypto/des: Moved from ../.
3558         * modules/crypto/des-tests: Moved from ../.
3559         * modules/crypto/gc-arcfour: Moved from ../.
3560         * modules/crypto/gc-arcfour-tests: Moved from ../.
3561         * modules/crypto/gc-arctwo: Moved from ../.
3562         * modules/crypto/gc-arctwo-tests: Moved from ../.
3563         * modules/crypto/gc-des: Moved from ../.
3564         * modules/crypto/gc-des-tests: Moved from ../.
3565         * modules/crypto/gc-hmac-md5: Moved from ../.
3566         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
3567         * modules/crypto/gc-hmac-sha1: Moved from ../.
3568         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
3569         * modules/crypto/gc-md2: Moved from ../.
3570         * modules/crypto/gc-md2-tests: Moved from ../.
3571         * modules/crypto/gc-md4: Moved from ../.
3572         * modules/crypto/gc-md4-tests: Moved from ../.
3573         * modules/crypto/gc-md5: Moved from ../.
3574         * modules/crypto/gc-md5-tests: Moved from ../.
3575         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
3576         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
3577         * modules/crypto/gc-random: Moved from ../.
3578         * modules/crypto/gc-rijndael: Moved from ../.
3579         * modules/crypto/gc-rijndael-tests: Moved from ../.
3580         * modules/crypto/gc-sha1: Moved from ../.
3581         * modules/crypto/gc-sha1-tests: Moved from ../.
3582         * modules/crypto/gc-tests: Moved from ../.
3583         * modules/crypto/hmac-md5: Moved from ../.
3584         * modules/crypto/hmac-md5-tests: Moved from ../.
3585         * modules/crypto/hmac-sha1: Moved from ../.
3586         * modules/crypto/hmac-sha1-tests: Moved from ../.
3587         * modules/crypto/md2: Moved from ../.
3588         * modules/crypto/md2-tests: Moved from ../.
3589         * modules/crypto/md4: Moved from ../.
3590         * modules/crypto/md4-tests: Moved from ../.
3591         * modules/crypto/md5: Moved from ../.
3592         * modules/crypto/md5-tests: Moved from ../.
3593         * modules/crypto/memxor: Moved from ../.
3594         * modules/crypto/rijndael: Moved from ../.
3595         * modules/crypto/rijndael-tests: Moved from ../.
3596         * modules/crypto/sha1: Moved from ../.
3597
3598 2007-03-30  James Youngman  <jay@gnu.org>
3599
3600         * tests/test-stat-time.c (prepare_test): use chmod() rather than
3601         rename() to change the ctime of a file (because ctime is unaffected
3602         by rename on jfs2 on AIX 5.1).
3603         (main): Start by doing cleanup, in case a previous run failed leaving
3604         test files behind.
3605
3606 2007-03-31  Bruno Haible  <bruno@clisp.org>
3607
3608         Support old proprietary implementations of iconv.
3609         * modules/iconv_open: New file.
3610         * lib/iconv_.h: New file.
3611         * m4/iconv_h.m4: New file.
3612         * lib/iconv_open.c: New file.
3613         * lib/iconv_open-aix.gperf: New file.
3614         * lib/iconv_open-hpux.gperf: New file.
3615         * lib/iconv_open-irix.gperf: New file.
3616         * lib/iconv_open-osf.gperf: New file.
3617         * m4/iconv_open.m4: New file.
3618         * modules/linebreak (Depends-on): Add iconv_open.
3619         * modules/striconv (Depends-on): Likewise.
3620         * modules/striconveh (Depends-on): Likewise.
3621         * modules/unicodeio (Depends-on): Likewise.
3622         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
3623         (iconv_t)(-1).
3624         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
3625         conversion if cd is (iconv_t)(-1).
3626         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
3627         is not possible.
3628
3629 2007-03-31  Bruno Haible  <bruno@clisp.org>
3630
3631         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
3632         work on Solaris either. Protect also second use of "autodetect_jp".
3633
3634 2007-03-31  Bruno Haible  <bruno@clisp.org>
3635
3636         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
3637         the function is not present.
3638
3639 2007-03-31  Bruno Haible  <bruno@clisp.org>
3640
3641         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
3642         the function is not present.
3643
3644 2007-03-31  Bruno Haible  <bruno@clisp.org>
3645
3646         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
3647         a bug in HP-UX iconv_open().
3648
3649 2007-03-31  Bruno Haible  <bruno@clisp.org>
3650
3651         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
3652         (Mathematics <math.h>): New section, add fpieee.
3653         (Input/output <stdio.h>): Add fseterr.
3654         (Mathematics <math.h>): New section, add printf-frexp.
3655         (Container data structures): Add sublist.
3656         (Core language properties): Add fpucw, inline.
3657         (Functions for greatest-width integer types <inttypes.h>): Add
3658         imaxabs, imaxdiv, inttypes.
3659         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
3660         isnanl-nolibm, ldexp.
3661         (Mathematics <math.h>): New section, add printf-frexpl.
3662         (Support for systems lacking POSIX:2001): Add fprintf-posix,
3663         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
3664         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
3665         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
3666         (Unicode string functions): Add unistr/u*-mbtoucr.
3667         (Java): Add javacomp-script, javaexec-script.
3668         (C#): Add csharpcomp-script, csharpexec-script.
3669         (Support for building libraries and executables): Add havelib,
3670         relocatable-*.
3671         (Support for maintaining and releasing projects): Renamed from
3672         'Support for maintaining and release projects'. Add announce-gen.
3673
3674 2007-03-31  Bruno Haible  <bruno@clisp.org>
3675
3676         * README: Talk primarily about git.
3677         (git and CVS): Renamed from CVS.
3678         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
3679         gnulib is available through git.
3680         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
3681
3682 2007-03-30  Bruno Haible  <bruno@clisp.org>
3683
3684         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
3685         * lib/poll_.h: Likewise.
3686         * lib/stat_.h: Likewise.
3687         * lib/sys_time_.h: Likewise.
3688         * lib/sysexit_.h: Likewise.
3689         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
3690         * lib/stdbool_.h: Likewise.
3691         * lib/byteswap_.h: Add double-inclusion guard.
3692
3693 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
3694
3695         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
3696
3697 2007-03-30  Karl Berry  <karl@gnu.org>
3698
3699         * config/srclist-update: double space after USA in the license
3700         substitution, since that's how it's usually (?) written.
3701
3702 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
3703
3704         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
3705         reported by Bruno Haible.
3706
3707 2007-03-29  Bruno Haible  <bruno@clisp.org>
3708
3709         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
3710         a bug in AIX iconv().
3711
3712 2007-03-29  Bruno Haible  <bruno@clisp.org>
3713
3714         * modules/ldexpl-tests: New file.
3715         * tests/test-ldexpl.c: New file.
3716
3717 2007-03-29  Bruno Haible  <bruno@clisp.org>
3718
3719         * lib/ldexpl.c: Include fpucw.h.
3720         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
3721         multiplication.
3722         * modules/ldexpl (Depends-on): Add fpucw.
3723
3724 2007-03-29  Bruno Haible  <bruno@clisp.org>
3725
3726         * modules/ldexpl: New file.
3727         * m4/ldexpl.m4: New file.
3728         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
3729         set.
3730         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
3731         REPLACE_LDEXPL.
3732         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
3733         REPLACE_LDEXPL.
3734         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
3735         gl_FUNC_LDEXPL_WORKS.
3736         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
3737         * modules/mathl (Files): Remove lib/ldexpl.c.
3738         (Depends-on): Add ldexpl.
3739
3740 2007-03-29  Bruno Haible  <bruno@clisp.org>
3741
3742         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
3743
3744 2007-03-29  Bruno Haible  <bruno@clisp.org>
3745
3746         * tests/test-striconveh.c (main): Don't assume that a direct conversion
3747         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
3748         and possibly also HP-UX.
3749         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
3750         work on AIX, IRIX, HP-UX, OSF/1.
3751         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
3752         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
3753         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
3754         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
3755         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
3756         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
3757
3758 2007-03-29  Bruno Haible  <bruno@clisp.org>
3759
3760         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
3761
3762 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
3763
3764         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
3765         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
3766
3767 2007-03-29  Eric Blake  <ebb9@byu.net>
3768
3769         * lib/acl-internal.h: Remove redundant include.
3770         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
3771         Cygwin when a file is locked.
3772
3773 2007-03-29  Bruno Haible  <bruno@clisp.org>
3774
3775         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
3776         file.
3777         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
3778
3779 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
3780
3781         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
3782         try to remove a parent directory if the child couldn't be removed
3783         (except for the first rmdir, which could fail because the child
3784         doesn't exist).  Problem reported by Jeff Blaine in
3785         <http://lists.gnu.org/archive/html/bug-tar/2007-03/msg00014.html>.
3786
3787 2007-03-28  Bruno Haible  <bruno@clisp.org>
3788
3789         * lib/striconveh.c (utf8conv_carefully): New function.
3790         (mem_cd_iconveh_internal): Invoke it.
3791
3792 2007-03-28  Bruno Haible  <bruno@clisp.org>
3793
3794         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
3795         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
3796         input.
3797         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
3798         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
3799         unistr/u8-uctomb.
3800
3801 2007-03-28  Bruno Haible  <bruno@clisp.org>
3802
3803         * modules/unistr/u8-mbtoucr: New file.
3804         * lib/unistr/u8-mbtoucr.c: New file.
3805         * modules/unistr/u16-mbtoucr: New file.
3806         * lib/unistr/u16-mbtoucr.c: New file.
3807         * modules/unistr/u16-mbtoucr: New file.
3808         * lib/unistr/u16-mbtoucr.c: New file.
3809         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
3810
3811 2007-03-27  Simon Josefsson  <simon@josefsson.org>
3812             Bruno Haible  <bruno@clisp.org>
3813
3814         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
3815         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
3816         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
3817
3818         * m4/stdio_h.m4: Add stubs for vasprintf too.
3819
3820         * modules/stdio: Support vasprintf in sed command.
3821
3822         * modules/vasprintf: Depend on stdio for prototypes.  Remove
3823         vasprintf.h.  Add stdio module indicator.
3824
3825         * lib/stdio_.h: Declare asprintf and vasprintf, based on
3826         vasprintf.h.
3827
3828         * lib/vasprintf.h: File removed.
3829
3830         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
3831         * lib/vasprintf.c: Ditto.
3832         * lib/xvasprintf.c: Ditto.
3833         * tests/test-vasprintf-posix.c: Ditto.
3834         * tests/test-vasprintf.c: Ditto.
3835
3836 2007-03-27  Bruno Haible  <bruno@clisp.org>
3837
3838         Make vasnprintf multithread-safe.
3839         * lib/vasnprintf.c (decimal_point_char): New function.
3840         (VASNPRINTF): Use it.
3841         Suggested by Simon Josefsson.
3842
3843 2007-03-27  Eric Blake  <ebb9@byu.net>
3844
3845         Support sub-second birthtime on cygwin.
3846         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
3847         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
3848         (get_stat_birthtime): Also work with st_birthtim.
3849
3850 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
3851
3852         * lib/stat-time.h (USE_BIRTHTIME): Remove.
3853         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
3854         (get_stat_birthtime_ns): Do not try to use "spare" fields.
3855         (get_stat_birthtime_ns): Simplify compile-time tests.
3856         (get_stat_birthtime): Change the API to look like
3857         get_stat_mtime etc., except return a negative tv_nsec on error.
3858         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
3859         Don't check for "spare" fields.
3860         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
3861         or for struct stat.st_birthtime, as these tests aren't used.
3862         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
3863
3864 2007-03-27  Bruno Haible  <bruno@clisp.org>
3865
3866         * lib/stat-time.h: Include <sys/stat.h>.
3867
3868 2007-03-27  James Youngman  <jay@gnu.org>
3869
3870         * lib/stat-time.h (get_stat_birthtime): New function for
3871           retrieving st_birthtime as provided by UFS2 (hence *BSD).
3872         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
3873           and its variants.
3874         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
3875         * modules/stat-time-test: New file.
3876         * tests/test-stat-time.c: New test, devised by Bruno Haible.
3877
3878 2007-03-26  Bruno Haible  <bruno@clisp.org>
3879
3880         Better support of signalling NaNs.
3881         * lib/atanl.c: Include isnanl.h.
3882         (atanl): Perform test for NaN at the beginning of the function and
3883         through a call to isnanl.
3884         * lib/cosl.c: Include isnanl.h.
3885         (cosl): Perform test for NaN at the beginning of the function and
3886         through a call to isnanl.
3887         * lib/ldexpl.c: Include isnanl.h.
3888         (ldexpl): Perform test for NaN through a call to isnanl.
3889         * lib/logl.c: Include isnanl.h.
3890         (logl): Perform test for NaN at the beginning of the function and
3891         through a call to isnanl.
3892         * lib/sinl.c: Include isnanl.h.
3893         (sinl): Perform test for NaN at the beginning of the function and
3894         through a call to isnanl.
3895         * lib/sqrtl.c: Include isnanl.h.
3896         (sqrtl): Perform test for NaN at the beginning of the function and
3897         through a call to isnanl.
3898         * lib/tanl.c: Include isnanl.h.
3899         (tanl): Perform test for NaN at the beginning of the function and
3900         through a call to isnanl.
3901         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
3902         * modules/mathl (Depends-on): Add isnanl.
3903
3904 2007-03-26  Eric Blake  <ebb9@byu.net>
3905
3906         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
3907         regression in logic sense of previous patch.
3908
3909 2007-03-26  Bruno Haible  <bruno@clisp.org>
3910
3911         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
3912         unportable shell command "if ! ...".
3913         Reported by Ralf Wildenhues.
3914
3915 2007-03-25  Bruno Haible  <bruno@clisp.org>
3916
3917         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
3918         <sysexits.h> file, and only add EX_CONFIG.
3919         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
3920         absolute file name and whether it is sufficient. Substitute also
3921         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
3922         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
3923         ABSOLUTE_SYSEXITS_H into sysexits.h.
3924
3925 2007-03-25  Bruno Haible  <bruno@clisp.org>
3926
3927         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
3928         hints is NULL.
3929
3930 2007-03-25  Bruno Haible  <bruno@clisp.org>
3931
3932         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
3933         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
3934
3935 2007-03-25  Bruno Haible  <bruno@clisp.org>
3936
3937         * lib/vasnprintf.c: Include langinfo.h.
3938         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
3939         multithread-safe.
3940         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
3941         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
3942         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
3943         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
3944         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
3945         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
3946         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
3947         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
3948         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
3949         Reported by Simon Josefsson.
3950
3951 2007-03-25  Bruno Haible  <bruno@clisp.org>
3952
3953         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
3954         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
3955         * modules/vasnprintf (Depends-on): Add stdint.
3956
3957 2007-03-25  Bruno Haible  <bruno@clisp.org>
3958
3959         * modules/fpieee: New file.
3960         * m4/fpieee.m4: New file.
3961         * modules/isnan-nolibm (Depends-on): Add fpieee.
3962         * modules/isnanl-nolibm (Depends-on): Add fpieee.
3963         * modules/isnanl (Depends-on): Add fpieee.
3964
3965 2007-03-25  Bruno Haible  <bruno@clisp.org>
3966
3967         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
3968
3969 2007-03-25  Bruno Haible  <bruno@clisp.org>
3970
3971         Avoid test failures on IRIX 6.5.
3972         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
3973         (main): Use it.
3974         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
3975         macros.
3976         (main): Use them.
3977
3978 2007-03-25  Bruno Haible  <bruno@clisp.org>
3979
3980         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
3981         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
3982         exists but doesn't work.
3983         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
3984         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
3985         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
3986         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
3987
3988 2007-03-25  Bruno Haible  <bruno@clisp.org>
3989
3990         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
3991         returns inf. Needed on IRIX 6.5.
3992
3993 2007-03-25  Bruno Haible  <bruno@clisp.org>
3994
3995         * tests/test-frexpl.c: Include isnanl-nolibm.h.
3996         (main): Use isnanl instead of x != x idiom.
3997         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
3998
3999         * tests/test-frexp.c: Include isnan.h.
4000         (main): Use isnan instead of x != x idiom.
4001         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
4002
4003 2007-03-25  Bruno Haible  <bruno@clisp.org>
4004
4005         * tests/test-frexp.c (NaN): New function/macro.
4006         (main): Use it instead of 0.0 / 0.0.
4007         * tests/test-isnan.c (NaN): New function/macro.
4008         (main): Use it instead of 0.0 / 0.0.
4009         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
4010         (test_function): Use it instead of 0.0 / 0.0.
4011         * tests/test-vasprintf-posix.c (NaN): New function/macro.
4012         (test_function): Use it instead of 0.0 / 0.0.
4013         * tests/test-snprintf-posix.h (NaN): New function/macro.
4014         (test_function): Use it instead of 0.0 / 0.0.
4015         * tests/test-sprintf-posix.h (NaN): New function/macro.
4016         (test_function): Use it instead of 0.0 / 0.0.
4017         * tests/test-fprintf-posix.h (NaN): New function/macro.
4018         (test_function): Use it instead of 0.0 / 0.0.
4019         * tests/test-printf-posix.h (NaN): New function/macro.
4020         (test_function): Use it instead of 0.0 / 0.0.
4021
4022         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
4023
4024 2007-03-25  Bruno Haible  <bruno@clisp.org>
4025
4026         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
4027
4028 2007-03-25  Bruno Haible  <bruno@clisp.org>
4029
4030         * lib/regexec.c (merge_state_with_log): Make static.
4031
4032 2007-03-25  Bruno Haible  <bruno@clisp.org>
4033
4034         * lib/trigl.c (kernel_rem_pio2): Make static.
4035
4036 2007-03-25  Bruno Haible  <bruno@clisp.org>
4037
4038         * lib/sincosl.c (sincosl_table): Make static.
4039
4040 2007-03-25  Bruno Haible  <bruno@clisp.org>
4041
4042         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
4043         if the compiler does not support C99.
4044
4045 2007-03-25  Bruno Haible  <bruno@clisp.org>
4046
4047         * modules/time (Makefile.am): Ensure all rule action lines start with a
4048         tab.
4049
4050 2007-03-24  Bruno Haible  <bruno@clisp.org>
4051
4052         * modules/tsearch-tests: New file.
4053         * tests/test-tsearch.sh: New file.
4054         * tests/test-tsearch.c: New file, mostly copied from glibc.
4055
4056         * modules/search-tests: New file.
4057         * tests/test-search.c: New file.
4058
4059         * modules/search: New file.
4060         * lib/search_.h: New file, incorporating lib/tsearch.h.
4061         * m4/search_h.m4: New file.
4062         * lib/tsearch.h: Remove file.
4063         * lib/tsearch.c: Include search.h instead of tsearch.h.
4064         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
4065         HAVE_TSEARCH.
4066         * modules/tsearch (Files): Remove lib/tsearch.h.
4067         (Depends-on): Add search.
4068         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
4069         (Include): Change tsearch.h into search.h.
4070
4071 2007-03-24  Bruno Haible  <bruno@clisp.org>
4072
4073         * modules/fpucw: New file.
4074         * lib/fpucw.h: New file.
4075         * lib/frexp.c: Include fpucw.h.
4076         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
4077         (FUNC): Use them.
4078         * lib/printf-frexp.c: Include fpucw.h.
4079         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
4080         (FUNC): Use them.
4081         * lib/vasnprintf.c: Include fpucw.h.
4082         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
4083         'long double' calculations.
4084         * tests/test-frexpl.c: Include fpucw.h.
4085         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
4086         * tests/test-printf-frexpl.c: Include fpucw.h.
4087         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
4088         * modules/frexpl (Depends-on): Add fpucw.
4089         * modules/printf-frexpl (Depends-on): Likewise.
4090         * modules/fprintf-posix (Depends-on): Likewise.
4091         * modules/snprintf-posix (Depends-on): Likewise.
4092         * modules/sprintf-posix (Depends-on): Likewise.
4093         * modules/vasnprintf-posix (Depends-on): Likewise.
4094         * modules/vasprintf-posix (Depends-on): Likewise.
4095         * modules/vfprintf-posix (Depends-on): Likewise.
4096         * modules/vsnprintf-posix (Depends-on): Likewise.
4097         * modules/vsprintf-posix (Depends-on): Likewise.
4098         * modules/frexpl-tests (Depends-on): Likewise.
4099         * modules/printf-frexpl-tests (Depends-on): Likewise.
4100
4101 2007-03-24  Bruno Haible  <bruno@clisp.org>
4102
4103         * lib/float+.h: New file.
4104         * lib/isnan.c: Include float+.h.
4105         (SIZE): New macro.
4106         (FUNC): Compare only SIZE bytes of the value.
4107         * lib/vasnprintf.c: Include float+.h.
4108         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
4109         SIZEOF_LDBL or SIZEOF_DBL bytes.
4110         * modules/isnan-nolibm (Files): Add lib/float+.h.
4111         * modules/isnanl-nolibm (Files): Add lib/float+.h.
4112         * modules/isnanl (Files): Add lib/float+.h.
4113         * modules/vasnprintf (Files): Add lib/float+.h.
4114
4115 2007-03-24  Bruno Haible  <bruno@clisp.org>
4116
4117         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
4118         include isnanl-nolibm.h.
4119
4120 2007-03-24  Bruno Haible  <bruno@clisp.org>
4121
4122         * tests/test-read-file.c (main): Don't produce spurious output for
4123         expected situations. Make the test fail if it encountered unexpected
4124         results.
4125
4126 2007-03-24  Bruno Haible  <bruno@clisp.org>
4127
4128         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
4129         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
4130
4131 2007-03-24  Bruno Haible  <bruno@clisp.org>
4132
4133         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
4134
4135 2007-03-24  Bruno Haible  <bruno@clisp.org>
4136
4137         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
4138         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
4139
4140         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
4141         * modules/utf8-ucs4: Turn into a symbolic link to module
4142         unistr/u8-mbtouc.
4143
4144         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
4145         utf8-ucs4-unsafe.
4146         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
4147         unistr/u8-mbtouc-unsafe.
4148
4149         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
4150         * modules/utf16-ucs4: Turn into a symbolic link to module
4151         unistr/u16-mbtouc.
4152
4153         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
4154         utf16-ucs4-unsafe.
4155         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
4156         unistr/u16-mbtouc-unsafe.
4157
4158         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
4159         * modules/ucs4-utf8: Turn into a symbolic link to module
4160         unistr/u8-ubtomb.
4161
4162         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
4163         * modules/ucs4-utf16: Turn into a symbolic link to module
4164         unistr/u16-ubtomb.
4165
4166 2007-03-24  Bruno Haible  <bruno@clisp.org>
4167
4168         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
4169         Enable the function only if HAVE_INLINE.
4170         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
4171         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
4172         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
4173         Enable the function only if HAVE_INLINE.
4174         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
4175         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
4176         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
4177         Enable the function only if HAVE_INLINE.
4178         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
4179         Enable the function only if HAVE_INLINE.
4180         * modules/utf8-ucs4: Update.
4181         * modules/utf8-ucs4-unsafe: Update.
4182         * modules/utf16-ucs4: Update.
4183         * modules/utf16-ucs4-unsafe: Update.
4184         * modules/ucs4-utf8: Update.
4185         * modules/ucs4-utf16: Update.
4186
4187 2007-03-24  Bruno Haible  <bruno@clisp.org>
4188
4189         * lib/utf8-ucs4.h: Remove file.
4190         * lib/utf8-ucs4-unsafe.h: Remove file.
4191         * lib/utf16-ucs4.h: Remove file.
4192         * lib/utf16-ucs4-unsafe.h: Remove file.
4193         * lib/ucs4-utf8.h: Remove file.
4194         * lib/ucs4-utf16.h: Remove file.
4195         * lib/unistr.h: Include their previous contents.
4196         * m4/utf-ucs4.m4: Remove file.
4197         * m4/ucs4-utf.m4: Remove file.
4198         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
4199         (Depends-on): Add unistr/base.
4200         (configure.ac): Remove gl_UTF_UCS4.
4201         (Makefile.am): Update.
4202         (Include): Change to unistr.h.
4203         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
4204         (Depends-on): Add unistr/base.
4205         (configure.ac): Remove gl_UTF_UCS4.
4206         (Makefile.am): Update.
4207         (Include): Change to unistr.h.
4208         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
4209         (Depends-on): Add unistr/base.
4210         (configure.ac): Remove gl_UTF_UCS4.
4211         (Makefile.am): Update.
4212         (Include): Change to unistr.h.
4213         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
4214         (Depends-on): Add unistr/base.
4215         (configure.ac): Remove gl_UTF_UCS4.
4216         (Makefile.am): Update.
4217         (Include): Change to unistr.h.
4218         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
4219         (Depends-on): Add unistr/base.
4220         (configure.ac): Remove gl_UCS4_UTF.
4221         (Makefile.am): Update.
4222         (Include): Change to unistr.h.
4223         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
4224         (Depends-on): Add unistr/base.
4225         (configure.ac): Remove gl_UCS4_UTF.
4226         (Makefile.am): Update.
4227         (Include): Change to unistr.h.
4228         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
4229         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
4230         utf8-ucs4-unsafe.h.
4231         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
4232         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
4233         utf16-ucs4-unsafe.h.
4234         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
4235         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
4236         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
4237         * lib/unistr/u8-strchr.c: Likewise.
4238         * lib/unistr/u8-strrchr.c: Likewise.
4239         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
4240         * lib/unistr/u16-strchr.c: Likewise.
4241         * lib/unistr/u16-strrchr.c: Likewise.
4242         * lib/striconveh.c: Update.
4243         * lib/linebreak.c: Update.
4244
4245 2007-03-24  Bruno Haible  <bruno@clisp.org>
4246
4247         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
4248         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
4249
4250 2007-03-22  Bruno Haible  <bruno@clisp.org>
4251
4252         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
4253
4254 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
4255
4256         * MODULES.html.sh (File system functions): New module write-any-file.
4257         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
4258         * m4/write-any-file.m4: New files.
4259
4260 2007-03-23  Eric Blake  <ebb9@byu.net>
4261
4262         * gnulib-tool: Rearrange space-tab sequences, since some editors
4263         like to eat them.
4264
4265 2007-03-23  Eric Blake  <ebb9@byu.net>
4266
4267         * lib/version-etc.c (version_etc_va): Update license wording to
4268         be more concise.  Recommended by Richard Stallman.
4269
4270 2007-03-22  Bruno Haible  <bruno@clisp.org>
4271
4272         * lib/poll.c (MSG_PEEK): New fallback definition.
4273
4274 2007-03-22  Bruno Haible  <bruno@clisp.org>
4275
4276         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
4277         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
4278         (main): Update.
4279         Fixes a compilation error on BeOS.
4280
4281 2007-03-22  Bruno Haible  <bruno@clisp.org>
4282
4283         * modules/frexpl-tests: New file.
4284         * tests/test-frexpl.c: New file.
4285
4286         * modules/frexpl: New file.
4287         * m4/frexpl.m4: New file.
4288         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
4289         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
4290         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
4291         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
4292         (Depends-on): Add frexpl. Remove isnanl-nolibm.
4293         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
4294
4295 2007-03-22  Bruno Haible  <bruno@clisp.org>
4296
4297         * lib/frexpl.c: Share code with lib/frexp.c.
4298         * modules/mathl (Files): Add lib/frexp.c.
4299         (Depends-on): Add isnanl-nolibm.
4300
4301 2007-03-22  Bruno Haible  <bruno@clisp.org>
4302
4303         * modules/printf-frexp (Files): Add m4/frexp.m4.
4304         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
4305         only if the found frexp function actually works.
4306
4307 2007-03-22  Bruno Haible  <bruno@clisp.org>
4308
4309         * lib/frexp.c: Remove older implementation that uses divisions.
4310
4311 2007-03-21  Bruno Haible  <bruno@clisp.org>
4312
4313         * modules/frexp-tests: New file.
4314         * tests/test-frexp.c: New file.
4315
4316         * modules/frexp: New file.
4317         * lib/frexp.c: New file.
4318         * m4/frexp.m4: New file.
4319         * lib/math_.h (frexp): New declaration.
4320         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
4321         REPLACE_FREXP.
4322         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
4323
4324 2007-03-21  Bruno Haible  <bruno@clisp.org>
4325
4326         * modules/isnanl-tests: New file.
4327         * tests/test-isnanl.c: New file.
4328
4329         * modules/isnanl: New file.
4330         * lib/isnanl.h: New file.
4331         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
4332         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
4333         gl_FUNC_ISNANL_WORKS.
4334         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
4335         New macros.
4336
4337 2007-03-21  Bruno Haible  <bruno@clisp.org>
4338
4339         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
4340         lib/isnanl.h.
4341         (Include): Update.
4342         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
4343         * lib/vasnprintf.c: Update.
4344         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
4345         tests/test-isnanl.h, remove tests/test-isnanl.c.
4346         (Makefile.am): Update.
4347         * tests/test-isnanl-nolibm.c: New file.
4348         * tests/test-isnanl.h: New file.
4349         * tests/test-isnanl.c: Remove file.
4350
4351 2007-03-21  Jim Meyering  <jim@meyering.net>
4352
4353         When trying to open ".", treat ESTALE like EACCES.
4354         * lib/savewd.c (savewd_save): Resort to forking not just upon
4355         failure with EACCES, but also when errno is ESTALE.
4356
4357 2007-03-20  Bruno Haible  <bruno@clisp.org>
4358
4359         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
4360         Needed on AIX 5.1. Reported by Matthew Woehlke.
4361
4362 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
4363
4364         Suggestions by Bruno Haible:
4365         * lib/acl-internal.h: Include "gettext.h" rather than rolling
4366         our own.
4367         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
4368         * modules/acl (Depends-on): Add gettext.
4369
4370 2007-03-19  Bruno Haible  <bruno@clisp.org>
4371
4372         * modules/iconvme: Remove file.
4373         * lib/iconvme.h: Remove file.
4374         * lib/iconvme.c: Remove file.
4375         * m4/iconvme.m4: Remove file.
4376
4377 2007-03-19  Bruno Haible  <bruno@clisp.org>
4378
4379         * doc/relocatable-maint.texi: Break long shell script line.
4380         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
4381
4382 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
4383
4384         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
4385         handle file_has_acl.
4386         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
4387         * lib/acl.c: Move header inclusions and related macro defns into
4388         lib/acl-internal.h.
4389         (S_ISLNK): Remove defn, since that's now done for us.
4390         (file_has_acl): Move to lib/file-has-acl.c.
4391         Call acl_trivial if available.  This is the crucial part of the fix.
4392         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
4393         shared within the library.  Rewrite a bit, partly to make it compatible
4394         with the GNU coding style.
4395         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
4396         Remove unnecessary double-quotes.
4397         Don't test for acl_to_text; the build will catch that.
4398         Replace acl_entries if it doesn't exist and it is needed.
4399         Check for -lsec and acl_trivial (as used on Solaris 10).
4400         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
4401         lib/file-has-acl.c.
4402         (Depends-on): Add sys_stat, for S_ISLNK.
4403
4404 2007-03-19  Ben Pfaff  <blp@gnu.org>
4405
4406         * doc/gnulib.texi: Fix typos.
4407         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
4408
4409 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
4410
4411         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
4412         If size is zero here, buf must be zero.
4413
4414 2007-03-19  Simon Josefsson  <simon@josefsson.org>
4415
4416         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
4417         <bruno@clisp.org>.
4418
4419 2007-03-18  Bruno Haible  <bruno@clisp.org>
4420
4421         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
4422         Suggested by Eric Blake.
4423
4424 2007-03-18  Ben Pfaff  <blp@gnu.org>
4425
4426         * doc/relocatable.texi: Recommend using as prefix a directory
4427         that does not exist and will never be created.  Based on
4428         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
4429         and others.
4430
4431 2007-03-17  Bruno Haible  <bruno@clisp.org>
4432
4433         * lib/fchownat.c: Include lchown.h.
4434
4435 2007-03-17  Bruno Haible  <bruno@clisp.org>
4436
4437         Fix endless loop when the given allocated size was > INT_MAX.
4438         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
4439         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
4440         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
4441         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
4442         * lib/sprintf.c (sprintf): Likewise.
4443
4444 2007-03-17  Bruno Haible  <bruno@clisp.org>
4445
4446         * tests/test-argp-2.sh (func_compare): Output a context diff.
4447
4448 2007-03-17  Bruno Haible  <bruno@clisp.org>
4449
4450         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
4451         locale's decimal-point character.
4452
4453 2007-03-17  Bruno Haible  <bruno@clisp.org>
4454
4455         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
4456         before comparing it. Needed because on some platforms (e.g. x86) a
4457         'long double' occupies less bytes than sizeof (long double).
4458
4459 2007-03-17  Bruno Haible  <bruno@clisp.org>
4460
4461         * tests/test-crc.c (main): Make printf statements 64-bit clean.
4462         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
4463         * tests/test-getaddrinfo.c (simple): Likewise.
4464         * tests/test-read-file.c (main): Likewise.
4465
4466 2007-03-17  Bruno Haible  <bruno@clisp.org>
4467
4468         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
4469
4470 2007-03-17  Bruno Haible  <bruno@clisp.org>
4471
4472         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
4473         unused variable.
4474
4475 2007-03-17  Bruno Haible  <bruno@clisp.org>
4476
4477         * tests/test-c-strcasecmp.c: Include c-strcase.h.
4478         * tests/test-c-strncasecmp.c: Likewise.
4479
4480 2007-03-17  Bruno Haible  <bruno@clisp.org>
4481
4482         * modules/stdlib (Depends-on): Add unistd.
4483         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
4484         Needed for MacOS X 10.3.
4485
4486 2007-03-17  Bruno Haible  <bruno@clisp.org>
4487
4488         * lib/unistr/u-strdup.h: Include <stdlib.h>.
4489
4490 2007-03-17  Bruno Haible  <bruno@clisp.org>
4491
4492         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
4493
4494 2007-03-17  Bruno Haible  <bruno@clisp.org>
4495
4496         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
4497         to reflect files copied from gnulib (with or without modifications).
4498         Suggested by Jim Meyering.
4499
4500 2007-03-17  Eric Blake  <ebb9@byu.net>
4501
4502         * NEWS: Document stdlib change from 2007-02-18.
4503
4504 2007-03-17  Jim Meyering  <jim@meyering.net>
4505
4506         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
4507         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
4508         someone uses a name containing shell meta-characters.
4509         Reported by Alfred M. Szmidt.
4510
4511         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
4512
4513 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
4514
4515         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
4516         and copy gettext configuration files only if configure.ac contains
4517         a use of AM_GNU_GETTEXT_VERSION.
4518
4519 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
4520
4521         * build-aux/bootstrap (gnulib_name): New variable.
4522         (gnulib_tool_options): Use it.
4523
4524 2007-03-13  Simon Josefsson  <simon@josefsson.org>
4525
4526         * tests/test-des.c: Use new namespace.
4527
4528 2007-03-15  Bruno Haible  <bruno@clisp.org>
4529
4530         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
4531         Reported by James Youngman <jay@gnu.org>.
4532
4533 2007-03-15  Bruno Haible  <bruno@clisp.org>
4534
4535         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
4536         declared prototype. Needed with cc on OSF/1 5.1.
4537
4538 2007-03-15  Bruno Haible  <bruno@clisp.org>
4539
4540         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
4541         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
4542         (struct gl_list_implementation): Add dispose_fn argument to the
4543         'create_empty', 'create' methods.
4544         (struct gl_list_impl_base): Add field 'dispose_fn'.
4545         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
4546         argument.
4547         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
4548         dispose_fn argument.
4549         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
4550         dispose_fn on the dropped values.
4551         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
4552         dispose_fn argument.
4553         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
4554         dropped values.
4555         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
4556         (gl_tree_remove_node): Call dispose_fn on the dropped value.
4557         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
4558         (gl_tree_remove_node): Call dispose_fn on the dropped value.
4559         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
4560         argument.
4561         (gl_tree_list_free): Call dispose_fn on the dropped values.
4562         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
4563         the dropped values.
4564         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
4565         Add dispose_fn argument.
4566         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
4567         Call dispose_fn on the dropped values.
4568         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
4569         Add dispose_fn argument.
4570         (gl_sublist_create): Initialize the 'dispose_fn' field.
4571         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
4572         * tests/test-array_list.c (main): Update.
4573         * tests/test-carray_list.c (main): Update.
4574         * tests/test-avltree_list.c (main): Update.
4575         * tests/test-rbtree_list.c (main): Update.
4576         * tests/test-avltreehash_list.c (main): Update.
4577         * tests/test-rbtreehash_list.c (main): Update.
4578         * tests/test-linked_list.c (main): Update.
4579         * tests/test-linkedhash_list.c (main): Update.
4580         * tests/test-array_oset.c (main): Update.
4581
4582 2007-03-15  Bruno Haible  <bruno@clisp.org>
4583
4584         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
4585         (gl_oset_create_empty): Add dispose_fn argument.
4586         (struct gl_oset_implementation): Add dispose_fn argument to
4587         'create_empty' method.
4588         (struct gl_oset_impl_base): Add dispose_fn field.
4589         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
4590         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
4591         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
4592         values.
4593         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
4594         (gl_tree_oset_free): Call dispose_fn on the dropped values.
4595         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
4596         dropped value.
4597         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
4598         dropped value.
4599         * tests/test-array_oset.c (main): Update.
4600         * tests/test-avltree_oset.c (main): Update.
4601         * tests/test-rbtree_oset.c (main): Update.
4602         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
4603
4604 2007-03-13  Bruno Haible  <bruno@clisp.org>
4605
4606         * tests/test-stdbool.c (i): Update after last patch.
4607
4608 2007-03-12  Bruno Haible  <bruno@clisp.org>
4609
4610         * lib/quotearg.c: Include <wctype.h> early, before the definition of
4611         the iswprint macro. Needed on Solaris 2.5.1.
4612
4613 2007-03-12  Bruno Haible  <bruno@clisp.org>
4614
4615         * tests/test-printf-frexp.c (main): Declare x as volatile.
4616
4617 2007-03-12  Simon Josefsson  <simon@josefsson.org>
4618
4619         * doc/gnulib.texi (Build robot for gnulib): New section.
4620
4621 2007-03-12  Jim Meyering  <jim@meyering.net>
4622
4623         * build-aux/bootstrap: New file.
4624         * build-aux/bootstrap.conf: New file, from coreutils.
4625
4626 2007-03-11  Bruno Haible  <bruno@clisp.org>
4627
4628         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
4629
4630 2007-03-12  Simon Josefsson  <simon@josefsson.org>
4631
4632         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
4633         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
4634         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
4635
4636 2007-03-11  Bruno Haible  <bruno@clisp.org>
4637
4638         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
4639         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
4640
4641 2007-03-11  Bruno Haible  <bruno@clisp.org>
4642
4643         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
4644         formula. Needed for SunPRO C 5.0.
4645
4646 2007-03-11  Bruno Haible  <bruno@clisp.org>
4647
4648         * modules/long-options (Depends-on): Add getopt.
4649
4650 2007-03-11  Bruno Haible  <bruno@clisp.org>
4651
4652         * modules/modechange (Depends-on): Add stdbool.
4653
4654 2007-03-11  Bruno Haible  <bruno@clisp.org>
4655
4656         * modules/i-ring (Depends-on): Add stdbool.
4657
4658 2007-03-11  Bruno Haible  <bruno@clisp.org>
4659
4660         * modules/gc-des (Depends-on): Add stdbool.
4661
4662 2007-03-11  Bruno Haible  <bruno@clisp.org>
4663
4664         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
4665
4666 2007-03-11  Bruno Haible  <bruno@clisp.org>
4667
4668         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
4669
4670 2007-03-11  Bruno Haible  <bruno@clisp.org>
4671
4672         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
4673
4674 2007-03-11  Bruno Haible  <bruno@clisp.org>
4675
4676         * lib/vasnprintf.c (sprintf): Undefine.
4677
4678 2007-03-11  Bruno Haible  <bruno@clisp.org>
4679
4680         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
4681         initializers in SunPRO C and Compaq C compilers.
4682
4683 2007-03-11  Bruno Haible  <bruno@clisp.org>
4684
4685         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
4686         decrementing code ANSI C compliant.
4687
4688 2007-03-11  Bruno Haible  <bruno@clisp.org>
4689
4690         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
4691         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
4692
4693 2007-03-11  Bruno Haible  <bruno@clisp.org>
4694
4695         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
4696         <stdbool.h> substitute doesn't pass.
4697
4698 2007-03-11  Bruno Haible  <bruno@clisp.org>
4699
4700         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
4701
4702 2007-03-11  Bruno Haible  <bruno@clisp.org>
4703
4704         * gnulib-tool (func_create_megatestdir): Create also an autobuild
4705         script, for submission to autobuild.josefsson.org.
4706
4707 2007-03-10  Bruno Haible  <bruno@clisp.org>
4708
4709         * modules/canonicalize-lgpl-tests: New file.
4710         * tests/test-canonicalize-lgpl.sh: New file.
4711         * tests/test-canonicalize-lgpl.c: New file.
4712
4713         * modules/c-strcase-tests: New file.
4714         * tests/test-c-strcase.sh: New file.
4715         * tests/test-c-strcasecmp.c: New file.
4716         * tests/test-c-strncasecmp.c: New file.
4717
4718         * modules/atexit-tests: New file.
4719         * tests/test-atexit.sh: New file.
4720         * tests/test-atexit.c: New file.
4721
4722 2007-03-10  Bruno Haible  <bruno@clisp.org>
4723
4724         * tests/test-binary-io.sh: Use temporary filenames that are not so
4725         likely to clash with those of other tests (in a parallel make).
4726         * tests/test-binary-io.c: Likewise.
4727
4728 2007-03-10  Bruno Haible  <bruno@clisp.org>
4729
4730         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
4731         fallback; use #error instead.
4732         Suggested by Simon Josefsson.
4733
4734 2007-03-10  Bruno Haible  <bruno@clisp.org>
4735
4736         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
4737         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
4738         first and the last.
4739
4740 2007-03-10  Bruno Haible  <bruno@clisp.org>
4741
4742         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
4743
4744 2007-03-10  Bruno Haible  <bruno@clisp.org>
4745
4746         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
4747         "make distcheck".
4748         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
4749         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
4750         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
4751
4752 2007-03-10  Bruno Haible  <bruno@clisp.org>
4753
4754         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
4755         variable.
4756         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
4757         variable.
4758
4759 2007-03-09  Eric Blake  <ebb9@byu.net>
4760         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
4761
4762         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
4763         types are not being provided by gnulib.
4764         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
4765         types are supported.
4766
4767 2007-03-10  Bruno Haible  <bruno@clisp.org>
4768
4769         * lib/stdio_.h (__attribute__): New macro.
4770         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
4771         vsprintf): Specify __attribute__ __format__ for GCC.
4772         Suggested by Eric Blake.
4773
4774 2007-03-09  Bruno Haible  <bruno@clisp.org>
4775
4776         * modules/printf-posix-tests: New file.
4777         * tests/test-printf-posix.sh: New file.
4778         * tests/test-printf-posix.c: New file.
4779
4780         * modules/printf-posix: New file.
4781         * lib/printf.c: New file.
4782         * m4/printf-posix-rpl.m4: New file.
4783         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
4784         REPLACE_PRINTF.
4785         * lib/stdio_.h (printf): New declaration.
4786         (format, __format__, ____printf____, ____scanf____, ____strftime____,
4787         ____strfmon____): New macros.
4788         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
4789         REPLACE_PRINTF.
4790
4791 2007-03-09  Bruno Haible  <bruno@clisp.org>
4792
4793         * tests/test-vasnprintf-posix2.sh: New file.
4794         * tests/test-vasnprintf-posix2.c: New file.
4795         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
4796         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
4797         (Makefile.am): Activate test-vasnprintf-posix2.sh.
4798
4799         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
4800         a locale dependent decimal point, rather than always '.'.
4801
4802 2007-03-09  Eric Blake  <ebb9@byu.net>
4803
4804         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
4805         spite of platforms like Tandem/NSK that define it to -1.
4806
4807 2007-03-08  Bruno Haible  <bruno@clisp.org>
4808
4809         * modules/vprintf-posix-tests: New file.
4810         * tests/test-vprintf-posix.sh: New file.
4811         * tests/test-vprintf-posix.c: New file.
4812         * tests/test-printf-posix.h: New file.
4813
4814         * modules/vprintf-posix: New file.
4815         * lib/vprintf.c: New file.
4816         * m4/vprintf-posix.m4: New file.
4817         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
4818         REPLACE_VPRINTF.
4819         * lib/stdio_.h (vprintf): New declaration.
4820         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
4821         REPLACE_VPRINTF.
4822
4823 2007-03-08  Bruno Haible  <bruno@clisp.org>
4824
4825         * modules/fprintf-posix-tests: New file.
4826         * tests/test-fprintf-posix.sh: New file.
4827         * tests/test-fprintf-posix.c: New file.
4828
4829         * modules/fprintf-posix: New file.
4830         * lib/fprintf.c: New file.
4831         * m4/fprintf-posix.m4: New file.
4832         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
4833         REPLACE_FPRINTF.
4834         * lib/stdio_.h (fprintf): New declaration.
4835         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
4836         REPLACE_FPRINTF.
4837
4838 2007-03-08  Bruno Haible  <bruno@clisp.org>
4839
4840         * modules/vfprintf-posix-tests: New file.
4841         * tests/test-vfprintf-posix.sh: New file.
4842         * tests/test-vfprintf-posix.c: New file.
4843         * tests/test-fprintf-posix.h: New file.
4844         * tests/test-fprintf-posix.out: New file.
4845
4846         * modules/vfprintf-posix: New file.
4847         * lib/vfprintf.c: New file.
4848         * m4/vfprintf-posix.m4: New file.
4849         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
4850         REPLACE_VFPRINTF.
4851         * lib/stdio_.h (vfprintf): New declaration.
4852         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
4853         REPLACE_VFPRINTF.
4854
4855 2007-03-08  Bruno Haible  <bruno@clisp.org>
4856
4857         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
4858
4859 2007-03-08  Bruno Haible  <bruno@clisp.org>
4860
4861         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
4862         instead of 'expr' invocations.
4863         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
4864         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
4865         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
4866         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
4867         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
4868         Suggested by Paul Eggert.
4869
4870 2007-03-08  Bruno Haible  <bruno@clisp.org>
4871
4872         * modules/fseterr-tests: New file.
4873         * tests/test-fseterr.c: New file.
4874
4875         * modules/fseterr: New file.
4876         * lib/fseterr.h: New file.
4877         * lib/fseterr.c: New file.
4878
4879 2007-03-08  Bruno Haible  <bruno@clisp.org>
4880
4881         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
4882         * lib/getopt_.h: Likewise.
4883         * lib/mbswidth.h: Likewise.
4884         * lib/setenv.h: Likewise.
4885         * lib/vasnprintf.h: Likewise.
4886         * lib/vasprintf.h: Likewise.
4887         * lib/verror.h: Likewise.
4888         * lib/xsetenv.h: Likewise.
4889         * lib/xvasprintf.h: Likewise.
4890
4891 2007-03-08  Jim Meyering  <jim@meyering.net>
4892
4893         * users.txt: Add parted.
4894
4895         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
4896
4897 2007-03-07  Bruno Haible  <bruno@clisp.org>
4898
4899         * m4/printf.m4: Make the shell script snippets copy&pastable.
4900
4901 2007-03-02  Bruno Haible  <bruno@clisp.org>
4902
4903         * lib/netinet_in_.h: New file.
4904         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
4905         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
4906         * modules/netinet_in (Files): Add lib/netinet_in_.h.
4907         (Depends-on): Add absolute-header.
4908         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
4909         into netinet/in.h.
4910
4911 2007-03-03  Bruno Haible  <bruno@clisp.org>
4912
4913         * lib/sys_select_.h: New file.
4914         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
4915         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
4916         * modules/sys_select (Files): Add lib/sys_select_.h.
4917         (Depends-on): Add absolute-header.
4918         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
4919         into sys/select.h.
4920
4921 2007-03-02  Bruno Haible  <bruno@clisp.org>
4922
4923         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
4924         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
4925         values.
4926         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
4927         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
4928         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
4929         * modules/sys_socket (Depends-on): Add absolute-header.
4930         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
4931         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
4932         (Include): Remove requirement of inclusion of <sys/types.h>.
4933
4934 2007-03-02  Bruno Haible  <bruno@clisp.org>
4935
4936         * lib/byteswap_.h (bswap_32): Fix formula.
4937
4938 2007-03-06  Bruno Haible  <bruno@clisp.org>
4939
4940         * modules/sprintf-posix-tests: New file.
4941         * tests/test-sprintf-posix.c: New file.
4942
4943         * modules/sprintf-posix: New file.
4944         * lib/sprintf.c: New file.
4945         * m4/sprintf-posix.m4: New file.
4946         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
4947         REPLACE_SPRINTF.
4948         * lib/stdio_.h (sprintf): New declaration.
4949         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
4950         REPLACE_SPRINTF.
4951
4952 2007-03-06  Bruno Haible  <bruno@clisp.org>
4953
4954         * modules/vsprintf-posix-tests: New file.
4955         * tests/test-vsprintf-posix.c: New file.
4956         * tests/test-sprintf-posix.h: New file.
4957
4958         * modules/vsprintf-posix: New file.
4959         * lib/vsprintf.c: New file.
4960         * m4/vsprintf-posix.m4: New file.
4961         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
4962         REPLACE_VSPRINTF.
4963         * lib/stdio_.h (vsprintf): New declaration.
4964         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
4965         REPLACE_VSPRINTF.
4966
4967 2007-03-06  Bruno Haible  <bruno@clisp.org>
4968
4969         * modules/vsnprintf (Depend-on): Remove minmax.
4970
4971 2007-03-06  Bruno Haible  <bruno@clisp.org>
4972
4973         * modules/snprintf-posix-tests: New file.
4974         * tests/test-snprintf-posix.c: New file.
4975
4976         * modules/snprintf-posix: New file.
4977         * m4/snprintf-posix.m4: New file.
4978         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
4979         gl_FUNC_SNPRINTF.
4980         (gl_FUNC_SNPRINTF): Invoke it.
4981         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
4982         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
4983         is set.
4984         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
4985
4986 2007-03-06  Bruno Haible  <bruno@clisp.org>
4987
4988         * modules/vsnprintf-posix-tests: New file.
4989         * tests/test-vsnprintf-posix.c: New file.
4990         * tests/test-snprintf-posix.h: New file.
4991
4992         * modules/vsnprintf-posix: New file.
4993         * m4/vsnprintf-posix.m4: New file.
4994         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
4995         gl_FUNC_VSNPRINTF.
4996         (gl_FUNC_VSNPRINTF): Invoke it.
4997         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
4998         * lib/stdio_.h (vsnprintf): Define as a replacement if
4999         REPLACE_VSNPRINTF is set.
5000         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
5001
5002 2007-03-06  Bruno Haible  <bruno@clisp.org>
5003
5004         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
5005         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
5006
5007 2007-03-06  Bruno Haible  <bruno@clisp.org>
5008
5009         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
5010         (asinl): Declare also if HAVE_DECL_ASINL is set.
5011         (atanl): Declare also if HAVE_DECL_ATANL is set.
5012         (ceill): Declare also if HAVE_DECL_CEILL is set.
5013         (cosl): Declare also if HAVE_DECL_COSL is set.
5014         (expl): Declare also if HAVE_DECL_EXPL is set.
5015         (floorl): Declare also if HAVE_DECL_FLOORL is set.
5016         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
5017         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
5018         (logl): Declare also if HAVE_DECL_LOGL is set.
5019         (sinl): Declare also if HAVE_DECL_SINL is set.
5020         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
5021         (tanl): Declare also if HAVE_DECL_TANL is set.
5022         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
5023         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
5024         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
5025         declaration of frexpl, ldexpl.
5026         * modules/printf-frexpl (Depends-on): Add math.
5027         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
5028
5029 2007-03-05  Bruno Haible  <bruno@clisp.org>
5030
5031         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
5032         frexpl and ldexpl are declared.
5033         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
5034
5035 2007-03-05  Bruno Haible  <bruno@clisp.org>
5036
5037         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
5038         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
5039
5040 2007-03-05  Bruno Haible  <bruno@clisp.org>
5041
5042         * lib/stdio_.h: Include <stddef.h>.
5043
5044 2007-03-05  Bruno Haible  <bruno@clisp.org>
5045
5046         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
5047
5048 2007-03-05  Bruno Haible  <bruno@clisp.org>
5049
5050         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
5051         NetBSD 4, from Ralf Wildenhues.
5052
5053 2007-03-04  Bruno Haible  <bruno@clisp.org>
5054
5055         * lib/vasprintf.h: Update #if logic for the case when the functions
5056         exist but are overridden.
5057
5058 2007-03-04  Bruno Haible  <bruno@clisp.org>
5059
5060         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
5061         implementations: glibc-2.4 and MacOS X 10.3.
5062         * tests/test-vasnprintf-posix.c (test_function): Test also the case
5063         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
5064         * tests/test-vasprintf-posix.c (test_function): Likewise.
5065
5066 2007-03-04  Bruno Haible  <bruno@clisp.org>
5067
5068         * modules/vasprintf-posix-tests: New file.
5069         * tests/test-vasprintf-posix.c: New file.
5070
5071         * modules/vasprintf-posix: New file.
5072         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
5073         defined.
5074         * m4/vasprintf-posix.m4: New file.
5075         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
5076         gl_FUNC_VASPRINTF.
5077         (gl_FUNC_VASPRINTF): Invoke it.
5078         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
5079         here.
5080         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
5081
5082 2007-03-04  Bruno Haible  <bruno@clisp.org>
5083
5084         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
5085         REPLACE_GETTIMEOFDAY.
5086         * modules/sys_time (Makefile.am): Likewise.
5087         * m4/sys_time_h.m4: Likewise.
5088         * m4/gettimeofday.m4: Likewise.
5089
5090 2007-03-04  Bruno Haible  <bruno@clisp.org>
5091
5092         * modules/vasnprintf-posix-tests: New file.
5093         * tests/test-vasnprintf-posix.c: New file.
5094
5095         * modules/vasnprintf-posix: New file.
5096         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
5097         printf-frexpl.h.
5098         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
5099         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
5100         REPLACE_VASNPRINTF is defined.
5101         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
5102         gl_FUNC_VASNPRINTF.
5103         (gl_FUNC_VASNPRINTF): Invoke it.
5104         * m4/vasnprintf-posix.m4: New file.
5105         * m4/printf.m4: New file.
5106
5107 2007-03-04  Bruno Haible  <bruno@clisp.org>
5108
5109         Compile progreloc.c only if --enable-relocatable is specified.
5110         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
5111         if --enable-relocatable was specified.
5112         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
5113         lib_SOURCES.
5114
5115 2007-03-04  Jim Meyering  <jim@meyering.net>
5116
5117         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
5118         Use it consistently, rather than enumerating errno constants.
5119
5120 2007-03-04  Bruno Haible  <bruno@clisp.org>
5121
5122         * modules/xvasprintf-tests: New file.
5123         * tests/test-xvasprintf.c: New file.
5124
5125         * modules/vasprintf-tests: New file.
5126         * tests/test-vasprintf.c: New file.
5127
5128         * modules/vasnprintf-tests: New file.
5129         * tests/test-vasnprintf.c: New file.
5130
5131         * modules/vsnprintf-tests: New file.
5132         * tests/test-vsnprintf.c: New file.
5133
5134         * modules/snprintf-tests: New file.
5135         * tests/test-snprintf.c: New file.
5136
5137 2007-03-04  Bruno Haible  <bruno@clisp.org>
5138
5139         Compile relocatable.c only if --enable-relocatable is specified.
5140         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
5141         gl_RELOCATABLE_LIBRARY.
5142         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
5143         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
5144         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
5145         gl_RELOCATABLE_LIBRARY.
5146         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
5147         (Makefile.am): Remove lib_SOURCES.
5148         * modules/relocatable-lib-lgpl (configure.ac): Invoke
5149         gl_RELOCATABLE_LIBRARY.
5150         (Makefile.am): Remove lib_SOURCES.
5151         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
5152         always.
5153         * modules/relocatable-prog-wrapper (configure.ac): Invoke
5154         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
5155
5156 2007-03-04  Bruno Haible  <bruno@clisp.org>
5157
5158         * modules/argmatch-tests: New file.
5159         * tests/test-argmatch.c: New file.
5160
5161         * tests/test-allocsa.c (main): Halve the number of loop runs.
5162
5163         * modules/alloca-opt-tests: New file.
5164         * tests/test-alloca-opt.c: New file.
5165
5166 2007-03-04  Jim Meyering  <jim@meyering.net>
5167
5168         Work around difference between Linux ACLs and Solaris 10 ZFS.
5169         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
5170         for EINVAL.
5171
5172 2007-03-03  Bruno Haible  <bruno@clisp.org>
5173
5174         * modules/relocatable-prog (Depends-on): Add back progreloc's
5175         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
5176
5177 2007-03-03  Bruno Haible  <bruno@clisp.org>
5178
5179         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
5180         * modules/relocatable-lib: New file.
5181
5182 2007-03-03  Bruno Haible  <bruno@clisp.org>
5183
5184         * modules/relocatable-prog: Renamed from modules/relocatable.
5185         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
5186
5187 2007-03-03  Bruno Haible  <bruno@clisp.org>
5188
5189         * modules/relocatable-script (Files): Add doc/relocatable.texi,
5190         m4/relocatable-lib.m4.
5191         (Depends-on): Remove 'relocatable'.
5192         (configure.ac): Add gl_RELOCATABLE_NOP.
5193
5194 2007-03-03  Bruno Haible  <bruno@clisp.org>
5195
5196         * modules/relocatable-prog-wrapper: New file.
5197         * modules/relocatable (Depends-on): Add it. Remove all other
5198         dependencies except progname.
5199         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
5200
5201         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
5202         (gl_FUNC_STRERROR): Nop.
5203         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
5204
5205         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
5206         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
5207
5208         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
5209         (gl_FUNC_READLINK): Update.
5210
5211         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
5212
5213 2007-03-03  Bruno Haible  <bruno@clisp.org>
5214
5215         * lib/xreadlink.c: Include <unistd.h> unconditionally.
5216         * modules/xreadlink (Depends-on): Add unistd.
5217         * modules/xreadlink-with-size (Depends-on): Likewise.
5218
5219 2007-03-03  Bruno Haible  <bruno@clisp.org>
5220
5221         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
5222         extracted from gt_FUNC_SETENV.
5223         (gt_FUNC_SETENV): Remove macro.
5224         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
5225         remove gt_FUNC_SETENV.
5226
5227 2007-03-03  Bruno Haible  <bruno@clisp.org>
5228
5229         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
5230         ENABLE_RELOCATABLE here.
5231         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
5232
5233 2007-03-03  Bruno Haible  <bruno@clisp.org>
5234
5235         * modules/rbtreehash-list-tests (Depends-on): Add progname.
5236         * tests/test-rbtreehash_list.c: Include progname.h.
5237         (main): Call set_program_name.
5238
5239         * modules/rbtree-oset-tests (Depends-on): Add progname.
5240         * tests/test-rbtree_oset.c: Include progname.h.
5241         (main): Call set_program_name.
5242
5243         * modules/rbtree-list-tests (Depends-on): Add progname.
5244         * tests/test-rbtree_list.c: Include progname.h.
5245         (main): Call set_program_name.
5246
5247         * modules/linked-list-tests (Depends-on): Add progname.
5248         * tests/test-linked_list.c: Include progname.h.
5249         (main): Call set_program_name.
5250
5251 2007-03-03  Bruno Haible  <bruno@clisp.org>
5252
5253         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
5254         All uses of __restrict changed to _Restrict_.
5255         * lib/glob_.h (__restrict): Remove macro.
5256
5257 2007-03-02  Bruno Haible  <bruno@clisp.org>
5258
5259         * modules/gettext (configure.ac): Require gettext infrastructure
5260         from version 0.16.1.
5261
5262 2007-03-02  Bruno Haible  <bruno@clisp.org>
5263
5264         * modules/linkedhash-list-tests (Depends-on): Add progname.
5265         * tests/test-linkedhash_list.c: Include progname.h.
5266         (main): Call set_program_name.
5267
5268         * modules/carray-list-tests (Depends-on): Add progname.
5269         * tests/test-carray_list.c: Include progname.h.
5270         (main): Call set_program_name.
5271
5272         * modules/avltreehash-list-tests (Depends-on): Add progname.
5273         * tests/test-avltreehash_list.c: Include progname.h.
5274         (main): Call set_program_name.
5275
5276         * modules/avltree-oset-tests (Depends-on): Add progname.
5277         * tests/test-avltree_oset.c: Include progname.h.
5278         (main): Call set_program_name.
5279
5280         * modules/avltree-list-tests (Depends-on): Add progname.
5281         * tests/test-avltree_list.c: Include progname.h.
5282         (main): Call set_program_name.
5283
5284         * modules/array-oset-tests (Depends-on): Add progname.
5285         * tests/test-array_oset.c: Include progname.h.
5286         (main): Call set_program_name.
5287
5288         * modules/array-list-tests (Depends-on): Add progname.
5289         * tests/test-array_list.c: Include progname.h.
5290         (main): Call set_program_name.
5291
5292         * modules/argp-tests (Depends-on): Add progname.
5293         * tests/test-argp.c: Include argp.h first. Include progname.h.
5294         (main): Call set_program_name.
5295
5296 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
5297
5298         * doc/gnulib-tool.texi (Initial import): Reword description of
5299         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
5300         limited effect even if defined after the first system include.
5301
5302 2007-03-01  Bruno Haible  <bruno@clisp.org>
5303
5304         * build-aux/config.libpath: Update to libtool-1.5.22.
5305         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
5306
5307 2007-03-01  Bruno Haible  <bruno@clisp.org>
5308
5309         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
5310         foo_CFLAGS.
5311         Reported by Ralf Wildenhues.
5312
5313 2007-03-01  Bruno Haible  <bruno@clisp.org>
5314
5315         * build-aux/install-reloc: Remove object files left over by some
5316         compilers.
5317         Reported by Ralf Wildenhues.
5318
5319 2007-03-01  Bruno Haible  <bruno@clisp.org>
5320
5321         * build-aux/install-reloc: Break long lines.
5322
5323 2007-03-01  Bruno Haible  <bruno@clisp.org>
5324
5325         * doc/relocatable.texi: Document that it may not work on OpenBSD.
5326         Reported by Ralf Wildenhues.
5327
5328 2007-03-01  Bruno Haible  <bruno@clisp.org>
5329
5330         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
5331         include ordering constraints.
5332
5333 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
5334
5335         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
5336         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
5337         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
5338         as another example.
5339         * lib/time_.h: Fix misspelling.
5340         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
5341         Require gl_HEADER_TIME_H_DEFAULTS.
5342         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
5343         * m4/time_r.m4 (gl_TIME_R): Likewise.
5344         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
5345
5346 2007-03-01  Bruno Haible  <bruno@clisp.org>
5347
5348         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
5349         * m4/utimens.m4 (gl_UTIMENS): Likewise.
5350
5351 2007-03-01  Jim Meyering  <jim@meyering.net>
5352
5353         * modules/xreadlink (Maintainer): Add my name.
5354         * modules/xreadlink-with-size (Depends-on): Alphabetize.
5355
5356 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
5357             Bruno Haible  <bruno@clisp.org>
5358
5359         * build-aux/install-reloc: Compile also c-ctype.c.
5360         * build-aux/relocatable.sh.in: New file.
5361         * doc/relocatable.texi: New file.
5362         * doc/relocatable-maint.texi: New file.
5363         * doc/gnulib.texi: Include relocatable-maint.texi.
5364         * lib/progreloc.c: Include unistd.h unconditionally.
5365         * lib/relocwrapper.c: Include unistd.h unconditionally.
5366         Include c-ctype.h.
5367         (add_dotbin): Use c_tolower.
5368         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
5369         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
5370         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
5371         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
5372         to m4/relocatable-lib.m4.
5373         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
5374         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
5375         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
5376         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
5377         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
5378         * modules/relocatable: New file.
5379         * modules/relocatable-lib: New file.
5380         * modules/relocatable-script: New file.
5381
5382 2007-02-28  Bruno Haible  <bruno@clisp.org>
5383
5384         Import --enable-relocatable infrastructure.
5385         * build-aux/config.libpath: New file, from GNU gettext.
5386         * build-aux/install-reloc: New file, from GNU gettext.
5387         * build-aux/reloc-ldflags: New file, from GNU gettext.
5388         * lib/relocatable.h: New file, from GNU gettext.
5389         * lib/relocatable.c: New file, from GNU gettext.
5390         * lib/relocwrapper.c: New file, from GNU gettext.
5391         * m4/relocatable.m4: New file, from GNU gettext.
5392
5393 2007-02-28  Bruno Haible  <bruno@clisp.org>
5394
5395         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
5396
5397         * modules/xreadlink: New file, from GNU gettext with modifications.
5398         * lib/xreadlink.c: New file, from GNU gettext.
5399         * lib/xreadlink.h: Add comments.
5400         (xreadlink): New declaration.
5401
5402         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
5403         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
5404         lib/xreadlink-with-size.c.
5405         (configure.ac): Remove gl_XREADLINK invocation.
5406         (Makefile.am): Augment lib_SOURCES.
5407         * m4/xreadlink.m4: Remove file.
5408         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
5409         (xreadlink_with_size): Renamed from xreadink.
5410         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
5411         * modules/canonicalize (Depends-on): Replace xreadlink with
5412         xreadlink-with-size.
5413         * lib/canonicalize.c (canonicalize_filename_mode): Update.
5414
5415 2007-02-25  Jim Meyering  <jim@meyering.net>
5416
5417         * build-aux/announce-gen: When complaining about excess arguments,
5418         list them.
5419
5420 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
5421
5422         * README: Document signed integer overflow situation more
5423         accurately.
5424
5425 2007-02-25  Bruno Haible  <bruno@clisp.org>
5426
5427         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
5428         'a' or 'A' conversion.
5429
5430 2007-02-25  Bruno Haible  <bruno@clisp.org>
5431
5432         * modules/filename: Renamed from modules/pathname.
5433         (Files): Replace lib/pathname.h with lib/filename.h. Replace
5434         lib/concatpath.c with lib/concat-filename.c.
5435         (Makefile.am): Update.
5436         (Include): Replace pathname.h with filename.h.
5437         * lib/filename.h: Renamed from lib/pathname.h.
5438         (concatenated_filename): Renamed from concatenated_pathname.
5439         * lib/concat-filename.c: Renamed from lib/concatpath.c.
5440         (concatenated_filename): Renamed from concatenated_pathname.
5441         * lib/findprog.c: Include filename.h instead of pathname.h.
5442         (find_in_path): Update.
5443         * lib/javacomp.c: Include filename.h instead of pathname.h.
5444         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
5445         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
5446         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
5447         is_oldgcj_14_13_usable, is_javac_usable): Update.
5448         * lib/javaexec.c: Include filename.h instead of pathname.h.
5449         (execute_java_class): Update.
5450         * modules/findprog: Update.
5451         * modules/javacomp: Update.
5452         * modules/javaexec: Update.
5453         * MODULES.html.sh (File system functions): Add 'filename', remove
5454         'pathname'.
5455
5456 2007-02-25  Bruno Haible  <bruno@clisp.org>
5457
5458         * modules/printf-frexpl-tests: New file.
5459         * tests/test-printf-frexpl.c: New file.
5460
5461         * modules/printf-frexpl: New file.
5462         * lib/printf-frexpl.h: New file.
5463         * lib/printf-frexpl.c: New file.
5464         * m4/printf-frexpl.m4: New file.
5465
5466 2007-02-25  Bruno Haible  <bruno@clisp.org>
5467
5468         * modules/printf-frexp-tests: New file.
5469         * tests/test-printf-frexp.c: New file.
5470
5471         * modules/printf-frexp: New file.
5472         * lib/printf-frexp.h: New file.
5473         * lib/printf-frexp.c: New file.
5474         * m4/printf-frexp.m4: New file.
5475
5476 2007-02-25  Bruno Haible  <bruno@clisp.org>
5477
5478         Assume automake >= 1.10 for the tests.
5479         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
5480         * modules/arctwo-tests: Likewise.
5481         * modules/argp-tests: Likewise.
5482         * modules/avltree-list-tests: Likewise.
5483         * modules/avltree-oset-tests: Likewise.
5484         * modules/avltreehash-list-tests: Likewise.
5485         * modules/carray-list-tests: Likewise.
5486         * modules/crc-tests: Likewise.
5487         * modules/des-tests: Likewise.
5488         * modules/gc-arcfour-tests: Likewise.
5489         * modules/gc-arctwo-tests: Likewise.
5490         * modules/gc-des-tests: Likewise.
5491         * modules/gc-hmac-md5-tests: Likewise.
5492         * modules/gc-hmac-sha1-tests: Likewise.
5493         * modules/gc-md2-tests: Likewise.
5494         * modules/gc-md4-tests: Likewise.
5495         * modules/gc-md5-tests: Likewise.
5496         * modules/gc-pbkdf2-sha1-tests: Likewise.
5497         * modules/gc-rijndael-tests: Likewise.
5498         * modules/gc-sha1-tests: Likewise.
5499         * modules/gc-tests: Likewise.
5500         * modules/getaddrinfo-tests: Likewise.
5501         * modules/hmac-md5-tests: Likewise.
5502         * modules/hmac-sha1-tests: Likewise.
5503         * modules/linked-list-tests: Likewise.
5504         * modules/linkedhash-list-tests: Likewise.
5505         * modules/lock-tests: Likewise.
5506         * modules/md2-tests: Likewise.
5507         * modules/md4-tests: Likewise.
5508         * modules/md5-tests: Likewise.
5509         * modules/rbtree-list-tests: Likewise.
5510         * modules/rbtree-oset-tests: Likewise.
5511         * modules/rbtreehash-list-tests: Likewise.
5512         * modules/read-file-tests: Likewise.
5513         * modules/rijndael-tests: Likewise.
5514         * modules/stdint-tests: Likewise.
5515         * modules/tls-tests: Likewise.
5516
5517 2007-02-24  Bruno Haible  <bruno@clisp.org>
5518
5519         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
5520         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
5521         function; instead check whether isnan with a double argument links.
5522         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
5523         function; instead check whether isnan with a 'long double' argument
5524         links.
5525         Reported by Eric Blake <ebb9@byu.net>.
5526
5527 2007-02-24  Bruno Haible  <bruno@clisp.org>
5528
5529         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
5530         defined.
5531         * lib/isnanl.c: Remove all code. Just include isnan.c.
5532         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
5533
5534 2007-02-25  Jim Meyering  <jim@meyering.net>
5535
5536         Avoid conflicting types for 'unsetenv' on FreeBSD.
5537         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
5538         conflicting with FreeBSD's (5.0 and 6.1) function declaration
5539         in stdlib.h.
5540
5541 2007-02-24  Bruno Haible  <bruno@clisp.org>
5542
5543         * modules/isnanl-nolibm-tests: New file.
5544         * tests/test-isnanl.c: New file.
5545
5546         * modules/isnanl-nolibm: New file.
5547         * lib/isnanl.h: New file.
5548         * lib/isnanl.c: New file.
5549         * m4/isnanl.m4: New file.
5550
5551 2007-02-24  Bruno Haible  <bruno@clisp.org>
5552
5553         * modules/isnan-nolibm-tests: New file.
5554         * tests/test-isnan.c: New file.
5555
5556         * modules/isnan-nolibm: New file.
5557         * lib/isnan.h: New file.
5558         * lib/isnan.c: New file.
5559         * m4/isnan.m4: New file.
5560
5561 2007-02-24  Bruno Haible  <bruno@clisp.org>
5562
5563         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
5564         assume that an exponent fits in 20 bits.
5565
5566 2007-02-24  Jim Meyering  <jim@meyering.net>
5567
5568         * m4/regex.m4: Update the description of the configure-time option,
5569         --without-included-regex, to state accurately what the defaults are,
5570         and perhaps to give people an idea why using this option is risky.
5571
5572 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
5573
5574         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
5575         loops on small arguments.  This attempts to avoid the problem
5576         Bruno Haible reported for AIX 4.3.2 in
5577         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
5578
5579 2007-02-23  Bruno Haible  <bruno@clisp.org>
5580
5581         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
5582         Needed for help2man.
5583
5584 2007-02-23  Karl Berry  <karl@gnu.org>
5585
5586         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
5587         exists, foo.h should be cvs-ignored, not committed.
5588
5589 2007-02-23  Eric Blake  <ebb9@byu.net>
5590
5591         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
5592         * lib/stat-time.h (includes): Likewise.
5593         * lib/utimecmp.c (includes): Likewise.
5594         * lib/utimens.h (includes): Likewise.
5595         * lib/getdate.y (includes): Also include "timespec.h" for use
5596         internal to the module.
5597         * modules/utimens (Depends-on): Revert yesterday's patch.
5598         * modules/nanosleep (Depends-on): Add missing dependency.
5599
5600 2007-02-22  Bruno Haible  <bruno@clisp.org>
5601
5602         * lib/glob.c: Don't include getlogin_r.h.
5603
5604 2007-02-22  Jim Meyering  <jim@meyering.net>
5605
5606         * modules/utimens (Depends-on): Add timespec, required for
5607         utimens.h's inclusion of timespec.h.
5608
5609 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
5610
5611         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
5612         long unreadable paths in GNU/Linux.  Problem reported by Andreas
5613         Schwab in
5614         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
5615         I'll try to think of a better way to fix the Solaris problem.
5616
5617         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
5618         like glibc; on Solaris 10, it fails with errno == EINVAL.
5619         POSIX says the behavior is unspecified if the first argument is NULL,
5620         so play it safe and never pass NULL to the system getcwd.
5621
5622 2007-02-21  Jim Meyering  <jim@meyering.net>
5623
5624         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
5625         of gettimeofday.  It would conflict with the one now always
5626         provided via sys_time_.h.  Reported by Matthew Woehlke, as
5627         an IRIX 6.5 build failure.
5628
5629 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
5630
5631         Minor fixups to port to Solaris 10 with Sun C 5.8.
5632         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
5633         * modules/getcwd (Depends-on): Add dirfd.
5634         * lib/putenv.c (putenv): #undef it.
5635         (rpl_putenv): New decl.
5636         (malloc, free): Include <stdlib.h> rather than prototyping separately.
5637
5638 2007-02-20  Bruno Haible  <bruno@clisp.org>
5639
5640         * modules/stdio-tests: New file.
5641         * tests/test-stdio.c: New file.
5642
5643         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
5644         (Depends-on): Add stdio.
5645         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
5646         (Include): Use <stdio.h> instead of vsnprintf.h.
5647         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
5648         HAVE_DECL_VSNPRINTF.
5649         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
5650
5651         * modules/snprintf (Files): Remove lib/snprintf.h.
5652         (Depends-on): Add stdio.
5653         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
5654         (Include): Use <stdio.h> instead of snprintf.h.
5655         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
5656         HAVE_DECL_SNPRINTF.
5657         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
5658         * lib/getaddrinfo.c: Likewise.
5659
5660         * modules/stdio: New file.
5661         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
5662         * lib/snprintf.h: Remove file.
5663         * lib/vsnprintf.h: Remove file.
5664         * lib/.cppi-disable: Remove snprintf.h.
5665         * m4/stdio_h.m4: New file.
5666         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
5667
5668 2007-02-20  Jim Meyering  <jim@meyering.net>
5669
5670         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
5671         used by e.g., mingw.  From Bruno Haible.
5672
5673 2007-02-19  Bruno Haible  <bruno@clisp.org>
5674
5675         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
5676         warnings.
5677         Reported by Ben Pfaff <blp@cs.stanford.edu>.
5678
5679 2007-02-19  Bruno Haible  <bruno@clisp.org>
5680
5681         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
5682         from mingw users.
5683
5684 2007-02-19  Bruno Haible  <bruno@clisp.org>
5685
5686         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
5687         warnings.
5688         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
5689
5690 2007-02-19  Jim Meyering  <jim@meyering.net>
5691
5692         Don't use FD after a successful "fdopendir (fd)".
5693         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
5694         Reset it by calling dirfd on the just-obtained DIR*.
5695
5696         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
5697         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
5698
5699 2007-02-18  Bruno Haible  <bruno@clisp.org>
5700
5701         * lib/readlink.c: Include <unistd.h>.
5702         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
5703         HAVE_READLINK.
5704         * modules/readlink (Depends-on): Add unistd.
5705         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5706         (Include): Add <unistd.h>.
5707
5708         * lib/getlogin_r.h: Remove file.
5709         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
5710         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
5711         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
5712         HAVE_DECL_GETLOGIN_R.
5713         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
5714         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5715         (Include): Use <unistd.h> instead of getlogin_r.h.
5716
5717         * lib/getcwd.h: Remove file.
5718         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
5719         * lib/xgetcwd.c: Likewise.
5720         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
5721         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
5722         * modules/getcwd (Files): Remove lib/getcwd.h.
5723         (Depends-on): Add unistd.
5724         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5725         (Include): Use <unistd.h> instad of getcwd.h.
5726
5727         * lib/ftruncate.c: Include <unistd.h> first.
5728         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
5729         Set HAVE_FTRUNCATE.
5730         * modules/ftruncate (Depends-on): Add unistd.
5731         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5732
5733         * lib/fchdir.c: Include <unistd.h> first.
5734         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
5735         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
5736         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
5737         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5738         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
5739
5740         * lib/dup2.c: Include <unistd.h> first.
5741         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
5742         HAVE_DUP2.
5743         * modules/dup2 (Depends-on): Add unistd.
5744         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5745
5746         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
5747         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
5748         REPLACE_CHOWN. Don't define chown as a macro here.
5749         * modules/chown (Depends-on): Add unistd.
5750         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5751
5752         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
5753         Add definition for GL_LINK_WARNING.
5754         (chown, dup2): New declarations.
5755         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
5756         link warning.
5757         (ftruncate): New declaration.
5758         (getcwd): New declaration, taken from old getcwd.h.
5759         (getlogin_r): New declaration, taken from old getlogin_r.h.
5760         (readlink): New declaration.
5761         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
5762         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
5763         (gl_PREREQ_UNISTD): Remove macro.
5764         (gl_UNISTD_MODULE_INDICATOR): New macro.
5765         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
5766         many new variables. Don't set UNISTD_H.
5767         * modules/unistd (Description): Change.
5768         (Depends-on): Add link-warning.
5769         (configure.ac): Update.
5770         (Makefile.am): Create unistd.h always. Substitute many new variables
5771         into it.
5772
5773 2007-02-18  Bruno Haible  <bruno@clisp.org>
5774
5775         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
5776         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
5777         HAVE_GETSUBOPT.
5778         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
5779         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
5780         * lib/getsubopt.h: Remove file.
5781         * modules/getsubopt (Files): Remove lib/getsubopt.h.
5782         (Depends-on): Add stdlib.
5783         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5784         (Includes): Use <stdlib.h> instead of getsubopt.h.
5785         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
5786         Set HAVE_GETSUBOPT.
5787         * lib/getsubopt.c: Don't include getsubopt.h.
5788
5789 2007-02-18  Bruno Haible  <bruno@clisp.org>
5790
5791         * modules/fchdir (Depends-on): Add dup2.
5792
5793 2007-02-18  Bruno Haible  <bruno@clisp.org>
5794
5795         * lib/stdlib_.h: Handle glibc's special invocation convention
5796         specially.
5797
5798 2007-02-18  Bruno Haible  <bruno@clisp.org>
5799
5800         * modules/stdlib-tests: New file.
5801         * tests/test-stdlib.c: New file.
5802
5803         * modules/mkstemp (Files): Remove lib/mkstemp.h.
5804         (Depends-on): Add stdlib.
5805         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5806         (Includes): Use <stdlib.h> instead of mkstemp.h.
5807         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
5808         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
5809         * lib/mkstemp.c: Don't include mkstemp.h.
5810         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
5811         * lib/stdlib--.h: Don't include mkstemp.h.
5812
5813         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
5814         (Depends-on): Add stdlib.
5815         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5816         (Includes): Use <stdlib.h> instead of mkdtemp.h.
5817         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
5818         HAVE_MKDTEMP.
5819         * lib/mkdtemp.c: Don't include mkdtemp.h.
5820         * lib/clean-temp.c: Don't include mkdtemp.h.
5821
5822         * modules/exit (Files): Remove lib/exit.h.
5823         (Depends-on): Add stdlib.
5824         (Makefile.am): Remove lib_SOURCES.
5825         (Include): Use <stdlib.h> instead of exit.h.
5826         * lib/argmatch.c: Don't include exit.h.
5827         * lib/execute.c: Likewise.
5828         * lib/pagealign_alloc.c: Likewise.
5829         * lib/pipe.c: Likewise.
5830         * lib/wait-process.c: Likewise.
5831         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
5832         * lib/exitfail.c: Likewise.
5833         * lib/savewd.c: Likewise.
5834         * lib/xsetenv.c: Likewise.
5835
5836         * modules/stdlib: New file.
5837         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
5838         and extra comments about mkstemp().
5839         * lib/exit.h: Remove file.
5840         * lib/mkdtemp.h: Remove file.
5841         * lib/mkstemp.h: Remove file.
5842         * m4/stdlib_h.m4: New file.
5843         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
5844
5845 2007-02-18  Bruno Haible  <bruno@clisp.org>
5846
5847         * modules/math-tests: New file.
5848         * tests/test-math.c: New file.
5849
5850         * modules/math: New file.
5851         * modules/mathl (Files): Remove lib/mathl.h.
5852         (Depends-on): Add math.
5853         (Makefile.am): Don't mention mathl.h.
5854         (Include): Use <math.h> instead of mathl.h.
5855         * lib/math_.h: New file.
5856         * lib/mathl.h: Remove file.
5857         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
5858         mathl.h.
5859         * lib/asinl.c: Likewise.
5860         * lib/atanl.c: Likewise.
5861         * lib/ceill.c: Likewise.
5862         * lib/cosl.c: Likewise.
5863         * lib/expl.c: Likewise.
5864         * lib/floorl.c: Likewise.
5865         * lib/frexpl.c: Likewise.
5866         * lib/ldexpl.c: Likewise.
5867         * lib/logl.c: Likewise.
5868         * lib/sincosl.c: Likewise.
5869         * lib/sinl.c: Likewise.
5870         * lib/sqrtl.c: Likewise.
5871         * lib/tanl.c: Likewise.
5872         * lib/trigl.c: Likewise.
5873         * m4/math_h.m4: New file.
5874         * MODULES.html.sh (Mathematics): Add math.
5875
5876 2007-02-17  Bruno Haible  <bruno@clisp.org>
5877
5878         * modules/wctype-tests: New file.
5879         * tests/test-wctype.c: New file.
5880
5881         * modules/wchar-tests: New file.
5882         * tests/test-wchar.c: New file.
5883
5884         * modules/unistd-tests: New file.
5885         * tests/test-unistd.c: New file.
5886
5887         * modules/time-tests: New file.
5888         * tests/test-time.c: New file.
5889
5890         * modules/sysexits-tests: New file.
5891         * tests/test-sysexits.c: New file.
5892
5893         * modules/sys_time-tests: New file.
5894         * tests/test-sys_time.c: New file.
5895
5896         * modules/sys_stat-tests: New file.
5897         * tests/test-sys_stat.c: New file.
5898
5899         * modules/sys_socket-tests: New file.
5900         * tests/test-sys_socket.c: New file.
5901
5902         * modules/sys_select-tests: New file.
5903         * tests/test-sys_select.c: New file.
5904
5905         * modules/string-tests: New file.
5906         * tests/test-string.c: New file.
5907
5908         * modules/stdbool-tests: New file.
5909         * tests/test-stdbool.c: New file.
5910
5911         * modules/netinet_in-tests: New file.
5912         * tests/test-netinet_in.c: New file.
5913
5914         * modules/inttypes-tests: New file.
5915         * tests/test-inttypes.c: New file.
5916
5917         * modules/fcntl-tests: New file.
5918         * tests/test-fcntl.c: New file.
5919
5920         * modules/byteswap-tests: New file.
5921         * tests/test-byteswap.c: New file.
5922
5923         * modules/arpa_inet-tests: New file.
5924         * tests/test-arpa_inet.c: New file.
5925
5926 2007-02-17  Bruno Haible  <bruno@clisp.org>
5927
5928         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
5929         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
5930         if the corresponding module is not enabled. Emit link warnings if
5931         the function is used nevertheless.
5932         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
5933         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
5934         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
5935         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
5936         * modules/inttypes (Depends-on): Add link-warning.
5937         (Makefile.am): Copy the contents of build-aux/link-warning.h into
5938         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
5939         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
5940         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
5941         * modules/imaxdiv (configure.ac): Likewise.
5942         * modules/strtoimax (configure.ac): Likewise.
5943         * modules/strtoumax (configure.ac): Likewise.
5944
5945 2007-02-17  Bruno Haible  <bruno@clisp.org>
5946
5947         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
5948         gl_STRING_MODULE_INDICATOR_DEFAULTS.
5949         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
5950         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
5951
5952 2007-02-17  Bruno Haible  <bruno@clisp.org>
5953
5954         * modules/link-warning: New file.
5955         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
5956         * lib/string_.h (GL_LINK_WARNING): Remove definition.
5957         * modules/string (Depends-on): Add link-warning.
5958         (Makefile.am): Copy the contents of build-aux/link-warning.h into
5959         string.h.
5960         * MODULES.html.sh (Support for building libraries and executables): Add
5961         link-warning.
5962
5963 2007-02-17  Bruno Haible  <bruno@clisp.org>
5964
5965         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
5966         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
5967         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
5968         long lines.
5969
5970 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
5971             Bruno Haible  <bruno@clisp.org>
5972
5973         * modules/tmpfile: New file.
5974         * lib/tmpfile.c: New file.
5975         * m4/tmpfile.m4: New file.
5976         * MODULES.html.sh (func_all_modules): New section "Input/output".
5977
5978 2007-02-15  Bruno Haible  <bruno@clisp.org>
5979
5980         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
5981         (supports_delete_on_close): New function.
5982         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
5983
5984 2007-02-14  Bruno Haible  <bruno@clisp.org>
5985
5986         * modules/mbspcasecmp-tests: New file.
5987         * tests/test-mbspcasecmp.sh: New file.
5988         * tests/test-mbspcasecmp.c: New file.
5989
5990         New module mbspcasecmp.
5991         * modules/mbspcasecmp: New file.
5992         * lib/mbspcasecmp.c: New file.
5993         * lib/string_.h (strncasecmp): Change warning message.
5994         (mbspcasecmp): New declaration.
5995         * m4/mbspcasecmp.m4: New file.
5996         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
5997         GNULIB_MBSPCASECMP.
5998         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
5999         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
6000
6001 2007-02-14  Bruno Haible  <bruno@clisp.org>
6002
6003         * modules/mbsncasecmp-tests: New file.
6004         * tests/test-mbsncasecmp.sh: New file.
6005         * tests/test-mbsncasecmp.c: New file.
6006
6007         New module mbsncasecmp.
6008         * modules/mbsncasecmp: New file.
6009         * lib/mbsncasecmp.c: New file.
6010         * lib/string_.h (mbsncasecmp): New declaration.
6011         * m4/mbsncasecmp.m4: New file.
6012         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6013         GNULIB_MBSNCASECMP.
6014         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
6015         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
6016
6017 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
6018
6019         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
6020         Verify that it doesn't overlap with our flags.
6021         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
6022         do not have the desired effect in multibyte locales; instead, use
6023         mbscasecmp.
6024         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
6025         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
6026         we don't require GNU fnmatch ourselves (if our users require it, they
6027         should do so explicitly).
6028
6029         Fix regex code so it doesn't rely on strcasecmp.
6030         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
6031         Otherwise, include gnulib's langinfo.h.
6032         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
6033         undesirable behavior in non-C locales.  Instead, rely on localecharset.
6034         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
6035         * modules/regex (FILES): Remove m4/codeset.m4.
6036         (Depends-on): Add localcharset.  Remove strcase.
6037
6038 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6039
6040         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
6041         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
6042
6043 2007-02-13  Bruno Haible  <bruno@clisp.org>
6044
6045         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
6046         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
6047
6048 2007-02-12  Bruno Haible  <bruno@clisp.org>
6049
6050         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
6051         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
6052         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
6053         time warning rather than a link error.
6054
6055 2007-02-12  Bruno Haible  <bruno@clisp.org>
6056
6057         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
6058         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
6059         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
6060
6061 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
6062
6063         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
6064         args, not 2.
6065
6066 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
6067
6068         New module 'time', so that apps can include <time.h> as per
6069         POSIX and GNU instead of separate include files like time_r.h
6070         and timegm.h.  This implementation tries out a simpler approach
6071         for replacing decls in standard include files (as compared to
6072         the string module), somewhat as an experiment.
6073
6074         * config/srclist.txt: Comment out mktime.c for now.
6075         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
6076         since it doesn't apply any more.  Use generic wording instead.
6077         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
6078         'time'.
6079         * lib/time_.h, m4/time_h.m4, modules/time: New files.
6080         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
6081         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
6082         Don't include <sys/types.h>; no longer needed since we assume C89.
6083         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
6084         * lib/strftime.c: Likewise.
6085         * lib/time_r.c: Likewise.
6086         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
6087         * lib/nanosleep.c: Include <time.h> first, to check interface.
6088         * lib/strptime.c: Likewise.
6089         * lib/time_r.c: Likewise.
6090         * lib/timegm.c: Likewise.
6091         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
6092         needed.
6093         * lib/timegm.c: Don't include timegm.h; no longer needed.
6094         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
6095         time.h now handles any problems in that area.
6096         (struct timespec, nanosleep): Remove; time.h now arranges for these.
6097         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
6098         that time.h defines struct timespec.
6099         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
6100         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
6101         handles that.
6102         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
6103         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
6104         needed.  Set REPLACE_LOCALTIME.
6105         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
6106         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
6107         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
6108         nanosleep; time_h.m4 now does that.  Don't require
6109         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
6110         module handles this now.
6111         * modules/getdate (Depends-on): Remove timespec.  Add time.
6112         * modules/nanosleep (Depends-on): Likewise.
6113         * modules/stat-time (Depends-on): Likewise.
6114         * modules/nanosleep (Include): Include time.h, not timespec.h.
6115         * modules/strptime (Files): Remove lib/strptime.h.
6116         (Depends-on): Add extensions, time.
6117         (Include): Include time.h, not strptime.h.
6118         * modules/time_r (Files): Remove lib/time_r.h.
6119         (Depends-on): Add time.
6120         (Include): Include time.h, not time_r.h.
6121         * modules/timegm: Likewise.
6122         * modules/timespec (Description): Now does timespec-related decls
6123         of our own, instead of struct timespec itself.
6124         (Depends-on): Add time; remove extensions.
6125         (Maintainer): Add self.
6126         * modules/utimecmp (Depends-on): Add time; remove timespec.
6127         * modules/utimens (Depends-on): Likewise.
6128         * modules/xnanosleep (Depends-on): Likewise.
6129
6130 2007-02-11  Bruno Haible  <bruno@clisp.org>
6131
6132         * lib/c-strstr.c: Include allocsa.h.
6133         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
6134         * lib/c-strcasestr.c: Include allocsa.h.
6135         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
6136         * lib/strcasestr.c: Include allocsa.h.
6137         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
6138         * lib/mbsstr.c: Include allocsa.h.
6139         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
6140         allocsa/freesa instead of malloc/free.
6141         * lib/mbscasestr.c: Include allocsa.h.
6142         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
6143         allocsa/freesa instead of malloc/free.
6144         * modules/c-strstr (Depends-on): Add allocsa.
6145         * modules/c-strcasestr (Depends-on): Likewise.
6146         * modules/strcasestr (Depends-on): Likewise.
6147         * modules/mbsstr (Depends-on): Likewise.
6148         * modules/mbscasestr (Depends-on): Likewise.
6149
6150 2007-02-11  Bruno Haible  <bruno@clisp.org>
6151
6152         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
6153
6154         * modules/mbsspn-tests: New file.
6155         * tests/test-mbsspn.sh: New file.
6156         * tests/test-mbsspn.c: New file.
6157
6158 2007-02-11  Bruno Haible  <bruno@clisp.org>
6159
6160         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
6161
6162         * modules/mbspbrk-tests: New file.
6163         * tests/test-mbspbrk.sh: New file.
6164         * tests/test-mbspbrk.c: New file.
6165
6166 2007-02-11  Bruno Haible  <bruno@clisp.org>
6167
6168         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
6169         unneeded cast.
6170
6171         * modules/mbscspn-tests: New file.
6172         * tests/test-mbscspn.sh: New file.
6173         * tests/test-mbscspn.c: New file.
6174
6175 2007-02-11  Bruno Haible  <bruno@clisp.org>
6176
6177         * modules/mbscasecmp-tests: New file.
6178         * tests/test-mbscasecmp.sh: New file.
6179         * tests/test-mbscasecmp.c: New file.
6180
6181 2007-02-11  Bruno Haible  <bruno@clisp.org>
6182
6183         Ensure O(n) worst-case complexity of mbscasestr.
6184         * lib/mbscasestr.c: Include stdbool.h.
6185         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
6186         functions.
6187         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
6188         the bookkeeping indicates that it's worth it.
6189         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
6190
6191         * modules/mbscasestr-tests: New file.
6192         * tests/test-mbscasestr1.c: New file.
6193         * tests/test-mbscasestr2.sh: New file.
6194         * tests/test-mbscasestr2.c: New file.
6195         * tests/test-mbscasestr3.sh: New file.
6196         * tests/test-mbscasestr3.c: New file.
6197         * tests/test-mbscasestr4.sh: New file.
6198         * tests/test-mbscasestr4.c: New file.
6199         * m4/locale-tr.m4: New file.
6200
6201 2007-02-11  Bruno Haible  <bruno@clisp.org>
6202
6203         Ensure O(n) worst-case complexity of mbsstr.
6204         * lib/mbsstr.c: Include stdbool.h.
6205         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
6206         functions.
6207         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
6208         bookkeeping indicates that it's worth it.
6209         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
6210
6211         * modules/mbsstr-tests: New file.
6212         * tests/test-mbsstr1.c: New file.
6213         * tests/test-mbsstr2.sh: New file.
6214         * tests/test-mbsstr2.c: New file.
6215         * tests/test-mbsstr3.sh: New file.
6216         * tests/test-mbsstr3.c: New file.
6217         * m4/locale-fr.m4: New file.
6218
6219 2007-02-11  Bruno Haible  <bruno@clisp.org>
6220
6221         * lib/mbsrchr.c (mbsrchr): Fix bug.
6222
6223         * modules/mbsrchr-tests: New file.
6224         * tests/test-mbsrchr.sh: New file.
6225         * tests/test-mbsrchr.c: New file.
6226
6227 2007-02-11  Bruno Haible  <bruno@clisp.org>
6228
6229         * lib/mbschr.c (mbschr): Fix bug.
6230
6231         * modules/mbschr-tests: New file.
6232         * tests/test-mbschr.sh: New file.
6233         * tests/test-mbschr.c: New file.
6234         * m4/locale-zh.m4: New file.
6235
6236 2007-02-11  Bruno Haible  <bruno@clisp.org>
6237
6238         Support for copying multibyte string iterators.
6239         * lib/mbiter.h: Include <string.h>.
6240         (mbiter_multi_copy): New function.
6241         (mbi_copy): New macro.
6242         * lib/mbuiter.h: Include <string.h>.
6243         (mbuiter_multi_copy): New function.
6244         (mbui_copy): New macro.
6245
6246 2007-02-11  Bruno Haible  <bruno@clisp.org>
6247
6248         New module mbslen.
6249         * modules/mbslen: New file.
6250         * lib/mbslen.c: New file.
6251         * lib/string_.h (mbslen): New declaration.
6252         * m4/mbslen.m4: New file.
6253         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6254         GNULIB_MBSLEN.
6255         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
6256         * MODULES.html.sh (Internationalization functions): Add mbslen.
6257
6258 2007-02-11  Bruno Haible  <bruno@clisp.org>
6259
6260         Ensure O(n) worst-case complexity of strcasestr substitute.
6261         * lib/strcasestr.c: Include stdbool.h.
6262         (knuth_morris_pratt): New function.
6263         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
6264         bookkeeping indicates that it's worth it.
6265         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
6266
6267         * modules/strcasestr-tests: New file.
6268         * tests/test-strcasestr.c: New file.
6269
6270 2007-02-11  Bruno Haible  <bruno@clisp.org>
6271
6272         Ensure O(n) worst-case complexity of c_strcasestr.
6273         * lib/c-strcasestr.c: Include stdbool.h, string.h.
6274         (knuth_morris_pratt): New function.
6275         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
6276         the bookkeeping indicates that it's worth it.
6277         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
6278
6279         * modules/c-strcasestr-tests: New file.
6280         * tests/test-c-strcasestr.c: New file.
6281
6282 2007-02-11  Bruno Haible  <bruno@clisp.org>
6283
6284         Ensure O(n) worst-case complexity of c_strstr.
6285         * lib/c-strstr.c: Include stdbool.h, string.h.
6286         (knuth_morris_pratt): New function.
6287         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
6288         bookkeeping indicates that it's worth it.
6289         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
6290
6291         * lib/c-strstr.c: Complete rewrite for maintainability.
6292
6293         * modules/c-strstr-tests: New file.
6294         * tests/test-c-strstr.c: New file.
6295
6296 2007-02-11  Bruno Haible  <bruno@clisp.org>
6297
6298         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
6299         5.2.1 and earlier, whereby \055 was treated just like the range
6300         delimiter '-'.
6301         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
6302
6303 2007-02-08  Bruno Haible  <bruno@clisp.org>
6304
6305         * modules/regex (Depends-on): Add stdbool.
6306         Reported by Dalibor Topic <robilad@kaffe.org>.
6307
6308 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
6309
6310         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
6311         Prefer returning from main to exiting from it.
6312         Remove unnecessary parens after sizeof.
6313
6314 2007-02-05  Bruno Haible  <bruno@clisp.org>
6315
6316         New module mbssep.
6317         * modules/mbssep: New file.
6318         * lib/mbssep.c: New file.
6319         * lib/string_.h (strsep): Add a conditional link warning.
6320         (mbssep): New declaration.
6321         * m4/mbssep.m4: New file.
6322         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6323         GNULIB_MBSSEP.
6324         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
6325         * MODULES.html.sh (Internationalization functions): Add mbssep.
6326
6327 2007-02-05  Bruno Haible  <bruno@clisp.org>
6328
6329         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
6330         Optimize search in case of 1 delimiter.
6331
6332 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
6333
6334         * lib/acl.h: Include sys/types.h before sys/acl.h.
6335
6336 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
6337
6338         Merge upstream fix for glibc bugzilla #3957:
6339
6340         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
6341
6342         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
6343         bit for RE_HAT_LISTS_NOT_NEWLINE.
6344         (build_charclass_op): Remove bogus comment.
6345
6346 2007-02-05  Simon Josefsson  <simon@josefsson.org>
6347
6348         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
6349
6350 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
6351
6352         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
6353         * lib/memmem.c [!defined _LIBC]: Include config.h.
6354
6355 2007-02-04  Bruno Haible  <bruno@clisp.org>
6356
6357         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
6358         warning message.
6359
6360 2007-02-04  Bruno Haible  <bruno@clisp.org>
6361
6362         New module mbstok_r.
6363         * modules/mbstok_r: New file.
6364         * lib/mbstok_r.c: New file.
6365         * lib/string_.h (strtok_r): Change argument names to match the
6366         comments. Add a conditional link warning.
6367         (mbstok_r): New declaration.
6368         * m4/mbstok_r.m4: New file.
6369         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6370         GNULIB_MBSTOK_R.
6371         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
6372         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
6373
6374 2007-02-04  Bruno Haible  <bruno@clisp.org>
6375
6376         New module mbsspn.
6377         * modules/mbsspn: New file.
6378         * lib/mbsspn.c: New file.
6379         * lib/string_.h (strspn): Add a conditional link warning.
6380         (mbsspn): New declaration.
6381         * m4/mbsspn.m4: New file.
6382         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6383         GNULIB_MBSSPN.
6384         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
6385         * MODULES.html.sh (Internationalization functions): Add mbsspn.
6386
6387 2007-02-04  Bruno Haible  <bruno@clisp.org>
6388
6389         New module mbspbrk.
6390         * modules/mbspbrk: New file.
6391         * lib/mbspbrk.c: New file.
6392         * lib/string_.h (strpbrk): Add a conditional link warning.
6393         (mbspbrk): New declaration.
6394         * m4/mbspbrk.m4: New file.
6395         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6396         GNULIB_MBSPBRK.
6397         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
6398         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
6399
6400 2007-02-04  Bruno Haible  <bruno@clisp.org>
6401
6402         New module mbscspn.
6403         * modules/mbscspn: New file.
6404         * lib/mbscspn.c: New file.
6405         * lib/string_.h (strcspn): Add a conditional link warning.
6406         (mbscspn): New declaration.
6407         * m4/mbscspn.m4: New file.
6408         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6409         GNULIB_MBSCSPN.
6410         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
6411         * MODULES.html.sh (Internationalization functions): Add mbscspn.
6412
6413 2007-02-04  Bruno Haible  <bruno@clisp.org>
6414
6415         New module mbscasestr, reduced goal of strcasestr.
6416         * modules/mbscasestr: New file.
6417         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
6418         (mbscasestr): Renamed from strcasestr.
6419         * lib/strcasestr.c: Don't include mbuiter.h.
6420         (strcasestr): Remove support for multibyte locales.
6421         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
6422         Change the conditional link warning.
6423         (mbscasestr): New declaration.
6424         * m4/mbscasestr.m4: New file.
6425         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
6426         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
6427         REPLACE_STRCASESTR.
6428         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
6429         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
6430         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
6431         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
6432         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
6433         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
6434         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
6435         (Depends-on): Remove mbuiter.
6436         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
6437
6438 2007-02-04  Bruno Haible  <bruno@clisp.org>
6439
6440         Simplify handling of strncasecmp.
6441         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
6442         the conditional link warning.
6443         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
6444         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
6445         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
6446         * modules/strcase (configure.ac): Don't invoke
6447         gl_STRING_MODULE_INDICATOR.
6448         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
6449
6450 2007-02-04  Bruno Haible  <bruno@clisp.org>
6451
6452         New module mbscasecmp, reduced goal of strcasecmp.
6453         * modules/mbscasecmp: New file.
6454         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
6455         (mbscasecmp): Renamed from strcasecmp.
6456         * lib/strcasecmp.c: Don't include mbuiter.h.
6457         (strcasecmp): Remove support for multibyte locales.
6458         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
6459         Change the conditional link warning.
6460         (mbscasecmp): New declaration.
6461         * m4/mbscasecmp.m4: New file.
6462         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
6463         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
6464         REPLACE_STRCASECMP.
6465         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
6466         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6467         GNULIB_MBSCASECMP.
6468         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
6469         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
6470         * modules/strcase (Files): Remove m4/mbrtowc.m4.
6471         (Depends-on): Remove mbuiter.
6472         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
6473
6474 2007-02-04  Bruno Haible  <bruno@clisp.org>
6475
6476         New module mbsstr. Remove module strstr.
6477         * modules/mbsstr: New file.
6478         * modules/strstr: Remove file.
6479         * lib/mbsstr.c: Renamed from lib/strstr.c.
6480         (mbsstr): Renamed from strstr.
6481         * lib/string_.h (strstr): Remove declaration. Change the conditional
6482         link warning.
6483         (mbsstr): New declaration.
6484         * m4/mbsstr.m4: New file.
6485         * m4/strstr.m4: Remove file.
6486         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
6487         REPLACE_STRSTR.
6488         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
6489         Don't initialize GNULIB_STRSTR.
6490         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
6491         substitute GNULIB_STRSTR and REPLACE_STRSTR.
6492         * MODULES.html.sh (Internationalization functions): Add mbsstr.
6493         (Support for systems lacking ANSI C 89): Remove strstr.
6494
6495 2007-02-04  Bruno Haible  <bruno@clisp.org>
6496
6497         New module mbsrchr.
6498         * modules/mbsrchr: New file.
6499         * lib/mbsrchr.c: New file.
6500         * lib/string_.h (strrchr): Add a conditional link warning.
6501         (mbsrchr): New declaration.
6502         * m4/mbsrchr.m4: New file.
6503         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6504         GNULIB_MBSRCHR.
6505         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
6506         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
6507
6508 2007-02-04  Bruno Haible  <bruno@clisp.org>
6509
6510         New module mbschr.
6511         * modules/mbschr: New file.
6512         * lib/mbschr.c: New file.
6513         * lib/string_.h (strchr): Add a conditional link warning.
6514         (mbschr): New declaration.
6515         * m4/mbschr.m4: New file.
6516         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6517         GNULIB_MBSCHR.
6518         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
6519         * MODULES.html.sh (Internationalization functions): Add mbschr.
6520
6521 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
6522
6523         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
6524
6525         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
6526
6527 2007-02-04  Bruno Haible  <bruno@clisp.org>
6528
6529         New module description section 'configure.ac-early'.
6530         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
6531         (func_get_autoconf_early_snippet): New function.
6532         (func_import, func_create_testdir): Use it. Remove special cases for
6533         modules 'extensions' and 'lock'.
6534         * modules/extensions (configure.ac-early): Require
6535         gl_USE_SYSTEM_EXTENSIONS.
6536         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
6537
6538 2007-02-04  Bruno Haible  <bruno@clisp.org>
6539
6540         Make use of gcj-4.3's -fsource and -ftarget option.
6541         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
6542         and if so try the options -fsource and -ftarget.
6543         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
6544         source_version, ftarget_option, target_version arguments.
6545         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
6546         (is_envjavac_oldgcj_14_14_usable): Renamed from
6547         is_envjavac_gcj_14_14_usable.
6548         (is_envjavac_oldgcj_14_13_usable): Renamed from
6549         is_envjavac_gcj_14_13_usable.
6550         (is_gcj_present): Update.
6551         (is_gcj_43, is_gcj43_usable): New functions.
6552         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
6553         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
6554         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
6555         try the options -fsource and -ftarget.
6556
6557 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
6558
6559         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
6560         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
6561         larger value.
6562
6563 2007-02-03  Jim Meyering  <jim@meyering.net>
6564
6565         Give tools a better chance to allocate space for very large buffers.
6566         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
6567
6568         Make pwd and readlink work also when run with an unreadable parent dir
6569         on systems with openat support.
6570         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
6571         provided getcwd function, even when we have openat support.
6572         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
6573
6574 2007-02-02  Bruno Haible  <bruno@clisp.org>
6575
6576         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
6577         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
6578         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
6579         portability problems if one of these functions is only used on specific
6580         platforms.
6581         Reported by Paul Eggert.
6582
6583 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
6584
6585         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
6586         is causing more trouble than it's curing.
6587         * lib/regex_internal.h (__mempcpy): Remove.
6588         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
6589         (and make the code a tad smaller to boot).
6590         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
6591
6592 2007-02-02  Jim Meyering  <jim@meyering.net>
6593
6594         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
6595         section, not in the Makefile.am: one.
6596
6597 2007-02-02  Eric Blake  <ebb9@byu.net>
6598
6599         * lib/strchrnul.c: Always include config.h first.
6600
6601         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
6602         gnulib strstr is not necessary here.
6603
6604 2007-02-02  Simon Josefsson  <simon@josefsson.org>
6605
6606         * m4/socklen.m4: Fix typo.
6607
6608 2007-02-02  Eric Blake  <ebb9@byu.net>
6609
6610         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
6611         * modules/netinet_in (Makefile.am): Likewise.
6612
6613 2007-02-01  Bruno Haible  <bruno@clisp.org>
6614
6615         * lib/string_.h (GL_LINK_WARNING): New macro.
6616         (strcasecmp, strstr, strcasestr): If provided by the system,
6617         conditionally define as a macro that leads to a warning instead of to
6618         an error.
6619         (strncasecmp): Conditionally define as a macro that leads to a warning.
6620
6621 2007-02-01  Karl Berry  <karl@gnu.org>
6622
6623         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
6624
6625 2007-02-01  Bruno Haible  <bruno@clisp.org>
6626
6627         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
6628         renamings.
6629
6630 2007-02-01  Eric Blake  <ebb9@byu.net>
6631
6632         * modules/regex (Depends-on): Revert dependence on mempcpy.
6633         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
6634         module's definition of mempcpy.
6635         Reported by Paul Eggert.
6636
6637 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
6638
6639         * lib/string_.h: If the gnulib module XYZ is not present, undefine
6640         the symbol XYZ before redefining it.  This fixes a problem with
6641         programs that don't use XYZ, when compiled on systems that define
6642         XYZ to something else.
6643
6644 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
6645
6646         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
6647         occurs when "mkdir -m foo" creates a setgid directory that is (1)
6648         writeable to group or other and (2) is intended to have a special
6649         mode bit that is set or cleared.  In such a case, the directory
6650         should be neither group- nor other-writeable until the special
6651         mode bits are right.
6652
6653 2007-01-31  Eric Blake  <ebb9@byu.net>
6654
6655         * modules/mountlist (Depends-on): Add strstr.
6656
6657         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
6658         bug.
6659         * modules/string (Makefile.am): Remove redundant replacement.
6660         * modules/regex (Depends-on): Add mempcpy.
6661
6662 2007-01-31  Bruno Haible  <bruno@clisp.org>
6663
6664         New module description field 'Link'.
6665         * gnulib-tool (func_usage): Document --extract-link-directive.
6666         (sed_extract_prog): Recognize 'Link' directive.
6667         (func_get_link_directive): New function.
6668         (func_import): Show summary of link directives.
6669         Handle --extract-link-directive option.
6670         * modules/acl (Link): New section.
6671         * modules/clock-time (Link): New section.
6672         * modules/euidaccess (Link): New section.
6673         * modules/gettext (Link): New section.
6674         * modules/iconv (Link): New section.
6675         * modules/lock (Link): New section.
6676         * modules/nanosleep (Link): New section.
6677         * modules/readline (Link): New section.
6678
6679 2007-01-27  Bruno Haible  <bruno@clisp.org>
6680
6681         Enforce the use of gnulib modules for unportable <string.h> functions.
6682         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
6683         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
6684         (gl_HEADER_STRING_H_BODY): Require it.
6685         * lib/string_.h: If the gnulib module XYZ is not present, redefine
6686         the symbol XYZ to one that gives a link error.
6687         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
6688         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
6689         * modules/mempcpy (configure.ac): Likewise.
6690         * modules/memrchr (configure.ac): Likewise.
6691         * modules/stpcpy (configure.ac): Likewise.
6692         * modules/stpncpy (configure.ac): Likewise.
6693         * modules/strcase (configure.ac): Likewise.
6694         * modules/strcasestr (configure.ac): Likewise.
6695         * modules/strchrnul (configure.ac): Likewise.
6696         * modules/strdup (configure.ac): Likewise.
6697         * modules/strndup (configure.ac): Likewise.
6698         * modules/strnlen (configure.ac): Likewise.
6699         * modules/strpbrk (configure.ac): Likewise.
6700         * modules/strsep (configure.ac): Likewise.
6701         * modules/strstr (configure.ac): Likewise.
6702         * modules/strtok_r (configure.ac): Likewise.
6703
6704 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
6705
6706         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
6707
6708 2007-01-30  Jim Meyering  <jim@meyering.net>
6709
6710         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
6711
6712 2007-01-29  Bruno Haible  <bruno@clisp.org>
6713
6714         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
6715         * lib/execute.c: Likewise.
6716         * lib/pipe.c: Likewise.
6717         * lib/printf-args.h: Likewise.
6718         * lib/printf-args.c: Likewise.
6719         * lib/printf-parse.c: Likewise.
6720         * lib/vasnprintf.c: Likewise.
6721
6722 2007-01-29  Eric Blake  <ebb9@byu.net>
6723
6724         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
6725         declaration.
6726
6727 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
6728
6729         * lib/strptime.h (strptime): Use 'restrict' for args where
6730         POSIX requires this.
6731         * lib/strptime.c (strptime): Likewise.
6732         Change license notice from LGPL to GPL, since gnulib-tool will
6733         change this as needed.
6734         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
6735         defined.
6736         Include "strptime.h" first, to check interface.
6737         Do not #undef _LIBC and _NL_CURRENT.
6738         Do not include <stdlib.h>; no longer needed.
6739         Include "time_r.h" and declare ptime_locale_status
6740         only if _LIBC is not defined.
6741         (__P): Remove unused macro.
6742         (match_string): Bring back glibc version, but use it only if _LIBC
6743         is defined.
6744         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
6745         Remove unnecessary assertion and abort() call.
6746         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
6747         * m4/strptime.m4: Fix serial number comment.
6748         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
6749         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
6750         (Depends-on): Add time_r.
6751
6752 2007-01-29  Bruno Haible  <bruno@clisp.org>
6753
6754         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
6755         strptime.
6756         * modules/strptime (Depends-on): Add stdbool.
6757         * lib/strptime.h: Include <time.h> always. Add comments.
6758
6759 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
6760
6761         * modules/strptime: New file.
6762         * lib/strptime.h: New file.
6763         * lib/strptime.c: New file.
6764         * m4/strptime.m4: New file.
6765
6766 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
6767
6768         * MODULES.html.sh: New module mpsort.
6769         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
6770
6771         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
6772         a circularity problem with HP-UX ia64 reported by Bob Proulx in
6773         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
6774         All uses changed.
6775         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
6776         All uses changed.
6777         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
6778         to _Restrict_.
6779         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
6780         the parameter matches the prototype.
6781
6782 2007-01-28  Jim Meyering  <jim@meyering.net>
6783
6784         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
6785         sys/time.h here, reverting that part of the previous patch:
6786         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
6787
6788 2007-01-28  Bruno Haible  <bruno@clisp.org>
6789
6790         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
6791         value of $(SYS_TIME_H).
6792         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
6793         remove it conditionally, too. [added by Jim Meyering]
6794         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
6795         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
6796         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
6797         GETTIMEOFDAY_REPLACEMENT to 1.
6798
6799 2007-01-28  Bruno Haible  <bruno@clisp.org>
6800
6801         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
6802         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
6803         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
6804         Set UNISTD_H instead of UNISTD_H2.
6805         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
6806
6807 2007-01-28  Bruno Haible  <bruno@clisp.org>
6808
6809         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
6810         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
6811
6812 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6813
6814         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
6815         (func_create_testdir): Ensure C locale for `grep' and `tr'
6816         character ranges.
6817         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
6818         ACLOCAL_AMFLAGS parsing state machine.
6819
6820 2007-01-27  Bruno Haible  <bruno@clisp.org>
6821
6822         * modules/unistr/base: Update.
6823
6824 2007-01-27  Bruno Haible  <bruno@clisp.org>
6825
6826         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
6827         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
6828         * modules/unistr/u32-mbtouc-unsafe: Renamed from
6829         modules/unistr/u32-mbtouc.
6830         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
6831         * lib/unistr.h: Update.
6832         * lib/linebreak.c: Update.
6833         * modules/unistr/u32-mbtouc: Renamed from
6834         modules/unistr/u32-mbtouc-safe.
6835         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
6836         * lib/unistr.h: Update.
6837         * lib/unistr/u32-to-u8.c: Update.
6838         * lib/unistr/u32-to-u16.c: Update.
6839
6840 2007-01-27  Bruno Haible  <bruno@clisp.org>
6841
6842         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
6843         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
6844         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
6845         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
6846         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
6847         * modules/unistr/u16-mbtouc-unsafe: Renamed from
6848         modules/unistr/u16-mbtouc.
6849         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
6850         * lib/unistr.h: Update.
6851         * lib/linebreak.c: Update.
6852         * modules/linebreak: Update.
6853         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
6854         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
6855         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
6856         * modules/unistr/u16-mbtouc: Renamed from
6857         modules/unistr/u16-mbtouc-safe.
6858         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
6859         * lib/unistr.h: Update.
6860         * lib/unistr/u16-to-u8.c: Update.
6861         * modules/unistr/u16-to-u8: Update.
6862         * lib/unistr/u16-to-u32.c: Update.
6863         * modules/unistr/u16-to-u32: Update.
6864
6865 2007-01-27  Bruno Haible  <bruno@clisp.org>
6866
6867         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
6868         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
6869         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
6870         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
6871         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
6872         * modules/unistr/u8-mbtouc-unsafe: Renamed from
6873         modules/unistr/u8-mbtouc.
6874         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
6875         * lib/unistr.h: Update.
6876         * lib/striconveh.c: Update.
6877         * modules/striconveh: Update.
6878         * lib/linebreak.c: Update.
6879         * modules/linebreak: Update.
6880         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
6881         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
6882         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
6883         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
6884         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
6885         * lib/unistr.h: Update.
6886         * lib/striconveh.c: Update.
6887         * modules/striconveh: Update.
6888         * lib/unistr/u8-to-u16.c: Update.
6889         * modules/unistr/u8-to-u16: Update.
6890         * lib/unistr/u8-to-u32.c: Update.
6891         * modules/unistr/u8-to-u32: Update.
6892
6893 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6894
6895         Sync from Libtool.
6896         * lib/argz.c: Do not include strings.h nor memory.h, include
6897         string.h unconditionally.  Patch by Simon Josefsson.
6898
6899 2007-01-27  Bruno Haible  <bruno@clisp.org>
6900
6901         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
6902         from gl_HEADER_STRING_H_BODY.
6903         (gl_HEADER_STRING_H_BODY): Require it.
6904         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
6905         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
6906         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
6907         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
6908         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
6909         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
6910         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
6911         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
6912         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
6913         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
6914         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
6915         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
6916         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
6917         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
6918         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
6919
6920 2007-01-27  Bruno Haible  <bruno@clisp.org>
6921
6922         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
6923         check_PROGRAMS into noinst_PROGRAMS.
6924         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
6925         check_PROGRAMS in this case.
6926         (func_import): Set for_test to false.
6927         (func_create_testdir): Set for_test to true.
6928
6929 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
6930             Bruno Haible  <bruno@clisp.org>
6931
6932         * modules/strcasestr (Files): Remove lib/strcasestr.h.
6933         (Depends-on): Add string.
6934         (Includes): Use <string.h> instead of strcasestr.h.
6935         * modules/string (Makefile.am): Also substitute the value of
6936         REPLACE_STRCASESTR.
6937         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
6938         assume strcasestr is declared in <string.h> not <strings.h>. Also
6939         set REPLACE_STRCASESTR.
6940         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
6941         REPLACE_STRCASESTR.
6942         * lib/strcasestr.h: Remove file.
6943         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
6944         * lib/string_.h (strcasestr): New declaration.
6945
6946 2007-01-27  Bruno Haible  <bruno@clisp.org>
6947
6948         * lib/string_.h: Use 'extern'.
6949
6950 2007-01-27  Jim Meyering  <jim@meyering.net>
6951
6952         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
6953         of set-but-not-used local, "q".
6954
6955         * lib/mempcpy.c: Include <config.h> before <string.h>.
6956         This fixes a compilation error on HP-UX, due to the system's
6957         "restrict"-using mempcpy prototype.
6958
6959 2007-01-26  Bruno Haible  <bruno@clisp.org>
6960
6961         Small optimization.
6962         * lib/javacomp.c: Include c-strstr.h.
6963          (is_envjavac_gcj): Use c_strstr instead of strstr.
6964         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
6965
6966 2007-01-26  Bruno Haible  <bruno@clisp.org>
6967
6968         * MODULES.html.sh (Unicode string functions): Add the new modules.
6969
6970         * modules/uniconv/u32-strconv-to-locale: New file.
6971         * lib/uniconv/u32-strconv-to-locale.c: New file.
6972
6973         * modules/uniconv/u16-strconv-to-locale: New file.
6974         * lib/uniconv/u16-strconv-to-locale.c: New file.
6975
6976         * modules/uniconv/u8-strconv-to-locale: New file.
6977         * lib/uniconv/u8-strconv-to-locale.c: New file.
6978
6979         * modules/uniconv/u32-strconv-from-locale: New file.
6980         * lib/uniconv/u32-strconv-from-locale.c: New file.
6981
6982         * modules/uniconv/u16-strconv-from-locale: New file.
6983         * lib/uniconv/u16-strconv-from-locale.c: New file.
6984
6985         * modules/uniconv/u8-strconv-from-locale: New file.
6986         * lib/uniconv/u8-strconv-from-locale.c: New file.
6987
6988         * modules/uniconv/u32-strconv-to-enc: New file.
6989         * lib/uniconv/u32-strconv-to-enc.c: New file.
6990         * modules/uniconv/u32-strconv-to-enc-tests: New file.
6991         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
6992
6993         * modules/uniconv/u16-strconv-to-enc: New file.
6994         * lib/uniconv/u16-strconv-to-enc.c: New file.
6995         * lib/uniconv/u-strconv-to-enc.h: New file.
6996         * modules/uniconv/u16-strconv-to-enc-tests: New file.
6997         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
6998
6999         * modules/uniconv/u8-strconv-to-enc: New file.
7000         * lib/uniconv/u8-strconv-to-enc.c: New file.
7001         * modules/uniconv/u8-strconv-to-enc-tests: New file.
7002         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
7003
7004         * modules/uniconv/u32-strconv-from-enc: New file.
7005         * lib/uniconv/u32-strconv-from-enc.c: New file.
7006         * modules/uniconv/u32-strconv-from-enc-tests: New file.
7007         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
7008
7009         * modules/uniconv/u16-strconv-from-enc: New file.
7010         * lib/uniconv/u16-strconv-from-enc.c: New file.
7011         * modules/uniconv/u16-strconv-from-enc-tests: New file.
7012         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
7013
7014         * modules/uniconv/u8-strconv-from-enc: New file.
7015         * lib/uniconv/u8-strconv-from-enc.c: New file.
7016         * lib/uniconv/u-strconv-from-enc.h: New file.
7017         * modules/uniconv/u8-strconv-from-enc-tests: New file.
7018         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
7019
7020         * modules/uniconv/u32-conv-from-enc: New file.
7021         * lib/uniconv/u32-conv-from-enc.c: New file.
7022         * modules/uniconv/u32-conv-from-enc-tests: New file.
7023         * tests/uniconv/test-u32-conv-from-enc.c: New file.
7024
7025         * modules/uniconv/u16-conv-from-enc: New file.
7026         * lib/uniconv/u16-conv-from-enc.c: New file.
7027         * lib/uniconv/u-conv-from-enc.h: New file.
7028         * modules/uniconv/u16-conv-from-enc-tests: New file.
7029         * tests/uniconv/test-u16-conv-from-enc.c: New file.
7030
7031         * modules/uniconv/u8-conv-from-enc: New file.
7032         * lib/uniconv/u8-conv-from-enc.c: New file.
7033         * modules/uniconv/u8-conv-from-enc-tests: New file.
7034         * tests/uniconv/test-u8-conv-from-enc.c: New file.
7035
7036         * modules/uniconv/base: New file.
7037         * lib/uniconv.h: New file.
7038
7039 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
7040
7041         * doc/gnulib-tool.texi (Initial import): Update to match current
7042         behavior with strdup module.
7043         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
7044         * lib/memmem.h: Remove; all uses removed.  This is now done
7045         by <string.h>.
7046         * lib/mempcpy.h: Likewise.
7047         * lib/memrchr.h: Likewise.
7048         * lib/stpcpy.h: Likewise.
7049         * lib/stpncpy.h: Likewise.
7050         * lib/strcase.h: Likewise.
7051         * lib/strchrnul.h: Likewise.
7052         * lib/strdup.h: Likewise.
7053         * lib/strndup.h: Likewise.
7054         * lib/strnlen.h: Likewise.
7055         * lib/strpbrk.h: Likewise.
7056         * lib/strsep.h: Likewise.
7057         * lib/strstr.h: Likewise.
7058         * lib/strtok_r.h: Likewise.
7059         * lib/string_.h: New file.
7060         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
7061         Rely on <string.h> instead.
7062         * lib/canon-host.c: Likewise.
7063         * lib/chdir-long.c: Likewise.
7064         * lib/concatpath.c: Likewise.
7065         * lib/exclude.c: Likewise.
7066         * lib/fchdir.c: Likewise.
7067         * lib/getaddrinfo.c: Likewise.
7068         * lib/getcwd.c: Likewise.
7069         * lib/getsubopt.c: Likewise.
7070         * lib/glob.c: Likewise.
7071         * lib/hard-locale.c: Likewise.
7072         * lib/iconvme.c: Likewise.
7073         * lib/javacomp.c: Likewise.
7074         * lib/mempcpy.c: Likewise.
7075         * lib/memrchr.c: Likewise.
7076         * lib/regex_internal.h: Likewise.
7077         * lib/stpncpy.c: Likewise.
7078         * lib/strcasecmp.c: Likewise.
7079         * lib/strchrnul.c: Likewise.
7080         * lib/strdup.c: Likewise.
7081         * lib/striconv.c: Likewise.
7082         * lib/striconveh.c: Likewise.
7083         * lib/striconveha.c: Likewise.
7084         * lib/strncasecmp.c: Likewise.
7085         * lib/strndup.c: Likewise.
7086         * lib/strnlen.c: Likewise.
7087         * lib/strsep.c: Likewise.
7088         * lib/strstr.c: Likewise.
7089         * lib/strtok_r.c: Likewise.
7090         * lib/userspec.c: Likewise.
7091         * lib/w32spawn.h: Likewise.
7092         * lib/xstrndup.c: Likewise.
7093         * lib/mountlist.c (strstr): Remove decl.
7094         * m4/string_h.m4: New file.
7095         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
7096         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
7097         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
7098         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
7099         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
7100         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
7101         Set REPLACE_STRCASECMP if necessary.
7102         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
7103         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
7104         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
7105         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
7106         HAVE_DECL_STRDUP if necessary.
7107         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
7108         since gl_FUNC_STRNDUP does that now.
7109         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
7110         Check for decl here...
7111         (gl_PREREQ_STRNLEN): ... not here.
7112         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
7113         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
7114         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
7115         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
7116         necessary.
7117         * modules/string: New file.
7118         * modules/memmem (Files): Remove special-purpose include file.
7119         (Depends-on): Add string.
7120         (Include): Include <string.h>, not the removed file.
7121         * modules/mempcpy: Likewise.
7122         * modules/memrchr: Likewise.
7123         * modules/stpcpy: Likewise.
7124         * modules/stpncpy: Likewise.
7125         * modules/strcase: Likewise.
7126         * modules/strchrnul: Likewise.
7127         * modules/strdup: Likewise.
7128         * modules/strndup: Likewise.
7129         * modules/strnlen: Likewise.
7130         * modules/strpbrk: Likewise.
7131         * modules/strsep: Likewise.
7132         * modules/strstr: Likewise.
7133         * modules/strtok_r: Likewise.
7134         * tests/test-dirname.c: Don't include "strdup.h", since
7135         <string.h> now suffices.
7136         * tests/test-memmem.c: Don't include "memmem.h", since
7137         <string.h> now suffices.
7138
7139 2007-01-25  Bruno Haible  <bruno@clisp.org>
7140
7141         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
7142         *resultp is 0.
7143
7144         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
7145         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
7146         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
7147         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
7148
7149         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
7150         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
7151         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
7152         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
7153         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
7154         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
7155
7156 2007-01-24  Bruno Haible  <bruno@clisp.org>
7157
7158         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
7159         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
7160         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
7161         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
7162         gl_FUNC_FTS_CORE.
7163         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
7164         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
7165         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
7166         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
7167         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
7168         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
7169         gl_FUNC_FCHOWNAT.
7170         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
7171         gl_FUNC_STRFTIME.
7172         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
7173         Reported by Ralf Wildenhues.
7174
7175 2007-01-24  Bruno Haible  <bruno@clisp.org>
7176
7177         Drop AC_REQUIRE calls that are redundant with the module dependencies.
7178         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
7179         gl_GETADDRINFO.
7180         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
7181         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
7182         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
7183
7184 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
7185
7186         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
7187         Don't use 'exit'; just return from 'main'.
7188         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
7189
7190         * lib/fnmatch_.h: Readjust white space and comments to match
7191         glibc, to avoid spurious diffs.
7192
7193 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
7194
7195         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
7196         2004-12-01 change by Jakub Jelinek, since this code won't compile
7197         if !LIBC.  Problem reported by Bob Proulx.
7198
7199 2007-01-23  Bruno Haible  <bruno@clisp.org>
7200
7201         * lib/striconveh.c: Include c-strcaseeq.h.
7202         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
7203         * modules/striconveh (Depends-on): Add c-strcaseeq.
7204
7205 2007-01-23  Bruno Haible  <bruno@clisp.org>
7206
7207         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
7208
7209         * modules/c-strcaseeq: New file.
7210         * lib/c-strcaseeq.h: New file.
7211
7212         * modules/streq: New file.
7213         * lib/streq.h: New file.
7214
7215 2007-01-23  Bruno Haible  <bruno@clisp.org>
7216
7217         * modules/striconveha-tests: New file.
7218         * tests/test-striconveha.c: New file.
7219
7220         * lib/striconveha.h: Include <stdbool.h>.
7221         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
7222         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
7223         (mem_iconveha_notranslit): Renamed from mem_iconveha.
7224         (mem_iconveha): New function.
7225         (str_iconveha_notranslit): Renamed from str_iconveha.
7226         (str_iconveha): New function.
7227         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
7228         c-strcase.
7229
7230 2007-01-23  Bruno Haible  <bruno@clisp.org>
7231
7232         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
7233         encodings without forgiving before trying any encoding with handler.
7234         (str_iconveha): Try all encodings without forgiving before trying any
7235         encoding with handler.
7236
7237 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
7238
7239         Import the following changes from libc.
7240
7241         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
7242
7243         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
7244
7245         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
7246
7247         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
7248         normal_bracket label.
7249
7250         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
7251
7252         [BZ #361]
7253         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
7254         to normal_bracket after fetching the next character.
7255
7256 2007-01-22  Bruno Haible  <bruno@clisp.org>
7257
7258         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
7259         argument.
7260         * lib/striconveh.c (iconv_carefully_1): New function.
7261         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
7262         argument.
7263         (str_cd_iconveh): Update.
7264         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
7265         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
7266         * tests/test-striconveh.c (MAGIC): New macro.
7267         (new_offsets): New function.
7268         (main): Test call with and without offsets.
7269
7270 2007-01-22  Bruno Haible  <bruno@clisp.org>
7271
7272         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
7273         * modules/sys_select (Makefile.am): Likewise.
7274         * modules/sys_socket (Makefile.am): Likewise.
7275         * modules/sys_time (Makefile.am): Likewise.
7276
7277 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
7278
7279         * modules/gettimeofday (License): Change from GPL to LGPL, since
7280         gettimeofday is a library function.
7281
7282 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
7283
7284         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
7285
7286 2007-01-21  Bruno Haible  <bruno@clisp.org>
7287
7288         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
7289
7290 2007-01-21  Bruno Haible  <bruno@clisp.org>
7291
7292         * modules/striconveha: New file.
7293         * lib/striconveha.h: New file.
7294         * lib/striconveha.c: New file.
7295         * MODULES.html.sh (Internationalization functions): Add striconveha.
7296         * lib/striconv.c (str_iconv): Optimize the case of an empty input
7297         string.
7298         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
7299
7300 2007-01-21  Bruno Haible  <bruno@clisp.org>
7301
7302         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
7303         * lib/striconveh.c (str_iconveh): Likewise.
7304
7305 2007-01-21  Bruno Haible  <bruno@clisp.org>
7306
7307         * lib/striconveh.h (mem_iconveh): New declaration.
7308         * lib/striconveh.c (mem_iconveh): New function.
7309         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
7310
7311 2007-01-21  Bruno Haible  <bruno@clisp.org>
7312
7313         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
7314
7315         * lib/striconveh.h (mem_cd_iconveh): Change specification.
7316         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
7317         original result buffer.
7318         (str_cd_iconveh): Update.
7319         * tests/test-striconveh.c (main): Update.
7320
7321         * lib/striconv.h (mem_cd_iconv): Change specification.
7322         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
7323         result buffer.
7324         (str_cd_iconv): Update.
7325         * tests/test-striconv.c (main): Update.
7326
7327 2007-01-21  Bruno Haible  <bruno@clisp.org>
7328
7329         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
7330
7331 2007-01-20  Jim Meyering  <jim@meyering.net>
7332
7333         * lib/userspec.c (parse_with_separator): If a user or group string
7334         starts with "+", skip the corresponding name-to-ID look-up, since
7335         such a look-up must fail: user and group names may not include "+".
7336
7337 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
7338
7339         * lib/poll.c: Include sys/time.h and time.h unconditionally,
7340         since we now assume the sys_time module.
7341         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
7342         check for sys/time.h; no longer needed.
7343         * modules/poll (Depends-on): Depend on sys_time.
7344
7345 2007-01-18  Bruno Haible  <bruno@clisp.org>
7346
7347         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
7348         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
7349
7350         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
7351         gettimeofday.
7352
7353         * tests/test-gettimeofday.c: Include <time.h>.
7354         (dummy): Remove variable.
7355
7356         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
7357         gl_HEADER_SYS_TIME_H.
7358         (gl_HEADER_SYS_TIME_H): New macro.
7359
7360         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
7361         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7362         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
7363         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
7364         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7365         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
7366         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
7367         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7368         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
7369         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
7370         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7371
7372         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
7373         last change; it caused a compilation error when cross-compiling to
7374         Cygwin.
7375
7376 2007-01-18  Jim Meyering  <jim@meyering.net>
7377
7378         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
7379         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
7380         than the race-prone "test -d sys || mkdir sys".
7381         (configure.ac): Use AC_PROG_MKDIR_P.
7382         * modules/sys_select: Likewise.
7383         * modules/sys_socket: Likewise.
7384         * modules/sys_time: Likewise.
7385
7386 2007-01-18  Eric Blake  <ebb9@byu.net>
7387
7388         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
7389         replace gettimeofday.
7390         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
7391         name, to avoid infinite recursion.
7392
7393 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
7394
7395         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
7396         module sys_time.
7397         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
7398         assume timespec.h defines struct timeval.
7399         * lib/settime.c: Likewise.
7400         * lib/utimens.c: Likewise.
7401         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
7402         since we now assume the gettimeofday module.
7403         * lib/tempname.c (__gen_tempname): Likewise.
7404         * lib/gettimeofday.h: Remove.
7405         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
7406         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
7407         Include <time.h>, for 'time()'.
7408         (localtime_buffer_addr): Also use this workaround if
7409         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
7410         to simplify the uses.  All uses changed.
7411         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
7412         that #undef is inside {}, and 'const' follows type name consistently.
7413         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
7414         (gettimeofday): Do not use the maximum possible value for
7415         tv->tv_usec, since that might break usages other than ls.c.
7416         Instead, we'll leave ls.c alone.  This undoes today's patch
7417         by Bruno.  Add a compile-time warning for 1s-clock resolution;
7418         we've never observed the problem but might as well keep the
7419         canary.
7420         * lib/nanosleep.c: Include timespec.h first, for interface check.
7421         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
7422         now assume the sys_time module.
7423         * lib/tempname.c: Likewise.
7424         * lib/timespec.h: Likewise.
7425         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
7426         needed.
7427         * lib/strftime.c: Likewise.
7428         * lib/timespec.h: Likewise.
7429         * lib/posixtm.c: Include posixtm.h first, for interface check.
7430         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
7431         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
7432         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
7433         * lib/sys_time_.h: New file.
7434         * lib/timespec.h (struct timespec): Use long int, not long.
7435         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
7436         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
7437         Remove obsolescent call to AC_HEADER_TIME.
7438         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
7439         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7440         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
7441         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
7442         Likewise.
7443         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
7444         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
7445         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
7446         into the sys_time module.  Check for gettimeofday just once.
7447         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
7448         for gettimeofday signature to just check the signature.  Merely
7449         compile it, since linking doesn't test signature.  Improve test for
7450         whether gettimeofday.o is actually needed.
7451         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
7452         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
7453         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
7454         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7455         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
7456         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
7457         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
7458         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
7459         than worrying about sys/time.h.
7460         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
7461         Don't bother worrying about TIME_WITH_SYS_TIME.
7462         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
7463         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
7464         * m4/sys_time_h.m4: New file.
7465         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
7466         Don't include sys/time.h.  Return from main rather than exiting.
7467         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
7468         all uses changed.
7469         * modules/gethrxtime (Depends-on): Add sys_time.
7470         * modules/gettime (Depends-on): Likewise.
7471         * modules/gettimeofday (Depends-on): Likewise.
7472         * modules/nanosleep (Depends-on): Likewise.
7473         * modules/settime (Depends-on): Likewise.
7474         * modules/tempname (Depends-on): Likewise.
7475         * modules/utimens (Depends-on): Likewise.
7476         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
7477         (Include:) Change back to <sys/time.h>.
7478         (Maintainer:) Add self.
7479         * modules/sys_time: New file.
7480         * modules/tempname (Depends-on): Add gettimeofday.
7481         * tests/test-gettimeofday.c: Include <sys/time.h>
7482         rather than gettimeofday.h.
7483
7484 2007-01-17  Bruno Haible  <bruno@clisp.org>
7485
7486         * gnulib-tool (func_get_license): Revert last patch. Instead, let
7487         the license default to GPL.
7488         (func_create_testdir): Don't complain if a module is LGPL and its
7489         tests module depends on GPLed modules.
7490
7491 2007-01-17  Bruno Haible  <bruno@clisp.org>
7492
7493         * lib/gettimeofday.c (gettimeofday): Add code for the case
7494         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
7495         maximum possible value for tv->tv_usec, rather than the minimum one.
7496
7497 2005-10-08  Martin Lambers  <marlam@marlam.de>
7498 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
7499 2007-01-16  Bruno Haible  <bruno@clisp.org>
7500
7501         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
7502         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
7503         gl_FUNC_GETTIMEOFDAY.
7504         (Include): Add gettimeofday.h.
7505         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
7506         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
7507         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
7508         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
7509         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
7510         * lib/gettimeofday.h: New file.
7511         * lib/gettimeofday.c: Include <sys/timeb.h>.
7512         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
7513         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7514         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
7515         fall back on time().
7516
7517         * tests/test-gettimeofday.c: New file.
7518         * modules/gettimeofday-tests: New file.
7519
7520 2007-01-16  Eric Blake  <ebb9@byu.net>
7521
7522         * modules/fnmatch (Depends-on): Depend on wchar.
7523         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
7524         * m4/fnmatch.m4: Likewise.
7525         * modules/mbchar (Makefile.am): Assume <wchar.h>.
7526         * m4/mbchar.m4: Likewise.
7527         * modules/mbswidth (Depends-on): Depend on wchar.
7528         * lib/mbswidth.c: Assume <wchar.h>.
7529         * m4/mbswidth.m4: Likewise.
7530         * modules/quotearg (Depends-on): Depend on wchar.
7531         * lib/quotearg.c: Assume <wchar.h>.
7532         * m4/quotearg.m4: Likewise.
7533         * modules/regex (Depends-on): Depend on wchar.
7534         * lib/regex_internal.h: Assume <wchar.h>.
7535         * m4/regex.m4: Likewise.
7536         * modules/stdint (Depends-on): Depend on wchar.
7537         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
7538         * m4/stdint.m4: Likewise.
7539         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
7540         * modules/strftime (Depends-on): Depend on wchar.
7541         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
7542         * modules/strtol (Depends-on): Depend on wchar.
7543         * lib/strtol.c: Assume <wchar.h>.
7544         * modules/wcwidth (Depends-on): Depend on wchar.
7545         * lib/wcwidth.h: Assume <wchar.h>.
7546         * m4/wcwidth.m4: Likewise.
7547
7548 2007-01-16  Bruno Haible  <bruno@clisp.org>
7549
7550         * modules/csharpexec-script: New, created from...
7551         * modules/csharpexec: ... this.
7552
7553 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
7554
7555         * modules/javaexec-script: New, created from...
7556         * modules/javaexec: ... this.
7557
7558 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
7559
7560         * modules/poll (Dependencies): Add sys_select.
7561
7562 2007-01-15  Jim Meyering  <jim@meyering.net>
7563
7564         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
7565         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
7566         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
7567         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
7568
7569 2007-01-15  Bruno Haible  <bruno@clisp.org>
7570
7571         * modules/striconveh: New file.
7572         * lib/striconveh.h: New file.
7573         * lib/striconveh.c: New file.
7574         * MODULES.html.sh (Internationalization functions): Add striconveh.
7575
7576         * modules/striconveh-tests: New file.
7577         * tests/test-striconveh.c: New file.
7578
7579 2007-01-15  Bruno Haible  <bruno@clisp.org>
7580
7581         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
7582         not from GNU libiconv or GNU libc.
7583
7584 2007-01-15  Bruno Haible  <bruno@clisp.org>
7585
7586         * doc/gnulib-intro.texi (Copyright): Explain the different license
7587         terms for module descriptions, autoconf macros, tests, documentation.
7588
7589 2007-01-14  Bruno Haible  <bruno@clisp.org>
7590
7591         * modules/striconv-tests: New file.
7592         * tests/test-striconv.c: New file.
7593
7594 2007-01-14  Bruno Haible  <bruno@clisp.org>
7595
7596         * modules/iconv-tests: New file.
7597         * tests/test-iconv.c: New file.
7598
7599 2007-01-14  Bruno Haible  <bruno@clisp.org>
7600
7601         * gnulib-tool (func_get_license): For test modules, use the license of
7602         the main module.
7603
7604 2007-01-14  Bruno Haible  <bruno@clisp.org>
7605
7606         * modules/iconv (Include): Clarify that <iconv.h> can only be included
7607         if iconv is found to exist.
7608
7609 2007-01-14  Bruno Haible  <bruno@clisp.org>
7610
7611         * modules/c-ctype-tests: New file.
7612         * tests/test-c-ctype.c: New file.
7613
7614 2007-01-14  Bruno Haible  <bruno@clisp.org>
7615
7616         * modules/binary-io-tests: New file.
7617         * tests/test-binary-io.sh: New file.
7618         * tests/test-binary-io.c: New file.
7619
7620 2007-01-14  Bruno Haible  <bruno@clisp.org>
7621
7622         * modules/array-oset-tests: New file.
7623         * tests/test-array_oset.c: New file.
7624
7625 2007-01-14  Bruno Haible  <bruno@clisp.org>
7626
7627         * modules/array-list-tests: New file.
7628         * tests/test-array_list.c: New file.
7629
7630 2007-01-14  Bruno Haible  <bruno@clisp.org>
7631
7632         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
7633         and make.
7634         Reported by Simon Josefsson in
7635         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
7636
7637 2007-01-14  Bruno Haible  <bruno@clisp.org>
7638
7639         * modules/allocsa-tests: New file.
7640         * tests/test-allocsa.c: New file.
7641
7642 2007-01-14  Bruno Haible  <bruno@clisp.org>
7643
7644         * modules/fchdir (Depends-on): Add absolute-header.
7645         * modules/unistd (Depends-on): Likewise.
7646
7647 2006-12-30  Bruno Haible  <bruno@clisp.org>
7648
7649         * modules/fchdir: New file.
7650         * modules/unistd (Files): Add lib/unistd_.h.
7651         (Makefile.am): Generate unistd.h from unistd_.h.
7652         * lib/fchdir.c: New file.
7653         * lib/dirent_.h: New file.
7654         * lib/unistd_.h: New file.
7655         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
7656         * m4/fchdir.m4: New file.
7657         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
7658         (gl_HEADER_UNISTD): Invoke it.
7659         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
7660         function.
7661         * lib/backupfile.c (opendir, closedir): Undefine.
7662         * lib/chown.c (open, close): Undefine.
7663         * lib/clean-temp.c (open, close): Undefine.
7664         * lib/copy-file.c (open, close): Undefine.
7665         * lib/execute.c (open, close): Undefine.
7666         * lib/fsusage.c (open, close): Undefine.
7667         * lib/gc-gnulib.c (open, close): Undefine.
7668         * lib/getcwd.c (opendir, closedir): Undefine.
7669         * lib/glob.c (opendir, closedir): Undefine.
7670         * lib/javacomp.c (open, close): Undefine.
7671         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
7672         * lib/openat-proc.c (open, close): Undefine.
7673         * lib/pagealign_alloc.c (open, close): Undefine.
7674         * lib/pipe.c (open, close): Undefine.
7675         * lib/progreloc.c (open, close): Undefine.
7676         * lib/savedir.c (opendir, closedir): Undefine.
7677         * lib/utime.c (open, close): Undefine.
7678         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
7679
7680 2007-01-10  Bruno Haible  <bruno@clisp.org>
7681
7682         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
7683
7684 2007-01-12  Eric Blake  <ebb9@byu.net>
7685
7686         Provide a robust <wchar.h>.  Further simplifications are now
7687         possible in other modules, but not included here.
7688         * modules/wchar: New module.
7689         * m4/wchar.m4: New file.
7690         * lib/wchar_.h: Likewise.
7691         * modules/mbchar (Depends-on): Depend on wchar, as the first use
7692         of the new module.
7693         * MODULES.html.sh (Extended multibyte and wide character utilities):
7694         New section.
7695
7696 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
7697
7698         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
7699         to a reasonable default for memory allocation.
7700         (xreadlink): Don't allocate a huge buffer, to work around a buggy
7701         file system that reports garbage st_size values for symlinks.
7702         Problem reported by Liyang Hu.
7703
7704 2007-01-11  Simon Josefsson  <simon@josefsson.org>
7705
7706         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
7707         Emacs .#* auto-save files).
7708
7709 2007-01-11  Bruno Haible  <bruno@clisp.org>
7710
7711         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
7712         directory.
7713
7714 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
7715
7716         Use @...@ consistently in lib/wctype_.h.
7717         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
7718         on it being set to 1 or 0.
7719         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
7720         go back to AC_SUBSTing it.
7721         * modules/wctype (Makefile.am): Undo previous change.
7722
7723 2007-01-10  Eric Blake  <ebb9@byu.net>
7724
7725         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
7726         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
7727         * modules/wctype (Makefile.am): Likewise.
7728         Reported by Chris McGuire.
7729
7730 2007-01-10  Jim Meyering  <jim@meyering.net>
7731
7732         fts.c: a small readability/maintainability improvement
7733         * lib/fts.c (fts_read): Make this code slightly more readable and
7734         maintainable by hoisting the "sp->fts_cur = p" assignments to
7735         immediately follow the statements that set P.  Derived from
7736         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
7737
7738 2007-01-10  Eric Blake  <ebb9@byu.net>
7739
7740         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
7741         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
7742         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
7743         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
7744         Reported by Chris McGuire.
7745
7746 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7747
7748         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
7749         in sed script.
7750
7751 2007-01-09  Bruno Haible  <bruno@clisp.org>
7752
7753         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
7754         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
7755         variables.
7756         (func_module): Use them.
7757
7758 2007-01-09  Bruno Haible  <bruno@clisp.org>
7759
7760         * modules/unistr/base: New file.
7761         * lib/unistr.h: New file.
7762
7763         * modules/unistr/u8-to-u16: New file.
7764         * lib/unistr/u8-to-u16.c: New file.
7765
7766         * modules/unistr/u8-to-u32: New file.
7767         * lib/unistr/u8-to-u32.c: New file.
7768
7769         * modules/unistr/u16-to-u8: New file.
7770         * lib/unistr/u16-to-u8.c: New file.
7771
7772         * modules/unistr/u16-to-u32: New file.
7773         * lib/unistr/u16-to-u32.c: New file.
7774
7775         * modules/unistr/u32-to-u8: New file.
7776         * lib/unistr/u32-to-u8.c: New file.
7777
7778         * modules/unistr/u32-to-u16: New file.
7779         * lib/unistr/u32-to-u16.c: New file.
7780
7781         * modules/unistr/u8-check: New file.
7782         * modules/unistr/u16-check: New file.
7783         * modules/unistr/u32-check: New file.
7784         * lib/unistr/u8-check.c: New file.
7785         * lib/unistr/u16-check.c: New file.
7786         * lib/unistr/u32-check.c: New file.
7787
7788         * modules/unistr/u8-chr: New file.
7789         * modules/unistr/u16-chr: New file.
7790         * modules/unistr/u32-chr: New file.
7791         * lib/unistr/u8-chr.c: New file.
7792         * lib/unistr/u16-chr.c: New file.
7793         * lib/unistr/u32-chr.c: New file.
7794
7795         * modules/unistr/u8-cmp: New file.
7796         * modules/unistr/u16-cmp: New file.
7797         * modules/unistr/u32-cmp: New file.
7798         * lib/unistr/u8-cmp.c: New file.
7799         * lib/unistr/u16-cmp.c: New file.
7800         * lib/unistr/u32-cmp.c: New file.
7801
7802         * modules/unistr/u8-cpy: New file.
7803         * modules/unistr/u16-cpy: New file.
7804         * modules/unistr/u32-cpy: New file.
7805         * lib/unistr/u8-cpy.c: New file.
7806         * lib/unistr/u16-cpy.c: New file.
7807         * lib/unistr/u32-cpy.c: New file.
7808         * lib/unistr/u-cpy.h: New file.
7809
7810         * modules/unistr/u8-cpy-alloc: New file.
7811         * modules/unistr/u16-cpy-alloc: New file.
7812         * modules/unistr/u32-cpy-alloc: New file.
7813         * lib/unistr/u8-cpy-alloc.c: New file.
7814         * lib/unistr/u16-cpy-alloc.c: New file.
7815         * lib/unistr/u32-cpy-alloc.c: New file.
7816         * lib/unistr/u-cpy-alloc.h: New file.
7817
7818         * modules/unistr/u8-endswith: New file.
7819         * modules/unistr/u16-endswith: New file.
7820         * modules/unistr/u32-endswith: New file.
7821         * lib/unistr/u8-endswith.c: New file.
7822         * lib/unistr/u16-endswith.c: New file.
7823         * lib/unistr/u32-endswith.c: New file.
7824         * lib/unistr/u-endswith.h: New file.
7825
7826         * modules/unistr/u8-mblen: New file.
7827         * modules/unistr/u16-mblen: New file.
7828         * modules/unistr/u32-mblen: New file.
7829         * lib/unistr/u8-mblen.c: New file.
7830         * lib/unistr/u16-mblen.c: New file.
7831         * lib/unistr/u32-mblen.c: New file.
7832
7833         * modules/unistr/u8-mbtouc: New file.
7834         * modules/unistr/u16-mbtouc: New file.
7835         * modules/unistr/u32-mbtouc: New file.
7836         * lib/unistr/u8-mbtouc.c: New file.
7837         * lib/unistr/u16-mbtouc.c: New file.
7838         * lib/unistr/u32-mbtouc.c: New file.
7839
7840         * modules/unistr/u8-mbtouc-safe: New file.
7841         * modules/unistr/u16-mbtouc-safe: New file.
7842         * modules/unistr/u32-mbtouc-safe: New file.
7843         * lib/unistr/u8-mbtouc-safe.c: New file.
7844         * lib/unistr/u16-mbtouc-safe.c: New file.
7845         * lib/unistr/u32-mbtouc-safe.c: New file.
7846
7847         * modules/unistr/u8-move: New file.
7848         * modules/unistr/u16-move: New file.
7849         * modules/unistr/u32-move: New file.
7850         * lib/unistr/u8-move.c: New file.
7851         * lib/unistr/u16-move.c: New file.
7852         * lib/unistr/u32-move.c: New file.
7853         * lib/unistr/u-move.h: New file.
7854
7855         * modules/unistr/u8-next: New file.
7856         * modules/unistr/u16-next: New file.
7857         * modules/unistr/u32-next: New file.
7858         * lib/unistr/u8-next.c: New file.
7859         * lib/unistr/u16-next.c: New file.
7860         * lib/unistr/u32-next.c: New file.
7861
7862         * modules/unistr/u8-prev: New file.
7863         * modules/unistr/u16-prev: New file.
7864         * modules/unistr/u32-prev: New file.
7865         * lib/unistr/u8-prev.c: New file.
7866         * lib/unistr/u16-prev.c: New file.
7867         * lib/unistr/u32-prev.c: New file.
7868
7869         * modules/unistr/u8-set: New file.
7870         * modules/unistr/u16-set: New file.
7871         * modules/unistr/u32-set: New file.
7872         * lib/unistr/u8-set.c: New file.
7873         * lib/unistr/u16-set.c: New file.
7874         * lib/unistr/u32-set.c: New file.
7875         * lib/unistr/u-set.h: New file.
7876
7877         * modules/unistr/u8-startswith: New file.
7878         * modules/unistr/u16-startswith: New file.
7879         * modules/unistr/u32-startswith: New file.
7880         * lib/unistr/u8-startswith.c: New file.
7881         * lib/unistr/u16-startswith.c: New file.
7882         * lib/unistr/u32-startswith.c: New file.
7883         * lib/unistr/u-startswith.h: New file.
7884
7885         * modules/unistr/u8-stpcpy: New file.
7886         * modules/unistr/u16-stpcpy: New file.
7887         * modules/unistr/u32-stpcpy: New file.
7888         * lib/unistr/u8-stpcpy.c: New file.
7889         * lib/unistr/u16-stpcpy.c: New file.
7890         * lib/unistr/u32-stpcpy.c: New file.
7891         * lib/unistr/u-stpcpy.h: New file.
7892
7893         * modules/unistr/u8-stpncpy: New file.
7894         * modules/unistr/u16-stpncpy: New file.
7895         * modules/unistr/u32-stpncpy: New file.
7896         * lib/unistr/u8-stpncpy.c: New file.
7897         * lib/unistr/u16-stpncpy.c: New file.
7898         * lib/unistr/u32-stpncpy.c: New file.
7899         * lib/unistr/u-stpncpy.h: New file.
7900
7901         * modules/unistr/u8-strcat: New file.
7902         * modules/unistr/u16-strcat: New file.
7903         * modules/unistr/u32-strcat: New file.
7904         * lib/unistr/u8-strcat.c: New file.
7905         * lib/unistr/u16-strcat.c: New file.
7906         * lib/unistr/u32-strcat.c: New file.
7907         * lib/unistr/u-strcat.h: New file.
7908
7909         * modules/unistr/u8-strchr: New file.
7910         * modules/unistr/u16-strchr: New file.
7911         * modules/unistr/u32-strchr: New file.
7912         * lib/unistr/u8-strchr.c: New file.
7913         * lib/unistr/u16-strchr.c: New file.
7914         * lib/unistr/u32-strchr.c: New file.
7915
7916         * modules/unistr/u8-strcmp: New file.
7917         * modules/unistr/u16-strcmp: New file.
7918         * modules/unistr/u32-strcmp: New file.
7919         * lib/unistr/u8-strcmp.c: New file.
7920         * lib/unistr/u16-strcmp.c: New file.
7921         * lib/unistr/u32-strcmp.c: New file.
7922
7923         * modules/unistr/u8-strcpy: New file.
7924         * modules/unistr/u16-strcpy: New file.
7925         * modules/unistr/u32-strcpy: New file.
7926         * lib/unistr/u8-strcpy.c: New file.
7927         * lib/unistr/u16-strcpy.c: New file.
7928         * lib/unistr/u32-strcpy.c: New file.
7929         * lib/unistr/u-strcpy.h: New file.
7930
7931         * modules/unistr/u8-strcspn: New file.
7932         * modules/unistr/u16-strcspn: New file.
7933         * modules/unistr/u32-strcspn: New file.
7934         * lib/unistr/u8-strcspn.c: New file.
7935         * lib/unistr/u16-strcspn.c: New file.
7936         * lib/unistr/u32-strcspn.c: New file.
7937         * lib/unistr/u-strcspn.h: New file.
7938
7939         * modules/unistr/u8-strdup: New file.
7940         * modules/unistr/u16-strdup: New file.
7941         * modules/unistr/u32-strdup: New file.
7942         * lib/unistr/u8-strdup.c: New file.
7943         * lib/unistr/u16-strdup.c: New file.
7944         * lib/unistr/u32-strdup.c: New file.
7945         * lib/unistr/u-strdup.h: New file.
7946
7947         * modules/unistr/u8-strlen: New file.
7948         * modules/unistr/u16-strlen: New file.
7949         * modules/unistr/u32-strlen: New file.
7950         * lib/unistr/u8-strlen.c: New file.
7951         * lib/unistr/u16-strlen.c: New file.
7952         * lib/unistr/u32-strlen.c: New file.
7953         * lib/unistr/u-strlen.h: New file.
7954
7955         * modules/unistr/u8-strmblen: New file.
7956         * modules/unistr/u16-strmblen: New file.
7957         * modules/unistr/u32-strmblen: New file.
7958         * lib/unistr/u8-strmblen.c: New file.
7959         * lib/unistr/u16-strmblen.c: New file.
7960         * lib/unistr/u32-strmblen.c: New file.
7961
7962         * modules/unistr/u8-strmbtouc: New file.
7963         * modules/unistr/u16-strmbtouc: New file.
7964         * modules/unistr/u32-strmbtouc: New file.
7965         * lib/unistr/u8-strmbtouc.c: New file.
7966         * lib/unistr/u16-strmbtouc.c: New file.
7967         * lib/unistr/u32-strmbtouc.c: New file.
7968
7969         * modules/unistr/u8-strncat: New file.
7970         * modules/unistr/u16-strncat: New file.
7971         * modules/unistr/u32-strncat: New file.
7972         * lib/unistr/u8-strncat.c: New file.
7973         * lib/unistr/u16-strncat.c: New file.
7974         * lib/unistr/u32-strncat.c: New file.
7975         * lib/unistr/u-strncat.h: New file.
7976
7977         * modules/unistr/u8-strncmp: New file.
7978         * modules/unistr/u16-strncmp: New file.
7979         * modules/unistr/u32-strncmp: New file.
7980         * lib/unistr/u8-strncmp.c: New file.
7981         * lib/unistr/u16-strncmp.c: New file.
7982         * lib/unistr/u32-strncmp.c: New file.
7983
7984         * modules/unistr/u8-strncpy: New file.
7985         * modules/unistr/u16-strncpy: New file.
7986         * modules/unistr/u32-strncpy: New file.
7987         * lib/unistr/u8-strncpy.c: New file.
7988         * lib/unistr/u16-strncpy.c: New file.
7989         * lib/unistr/u32-strncpy.c: New file.
7990         * lib/unistr/u-strncpy.h: New file.
7991
7992         * modules/unistr/u8-strnlen: New file.
7993         * modules/unistr/u16-strnlen: New file.
7994         * modules/unistr/u32-strnlen: New file.
7995         * lib/unistr/u8-strnlen.c: New file.
7996         * lib/unistr/u16-strnlen.c: New file.
7997         * lib/unistr/u32-strnlen.c: New file.
7998         * lib/unistr/u-strnlen.h: New file.
7999
8000         * modules/unistr/u8-strpbrk: New file.
8001         * modules/unistr/u16-strpbrk: New file.
8002         * modules/unistr/u32-strpbrk: New file.
8003         * lib/unistr/u8-strpbrk.c: New file.
8004         * lib/unistr/u16-strpbrk.c: New file.
8005         * lib/unistr/u32-strpbrk.c: New file.
8006         * lib/unistr/u-strpbrk.h: New file.
8007
8008         * modules/unistr/u8-strrchr: New file.
8009         * modules/unistr/u16-strrchr: New file.
8010         * modules/unistr/u32-strrchr: New file.
8011         * lib/unistr/u8-strrchr.c: New file.
8012         * lib/unistr/u16-strrchr.c: New file.
8013         * lib/unistr/u32-strrchr.c: New file.
8014
8015         * modules/unistr/u8-strspn: New file.
8016         * modules/unistr/u16-strspn: New file.
8017         * modules/unistr/u32-strspn: New file.
8018         * lib/unistr/u8-strspn.c: New file.
8019         * lib/unistr/u16-strspn.c: New file.
8020         * lib/unistr/u32-strspn.c: New file.
8021         * lib/unistr/u-strspn.h: New file.
8022
8023         * modules/unistr/u8-strstr: New file.
8024         * modules/unistr/u16-strstr: New file.
8025         * modules/unistr/u32-strstr: New file.
8026         * lib/unistr/u8-strstr.c: New file.
8027         * lib/unistr/u16-strstr.c: New file.
8028         * lib/unistr/u32-strstr.c: New file.
8029         * lib/unistr/u-strstr.h: New file.
8030
8031         * modules/unistr/u8-strtok: New file.
8032         * modules/unistr/u16-strtok: New file.
8033         * modules/unistr/u32-strtok: New file.
8034         * lib/unistr/u8-strtok.c: New file.
8035         * lib/unistr/u16-strtok.c: New file.
8036         * lib/unistr/u32-strtok.c: New file.
8037         * lib/unistr/u-strtok.h: New file.
8038
8039         * modules/unistr/u8-uctomb: New file.
8040         * modules/unistr/u16-uctomb: New file.
8041         * modules/unistr/u32-uctomb: New file.
8042         * lib/unistr/u8-uctomb.c: New file.
8043         * lib/unistr/u16-uctomb.c: New file.
8044         * lib/unistr/u32-uctomb.c: New file.
8045
8046         * MODULES.html.sh (Unicode string functions): Add the new modules.
8047
8048 2007-01-08  Bruno Haible  <bruno@clisp.org>
8049
8050         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
8051         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
8052         subdirectories.
8053
8054 2007-01-08  Karl Berry  <karl@gnu.org>
8055
8056         * doc/error.texi: mention that main() fns must set program_name
8057         when progname is used.
8058
8059 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
8060
8061         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
8062         WCTYPE_H is empty, for the benefit of builds from non-distclean
8063         directories.  Problem reported by Eric Blake in
8064         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
8065
8066 2007-01-08  Bruno Haible  <bruno@clisp.org>
8067
8068         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
8069         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
8070         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
8071         PROVIDE_CANONICALIZE_FILENAME_MODE.
8072         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
8073
8074 2007-01-08  Bruno Haible  <bruno@clisp.org>
8075
8076         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
8077         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
8078         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
8079         * lib/fts.c: Likewise.
8080         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
8081
8082 2006-12-25  Bruno Haible  <bruno@clisp.org>
8083
8084         * modules/utf8-ucs4-safe: New file.
8085         * lib/utf8-ucs4-safe.h: New file.
8086         * lib/unistr/utf8-ucs4-safe.c: New file.
8087
8088         * modules/utf16-ucs4-safe: New file.
8089         * lib/utf16-ucs4-safe.h: New file.
8090         * lib/unistr/utf16-ucs4-safe.c: New file.
8091
8092         * MODULES.html.sh (Unicode string functions): Add the new modules.
8093
8094 2007-01-08  Bruno Haible  <bruno@clisp.org>
8095
8096         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
8097         (Depends-on): Add unitypes.
8098         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
8099         (u8_mbtouc_aux): Move out to separate file.
8100         (u8_mbtouc): Use ucs4_t, uint8_t types.
8101         * lib/unistr/utf8-ucs4.c: New file.
8102
8103         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
8104         (Depends-on): Add unitypes.
8105         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
8106         (u16_mbtouc_aux): Move out to separate file.
8107         (u16_mbtouc): Use ucs4_t, uint16_t types.
8108         * lib/unistr/utf16-ucs4.c: New file.
8109
8110         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
8111         (Depends-on): Add unitypes.
8112         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
8113         (u8_uctomb_aux): Move out to separate file.
8114         (u8_uctomb): Use ucs4_t, uint8_t types.
8115         * lib/unistr/ucs4-utf8.c: New file.
8116
8117         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
8118         (Depends-on): Add unitypes.
8119         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
8120         (u16_uctomb_aux): Move out to separate file.
8121         (u16_uctomb): Use ucs4_t, uint16_t types.
8122         * lib/unistr/ucs4-utf16.c: New file.
8123
8124 2006-12-25  Bruno Haible  <bruno@clisp.org>
8125
8126         * modules/unitypes: New file.
8127         * lib/unitypes.h: New file.
8128         * MODULES.html.sh (func_all_modules): New section "Unicode string
8129         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
8130         this section. Add unitypes.
8131
8132 2007-01-08  Bruno Haible  <bruno@clisp.org>
8133
8134         Avoid variable names that conflict with those from libtool.
8135         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
8136         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
8137         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
8138         library_names_spec to acl_library_names_spec, hardcode_* to
8139         acl_hardcode_*.
8140         Reported by Ralf Wildenhues.
8141
8142 2007-01-08  Bruno Haible  <bruno@clisp.org>
8143
8144         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
8145         definition.
8146         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
8147         definition.
8148         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
8149         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
8150         definition.
8151         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
8152         definition.
8153         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
8154         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
8155         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
8156         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
8157         definition.
8158         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
8159         definition.
8160         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
8161         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
8162         GC_USE_<algorithm>.
8163         * lib/gc-libgcrypt.c: Likewise.
8164         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
8165         * modules/gc-arctwo (configure.ac): Likewise.
8166         * modules/gc-des (configure.ac): Likewise.
8167         * modules/gc-hmac-md5 (configure.ac): Likewise.
8168         * modules/gc-hmac-sha1 (configure.ac): Likewise.
8169         * modules/gc-md2 (configure.ac): Likewise.
8170         * modules/gc-md4 (configure.ac): Likewise.
8171         * modules/gc-md5 (configure.ac): Likewise.
8172         * modules/gc-random (configure.ac): Likewise.
8173         * modules/gc-rijndael (configure.ac): Likewise.
8174         * modules/gc-sha1 (configure.ac): Likewise.
8175
8176 2007-01-08  Bruno Haible  <bruno@clisp.org>
8177
8178         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
8179         macro definition.
8180         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
8181         definition.
8182         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
8183         definition.
8184         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
8185         * modules/fcntl-safer (configure.ac): Likewise.
8186         * modules/fopen-safer (configure.ac): Likewise.
8187         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
8188         GNULIB_FWRITEERROR macro definition.
8189
8190 2007-01-08  Bruno Haible  <bruno@clisp.org>
8191
8192         * m4/gnulib-common.m4: New file.
8193         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
8194         (func_get_filelist): Add m4/gnulib-common.m4.
8195
8196 2007-01-08  Bruno Haible  <bruno@clisp.org>
8197
8198         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
8199         command.
8200
8201 2007-01-08  Jim Meyering  <jim@meyering.net>
8202
8203         Use a more robust test for a "can't happen" condition.
8204         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
8205         narrowed the st_size value.  Presuming the "can't happen" condition
8206         is true, that narrowing could conceivably convert an invalid st_size
8207         value into a valid one.  Instead, use a change based on Matthew
8208         Woehlke's original patch.
8209
8210         Slight readability improvement: use an assert-like macro
8211         in place of literal "abort ()" uses.
8212         * lib/fts.c (fts_assert): Define.
8213         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
8214         Use this macro instead of a bare 'abort'.
8215
8216 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
8217
8218         Don't worry about using IRIX 5.3's wctype.h broken definitions;
8219         simply work around them.
8220         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
8221         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
8222         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
8223         declaring.
8224         Don't bother to define as macros, since the standard doesn't require it.
8225         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
8226         longer worry about IRIX 5.3.
8227         (HAVE_WCTYPE_CTMP_BUG): Remove.
8228
8229 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8230
8231         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
8232         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
8233         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
8234         Problems reported by Georg Schwarz for IRIX 5.3.
8235
8236         * gnulib-tool (autoconf_minversion): Take the maximum version number
8237         found, not the minimum.  Problem reported by James Youngman.
8238
8239 2007-01-03  Karl Berry  <karl@gnu.org>
8240
8241         * doc/error.texi: new file, explaining interaction with progname.
8242         * doc/gnulib.texi: include it.  Update copyright.
8243
8244 2007-01-03  Simon Josefsson  <simon@josefsson.org>
8245
8246         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
8247         AC_CANONICAL_HOST, to improve autobuild outputs.
8248
8249 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
8250             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
8251
8252         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
8253         sockets, server sockets, and other file descriptors.  Count errors
8254         to compute the return value.  Reorder the code a bit to be easier
8255         to follow.  Don't set event bits that were not requested (except
8256         POLLERR and POLLHUP).
8257
8258 2007-01-01  Bruno Haible  <bruno@clisp.org>
8259
8260         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
8261
8262 2007-01-03  Jim Meyering  <jim@meyering.net>
8263
8264         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
8265
8266 2007-01-02  Bruno Haible  <bruno@clisp.org>
8267
8268         * modules/settime (Include): Require timespec.h.
8269         * modules/nanosleep (Include): Likewise.
8270
8271 2007-01-01  Bruno Haible  <bruno@clisp.org>
8272
8273         * gnulib-tool (func_emit_copyright_notice): Bump year.
8274         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
8275
8276 2007-01-01  Bruno Haible  <bruno@clisp.org>
8277
8278         Improve support for OpenBSD.
8279         * build-aux/config.rpath (libname_spec): Export.
8280         (library_names_spec): New variable. Export.
8281         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
8282         library_names_spec from the config.rpath output. Locate shared library
8283         through the name pattern in library_names_spec.
8284
8285 2007-01-01  Eric Blake  <ebb9@byu.net>
8286
8287         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
8288
8289 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
8290
8291         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
8292         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
8293         assume the C locale, and avoid an "eval" that could cause trouble.
8294         Problem with SORT reported by Bob Proulx.
8295
8296         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
8297         Define.  Trivial patch from Henning Nielsen Lund, originally
8298         sent to bug-grep@gnu.org today.
8299
8300 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
8301
8302         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
8303         struct stat.  Problem reported by Henning Nielsen Lund.
8304         * lib/acl.c: Include acl.h first, to check interface.  Don't
8305         bother to include sys/types.h and sys/stat.h again.
8306
8307 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
8308
8309         Import the following change from libc; problem reported by
8310         Sven Verdoolaege.
8311
8312         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
8313
8314         [BZ #1373]
8315         * lib/argp.h: Remove __NTH for __argp_usage inline function.
8316
8317 2006-12-28  Jim Meyering  <jim@meyering.net>
8318
8319         * build-aux/announce-gen: Do not assume that the package
8320         builds any of tar.gz, tar.bz2, and .xdelta files.
8321         Suggestion from Simon Josefsson.
8322
8323 2006-12-28  Simon Josefsson  <simon@josefsson.org>
8324
8325         * modules/announce-gen: New file.
8326
8327 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
8328
8329         * lib/mbchar.h: Just include <wctype.h>; the wctype module
8330         handles its gotchas now.
8331         * lib/mbswidth.c: Likewise.
8332         * lib/wcwidth.h: Likewise.
8333         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
8334         and iswcntrl; the wctype module does this stuff now.
8335         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
8336         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
8337         * modules/mbchar (Depends-on): Add wctype.
8338         * modules/mbswidth (Depends-on): Likewise.
8339         * modules/wcwidth (Depends-on): Likewise.
8340
8341 2006-12-27  Eric Blake  <ebb9@byu.net>
8342
8343         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
8344         module uses more than what <wctype.h> is required to provide.
8345
8346 2006-12-26  Eric Blake  <ebb9@byu.net>
8347
8348         * gnulib-tool (sed_extract_prog): Avoid space-tab.
8349
8350 2006-12-26  Eric Blake  <ebb9@byu.net>
8351
8352         * modules/absolute-header: New module.
8353         * modules/fcntl (Depends-on): Depend on it.
8354         * modules/inttypes (Depends-on): Likewise.
8355         * modules/stdint (Depends-on): Likewise.
8356         * modules/sys_stat (Depends-on): Likewise.
8357         * modules/wctype (Depends-on): Likewise.
8358         * MODULES.html.sh (Support for building libraries and
8359         executables): Document it.
8360
8361 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
8362
8363         * gnulib-tool (SED): Remove, undoing previous change.
8364         The problem was that it broke coreutils on Solaris, because
8365         "sed --posix" leaked into a makefile.
8366         (sed): New alias, if 'alias' and GNU sed.
8367
8368 2006-12-24  Jim Meyering  <jim@meyering.net>
8369
8370         Work around an fchownat bug in glibc-2.4:
8371         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
8372         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
8373         in spite of the -P option.
8374         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
8375         New macros.
8376         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
8377         * modules/openat (Files): Add lib/fchownat.c.
8378         * lib/openat.c (fchownat): Don't define here.  Move to...
8379         * lib/fchownat.c: ...this new file.
8380
8381 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
8382
8383         Fix bug reported by Bruno Haible in
8384         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
8385         where quotearg.c didn't compile on Mac OS X 10.2 because it
8386         lacks <wchar.h> and wint_t.
8387         * lib/wctype_.h (__wctype_wint_t): New type.
8388         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
8389         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
8390         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
8391         Arg is now of type __wctype_wint_t, not wint_t.
8392         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
8393         substitute HAVE_WINT_T.
8394         * modules/wctype (Files): Add m4/wint_t.m4.
8395         (wctype.h): Substitute HAVE_WINT_T.
8396
8397 2006-12-23  Bruno Haible  <bruno@clisp.org>
8398
8399         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
8400
8401 2006-12-23  Bruno Haible  <bruno@clisp.org>
8402
8403         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
8404         S_ISLNK.
8405         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
8406         mingw.
8407
8408 2006-12-22  Bruno Haible  <bruno@clisp.org>
8409
8410         * lib/copy-file.c: Include acl.h.
8411         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
8412         Close the file descriptors only after being done with copy_acl.
8413         * modules/copy-file (Depends-on): Add acl.
8414
8415 2006-12-22  Bruno Haible  <bruno@clisp.org>
8416
8417         * gnulib-tool (SED): New variable.
8418         Use $SED instead of sed everywhere.
8419
8420 2006-12-22  Bruno Haible  <bruno@clisp.org>
8421
8422         * modules/no-c++: New file.
8423         * m4/no-c++.m4: New file.
8424         * MODULES.html.sh (Support for building libraries and executables):
8425         Add no-c++.
8426
8427 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
8428
8429         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
8430         Include <limits.h>, and use its INT_MAX to rewrite the
8431         j loop so that it does not overflow 'int'.  Problem reported by
8432         Ralf Wildenhues in
8433         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
8434         Play it safe by shifting left by 1 rather than multiplying by 2,
8435         as GCC is less likely to optimize this away when the value
8436         is signed (when it assumes overflow leads to undefined behavior).
8437         Also, don't assume time_t uses two's complement.
8438
8439 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
8440
8441         * MODULES.html.sh: New module wctype.
8442         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
8443         * lib/fnmatch.c: Don't bother to include <wchar.h> before
8444         <wctype.h>, since the new wctype module should fix this.
8445         * lib/quotearg.c: Include <wctype.h> unconditionally, since
8446         the wctype module should arrange for it.
8447         * lib/regex_internal.h: Likewise.
8448         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
8449         since the wctype module should handle this now.
8450         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
8451         * modules/fnmatch (Depends-on): Add wctype.
8452         * modules/quotearg (Depends-on): Likewise.
8453         * modules/regex (Depends-on): Likewise.
8454
8455 2006-12-19  Bruno Haible  <bruno@clisp.org>
8456
8457         * lib/strdup.h [C++]: Wrap definitions in extern "C".
8458         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
8459
8460 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8461
8462         * modules/savewd (Depends-on): Fix dependency on fcntl.
8463
8464 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
8465
8466         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
8467         conforms to C99, rather than relying on the user's environment
8468         setting of STDINT_H.
8469
8470 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
8471         and Eric Blake  <ebb9@byu.net>
8472
8473         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
8474         This is more consistent with the other defines here.
8475         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
8476         Port to z/OS.  Problem reported by Paul Gilmartin.
8477         Change local vars to use gl_ prefix rather than ac_.
8478         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
8479         with other defines.
8480         * modules/double-slash-root: New module.
8481         * modules/dirname (Files): Remove m4/double-slash-root.m4.
8482         (Depends-on): Add double-slash-root.
8483         * MODULES.html.sh (File system functions): Mention new module.
8484
8485 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
8486
8487         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
8488         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
8489         This is for the benefit of gzip, which doesn't do i18n.
8490
8491 2006-12-12  Jim Meyering  <jim@meyering.net>
8492
8493         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
8494         Reported by Andreas Schwab <schwab@suse.de>.
8495
8496 2006-12-12  Bruno Haible  <bruno@clisp.org>
8497
8498         Merge these changes.
8499         2006-09-05  Bruno Haible  <bruno@clisp.org>
8500         * lib/iconvme.c (iconv_string): No need to save and restore errno when
8501         iconv_alloc succeeded.
8502         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
8503         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
8504         test for " && dest " at the end - dest is always != NULL there. Call
8505         iconv with 4xNULL arguments initially, to reset the state. Call iconv
8506         with 2xNULL arguments, also to flush the state storage. Handle the
8507         IRIX iconv behaviour. Realloc the final result, to throw away unused
8508         memory.
8509
8510 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
8511
8512         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
8513         and fchmodat unconditionally, since glibc 2.4 has them.
8514         Problem reported by Arkadiusz Miskiewicz.
8515
8516 2006-12-10  Bruno Haible  <bruno@clisp.org>
8517
8518         * gnulib-tool (func_import): Show the include files only for those
8519         modules that are copied and specified.
8520         Reported by Karl Berry.
8521
8522 2006-12-08  Jim Meyering  <jim@meyering.net>
8523
8524         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
8525         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
8526
8527         * build-aux/announce-gen: Add two new options, both optional:
8528         --bootstrap-tools=TOOL_LIST
8529               a comma-separated list of tools, e.g.,
8530               autoconf,automake,bison,gnulib
8531         --gnulib-snapshot-date=DATE
8532               if gnulib is in the bootstrap tool list,
8533               then report this as the snapshot date.
8534               If not specified, use the current date/time.
8535               If you specify a date here, be sure it's UTC.
8536
8537 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8538
8539         * tests/test-argp-2.sh: Fix test to match actual output.
8540         (func_compare): Fix sed script to be portable.
8541
8542 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
8543
8544         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
8545         workaround for this case.  It is not autoconfigured now; offhand
8546         it's hard to see how to autoconfigure it.
8547
8548 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
8549
8550         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
8551         a directory that is about to be chowned.  Such a directory's
8552         initial file permissions should permit the owner only and this
8553         should not be changed until after the chown, since the group and
8554         other bits would be incorrect if they granted permission before
8555         the chown.
8556
8557         Fix porting problem for iswctype reported by Georg Schwarz in:
8558         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
8559         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
8560         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
8561         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
8562         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
8563
8564 2006-12-03  Jim Meyering  <jim@meyering.net>
8565
8566         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
8567         p->fts_statp may not yet be defined.
8568         (fts_read): Instead, set it in the caller, once p->fts_statp is
8569         sure to be defined, and corresponds to a top-level directory.
8570         This bug made du -x fail.  Here's the coreutils test case:
8571         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
8572         Reported by Mike Frysinger.
8573
8574 2006-12-01  Jim Meyering  <jim@meyering.net>
8575
8576         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
8577         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
8578         Reported by Simon Josefsson.
8579
8580 2006-11-30  Jim Meyering  <jim@meyering.net>
8581
8582         * m4/warning.m4: Use the all-permissive copyright notice
8583         recommended by RMS (rather than LGPL).
8584         * m4/vararrays.m4: Likewise.
8585         * m4/flexmember.m4: Likewise.
8586
8587 2006-11-29  Bruno Haible  <bruno@clisp.org>
8588
8589         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
8590         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
8591         using +=.
8592         Reported by Simon Josefsson <simon@josefsson.org>.
8593
8594 2006-11-28  James Youngman <jay@gnu.org>
8595
8596         * README: Advise users that they might find the bug-gnulib@gnu.org
8597         and autotools-announce@gnu.org mailing lists useful.
8598
8599 2006-11-28  Bruno Haible  <bruno@clisp.org>
8600
8601         * m4/ptrdiff_max.m4: Remove file.
8602
8603 2006-11-21  Bruno Haible  <bruno@clisp.org>
8604
8605         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
8606         _AC_COMPUTE_INT.
8607         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8608         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
8609         _AC_COMPUTE_INT.
8610         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8611         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
8612         _AC_COMPUTE_INT.
8613         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8614
8615 2006-11-28  Jim Meyering  <jim@meyering.net>
8616
8617         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
8618         warning from "gcc -Wshadow" about shadowing the builtin.
8619
8620 2006-11-27  Bruno Haible  <bruno@clisp.org>
8621
8622         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
8623         _AC_COMPUTE_INT.
8624         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8625
8626 2006-11-27  Bruno Haible  <bruno@clisp.org>
8627             Paul Eggert  <eggert@cs.ucla.edu>
8628
8629         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
8630
8631 2006-11-26  Bruno Haible  <bruno@clisp.org>
8632
8633         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
8634         noinst_LTLIBRARIES.
8635
8636 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
8637             Bruno Haible  <bruno@clisp.org>
8638
8639         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
8640         if compiling with "gcc -ansi".
8641
8642 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
8643
8644         Fix some incompatibilities with gcc -ansi -pedantic.
8645         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
8646         if compiling pedantically with GCC, unless it's C99 or later.
8647         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
8648         it mishandles gcc -ansi -pedantic as well.
8649         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
8650         if gcc -pedantic.
8651         * lib/regexec.c (check_node_accept_bytes): Don't use auto
8652         initializers for struct if -pedantic, unless it's C99 or later.
8653
8654 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
8655
8656         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
8657         Don't close an fd more than once. Identical atimes indicate
8658         success, not failure.
8659
8660 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
8661
8662         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
8663
8664 2006-11-23  Jim Meyering  <jim@meyering.net>
8665
8666         * build-aux/announce-gen: New file.  From coreutils.
8667
8668 2006-11-22  Jim Meyering  <jim@meyering.net>
8669
8670         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
8671         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
8672         (fts_read): Use a temporary to narrow the overused st_size member
8673         before using it in a switch statement.  Reported by Matthew Woehlke.
8674
8675         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
8676         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
8677
8678 2006-11-20  Bruno Haible  <bruno@clisp.org>
8679
8680         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
8681         changequote instead of pairs of brackets.
8682         Reported by Andreas Schwab <schwab@suse.de>.
8683
8684 2006-11-21  Jim Meyering  <jim@meyering.net>
8685
8686         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
8687         so as to remain compatible with older compilers.
8688         Patch from Michael Deutschmann.
8689
8690 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
8691
8692         * MODULES.html.sh (File system functions): Add openat.
8693
8694         * lib/openat.h (rpl_fstatat): New macro, if
8695         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
8696         (fstatat): Define to rpl_fstatat under the same conditions,
8697         unless COMPILING_FSTATAT.
8698         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
8699         seems to have the bug.
8700         * lib/fstatat.c: New file.
8701         * modules/openat (Files): Add it.
8702
8703 2006-11-20  Bruno Haible  <bruno@clisp.org>
8704
8705         * Makefile: New file.
8706
8707 2006-11-20  Jim Meyering  <jim@meyering.net>
8708
8709         The beginnings of syntax-related checks for gnulib.
8710         * lib/Makefile: New file.
8711         * lib/t-idcache: New script.  Ensure that the two halves of
8712         idcache.c stay in sync.
8713
8714         * lib/idcache.c: Adjust comments in user- and group- portions to
8715         be more accurate, and to be consistent with one another.
8716
8717 2006-11-20  Jim Meyering  <jim@meyering.net>
8718
8719         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
8720         continue using the flexible array member (thus, this module performs
8721         half as many malloc calls), with the addition that...
8722         (getgroup, getuser): Consistently record a non-match via an empty
8723         "name" string, and map an empty string match to a NULL return value.
8724         * modules/idcache (Depends-on): Re-add flexmember.
8725
8726         * lib/idcache.c (getuser): Remove all uses of the register keyword.
8727         (getuidbyname, getgroup, getgidbyname): Likewise.
8728
8729         Use cleaner syntax: NULL rather than 0.
8730         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
8731
8732 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
8733
8734         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
8735         It mishandled the case where the group was missing.
8736         Problem reported by Greg Schafer.
8737         * modules/idcache: Likewise.
8738
8739 2006-11-18  Jim Meyering  <jim@meyering.net>
8740
8741         * check-module (%exempt_header): Add exception for some
8742         conditionally-included headers.
8743
8744         * modules/i-ring (Depends-on): Add verify.
8745         (License): Change to LGPL.
8746
8747 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
8748
8749         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
8750         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
8751         and inttostr.h.  Use snprintf rather than uinttostr, so that
8752         LGPLed code doesn't depend on GPLed.
8753
8754 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
8755
8756         * modules/inline (License): Change from GPL to LGPL.
8757
8758 2006-11-17  Jim Meyering  <jim@meyering.net>
8759
8760         * modules/d-type (License): Switch to LGPL.
8761
8762 2006-11-15  Bruno Haible  <bruno@clisp.org>
8763
8764         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
8765
8766 2006-11-15  Eric Blake  <ebb9@byu.net>
8767
8768         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
8769         the module dependency.
8770
8771 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
8772             Bruno Haible  <bruno@clisp.org>
8773
8774         * gnulib-tool (func_create_testdir): Add license consistency check.
8775
8776 2006-11-15  Eric Blake  <ebb9@byu.net>
8777
8778         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
8779         random "(cached)" in configure output.
8780
8781 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8782
8783         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
8784         test for conforming inttypes.h is both announced and cached.
8785
8786         * MODULES.html.sh (seen_modules, seen_files): New variables.
8787         (func_module): Rewrite to use a few less gnulib-tool and sed
8788         invocations.  Avoid a couple of quadratic algorithms for ...
8789         (missed_modules, missed_files): ... these, with ...
8790         (func_append, func_tmpdir): ... these new functions, from
8791         gnulib-tool.  Analogously, install traps for cleanup.
8792
8793         * tests/test-gc.c (main): Remove unused variables.
8794         * tests/test-read-file.c: Include stdlib.h, for 'free'.
8795
8796 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
8797
8798         * modules/inttostr (License): Change to LGPL.
8799
8800 2006-11-14  Eric Blake  <ebb9@byu.net>
8801
8802         * modules/tempname (License): Change to LGPL.
8803
8804 2006-11-14  Eric Blake  <ebb9@byu.net>
8805
8806         * doc/functions.texi (Function Portability): *printf functions on
8807         Cygwin now understand all POSIX size specifiers.
8808
8809 2006-11-14  Bruno Haible  <bruno@clisp.org>
8810
8811         * modules/c-ctype (License): Change to LGPL.
8812
8813 2006-11-12  Bruno Haible  <bruno@clisp.org>
8814
8815         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
8816         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
8817         for GNOME libraries, for which the include files are installed in
8818         subdirectories of $prefix/include.
8819
8820 2006-11-12  Bruno Haible  <bruno@clisp.org>
8821
8822         * m4/lib-link.m4: Require at least autoconf-2.54.
8823         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
8824         name to underscores for the --with option.
8825
8826 2006-11-13  Bruno Haible  <bruno@clisp.org>
8827
8828         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
8829         the tests directory.
8830         Reported by Ralf Wildenhues.
8831
8832 2006-11-13  Bruno Haible  <bruno@clisp.org>
8833
8834         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
8835         (func_emit_initmacro_end): Undo the override here.
8836         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
8837         Works around the famous automake error in coreutils.
8838
8839 2006-11-13  Eric Blake  <ebb9@byu.net>
8840
8841         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
8842         element, not its node.
8843
8844 2006-11-12  Bruno Haible  <bruno@clisp.org>
8845
8846         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
8847         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
8848
8849 2006-11-12  Bruno Haible  <bruno@clisp.org>
8850
8851         * gnulib-tool: New option --local-symlink.
8852         (func_usage): Document it.
8853         (lsymbolic): New variable.
8854         (func_import, func_create_testdir): If --symlink was not specified,
8855         test whether --local-symlink was specified and the file comes from
8856         the local_gnulib_dir.
8857
8858 2006-11-12  Bruno Haible  <bruno@clisp.org>
8859
8860         * gnulib-tool (func_ln): New function.
8861         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
8862
8863 2006-11-12  Bruno Haible  <bruno@clisp.org>
8864
8865         Finish support for source files in subdirectories.
8866         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
8867         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
8868         AUTOMAKE_OPTIONS.
8869         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
8870
8871 2006-11-12  Bruno Haible  <bruno@clisp.org>
8872
8873         * gnulib-tool (func_get_automake_snippet): Synthesize also an
8874         EXTRA_lib_SOURCES augmentation.
8875         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
8876
8877 2006-11-12  Jim Meyering  <jim@meyering.net>
8878
8879         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
8880         file descriptors.  This also averts a failure on systems with
8881         native openat support when a traversed directory lacks "x" access.
8882         * lib/fts_.h: Include "i-ring.h"
8883         (struct FTS) [fts_fd_ring]: New member.
8884         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
8885         (FCHDIR): Add parentheses.
8886         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
8887         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
8888         When descending, rather than simply closing the previous
8889         fts_cwd_fd value, push that file descriptor onto the ring.
8890         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
8891         (fts_open): Initialize the new fd_ring member.
8892         (fts_close): Clear the ring.
8893         (fts_safe_changedir): When possible, use our new fd_ring to skip
8894         the diropen and fstat and dev/ino comparison that would normally
8895         accompany a virtual `chdir ("..")'.
8896
8897         * modules/fts (Depends-on): Add i-ring.
8898         * modules/i-ring: New module.
8899         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
8900         * m4/i-ring.m4: New file.
8901
8902 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8903
8904         * gnulib-tool (func_create_testdir): Fix replacement of
8905         `build-aux' in configure.ac.  Run autotools in gltests
8906         subdirectory.
8907         (func_create_testdir, func_create_megatestdir, test): There is
8908         no need for '--force' in most autotool invocations in a new
8909         tree.  Actually fail the whole test if any of the tools, or the
8910         configure or make stages fail.
8911
8912         Sync from Automake.
8913         * build-aux/gnupload: Revert last change.  Add pointer to upload
8914         instructions of the GNU Maintenance Instructions.
8915         Suggestion by Karl Berry.
8916
8917 2006-11-10  Jim Meyering  <jim@meyering.net>
8918
8919         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
8920
8921 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
8922
8923         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
8924         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
8925         (bind_textdomain_codeset) [! ENABLE_NLS]:
8926         Evaluate all the arguments.  That way, callers get compatible behavior
8927         if the arguments have side effects.  Also, it avoids some GCC
8928         diagnostics in some cases; Joel E. Denny reported problems when Bison
8929         was configured with --enable-gcc-warnigs.
8930
8931 2006-11-10  Jim Meyering  <jim@meyering.net>
8932
8933         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
8934         relevant options in CFLAGS (like -O, -fno-inline) are taken into
8935         account.
8936
8937 2006-11-10  Jim Meyering  <jim@meyering.net>
8938
8939         * modules/inline: New file/module.
8940         * modules/xalloc (Files): Remove m4/inline.m4.
8941         (Depends-on): Add inline, instead.
8942         * modules/oset: Likewise.
8943         * modules/list: Likewise.
8944
8945 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
8946
8947         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
8948         Problem reported by Matthew Woehlke.
8949
8950 2006-11-09  Bruno Haible  <bruno@clisp.org>
8951
8952         * lib/tempname.c (gen_tempname): Remove variant that invokes
8953         __gen_tempname.
8954         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
8955         __gen_tempname.
8956
8957 2006-11-08  Bruno Haible  <bruno@clisp.org>
8958
8959         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
8960         to 'yes' instead of 'cross-compiling'.
8961
8962 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
8963
8964         * lib/quotearg.h (quotearg_free): New decl.
8965         * lib/quotearg.c (quotearg_free): New function.
8966         (slot0, nslots, slotvec0, slotvec):
8967         Now file-scope so that quotearg_free can get at them.
8968
8969 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8970
8971         Sync from Automake.
8972         * build-aux/gnupload: Add missing 'gnu' to example URL.
8973         Report by Karl Berry.
8974
8975 2006-11-08  Bruno Haible  <bruno@clisp.org>
8976
8977         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
8978         Suggested by Paul Eggert.
8979
8980 2006-11-08  Jim Meyering  <jim@meyering.net>
8981
8982         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
8983         It's already included if !_LIBC.
8984         (fts_safe_changedir): Add a comment.
8985
8986 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
8987
8988         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
8989         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
8990         Matthew Woehlke.
8991
8992         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
8993         definitions up, to avoid colliding with change below.
8994         (static_inline) [HAVE_INLINE]: New macro.
8995         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
8996         Provide extern decls when !HAVE_INLINE.  Do not define unless
8997         static_inline is defined, either by us or by xmalloc.c.  Use
8998         static_inline rather than static inline.
8999         (XCALLOC): Optimize sizeof(T) = 1 case.
9000         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
9001
9002 2006-11-07  Bruno Haible  <bruno@clisp.org>
9003
9004         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
9005         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
9006         AC_C_INLINE.
9007         * modules/xalloc (Files): Add m4/inline.m4.
9008
9009 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9010
9011         * README: Fix typo.
9012         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
9013         (Miscellanous Notes): ...from this.
9014
9015 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
9016
9017         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
9018         Mention that offsetof should be used instead of sizeof.
9019         From Bruno Haible.
9020
9021 2006-11-07  Bruno Haible  <bruno@clisp.org>
9022
9023         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
9024
9025 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
9026
9027         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
9028         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
9029         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
9030         (gl_tree_add_before, gl_tree_add_after):
9031         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
9032         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
9033         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
9034         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
9035         (gl_linked_add_after, gl_linked_add_at): Likewise.
9036         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
9037         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
9038         (gl_tree_add_before, gl_tree_add_after): Likewise.
9039         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
9040         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
9041         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
9042
9043 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9044
9045         * lib/gl_oset.h: Use C comment style, not C++ comment style.
9046
9047 2006-11-06  Bruno Haible  <bruno@clisp.org>
9048
9049         * m4/inline.m4: New file.
9050         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
9051         * modules/list (Files): Add m4/inline.m4.
9052         * modules/oset (Files): Likewise.
9053
9054 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
9055
9056         * lib/idcache.c: Include <stddef.h>, for offsetof.
9057         (struct userid.name): Change from char * to a flexible array member.
9058         All uses changed.
9059         * modules/idcache (Depends-on): Add flexmember.
9060
9061         * MODULES.html.sh (Core language properties): New module flexmember.
9062         * modules/flexmember, m4/flexmember.m4: New files.
9063
9064         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
9065         inline functions that are identical with the old xnmalloc_inline,
9066         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
9067         that we can avoid some unnecessary integer multiplications and
9068         divisions in the common case where the element size is known at
9069         compile time.
9070         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
9071         needed.
9072         (xnboundedmalloc): Remove.
9073         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
9074         arguments, for consistency with rest of this header.
9075         (xcharalloc): Rewrite using XNMALLOC.
9076         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
9077         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
9078         versions have been moved to lib/xalloc.h and renamed to be the
9079         non-*_inline versions.
9080         (xmalloc, xrealloc): Implement without reference to the xnmalloc
9081         and xnrealloc functions, since those functions are now inline and
9082         now call us.
9083         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
9084         renaming described above.
9085         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
9086         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
9087         captures the dependency in AC_C_INLINE.
9088
9089         New module canonicalize-lgpl, proposed by Charles Wilson in
9090         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
9091         with a few small changes afterwards.
9092         * MODULES.html.sh (File system functions): New module
9093         canonicalize-lgpl.
9094         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
9095         and canonicalize_file_name.
9096         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
9097         * modules/canonicalize-lgpl: New files.
9098
9099 2006-11-05  Bruno Haible  <bruno@clisp.org>
9100
9101         * gnulib-tool (func_import, func_create_testdir): Create directories
9102         also for files in subdirectories of lib/.
9103
9104 2006-11-05  Bruno Haible  <bruno@clisp.org>
9105
9106         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
9107         ANSI C compliant.
9108
9109 2006-11-03  Bruno Haible  <bruno@clisp.org>
9110
9111         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
9112         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
9113         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
9114         (xnboundedmalloc): New inline function.
9115         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
9116         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
9117         xmalloc.
9118         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
9119         xmalloc.
9120         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
9121         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
9122         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
9123         xmalloc.
9124         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
9125         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
9126         xmalloc.
9127         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
9128         gl_tree_add_after): Use XMALLOC instead of xmalloc.
9129         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
9130         xmalloc.
9131         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
9132         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
9133         gl_tree_add_after): Use XMALLOC instead of xmalloc.
9134         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
9135         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
9136         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
9137         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
9138
9139 2006-11-03  Bruno Haible  <bruno@clisp.org>
9140
9141         * lib/c-ctype.h [C++]: Define functions without name mangling.
9142         * lib/fwriteerror.h [C++]: Likewise.
9143         * lib/gcd.h [C++]: Likewise.
9144         * lib/linebreak.h [C++]: Likewise.
9145
9146 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
9147
9148         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
9149         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
9150         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
9151         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
9152         Check for functions and headers just once.
9153         Check for declaration of canonicalize_file_name.
9154         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
9155
9156 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
9157
9158         * gnulib-tool (func_import): Fix typo in actioncmd.
9159
9160 2006-11-02  Bruno Haible  <bruno@clisp.org>
9161
9162         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
9163         newline sequence in the Makefile.am snippet as a space, like "make"
9164         does.
9165         Reported by Roger Persson <perrog@gmail.com>.
9166
9167 2006-11-01  Bruno Haible  <bruno@clisp.org>
9168
9169         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
9170         already declared in <string.h>.
9171         * lib/strcase.h (strncasecmp): Don't declare it if yes.
9172
9173 2006-11-01  Bruno Haible  <bruno@clisp.org>
9174
9175         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
9176         * lib/strcase.h: Include <string.h>.
9177         (strcasecmp): Define to rpl_strcasecmp here.
9178
9179 2006-11-01  Bruno Haible  <bruno@clisp.org>
9180
9181         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
9182
9183 2006-11-01  Eric Blake  <ebb9@byu.net>
9184
9185         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
9186
9187         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
9188
9189 2006-10-29  Bruno Haible  <bruno@clisp.org>
9190
9191         Make it compile in C++ mode.
9192         * lib/full-write.c (full_rw): Add a cast.
9193
9194 2006-11-01  Bruno Haible  <bruno@clisp.org>
9195
9196         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
9197         be POSIX compliant.
9198         Reported by Roger Persson <perrog@gmail.com>.
9199
9200 2006-11-01  Eric Blake  <ebb9@byu.net>
9201
9202         * lib/getopt_.h: Fix comments.
9203
9204 2006-10-31  Eric Blake  <ebb9@byu.net>
9205
9206         * modules/tmpdir (Depends-on): Add sys_stat.
9207         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
9208         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
9209         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
9210         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
9211         tempname.
9212
9213 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
9214
9215         Avoid some C++ diagnostics reported by Bruno Haible.
9216         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
9217         xmalloc.
9218         (quotearg_alloc): Use xcharalloc rather than xmalloc.
9219         (struct slotvec): Move to top level.
9220         (quotearg_n_options): Rewrite to avoid xmalloc.
9221         * lib/xalloc.h (xcharalloc): New function.
9222         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
9223         [defined __cplusplus]: Add function template that provides result
9224         type propagation.  This part of the change is from Bruno Haible.
9225
9226 2006-10-29  Bruno Haible  <bruno@clisp.org>
9227
9228         Make it compile in C++ mode.
9229         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
9230         * lib/strnlen1.c (strnlen1): Cast memchr result.
9231         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
9232         * lib/clean-temp.c (string_equals, string_hash): Add casts.
9233         (create_temp_dir): Rename local variable 'template'.
9234         (compile_csharp_using_sscli): Add cast.
9235         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
9236         * lib/findprog.c (find_in_path): Likewise.
9237         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
9238         * lib/wait-process.c (register_slave_subprocess): Likewise.
9239
9240 2006-10-22  Bruno Haible  <bruno@clisp.org>
9241
9242         * modules/tsearch: New file.
9243         * lib/tsearch.h: New file.
9244         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
9245         * m4/tsearch.m4: New file.
9246         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
9247
9248 2006-10-29  Eric Blake  <ebb9@byu.net>
9249
9250         * lib/arcfour.c: Assume config.h.
9251         * lib/arctwo.c: Likewise.
9252         * lib/base64.c: Likewise.
9253         * lib/check-version.c: Likewise.
9254         * lib/crc.c: Likewise.
9255         * lib/des.c: Likewise.
9256         * lib/gc-gnulib.c: Likewise.
9257         * lib/gc-libgcrypt.c: Likewise.
9258         * lib/gc-pbkdf2-sha1.c: Likewise.
9259         * lib/getaddrinfo.c: Likewise.
9260         * lib/getdelim.c: Likewise.
9261         * lib/getline.c: Likewise.
9262         * lib/hmac-md5.c: Likewise.
9263         * lib/hmac-sha1.c: Likewise.
9264         * lib/iconvme.c: Likewise.
9265         * lib/md2.c: Likewise.
9266         * lib/md4.c: Likewise.
9267         * lib/memxor.c: Likewise.
9268         * lib/read-file.c: Likewise.
9269         * lib/readline.c: Likewise.
9270         * lib/rijndael-alg-fst.c: Likewise.
9271         * lib/rijndael-api-fst.c: Likewise.
9272         * lib/xgetdomainname.c: Likewise.
9273
9274 2006-10-28  Eric Blake  <ebb9@byu.net>
9275
9276         * lib/xstrndup.c: Assume config.h.
9277
9278 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
9279
9280         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
9281         stat-macros.h is now for our own macros, whereas stat_h is for
9282         macros in the <sys/stat.h> name space.
9283         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
9284         (STAT_MACROS_H): Remove.
9285         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
9286         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
9287         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
9288         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
9289         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
9290         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
9291         Move these macros to ...
9292         * lib/stat_.h: here.  Don't include stat-macros.h.
9293         * lib/canonicalize.c: Don't include stat-macros.h.
9294         * lib/chown.c: Likewise.
9295         * lib/euidaccess.c: Likewise.
9296         * lib/file-type.c: Likewise.
9297         * lib/filemode.c: Likewise.
9298         * lib/glob.c: Likewise.
9299         * lib/isapipe.c: Likewise.
9300         * lib/lchown.c: Likewise.
9301         * lib/lstat.c: Likewise.
9302         * lib/mkdir-p.c: Likewise.
9303         * lib/rmdir.c: Likewise.
9304         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
9305         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
9306         unless mkdir isn't declared, to speed up 'configure'.
9307         Always create sys/stat.h, since it's unlikely any real sys/stat.h
9308         would define all the S_* symbols.
9309         * modules/canonicalize (Depends-on):
9310         Depend on sys_stat, not stat-macros.
9311         * modules/chown: Likewise.
9312         * modules/euidaccess: Likewise.
9313         * modules/filemode: Likewise.
9314         * modules/file-type: Likewise.
9315         * modules/glob: Likewise.
9316         * modules/isapipe: Likewise.
9317         * modules/lchown: Likewise.
9318         * modules/lstat: Likewise.
9319         * modules/mkancesdirs: Likewise.
9320         * modules/rmdir: Likewise.
9321         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
9322         * modules/modechange: Likewise.
9323         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
9324         (configure.ac): Remove gl_STAT_MACROS.
9325         * modules/sys_stat (Depends-on): Remove stat-macros.
9326
9327 2006-10-27  Bruno Haible  <bruno@clisp.org>
9328
9329         * m4/signed.m4: Remove file.
9330         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
9331         invocation.
9332         * modules/vasnprintf (Files): Remove m4/signed.m4.
9333
9334 2006-10-27  Bruno Haible  <bruno@clisp.org>
9335
9336         Update to GNU gettext 0.16.
9337         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
9338         m4/inttypes-h.m4, m4/signed.m4.
9339         * m4/gettext.m4: Update to GNU gettext 0.16.
9340         * m4/intl.m4: New file, from GNU gettext.
9341         * m4/intldir.m4: New file, from GNU gettext.
9342         * config/srclist.txt: Update
9343
9344 2006-10-27  Eric Blake  <ebb9@byu.net>
9345
9346         * MODULES.html.sh: Document tempname.
9347         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
9348         dependencies.
9349         (Files): Move lib/tempname.c...
9350         * modules/tempname: ...to this new module.
9351         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
9352         (gl_PREREQ_TEMPNAME): Move...
9353         * m4/tempname.m4: ...to this new file.
9354         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
9355         * modules/sys_stat (Depends-on): Add stat-macros.
9356         * lib/stat_.h (includes): Pick up stat macros.
9357         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
9358         if stat macros are broken.
9359         * lib/tempname.c (includes): No need to include "stat-macros.h".
9360         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
9361         (direxists, __path_search) [!_LIBC]: Don't compile these in
9362         gnulib; the tmpdir module covers that.
9363         * lib/tempname.h: New file.
9364
9365 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
9366
9367         * COPYING: Explain how gnulib-tool converts licence headers.
9368         Almost all wording by Eric Blake.
9369
9370 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
9371
9372         * lib/mbchar.h (is_basic_table): Make read-only.
9373         * lib/mbchar.c (is_basic_table): Likewise.
9374         Reported by John Darrington.
9375
9376 2006-10-25  Bruno Haible  <bruno@clisp.org>
9377
9378         * lib/progname.h (set_program_name): Undefine before defining.
9379
9380 2006-10-25  Bruno Haible  <bruno@clisp.org>
9381
9382         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
9383         false for non-gcc C++ compilers.
9384         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
9385
9386 2006-10-24  Bruno Haible  <bruno@clisp.org>
9387
9388         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
9389         iconv implementations like Irix iconv.
9390
9391 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
9392
9393         * modules/vararrays: New file.
9394         * m4/vararrays.m4: New file, taken from diffutils.
9395         * MODULES.html.sh: New module vararrays.
9396
9397 2006-10-24  Karl Berry  <karl@gnu.org>
9398
9399         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
9400         Don't call GNU Unix.
9401
9402 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9403
9404         * users.txt: Add Libtool.
9405
9406         Sync from Libtool:
9407
9408         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
9409
9410         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
9411         to gnulib's policy of including config.h unconditionally.
9412
9413 2006-10-24  Bruno Haible  <bruno@clisp.org>
9414
9415         * modules/wcwidth (Files): Add m4/wint_t.m4.
9416         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
9417         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
9418
9419 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
9420
9421         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
9422         to pacify GCC with some -W flags enabled.  Problem reported by
9423         Bruno Haible.
9424
9425 2006-10-24  Jim Meyering  <jim@meyering.net>
9426
9427         * MODULES.html.sh: Remove uinttostr.  It's not a module.
9428         Reported by Karl Berry.
9429
9430 2006-10-23  Bruno Haible  <bruno@clisp.org>
9431
9432         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
9433
9434 2006-10-24  Bruno Haible  <bruno@clisp.org>
9435
9436         * lib/gl_list.h: Use C comment style, not C++ comment style.
9437
9438 2006-10-23  Eric Blake  <ebb9@byu.net>
9439
9440         * lib/getaddrinfo.c (includes): Add missing include.
9441
9442 2006-10-23  Bruno Haible  <bruno@clisp.org>
9443             Paul Eggert  <eggert@cs.ucla.edu>
9444
9445         Ability to rename obstack_free.
9446         * lib/obstack.h (__obstack_free): New macro. Declare instead of
9447         obstack_free.
9448         (obstack_free): Invoke the __obstack_free macro.
9449         * lib/obstack.c (obstack_free): Use __obstack_free macro.
9450
9451 2006-10-23  Bruno Haible  <bruno@clisp.org>
9452             Paul Eggert  <eggert@cs.ucla.edu>
9453
9454         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
9455         __argc, __argv from the declaration. (They are defined as macros on
9456         mingw.)
9457
9458 2006-10-22  Bruno Haible  <bruno@clisp.org>
9459
9460         * doc/gnulib-intro.texi: New file.
9461         * doc/gnulib.texi: Include it.
9462
9463 2006-10-21  Bruno Haible  <bruno@clisp.org>
9464
9465         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
9466         "Introduction", "Miscellanous Notes", "Particular Modules".
9467
9468 2006-10-21  Bruno Haible  <bruno@clisp.org>
9469
9470         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9471         Change mostlyclean-local rule to avoid sh syntax error from bash
9472         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
9473
9474 2006-10-23  Jim Meyering  <jim@meyering.net>
9475
9476         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
9477         in place of snprintf.
9478
9479         * modules/inttostr (Files): Add lib/uinttostr.c.
9480         * lib/uinttostr.c (inttostr): New file/function.
9481         * lib/inttostr.h (uinttostr): Declare.
9482         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
9483         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
9484         Add uinttostr.
9485         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
9486
9487 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
9488
9489         * lib/canonicalize.c (ELOOP): Define if not already defined.
9490         Problem reported by Bruno Haible in
9491         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
9492
9493 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
9494
9495         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
9496         Problem reported by Perry Smith and Ville Laurikari.
9497
9498         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
9499         uses.
9500
9501 2006-10-19  Bruno Haible  <bruno@clisp.org>
9502
9503         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
9504         for mingw.
9505
9506 2006-10-19  Bruno Haible  <bruno@clisp.org>
9507
9508         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
9509         Needed for mingw.
9510
9511 2006-10-19  Bruno Haible  <bruno@clisp.org>
9512
9513         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
9514
9515 2006-10-19  Bruno Haible  <bruno@clisp.org>
9516
9517         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
9518         it.
9519
9520 2006-10-19  Bruno Haible  <bruno@clisp.org>
9521
9522         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
9523         invocation.
9524
9525 2006-10-19  Bruno Haible  <bruno@clisp.org>
9526
9527         * gnulib-tool (func_create_testdir): Don't include ftruncate and
9528         mountlist by default.
9529
9530 2006-10-16  Bruno Haible  <bruno@clisp.org>
9531
9532         * lib/c-strstr.c: Include c-strstr.h.
9533
9534 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
9535
9536         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
9537         in a slash.
9538
9539 2006-10-18  Bruno Haible  <bruno@clisp.org>
9540
9541         * lib/lock.h [C++]: Wrap definitions in extern "C".
9542
9543 2006-10-18  Bruno Haible  <bruno@clisp.org>
9544
9545         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
9546         gl_LIBOBJS list.
9547
9548 2006-10-18  Bruno Haible  <bruno@clisp.org>
9549
9550         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
9551
9552 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
9553
9554         * lib/xstrtol.h: Include gettext.h.
9555         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
9556         Problem reported by Eric Blake.
9557         * modules/xstrtol (Depends-on): Add gettext-h.
9558
9559 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
9560
9561         * lib/strftime.c (advance): New macro.
9562         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
9563         incomplete type, so you can't add 0 to it.  Problem and patch
9564         reported by Eelco Dolstra for dietlibc.
9565
9566 2006-10-18  Jim Meyering  <jim@meyering.net>
9567
9568         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
9569         type for a local, and rename it: s/up/user_proc/.
9570
9571 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
9572
9573         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
9574         READ_UTMP_USER_PROCESS.
9575         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
9576
9577 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
9578
9579         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
9580         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
9581
9582 2006-10-17  Eric Blake  <ebb9@byu.net>
9583
9584         * lib/sigprocmask.c (sigprocmask): Fix typo.
9585
9586         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
9587
9588         * modules/clean-temp (Makefile.am): Don't add to make output...
9589         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
9590         config.h.
9591
9592 2006-10-17  Bruno Haible  <bruno@clisp.org>
9593
9594         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
9595         differently if DEFAULT_TEXT_DOMAIN is set.
9596
9597 2006-10-16  Bruno Haible  <bruno@clisp.org>
9598
9599         * lib/clean-temp.c: Include fwriteerror.h.
9600
9601 2006-10-16  Bruno Haible  <bruno@clisp.org>
9602
9603         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
9604
9605 2006-10-16  Bruno Haible  <bruno@clisp.org>
9606
9607         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
9608         * lib/sigprocmask.h: Include <sys/types.h>.
9609         (sigset_t): Use the system's definition if present.
9610
9611 2006-10-17  Eric Blake  <ebb9@byu.net>
9612
9613         * lib/xvasprintf.c (includes): Assume config.h.
9614         * lib/xasprintf.c (includes): Likewise.
9615
9616 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
9617
9618         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
9619         at least as wide as intmax_t.
9620
9621 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
9622
9623         (Imported from Automake.)
9624         * build-aux/gnupload: Update to version 1.1 of directive file.
9625
9626 2006-10-16  Eric Blake  <ebb9@byu.net>
9627
9628         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
9629         match Automake 1.10a.
9630
9631 2006-10-14  Bruno Haible  <bruno@clisp.org>
9632
9633         * modules/sigprocmask: New file.
9634         * lib/sigprocmask.h: New file.
9635         * lib/sigprocmask.c: New file.
9636         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
9637         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
9638         request sigprocmask.o.
9639         (gl_PREREQ_SIGPROCMASK): New macro.
9640         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
9641         (Depends-on): Add sigprocmask.
9642         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
9643         gt_SIGNALBLOCKING. Test for 'raise' only once.
9644         * lib/fatal-signal.c: Include sigprocmask.h.
9645         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
9646         unblock_fatal_signals): Define always.
9647         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
9648         sigprocmask.
9649
9650 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9651
9652         Sync from Automake.
9653         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
9654         which incorrectly sets the mode of an existing destination
9655         directory.  In some cases the unpatched install-sh could do the
9656         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
9657         system.  We hope this is rare in practice, but it's clearly worth
9658         fixing.  Problem reported by Alex Unleashed in
9659         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
9660         Also, don't bother to check for -m bugs unless we're using -m;
9661         suggested by Stepan Kasal.
9662
9663 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9664
9665         Sync from Automake.
9666         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
9667         `-c' flag, so they appear at the same position as in %FASTDEP%
9668         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
9669         which ignores unknown options only after the first non-option.
9670         Bug report against M4 by Nelson H. F. Beebe.
9671
9672 2006-10-13  Jim Meyering  <jim@meyering.net>
9673
9674         Fix a bug in yesterday's change.
9675         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
9676         p->fts_statp->st_dev would be used uninitialized.
9677         Ensures that we always call fts_stat on the very first entry.
9678         Miklos Szeredi reported that find -xdev stopped working.
9679
9680 2006-10-12  Bruno Haible  <bruno@clisp.org>
9681
9682         * gnulib-tool (func_get_automake_snippet): Append an automatically
9683         computed EXTRA_DIST augmentation.
9684         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
9685         * modules/alloca-opt (Makefile.am): Likewise.
9686         * modules/allocsa (Makefile.am): Likewise.
9687         * modules/arcfour (Makefile.am): Likewise.
9688         * modules/arctwo (Makefile.am): Likewise.
9689         * modules/argmatch (Makefile.am): Likewise.
9690         * modules/argz (Makefile.am): Likewise.
9691         * modules/atexit (Makefile.am): Likewise.
9692         * modules/backupfile (Makefile.am): Likewise.
9693         * modules/byteswap (Makefile.am): Likewise.
9694         * modules/c-strtod (Makefile.am): Likewise.
9695         * modules/c-strtold (Makefile.am): Likewise.
9696         * modules/calloc (Makefile.am): Likewise.
9697         * modules/canon-host (Makefile.am): Likewise.
9698         * modules/canonicalize (Makefile.am): Likewise.
9699         * modules/chdir-long (Makefile.am): Likewise.
9700         * modules/chdir-safer (Makefile.am): Likewise.
9701         * modules/check-version (Makefile.am): Likewise.
9702         * modules/chown (Makefile.am): Likewise.
9703         * modules/cloexec (Makefile.am): Likewise.
9704         * modules/close-stream (Makefile.am): Likewise.
9705         * modules/closeout (Makefile.am): Likewise.
9706         * modules/crc (Makefile.am): Likewise.
9707         * modules/csharpexec (Makefile.am): Likewise.
9708         * modules/cycle-check (Makefile.am): Likewise.
9709         * modules/des (Makefile.am): Likewise.
9710         * modules/dev-ino (Makefile.am): Likewise.
9711         * modules/dirfd (Makefile.am): Likewise.
9712         * modules/dirname (Makefile.am): Likewise.
9713         * modules/dup2 (Makefile.am): Likewise.
9714         * modules/eealloc (Makefile.am): Likewise.
9715         * modules/error (Makefile.am): Likewise.
9716         * modules/euidaccess (Makefile.am): Likewise.
9717         * modules/exclude (Makefile.am): Likewise.
9718         * modules/exitfail (Makefile.am): Likewise.
9719         * modules/fcntl-safer (Makefile.am): Likewise.
9720         * modules/fcntl (Makefile.am): Likewise.
9721         * modules/file-type (Makefile.am): Likewise.
9722         * modules/fileblocks (Makefile.am): Likewise.
9723         * modules/filemode (Makefile.am): Likewise.
9724         * modules/filenamecat (Makefile.am): Likewise.
9725         * modules/fnmatch (Makefile.am): Likewise.
9726         * modules/fopen-safer (Makefile.am): Likewise.
9727         * modules/fpending (Makefile.am): Likewise.
9728         * modules/fprintftime (Makefile.am): Likewise.
9729         * modules/free (Makefile.am): Likewise.
9730         * modules/fsusage (Makefile.am): Likewise.
9731         * modules/ftruncate (Makefile.am): Likewise.
9732         * modules/fts (Makefile.am): Likewise.
9733         * modules/gc-arcfour (Makefile.am): Likewise.
9734         * modules/gc-des (Makefile.am): Likewise.
9735         * modules/gc-hmac-md5 (Makefile.am): Likewise.
9736         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
9737         * modules/gc-md4 (Makefile.am): Likewise.
9738         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
9739         * modules/gc-sha1 (Makefile.am): Likewise.
9740         * modules/gc (Makefile.am): Likewise.
9741         * modules/getaddrinfo (Makefile.am): Likewise.
9742         * modules/getcwd (Makefile.am): Likewise.
9743         * modules/getdelim (Makefile.am): Likewise.
9744         * modules/getdomainname (Makefile.am): Likewise.
9745         * modules/getgroups (Makefile.am): Likewise.
9746         * modules/gethostname (Makefile.am): Likewise.
9747         * modules/gethrxtime (Makefile.am): Likewise.
9748         * modules/getline (Makefile.am): Likewise.
9749         * modules/getloadavg (Makefile.am): Likewise.
9750         * modules/getlogin_r (Makefile.am): Likewise.
9751         * modules/getndelim2 (Makefile.am): Likewise.
9752         * modules/getopt (Makefile.am): Likewise.
9753         * modules/getpagesize (Makefile.am): Likewise.
9754         * modules/getpass-gnu (Makefile.am): Likewise.
9755         * modules/getpass (Makefile.am): Likewise.
9756         * modules/getsubopt (Makefile.am): Likewise.
9757         * modules/gettime (Makefile.am): Likewise.
9758         * modules/gettimeofday (Makefile.am): Likewise.
9759         * modules/getugroups (Makefile.am): Likewise.
9760         * modules/getusershell (Makefile.am): Likewise.
9761         * modules/glob (Makefile.am): Likewise.
9762         * modules/group-member (Makefile.am): Likewise.
9763         * modules/hard-locale (Makefile.am): Likewise.
9764         * modules/hash (Makefile.am): Likewise.
9765         * modules/hmac-md5 (Makefile.am): Likewise.
9766         * modules/hmac-sha1 (Makefile.am): Likewise.
9767         * modules/human (Makefile.am): Likewise.
9768         * modules/idcache (Makefile.am): Likewise.
9769         * modules/imaxabs (Makefile.am): Likewise.
9770         * modules/imaxdiv (Makefile.am): Likewise.
9771         * modules/inet_ntop (Makefile.am): Likewise.
9772         * modules/inet_pton (Makefile.am): Likewise.
9773         * modules/intprops (Makefile.am): Likewise.
9774         * modules/inttostr (Makefile.am): Likewise.
9775         * modules/inttypes (Makefile.am): Likewise.
9776         * modules/isapipe (Makefile.am): Likewise.
9777         * modules/javaversion (Makefile.am): Likewise.
9778         * modules/lchmod (Makefile.am): Likewise.
9779         * modules/lchown (Makefile.am): Likewise.
9780         * modules/localcharset (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-p (Makefile.am): Likewise.
9802         * modules/mkdir (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/obstack (Makefile.am): Likewise.
9810         * modules/openat (Makefile.am): Likewise.
9811         * modules/pagealign_alloc (Makefile.am): Likewise.
9812         * modules/pathmax (Makefile.am): Likewise.
9813         * modules/physmem (Makefile.am): Likewise.
9814         * modules/poll (Makefile.am): Likewise.
9815         * modules/posixtm (Makefile.am): Likewise.
9816         * modules/posixver (Makefile.am): Likewise.
9817         * modules/putenv (Makefile.am): Likewise.
9818         * modules/quote (Makefile.am): Likewise.
9819         * modules/quotearg (Makefile.am): Likewise.
9820         * modules/raise (Makefile.am): Likewise.
9821         * modules/read-file (Makefile.am): Likewise.
9822         * modules/readline (Makefile.am): Likewise.
9823         * modules/readlink (Makefile.am): Likewise.
9824         * modules/readtokens (Makefile.am): Likewise.
9825         * modules/readutmp (Makefile.am): Likewise.
9826         * modules/realloc (Makefile.am): Likewise.
9827         * modules/regex (Makefile.am): Likewise.
9828         * modules/rename-dest-slash (Makefile.am): Likewise.
9829         * modules/rename (Makefile.am): Likewise.
9830         * modules/rijndael (Makefile.am): Likewise.
9831         * modules/rmdir (Makefile.am): Likewise.
9832         * modules/rpmatch (Makefile.am): Likewise.
9833         * modules/safe-read (Makefile.am): Likewise.
9834         * modules/safe-write (Makefile.am): Likewise.
9835         * modules/same-inode (Makefile.am): Likewise.
9836         * modules/same (Makefile.am): Likewise.
9837         * modules/save-cwd (Makefile.am): Likewise.
9838         * modules/savedir (Makefile.am): Likewise.
9839         * modules/setenv (Makefile.am): Likewise.
9840         * modules/settime (Makefile.am): Likewise.
9841         * modules/sha1 (Makefile.am): Likewise.
9842         * modules/sig2str (Makefile.am): Likewise.
9843         * modules/snprintf (Makefile.am): Likewise.
9844         * modules/stat-macros (Makefile.am): Likewise.
9845         * modules/stat-time (Makefile.am): Likewise.
9846         * modules/stdbool (Makefile.am): Likewise.
9847         * modules/stdint (Makefile.am): Likewise.
9848         * modules/stdlib-safer (Makefile.am): Likewise.
9849         * modules/stpcpy (Makefile.am): Likewise.
9850         * modules/stpncpy (Makefile.am): Likewise.
9851         * modules/strcase (Makefile.am): Likewise.
9852         * modules/strcasestr (Makefile.am): Likewise.
9853         * modules/strchrnul (Makefile.am): Likewise.
9854         * modules/strcspn (Makefile.am): Likewise.
9855         * modules/strdup (Makefile.am): Likewise.
9856         * modules/strerror (Makefile.am): Likewise.
9857         * modules/strftime (Makefile.am): Likewise.
9858         * modules/strndup (Makefile.am): Likewise.
9859         * modules/strnlen (Makefile.am): Likewise.
9860         * modules/strpbrk (Makefile.am): Likewise.
9861         * modules/strsep (Makefile.am): Likewise.
9862         * modules/strstr (Makefile.am): Likewise.
9863         * modules/strtod (Makefile.am): Likewise.
9864         * modules/strtoimax (Makefile.am): Likewise.
9865         * modules/strtok_r (Makefile.am): Likewise.
9866         * modules/strtol (Makefile.am): Likewise.
9867         * modules/strtoll (Makefile.am): Likewise.
9868         * modules/strtoul (Makefile.am): Likewise.
9869         * modules/strtoull (Makefile.am): Likewise.
9870         * modules/strtoumax (Makefile.am): Likewise.
9871         * modules/strverscmp (Makefile.am): Likewise.
9872         * modules/sys_socket (Makefile.am): Likewise.
9873         * modules/sys_stat (Makefile.am): Likewise.
9874         * modules/sysexits (Makefile.am): Likewise.
9875         * modules/time_r (Makefile.am): Likewise.
9876         * modules/timegm (Makefile.am): Likewise.
9877         * modules/timespec (Makefile.am): Likewise.
9878         * modules/tmpfile-safer (Makefile.am): Likewise.
9879         * modules/trim (Makefile.am): Likewise.
9880         * modules/unistd-safer (Makefile.am): Likewise.
9881         * modules/unlinkdir (Makefile.am): Likewise.
9882         * modules/unlocked-io (Makefile.am): Likewise.
9883         * modules/userspec (Makefile.am): Likewise.
9884         * modules/utime (Makefile.am): Likewise.
9885         * modules/utimecmp (Makefile.am): Likewise.
9886         * modules/utimens (Makefile.am): Likewise.
9887         * modules/vasnprintf (Makefile.am): Likewise.
9888         * modules/vasprintf (Makefile.am): Likewise.
9889         * modules/vsnprintf (Makefile.am): Likewise.
9890         * modules/xalloc (Makefile.am): Likewise.
9891         * modules/xgetcwd (Makefile.am): Likewise.
9892         * modules/xnanosleep (Makefile.am): Likewise.
9893         * modules/xreadlink (Makefile.am): Likewise.
9894         * modules/xstrtod (Makefile.am): Likewise.
9895         * modules/xstrtol (Makefile.am): Likewise.
9896         * modules/xstrtold (Makefile.am): Likewise.
9897         * modules/yesno (Makefile.am): Likewise.
9898         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
9899
9900 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
9901
9902         * modules/error (Makefile.am): Distribute files through
9903         EXTRA_DIST, not lib_SOURCES.
9904
9905 2006-10-12  Eric Blake  <ebb9@byu.net>
9906
9907         * modules/error (Makefile.am): Distribute files in /lib.
9908         * modules/obstack (Makefile.am): Likewise.
9909
9910 2006-10-12  Bruno Haible  <bruno@clisp.org>
9911
9912         * modules/acl (Makefile.am): Distribute all files in lib/ through
9913         EXTRA_DIST.
9914         * modules/arcfour (Makefile.am): Likewise.
9915         * modules/arctwo (Makefile.am): Likewise.
9916         * modules/argmatch (Makefile.am): Likewise.
9917         * modules/argz (Makefile.am): Likewise.
9918         * modules/atexit (Makefile.am): Likewise.
9919         * modules/backupfile (Makefile.am): Likewise.
9920         * modules/c-strtod (Makefile.am): Likewise.
9921         * modules/c-strtold (Makefile.am): Likewise.
9922         * modules/calloc (Makefile.am): Likewise.
9923         * modules/canon-host (Makefile.am): Likewise.
9924         * modules/canonicalize (Makefile.am): Likewise.
9925         * modules/chdir-long (Makefile.am): Likewise.
9926         * modules/chdir-safer (Makefile.am): Likewise.
9927         * modules/check-version (Makefile.am): Likewise.
9928         * modules/chown (Makefile.am): Likewise.
9929         * modules/cloexec (Makefile.am): Likewise.
9930         * modules/close-stream (Makefile.am): Likewise.
9931         * modules/closeout (Makefile.am): Likewise.
9932         * modules/crc (Makefile.am): Likewise.
9933         * modules/cycle-check (Makefile.am): Likewise.
9934         * modules/des (Makefile.am): Likewise.
9935         * modules/dirfd (Makefile.am): Likewise.
9936         * modules/dirname (Makefile.am): Likewise.
9937         * modules/dup2 (Makefile.am): Likewise.
9938         * modules/euidaccess (Makefile.am): Likewise.
9939         * modules/exclude (Makefile.am): Likewise.
9940         * modules/exitfail (Makefile.am): Likewise.
9941         * modules/fcntl-safer (Makefile.am): Likewise.
9942         * modules/file-type (Makefile.am): Likewise.
9943         * modules/fileblocks (Makefile.am): Likewise.
9944         * modules/filemode (Makefile.am): Likewise.
9945         * modules/filenamecat (Makefile.am): Likewise.
9946         * modules/fnmatch (Makefile.am): Likewise.
9947         * modules/fopen-safer (Makefile.am): Likewise.
9948         * modules/fpending (Makefile.am): Likewise.
9949         * modules/fprintftime (Makefile.am): Likewise.
9950         * modules/free (Makefile.am): Likewise.
9951         * modules/fsusage (Makefile.am): Likewise.
9952         * modules/ftruncate (Makefile.am): Likewise.
9953         * modules/fts (Makefile.am): Likewise.
9954         * modules/gc (Makefile.am): Likewise.
9955         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
9956         * modules/getaddrinfo (Makefile.am): Likewise.
9957         * modules/getcwd (Makefile.am): Likewise.
9958         * modules/getdelim (Makefile.am): Likewise.
9959         * modules/getdomainname (Makefile.am): Likewise.
9960         * modules/getgroups (Makefile.am): Likewise.
9961         * modules/gethostname (Makefile.am): Likewise.
9962         * modules/gethrxtime (Makefile.am): Likewise.
9963         * modules/getline (Makefile.am): Likewise.
9964         * modules/getloadavg (Makefile.am): Likewise.
9965         * modules/getlogin_r (Makefile.am): Likewise.
9966         * modules/getopt (Makefile.am): Likewise.
9967         * modules/getpass (Makefile.am): Likewise.
9968         * modules/getpass-gnu (Makefile.am): Likewise.
9969         * modules/getsubopt (Makefile.am): Likewise.
9970         * modules/gettime (Makefile.am): Likewise.
9971         * modules/gettimeofday (Makefile.am): Likewise.
9972         * modules/getugroups (Makefile.am): Likewise.
9973         * modules/getusershell (Makefile.am): Likewise.
9974         * modules/glob (Makefile.am): Likewise.
9975         * modules/group-member (Makefile.am): Likewise.
9976         * modules/hard-locale (Makefile.am): Likewise.
9977         * modules/hash (Makefile.am): Likewise.
9978         * modules/hmac-md5 (Makefile.am): Likewise.
9979         * modules/hmac-sha1 (Makefile.am): Likewise.
9980         * modules/human (Makefile.am): Likewise.
9981         * modules/idcache (Makefile.am): Likewise.
9982         * modules/imaxabs (Makefile.am): Likewise.
9983         * modules/imaxdiv (Makefile.am): Likewise.
9984         * modules/inet_ntop (Makefile.am): Likewise.
9985         * modules/inet_pton (Makefile.am): Likewise.
9986         * modules/inttostr (Makefile.am): Likewise.
9987         * modules/isapipe (Makefile.am): Likewise.
9988         * modules/lchown (Makefile.am): Likewise.
9989         * modules/long-options (Makefile.am): Likewise.
9990         * modules/lstat (Makefile.am): Likewise.
9991         * modules/malloc (Makefile.am): Likewise.
9992         * modules/mathl (Makefile.am): Likewise.
9993         * modules/mbchar (Makefile.am): Likewise.
9994         * modules/md2 (Makefile.am): Likewise.
9995         * modules/md4 (Makefile.am): Likewise.
9996         * modules/md5 (Makefile.am): Likewise.
9997         * modules/memcasecmp (Makefile.am): Likewise.
9998         * modules/memchr (Makefile.am): Likewise.
9999         * modules/memcmp (Makefile.am): Likewise.
10000         * modules/memcoll (Makefile.am): Likewise.
10001         * modules/memcpy (Makefile.am): Likewise.
10002         * modules/memmem (Makefile.am): Likewise.
10003         * modules/memmove (Makefile.am): Likewise.
10004         * modules/mempcpy (Makefile.am): Likewise.
10005         * modules/memrchr (Makefile.am): Likewise.
10006         * modules/memset (Makefile.am): Likewise.
10007         * modules/memxor (Makefile.am): Likewise.
10008         * modules/mkancesdirs (Makefile.am): Likewise.
10009         * modules/mkdir (Makefile.am): Likewise.
10010         * modules/mkdir-p (Makefile.am): Likewise.
10011         * modules/mkdtemp (Makefile.am): Likewise.
10012         * modules/mkstemp (Makefile.am): Likewise.
10013         * modules/mktime (Makefile.am): Likewise.
10014         * modules/modechange (Makefile.am): Likewise.
10015         * modules/mountlist (Makefile.am): Likewise.
10016         * modules/nanosleep (Makefile.am): Likewise.
10017         * modules/openat (Makefile.am): Likewise.
10018         * modules/pagealign_alloc (Makefile.am): Likewise.
10019         * modules/physmem (Makefile.am): Likewise.
10020         * modules/poll (Makefile.am): Likewise.
10021         * modules/posixtm (Makefile.am): Likewise.
10022         * modules/posixver (Makefile.am): Likewise.
10023         * modules/putenv (Makefile.am): Likewise.
10024         * modules/quote (Makefile.am): Likewise.
10025         * modules/quotearg (Makefile.am): Likewise.
10026         * modules/raise (Makefile.am): Likewise.
10027         * modules/read-file (Makefile.am): Likewise.
10028         * modules/readline (Makefile.am): Likewise.
10029         * modules/readlink (Makefile.am): Likewise.
10030         * modules/readtokens (Makefile.am): Likewise.
10031         * modules/readutmp (Makefile.am): Likewise.
10032         * modules/realloc (Makefile.am): Likewise.
10033         * modules/regex (Makefile.am): Likewise.
10034         * modules/rename (Makefile.am): Likewise.
10035         * modules/rename-dest-slash (Makefile.am): Likewise.
10036         * modules/rijndael (Makefile.am): Likewise.
10037         * modules/rmdir (Makefile.am): Likewise.
10038         * modules/rpmatch (Makefile.am): Likewise.
10039         * modules/safe-read (Makefile.am): Likewise.
10040         * modules/safe-write (Makefile.am): Likewise.
10041         * modules/same (Makefile.am): Likewise.
10042         * modules/save-cwd (Makefile.am): Likewise.
10043         * modules/savedir (Makefile.am): Likewise.
10044         * modules/setenv (Makefile.am): Likewise.
10045         * modules/settime (Makefile.am): Likewise.
10046         * modules/sha1 (Makefile.am): Likewise.
10047         * modules/sig2str (Makefile.am): Likewise.
10048         * modules/snprintf (Makefile.am): Likewise.
10049         * modules/stdlib-safer (Makefile.am): Likewise.
10050         * modules/stpcpy (Makefile.am): Likewise.
10051         * modules/stpncpy (Makefile.am): Likewise.
10052         * modules/strcase (Makefile.am): Likewise.
10053         * modules/strcasestr (Makefile.am): Likewise.
10054         * modules/strchrnul (Makefile.am): Likewise.
10055         * modules/strcspn (Makefile.am): Likewise.
10056         * modules/strdup (Makefile.am): Likewise.
10057         * modules/strerror (Makefile.am): Likewise.
10058         * modules/strftime (Makefile.am): Likewise.
10059         * modules/strndup (Makefile.am): Likewise.
10060         * modules/strnlen (Makefile.am): Likewise.
10061         * modules/strpbrk (Makefile.am): Likewise.
10062         * modules/strsep (Makefile.am): Likewise.
10063         * modules/strstr (Makefile.am): Likewise.
10064         * modules/strtod (Makefile.am): Likewise.
10065         * modules/strtoimax (Makefile.am): Likewise.
10066         * modules/strtok_r (Makefile.am): Likewise.
10067         * modules/strtol (Makefile.am): Likewise.
10068         * modules/strtoll (Makefile.am): Likewise.
10069         * modules/strtoul (Makefile.am): Likewise.
10070         * modules/strtoull (Makefile.am): Likewise.
10071         * modules/strtoumax (Makefile.am): Likewise.
10072         * modules/strverscmp (Makefile.am): Likewise.
10073         * modules/time_r (Makefile.am): Likewise.
10074         * modules/timegm (Makefile.am): Likewise.
10075         * modules/tmpfile-safer (Makefile.am): Likewise.
10076         * modules/unistd-safer (Makefile.am): Likewise.
10077         * modules/unlinkdir (Makefile.am): Likewise.
10078         * modules/userspec (Makefile.am): Likewise.
10079         * modules/utime (Makefile.am): Likewise.
10080         * modules/utimecmp (Makefile.am): Likewise.
10081         * modules/utimens (Makefile.am): Likewise.
10082         * modules/vasnprintf (Makefile.am): Likewise.
10083         * modules/vasprintf (Makefile.am): Likewise.
10084         * modules/vsnprintf (Makefile.am): Likewise.
10085         * modules/xalloc (Makefile.am): Likewise.
10086         * modules/xgetcwd (Makefile.am): Likewise.
10087         * modules/xnanosleep (Makefile.am): Likewise.
10088         * modules/xreadlink (Makefile.am): Likewise.
10089         * modules/xstrtod (Makefile.am): Likewise.
10090         * modules/xstrtol (Makefile.am): Likewise.
10091         * modules/xstrtold (Makefile.am): Likewise.
10092         * modules/yesno (Makefile.am): Likewise.
10093
10094 2006-10-12  Jim Meyering  <jim@meyering.net>
10095
10096         * m4/getloadavg.m4: Revert the change below.
10097
10098         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
10099         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
10100         fail with a symlink, which is what coreutils' ./bootstrap now
10101         creates by default.
10102
10103 2006-10-12  Bruno Haible  <bruno@clisp.org>
10104
10105         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
10106         mingw.
10107         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
10108         MSVC and mingw explicitly.
10109
10110 2006-10-11  Simon Josefsson  <jas@extundo.com>
10111             Bruno Haible  <bruno@clisp.org>
10112
10113         Add support for multiple gnulib-tool invocations in the scope of a
10114         single configure.ac file.
10115         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
10116         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
10117         with the same contents as the _LIBADD variable.
10118         (func_emit_initmacro_start, func_emit_initmacro_end,
10119         func_emit_initmacro_done): New functions.
10120         (func_import, func_create_testdir): Invoke them. Allow the identifiers
10121         gl_LIBOBJS and gl_LTLIBOBJS.
10122
10123 2006-10-11  Bruno Haible  <bruno@clisp.org>
10124
10125         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
10126         (func_create_testdir): Don't create po/Makefile.am, don't invoke
10127         autoreconf. Instead, invoke autopoint explicitly but move back the
10128         *.m4 files from gnulib.
10129
10130 2006-10-11  Bruno Haible  <bruno@clisp.org>
10131
10132         * gnulib-tool (func_usage): Make module names after --create-testdir
10133         optional.
10134         (func_create_testdir): If no module was specified, use nearly all
10135         modules.
10136
10137 2006-10-12  Jim Meyering  <jim@meyering.net>
10138
10139         Big performance improvement for fts-based tools that use FTS_NOSTAT.
10140         Avoid spurious inode-mismatch problems on non-POSIX file systems.
10141         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
10142         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
10143         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
10144         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
10145         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
10146         (fts_set_stat_required): New function.
10147         (fts_open): Defer the calls to fts_stat, if possible or requested.
10148         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
10149         into fts_stat itself.
10150         (fts_read): Perform any required (deferred) fts_stat call.
10151         (fts_build): Likewise, for the directory we're about to open and read.
10152         In the readdir loop, carefully decide whether each entry will require
10153         an eventual call to fts_stat, using dirent.d_type info if available.
10154         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
10155         a command line argument into this function.  Update all callers.
10156         Map a return value of FTS_DOT to FTS_D for a command line argument.
10157         * modules/fts (Depends-on): Add d-type.  Alphabetize.
10158         Thanks to Miklos Szeredi for his tenacity and for the initial
10159         bug report about "find" failing on a FUSE-based file system.
10160
10161         * lib/fts.c (fts_open): Use consistent indentation.
10162
10163 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
10164
10165         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
10166         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
10167         reported by Jim Meyering.  All uses of cache variables renamed
10168         to match Autoconf's.
10169         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
10170         the other one.
10171
10172         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
10173         Fix misspelling in diagnostic.
10174
10175 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
10176
10177         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
10178         defined.  Problem reported by Matthew Woehlke.
10179
10180         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
10181         Add support for Tandem NonStop R series.
10182         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
10183         Use new macro.
10184
10185         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
10186         (has_trailing_slash): Omit size arg; all callers changed.
10187         Omit 'inline', since it doesn't help performance and we'd
10188         need to configure it.
10189         Don't count //, ///, etc. as having a trailing slash.
10190         As a side effect, this removes a C99ism reported by Matthew Woehlke.
10191         (rpl_rename_dest_slash): On failure, use rename's errno rather
10192         than (in some cases) an incorrect or junk errno.
10193         Simplify code by removing need to compute length; this does
10194         cause it to make two passes instead of one over the file name,
10195         but it's worth it.
10196
10197         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
10198         change, since Autoconf's version may no longer be appropriate now
10199         that we are using CVS Autoconf's version.  Add support for Tandem.
10200
10201 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
10202             Bruno Haible  <bruno@clisp.org>
10203
10204         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
10205         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
10206         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
10207         gl_AC_TYPE_LONG_LONG.
10208
10209         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
10210         instead of HAVE_LONG_LONG.
10211         * lib/printf-args.c (printf_fetchargs): Likewise.
10212         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
10213         * lib/vasnprintf.c (VASNPRINTF): Likewise.
10214         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
10215         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
10216         gl_AC_TYPE_LONG_LONG.
10217
10218 2006-10-11  Bruno Haible  <bruno@clisp.org>
10219
10220         * m4/longlong.m4: Add comments.
10221         * m4/ulonglong.m4: Likewise.
10222
10223 2006-10-10  Bruno Haible  <bruno@clisp.org>
10224
10225         Make it possible to #define stpcpy, strdup to aliases.
10226         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
10227         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
10228
10229 2006-10-10  Bruno Haible  <bruno@clisp.org>
10230
10231         Make it possible to #define gcd to an alias.
10232         * lib/gcd.c: Include config.h.
10233
10234 2006-10-10  Bruno Haible  <bruno@clisp.org>
10235
10236         Make it possible to #define c_isascii to an alias.
10237         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
10238         defined. Undefine the macros before defining them, to avoid gcc
10239         warnings.
10240         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
10241         define NO_C_CTYPE_MACROS early.
10242
10243 2006-10-10  Bruno Haible  <bruno@clisp.org>
10244
10245         Make it possible to #define set_program_name to an alias.
10246         * lib/progname.c: Don't undefine set_program_name; instead, undefine
10247         ENABLE_RELOCATABLE early.
10248
10249 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
10250
10251         Port to Tandem NSK OSS, which has 64-bit signed int but at most
10252         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
10253         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
10254         More generally, don't assume that 64-bit signed int is available
10255         if unsigned int is, and vice versa.
10256         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
10257         unsigned symbols, not on their signed counterparts.
10258         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
10259         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
10260         (UINT64_C, UINTMAX_C):
10261         Likewise.
10262         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
10263         unsigned counterparts.
10264         (Have_long_long, Unsigned): New macros.
10265         (Int): Renamed from INT.
10266         (strtoimax): Use the new macros.
10267         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
10268         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
10269         * modules/inttypes (inttypes.h): Substitute
10270         HAVE_UNSIGNED_LONG_LONG_INT.
10271         * modules/stdint (stdint.h): Likewise.
10272         (Files): Add m4/ulonglong.m4.
10273
10274 2006-10-10  Bruno Haible  <bruno@clisp.org>
10275
10276         Fix a gcc -Wshadow warning.
10277         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
10278         to 'bucket'.
10279         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
10280         gl_linked_indexof_from_to): Likewise.
10281         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
10282         Likewise.
10283         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
10284         Likewise.
10285         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
10286         Reported by Eric Blake.
10287
10288 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
10289
10290         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
10291         for NetBSD.  Problem reported by Bruno Haible.
10292
10293 2006-10-09  Jim Meyering  <jim@meyering.net>
10294
10295         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
10296         Patch from Bruno Haible.
10297
10298 2006-10-09  Jim Meyering  <jim@meyering.net>
10299
10300         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
10301         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
10302         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
10303
10304 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
10305
10306         Don't include <config.h> twice; this doesn't work in some cases,
10307         e.g., when config.h has "#define intmax_t long long int" and
10308         we include <config.h>, <inttypes.h>, <config.h> in that order.
10309         Problem reported by Matthew Woehlke in:
10310         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
10311         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
10312         * lib/fts-cycle.c: Don't include config.h.
10313         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
10314         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
10315         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
10316         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
10317         inttypes.h.
10318         * lib/xstrtoumax.c: Likewise.
10319         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
10320         __strtol and the like, so that this module is more like its siblings.
10321         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
10322         Remove; no longer needed now that we assume gnulib inttypes.h.
10323
10324 2006-10-08  Bruno Haible  <bruno@clisp.org>
10325
10326         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
10327         option.
10328
10329 2006-10-07  Jim Meyering  <jim@meyering.net>
10330
10331         * modules/inttypes (inttypes.h): Revert what seems to have been
10332         an inadvertent part of today's change: use "|", not "/" in the
10333         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
10334
10335 2006-10-07  Bruno Haible  <bruno@clisp.org>
10336
10337         * modules/sublist: New file.
10338
10339 2006-10-07  Bruno Haible  <bruno@clisp.org>
10340
10341         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
10342         * modules/argz (argz.h): Likewise.
10343         * modules/arpa_inet (arpa/inet.h): Likewise.
10344         * modules/byteswap (byteswap.h): Likewise.
10345         * modules/configmake (configmake.h): Likewise.
10346         * modules/fcntl (fcntl.h): Likewise.
10347         * modules/fnmatch (fnmatch.h): Likewise.
10348         * modules/getopt (getopt.h): Likewise.
10349         * modules/glob (glob.h): Likewise.
10350         * modules/inttypes (inttypes.h): Likewise.
10351         * modules/netinet_in (netinet/in.h): Likewise.
10352         * modules/poll (poll.h): Likewise.
10353         * modules/stdbool (stdbool.h): Likewise.
10354         * modules/stdint (stdint.h): Likewise.
10355         * modules/sys_select (sys/select.h): Likewise.
10356         * modules/sys_socket (sys/socket.h): Likewise.
10357         * modules/sys_stat (sys/stat.h): Likewise.
10358         * modules/sysexits (sysexits.h): Likewise.
10359         * modules/unistd (unistd.h): Likewise.
10360         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
10361         Add a "DO NOT EDIT" comment to the generated file.
10362         (func_import): Likewise for gnulib-comp.m4.
10363
10364 2006-10-07  Bruno Haible  <bruno@clisp.org>
10365
10366         * lib/gl_sublist.h: New file.
10367         * lib/gl_sublist.c: New file.
10368
10369 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
10370
10371         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
10372         name (relative to the original working directory) and the file
10373         name component (relative to the temporary working directory).  All
10374         callers changed.
10375         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
10376         * lib/mkdir-p.c (make_dir_parents): Likewise.
10377         * lib/mkdir-p.h (make_dir_parents): Likewise.
10378
10379 2006-10-06  Eric Blake  <ebb9@byu.net>
10380
10381         Define several macros for use by the clean-temp module.
10382         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
10383         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
10384         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
10385
10386         * lib/clean-temp.h (close_stream_temp): New declaration.
10387         * lib/clean-temp.c (includes): Pull in headers according to what
10388         other modules are in use.
10389         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
10390
10391 2006-10-06  Bruno Haible  <bruno@clisp.org>
10392
10393         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
10394         instead of fopen, fwriteerror.
10395
10396 2006-10-06  Bruno Haible  <bruno@clisp.org>
10397
10398         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
10399         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
10400         int.
10401         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
10402         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
10403         Return an error indicator.
10404         Suggested by Eric Blake.
10405
10406 2006-10-06  Bruno Haible  <bruno@clisp.org>
10407
10408         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
10409         Reported by Eric Blake.
10410
10411 2006-10-06  Bruno Haible  <bruno@clisp.org>
10412
10413         * modules/closeout (Description): Mention stderr too.
10414
10415 2006-10-06  Bruno Haible  <bruno@clisp.org>
10416         and Paul Eggert  <eggert@cs.ucla.edu>
10417
10418         * lib/closeout.c (close_stdout): Also close stderr.
10419         * lib/closeout.h: Update comment.
10420
10421 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
10422
10423         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
10424         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
10425         * lib/dirchownmod.c: Include lchown.h.
10426         * lib/lchown.c: Don't include files that lchown.h now includes.
10427         Don't declare chown, since lchown.h now does that.
10428         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
10429         (lchown): Define to rpl_chown if lchown is declared but
10430         does not exist.  Declare using a prototype if lchown is not
10431         declared.  Add a copyright notice.
10432         * lib/mkstemp.h: Include <unistd.h>.
10433         * lib/openat.c: Include lchown.h.
10434
10435         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
10436         we now test for that separately.
10437         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
10438         rather than O_NOFOLLOW, when testing whether it's possible to
10439         avoid a race condition reliably.
10440         * lib/savewd.c (savewd_chdir): Likewise.
10441
10442         Remove macros that are no longer needed now that stdint.h is
10443         reliable.
10444         * lib/fsusage.c (UINTMAX_MAX): Remove.
10445         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
10446         * lib/utimecmp.c (SIZE_MAX): Remove.
10447
10448         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
10449
10450         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
10451         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
10452         O_NOATIME works.
10453
10454 2006-10-05  Bruno Haible  <bruno@clisp.org>
10455
10456         * lib/gl_list.h (gl_sortedlist_search_from_to,
10457         gl_sortedlist_indexof_from_to): New declarations.
10458         (gl_list_implementation): New fields sortedlist_search_from_to,
10459         sortedlist_indexof_from_to.
10460         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
10461         inline functions.
10462         * lib/gl_list.c (gl_sortedlist_search_from_to,
10463         gl_sortedlist_indexof_from_to): New functions.
10464         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
10465         function.
10466         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
10467         (gl_array_sortedlist_search_from_to): New function.
10468         (gl_array_list_implementation): Update.
10469         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
10470         function.
10471         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
10472         (gl_carray_sortedlist_search_from_to): New function.
10473         (gl_carray_list_implementation): Update.
10474         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
10475         gl_linked_sortedlist_indexof_from_to): New functions.
10476         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
10477         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
10478         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
10479         gl_tree_sortedlist_indexof_from_to): New functions.
10480         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
10481         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
10482         Update.
10483         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
10484         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
10485         Update.
10486
10487 2006-10-05  Bruno Haible  <bruno@clisp.org>
10488
10489         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
10490         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
10491         (struct gl_list_implementation): Add fields search_from_to,
10492         indexof_from_to. Remove fields search, indexof.
10493         (gl_list_search): Use the search_from_to method.
10494         (gl_list_search_from, gl_list_search_from_to): New functions.
10495         (gl_list_indexof): Use the indexof_from_to method.
10496         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
10497         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
10498         (gl_list_search_from, gl_list_search_from_to): New functions.
10499         (gl_list_indexof): Use the indexof_from_to method.
10500         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
10501         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
10502         gl_array_indexof. Add start_index, end_index arguments.
10503         (gl_array_search_from_to): Renamed from gl_array_search. Add
10504         start_index, end_index arguments.
10505         (gl_array_remove, gl_array_list_implementation): Update.
10506         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
10507         gl_carray_indexof. Add start_index, end_index arguments.
10508         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
10509         start_index, end_index arguments.
10510         (gl_carray_remove, gl_carray_list_implementation): Update.
10511         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
10512         gl_linked_search. Add start_index, end_index arguments.
10513         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
10514         start_index, end_index arguments.
10515         (gl_linked_remove): Update.
10516         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
10517         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
10518         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
10519         field to 'size_t'.
10520         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
10521         gl_tree_search. Add start_index, end_index arguments.
10522         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
10523         start_index, end_index arguments.
10524         (gl_tree_remove): Update.
10525         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
10526         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
10527         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
10528         function.
10529         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
10530         gl_tree_search. Add start_index, end_index arguments.
10531         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
10532         start_index, end_index arguments.
10533         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
10534         Update.
10535         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
10536
10537 2006-10-05  Bruno Haible  <bruno@clisp.org>
10538
10539         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
10540
10541         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
10542         fwriteerror_temp): New declarations.
10543         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
10544         (descriptors): New variable.
10545         (cleanup): First, close the descriptors.
10546         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
10547         fclose_temp, fwriteerror_temp): New functions.
10548
10549 2006-10-04  Jim Meyering  <jim@meyering.net>
10550
10551         * lib/fts.c (fts_open): Tiny comment change.
10552
10553 2006-10-04  Bruno Haible  <bruno@clisp.org>
10554
10555         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
10556         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
10557         gl_LOCK_BODY.
10558         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
10559         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
10560         gl_LOCK_EARLY_BODY.
10561         (gl_LOCK): Require gl_LOCK_BODY.
10562
10563 2006-10-04  Bruno Haible  <bruno@clisp.org>
10564
10565         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
10566         (gl_oset_search_atleast): New declaration.
10567         (struct gl_oset_implementation): Add field 'search_atleast'.
10568         (gl_oset_search_atleast): New inline function.
10569         * lib/gl_oset.c (gl_oset_search_atleast): New function.
10570         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
10571         (gl_array_oset_implementation): Update.
10572         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
10573         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
10574         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
10575
10576 2006-10-04  Bruno Haible  <bruno@clisp.org>
10577
10578         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
10579
10580 2006-10-03  Bruno Haible  <bruno@clisp.org>
10581
10582         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
10583         from gl_avltreehash_list_implementation.
10584
10585 2006-10-03  Bruno Haible  <bruno@clisp.org>
10586
10587         * lib/gl_oset.c (gl_oset_add): Fix return type.
10588
10589 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
10590
10591         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
10592
10593 2006-10-02  Eric Blake  <ebb9@byu.net>
10594
10595         * modules/strnlen (Depends-on): Add extensions.
10596
10597 2006-10-02  Eric Blake  <ebb9@byu.net>
10598
10599         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
10600         definition in 2.60+.
10601
10602 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
10603
10604         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
10605         checks.
10606
10607 2006-10-02  Bruno Haible  <bruno@clisp.org>
10608
10609         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
10610         to the AUTOMAKE_OPTIONS.
10611         Reported by Jim Meyering.
10612
10613 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
10614
10615         Work around bug in Solaris 10 /proc file system:
10616         /proc/self/fd/NNN/.. isn't the parent directory of
10617         the directory whose file descriptor is NNN.  This needs to
10618         be worked around at run time, not compile time, since a
10619         program might be built on Solaris 8, where things work, and
10620         run on Solaris 10.
10621         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
10622         to use the following interface instead:
10623         (OPENAT_BUFFER_SIZE): New macro.
10624         (openat_proc_name): New function.
10625         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
10626         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
10627         Likewise.
10628         * lib/openat-proc.c: New file.
10629         * modules/openat (Files): Add lib/openat-proc.c.
10630         (Depends-on): Add same-inode, stdbool.
10631         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
10632
10633 2006-09-29  Bruno Haible  <bruno@clisp.org>
10634
10635         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
10636         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
10637         argument. Set stdout_closed before testing for ferror, not after.
10638         (fwriteerror, fwriteerror_no_ebadf): New functions.
10639
10640 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10641
10642         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
10643
10644 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
10645
10646         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
10647         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
10648
10649 2006-09-28  Jim Meyering  <jim@meyering.net>
10650
10651         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
10652         Include <unistd.h>.
10653
10654 2006-09-28  Bruno Haible  <bruno@clisp.org>
10655
10656         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
10657         * modules/linkedhash-list (Depends-on): Likewise.
10658         * modules/rbtreehash-list (Depends-on): Likewise.
10659
10660 2006-09-28  Bruno Haible  <bruno@clisp.org>
10661
10662         * lib/strndup.h: Simplify the redefinition of strndup.
10663         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
10664         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
10665
10666 2006-09-28  Bruno Haible  <bruno@clisp.org>
10667
10668         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
10669         * lib/gl_linkedhash_list.c: Likewise.
10670         * lib/gl_rbtreehash_list.c: Likewise.
10671
10672 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
10673
10674         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
10675         getaddrinfo.
10676
10677         * lib/__fpending.h: Don't include <stdio_ext.h> unless
10678         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
10679         it causes <stdio_ext.h> to cause a compile-time error.
10680         Problem reported by Nelson H. F. Beebe.
10681         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
10682         of HAVE_DECL___PENDING.
10683
10684         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
10685         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
10686         declaration.
10687
10688 2006-09-27  Jim Meyering  <jim@meyering.net>
10689
10690         This file could end up with a definition for a function
10691         named __strndup, rather than rpl_strndup on a system with
10692         incomplete weak_alias support.
10693         * lib/strndup.c (strndup): Rename from __strndup.
10694         Remove #defines that used to map __strndup to strndup.
10695         Don't use K&R prototypes.
10696         Remove LIBC-related code, since this file is not sync'd with glibc.
10697         * lib/strndup.h: Revamp, accordingly.
10698         * m4/strndup.m4: Modernize.
10699
10700 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
10701
10702         * modules/savewd (Depends-on): Add 'raise'.
10703         * lib/savewd.c: Include <signal.h>, for 'raise'.
10704
10705 2006-09-26  Jim Meyering  <jim@meyering.net>
10706
10707         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
10708         when we detect Darwin 8.7.0's acl_get_file bug.
10709         Rearrange to perform the new (below) run-test while $LIBS
10710         contains any acl-related library.  Set USE_ACL at the end.
10711         (gl_ACL_GET_FILE): New function.
10712
10713 2006-09-26  Eric Blake  <ebb9@byu.net>
10714
10715         * lib/verror.c: Include <config.h> unconditionally.
10716
10717 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
10718
10719         * modules/clock-time (Maintainer): Add self.
10720         * modules/getlogin_r (Depends-on): Add extensions.
10721
10722 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10723
10724         * modules/clock-time: New module.
10725         * modules/nanosleep (Depends-on): Add clock-time.
10726         * modules/gethrxtime (Depends-on): Likewise.
10727         * modules/gettime (Depends-on): Likewise.
10728         * modules/settime (Depends-on): Likewise.
10729
10730         * modules/fts-lgpl: Depend on openat.
10731         * modules/mkancesdirs: Depend on savewd.
10732         * modules/mkdir-p: Likewise.
10733
10734 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10735
10736         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
10737
10738         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
10739         `gl_have_arbitrary_file_name_length_limit' to
10740         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
10741         actually works between configure runs.
10742
10743 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10744             Bruno Haible  <bruno@clisp.org>
10745
10746         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
10747
10748 2006-09-25  Jim Meyering  <jim@meyering.net>
10749
10750         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
10751         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
10752
10753 2006-09-25  Eric Blake  <ebb9@byu.net>
10754
10755         * gnulib-tool (func_import, func_create_testdir): Fix typos in
10756         exec's in 2006-09-18 patch when shuffling fds.
10757
10758 2006-09-25  Bruno Haible  <bruno@clisp.org>
10759
10760         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
10761         Reported by Jim Meyering.
10762
10763 2006-09-24  Jim Meyering  <jim@meyering.net>
10764
10765         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
10766         compare a pointer against a literal "0".  That caused failures with
10767         at least HP-UX's hpcc.
10768
10769 2006-09-22  Simon Josefsson  <jas@extundo.com>
10770
10771         * modules/gc-sha1:
10772         * modules/gc-md4:
10773         * modules/gc-hmac-sha1:
10774         * modules/gc-hmac-md5:
10775         * modules/gc-des:
10776         * modules/gc-arcfour: Distribute more files.
10777
10778 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10779
10780         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
10781         (gl_linked_iterator_from_to): Initialize struct completely.
10782         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
10783         (gl_tree_iterator_from_to): Likewise
10784         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
10785         * lib/gl_array_list.c [lint] (gl_array_iterator)
10786         (gl_array_iterator_from_to): Likewise.
10787         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
10788         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
10789         (gl_carray_iterator_from_to): Likewise.
10790
10791         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
10792         * lib/md4.c (md4_process_block): Remove unused variable.
10793         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
10794         parentheses for clarity.
10795
10796 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10797
10798         * modules/bison-i18n (Depends-on): Add gettext.
10799
10800 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10801
10802         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
10803         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
10804         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
10805         also add missing comma that caused broken test.
10806         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
10807         stdlib.h, for `abort'.
10808         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
10809         variables.
10810         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
10811         include unistd.h if present, for `rmdir'.
10812         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
10813         variables.
10814         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
10815         in the process include standard headers for prototypes.
10816         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
10817         gets declared on GNU/Linux.
10818         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
10819         unistd.h, for `rmdir'.
10820         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
10821
10822         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
10823         always true.
10824         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
10825
10826         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
10827
10828 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10829
10830         * gnulib-tool (func_version): Create output all at once.  This
10831         may help avoid triggering unnecessary SIGPIPEs, and at any
10832         rate it doesn't hurt.
10833
10834 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10835             Bruno Haible  <bruno@clisp.org>
10836
10837         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
10838         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
10839         * m4/signed.m4 (bh_C_SIGNED): Likewise.
10840
10841         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
10842         (gl_FUNC_VASPRINTF): Invoke it.
10843
10844 2006-09-22  Bruno Haible  <bruno@clisp.org>
10845
10846         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
10847         getloadavg.c as first argument.
10848
10849 2006-09-22  Bruno Haible  <bruno@clisp.org>
10850
10851         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
10852         at the beginning of the gl_INIT macro.
10853         * modules/getloadavg (configure.ac): Pass $gl_source_base to
10854         gl_GETLOADAVG.
10855
10856 2006-09-22  Bruno Haible  <bruno@clisp.org>
10857
10858         * gnulib-tool (func_create_megatestdir): Don't include the config-h
10859         module.
10860         Suggested by Ralf Wildenhues.
10861
10862 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
10863
10864         Import this patch from libc:
10865
10866         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
10867
10868         * lib/regex_internal.c (re_string_reconstruct): Handle
10869         offset < pstr->valid_raw_len && pstr->offsets_needed case.
10870         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
10871         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
10872         re_string_context_at.
10873
10874         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
10875         now requires it.
10876         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
10877         gl_REGEX now does it for us.
10878         (gl_REGEX): Add test taken from
10879         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
10880
10881         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
10882         Check that large offsets work.  Modernize Autoconf usages.
10883         Prefer "yes" to mean a good thing rather than a bad.
10884         Don't put "#define mkstemp" in config.h, as this might interfere
10885         with standard system headers that "#define mkstemp mkstemp64".
10886
10887         * modules/mkstemp (Depends-on): Add extensions, so that
10888         mkstemp is visible on some platforms.
10889         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
10890         (Include): Change to "mkstemp.h" from <stdlib.h>.
10891         (Files): Add mkstemp.h.
10892
10893         * lib/mkstemp.h: New file, since some standard headers
10894         #define mkstemp.
10895         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
10896         Include "mkstemp.h".
10897         Make the _LIBC code resemble glibc original more,
10898         e.g., use K&R style.
10899         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
10900         (mkstemp): Remove, since mkstemp.h does this for us.
10901         * lib/stdlib--.h: Include mkstemp.h.
10902
10903         Import this patch from libc:
10904
10905         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
10906
10907         * lib/tempname.c (__gen_tempname): Change attempts_min
10908         into a macro.  Use preprocessor to decide how to initialize
10909         attempts [Coverity CID 67].
10910
10911 2006-09-20  Bruno Haible  <bruno@clisp.org>
10912
10913         * lib/mkdtemp.c: Import from libc.
10914         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
10915                 * sysdeps/posix/tempname.c (__gen_tempname): Change
10916                 attempts_min into a macro.  Use preprocessor to decide how to
10917                 initialize attempts [Coverity CID 67].
10918         2001-11-27  Paul Eggert  <eggert@twinsun.com>
10919                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
10920                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
10921
10922 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10923
10924         * gnulib-tool (func_exit): New function, to allow to pass the
10925         exit status portably through the trap.  Use everywhere.
10926         (--help, --version): Signal a write error.
10927         (trap): catch SIGPIPE, for write errors.
10928         Exit at the end of the trap, with the correct exit status.
10929
10930 2006-09-19  Karl Berry  <karl@gnu.org>
10931
10932         * doc/gnulib.texi: note about the license texinfo files.
10933
10934 2006-09-19  Eric Blake  <ebb9@byu.net>
10935
10936         * gnulib-tool: Avoid space-tab.
10937
10938 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
10939
10940         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
10941         that prevented coreutils 6.1 from building.  Problem reported
10942         by Petter Reinholdtsen.
10943
10944 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
10945
10946         * gnulib-tool (avoidlist): Fix typo that broke options like
10947         --avoid=lock that are used by coreutils bootstrap.
10948
10949 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
10950
10951         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
10952         more systematically.
10953
10954 2006-09-18  Jim Meyering  <jim@meyering.net>
10955
10956         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
10957
10958 2006-09-18  Bruno Haible  <bruno@clisp.org>
10959
10960         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
10961
10962 2006-09-18  Bruno Haible  <bruno@clisp.org>
10963
10964         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
10965         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
10966         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
10967         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
10968         * m4/gettext.m4: Require autoconf >= 2.52.
10969         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
10970         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
10971         of gl_cv_header_inttypes_h.
10972
10973 2006-09-18  Bruno Haible  <bruno@clisp.org>
10974
10975         * lib/javaversion.c: Include configmake.h.
10976
10977 2006-09-18  Bruno Haible  <bruno@clisp.org>
10978
10979         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
10980         avoid that the while loops be executed in a subshell.
10981
10982 2006-09-18  Bruno Haible  <bruno@clisp.org>
10983
10984         * MODULES.html.sh (func_module): Break long lines.
10985         Suggested by Bruce Korb <bkorb@gnu.org>.
10986
10987 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10988
10989         Speed up by a factor of 1.12.
10990         * gnulib-tool (nl): New variable.
10991         (func_import): Rewrite include directive extraction to only read each
10992         directive once.
10993
10994 2006-09-17  Bruno Haible  <bruno@clisp.org>
10995
10996         * modules/javaversion (Makefile.am): Remove DEFS setting.
10997         (Depends-on): Add configmake, for PKGDATADIR definition.
10998
10999 2006-09-17  Bruno Haible  <bruno@clisp.org>
11000
11001         * gnulib-tool (func_create_testdir): Rewrite all files at once.
11002
11003 2006-09-17  Bruno Haible  <bruno@clisp.org>
11004
11005         * gnulib-tool (func_append): New function, stolen from libtool.m4.
11006         (func_modules_transitive_closure, func_modules_add_dummy,
11007         func_modules_to_filelist, func_import, func_create_testdir,
11008         func_create_megatestdir, ...): Use it wherever possible.
11009         Suggested by Ralf Wildenhues.
11010
11011 2006-09-16  Karl Berry  <karl@gnu.org>
11012
11013         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
11014         to avoid sectioning errors.
11015         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
11016         [ifinfo]: blank line after @center-ed titles.
11017         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
11018         Spell FSF address consistently with others.
11019         (These changes approved by rms.)
11020
11021 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11022
11023         Speed up by a factor of 1.61.
11024         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
11025         already checked module names again.
11026
11027 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11028
11029         Speed up by a factor of 1.13.
11030         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
11031         for new_files, and the input to func_add_or_update.
11032
11033 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11034
11035         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
11036         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
11037
11038 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
11039
11040         * modules/mkancesdirs (Depends-on): Add fcntl.
11041         * modules/savewd: New file.
11042         * MODULES.html.sh (File system functions): Add savewd.
11043
11044         * modules/configmake (Makefile.am): Add support for the
11045         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
11046
11047 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
11048
11049         * m4/savewd.m4: New file.
11050
11051 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
11052
11053         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
11054         (dirchownmod): New arg FD.  All callers changed.
11055         Use FD rather than opening the directory ourself, as opening is
11056         now the caller's responsibility.
11057         * lib/dirchownmod.h: Likewise.
11058         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
11059         hosts that require <sys/types.h> before <sys/stat.h>.  Include
11060         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
11061         (test_dir): Remove.
11062         (mkancesdirs): Return length of prefix of FILE that has already
11063         been made, or -2 if there is a child doing the work.  Redo
11064         algorithm so that it is O(N) rather than O(N**2).  Optimize away
11065         ".", and treat ".." specially since it might stray back into
11066         already-created areas.  Use a subprocess if necessary.  New arg
11067         WD; all users changed.  MAKE_DIR function should now return 1
11068         if it creates a directory that is not readable.  Return -2 if
11069         a child process is spun off.
11070         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
11071         Adjust signature to match code.
11072         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
11073         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
11074         all users changed.
11075         * lib/savewd.c, lib/savewd.h: New files.
11076
11077 2006-09-15  Jim Meyering  <jim@meyering.net>
11078
11079         * modules/rename-dest-slash: New module.
11080         * MODULES.html.sh (posix_compat): Add it here.
11081
11082         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
11083
11084 2006-09-15  Jim Meyering  <jim@meyering.net>
11085
11086         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
11087         file.
11088
11089         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
11090
11091 2006-09-15  Jim Meyering  <jim@meyering.net>
11092
11093         * lib/rename-dest-slash.c (has_trailing_slash): Use
11094         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
11095         (rpl_rename_dest_slash): Perform the cheaper trailing slash
11096         test before testing whether SRC is a directory.
11097         Suggestions from Bruno Haible.
11098
11099         Avoid a warning about an unused variable.
11100         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
11101         into the #ifdef block where it's used.
11102
11103         * lib/rename-dest-slash.c: New file.
11104
11105 2006-09-14  Bruno Haible  <bruno@clisp.org>
11106
11107         * lib/allocsa.c: Include <config.h> unconditionally.
11108         * lib/asnprintf.c: Likewise.
11109         * lib/asprintf.c: Likewise.
11110         * lib/c-strcasecmp.c: Likewise.
11111         * lib/c-strcasestr.c: Likewise.
11112         * lib/c-strncasecmp.c: Likewise.
11113         * lib/c-strstr.c: Likewise.
11114         * lib/classpath.c: Likewise.
11115         * lib/clean-temp.c: Likewise.
11116         * lib/concatpath.c: Likewise.
11117         * lib/copy-file.c: Likewise.
11118         * lib/csharpcomp.c: Likewise.
11119         * lib/csharpexec.c: Likewise.
11120         * lib/execute.c: Likewise.
11121         * lib/fatal-signal.c: Likewise.
11122         * lib/findprog.c: Likewise.
11123         * lib/fwriteerror.c: Likewise.
11124         * lib/gl_array_list.c: Likewise.
11125         * lib/gl_array_oset.c: Likewise.
11126         * lib/gl_avltree_list.c: Likewise.
11127         * lib/gl_avltree_oset.c: Likewise.
11128         * lib/gl_avltreehash_list.c: Likewise.
11129         * lib/gl_carray_list.c: Likewise.
11130         * lib/gl_linked_list.c: Likewise.
11131         * lib/gl_linkedhash_list.c: Likewise.
11132         * lib/gl_list.c: Likewise.
11133         * lib/gl_oset.c: Likewise.
11134         * lib/gl_rbtree_list.c: Likewise.
11135         * lib/gl_rbtree_oset.c: Likewise.
11136         * lib/gl_rbtreehash_list.c: Likewise.
11137         * lib/imaxabs.c: Likewise.
11138         * lib/imaxdiv.c: Likewise.
11139         * lib/javacomp.c: Likewise.
11140         * lib/javaexec.c: Likewise.
11141         * lib/javaversion.c: Likewise.
11142         * lib/linebreak.c: Likewise.
11143         * lib/localcharset.c: Likewise.
11144         * lib/lock.c: Likewise.
11145         * lib/mbchar.c: Likewise.
11146         * lib/mbswidth.c: Likewise.
11147         * lib/mkdtemp.c: Likewise.
11148         * lib/pipe.c: Likewise.
11149         * lib/printf-args.c: Likewise.
11150         * lib/printf-parse.c: Likewise.
11151         * lib/progname.c: Likewise.
11152         * lib/progreloc.c: Likewise.
11153         * lib/readlink.c: Likewise.
11154         * lib/sh-quote.c: Likewise.
11155         * lib/stpcpy.c: Likewise.
11156         * lib/stpncpy.c: Likewise.
11157         * lib/strcasecmp.c: Likewise.
11158         * lib/strcasestr.c: Likewise.
11159         * lib/strcspn.c: Likewise.
11160         * lib/striconv.c: Likewise.
11161         * lib/strncasecmp.c: Likewise.
11162         * lib/strnlen1.c: Likewise.
11163         * lib/strstr.c: Likewise.
11164         * lib/strtok_r.c: Likewise.
11165         * lib/tls.c: Likewise.
11166         * lib/tmpdir.c: Likewise.
11167         * lib/unicodeio.c: Likewise.
11168         * lib/unsetenv.c: Likewise.
11169         * lib/vasnprintf.c: Likewise.
11170         * lib/vasprintf.c: Likewise.
11171         * lib/wait-process.c: Likewise.
11172         * lib/xallocsa.c: Likewise.
11173         * lib/xsetenv.c: Likewise.
11174         * lib/xstriconv.c: Likewise.
11175
11176 2006-09-13  Simon Josefsson  <jas@extundo.com>
11177
11178         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
11179         that internally, suggested by Ralf Wildenhues
11180         <Ralf.Wildenhues@gmx.de>.
11181
11182 2006-09-13  Simon Josefsson  <jas@extundo.com>
11183
11184         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
11185         @LIBOBJS@.
11186         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
11187
11188 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
11189
11190         * lib/_fpending.c: Include <config.h> unconditionally, since we no
11191         longer worry about uses that don't define HAVE_CONFIG_H.
11192         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
11193         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
11194         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
11195         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
11196         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
11197         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
11198         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
11199         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
11200         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
11201         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
11202         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
11203         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
11204         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
11205         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
11206         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
11207         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
11208         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
11209         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
11210         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
11211         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
11212         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
11213         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
11214         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
11215         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
11216         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
11217         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
11218         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
11219         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
11220         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
11221         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
11222         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
11223         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
11224         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
11225         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
11226         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
11227         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
11228         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
11229         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
11230         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
11231         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
11232         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
11233         Likewise.
11234
11235 2006-09-13  Eric Blake  <ebb9@byu.net>
11236
11237         * lib/getopt.c: Fix typo in last commit.
11238
11239 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
11240
11241         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
11242         dgettext.
11243
11244 2006-09-12  Jim Meyering  <jim@meyering.net>
11245
11246         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
11247         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
11248         Reported by Nelson H. F. Beebe.
11249
11250 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
11251
11252         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
11253         program_invocation_name and program_invocation_short_name are
11254         initialized.
11255         * lib/argp-namefrob.h: Move declarations of program_invocation_name
11256         and program_invocation_short_name to argp.h, so they are visible
11257         to user programs.
11258         * lib/argp.h: Likewise
11259
11260 2006-09-10  Bruno Haible  <bruno@clisp.org>
11261
11262         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
11263         m4/inttypes_h.m4, m4/uintmax_t.m4.
11264
11265 2006-09-10  Bruno Haible  <bruno@clisp.org>
11266
11267         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
11268         gl_AC_TYPE_UINTMAX_T.
11269
11270 2006-09-10  Bruno Haible  <bruno@clisp.org>
11271
11272         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
11273
11274 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11275
11276         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
11277         convention.  Text proposed by Bruno Haible.
11278         (struct argp_option): Document the use of N_() wrappers.
11279
11280         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
11281         '\v', and translate the two parts separately, instead of feeding
11282         the whole string to gettext.  This allows to exclude
11283         '\v' from the strings visible to the translator by writing doc
11284         strings as N_("..") "\v" N_("..").
11285
11286 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
11287
11288         * config/srclist.txt: Undo latest change; the bug was fixed.
11289
11290 2006-09-09  Bruno Haible  <bruno@clisp.org>
11291
11292         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
11293         assignments if building a library without libtool.
11294         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
11295         in func_emit_lib_Makefile_am.
11296         (func_import): When building a static library libfoo.a, arrange to
11297         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
11298         (func_create_testdir): Likewise.
11299         * modules/gc (configure.ac, Makefile.am): If building statically,
11300         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
11301         * modules/iconvme (configure.ac, Makefile.am): Likewise.
11302         * modules/striconv (configure.ac, Makefile.am): Likewise.
11303         Based on a suggestion by Ralf Wildenhues.
11304
11305 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11306
11307         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
11308         Check for unistd.h too, since Autoconf doesn't assume POSIX.
11309         Also:
11310
11311         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11312         Add year_2050_test to catch glibc bug 2821
11313         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
11314
11315         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11316         Prefer #ifdef to #if.
11317
11318         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
11319         Return from 'main' instead of calling 'exit'.
11320
11321 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11322
11323         * lib/mktime.c (guess_time_tm): Fix bug where mktime
11324         returned the maximum time_t value rather than (time_t) -1.
11325         Problem originally reported by William Bardwell
11326         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
11327
11328         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
11329         Moved to here ...
11330         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
11331         ... from here.
11332
11333 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11334
11335         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
11336         2821 is fixed.
11337
11338 2006-09-08  Jim Meyering  <jim@meyering.net>
11339
11340         Don't make generated files read-only.  That would bother too many
11341         people.  However, do retain the ability to work when targets are
11342         read-only: remove the destination and temporary files before writing
11343         them (when generated via sed or echo), or by using the -f option for
11344         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
11345         * modules/alloca-opt, modules/argz, modules/arpa_inet:
11346         * modules/byteswap, modules/configmake, modules/fcntl:
11347         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
11348         * modules/localcharset, modules/netinet_in, modules/poll:
11349         * modules/stdbool, modules/stdint, modules/sys_select:
11350         * modules/sys_socket, modules/sys_stat, modules/sysexits:
11351
11352 2006-09-08  Jim Meyering  <jim@meyering.net>
11353
11354         Avoid new build failure on FreeBSD 6.0.
11355         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
11356         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
11357         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
11358
11359 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11360
11361         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
11362
11363 2006-09-07  Jim Meyering  <jim@meyering.net>
11364
11365         Fix global typo in last change: use chmod u-w, not chmod u-x.
11366         Spotted by Paul Eggert and Bruce Korb.
11367         * modules/alloca-opt, modules/argz, modules/arpa_inet:
11368         * modules/byteswap, modules/configmake, modules/fcntl:
11369         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
11370         * modules/localcharset, modules/netinet_in, modules/poll:
11371         * modules/stdbool, modules/stdint, modules/sys_select:
11372         * modules/sys_socket, modules/sys_stat, modules/sysexits:
11373
11374 2006-09-06  Jim Meyering  <jim@meyering.net>
11375
11376         Make generated files be read-only.
11377         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
11378         Ensure that each generated file is now read-only.
11379         * modules/argz: Likewise.
11380         * modules/arpa_inet: Likewise.
11381         * modules/byteswap: Likewise.
11382         * modules/configmake: Likewise.
11383         * modules/fcntl: Likewise.
11384         * modules/fnmatch: Likewise.
11385         * modules/getopt: Likewise.
11386         * modules/glob: Likewise.
11387         * modules/inttypes: Likewise.
11388         * modules/netinet_in: Likewise.
11389         * modules/poll: Likewise.
11390         * modules/stdbool: Likewise.
11391         * modules/stdint: Likewise.
11392         * modules/sys_select: Likewise.
11393         * modules/sys_socket: Likewise.
11394         * modules/sys_stat: Likewise.
11395         * modules/sysexits: Likewise.
11396         * modules/localcharset: Same as above, but continue using temporary
11397         file named "t-$@" (why different?) rather than the "$@-t" used
11398         everywhere else.
11399
11400         * modules/sysexits (Makefile.am): Replace literal occurrences
11401         of "sysexit.h" more readable, and more consistent, "$@".
11402
11403 2006-09-06  Bruno Haible  <bruno@clisp.org>
11404
11405         * modules/striconv: New file.
11406         * modules/xstriconv: New file.
11407         * MODULES.html.sh (Internationalization functions): Add striconv,
11408         xstriconv.
11409
11410 2006-09-06  Bruno Haible  <bruno@clisp.org>
11411
11412         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
11413         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
11414         not using libtool correctly.
11415
11416 2006-09-06  Bruno Haible  <bruno@clisp.org>
11417
11418         * lib/striconv.h: New file.
11419         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
11420         iconvstring.c.
11421         * lib/xstriconv.h: New file.
11422         * lib/xstriconv.c: New file.
11423
11424 2006-09-06  Bruno Haible  <bruno@clisp.org>
11425
11426         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
11427         lib_..._LDFLAGS.
11428
11429 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11430
11431         * lib/argz_.h: Sync from Libtool.
11432
11433         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
11434                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
11435
11436         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
11437
11438 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
11439
11440         * modules/trim: New file.
11441
11442 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
11443
11444         * lib/trim.h: New file.
11445         * lib/trim.c: New file.
11446
11447 2006-09-05  Bruno Haible  <bruno@clisp.org>
11448
11449         * MODULES.html.sh (String handling): Add trim.
11450
11451 2006-09-04  Karl Berry  <karl@gnu.org>
11452
11453         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
11454         until next release.
11455
11456 2006-09-03  Bruno Haible  <bruno@clisp.org>
11457
11458         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
11459         correctly.
11460
11461 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11462
11463         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
11464         not gl_GETLOADAVG.  Omit unneeded semicolons.
11465         Problems reported by Ralf Wildenhues in
11466         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
11467         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
11468         at the end, which is the usual gnulib style.
11469
11470         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
11471         of doing all the work ourselves.
11472         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
11473         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
11474
11475 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11476
11477         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
11478         Problem reported by Ralf Wildenhues in
11479         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
11480
11481         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
11482         HAVE_STRUCT_STATFS_F_FSTYPENAME.
11483
11484 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11485
11486         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
11487         yesterday's patch by changing test -n to test -z.
11488
11489 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11490
11491         * modules/getloadavg (Files): Add m4/getloadavg.m4.
11492         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
11493         the former is now obsolescent.
11494
11495         * modules/chdir-long (Depends-on): Add fcntl.
11496
11497 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11498
11499         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
11500         obsolescent, and programs should use gnulib instead.
11501         * m4/getloadavg.m4: New file, with contents taken from Autoconf
11502         but with prefixes changed.
11503
11504 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11505
11506         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
11507         or stdbool.h, because they might not exist while configuring.
11508
11509         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
11510         Don't include unistd.h or limits.h; not needed, since chdir-long.h
11511         does that for us.
11512         (O_DIRECTORY): Remove.
11513
11514 2006-08-31  Eric Blake  <ebb9@byu.net>
11515
11516         * gnulib-tool: Don't let emacs change spaces to TAB.
11517
11518 2006-08-31  Bruno Haible  <bruno@clisp.org>
11519
11520         * gnulib-tool: When calling func_import more than once, do it in a
11521         subshell.
11522         Reported by Eric Blake <ebb9@byu.net>.
11523
11524 2006-08-31  Bruno Haible  <bruno@clisp.org>
11525
11526         * gnulib-tool (nl): Remove variable.
11527         (sed_transform_lib_file): Use more robust test for config-h module.
11528         (func_import): Fix typo in 2006-08-25 patch.
11529
11530 2006-08-31  Bruno Haible  <bruno@clisp.org>
11531
11532         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
11533         specified, augment Makefile.am variables instead of assigning them.
11534
11535 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11536
11537         Work around a bug in both the Linux and SunOS 64-bit kernels:
11538         nanosleep mishandles sleeps for longer than 2**31 seconds.
11539         Problem reported by Frank v Waveren in
11540         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
11541         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
11542         Check for nanosleep bug.
11543         (LIB_NANOSLEEP): Append clock_gettime library if needed.
11544
11545 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11546
11547         Work around a bug in both the Linux and SunOS 64-bit kernels:
11548         nanosleep mishandles sleeps for longer than 2**31 seconds.
11549         Problem reported by Frank v Waveren in
11550         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
11551         * lib/nanosleep.c (BILLION): New constant.
11552         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
11553         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
11554         implementation.
11555
11556 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11557
11558         * modules/nanosleep (Depends-on): Add gettime.
11559
11560 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11561         and Simon Josefsson  <jas@extundo.com>
11562         and Oskar Liljeblad  <oskar@osk.mine.nu>
11563
11564         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
11565         * gnulib-tool (func_import): New license type 'unmodifiable license
11566         text'.
11567         * modules/fdl: Use it.  Longer description.
11568         * module/gpl, module/lgpl: New files.
11569
11570 2006-08-30  Jim Meyering  <jim@meyering.net>
11571
11572         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
11573         shadowing the parameter.
11574
11575 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11576
11577         Sync from Libtool:
11578
11579         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11580
11581         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
11582         sharing with gnulib.  Report by Eric Blake.
11583
11584 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11585
11586         * modules/isapipe: New file.
11587         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
11588
11589 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11590
11591         * modules/configmake (Makefile.am): Add a comment, and omit
11592         the CONFIGMAKE_ prefix from generated macro names.  Suggested
11593         by Bruno Haible.
11594
11595 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11596
11597         * m4/isapipe.m4: New file.
11598
11599 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11600
11601         * lib/isapipe.c, lib/isapipe.h: New files.
11602
11603 2006-08-29  Jim Meyering  <jim@meyering.net>
11604
11605         * modules/configmake (Makefile.am): Make configmake.h depend on
11606         Makefile.  Otherwise, a stale configmake.h could hang around.
11607
11608 2006-08-29  Eric Blake  <ebb9@byu.net>
11609
11610         * lib/error.c (error_at_line, print_errno_message): Match libc, after
11611         resolution of upstream bug 3044.
11612
11613 2006-08-29  Bruno Haible  <bruno@clisp.org>
11614
11615         * modules/localcharset (Depends-on): Add configmake.
11616         (Makefile.am): Remove setting of LIBDIR through DEFS.
11617
11618 2006-08-29  Bruno Haible  <bruno@clisp.org>
11619
11620         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
11621         defined.
11622
11623 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11624
11625         * modules/fcntl: New file.
11626         * modules/chdir-safer (Depends-on): Add fcntl.
11627         * modules/fts: Likewise.
11628         * modules/mkdir-p: Likewise.
11629
11630         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
11631         This undoes the most recent change, since we're now addressing the
11632         problem in a different way.
11633
11634         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
11635         into output, since the output might be called Makefile.am even
11636         if $makefile_name is something different.
11637         (func_import): Use $makefile_am rather than
11638         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
11639         empty.
11640
11641         * modules/inttypes (Files): Add m4/inttypes-h.m4.
11642
11643 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11644
11645         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
11646         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
11647         recent change to stdint.m4, since we're now addressing the problem in a
11648         different way.
11649
11650 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11651
11652         * m4/fcntl_h.m4: New file.
11653
11654 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11655
11656         * lib/fcntl_.h: New file.
11657         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
11658         the fcntl module.
11659         * lib/dirchownmod.c: Likewise.
11660         * lib/fts.c: Likewise.
11661
11662         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
11663         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
11664         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
11665         just before including <inttypes.h>, to avoid circular inclusion.
11666
11667 2006-08-28  Jim Meyering  <jim@meyering.net>
11668
11669         * doc/visibility.texi: Actually read and correct the grammar of the
11670         sentence affected by yesterday's change.
11671
11672 2006-08-28  Eric Blake  <ebb9@byu.net>
11673
11674         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
11675         needs wrapper.
11676
11677 2006-08-28  Eric Blake  <ebb9@byu.net>
11678
11679         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
11680
11681 2006-08-28  Eric Blake  <ebb9@byu.net>
11682
11683         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
11684
11685 2006-08-28  Bruno Haible  <bruno@clisp.org>
11686
11687         * modules/c-strstr: New file, from GNU gettext.
11688         * MODULES.html.sh (String handling): Add c-strstr.
11689
11690 2006-08-28  Bruno Haible  <bruno@clisp.org>
11691
11692         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
11693         macros.
11694         Reported by Eric Blake.
11695
11696 2006-08-28  Bruno Haible  <bruno@clisp.org>
11697
11698         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
11699         (VASNPRINTF): Return a string of length > INT_MAX without failing.
11700         * lib/vasprintf.c: Include errno.h, limits.h.
11701         (EOVERFLOW): New fallback definition.
11702         (vasprintf): Test here whether the string length is > INT_MAX.
11703         * lib/vsnprintf.c: Include errno.h, limits.h.
11704         (EOVERFLOW): New fallback definition.
11705         (vsnprintf): Fix bug when generated string was too long for the buffer.
11706         Test here whether the string length is > INT_MAX.
11707
11708 2006-08-28  Bruno Haible  <bruno@clisp.org>
11709
11710         * lib/inttypes_.h (SCNX*): Remove definitions.
11711         Reported by Eric Blake.
11712
11713 2006-08-28  Bruno Haible  <bruno@clisp.org>
11714
11715         * lib/c-strstr.h: New file, from GNU gettext.
11716         * lib/c-strstr.c: New file, from GNU gettext.
11717
11718 2006-08-28  Bruno Haible  <bruno@clisp.org>
11719
11720         * gnulib-tool: Reorder some statements.
11721
11722 2006-08-28  Bruno Haible  <bruno@clisp.org>
11723
11724         * gnulib-tool: New option --makefile-name.
11725         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
11726         $makefile_name.
11727         (func_import): Write $makefile_name to the cache file, and read it from
11728         there unless explicitly specified. Use $makefile_name as file name
11729         instead of Makefile.am. Adjust the recommendations accordingly.
11730
11731 2006-08-28  Bruno Haible  <bruno@clisp.org>
11732
11733         * gnulib-tool (func_verify_module): Check against misapplying patch.
11734
11735 2006-08-28  Bruno Haible  <bruno@clisp.org>
11736
11737         * gnulib-tool (func_relativize, func_relconcat): New functions.
11738         Give an error if --local-dir is given with --update.
11739         Remove trailing slashes from $local_gnulib_dir.
11740         (func_import): Store the relativized $local_gnulib_dir in
11741         gnulib-cache.m4, and read it from there if not specified explicitly.
11742
11743 2006-08-28  Bruno Haible  <bruno@clisp.org>
11744
11745         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
11746         is the current directory. Respect also $local_gnulib_dir.
11747
11748 2006-08-28  Bruno Haible  <bruno@clisp.org>
11749             Simon Josefsson  <jas@extundo.com>
11750
11751         BeOS portability.
11752         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
11753
11754 2006-08-27  Jim Meyering  <jim@meyering.net>
11755
11756         * doc/visibility.texi: Remove duplicate word: "pointer".
11757
11758 2006-08-26  Bruno Haible  <bruno@clisp.org>
11759
11760         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
11761         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
11762         (Makefile.am): Create inttypes.h from inttypes_.h.
11763         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
11764
11765         * modules/imaxabs: New file.
11766
11767         * modules/imaxdiv: New file.
11768
11769 2006-08-26  Bruno Haible  <bruno@clisp.org>
11770
11771         * m4/inttypes.m4: New file.
11772         * m4/_inttypes_h.m4: Remove file.
11773         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
11774         PRI_MACROS_BROKEN.
11775         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
11776
11777         * m4/imaxabs.m4: New file.
11778
11779         * m4/imaxdiv.m4: New file.
11780
11781 2006-08-26  Bruno Haible  <bruno@clisp.org>
11782
11783         * lib/inttypes_.h: New file.
11784         * lib/inttypes.h: Remove file.
11785         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
11786
11787         * lib/imaxabs.c: New file.
11788
11789         * lib/imaxdiv.c: New file.
11790
11791 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11792
11793         New config-h module, so that "make" output needn't be cluttered
11794         by -DHAVE_CONFIG_H.
11795         * MODULES.html.sh (Support for building libraries and executables):
11796         Add config-h.
11797         * modules/config-h: New file.
11798         * gnulib-tool (nl, sed_transform_lib_file): New vars.
11799         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
11800         the config-h module is used.
11801
11802         New configmake module, so that "make" output needn't be cluttered
11803         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
11804         * MODULES.html.sh (Support for building libraries and executables):
11805         Add configmake.
11806         * modules/configmake: New file.
11807
11808 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11809
11810         * m4/config-h.m4: New file.
11811
11812 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11813
11814         * config/srclist.txt: Add elisp-comp.
11815
11816 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11817
11818         * MODULES.html.sh (Support for building libraries and executables):
11819         Add elisp-comp.
11820         * build-aux/elisp-comp: New file.
11821         * modules/elisp-comp: New file.
11822
11823 2006-08-24  Bruno Haible  <bruno@clisp.org>
11824
11825         * gnulib-tool (func_create_testdir): Use non-default values of
11826         sourcebase and m4base.
11827
11828 2006-08-24  Bruno Haible  <bruno@clisp.org>
11829
11830         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
11831         HTML structure.
11832
11833 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11834
11835         * modules/openat (Depends-on): Add lchown.
11836
11837 2006-08-23  Bruno Haible  <bruno@clisp.org>
11838
11839         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
11840         of gl_LOCK_EARLY instead of gl_LOCK.
11841
11842 2006-08-23  Bruno Haible  <bruno@clisp.org>
11843
11844         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
11845         on OSF/1 to no.
11846         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
11847
11848 2006-08-23  Bruno Haible  <bruno@clisp.org>
11849
11850         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
11851         as unusable.
11852
11853         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
11854         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
11855         (gl_LOCK): New macro.
11856
11857 2006-08-22  Simon Josefsson  <jas@extundo.com>
11858
11859         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
11860         to md5 module.
11861
11862 2006-08-22  Simon Josefsson  <jas@extundo.com>
11863
11864         * MODULES.html.sh: Add "Support for maintaining and release
11865         projects".
11866
11867         * build-aux/gnupload: New file, from coreutils.
11868
11869 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11870
11871         Avoid the need for AC_LIBSOURCES in m4 macros.
11872         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
11873         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
11874         * modules/check-version (EXTRA_DIST): Add check-version.h.
11875         * modules/crc (EXTRA_DIST): Add crc.h.
11876         * modules/des (EXTRA_DIST): Add des.h.
11877         * modules/gc (EXTRA_DIST): Add gc.h.
11878         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
11879         * modules/getline (EXTRA_DIST): Add getline.h.
11880         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
11881         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
11882         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
11883         * modules/md2 (EXTRA_DIST): Add md2.h.
11884         * modules/md4 (EXTRA_DIST): Add md4.h.
11885         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
11886         * modules/read-file (EXTRA_DIST): Add read-file.h.
11887         * modules/readline (EXTRA_DIST): Add readline.h.
11888         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
11889         rijndael-api-fst.h.
11890
11891 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11892
11893         * m4/rijndael.m4 (gl_ARCFOUR):
11894         * m4/arctwo.m4 (gl_ARCTWO):
11895         * m4/check-version.m4 (gl_CHECK_VERSION):
11896         * m4/crc.m4 (gl_CRC):
11897         * m4/des.m4 (gl_DES):
11898         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
11899         * m4/gc.m4 (gl_GC):
11900         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
11901         * m4/getline.m4 (gl_FUNC_GETLINE):
11902         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
11903         * m4/hmac-md5.m4 (gl_HMAC_MD5):
11904         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
11905         * m4/md2.m4 (gl_MD2):
11906         * m4/md4.m4 (gl_MD4):
11907         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
11908         * m4/read-file.m4 (gl_FUNC_READ_FILE):
11909         * m4/readline.m4 (gl_FUNC_READLINE):
11910         * m4/rijndael.m4 (gl_RIJNDAEL):
11911         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
11912         to get the necessary .h files and whatnot.
11913
11914 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11915
11916         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
11917         gnulib rather than the other way around.
11918         * config/srclistvars.sh (COREUTILS): Remove.
11919
11920 2006-08-22  Jim Meyering  <jim@meyering.net>
11921
11922         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
11923
11924         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
11925
11926 2006-08-22  Eric Blake  <ebb9@byu.net>
11927
11928         * modules/regexprops-generic: New file.
11929         * MODULES.html.sh (Support for building documentation): List it.
11930
11931 2006-08-22  Eric Blake  <ebb9@byu.net>
11932
11933         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
11934         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
11935         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
11936         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
11937
11938 2006-08-22  Bruno Haible  <bruno@clisp.org>
11939
11940         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
11941         and lib_LTLIBRARIES like the other lib_* variables.
11942
11943 2006-08-22  Bruno Haible  <bruno@clisp.org>
11944
11945         * build-aux/x-to-1.in: New file, from GNU gettext.
11946
11947 2006-08-22  Bruno Haible  <bruno@clisp.org>
11948
11949         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
11950         <utmpx.h> exists.
11951
11952 2006-08-22  Bruno Haible  <bruno@clisp.org>
11953
11954         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
11955         <utmpx.h> exists.
11956
11957 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11958
11959         BeOS portability.
11960         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
11961         exist.
11962         Problem reported by Bruno Haible.
11963
11964 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
11965
11966         Avoid the need for AC_LIBSOURCES in m4 macros.
11967         * modules/acl (EXTRA_DIST): Add acl.h.
11968         * modules/argmatch (Files): Add m4/argmatch.m4.
11969         (configure.ac): Add gl_ARGMATCH.
11970         (EXTRA_DIST): Renamed from lib_SOURCES, for
11971         consistency with the other modules.  Remove argmatch.c.
11972         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
11973         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
11974         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
11975         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
11976         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
11977         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
11978         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
11979         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
11980         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
11981         * modules/closeout (EXTRA_DIST): Add closeout.h.
11982         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
11983         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
11984         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
11985         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
11986         dirname.h; remove basename.c and stripslash.c.
11987         * modules/exclude (EXTRA_DIST): Add exclude.h.
11988         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
11989         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
11990         * modules/file-type (EXTRA_DIST): Add file-type.h.
11991         * modules/filemode (EXTRA_DIST): Add filemode.h.
11992         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
11993         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
11994         * modules/fpending (EXTRA_DIST): Add __fpending.h.
11995         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
11996         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
11997         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
11998         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
11999         * modules/getdate (EXTRA_DIST): Add getdate.c.
12000         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
12001         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
12002         * modules/getpass (EXTRA_DIST): Add getpass.h.
12003         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
12004         * modules/group-member (EXTRA_DIST): Add group-member.h.
12005         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
12006         * modules/hash (EXTRA_DIST): Add hash.h.
12007         * modules/human (EXTRA_DIST): Add human.h.
12008         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
12009         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
12010         * modules/lchown (EXTRA_DIST): Add lchown.h.
12011         * modules/long-options (EXTRA_DIST): Add long-options.h.
12012         * modules/lstat (EXTRA_DIST): Add lstat.h.
12013         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
12014         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
12015         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
12016         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
12017         * modules/memxor (EXTRA_DIST): Add memxor.h.
12018         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
12019         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
12020         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
12021         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
12022         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
12023         * modules/physmem (EXTRA_DIST): Add physmem.h.
12024         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
12025         * modules/posixver (EXTRA_DIST): Add posixver.h.
12026         * modules/quote (EXTRA_DIST): Add quote.h.
12027         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
12028         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
12029         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
12030         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
12031         regex_internal.h regexec.c.
12032         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
12033         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
12034         * modules/same (EXTRA_DIST): Add same.h.
12035         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
12036         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
12037         * modules/savedir (EXTRA_DIST): Add savedir.h.
12038         * modules/sha1 (EXTRA_DIST): Add sha1.h.
12039         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
12040         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
12041         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
12042         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
12043         * modules/strdup (EXTRA_DIST): Add strdup.h.
12044         * modules/strftime (EXTRA_DIST): Add strftime.h.
12045         * modules/strndup (EXTRA_DIST): Add strndup.h.
12046         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
12047         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
12048         * modules/time_r (EXTRA_DIST): Add time_r.h.
12049         * modules/timespec (EXTRA_DIST): Add timespec.h.
12050         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
12051         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
12052         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
12053         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
12054         * modules/userspec (EXTRA_DIST): Add userspec.h.
12055         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
12056         * modules/utimens (EXTRA_DIST): Add utimens.h.
12057         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
12058         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
12059         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
12060         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
12061         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
12062         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
12063         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
12064         * modules/yesno (EXTRA_DIST): Add yesno.h.
12065
12066 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
12067
12068         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
12069
12070         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
12071         * m4/dev-ino.m4, same-inode.m4: Remove.
12072
12073         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
12074         * m4/acl.m4 (AC_FUNC_ACL):
12075         * m4/backupfile.m4 (gl_BACKUPFILE):
12076         * m4/c-strtod.m4 (gl_C99_STRTOLD):
12077         * m4/canon-host.m4 (gl_CANON_HOST):
12078         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
12079         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
12080         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
12081         * m4/cloexec.m4 (gl_CLOEXEC):
12082         * m4/close-stream.m4 (gl_CLOSE_STREAM):
12083         * m4/closeout.m4 (gl_CLOSEOUT):
12084         * m4/dirfd.m4 (gl_FUNC_DIRFD):
12085         * m4/dirname.m4 (gl_DIRNAME):
12086         * m4/exclude.m4 (gl_EXCLUDE):
12087         * m4/exitfail.m4 (gl_EXITFAIL):
12088         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
12089         * m4/file-type.m4 (gl_FILE_TYPE):
12090         * m4/filemode.m4 (gl_FILEMODE):
12091         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
12092         * m4/fpending.m4 (gl_FUNC_FPENDING):
12093         * m4/fprintftime.m4 (gl_FPRINTFTIME):
12094         * m4/fts.m4 (gl_FUNC_FTS):
12095         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
12096         * m4/getdate.m4 (gl_GETDATE):
12097         * m4/gethrxtime.m4 (gl_GETHRXTIME):
12098         * m4/getpagesize.m4 (gl_GETPAGESIZE):
12099         * m4/getpass.m4 (gl_FUNC_GETPASS):
12100         * m4/gettime.m4 (gl_GETTIME):
12101         * m4/getugroups.m4 (gl_GETUGROUPS):
12102         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
12103         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
12104         * m4/hard-locale.m4 (gl_HARD_LOCALE):
12105         * m4/hash.m4 (gl_HASH):
12106         * m4/idcache.m4 (gl_IDCACHE):
12107         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
12108         * m4/lchown.m4 (gl_FUNC_LCHOWN):
12109         * m4/long-options.m4 (gl_LONG_OPTIONS):
12110         * m4/lstat.m4 (gl_FUNC_LSTAT):
12111         * m4/md5.m4 (gl_MD5):
12112         * m4/memcasecmp.m4 (gl_MEMCASECMP):
12113         * m4/memcoll.m4 (gl_MEMCOLL):
12114         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
12115         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
12116         * m4/memxor.m4 (gl_MEMXOR):
12117         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
12118         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
12119         * m4/modechange.m4 (gl_MODECHANGE):
12120         * m4/mountlist.m4 (gl_MOUNTLIST):
12121         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
12122         * m4/openat.m4 (gl_FUNC_OPENAT):
12123         * m4/pathmax.m4 (gl_PATHMAX):
12124         * m4/physmem.m4 (gl_PHYSMEM):
12125         * m4/posixtm.m4 (gl_POSIXTM):
12126         * m4/posixver.m4 (gl_POSIXVER):
12127         * m4/quote.m4 (gl_QUOTE):
12128         * m4/quotearg.m4 (gl_QUOTEARG):
12129         * m4/readtokens.m4 (gl_READTOKENS):
12130         * m4/readutmp.m4 (gl_READUTMP):
12131         * m4/regex.m4 (gl_REGEX):
12132         * m4/safe-read.m4 (gl_SAFE_READ):
12133         * m4/safe-write.m4 (gl_SAFE_WRITE):
12134         * m4/same.m4 (gl_SAME):
12135         * m4/save-cwd.m4 (gl_SAVE_CWD):
12136         * m4/savedir.m4 (gl_SAVEDIR):
12137         * m4/settime.m4 (gl_SETTIME):
12138         * m4/sha1.m4 (gl_SHA1):
12139         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
12140         * m4/stat-macros.m4 (gl_STAT_MACROS):
12141         * m4/stat-time.m4 (gl_STAT_TIME):
12142         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
12143         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
12144         * m4/strdup.m4 (gl_FUNC_STRDUP):
12145         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
12146         * m4/strndup.m4 (gl_FUNC_STRNDUP):
12147         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
12148         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
12149         * m4/time_r.m4 (gl_TIME_R):
12150         * m4/timespec.m4 (gl_TIMESPEC):
12151         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
12152         * m4/unlinkdir.m4 (gl_UNLINKDIR):
12153         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
12154         * m4/userspec.m4 (gl_USERSPEC):
12155         * m4/utimecmp.m4 (gl_UTIMECMP):
12156         * m4/utimens.m4 (gl_UTIMENS):
12157         * m4/xalloc.m4 (gl_XALLOC):
12158         * m4/xgetcwd.m4 (gl_XGETCWD):
12159         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
12160         * m4/xreadlink.m4 (gl_XREADLINK):
12161         * m4/xstrtod.m4 (gl_XSTRTOD):
12162         * m4/yesno.m4 (gl_YESNO):
12163         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
12164         to get the necessary .h files and whatnot.
12165
12166 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
12167             Bruno Haible  <bruno@clisp.org>
12168
12169         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
12170         /bin/sh understanding of '!' conditional negation.
12171
12172 2006-08-21  Jim Meyering  <jim@meyering.net>
12173
12174         * modules/openat (Depends-on): Really alphabetize.
12175
12176         * modules/acl (Depends-on): Add error and quote.
12177
12178         * check-module (find_included_lib_files): Add at-func.c to the
12179         ok-to-include-more-than-once white list.
12180
12181         * modules/openat (Depends-on): Add lstat.  Alphabetize.
12182
12183 2006-08-21  Bruno Haible  <bruno@clisp.org>
12184
12185         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12186         Emit a pkgdata_DATA variable only if some snippets add contents to it.
12187         Reported by Martin Lambers <marlam@marlam.de>.
12188
12189 2006-08-21  Bruno Haible  <bruno@clisp.org>
12190
12191         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
12192         specify an installation location, don't emit a noinst_LIBRARIES or
12193         noinst_LTLIBRARIES assignment.
12194
12195 2006-08-21  Bruno Haible  <bruno@clisp.org>
12196
12197         BeOS portability.
12198         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
12199         BeOS has mbrtowc() but no <wctype.h>.
12200
12201 2006-08-21  Bruno Haible  <bruno@clisp.org>
12202
12203         BeOS portability.
12204         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
12205         exist.
12206
12207 2006-08-21  Bruno Haible  <bruno@clisp.org>
12208
12209         BeOS portability.
12210         * lib/mbchar.h: Include <wctype.h> only if it exists.
12211
12212 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12213
12214         Remove files that are no longer needed by their respective modules.
12215         * m4/obstack.m4: Remove.
12216         * m4/strerror_r.m4: Remove.
12217         * m4/uint32_t.m4: Remove.
12218         * m4/uintptr_t.m4: Remove.
12219         * m4/ullong_max.m4: Remove.
12220         * m4/xstrtoimax.m4: Remove.
12221         * m4/xstrtoumax.m4: Remove.
12222
12223         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
12224         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
12225         dependencies now capture this.
12226
12227         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
12228         Do not use AC_LIBSOURCES, since gnulib modules now do this.
12229         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
12230         * m4/human.m4 (gl_HUMAN): Likewise.
12231         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
12232         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
12233
12234         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
12235
12236         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
12237         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
12238         stdint.
12239         * m4/human.m4 (gl_HUMAN): Likewise.
12240         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
12241         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
12242         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
12243         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
12244         * m4/xstrtol (gl_XSTRTOL): Likewise.
12245
12246         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
12247         AC_TYPE_LONG_LONG_INT.
12248         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
12249         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
12250         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
12251         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
12252
12253         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
12254         on stdbool.
12255
12256         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
12257         (gl_PREREQ_XSTRTOUL): Remove.
12258
12259         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
12260
12261         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
12262         mode.
12263
12264 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12265
12266         Add and change modules to make it easier for coreutils to use
12267         gnulib-tool.
12268         * modules/backupfile (Files): Remove m4/d-ino.m4.
12269         (Depends-on): Add d-ino.
12270         * modules/cycle-check (Depends-on): Add stdint.
12271         (lib_SOURCES): Add cycle-check.h.
12272         * modules/d-ino: New module.
12273         * modules/d-type: New module.
12274         * modules/error (Files): Remove m4/strerror_r.m4.
12275         * modules/filemode (Files): Add m4/st_dm_mode.m4.
12276         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
12277         m4/inttypes_h.m4, m4/uintmax_t.m4.
12278         (Depends-on): Add stdint.
12279         (lib_SOURCES): Add fsusage.h.
12280         * modules/getcwd (Files): Remove d-ino.m4.
12281         (Depends-on): Add d-ino.
12282         * modules/getndelim2 (Depends-on): Add stdint.
12283         * modules/glob (Files): Remove m4/d-type.m4.
12284         (Depends-on): Add d-type.
12285         * modules/host-os: New module.
12286         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
12287         m4/inttypes_h.m4, m4/uintmax_t.m4.
12288         * Depends-on: Add stdint.
12289         (lib_SOURCES): Add human.h.
12290         * modules/inttostr (Files): Remove m4/intmax_t.m4,
12291         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
12292         m4/uintmax_t.m4, m4/ulonglong.m4.
12293         (Depends-on): Add stdint.
12294         (EXTRA_DIST): Add inttostr.h.
12295         * modules/lchmod: New module.
12296         * modules/link-follow: New module.
12297         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
12298         (Depends-on): Add lchmod.
12299         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
12300         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
12301         (Depends-on): Add stdint.
12302         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
12303         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
12304         (Depends-on): Add stdint.
12305         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
12306         * modules/perl: New module.
12307         * modules/regex (Depends-on): Add stdint.
12308         * modules/rmdir-errno: New module.
12309         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
12310         m4/intmax_t.m4.
12311         (Depends-on): Add stdint.
12312         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
12313         m4/uintmax_t.m4.
12314         (Depends-on): Add stdint.
12315         * modules/unlink-busy: New module.
12316         * modules/utimecmp (Depends-on): Add stdint.
12317         * modules/uptime: New module.
12318         * modules/winsz-ioctl: New module.
12319         * modules/winsz-termios: New module.
12320         * modules/xnanosleep (Depends-on): Add nanosleep.
12321         * modules/ullong_max: Remove.
12322         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
12323         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
12324         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
12325         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
12326         (Depends-on): Add inttypes.
12327         (lib_SOURCES): Add xstrtol.h.
12328         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
12329         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
12330         * MODULES.html.sh: Move 'assert' into the assert section.
12331         Move 'dummy' into the linking section.
12332         Remove ullong_max.
12333         Add section for compatibility checks for POSIX:2001 functions,
12334         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
12335         winsz-ioctl, and winsz-termios into it.
12336         Add lchmod.
12337         Add top-level Misc section and put host-os, perl, and uptime
12338         into it.
12339
12340 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12341
12342         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
12343         now assume the stdint module.  Do not include inttypes.h.
12344         * lib/fsusage.h: Likewise.
12345         * lib/getndelim2.c: Likewise.
12346         * lib/human.h: Likewise.
12347         * lib/inttostr.h: Likewise.
12348         * lib/obstack.c: Likewise.
12349         * lib/regex_internal.h: Likewise.
12350         * lib/tempname.c: Likewise.
12351         * lib/utimecmp.c: Likewise.
12352         * lib/xstrtol.h: Likewise.
12353
12354         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
12355
12356         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
12357         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
12358         * lib/xtime.h: Likewise.
12359
12360 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12361
12362         * modules/openat (Files): Add lib/fchmodat.c.
12363         Fixes problem reported by Jay Youngman.
12364
12365 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12366
12367         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
12368         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
12369
12370 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
12371             Bruno Haible  <bruno@clisp.org>
12372
12373         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
12374         and is a script that invokes bison. Tighten the code. Add comments.
12375
12376 2006-08-18  Jim Meyering  <jim@meyering.net>
12377
12378         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
12379         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
12380         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
12381         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
12382
12383 2006-08-18  Bruno Haible  <bruno@clisp.org>
12384
12385         * modules/bison-i18n: New file.
12386         * MODULES.html.sh (Internationalization functions): Add it.
12387
12388 2006-08-18  Bruno Haible  <bruno@clisp.org>
12389
12390         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
12391         sys/statvfs.h. When getmntinfo was found, check its declaration and
12392         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
12393
12394 2006-08-18  Bruno Haible  <bruno@clisp.org>
12395
12396         * m4/bison-i18n.m4: New file, from bison.
12397
12398 2006-08-18  Bruno Haible  <bruno@clisp.org>
12399
12400         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
12401         (ME_DUMMY): Treat "kernfs" as a dummy.
12402         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
12403
12404 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
12405
12406         Update from coreutils.
12407
12408         2006-08-15  Jim Meyering  <jim@meyering.net>
12409
12410         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
12411
12412         2006-01-17  Jim Meyering  <jim@meyering.net>
12413
12414         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
12415
12416         2006-01-11  Jim Meyering  <jim@meyering.net>
12417
12418         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
12419         Check for the lchmod function.
12420
12421 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
12422
12423         Update from coreutils.
12424
12425         * lib/__fpending.h: Add copyright notice.
12426         * lib/fprintftime.h: Likewise.
12427         * lib/savedir.c: Use (C) in copyright notice.
12428         * lib/savedir.h: Likewise.
12429
12430         2006-08-15  Jim Meyering  <jim@meyering.net>
12431
12432         * lib/at-func.c: New file, with the logic of all emulated at-functions.
12433         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
12434         in support of the EXPECTED_ERRNO macro.
12435         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
12436         definitions.  Instead, define the appropriate symbols and include
12437         "at-func.c".
12438         * lib/mkdirat.c (mkdirat): Likewise.
12439         * lib/fchmodat.c (fchmodat): Likewise.
12440         (ENOSYS): Remove definition.
12441         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
12442         it.  Don't include "unistd--.h" -- it wasn't ever used.
12443
12444         2006-01-17  Jim Meyering  <jim@meyering.net>
12445
12446         Rewrite fts.c not to change the current working directory,
12447         by using openat, fstatat, fdopendir, etc..
12448
12449         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
12450         (HAVE_OPENAT_SUPPORT): Define.
12451         [_LIBC] (fchdir): Don't undef or define; no longer used.
12452         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
12453         Now, this `function' always succeeds, and consumes its file descriptor
12454         parameter -- so callers must not close such FDs.  Update callers.
12455         (diropen_fd, opendirat, cwd_advance_fd): New functions.
12456         (diropen): Add parameter, SP.  Adjust all callers.
12457         Implement using diropen_fd, rather than open.
12458         (fts_open): Initialize new member, fts_cwd_fd.
12459         Remove fts_rft-setting code.
12460         (fts_close): Close fts_cwd_fd, if necessary.
12461         (__opendir2): Define in terms of opendir or opendirat,
12462         depending on whether the FST_NOCHDIR flag is set.
12463         (fts_build): Since fts_safe_changedir consumes its FD, and since
12464         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
12465         and close the dup'd file descriptor upon failure.
12466         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
12467         (fts_safe_changedir): Tweak semantics to reflect that this function
12468         now calls cwd_advance_fd and hence consumes its FD argument.
12469         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
12470         [struct FTS] (fts_rft): Remove now-unused member.
12471         [struct FTS] (fts_cycle.state): Improve comment.
12472
12473         * lib/openat.c (openat_needs_fchdir): New function.
12474         * lib/openat.h (openat_needs_fchdir): Declare it.
12475
12476 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
12477
12478         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
12479         Problem and fix reported by Pádraig Brady in
12480         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
12481
12482 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12483
12484         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
12485
12486 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12487
12488         * lib/memcoll.c (memcoll): Optimize for the common case where the
12489         arguments are bytewise equal.
12490
12491 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12492
12493         * doc/regexprops-generic.texi: Add a copyright notice.
12494
12495 2006-08-15  Bruno Haible  <bruno@clisp.org>
12496
12497         * modules/tmpdir (License): Change to LGPL.
12498
12499 2006-08-15  Bruno Haible  <bruno@clisp.org>
12500
12501         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
12502         module.
12503
12504 2006-08-14  Simon Josefsson  <jas@extundo.com>
12505
12506         * config/srclist.txt: Add gnupload.
12507
12508 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12509
12510         Change copyright notice from LGPL 2 to GPL 2, since that's the
12511         standard form used in the gnulib repository.
12512         * tests/test-lock.c: Likewise.
12513         * tests/test-stdint.c: Likewise.
12514         * tests/test-tls.c: Likewise.
12515
12516         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
12517         prelude-manager.  User shorter URLs for GNU projects, without '?'.
12518         Add copyright notice.
12519
12520         * check-module: Add copyright notice.  Output a copyright
12521         notice if "--version" is specified.
12522         * modules/COPYING: New file.
12523         * tests/test-getaddrinfo.c: Add copyright notice.
12524         * tests/test-verify.c: Likewise.
12525
12526 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12527
12528         Change copyright notice from LGPL 2 to GPL 2, since that's the
12529         standard form used in the gnulib repository.
12530         * lib/lock.c: LGPL -> GPL.
12531         * lib/lock.h: Likewise.
12532         * lib/strnlen1.c: Likewise.
12533         * lib/strnlen1.h: Likewise.
12534         * lib/tls.c: Likewise.
12535         * lib/tls.h: Likewise.
12536         * lib/tmpdir.c: Likewise.
12537
12538         * lib/TODO: Remove; this belongs only in coreutils.
12539
12540 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12541
12542         Add copyright notices to long-enough files that lack them, since
12543         otherwise the files aren't clearly free.  Use the same notice that
12544         getdate.texi already uses.
12545         * doc/alloca-opt.texi: Add copyright notice.
12546         * doc/alloca.texi: Likewise.
12547         * doc/ctime.texi: Likewise.
12548         * doc/functions.texi: Likewise.
12549         * doc/gcd.texi: Likewise.
12550         * doc/gnulib-tool.texi: Likewise.
12551         * doc/inet_ntoa.texi: Likewise.
12552         * doc/visibility.texi: Likewise.
12553
12554         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
12555         * doc/quote.texi: Add copyright notice.
12556
12557         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
12558         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
12559         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
12560         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
12561         is now obsolete, and give a pointer to the Sun list.
12562         Add copyright notice.
12563
12564 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12565
12566         * config/srclistvars.sh: Add copyright notice.
12567
12568 2006-08-14  Eric Blake  <ebb9@byu.net>
12569
12570         Import the following change from libc:
12571
12572         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
12573
12574         Upstream bug 2997.
12575         * lib/misc/error.c: Add space between program name and message if file
12576         name is missing.
12577
12578 2006-08-12  Karl Berry  <karl@gnu.org>
12579
12580         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
12581         remove, these originate in gnulib now.
12582
12583 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12584
12585         * doc/Makefile (standards.info standards.html standards.dvi):
12586         Also depend on make-stds.texi.
12587
12588 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
12589
12590         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
12591         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
12592
12593         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
12594         in wchar_t.  Problem reported by Eric Blake.
12595
12596         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
12597         LEN is smaller than SIZE.  Suggested by Bruno Haible.
12598         Also, help the compiler to keep LEN in a register.
12599
12600 2006-08-11  Eric Blake  <ebb9@byu.net>
12601
12602         * users.txt: Sort.  Add tar.
12603
12604 2006-08-11  Bruno Haible  <bruno@clisp.org>
12605
12606         * users.txt: New file.
12607
12608 2006-08-11  Bruno Haible  <bruno@clisp.org>
12609
12610         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
12611         before <wchar.h>. Needed for OSF/1 and BSD/OS.
12612
12613 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
12614
12615         * modules/snprintf (Depends-on): Remove minmax.
12616         (Maintainer): Add self and Bruno.
12617
12618 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
12619
12620         * lib/.cppi-disable: Add snprintf.h, socket_.h.
12621         * lib/snprintf.c: Include <errno.h> and <limits.h>.
12622         (EOVERFLOW): Define if the system does not.
12623         Do not include "minmax.h"; it wasn't used.
12624         (snprintf): Don't assume size_t promotes to an unsigned type.
12625         Fix bug when generated string was too long for the buffer: the
12626         buffer's contents are supposed to be the initial prefix of the
12627         output.  Don't assume vasnprintf returns EOVERFLOW if the size
12628         exceeds INT_MAX; do the check ourselves.
12629
12630         Import the following changes from libc:
12631
12632         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
12633
12634         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
12635         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
12636         set wc to the byte which couldn't be converted.
12637         (re_string_reconstruct): Don't clear valid_raw_len before calling
12638         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
12639         tip_context using re_string_context_at.
12640
12641         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
12642
12643         * lib/posix/regex.h: g++ still cannot handled [restrict].
12644
12645         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
12646
12647         * lib/posix/regex.h: Remove special handling for VMS.
12648
12649 2006-08-10  Jim Meyering  <jim@meyering.net>
12650
12651         * modules/same-inode: New module.
12652         * modules/dev-ino: New module.
12653         * modules/cycle-check: Depend on these modules, rather than simply
12654         including their .h files.
12655         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
12656         required via m4/cycle-check.m4.
12657         * modules/same: Depend on new same-inode module, rather than
12658         including same-inode.h.
12659         * modules/chdir-safer: New file.
12660
12661         * modules/chown (Depends-on): Add stat-macros.
12662
12663 2006-08-10  Jim Meyering  <jim@meyering.net>
12664
12665         * m4/cycle-check.m4: New file.
12666         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
12667         * m4/dev-ino.m4, m4/same-inode.m4: New files.
12668
12669 2006-08-10  Eric Blake  <ebb9@byu.net>
12670
12671         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
12672         in from original proposal.
12673
12674 2006-08-10  Eric Blake  <ebb9@byu.net>
12675         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
12676
12677         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
12678         namespace.
12679
12680 2006-08-10  Bruno Haible  <bruno@clisp.org>
12681
12682         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
12683         as well.
12684
12685 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12686
12687         Sync from coreutils.
12688
12689         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
12690
12691         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
12692         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
12693
12694 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12695
12696         * modules/restrict: Remove; no longer needed now that we assume
12697         Autoconf 2.59 or later.
12698         * MODULES.html.sh: Remove 'restrict'.
12699         * modules/argp (Depends-on): Remove 'restrict'.
12700         * modules/base64 (Depends-on): Likewise.
12701         * modules/gc (Depends-on): Likewise.
12702         * modules/getaddrinfo (Depends-on): Likewise.
12703         * modules/glob (Depends-on): Likewise.
12704         * modules/inet_ntop (Depends-on): Likewise.
12705         * modules/inet_pton (Depends-on): Likewise.
12706         * modules/memxor (Depends-on): Likewise.
12707         * modules/regex (Depends-on): Likewise.
12708         * modules/strtok_r (Depends-on): Likewise.
12709         * modules/time_r (Depends-on): Likewise.
12710
12711 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12712
12713         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
12714         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
12715         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
12716         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
12717         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
12718         * m4/memxor.m4 (gl_MEMXOR): Likewise.
12719         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
12720         gl_C_RESTRICT replaced by AC_C_RESTRICT.
12721
12722         Merge from coreutils.
12723         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
12724         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
12725         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
12726         * m4/time_r.m4 (gl_TIME_R): Likewise.
12727
12728 2006-08-09  Karl Berry  <karl@gnu.org>
12729
12730         * config/srclist.txt: no more gettext-tools, per Bruno.
12731
12732 2006-08-08  Eric Blake  <ebb9@byu.net>
12733
12734         * modules/verror: New module.
12735         * MODULES.html.sh: Document it.
12736
12737 2006-08-08  Eric Blake  <ebb9@byu.net>
12738
12739         * lib/verror.h, lib/verror.c: New files.
12740
12741 2006-08-08  Eric Blake  <ebb9@byu.net>
12742
12743         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
12744         verror_at_line output complies with GNU Coding Standards even when
12745         file is NULL.
12746
12747 2006-08-07  Bruno Haible  <bruno@clisp.org>
12748
12749         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
12750         versions of AIX.
12751         Reported by Ralf Wildenhues.
12752
12753 2006-08-07  Bruno Haible  <bruno@clisp.org>
12754
12755         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
12756         in an AC_DEFUN. Needed so that the autoconf snippets can use
12757         AC_REQUIRE.
12758
12759 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12760
12761         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12762         Initialize pkgdata_DATA.
12763         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
12764         overriding it.
12765
12766 2006-08-06  Eric Blake  <ebb9@byu.net>
12767
12768         * lib/error.h: Fold in some upstream changes from glibc.
12769         * lib/error.c: Likewise.
12770
12771 2006-08-04  Bruno Haible  <bruno@clisp.org>
12772
12773         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12774         Make the mostlyclean-local rule depend on mostlyclean-generic.
12775         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
12776
12777 2006-07-31  Bruno Haible  <bruno@clisp.org>
12778
12779         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
12780         <stdlib.h>, <string.h>.
12781
12782 2006-07-30  Bruno Haible  <bruno@clisp.org>
12783
12784         * modules/readlink (License): Change to LGPL.
12785
12786 2006-07-30  Bruno Haible  <bruno@clisp.org>
12787
12788         * modules/javaversion (Makefile.am): Distribute javaversion.java and
12789         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
12790         set PKGDATADIR to point to it.
12791
12792 2006-07-30  Bruno Haible  <bruno@clisp.org>
12793
12794         * modules/csharpexec (configure.ac): Comment out macro invocation.
12795         * modules/javaexec (configure.ac): Likewise.
12796         * modules/javacomp-script (configure.ac): Likewise.
12797
12798         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
12799
12800 2006-07-30  Bruno Haible  <bruno@clisp.org>
12801
12802         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
12803         linked-list.
12804
12805 2006-07-30  Bruno Haible  <bruno@clisp.org>
12806
12807         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
12808
12809 2006-07-30  Bruno Haible  <bruno@clisp.org>
12810
12811         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12812         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
12813         get removed.
12814
12815 2006-07-29  Bruno Haible  <bruno@clisp.org>
12816
12817         Make it possible for gnulib-tool to work with locally modified or
12818         augmented gnulib repositories.
12819         * gnulib-tool (func_usage): Document --local-dir option.
12820         (local_gnulib_dir): New variable.
12821         Handle --local-dir option.
12822         (func_lookup_file): New function.
12823         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
12824         (func_get_description, func_get_filelist, func_get_description,
12825         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
12826         func_get_automake_snippet, func_get_include_directive,
12827         func_get_license, func_get_maintainer): Use func_lookup_file.
12828         (func_import, func_create_testdir): Use func_lookup_file.
12829
12830 2006-07-29  Bruno Haible  <bruno@clisp.org>
12831
12832         * modules/setenv (Depends-on): Add unistd.
12833
12834 2006-07-29  Bruno Haible  <bruno@clisp.org>
12835
12836         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
12837
12838 2006-07-29  Bruno Haible  <bruno@clisp.org>
12839
12840         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
12841
12842 2006-07-29  Bruno Haible  <bruno@clisp.org>
12843
12844         * gnulib-tool (import, update): If there is no Makefile.am, look at
12845         aclocal.m4, instead of bailing out.
12846
12847 2006-07-29  Bruno Haible  <bruno@clisp.org>
12848
12849         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
12850         Categorize the options by when they are useful.
12851
12852 2006-07-29  Bruno Haible  <bruno@clisp.org>
12853
12854         * gnulib-tool (func_usage): Document option --no-libtool.
12855         Handle option --no-libtool.
12856         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
12857         for changed semantics of $libtool variable.
12858         (func_import): Likewise. If libtool is not used, show this through
12859         an option --no-libtool.
12860         (func_create_testdir): Update.
12861
12862 2006-07-29  Bruno Haible  <bruno@clisp.org>
12863
12864         * gnulib-tool (func_import): Extend error message about missing
12865         --doc-base.
12866
12867 2006-07-29  Bruno Haible  <bruno@clisp.org>
12868
12869         * gnulib-tool (func_import): Don't create the $docbase directory if
12870         there is no file to store there.
12871
12872 2006-07-29  Bruno Haible  <bruno@clisp.org>
12873
12874         * gnulib-tool (autoconf_minversion): If a --dir option is given and
12875         relevant, look for configure.ac there, not in the current directory.
12876         Also use a simple search for AC_PREREQ, not "autoconf --trace".
12877
12878 2006-07-29  Bruno Haible  <bruno@clisp.org>
12879
12880         * gnulib-tool (SORT): New variable.
12881         (func_usage): Undocument --assume-autoconf option.
12882         Remove --assume-autoconf option handling.
12883         (autoconf_minversion): Determine from the contents of configure.ac.
12884         (func_import): Remove autoconf_minversion handling.
12885         Suggested by Eric Blake.
12886
12887 2006-07-29  Bruno Haible  <bruno@clisp.org>
12888
12889         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
12890
12891 2006-07-29  Bruno Haible  <bruno@clisp.org>
12892
12893         * config/srclist.txt (*setenv.[ch]): Remove rules.
12894
12895 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12896
12897         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
12898
12899 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12900
12901         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
12902         arpa/inet.h.
12903
12904 2006-07-28  Simon Josefsson  <jas@extundo.com>
12905
12906         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
12907         * modules/inet_pton (Depends-on): Likewise.
12908
12909 2006-07-28  Simon Josefsson  <jas@extundo.com>
12910
12911         * m4/netinet_in_h.m4: New file.
12912
12913 2006-07-28  Simon Josefsson  <jas@extundo.com>
12914
12915         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
12916         #include's.
12917
12918 2006-07-28  Simon Josefsson  <jas@extundo.com>
12919
12920         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
12921         #include's.
12922
12923 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
12924
12925         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
12926         setgid on directories only if they set these bits.
12927         * lib/modechange.h: Remove obsolete comment about masks.
12928
12929 2006-07-28  Eric Blake  <ebb9@byu.net>
12930
12931         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
12932         macro expansion.
12933
12934 2006-07-28  Bruno Haible  <bruno@clisp.org>
12935
12936         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
12937
12938 2006-07-28  Bruno Haible  <bruno@clisp.org>
12939
12940         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
12941
12942 2006-07-28  Bruno Haible  <bruno@clisp.org>
12943
12944         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
12945         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
12946         Define fallbacks.
12947         Avoids link error on FreeBSD 4.x.
12948         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
12949
12950         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
12951         encoding.
12952         * lib/mbswidth.c (iswcntrl): Likewise.
12953
12954 2006-07-27  Bruno Haible  <bruno@clisp.org>
12955
12956         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
12957         test.
12958
12959 2006-07-27  Bruno Haible  <bruno@clisp.org>
12960
12961         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
12962         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
12963         defined.
12964
12965 2006-07-26  Eric Blake  <ebb9@byu.net>
12966
12967         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
12968
12969 2006-07-26  Eric Blake  <ebb9@byu.net>
12970
12971         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
12972         like mingw that lack mkstemp.
12973         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
12974         avoid compilation warning on mingw.
12975
12976 2006-07-26  Bruno Haible  <bruno@clisp.org>
12977
12978         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
12979         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
12980         INT_FAST*_MIN, INTPTR_MIN.
12981
12982 2006-07-25  Bruno Haible  <bruno@clisp.org>
12983
12984         * modules/version-etc (Depends-on): Add stdarg.
12985
12986 2006-07-25  Bruno Haible  <bruno@clisp.org>
12987
12988         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
12989         complex commands.
12990
12991 2006-07-25  Bruno Haible  <bruno@clisp.org>
12992
12993         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
12994         defined in <stdarg.h> or config.h.
12995
12996 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
12997
12998         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
12999         (gl_STDIO_SAFER): Remove.
13000
13001 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
13002
13003         * MODULES.html.sh (File stream based Input/Output):
13004         Add fopen-safer, tmpfile-safer; remove stdio-safer.
13005         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
13006         * modules/fopen-safer, modules/tmpfile-safer: New files.
13007         * modules/stdio-safer: Remove.
13008
13009 2006-07-24  Bruno Haible  <bruno@clisp.org>
13010
13011         * modules/tmpdir: New file.
13012         * MODULES.html.sh (File system functions): Add it.
13013
13014 2006-07-24  Bruno Haible  <bruno@clisp.org>
13015
13016         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
13017         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
13018
13019 2006-07-24  Bruno Haible  <bruno@clisp.org>
13020
13021         * modules/clean-temp: New file.
13022
13023 2006-07-24  Bruno Haible  <bruno@clisp.org>
13024
13025         * m4/tmpdir.m4: New file, from GNU gettext.
13026
13027 2006-07-24  Bruno Haible  <bruno@clisp.org>
13028
13029         * lib/tmpdir.h: New file, from GNU gettext.
13030         * lib/tmpdir.c: New file, from GNU gettext.
13031
13032 2006-07-24  Bruno Haible  <bruno@clisp.org>
13033
13034         * lib/clean-temp.h: New file, from GNU gettext.
13035         * lib/clean-temp.c: New file, from GNU gettext.
13036
13037 2006-07-23  Eric Blake  <ebb9@byu.net>
13038
13039         * modules/stdio-safer (Files): Add tmpfile-safer.c.
13040         (Depends-on): Add binary-io.
13041
13042 2006-07-23  Eric Blake  <ebb9@byu.net>
13043
13044         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
13045
13046 2006-07-23  Eric Blake  <ebb9@byu.net>
13047
13048         * lib/tmpfile-safer.c: New file.
13049         * lib/stdio-safer.h (fopen_safer): Add prototype.
13050         * lib/stdio--.h (tmpfile): Make safer.
13051
13052 2006-07-23  Bruno Haible  <bruno@clisp.org>
13053
13054         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
13055         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
13056         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
13057         gl_linked_remove_at): Use it.
13058
13059 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13060         and Simon Josefsson <jas@extundo.com>
13061
13062         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
13063
13064         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
13065
13066 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
13067
13068         * modules/close-stream: New file.
13069         * modules/closeout (Description): Make it clear that it exits
13070         with a diagnostic on error.
13071         (Depends-on): Add close-stream.  Remove fpending, stdbool.
13072         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
13073
13074 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
13075
13076         * m4/close-stream.m4: New file.
13077
13078 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
13079
13080         * lib/close-stream.c, lib/close-stream.h: New files.
13081
13082 2006-07-22  Bruno Haible  <bruno@clisp.org>
13083
13084         Merge from GNU gettext 0.15.
13085
13086         2006-05-01  Bruno Haible  <bruno@clisp.org>
13087
13088                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
13089
13090         2006-07-22  Bruno Haible  <bruno@clisp.org>
13091
13092                 * modules/javaversion: New file.
13093                 * MODULES.html.sh (Java): Add javaversion.
13094
13095         2006-03-12  Bruno Haible  <bruno@clisp.org>
13096
13097                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
13098
13099         2005-12-04  Bruno Haible  <bruno@clisp.org>
13100
13101                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
13102                 (untested).
13103
13104         2006-06-21  Bruno Haible  <bruno@clisp.org>
13105
13106                 Avoid warnings from recent versions of mcs.
13107                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
13108                 -o, -L, -r any more. Use options documented since mcs-1.0
13109                 instead. Similarly for -g.
13110
13111         2005-12-04  Bruno Haible  <bruno@clisp.org>
13112
13113                 * build-aux/csharpcomp.sh.in: Suffix for resources is
13114                 .resources, not .resource.
13115
13116         2005-07-09  Bruno Haible  <bruno@clisp.org>
13117
13118                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
13119                 add a .dll suffix.
13120                 Reported by Mark Junker <mjscod@gmx.de>.
13121
13122         2006-07-22  Bruno Haible  <bruno@clisp.org>
13123
13124                 * modules/gettext: Upgrade to gettext-0.15.
13125                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
13126                 m4/visibility.m4.
13127                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
13128
13129 2006-07-22  Bruno Haible  <bruno@clisp.org>
13130
13131         Merge from GNU gettext 0.15.
13132
13133         2006-03-25  Bruno Haible  <bruno@clisp.org>
13134
13135                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
13136
13137         2006-07-21  Bruno Haible  <bruno@clisp.org>
13138
13139                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
13140                 "1.1".
13141
13142         2006-05-09  Bruno Haible  <bruno@clisp.org>
13143
13144                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
13145                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
13146                 for the conftestver execution.
13147
13148         2006-05-01  Bruno Haible  <bruno@clisp.org>
13149
13150                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
13151                 optional target-version argument. Verify that the compiler
13152                 groks source of the specified source-version, or add -source
13153                 option as necessary. Verify that the compiler produces
13154                 bytecode in the specified target-version, or add -target and
13155                 -source options as necessary. Make the result of the test
13156                 available as variable CONF_JAVAC. Also log error output in
13157                 config.log.
13158
13159         2006-03-11  Bruno Haible  <bruno@clisp.org>
13160
13161                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
13162
13163         2006-05-09  Bruno Haible  <bruno@clisp.org>
13164
13165                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
13166                 CLASSPATH_SEPARATOR to a semicolon.
13167
13168         2006-03-12  Bruno Haible  <bruno@clisp.org>
13169
13170                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
13171                 available as variable CONF_JAVA, for subsequent autoconf
13172                 tests. Also log error output in config.log.
13173
13174         2006-07-19  Bruno Haible  <bruno@clisp.org>
13175
13176                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
13177                 that getline works on glibc2 systems. Needed to avoid trouble
13178                 in relocatable.c.
13179                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
13180
13181         2005-12-04  Bruno Haible  <bruno@clisp.org>
13182
13183                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
13184                 launcher (untested).
13185
13186         2005-12-04  Bruno Haible  <bruno@clisp.org>
13187
13188                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
13189
13190         2006-07-22  Bruno Haible  <bruno@clisp.org>
13191
13192                 * gettext.m4: Update from GNU gettext-0.15.
13193                 * nls.m4: Likewise.
13194                 * po.m4: Likewise.
13195                 * inttypes-pri.m4: Likewise.
13196                 * inttypes-h.m4: Renamed from inttypes.m4.
13197                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
13198
13199 2006-07-22  Bruno Haible  <bruno@clisp.org>
13200
13201         Merge from GNU gettext 0.15.
13202
13203         2005-07-05  Bruno Haible  <bruno@clisp.org>
13204
13205                 * printf-args.c (printf_fetchargs): Work around broken
13206                 definition of wint_t on mingw.
13207
13208         2005-02-12  Bruno Haible  <bruno@clisp.org>
13209
13210                 * xallocsa.h: Add extern "C" for C++.
13211
13212         2006-05-17  Bruno Haible  <bruno@clisp.org>
13213
13214                 Cygwin portability.
13215                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
13216
13217         2006-04-30  Bruno Haible  <bruno@clisp.org>
13218
13219                 * progreloc.c: Include <mach-o/dyld.h> if available.
13220                 (find_executable): Use _NSGetExecutablePath when possible.
13221
13222         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
13223
13224                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
13225                 function.
13226
13227         2005-12-29  Bruno Haible  <bruno@clisp.org>
13228
13229                 * progreloc.c (set_program_name_and_installdir): Fix
13230                 compilation error.
13231
13232         2005-12-04  Bruno Haible  <bruno@clisp.org>
13233
13234                 Cygwin portability.
13235                 * progreloc.c: Include <windows.h> also on Cygwin.
13236                 (find_executable): Add support for Cygwin.
13237                 (set_program_name_and_installdir): Handle also platforms with
13238                 nonempty EXEEXT.
13239
13240         2006-07-11  Bruno Haible  <bruno@clisp.org>
13241
13242                 * javacomp.c: Fix a comment.
13243                 Reported by Jim Meyering.
13244
13245         2006-04-30  Bruno Haible  <bruno@clisp.org>
13246
13247                 * javacomp.h (compile_java_class): Add source_version,
13248                 target_version arguments.
13249                 * javacomp.c: Rewritten to choose only a compiler that
13250                 respects the specified source_version and target_version.
13251
13252         2006-06-27  Bruno Haible  <bruno@clisp.org>
13253
13254                 Assume correct S_ISDIR macro.
13255                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
13256
13257         2006-07-22  Bruno Haible  <bruno@clisp.org>
13258
13259                 * javaversion.h: New file, from GNU gettext.
13260                 * javaversion.c: New file, from GNU gettext.
13261                 * javaversion.java: New file, from GNU gettext.
13262                 * javaversion.class: New file, from GNU gettext.
13263
13264         2006-05-17  Bruno Haible  <bruno@clisp.org>
13265
13266                 Cygwin portability.
13267                 * javaexec.c (execute_java_class): Test for jview program
13268                 also on Cygwin.
13269
13270         2006-04-09  Bruno Haible  <bruno@clisp.org>
13271
13272                 * fatal-signal.c: Don't include string.h.
13273                 (at_fatal_signal): Use a copying loop instead of memcpy.
13274
13275         2005-12-04  Bruno Haible  <bruno@clisp.org>
13276
13277                 * csharpexec.c: Add support for 'clix' launcher (untested).
13278                 (execute_csharp_using_sscli): New function.
13279                 (execute_csharp_program): Call it.
13280
13281         2006-06-21  Bruno Haible  <bruno@clisp.org>
13282
13283                 Avoid warnings from recent versions of mcs.
13284                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
13285                 -o, -L, -r any more. Use options documented since mcs-1.0
13286                 instead. Similarly for -g.
13287
13288         2005-07-09  Bruno Haible  <bruno@clisp.org>
13289
13290                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
13291                 add a .dll suffix.
13292                 Reported by Mark Junker <mjscod@gmx.de>.
13293
13294         2006-06-17  Bruno Haible  <bruno@clisp.org>
13295
13296                 * config.charset: Update for NetBSD 3.0.
13297
13298         2006-05-17  Bruno Haible  <bruno@clisp.org>
13299
13300                 Cygwin portability.
13301                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
13302
13303         2006-05-16  Bruno Haible  <bruno@clisp.org>
13304
13305                 * localcharset.c [CYGWIN]: Include <windows.h>.
13306                 (get_charset_aliases): For Cygwin, return the same CPxxx
13307                 aliases list as under WIN32.
13308                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
13309                 the environment variables. Fall back to GetACP().
13310
13311         2006-04-05  Bruno Haible  <bruno@clisp.org>
13312
13313                 * config.charset: Update Juan Manuel Guerrero's address.
13314
13315         2005-02-12  Bruno Haible  <bruno@clisp.org>
13316
13317                 * allocsa.h: Add extern "C" for C++.
13318
13319         2005-02-10  Bruno Haible  <bruno@clisp.org>
13320
13321                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
13322                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
13323
13324         2006-07-22  Bruno Haible  <bruno@clisp.org>
13325
13326                 * gettext.h: Update to GNU gettext-0.15.
13327
13328 2006-07-22  Bruno Haible  <bruno@clisp.org>
13329
13330         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
13331         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
13332         lib-prefix.m4, longdouble.m4, ssize_t.m4.
13333
13334 2006-07-21  Eric Blake  <ebb9@byu.net>
13335
13336         * modules/stdlib-safer: New file.
13337         * MODULES.html.sh (File stream based Input/Output): Add
13338         stdlib-safer.
13339
13340 2006-07-21  Eric Blake  <ebb9@byu.net>
13341
13342         * lib/stdlib-safer.h: New file from coreutils, required by
13343         stdlib--.h.
13344
13345 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
13346
13347         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
13348
13349 2006-07-20  Bruno Haible  <bruno@clisp.org>
13350
13351         * gnulib-tool: Recognize new option --assume-autoconf.
13352         (autoconf_minversion): New variable.
13353         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
13354
13355 2006-07-20  Bruno Haible  <bruno@clisp.org>
13356
13357         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
13358
13359 2006-07-19  Derek R. Price  <derek@ximbiot.com>
13360
13361         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
13362         Reindent and repaginate.
13363
13364 2006-07-19  Derek Price  <derek@ximbiot.com>
13365
13366         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
13367         Correct grammar.
13368
13369 2006-07-17  Bruno Haible  <bruno@clisp.org>
13370
13371         * modules/list: New file.
13372         * modules/array-list: New file.
13373         * modules/carray-list, modules/carray-list-tests: New files.
13374         * modules/linked-list, modules/linked-list-tests: New files.
13375         * modules/avltree-list, modules/avltree-list-tests: New files.
13376         * modules/rbtree-list, modules/rbtree-list-tests: New files.
13377         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
13378         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
13379         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
13380         * modules/oset: New file.
13381         * modules/array-oset: New file.
13382         * modules/avltree-oset, modules/avltree-oset-tests: New files.
13383         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
13384         * tests/test-carray_list.c: New file.
13385         * tests/test-linked_list.c: New file.
13386         * tests/test-avltree_list.c: New file.
13387         * tests/test-rbtree_list.c: New file.
13388         * tests/test-linkedhash_list.c: New file.
13389         * tests/test-avltreehash_list.c: New file.
13390         * tests/test-rbtreehash_list.c: New file.
13391         * tests/test-avltree_oset.c: New file.
13392         * tests/test-rbtree_oset.c: New file.
13393         * MODULES.html.sh (Container data structures): New section.
13394
13395 2006-07-17  Bruno Haible  <bruno@clisp.org>
13396
13397         * m4/gl_list.m4: New file.
13398
13399 2006-07-17  Bruno Haible  <bruno@clisp.org>
13400
13401         * lib/gl_list.h: New file.
13402         * lib/gl_list.c: New file.
13403         * lib/gl_array_list.h: New file.
13404         * lib/gl_array_list.c: New file.
13405         * lib/gl_carray_list.h: New file.
13406         * lib/gl_carray_list.c: New file.
13407         * lib/gl_linked_list.h: New file.
13408         * lib/gl_linked_list.c: New file.
13409         * lib/gl_anylinked_list1.h: New file.
13410         * lib/gl_anylinked_list2.h: New file.
13411         * lib/gl_avltree_list.h: New file.
13412         * lib/gl_avltree_list.c: New file.
13413         * lib/gl_anyavltree_list1.h: New file.
13414         * lib/gl_anyavltree_list2.h: New file.
13415         * lib/gl_rbtree_list.h: New file.
13416         * lib/gl_rbtree_list.c: New file.
13417         * lib/gl_anyrbtree_list1.h: New file.
13418         * lib/gl_anyrbtree_list2.h: New file.
13419         * lib/gl_anytree_list1.h: New file.
13420         * lib/gl_anytree_list2.h: New file.
13421         * lib/gl_linkedhash_list.h: New file.
13422         * lib/gl_linkedhash_list.c: New file.
13423         * lib/gl_anyhash_list1.h: New file.
13424         * lib/gl_anyhash_list2.h: New file.
13425         * lib/gl_avltreehash_list.h: New file.
13426         * lib/gl_avltreehash_list.c: New file.
13427         * lib/gl_rbtreehash_list.h: New file.
13428         * lib/gl_rbtreehash_list.c: New file.
13429         * lib/gl_anytreehash_list1.h: New file.
13430         * lib/gl_anytreehash_list2.h: New file.
13431
13432         * lib/gl_oset.h: New file.
13433         * lib/gl_oset.c: New file.
13434         * lib/gl_array_oset.h: New file.
13435         * lib/gl_array_oset.c: New file.
13436         * lib/gl_avltree_oset.h: New file.
13437         * lib/gl_avltree_oset.c: New file.
13438         * lib/gl_rbtree_oset.h: New file.
13439         * lib/gl_rbtree_oset.c: New file.
13440         * lib/gl_anytree_oset.h: New file.
13441
13442 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
13443
13444         * m4/mkancesdirs.m4: New file.
13445         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
13446         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
13447         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
13448         it.
13449
13450 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
13451
13452         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
13453         * lib/mkancesdirs.h: New files.
13454         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
13455         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
13456         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
13457         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
13458         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
13459         callers changed.  Revamp internals significantly, by not
13460         attempting to create directories that are temporarily more
13461         permissive than the final results.  Do not attempt to use
13462         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
13463         This removes some race conditions, fixes some bugs, and simplifies
13464         things.  Use new dirchownmod function to do owner and mode changes.
13465         * lib/mkdir-p.h: Likewise.
13466         * lib/modechange.c (octal_to_mode): New function.
13467         (struct mode_change): New member mentioned.
13468         (make_node_op_equals): New arg mentioned.  All callers changed.
13469         (mode_compile): Keep track of which mode bits the user has explicitly
13470         mentioned.
13471         (mode_adjust): New arg DIR, so that we implement the X op correctly.
13472         New arg PMODE_BITS, to keep track of which mode bits the user
13473         mentioned; it treats S_ISUID and S_ISGID speciall.
13474         All callers changed.
13475         * lib/modechange.h: Likewise.
13476
13477 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
13478
13479         * MODULES.html.sh: Add mkancestors.
13480         * modules/mkancesdirs: New module.
13481         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
13482         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
13483         The chdir-safer and afs files are now orphans; I'll remove them
13484         unless someone speaks up.
13485         Add lib/dirchownmod.c, lib/dirchownmod.h.
13486         (Depends-on): Remove alloca, chown, save-cwd, dirname.
13487         Add lchown, mkancesdirs.
13488         (Maintainer): Add self.
13489
13490 2006-07-15  Karl Berry  <karl@gnu.org>
13491
13492         * gnulib-tool: help message wording/arrangement.
13493
13494 2006-07-14  Simon Josefsson  <jas@extundo.com>
13495
13496         * doc/gnulib.texi (Libtool and Windows): New section.
13497
13498 2006-07-12  Simon Josefsson  <jas@extundo.com>
13499
13500         * modules/gendocs (License): Fix license, approved by Karl.
13501
13502 2006-07-12  Eric Blake  <ebb9@byu.net>
13503
13504         * MODULES.html.sh: Add gendocs.
13505
13506 2006-07-11  Eric Blake  <ebb9@byu.net>
13507
13508         * modules/fdl: New module, to install doc/fdl.texi.
13509         * MODULES.html.sh: Add new section for documentation modules.
13510         * gnulib-tool: Avoid space-tab.
13511         (--doc-base): New option, to manage files from doc.
13512
13513 2006-07-11  Eric Blake  <ebb9@byu.net>
13514
13515         * m4/absolute-header.m4: Fix comments to match recent change.
13516
13517 2006-07-11  Eric Blake  <ebb9@byu.net>
13518
13519         * gnulib-tool: List --doc-base before --tests-base.
13520
13521 2006-07-11  Derek R. Price  <derek@ximbiot.com>
13522
13523         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
13524
13525 2006-07-11  Bruno Haible  <bruno@clisp.org>
13526
13527         * README: Mention where to put documentation.
13528
13529 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13530
13531         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
13532
13533 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
13534
13535         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
13536         to stdint.m4.
13537
13538 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
13539
13540         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
13541         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
13542         "no/such/file/stdint.h" when there is no such file, so that
13543         the resulting C code can be parsed by dodgy compilers.
13544         Problems reported by Bob Proulx.
13545
13546 2006-07-10  Derek R. Price  <derek@ximbiot.com>
13547
13548         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
13549         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
13550         macros into the GNU _D_EXACT_NAMLEN.
13551         * lib/savedir.c:  Likewise.
13552         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
13553
13554 2006-07-10  Derek R. Price  <derek@ximbiot.com>
13555         and Paul Eggert  <eggert@cs.ucla.edu>
13556
13557         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
13558         * m4/savedir.m4:
13559         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
13560         macros into the GNU _D_EXACT_NAMLEN.
13561
13562 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
13563
13564         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
13565         around the absolute name, to work around a problem with the HP-UX
13566         11.23 native C compiler, reported by Bob Proulx.
13567
13568 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
13569
13570         * doc/maintain.texi, make-stds.texi: Sync from
13571         <http://savannah.gnu.org/projects/gnustandards>.
13572
13573 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
13574
13575         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
13576
13577 2006-07-09  Jim Meyering  <jim@meyering.net>
13578
13579         * m4/glob.m4: Remove a doubled word in a comment.
13580
13581 2006-07-09  Jim Meyering  <jim@meyering.net>
13582
13583         * lib/argp-pv.c: Remove a doubled word in a comment.
13584         * lib/check-version.c (check_version): Likewise.
13585         * lib/javacomp.c (compile_java_class): Likewise.
13586
13587 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
13588
13589         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
13590         for the benefit of people using Autoconf 2.60.  If you want to
13591         support older Autoconf versions you can copy m4/onceonly_2_57.m4
13592         (or m4/onceonly.m4, if pre-2.57) manually.
13593
13594 2006-07-08  Jim Meyering  <jim@meyering.net>
13595
13596         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
13597         comment.
13598         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
13599         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
13600         comment.
13601
13602 2006-07-08  Jim Meyering  <jim@meyering.net>
13603
13604         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
13605
13606 2006-07-07  Simon Josefsson  <jas@extundo.com>
13607
13608         * tests/test-crc.c: Change expected crc value, the test vector
13609         were probably computed using the old broken crc.c?
13610
13611 2006-07-06  Simon Josefsson  <jas@extundo.com>
13612
13613         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
13614         now the canonical place for the M4 file).
13615
13616         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
13617         from the sys_socket dependency now.
13618
13619         * modules/inet_pton (Files): Ditto.
13620
13621         * modules/inet_ntop (Files): Ditto.
13622
13623 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
13624
13625         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
13626         not gl_PREREQ_GETUSERSHELL.
13627
13628 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13629
13630         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
13631         with only one argument, for Autoconf 2.60.
13632         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
13633         expand to nothing, so add a shell command to avoid syntax error.
13634         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
13635
13636 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13637
13638         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
13639
13640 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
13641
13642         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
13643         no longer needed.  Check for isblank decl.
13644         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
13645         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
13646         of existence.
13647
13648 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
13649
13650         * lib/getloadavg.c: Use __VMS, not VMS.
13651         * lib/getopt.c: Likewise.
13652         * lib/getpagesize.h: Likewise.
13653         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
13654         and probably does not work.
13655
13656 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
13657
13658         * lib/.cppi-disable: Add wcwidth.
13659         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
13660         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
13661         (ISGRAPH): Remove.  All uses changed to isgraph.
13662         (FOLD) [!defined _LIBC]: Remove special case.
13663         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
13664         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
13665         HAVE_ISBLANK.
13666         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
13667         case.
13668
13669 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
13670
13671         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
13672         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
13673         brackets.  Other minor changes to suppress some compiler
13674         warnings.
13675
13676 2006-07-06  Derek R. Price  <derek@ximbiot.com>
13677         and Paul Eggert  <eggert@cs.ucla.edu>
13678
13679         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
13680         of invoking obsolescent AC_HEADER_DIRENT macro.
13681         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
13682         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
13683         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
13684         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
13685         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
13686         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
13687         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
13688         * m4/readdir.m4: Remove; no longer needed.
13689
13690 2006-07-06  Derek R. Price  <derek@ximbiot.com>
13691         and Paul Eggert  <eggert@cs.ucla.edu>
13692
13693         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
13694         Don't worry about this obsolete case any more.
13695         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
13696         directories.
13697         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
13698         worry about this obsolete case any more.
13699         * lib/fts.c: Likewise.
13700         * lib/getcwd.c: Likewise.
13701         * lib/glob.h: Likewise.
13702         * lib/savedir.c: Likewise.
13703
13704 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
13705
13706         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
13707         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
13708         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
13709         needed.
13710         All uses removed.
13711         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13712         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
13713         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
13714         needed.
13715         * m4/getdate.m4 (gl_GETDATE): Likewise.
13716         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
13717         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
13718         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
13719         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13720         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
13721         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
13722         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
13723         needed.
13724
13725 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
13726
13727         * lib/memcasecmp.c: Include <limits.h>.
13728         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
13729         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
13730         Don't assume isdigit succeeds only on '0' through '9'.
13731
13732 2006-07-05  Eric Blake  <ebb9@byu.net>
13733
13734         * modules/getaddrinfo (Depends-on): Add snprintf.
13735
13736 2006-07-05  Eric Blake  <ebb9@byu.net>
13737
13738         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
13739         to avoid 'header present but could not be compiled' on cygwin.
13740
13741 2006-07-05  Eric Blake  <ebb9@byu.net>
13742
13743         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
13744         missing from netdb.h.
13745         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
13746
13747 2006-07-05  Derek R. Price  <derek@ximbiot.com>
13748
13749         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
13750         no longer needed.
13751         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
13752         * m4/getdate.m4 (gl_GETDATE): Likewise.
13753         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
13754         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
13755         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
13756         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13757         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
13758
13759 2006-07-05  Derek R. Price  <derek@ximbiot.com>
13760
13761         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
13762         All uses of is_space replaced by isspace.
13763         * lib/exit.h: Don't talk about STDC_HEADERS.
13764         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
13765         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
13766         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
13767         replaced by isprint etc.
13768         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
13769         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
13770         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
13771         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
13772         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
13773         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
13774
13775 2006-07-05  Bruno Haible  <bruno@clisp.org>
13776
13777         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
13778         the function exists, before testing against AIX.
13779         Reported by Martin Lambers <marlam@marlam.de>.
13780
13781 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
13782
13783         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
13784         From Mark D. Baushke.
13785
13786 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
13787
13788         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
13789         to the absolute name, not just one, to bypass Sun C 5.8's
13790         "warning: #include of /usr/include/... may be non-portable".
13791
13792 2006-07-04  Eric Blake  <ebb9@byu.net>
13793
13794         * modules/dirname-tests: New test module.
13795         * tests/test-dirname.c: New file, replacing dirname.c
13796         TEST_DIRNAME section that was recently deleted.
13797
13798 2006-07-04  Bruno Haible  <bruno@clisp.org>
13799
13800         Assume ANSI C header files and <ctype.h> functions.
13801         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
13802         (mbsnwidth): Use isprint, iscntrl instead.
13803
13804 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13805
13806         Merge from coreutils.
13807         * MODULES.html.sh: Add xstrtold.
13808         * modules/xstrtold: New file.
13809         * modules/cycle-check (Files): Add lib/same-inode.h.
13810         * modules/dirname (Files): Add m4/double-slash-root.m4.
13811         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
13812         * modules/mkdir-p (Files): Add lib/same-inode.h.
13813         * modules/same (Files): Add lib/same-inode.h.
13814
13815 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13816
13817         * m4/absolute-header.m4: Renamed from full-header-path.m4.
13818         This is to keep the terminology clean; POSIX talks about
13819         "absolute pathnames", not "full pathnames", but the GNU
13820         Coding Standards say to use "path" for something else;
13821         so use "absolute" to keep both sides happy.
13822         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
13823         Set gl_absolute_header, not gl_full_header_path.
13824         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
13825         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
13826         All uses changed.
13827
13828         Merge from coreutils.
13829
13830         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
13831
13832         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
13833         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
13834         want to require the building of c-strtod.o.
13835         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
13836         needs -lm directly.
13837         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
13838
13839         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
13840
13841         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
13842         --as-needed option if available.  Problem reported by Albert Chin in
13843         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
13844         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
13845         cc merely issues a bunch of annoying warnings for --as-needed
13846         (this problem was reported by Bob Proulx).  Also, try linking with
13847         -lm to detect a bug in binutils 2.16 (this problem was reported
13848         by Ralf Wildenhues).
13849
13850         2006-06-18  Jim Meyering  <jim@meyering.net>
13851
13852         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
13853         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
13854         macro.
13855         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
13856         also check for glibc-2.4's abort-inducing bug.
13857
13858         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
13859         Low-probability clean-up should be to use rmdir to get rid of
13860         the just-created directory, not unlink.
13861
13862         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
13863         configure fail, and request a bug report to inform us about it.
13864         Add a comment that, barring reports to the contrary, in 2007 we'll
13865         assume ftruncate is universally available.
13866
13867         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
13868
13869         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
13870
13871         2006-03-12  Jim Meyering  <jim@meyering.net>
13872
13873         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
13874         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
13875         * m4/same.m4 (gl_SAME): Likewise.
13876         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
13877
13878         2006-03-11  Eric Blake  <ebb9@byu.net>
13879
13880         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
13881         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
13882         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
13883         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
13884
13885 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13886
13887         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
13888         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
13889         reported by Mark D. Baushke, one in
13890         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
13891
13892         Merge from coreutils.
13893
13894         * lib/.cppi-disable: Add stdint_.h.
13895         * lib/.cvsignore: Add stdint.h.
13896
13897         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
13898
13899         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
13900         both double and long double versions.
13901         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
13902         * lib/xstrtold.c: New file.
13903         * lib/xstrtod.h (xstrtold): New decl.
13904
13905         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
13906
13907         * lib/filemode.c (setst): Remove.
13908         (strmode): Rewrite to avoid setst.  This makes the code shorter,
13909         (arguably) clearer, and the generated code is a bit smaller on my
13910         Debian GNU/Linux stable x86 host.
13911
13912         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
13913
13914         * lib/filemode.c: Include "filemode.h" first, to test the interface.
13915         Assume that filemode.h includes sys/types.h and sys/stat.h.
13916         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
13917         (ftypelet): Reorder to put common cases first, for efficiency.
13918         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
13919         to do 'M'.
13920         (strmode): Renamed from mode_string, and now stores 12 bytes instead
13921         of 10, for compatibility with FreeBSD.  All callers changed.
13922         (filemodestring): Now stores 12 bytes instead of 10, and sets file
13923         types that can't be deduced solely from st_mode.  First arg is now a
13924         const pointer.
13925         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
13926         (strmode): Renamed from mode_string.
13927         (filemodestring): New decl.
13928         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
13929         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
13930         needed.
13931         (S_ISPORT, S_ISWHT): New macros, if not already defined.
13932
13933         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
13934
13935         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
13936         fsusage.h now does that.  Include fsusage.h first, to test interface.
13937         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
13938         at most one method (the old code could have generated decls that
13939         didn't conform to C89, not that this was ever exercised).
13940         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
13941
13942         2006-03-19  Jim Meyering  <jim@meyering.net>
13943
13944         Work even in a chroot where d_ino values for entries in "/"
13945         don't match the stat.st_ino values for the same names.
13946         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
13947         number, iterate through all entries again, using lstat instead.
13948         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
13949         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
13950
13951         * lib/getcwd.c (__getcwd): Clarify a comment.
13952         Use memcpy in place of a call to strcpy.
13953
13954         2006-03-12  Jim Meyering  <jim@meyering.net>
13955
13956         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
13957         matches that of the current directory (which we're about to chdir ".."
13958         out of), then save the dev-ino of the parent, instead.
13959
13960         * lib/same-inode.h (SAME_INODE): New file/macro.
13961         * lib/chdir-safer.c (SAME_INODE): Remove definition.
13962         Include "same-inode.h", instead.
13963         * lib/same.c: Likewise.
13964         * lib/cycle-check.h: Include "same-inode.h".
13965         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
13966         * lib/cycle-check.c (SAME_INODE): Remove definition.
13967         * lib/root-dev-ino.h: Include "same-inode.h".
13968
13969         2006-03-11  Eric Blake  <ebb9@byu.net>
13970
13971         * lib/same.c (same_name): s/base_name/last_component/
13972         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
13973         * lib/filenamecat.c (file_name_concat): Likewise.
13974
13975         2006-03-11  Eric Blake  <ebb9@byu.net>,
13976                     Paul Eggert  <eggert@cs.ucla.edu>
13977
13978         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
13979         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
13980         drive prefix.
13981         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
13982         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
13983         (last_component): New method.
13984         * lib/dirname.c (dir_len): Determine when drive letters need a
13985         subsequent slash.  Preserve // when it is special.
13986         (dir_name): Don't append dot when drive letter is absolute.
13987         [TEST_DIRNAME]: Move into a full-blown gnulib test.
13988         * lib/basename.c (base_name): New semantics - malloc the result.
13989         Preserve // when it is special.  Preserve relative files that look
13990         like drive letters.
13991         (base_len): Preserve // when it is special.
13992         (last_component): New method, similar to old base_name semantics.
13993         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
13994         base_name.  Strip redundant slashes from ///.
13995
13996 2006-07-03  Jim Meyering  <jim@meyering.net>
13997
13998         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
13999         macro is used before the first cycle_check call.
14000
14001 2006-07-03  Eric Blake  <ebb9@byu.net>
14002
14003         * modules/dirname (Depends-on): Add xstrndup.
14004
14005 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
14006
14007         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
14008         test cases, so that config.log is a bit easier to follow.
14009
14010 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
14011
14012         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
14013         both are 64 bits, since this seems to be the tradition, and this
14014         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
14015         we ever run into a host that prefers long long to long in this
14016         case, we'll need another configure-time test.  Problem reported by
14017         Jim Meyering.
14018
14019 2006-07-02  Eric Blake  <ebb9@byu.net>
14020
14021         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
14022
14023 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
14024
14025         * modules/inttypes (Depends-on): No longer depends on stdint.
14026         * modules/stdint (Description): Say more about assumptions.
14027         Say that the fast types might differ.  Say macros are used.
14028         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
14029         (Makefile.am): Revise list of substituted symbols to match
14030         new stdint.m4.
14031         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
14032         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
14033         * tests/test-stdint.c (verify_same_types)
14034         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
14035         the code conforms to C99/C89.
14036         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
14037         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
14038
14039 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
14040
14041         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
14042         but fix a bug, by requiring at least 64 bits.
14043         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
14044         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
14045         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
14046         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
14047
14048         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
14049         changes.  Make 2.59 a prerequisite.  Check and substitute for
14050         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
14051         inttypes.h.  Do not use special include files; just use the
14052         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
14053         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
14054         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
14055         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
14056         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
14057         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
14058         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
14059         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
14060         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
14061         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
14062         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
14063         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
14064         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
14065         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
14066         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
14067         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
14068         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
14069         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
14070         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
14071         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
14072         WINT_MAX.  Check for C99 conformance more strictly, by detecting
14073         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
14074         not check for things that C99 does not require, e.g., int8_t.  If
14075         a test isn't needed unless <stdint.h> isn't working, and is
14076         unlikely to be needed for any other reason, then don't do it
14077         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
14078         size_t, since we assume C89 freestanding at least.  Do not check
14079         for sig_atomic_t, wchar_t, or wint_t, since the code now does
14080         the right thing even if the types are not defined.  Instead use:
14081         (gl_STDINT_TYPE_PROPERTIES): New macro.
14082         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
14083         testing whether <sys/types.h> clashes, as Autoconf does this for
14084         us now.  All uses removed.
14085         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
14086         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
14087         (gl_CHECK_TYPE_SAME):
14088         Remove; no longer needed.
14089         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
14090         exists, since we'll return 0 anyway in that case.
14091         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
14092
14093 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
14094
14095         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
14096         possible collision with system files.
14097         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
14098         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
14099         WCHAR_MIN and WCHAR_MAX in this case.
14100         (<stddef.h>): Do not include; no longer needed.
14101         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
14102         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
14103         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
14104         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
14105         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
14106         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
14107         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
14108         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
14109         !defined(__c99))]: Include in this case too, since it's harmless
14110         now.
14111         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
14112         dangerous to do so.
14113         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
14114         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
14115         (_STDINT_MIN, _STDINT_MAX): New macros.
14116         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
14117         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
14118         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
14119         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
14120         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
14121         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
14122         macros, not typedefs; this simplifies things quite a bit.
14123         Use long int for all types narrower than int64_t.
14124         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
14125         Define in terms of long long int or int64_t or long int,
14126         not int64_t or int32_t.  This saves some compile-time testing.
14127         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
14128         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
14129         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
14130         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
14131         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
14132         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
14133         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
14134         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
14135         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
14136         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
14137         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
14138         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
14139         undef any previous version and define our own version, for
14140         simplicity and consistency with the new macros for types.
14141         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
14142         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
14143         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
14144         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
14145         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
14146         @WINT_T_SUFFIX@ to keep things simple here.
14147         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
14148         Simplify by assuming typical 8/16/32/64 host, since we're
14149         already doing that elsewhere anyway.
14150         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
14151         and assume long long int is 64 bits if available.  This
14152         speeds up 'configure'.
14153
14154 2006-07-01  Eric Blake  <ebb9@byu.net>
14155
14156         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
14157         Reported by Andreas Buening.
14158
14159 2006-07-01  Eric Blake  <ebb9@byu.net>
14160
14161         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
14162
14163 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
14164
14165         * lib/getaddrinfo.c: fixed typo
14166
14167 2006-06-29  Jim Meyering  <jim@meyering.net>
14168
14169         * modules/strftime (Maintainer): Add my name, since with the
14170         FPRINTFTIME changes strftime.c has forked from glibc.
14171
14172 2006-06-29  Eric Blake  <ebb9@byu.net>
14173
14174         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
14175
14176 2006-06-29  Eric Blake  <ebb9@byu.net>
14177
14178         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
14179
14180 2006-06-29  Eric Blake  <ebb9@byu.net>
14181
14182         * lib/stat_.h: New file.
14183
14184 2006-06-29  Eric Blake  <ebb9@byu.net>
14185
14186         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
14187         unused static function.
14188
14189 2006-06-29  Eric Blake  <ebb9@byu.net>
14190
14191         * doc/functions.texi (Function Portability): Document missing lstat
14192         on mingw.
14193
14194 2006-06-29  Eric Blake  <ebb9@byu.net>
14195
14196         * MODULES.html.sh: Add sys_stat.
14197         * modules/sys_stat: New module.
14198         * modules/mkstemp (Depends-on): Add sys_stat.
14199
14200 2006-06-29  Derek R. Price  <derek@ximbiot.com>
14201
14202         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
14203
14204 2006-06-29  Derek R. Price  <derek@ximbiot.com>
14205
14206         * m4/c-bs-a.m4: Removed.
14207
14208 2006-06-29  Derek R. Price  <derek@ximbiot.com>
14209
14210         * lib/strftime.c: Assume strftime() exists.
14211
14212 2006-06-29  Derek Price  <derek@ximbiot.com>
14213
14214         * modules/c-bs-a: Removed - \a is C89.
14215         * MODULES.html.sh: Remove c-bs-a.
14216
14217 2006-06-29  Bruno Haible  <bruno@clisp.org>
14218
14219         * modules/wcwidth (License): Change to LGPL.
14220
14221 2006-06-28  Simon Josefsson  <jas@extundo.com>
14222
14223         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
14224         on _WIN32.
14225
14226         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
14227         getnameinfo.
14228
14229 2006-06-28  Simon Josefsson  <jas@extundo.com>
14230
14231         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
14232
14233 2006-06-28  Simon Josefsson  <jas@extundo.com>
14234
14235         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
14236         functions there.  It will succeed on Windows XP, but on Windows
14237         2000 and (presumably) earlier, it will fail, and use the internal
14238         re-implementation.
14239         (use_win32_p): New function.
14240         (getaddrinfo): Use strtoul on servname, to support numeric ports.
14241         Support AI_NUMERICSERV to disable getservbyname.
14242         (getnameinfo): New function, only supports
14243         NI_NUMERICHOST|NI_NUMERICSERV for now.
14244
14245         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
14246         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
14247         getnameinfo.
14248
14249 2006-06-28  Eric Blake  <ebb9@byu.net>
14250
14251         * modules/wcwidth: New file.
14252         * modules/mbchar (Depends-on): Add wcwidth.
14253         * modules/mbswidth (Depends-on): Add wcwidth.
14254         * MODULES.html.sh: Add wcwidth.
14255
14256 2006-06-28  Eric Blake  <ebb9@byu.net>
14257
14258         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
14259         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
14260
14261 2006-06-28  Eric Blake  <ebb9@byu.net>
14262
14263         * lib/xvasprintf.h: Fix comments.
14264
14265 2006-06-28  Eric Blake  <ebb9@byu.net>
14266
14267         * lib/mbchar.h (wcwidth): Include wcwidth.h.
14268         * lib/mbswidth.c (wcwidth): Move from here...
14269         * lib/wcwidth.h: ...to this new file.
14270
14271 2006-06-28  Derek R. Price  <derek@ximbiot.com>
14272
14273         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
14274
14275         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
14276         it's obsolete.
14277         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
14278
14279 2006-06-28  Derek R. Price  <derek@ximbiot.com>
14280
14281         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
14282         Autoconf 2.60 says this stuff was obsolete.
14283
14284 2006-06-28  Bruno Haible  <bruno@clisp.org>
14285
14286         * modules/wcwidth (Files): Add m4/wchar_t.m4.
14287
14288 2006-06-28  Bruno Haible  <bruno@clisp.org>
14289
14290         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
14291         gt_TYPE_WCHAR_T.
14292
14293 2006-06-28  Bruno Haible  <bruno@clisp.org>
14294
14295         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
14296         declaration for wcwidth.
14297         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
14298
14299 2006-06-28  Bruno Haible  <bruno@clisp.org>
14300
14301         * lib/mkdtemp.c [MINGW]: Include <io.h>.
14302         (mkdir): Define using _mkdir.
14303
14304 2006-06-28  Bruno Haible  <bruno@clisp.org>
14305
14306         * lib/getaddrinfo.h: Fix POSIX URL.
14307         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
14308         _WIN32.
14309         (use_win32_p): Make static.
14310         (getaddrinfo): Reject service name if it is empty or does not consist
14311         solely of decimal digits, or if its value is > 65535.
14312         (getnameinfo): Remove useless casts.
14313
14314 2006-06-27  Simon Josefsson  <jas@extundo.com>
14315
14316         * modules/sys_select: New file, suggested by Bruno Haible, Paul
14317         Eggert and Martin Lambers.
14318
14319 2006-06-27  Simon Josefsson  <jas@extundo.com>
14320
14321         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
14322         Eggert and Martin Lambers.
14323
14324 2006-06-27  Bruno Haible  <bruno@clisp.org>
14325
14326         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
14327         result to 0, not to empty.
14328         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
14329
14330 2006-06-27  Bruno Haible  <bruno@clisp.org>
14331
14332         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
14333
14334 2006-06-26  Simon Josefsson  <jas@extundo.com>
14335
14336         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
14337         present.
14338
14339 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
14340
14341         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
14342         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
14343         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
14344
14345 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
14346
14347         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
14348
14349 2006-06-26  Bruno Haible  <bruno@clisp.org>
14350
14351         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
14352
14353 2006-06-26  Bruno Haible  <bruno@clisp.org>
14354
14355         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
14356
14357 2006-06-26  Bruno Haible  <bruno@clisp.org>
14358
14359         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
14360         SGI C compiler in pre-C99 mode.
14361         Suggested by Mark D. Baushke and Larry Jones.
14362
14363 2006-06-26  Bruno Haible  <bruno@clisp.org>
14364
14365         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
14366         WCHAR_MAX.
14367         Reported by Mark D. Baushke and Larry Jones.
14368
14369 2006-06-26  Bruno Haible  <bruno@clisp.org>
14370
14371         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
14372         in pre-C99 mode.
14373         Suggested by Mark D. Baushke and Larry Jones.
14374
14375 2006-06-23  Simon Josefsson  <jas@extundo.com>
14376             Bruno Haible  <bruno@clisp.org>
14377
14378         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
14379         Emit mostlyclean-local rule.
14380         (func_emit_tests_Makefile_am): Likewise.
14381         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
14382
14383 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
14384
14385         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
14386
14387 2006-06-23  Bruno Haible  <bruno@clisp.org>
14388
14389         * tests/test-stdint.c: Update to match ISO C 99 Technical
14390         Corrigendum 1.
14391
14392 2006-06-23  Bruno Haible  <bruno@clisp.org>
14393
14394         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
14395
14396 2006-06-23  Bruno Haible  <bruno@clisp.org>
14397
14398         * lib/stdint_.h: Treat IRIX like OpenBSD.
14399
14400 2006-06-23  Bruno Haible  <bruno@clisp.org>
14401
14402         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
14403         ISO C 99 Technical Corrigendum 1.
14404
14405 2006-06-22  Simon Josefsson  <jas@extundo.com>
14406
14407         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
14408         MinGW.
14409
14410 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
14411
14412         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
14413         needed.  Some compiler complained about some of them.  Problem reported
14414         by Larry Jones in
14415         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
14416
14417 2006-06-21  Simon Josefsson  <jas@extundo.com>
14418
14419         * tests/test-getaddrinfo.c: New file.
14420
14421         * modules/getaddrinfo-tests: New file.
14422
14423         * MODULES.html.sh: Add inet_pton.
14424
14425         * modules/inet_pton: New file.
14426
14427 2006-06-21  Simon Josefsson  <jas@extundo.com>
14428
14429         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
14430         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
14431         of using the (limited) gnulib implementation on Windows XP.
14432
14433         * m4/inet_pton.m4: New file.
14434
14435 2006-06-21  Simon Josefsson  <jas@extundo.com>
14436
14437         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
14438         variable.
14439
14440         * lib/socket_.h: Don't define WINVER.
14441
14442         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
14443         slightly modified to work in gnulib.
14444
14445 2006-06-21  Simon Josefsson  <jas@extundo.com>
14446
14447         * doc/gnulib.texi (Windows sockets): Add.
14448
14449 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
14450
14451         * lib/read-file.c (fread_file): Start with buffer allocation of
14452         0 bytes rather than 1 byte; this simplifies the code.
14453         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
14454         code to free buffer and save/restore errno.
14455         (internal_read_file): Remove unused local.
14456
14457 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
14458
14459         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
14460         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
14461         Problem reported by Denis Excoffier in
14462         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
14463
14464 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
14465
14466         * modules/sys_socket, modules/socklen: Include sys/types since
14467         FreeBSD 4.x's sys/socket.h needs it.
14468
14469 2006-06-19  Simon Josefsson  <jas@extundo.com>
14470
14471         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
14472
14473 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
14474
14475         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
14476
14477 2006-06-19  Bruno Haible  <bruno@clisp.org>
14478
14479         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
14480         and FULL_PATH_INTTYPES_H in angle brackets.
14481         Reported by Mark D. Baushke <mdb@gnu.org>.
14482
14483 2006-06-17  Eric Blake  <ebb9@byu.net>
14484
14485         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
14486         errno.
14487
14488 2006-06-17  Bruno Haible  <bruno@clisp.org>
14489
14490         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
14491         <sys/inttypes.h>.
14492
14493 2006-06-17  Bruno Haible  <bruno@clisp.org>
14494
14495         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
14496         whether errno is declared. Assume <errno.h> declares errno.
14497
14498 2006-06-17  Bruno Haible  <bruno@clisp.org>
14499
14500         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
14501
14502 2006-06-17  Bruno Haible  <bruno@clisp.org>
14503
14504         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
14505         problem on Solaris 2.5.1.
14506
14507 2006-06-16  Eric Blake  <ebb9@byu.net>
14508
14509         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
14510         * lib/unicodeio.c [!defined errno]: Likewise.
14511         * lib/strtol.c [!defined errno]: Likewise.
14512         * lib/strtod.c [!defined errno]: Likewise.
14513
14514 2006-06-15  Eric Blake  <ebb9@byu.net>
14515
14516         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
14517
14518 2006-06-15  Eric Blake  <ebb9@byu.net>
14519
14520         * config/srclist.txt (ssize_t.m4): Lose sync.
14521
14522 2006-06-15  Bruno Haible  <bruno@clisp.org>
14523
14524         * modules/stdint (Files): Include m4/full-header-path.m4,
14525         m4/size_max.m4, m4/wchar_t.m4.
14526         (Makefile.am): Many more substitutions.
14527         * modules/stdint-tests: New file.
14528         * tests/test-stdint.c: New file.
14529
14530 2006-06-15  Bruno Haible  <bruno@clisp.org>
14531
14532         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
14533         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
14534         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
14535         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
14536         gl_CHECK_TYPE_SAME): New macros.
14537
14538 2006-06-15  Bruno Haible  <bruno@clisp.org>
14539
14540         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
14541
14542 2006-06-15  Bruno Haible  <bruno@clisp.org>
14543
14544         * lib/stdint_.h: Rewritten to be fully auto-configured.
14545         Fixes bug on HP-UX/IA64.
14546
14547 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
14548
14549         * lib/getdate.y (__attribute__): Don't define if already defined.
14550         Problem reported by Larry Jones.
14551         * lib/utimens.c (__attribute__): Likewise.
14552
14553 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
14554
14555         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
14556         reported by Andreas Schwab.
14557
14558 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14559             Bruno Haible  <bruno@clisp.org>
14560
14561         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
14562         check for the declaration of strnlen and a run test that exposes the
14563         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
14564         rpl_strndup.
14565
14566 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14567             Bruno Haible  <bruno@clisp.org>
14568
14569         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
14570
14571 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14572
14573         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
14574         compile test, for Tru64 4.0D.
14575
14576 2006-05-28  Karl Berry  <karl@gnu.org>
14577
14578         * config/srclist.txt (printf-args.c): lose sync.
14579
14580 2006-05-26  Martin Lambers  <marlam@marlam.de>
14581
14582         * lib/getpass.c: Updates the test for the native W32 API, and adds
14583         missing includes, thus fixing compilation warnings.
14584
14585 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
14586
14587         * lib/exclude.c (exclude_fnmatch): New function.
14588         (excluded_file_name): Call exclude_fnmatch.
14589         * lib/exclude.h (excluded_file_name): New prototype
14590
14591 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
14592
14593         * lib/tempname.c (small_open, large_open): New macros.
14594         (__open, __open64) [!_LIBC]: Remove.
14595         (__gen_tempname): Use small_open and large_open instead of __open
14596         and __open64.  This fixes a portability bug on HP-UX 11.11i
14597         reported by Simon Wing-Tang in
14598         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
14599
14600 2006-05-24  Bruno Haible  <bruno@clisp.org>
14601
14602         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
14603         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
14604         Reported by Thorsten Maerz <torte@netztorte.de> via
14605         Aaron Stone <aaron@serendipity.cx>.
14606
14607 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
14608
14609         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
14610         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
14611         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
14612         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
14613         not really conditional on the cache.
14614         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
14615
14616 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
14617
14618         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
14619         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
14620         (my_usleep): Don't mishandle maximum value.
14621
14622 2006-05-19  Jim Meyering  <jim@meyering.net>
14623
14624         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
14625
14626 2006-05-17  Bruno Haible  <bruno@clisp.org>
14627
14628         Cygwin portability.
14629         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
14630
14631 2006-05-17  Bruno Haible  <bruno@clisp.org>
14632
14633         * lib/stdint_.h: Fix recognition of Cygwin.
14634
14635 2006-05-15  Bruno Haible  <bruno@clisp.org>
14636
14637         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
14638         on libtool patch by Ralf Wildenhues.
14639
14640 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
14641
14642         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
14643         test for C99 conformance; (bool) 0.5 is an integer constant
14644         expression, but (bool) -0.5 is not.  Problem reported by Fedor
14645         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
14646
14647 2006-05-11  Simon Josefsson  <jas@extundo.com>
14648
14649         * m4/xvasprintf.m4: Fix obvious typo.
14650
14651 2006-05-11  Jim Meyering  <jim@meyering.net>
14652
14653         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
14654         James Lemley.
14655
14656 2006-05-10  Simon Josefsson  <jas@extundo.com>
14657
14658         * lib/md4.c: Typo fix, update copyright years.
14659         (K1, K2): Don't use L because it turn computations into 64-bit on
14660         64-bit platforms.
14661
14662 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
14663
14664         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
14665         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
14666         unwanted sign propagation, e.g., on hosts with 64-bit int.
14667         There still are some problems with reeelly weird theoretical hosts
14668         (e.g., 33-bit int) but it's not worth worrying about now.
14669         * lib/sha1.c (rol): Likewise.
14670         (K1, K2, K3, K4): Remove unnecessary L suffix.
14671
14672 2006-05-10  Bruno Haible  <bruno@clisp.org>
14673
14674         * lib/des.c: Cast to avoid warnings.
14675
14676 2006-05-09  Bruno Haible  <bruno@clisp.org>
14677
14678         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
14679         (Depends-on): Depend also on xsize, stdarg.
14680         (configure.ac): Add gl_XVASPRINTF.
14681
14682 2006-05-09  Bruno Haible  <bruno@clisp.org>
14683
14684         * m4/xvasprintf.m4: New file.
14685
14686 2006-05-09  Bruno Haible  <bruno@clisp.org>
14687
14688         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
14689         (EOVERFLOW): Define fallback value.
14690         (xstrcat): New function.
14691         (xvasprintf): Recognize the special case of a string concatenation.
14692
14693 2006-05-08  Eric Blake  <ebb9@byu.net>
14694
14695         * gnulib-tool (func_version): Base copyright year on CVS date.
14696         (func_emit_copyright_notice): New function.
14697         (func_emit_lib_Makefile_am): Use it.
14698         (func_emit_tests_Makefile_am): Likewise.
14699         (func_import): Likewise.
14700
14701 2006-05-08  Bruno Haible  <bruno@clisp.org>
14702
14703         * modules/stdarg: New file.
14704         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
14705
14706 2006-05-08  Bruno Haible  <bruno@clisp.org>
14707
14708         * m4/stdarg.m4: New file, from GNU gettext.
14709
14710 2006-05-08  Bruno Haible  <bruno@clisp.org>
14711
14712         * config/srclist.txt (build-aux/config.rpath): different from latest
14713         release.
14714
14715 2006-05-08  Bruno Haible  <bruno@clisp.org>
14716
14717         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
14718
14719 2006-05-05  Jim Meyering  <jim@meyering.net>
14720
14721         * m4/warning.m4: New file, derived from bison's file by the same name.
14722
14723 2006-05-03  Bruno Haible  <bruno@clisp.org>
14724
14725         * lib/stdint_.h: Shorter URL.
14726         * lib/inttypes.h: Likewise.
14727
14728 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14729
14730         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
14731
14732 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14733
14734         * lib/verify.h: Document the internals better.  Most of this change
14735         was written by Bruno Haible.
14736
14737 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14738
14739         * doc/verify.texi: New file, partly based on a proposal by
14740         Bruno Haible.
14741
14742 2006-05-02  Bruno Haible  <bruno@clisp.org>
14743
14744         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
14745         test from here...
14746         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
14747
14748 2006-04-29  Bruno Haible  <bruno@clisp.org>
14749
14750         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
14751         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
14752
14753 2006-04-29  Bruno Haible  <bruno@clisp.org>
14754
14755         * gnulib-tool: Make --update option actually work.
14756
14757 2006-04-29  Bruno Haible  <bruno@clisp.org>
14758
14759         * doc/gcd.texi: New file.
14760         * doc/gnulib.texi: Include it.
14761
14762 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
14763
14764         * lib/getdate.y (get_date): When adding relative date, start with the
14765         initial time, not with the result of the first mktime call.
14766
14767 2006-04-25  Bruno Haible  <bruno@clisp.org>
14768
14769         * gnulib-tool (func_import): Output the include directives in three
14770         blocks, sorted separately.
14771         Reported by Ben Pfaff <blp@cs.stanford.edu>.
14772
14773 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
14774
14775         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
14776         to define main with arguments, for C++.  Reported by Eric Blake.
14777         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
14778         Prefer 'int main ()' to 'int main (void)', for C++.
14779         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
14780         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
14781         for 'main', for C99 and C++.
14782
14783 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
14784
14785         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
14786         Don't assume that exit status -1 is valid.
14787         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
14788         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
14789         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
14790         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
14791         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
14792         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
14793         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
14794         functions can be used without declaring them, or that you can
14795         exit with status -1.
14796         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
14797
14798 2006-04-24  Karl Berry  <karl@gnu.org>
14799
14800         * config/srclist.txt (longdouble.m4): sync lost.
14801
14802 2006-04-24  Eric Blake  <ebb9@byu.net>
14803
14804         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
14805
14806 2006-04-24  Bruno Haible  <bruno@clisp.org>
14807
14808         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
14809         poll() implementation in AIX.
14810         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14811
14812 2006-04-24  Bruno Haible  <bruno@clisp.org>
14813
14814         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
14815         assigned exactly once.
14816
14817 2006-04-23  Claudio Fontana  <claudio@gnu.org>
14818             Bruno Haible  <bruno@clisp.org>
14819
14820         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
14821         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
14822         for AM_CPPFLAGS.
14823
14824 2006-04-23  Bruno Haible  <bruno@clisp.org>
14825
14826         * modules/copy-file: Depend on unistd.
14827         * modules/execute: Likewise.
14828         * modules/fatal-signal: Likewise.
14829         * modules/findprog: Likewise.
14830         * modules/mkdtemp : Likewise.
14831         * modules/pipe: Likewise.
14832         * modules/wait-process: Likewise.
14833
14834 2006-04-23  Bruno Haible  <bruno@clisp.org>
14835
14836         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
14837         condition was already detected.
14838         Reported by Ben Pfaff <blp@cs.stanford.edu>.
14839
14840 2006-04-23  Bruno Haible  <bruno@clisp.org>
14841
14842         * lib/copy-file.c: Include <unistd.h> unconditionally.
14843         * lib/execute.c: Likewise.
14844         * lib/fatal-signal.c: Likewise.
14845         * lib/findprog.c: Likewise.
14846         * lib/mkdtemp.c: Likewise.
14847         * lib/pipe.h: Likewise.
14848         * lib/pipe.c: Likewise.
14849         * lib/wait-process.h: Likewise.
14850
14851 2006-04-23  Bruno Haible  <bruno@clisp.org>
14852
14853         * gnulib-tool (func_usage): Fix --import description. Document
14854         --update.
14855         (func_import): Create temporary file in a temporary directory, if
14856         --dry-run is specified. Silence errors from 'grep' when there are no
14857         m4 files in $m4dir.
14858         (func_create_testdir): Silence errors from 'grep' when there are no
14859         m4 files in $m4dir.
14860         Reported by Karl Berry <karl@freefriends.org>.
14861
14862 2006-04-20  Bruno Haible  <bruno@clisp.org>
14863
14864         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
14865         one argument, so that the code will be portable to Autoconf 2.60.
14866         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
14867         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
14868         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
14869
14870 2006-04-19  Derek Price  <derek@ximbiot.com>
14871             Eric Blake  <ebb9@byu.net>
14872
14873         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
14874         rather than "/full/path.h".  Update comment to match.  Shorten &
14875         generalize m4_translit call via AS_TR_CPP.
14876
14877 2006-04-19  Derek Price  <derek@ximbiot.com>
14878             Eric Blake  <ebb9@byu.net>
14879
14880         * lib/inttypes.h: Correct grammar in comment.
14881
14882 2006-04-18  Derek Price  <derek@ximbiot.com>
14883             Paul Eggert  <eggert@cs.ucla.edu>
14884
14885         * modules/inttypes: New file.
14886         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
14887
14888 2006-04-18  Derek Price  <derek@ximbiot.com>
14889             Paul Eggert  <eggert@cs.ucla.edu>
14890
14891         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
14892         New files.
14893
14894 2006-04-18  Derek Price  <derek@ximbiot.com>
14895             Paul Eggert  <eggert@cs.ucla.edu>
14896
14897         * lib/inttypes.h: New file.
14898         * lib/strtoimax.c: Assume <inttypes.h>.
14899
14900 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
14901
14902         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
14903         isn't mounted.  Problem reported by Kir Kolyshkin.
14904
14905 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
14906
14907         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
14908         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
14909         Derek R. Price.
14910         * lib/regex.h (RE_DUP_MAX): Update comment to match current
14911         implementation.
14912
14913 2006-04-12  Eric Blake  <ebb9@byu.net>
14914
14915         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
14916         is now done automatically by the corresponding Autoconf macro.
14917
14918 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
14919
14920         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
14921         time_r.h.
14922
14923 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
14924
14925         Merge regex changes from libc, removing some of our
14926         POSIX-conformance changes that were rejected and redoing them in a
14927         less-intrusive way.
14928
14929         * lib/regcomp.c (re_compile_internal, init_dfa):
14930         Length arg is now size_t, not Idx.  All uses changed.
14931         (peek_token): Forward decl now says internal_function.
14932         (__re_error_msgid, __re_error_msgid_idx):
14933         Now static rather than extern with attribute_hidden.
14934         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
14935         For some reason libc prefers K&R style defns for external functions.
14936         (regerror) [!defined _LIBC]: Likewise.
14937         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
14938         (seek_collating_symbol_entry, lookup_collation_sequence_value):
14939         (build_range_exp, build_collating_symbol):
14940         Use K&R-style defn.
14941         (re_compile_fastmap): Use '\0' to memset, not 0.
14942         (utf8_sb_map): Make the calculations more obvious.
14943         (init_dfa, parse_bracket_exp, build_charclass_op):
14944         Call calloc and cast result, as glibc does.
14945         (init_word_char, fetch_token, peek_token, peek_token_bracket):
14946         (build_range_exp, build_collating_symbol):
14947         Now internal functions.
14948
14949         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
14950
14951         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
14952         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
14953         Don't depend on VMS; depend on __VMS instead, for POSIX
14954         namespace cleanness.
14955         (regoff_t): Define to ssize_t, not long int.
14956
14957         Remove the REG_ macros named below.  Instead, make the old names
14958         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
14959         __USE_GNU_REGEX.
14960         (REG_BACKSLASH_ESCAPE_IN_LISTS):
14961         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
14962         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
14963         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
14964         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
14965         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
14966         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
14967         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
14968         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
14969         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
14970         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
14971         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
14972         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
14973         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
14974         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
14975         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
14976         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
14977         (REG_NREGS):
14978         Remove.  All uses replaced by the old RE_* names.
14979         (RE_BACKSLASH_ESCAPE_IN_LISTS):
14980         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
14981         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
14982         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
14983         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
14984         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
14985         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
14986         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
14987         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
14988         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
14989         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
14990         Don't bother having these macros be independent of each others'
14991         values, since they no longer exist in the POSIX name space.
14992
14993         Rename the following member names back to their old names,
14994         unless !__USE_GNU_REGEX.  All uses changed back.
14995         (buffer): Renamed from re_buffer.
14996         (allocated): Renamed from re_allocated.
14997         (used): Renamed from re_used.
14998         (syntax): Renamed from re_syntax.
14999         (fastmap): Renamed from re_fastmap.
15000         (translate): Renamed from re_translate.
15001         (can_be_null): Renamed from re_can_be_null.
15002         (regs_allocated): Renamed from re_regs_allocated.
15003         (fastmap_accurate): Renamed from re_fastmap_accurate.
15004         (no_sub): Renamed from re_no_sub.
15005         (not_bol): Renamed from re_not_bol.
15006         (not_eol): Renamed from re_not_eol.
15007         (newline_anchor): Renamed from re_newline_anchor.
15008         (num_regs): Renamed from rm_num_regs.
15009         (start): Renamed from rm_start.
15010         (end): Renamed from rm_end.
15011
15012         (free_state): Move up a bit.
15013
15014         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
15015         #define to be empty.
15016         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
15017         when that is what is intended.
15018         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
15019         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
15020         (MAX): New macro.
15021         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
15022         All uses changed back to re_malloc, etc.  It's now the caller's
15023         responsibility to check for overflow; all callers changed.
15024         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
15025         (re_x2nrealloc): Remove.
15026         (free_state): Remove decl.
15027
15028         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
15029         (re_set_registers, re_exec):
15030         Use K&R-style defn.
15031
15032         2006-01-31  Roland McGrath  <roland@redhat.com>
15033
15034         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
15035         Reported by Mike Frysinger <vapier@gentoo.org>.
15036
15037         2006-01-15  Andreas Jaeger  <aj@suse.de>
15038
15039         [BZ #1950]
15040         * lib/regex_internal.c (re_string_reconstruct): Adjust for
15041         build_wcs_upper_buffer change.
15042         (build_wcs_upper_buffer): Change return type.
15043
15044         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
15045
15046         * lib/regex_internal.h: Include <stdint.h> if available.
15047
15048         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
15049
15050         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
15051
15052         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
15053
15054         * lib/regcomp.c: Adjust for changed secondary hash function.
15055
15056         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
15057
15058         * lib/regex.h: Pretty printing.
15059         Clean up namespace a bit.
15060
15061         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
15062
15063         * lib/regexec.c (update_cur_sifted_state, check_arrival,
15064         check_arrival_add_next_nodes): Avoid using uninitialized variable.
15065
15066         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
15067                     Ulrich Drepper  <drepper@redhat.com>
15068
15069         [BZ #1302]
15070         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
15071         changed.
15072         (bitset_word_t): Renamed from bitset_word.  All uses changed.
15073
15074         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
15075
15076         [BZ #281]
15077         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
15078         * lib/regcomp.c: Remove unnecessary uses of
15079         unsigned RE_TRANSLATE_TYPE.
15080         * lib/regex_internal.h: Likewise.
15081         * lib/regex_internal.c: Likewise.
15082         * lib/regexec.c: Likewise.
15083         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
15084
15085         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
15086
15087         * lib/regexec.c (find_recover_state): Remove unnecessary
15088         initialization.
15089         (transit_state_bkref): Make DFA a const pointer.
15090         (get_subexp): Likewise.
15091         (check_arrival): Likewise.
15092         (update_cur_sifted_state): Likewise.
15093         (re_search_internal): Likewise.
15094         (prune_impossible_nodes): Likewise.
15095         (acquire_init_state_context): Likewise.
15096         (proceed_next_node): Likewise.
15097         (set_regs): Likewise.
15098         (free_fail_stack_return): Likewise.
15099         (check_arrival_expand_ecl): Mark DFA parameter as const.
15100         (check_arrival_expand_ecl_sub): Likewise.
15101         (check_subexp_limits): Likewise.
15102         (sub_epsilon_src_nodes):  Likewise.
15103         (add_epsilon_src_nodes):  Likewise.
15104         (merge_state_array): Likewise.
15105         (update_regs): Likewise.
15106         (build_trtable): Likewise.
15107         (sift_states_backward): Mark MCTX parameter as const.
15108         (build_sifted_states): Likewise.
15109         (update_cur_sifted_state): Likewise.
15110         (sift_states_mkref): Likewise.
15111         (check_arrival_expand_ecl): Mark eclosure as const.
15112         (check_dst_limits_calc_pos_1): Likewise.
15113         * lib/regex_internal.h (re_match_context_t): Make dfa a const
15114         pointer.
15115
15116         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
15117
15118         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
15119         (transit_state_sb): Likewise.
15120         (transit_state_mb): Likewise.
15121         (sift_states_iter_mb): Likewise.
15122         (check_arrival_add_next_nodes): Likewise.
15123         (check_node_accept_bytes): Change first parameter to pointer-to-const.
15124         [_LIBC] (re_search_2_stub): Use mempcpy.
15125
15126         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
15127         mbrtowc for very simple UTF-8 case.
15128
15129         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
15130         a pointer-to-const.
15131         (re_acquire_state_context): Likewise.
15132         * lib/regex_internal.h: Adjust prototypes.
15133
15134         * lib/regex.c: Prevent using C++ compilers.
15135
15136         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
15137         (re_acquire_state_context): Likewise.
15138
15139 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
15140
15141         * modules/regex (Depends-on): Add ssize_t.
15142
15143 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
15144
15145         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
15146         translation table.
15147
15148 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
15149
15150         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
15151
15152 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
15153             Bruno Haible  <bruno@clisp.org>
15154
15155         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
15156         <sys/types.h> and <inttypes.h>.
15157
15158 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15159
15160         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
15161         `__error_t_defined', so argp.h will not typedef the former.
15162
15163 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
15164
15165         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
15166         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
15167         glibc names.  Even if glibc is changed to conform to POSIX, the
15168         traditional names will be available anyway, since regex depends on
15169         the extensions module.  Also, fix a longstanding typo in the
15170         implementation of Spencer ERE test #75 from grep 2.3.  Problems
15171         reported by Emanuele Giaquinta.  Also, change sense of cached
15172         variable, so that the message makes sense.
15173
15174 2006-03-24  Simon Josefsson  <jas@extundo.com>
15175
15176         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
15177         including some doc fixes.
15178         (base64_encode_alloc): Fix +1 bug on allocation failures.
15179
15180 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15181
15182         * lib/base64.c (base64_encode): Do not read past end of array with
15183         unsanitized input on systems with CHAR_BIT > 8.
15184
15185 2006-03-24  Eric Blake  <ebb9@byu.net>
15186
15187         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
15188
15189 2006-03-22  Karl Berry  <karl@gnu.org>
15190
15191         * config/srclist.txt (*setenv.[ch]): get from coreutils.
15192         * config/srclistvars.sh (COREUTILS): new var.
15193
15194 2006-03-17  Jim Meyering  <jim@meyering.net>
15195
15196         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
15197         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
15198
15199 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
15200
15201         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
15202         no longer needs it.  Instead, check that regoff_t is as least
15203         as wide as ptrdiff_t.
15204
15205         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
15206         so that our regex.h stays compatible with the installed regex.
15207         This is helpful for installers who configure --without-included-regex.
15208         Problem reported by Emanuele Giaquinta.
15209
15210 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
15211
15212         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
15213         Typedef to long int, not to off_, as POSIX will likely change
15214         in that direction.
15215
15216 2006-03-15  Eric Blake  <ebb9@byu.net>
15217
15218         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
15219
15220 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
15221
15222         * lib/argp-help.c (validate_uparams): Fix typo
15223         * lib/argp-parse.c (argp_default_options): Consistently begin help
15224         messages with a lowercase letter.
15225
15226 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
15227
15228         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
15229         overrun buffers and shouldn't be used (much as gets shouldn't be
15230         used).
15231         * lib/time_r.c (asctime_r, ctime_r): Likewise.
15232
15233 2006-03-08  Simon Josefsson  <jas@extundo.com>
15234
15235         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
15236         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15237
15238 2006-03-08  Simon Josefsson  <jas@extundo.com>
15239
15240         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
15241         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15242
15243 2006-03-08  Simon Josefsson  <jas@extundo.com>
15244
15245         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
15246         signal that configure disabled the device.
15247
15248 2006-03-08  Simon Josefsson  <jas@extundo.com>
15249
15250         * build-aux/maint.mk: Fix refresh-po, to handle no translated
15251         languages.
15252
15253 2006-03-07  Simon Josefsson  <jas@extundo.com>
15254
15255         * modules/getopt (Depends-on): Add unistd.
15256
15257         * modules/unistd: New file.
15258
15259 2006-03-07  Simon Josefsson  <jas@extundo.com>
15260
15261         * modules/gc-random: New file.
15262
15263 2006-03-07  Simon Josefsson  <jas@extundo.com>
15264
15265         * m4/unistd_h.m4: New file.
15266
15267 2006-03-07  Simon Josefsson  <jas@extundo.com>
15268
15269         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
15270         test to be side-effect free by storing the result in the cache
15271         variable gl_cv_lib_readline, and moving the assignment of
15272         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
15273         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15274
15275 2006-03-07  Simon Josefsson  <jas@extundo.com>
15276
15277         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
15278         error on missing devices (the functions will return an error).
15279
15280         * m4/gc.m4: Move random stuff to gc-random.m4
15281
15282 2006-03-07  Simon Josefsson  <jas@extundo.com>
15283
15284         * lib/unistd_.h: New file.
15285
15286 2006-03-07  Simon Josefsson  <jas@extundo.com>
15287
15288         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
15289
15290 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
15291
15292         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
15293         Problem reported by Juan Manuel Guerrero.
15294
15295 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
15296
15297         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
15298         the unistd module.
15299         * lib/getlogin_r.c: Likewise.
15300         * lib/getlogin_r.h: Likewise.
15301         * lib/glob.c: Likewise.
15302         * lib/pagealign_alloc.c: Likewise.
15303         * lib/unistd_.h: Remove; no longer needed.
15304
15305 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
15306
15307         * MODULES.html.sh (Support for systems lacking POSIX:2001):
15308         Add unistd.
15309         * modules/c-stack (Depends-on): Add unistd.
15310         * modules/getlogin_r: Likewise.
15311         * modules/glob: Likewise.
15312         * modules/pagealign_alloc: Likewise.
15313         * modules/unistd (Files): Remove lib/unistd_.h.
15314         (EXTRA_DIST): Remove.
15315         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
15316         need unistd_.h.
15317         (MOSTLYCLEANFILES): Remove unistd.h-t.
15318
15319 2006-03-03  Simon Josefsson  <jas@extundo.com>
15320
15321         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
15322
15323 2006-03-03  Simon Josefsson  <jas@extundo.com>
15324
15325         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
15326         libidn and bison.
15327
15328 2006-03-03  Simon Josefsson  <jas@extundo.com>
15329
15330         * build-aux/maint.mk: Add indent target.
15331
15332 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
15333
15334         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
15335         our replacement poll.h in any case, to avoid a differing
15336         declaration from a system header.  Seen on AIX.
15337
15338 2006-03-01  Simon Josefsson  <jas@extundo.com>
15339
15340         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
15341         <kasal@ucw.cz>.
15342
15343 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
15344
15345         * modules/gettime (Depends-on): Add extensions module.
15346         * modules/nanosleep (Depends-on): Likewise.
15347         * modules/settime (Depends-on): Likewise.
15348
15349 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
15350
15351         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
15352         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
15353         pedantically.
15354         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
15355         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
15356
15357         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
15358         not "==".  Reported by Ralf Wildenhues.
15359
15360 2006-03-01  Karl Berry  <karl@gnu.org>
15361
15362         * doc/Copyright/request-*: new files, synced from gnuorg.
15363
15364 2006-03-01  Karl Berry  <karl@gnu.org>
15365
15366         * config/srclist.txt (Copyright/*): new entries.
15367
15368 2006-02-28  Simon Josefsson  <jas@extundo.com>
15369
15370         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
15371
15372 2006-02-27  Simon Josefsson  <jas@extundo.com>
15373
15374         * lib/base64.h: Indent #define's.  From Jim Meyering
15375         <jim@meyering.net>.
15376
15377 2006-02-27  Jim Meyering  <jim@meyering.net>
15378
15379         Revert the change of 2006-02-24, so these files can continue
15380         to be sync'd from gettext.
15381         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
15382         of `config.h'.
15383
15384 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
15385
15386         * modules/intprops: New file.
15387         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
15388         Add intprops.
15389         * modules/getloadavg (Files): Remove lib/intprops.h.
15390         (Depends-on): Add intprops.
15391         * modules/human: Likewise.
15392         * modules/inttostr: Likewise.
15393         * modules/openat: Likewise.
15394         * modules/sig2str: Likewise.
15395         * modules/userspec: Likewise.
15396         * modules/utimecmp: Likewise.
15397         * modules/xnanosleep: Likewise.
15398         * modules/xstrtol: Likewise.
15399
15400 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
15401
15402         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
15403         * modules/lock-tests (TESTS): Use $(EXEEXT).
15404         * modules/tls-tests: Likewise.
15405         * modules/argp-tests: Likewise.
15406         (check_PROGRAMS): New var, replacing...
15407         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
15408
15409 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15410
15411         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
15412         `config.h'.
15413
15414 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
15415
15416         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
15417
15418 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15419
15420         Sync from coreutils.
15421         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
15422         gl_CHDIR_SAFER.
15423
15424 2006-02-22  Jim Meyering  <jim@meyering.net>
15425
15426         Sync from coreutils.
15427         * m4/chdir-safer.m4: New file.
15428
15429 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
15430
15431         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
15432         AT_FDCWD exceeds INT_MAX.
15433         * lib/openat.h (AT_FDCWD): Likewise.
15434
15435 2006-02-17  Eric Blake  <address@hidden>
15436
15437         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
15438
15439 2006-02-16  Simon Josefsson  <jas@extundo.com>
15440
15441         * modules/getaddrinfo (Depends-on): Add sys_socket.
15442
15443 2006-02-15  Simon Josefsson  <jas@extundo.com>
15444
15445         * build-aux/maint.mk: Add dsyntax-check rule.
15446
15447 2006-02-15  Eric Blake  <ebb9@byu.net>
15448
15449         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
15450         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
15451         'present but cannot compile' warnings on cygwin.
15452         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
15453         use ws2tcpip.h if sys/socket.h works.
15454         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
15455         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
15456
15457 2006-02-14  Simon Josefsson  <jas@extundo.com>
15458
15459         * modules/maintainer-makefile (Files): Rename.
15460
15461         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
15462         and (the local) Makefile.cfg to maint-cfg.mk.
15463
15464         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
15465         to the latter.
15466
15467         * modules/maintainer-makefile: New module.
15468
15469         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
15470         severaly stripped to make it possible to build it up from scratch
15471         with reliable tests.
15472
15473         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
15474         fixes to permit overriding the default actions when configure and
15475         makefile are not available.
15476
15477 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
15478
15479         Sync from coreutils.
15480         * modules/lstat (Depends-on): Don't depend on xalloc.
15481         (License): Change from GPL to LGPL, since this is now simply a
15482         replacement for a libc function.
15483
15484 2006-02-14  Jim Meyering  <jim@meyering.net>
15485
15486         Sync from coreutils.
15487
15488         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
15489         failure on deficient systems, and simplify gnulib lgpl dependencies.
15490         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
15491         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
15492
15493         * lib/xalloc-die.c: Remove unused definition of N_.
15494
15495 2006-02-14  Jim Meyering  <jim@meyering.net>
15496
15497         Sync from coreutils.
15498         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
15499         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
15500         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
15501         double-quote uses of that variable, to accommodate the rare case in
15502         which getmntent is available in none of the libraries checked.  This
15503         happens at least on FreeBSD 5.0.
15504
15505 2006-02-13  Simon Josefsson  <jas@extundo.com>
15506
15507         * gnulib-tool (Usage): Fix --import, from
15508         karl@freefriends.org (Karl Berry).
15509
15510 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
15511
15512         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
15513
15514 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
15515
15516         * lib/argp-namefrob.h: Restore changes accidentally lost during the
15517         "autoupdate" on 2005-12-12.
15518
15519 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
15520
15521         * modules/closeout (Depends-on): Remove atexit.
15522
15523 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
15524
15525         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
15526         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
15527
15528 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
15529
15530         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
15531         __EXTENSIONS__ if this causes compilation to fail.  Problem
15532         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
15533         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
15534
15535 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
15536
15537         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
15538         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
15539         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
15540         All uses changed.
15541
15542 2006-01-26  Simon Josefsson  <jas@extundo.com>
15543
15544         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
15545         prototype is visible on mingw32.
15546
15547         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
15548         for mingw32.
15549
15550         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
15551         mingw32).
15552
15553 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
15554
15555         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
15556         attempt to open for write; this always fails, at least on POSIX
15557         hosts.  This reinstates the 2006-01-09 change, which was
15558         inadvertently removed.
15559
15560 2006-01-26  Bruno Haible  <bruno@clisp.org>
15561
15562         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
15563         Reported by Paul Eggert.
15564
15565 2006-01-26  Bruno Haible  <bruno@clisp.org>
15566             Paul Eggert  <eggert@cs.ucla.edu>
15567
15568         * lib/stdbool_.h (_Bool)
15569         [(! (defined __cplusplus || defined __BEOS__)
15570           && !defined __GNUC__
15571           && !(defined __HP_cc || defined __xlc__
15572                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
15573                || defined __sgi))]:
15574         #define to signed char in these cases too; this simplifies
15575         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
15576         etc., separately) and makes it more conservative.
15577
15578 2006-01-25  Simon Josefsson  <jas@extundo.com>
15579
15580         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
15581         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
15582         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
15583
15584 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
15585
15586         * lib/argp-namefrob.h: Bugfix. Remove stray #
15587
15588 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
15589
15590         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
15591         so that we test the test.
15592         Check for yet another HP-UX cc bug involving *bool |= bool.
15593
15594 2006-01-25  Karl Berry  <karl@gnu.org>
15595
15596         * config/srclist.txt (vasnprintf.c): sync lost.
15597
15598 2006-01-25  Jim Meyering  <jim@meyering.net>
15599
15600         Sync from the stable (b5) branch of coreutils:
15601
15602         * lib/fts.c (fts_children): Don't let close() clobber errno from
15603         failed fchdir().
15604
15605         * lib/fts.c (fts_stat): When following a symlink-to-directory,
15606         don't necessarily interpret stat-fails+lstat-succeeds as indicating
15607         a dangling symlink.  That can also happen at least for ELOOP.
15608         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
15609         FYI, this bug predates the inclusion of fts.c in coreutils.
15610
15611         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
15612         in their own block, so pre-c99 compilers don't object.
15613
15614         Avoid the double-free (first in fts_read, second in fts_close) that
15615         would occur when an `active' directory is made inaccessible (e.g.,
15616         via chmod a-x) during a traversal.
15617         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
15618         before returning.  Reproduce this failure by
15619         mkdir -p a/b; cd a; chmod a-x . b
15620         Reported by Stavros Passas.
15621
15622 2006-01-25  Jim Meyering  <jim@meyering.net>
15623
15624         * lib/fileblocks.c: Remove more useless parentheses.
15625         * lib/readutmp.h: Likewise.
15626
15627 2006-01-25  Bruno Haible  <bruno@clisp.org>
15628
15629         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
15630         warnings.
15631         Reported by Paul Eggert.
15632
15633 2006-01-25  Bruno Haible  <bruno@clisp.org>
15634
15635         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
15636         rid of a trap command. For Solaris sh.
15637         Reported by Mark D. Baushke <mdb@gnu.org>.
15638
15639 2006-01-24  Simon Josefsson  <jas@extundo.com>
15640
15641         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
15642         Bruno.
15643
15644 2006-01-24  Karl Berry  <karl@gnu.org>
15645
15646         * config/srclist.txt (argp-namefrob.h): sync lost.
15647
15648 2006-01-24  Jim Meyering  <jim@meyering.net>
15649
15650         * modules/openat (Files): Add lib/intprops.h.
15651         From Mark D. Baushke.
15652
15653 2006-01-24  Jim Meyering  <jim@meyering.net>
15654
15655         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
15656         Reported by Mark D. Baushke.
15657
15658 2006-01-24  Jim Meyering  <jim@meyering.net>
15659
15660         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
15661
15662 2006-01-24  Bruno Haible  <bruno@clisp.org>
15663
15664         * modules/strnlen (Maintainer): Change from glibc to all.
15665
15666 2006-01-24  Bruno Haible  <bruno@clisp.org>
15667
15668         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
15669         Patch by Paul Eggert.
15670
15671 2006-01-24  Bruno Haible  <bruno@clisp.org>
15672
15673         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
15674         already has it.
15675         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
15676         2005-11-26.
15677
15678         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
15679         'signed char' to avoid problems with the built-in _Bool type.
15680         Reported by Paul Eggert on 2005-11-26.
15681
15682 2006-01-24  Bruno Haible  <bruno@clisp.org>
15683
15684         * gnulib-tool (func_import): Avoid constructing complicated sed
15685         expressions inside backquote.
15686         Report and solution by Mark D. Baushke <mdb@gnu.org>.
15687
15688 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
15689
15690         These changes imported from libc.
15691         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
15692         test and two separate function calls.
15693         * lib/strndup.c (__strndup): Add libc_hidden_def.
15694
15695 2006-01-23  Simon Josefsson  <jas@extundo.com>
15696
15697         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
15698         Remove the test_*_SOURCES variable: automake infers it by default.
15699         * modules/tls-tests: Likewise.
15700
15701 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15702
15703         Work around porting bugs reported by Dieter in
15704         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
15705         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
15706         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
15707         Include "getopt.h" first, to check interface.
15708         (getenv): Declare only if defined HAVE_DECL_GETENV &&
15709         !HAVE_DECL_GETENV.
15710         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
15711         (__strndup): Revert to K&R-style function dfns, the glibc style.
15712         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
15713         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
15714         Include strnlen.h first, to get prototype properly.
15715         (strnlen): Renamed from __strnlen.
15716         Remove weak alias.
15717
15718 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15719
15720         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
15721
15722 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15723
15724         * config/srclist.txt: Adjust to reflect glibc reorganization.
15725         This affects only comments.
15726
15727 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
15728
15729          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
15730          Reported by Bruce Korb <bkorb@gnu.org>.
15731
15732 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
15733
15734         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
15735         to pacify gcc -Wswitch-default.
15736
15737 2006-01-22  Bruno Haible  <bruno@clisp.org>
15738
15739         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
15740         temporary buffer for sprintf, take into account the precision also
15741         for 'd', 'i', 'u', 'o', 'x', 'X'.
15742
15743 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
15744
15745         * modules/argp-tests: New module
15746         * tests/test-argp.c: New file
15747         * tests/test-argp-2.sh: New file
15748
15749 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
15750
15751         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
15752         (__argp_base_name): Removed
15753         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
15754         typo.
15755         (__argp_base_name): Provide macro definition or extern declaration
15756         depending on the configuration
15757
15758 2006-01-20  Simon Josefsson  <jas@extundo.com>
15759
15760         * modules/inet_ntop (Depends-on): Depend on sys_socket.
15761
15762 2006-01-20  Simon Josefsson  <jas@extundo.com>
15763
15764         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
15765
15766 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
15767
15768         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
15769         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
15770         Suggested by Bruno Haible.
15771
15772 2006-01-20  Karl Berry  <karl@gnu.org>
15773
15774         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
15775         until changes propagate, I guess.
15776
15777 2006-01-19  Simon Josefsson  <jas@extundo.com>
15778
15779         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
15780
15781 2006-01-19  Simon Josefsson  <jas@extundo.com>
15782
15783         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
15784
15785 2006-01-19  Simon Josefsson  <jas@extundo.com>
15786
15787         * gnulib-tool: Set check_PROGRAMS.
15788
15789         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
15790         modules/des-tests, modules/gc-arcfour-tests,
15791         modules/gc-arctwo-tests, modules/gc-des-tests,
15792         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
15793         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
15794         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
15795         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
15796         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
15797         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
15798         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
15799         test_*_SOURCES.
15800
15801 2006-01-18  Simon Josefsson  <jas@extundo.com>
15802
15803         * modules/socklen (Depends-on): Depend on sys_socket.
15804
15805 2006-01-18  Simon Josefsson  <jas@extundo.com>
15806
15807         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
15808         modules/des-tests, modules/gc-arcfour-tests,
15809         modules/gc-arctwo-tests, modules/gc-des-tests,
15810         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
15811         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
15812         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
15813         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
15814         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
15815         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
15816         $(EXEEXT) to automake TESTS variable, for mingw32.
15817
15818 2006-01-17  Simon Josefsson  <jas@extundo.com>
15819
15820         * modules/socklen (Include): Need sys/socket.h.
15821
15822 2006-01-17  Bruno Haible  <bruno@clisp.org>
15823
15824         * modules/ssize_t (Include): Add <sys/types.h>.
15825
15826 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
15827
15828         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
15829         it's not portable and it doesn't work with cross-compiles.
15830         Problem reported by Bruno Haible.  Fix missing-$ typo in
15831         'test "gl_cv_ignore_unused_libraries" ...' that prevented
15832         -zignore from being used with Sun's C compiler.
15833
15834 2006-01-12  Simon Josefsson  <jas@extundo.com>
15835
15836         * lib/base64.c: Fix warning, reported by Bruno Haible
15837         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
15838
15839 2006-01-12  Bruno Haible  <bruno@clisp.org>
15840
15841         * modules/ldd: New file.
15842         * build-aux/ldd.sh.in: New file.
15843         * MODULES.html.sh (Support for building libraries and executables): Add
15844         ldd.
15845
15846 2006-01-12  Bruno Haible  <bruno@clisp.org>
15847
15848         * m4/ldd.m4: New file.
15849
15850 2006-01-12  Bruno Haible  <bruno@clisp.org>
15851
15852         * gnulib-tool (func_import, func_create_testdir): Don't go into an
15853         endless loop while replacing $auxdir with build-aux.
15854
15855 2006-01-11  Simon Josefsson  <jas@extundo.com>
15856
15857         * lib/stdint_.h (SIZE_MAX): Add missing (.
15858
15859 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
15860
15861         Sync from coreutils.
15862         * lib/md5.c: Fix commentary typos.
15863         (alignof, UNALIGNED_P): No need for a GCC-specific version.
15864         * lib/md5.h (__attribute__): Remove; unused.
15865         * lib/sha1.c: Fix commentary to match md5 better.
15866         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
15867         so that we don't need to worry about alignment.  All uses changed.
15868         This merges the 2005-10-28 md5 change into sha1.
15869
15870 2006-01-11  Jim Meyering  <jim@meyering.net>
15871
15872         Sync from coreutils.
15873         * lib/md5.c (OP): Fix spacing.
15874
15875 2006-01-11  Bruno Haible  <bruno@clisp.org>
15876
15877         Ensure automatic ordering between gl_LOCK and gl_ARGP.
15878         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
15879         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
15880
15881 2006-01-11  Bruno Haible  <bruno@clisp.org>
15882
15883         Ensure automatic ordering between gl_LOCK and gl_ARGP.
15884         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
15885         the "early" section as well.
15886
15887 2006-01-11  Bruno Haible  <bruno@clisp.org>
15888
15889         Avoid "ar: no archive members specified" error on MacOS X.
15890         * gnulib-tool (func_modules_add_dummy): New function.
15891         (func_import, func_create_testdir): Invoke it.
15892
15893 2006-01-11  Bruno Haible  <bruno@clisp.org>
15894
15895         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
15896         with $auxdir in AC_CONFIG_FILES statements.
15897
15898 2006-01-11  Bruno Haible  <bruno@clisp.org>
15899
15900         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
15901         Initialize also noinst_HEADERS to empty.
15902
15903 2006-01-11  Bruno Haible  <bruno@clisp.org>
15904
15905         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
15906         variables.
15907         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
15908         autoreconf.
15909
15910 2006-01-11  Bruno Haible  <bruno@clisp.org>
15911
15912         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
15913         overridable by the user.
15914         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15915
15916 2006-01-10  Simon Josefsson  <jas@extundo.com>
15917
15918         * modules/sys_socket: New file.
15919
15920 2006-01-10  Simon Josefsson  <jas@extundo.com>
15921
15922         * m4/sys_socket_h.m4: New file.
15923
15924 2006-01-10  Simon Josefsson  <jas@extundo.com>
15925
15926         * lib/socket_.h: New file.
15927
15928 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15929
15930         * modules/readutmp (Maintainer): Add myself.
15931
15932 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15933
15934         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
15935         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
15936         People who are still concerned with buggy memcmp implementations
15937         can invoke gl_FUNC_MEMCMP themselves.
15938
15939 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
15940
15941         * lib/regex_internal.h (BITSET_WORD_BITS):
15942         Work around a bug in 64-bit PGC (before version 6.1-2), where the
15943         preprocessor mishandles large unsigned values as if they were signed.
15944         Problem reported by Claudio Fontana in
15945         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
15946
15947 2006-01-10  Jim Meyering  <jim@meyering.net>
15948
15949         Avoid the double-free (first in fts_read, second in fts_close) that
15950         would occur when an `active' directory is made inaccessible (e.g.,
15951         via chmod a-x) during a traversal.
15952         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
15953         before returning.  Reproduce this failure by
15954         mkdir -p a/b; cd a; chmod a-x . b
15955         Reported by Stavros Passas.
15956
15957         Sync from coreutils.
15958         * lib/sha1.c: Tweak grammar in a comment.
15959
15960 2006-01-10  Jim Meyering  <jim@meyering.net>
15961
15962         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
15963         Patch by Joerg Sonnenberger.
15964
15965 2006-01-10  Bruno Haible  <bruno@clisp.org>
15966
15967         * modules/readutmp: Depend on module free.
15968         * modules/strtok_r: Depend on module restrict.
15969
15970 2006-01-10  Bruno Haible  <bruno@clisp.org>
15971
15972         * modules/gettext (configure.ac): Add an invocation of
15973         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
15974
15975 2006-01-10  Bruno Haible  <bruno@clisp.org>
15976
15977         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
15978         Reported by Werner Lemberg <wl@gnu.org>.
15979
15980 2006-01-10  Bruno Haible  <bruno@clisp.org>
15981
15982         * lib/localcharset.c: Update from GNU gettext.
15983
15984 2006-01-10  Bruno Haible  <bruno@clisp.org>
15985
15986         * lib/argp.h (__const): Remove macro. Use const instead.
15987         * lib/argp-fmtstream.h (__const): Likewise.
15988         * lib/glob_.h (__const): Remove macro.
15989         * lib/glob-libc.h: Use const instead of __const.
15990
15991 2006-01-10  Bruno Haible  <bruno@clisp.org>
15992
15993         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
15994         variable.
15995         Needed to avoid an automake error regarding the 'gettext' module.
15996
15997 2006-01-09  Simon Josefsson  <jas@extundo.com>
15998
15999         * modules/inet_ntop (Depends-on): Add restrict.
16000
16001 2006-01-09  Simon Josefsson  <jas@extundo.com>
16002
16003         * modules/gc-rijndael-tests (License): Put under LGPL.
16004
16005         * modules/gc-des-tests (License): Likewise.
16006
16007         * modules/gc-arcfour-tests (License): Likewise.
16008
16009         * modules/gc-arctwo-tests (License): Likewise.
16010
16011         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
16012
16013         * modules/gc-hmac-sha1-tests (Files): Likewise.
16014
16015         * modules/gc-hmac-md5-tests (License): Likewise.
16016
16017         * modules/gc-sha1-tests (License): Likewise.
16018
16019         * modules/gc-md5-tests (License): Likewise.
16020
16021         * modules/gc-md4-tests (License): Likewise.
16022
16023         * modules/gc-md2-tests (License): Likewise.
16024
16025         * modules/gc-tests (License): Likewise.
16026
16027         * modules/des-tests (License): Likewise.
16028
16029         * modules/md4-tests (License): Likewise.
16030
16031         * modules/md2-tests (License): Likewise.
16032
16033 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
16034
16035         Sync from coreutils:
16036
16037         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
16038         * modules/lib-ignore: New file.
16039         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
16040         chdir-safer.m4, lchmod.m4.
16041         * modules/openat: Add mkdirat.c, openat-priv.h.
16042
16043 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
16044
16045         Sync from coreutils.
16046         * m4/lib-ignore.m4: New file.
16047         * m4/lchmod.m4: New file.
16048
16049 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
16050
16051         Sync from coreutils.
16052         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
16053         for write access: POSIX says that must fail.
16054         * lib/fts.c (diropen): Likewise.
16055         * lib/save-cwd.c (save_cwd): Likewise.
16056         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
16057         well, for minor improvements on hosts that lack O_DIRECTORY.
16058         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
16059         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
16060         Fall back on chown if open failed with EACCES.
16061
16062         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
16063         Report an error at compile-time if only a 1-second nominal clock
16064         resolution is found.
16065
16066         * lib/lchmod.h: New file.
16067         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
16068         (make_dir_parents): Use lchown rather than chown, and
16069         lchmod rather than chmod.
16070
16071         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
16072         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
16073         "proc" reported by n0dalus.
16074
16075         * lib/mountlist.c: Include <limits.h>.
16076         (dev_from_mount_options)
16077         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
16078         New function.  It no longer assumes "dev=" has the System V meaning
16079         on Linux (since it doesn't).  It also parses "dev=" more carefully.
16080         (read_file_system_list)
16081         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
16082         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
16083         dev= in that case.
16084
16085         * lib/posixtm.h (PDS_PRE_2000): New macro.
16086         * lib/posixtm.c (year): Arg is now syntax_bits rather than
16087         allow_century.  All usages changed.  Reject dates outside the range
16088         1969-1999 if PDS_PRE_2000 is used.
16089
16090 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
16091
16092         Sync from coreutils.
16093         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
16094         (Time of day items): Mention the possibility of leap seconds.
16095         Problem reported by Dr. David Alan Gilbert.
16096
16097 2006-01-09  Jim Meyering  <jim@meyering.net>
16098
16099         Sync from coreutils.
16100
16101         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
16102
16103         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
16104
16105         * lib/modechange.c (mode_compile): Reject an invalid mode string
16106         that starts with an octal digit.  From Andreas Gruenbacher.
16107
16108         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
16109         and dup to open_safer and dup_safer, respectively.
16110         (openat_permissive): Fix typo in comment.
16111
16112         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
16113         "gettext.h"; either no longer needed or are guaranteed by openat.h.
16114         (_): Remove; no longer needed.
16115         (openat): Renamed from rpl_openat; no need for rpl_openat
16116         since openat.h renames openat for us.
16117         Replace most of the body with a call to openat_permissive,
16118         to avoid duplicate code.
16119         Port to (probably hypothetical) environments were mode_t is
16120         wider than int.
16121         (openat_permissive): Require mode arg, so that we can check
16122         types better.  Put it just after flags.  Change cwd failure
16123         indicator from pointer-to-bool to pointer-to-errno-value.
16124         All callers changed.
16125         Invoke openat_save_fail and/or openat_restore_fail if
16126         cwd_errno is null, so that openat can call us.
16127         (openat_permissive, fdopendir, fstatat, unlinkat):
16128         Simplify errno handling to avoid some duplicate code,
16129         as it's OK to set errno on success.
16130         * lib/openat.h: Revamp code so that function macros depend on
16131         __OPENAT_PREFIX only, not also on AT_FDCWD.
16132         (openat_ro): Remove.  Caller changed to use openat_permissive.
16133         (openat_permissive): Now a macro, if not a function.
16134         (openat_restore_fail, openat_save_fail): Now always functions,
16135         since mkdirat needs them even if __OPENAT_PREFIX is defined.
16136
16137         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
16138         and openat.c.
16139         * lib/mkdirat.c: Include openat-priv.h.
16140         Remove definitions of macros defined therein.
16141         * lib/openat.c: Likewise.
16142
16143         * lib/mkdirat.c (mkdirat): New file and function.
16144         * lib/openat.h (mkdirat): Declare.
16145
16146         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
16147
16148         * lib/openat.h (openat_permissive): Declare.
16149         (openat_ro): Define.
16150
16151         * lib/openat.c (EXPECTED_ERRNO): New macro.
16152         (openat_permissive): New function -- used in remove.c rewrite.
16153         (all functions): Set errno just before returning, only if there
16154         was an actual failure.
16155         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
16156
16157         Emulate openat-family functions using Linux's procfs, if possible.
16158         Idea and some code based on Ulrich Drepper's glibc changes.
16159
16160         * lib/openat.c: (BUILD_PROC_NAME): New macro.
16161         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
16162         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
16163         before falling back on save_cwd and restore_cwd.
16164         (fdopendir, fstatat, unlinkat): Likewise.
16165
16166         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
16167         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
16168
16169         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
16170         as second argument to va_arg.  Otherwise, some versions of gcc
16171         warn that `if this code is reached, the program will abort'.
16172
16173 2006-01-09  Jim Meyering  <jim@meyering.net>
16174
16175         Sync from coreutils.
16176         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
16177         Require openat-priv.h.
16178
16179 2006-01-09  Bruno Haible  <bruno@clisp.org>
16180
16181         * modules/strnlen (Include): Use strnlen.h.
16182
16183 2006-01-09  Bruno Haible  <bruno@clisp.org>
16184
16185         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
16186
16187 2006-01-09  Bruno Haible  <bruno@clisp.org>
16188
16189         * lib/sysexit_.h (EX_OK): New macro.
16190         Suggested by Martin Lambers <marlam@marlam.de>.
16191
16192 2006-01-09  Bruno Haible  <bruno@clisp.org>
16193
16194         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
16195         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
16196
16197 2006-01-09  Bruno Haible  <bruno@clisp.org>
16198
16199         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
16200         numbers.
16201
16202 2006-01-09  Bruno Haible  <bruno@clisp.org>
16203
16204         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
16205         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
16206         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
16207         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
16208
16209 2006-01-09  Bruno Haible  <bruno@clisp.org>
16210
16211         * build-aux/javacomp.sh.in: New file, moved from lib/.
16212         * modules/javacomp-script (Files): Update.
16213         (configure.ac): Add AC_CONFIG_FILES invocation.
16214         (EXTRA_DIST): Remove variable.
16215
16216         * build-aux/javaexec.sh.in: New file, moved from lib/.
16217         * modules/javaexec (Files): Update.
16218         (configure.ac): Add AC_CONFIG_FILES invocation.
16219         (EXTRA_DIST): Remove javaexec.sh.in.
16220
16221         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
16222         * modules/csharpcomp-script (Files): Update.
16223         (configure.ac): Add AC_CONFIG_FILES invocation.
16224         (EXTRA_DIST): Remove variable.
16225
16226         * build-aux/csharpexec.sh.in: New file, moved from lib/.
16227         * modules/csharpexec (Files): Update.
16228         (configure.ac): Add AC_CONFIG_FILES invocation.
16229         (EXTRA_DIST): Remove csharpexec.sh.in.
16230
16231 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
16232
16233         Sync from coreutils.
16234
16235         Add POSIX ACL support
16236         * lib/acl.h (copy_acl, set_acl): Add declarations.
16237         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
16238         systems other than Linux.
16239         (chmod_or_fchmod): New function: use fchmod when possible,
16240         and chmod otherwise.
16241         (file_has_acl): Add a POSIX ACL implementation, with a
16242         Linux-specific subcase.
16243         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
16244         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
16245         acls are unsupported.
16246         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
16247         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
16248         are unsupported.
16249
16250 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
16251
16252         Sync from coreutils.
16253         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
16254
16255 2006-01-07  Bruno Haible  <bruno@clisp.org>
16256
16257         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
16258         gl_EARLY.
16259
16260 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
16261
16262         * lib/strftime.c (tzname): Don't declare if it is already #defined.
16263         Problem reported for Mingw by Mark Junker.
16264
16265 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
16266
16267         * README: Gnulib normally doesn't generate a tarball.
16268
16269 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
16270
16271         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
16272         long int, not int, for nanosecond counts, so that people who are
16273         used to POSIX struct timespec won't be surprised.  Reported by Jim
16274         Meyering.
16275
16276 2005-12-28  Bruno Haible  <bruno@clisp.org>
16277
16278         * build-aux/config.rpath: Update from GNU gettext.
16279
16280 2005-12-16  Jim Meyering  <jim@meyering.net>
16281
16282         * modules/fprintftime: New module.
16283         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
16284
16285 2005-12-16  Jim Meyering  <jim@meyering.net>
16286
16287         * m4/fprintftime.m4: New file.
16288
16289 2005-12-16  Jim Meyering  <jim@meyering.net>
16290
16291         * lib/fprintftime.c, lib/fprintftime.h: New files.
16292
16293 2005-12-15  Simon Josefsson  <jas@extundo.com>
16294
16295         * modules/socklen (configure.ac): Fix M4 macro name, to align with
16296         new m4/socklen.m4.
16297
16298 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
16299
16300         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
16301         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
16302
16303 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
16304
16305         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
16306         * lib/argp-help.c (fill_in_uparams): Check if the constructed
16307         struct uparams is valid. Fall back to the default values if it is
16308         not.
16309
16310 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16311
16312         * modules/argp (Files): Add argp-pin.c
16313         (Depends-on): dirname
16314         (lib_SOURCES): Add argp-pin.c
16315
16316 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16317
16318         * m4/argp.m4:  Check if program_invocation_name and
16319         program_invocation_short_name are declared and define appropriate
16320         macros if they are not.
16321
16322 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16323
16324         * lib/argp-help.c (__argp_base_name): New function
16325         (__argp_short_program_name): Rewrite using __argp_base_name
16326         * lib/argp-namefrob.h: Define program_invocation_name and
16327         program_invocation_short_name if requested
16328         (__argp_base_name): Add prototype
16329         * lib/argp-parse.c (argp_def): Use gettext wrappers
16330         (argp_default_parser): Use __argp_base_name
16331         * lib/argp-pin.c: New file. Defines program_invocation_name and
16332         program_invocation_short_name on systems that lack them.
16333
16334 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
16335
16336         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
16337         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
16338         porting problem reported by Georg Schwarz in
16339         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
16340
16341 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
16342
16343         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
16344         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
16345         porting problem reported by Georg Schwarz in
16346         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
16347
16348 2005-12-05  Bruno Haible  <bruno@clisp.org>
16349
16350         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
16351         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
16352         Reported by Mark Junker <mjscod@gmx.de>.
16353
16354 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
16355
16356         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
16357         Use implementation from Albert Chin, with some
16358         comments/corrections by Stepan Kasal and myself.
16359
16360 2005-12-02  Bruno Haible  <bruno@clisp.org>
16361
16362         * gnulib-tool (func_import): Accept GPLed build tool modules when
16363         --lgpl is given.
16364         * modules/csharpcomp-script: New file.
16365         * modules/csharpcomp: Depend on it.
16366         * modules/javacomp-script: New file.
16367         * modules/javacomp: Depend on it.
16368         Suggested by Simon Josefsson.
16369
16370 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
16371
16372         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
16373         statement, to work around an HP-UX 10.20 compiler bug reported by
16374         Peter O'Gorman.
16375
16376 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
16377
16378         * modules/savedir (Depends-on): Add openat.
16379
16380 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
16381
16382         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
16383         (uintmax_t) [defined uintmax_t]: Do not declare.
16384         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
16385         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
16386         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
16387         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
16388         sake of portability to weird hosts that C allows (though we don't
16389         know of any practical examples).
16390
16391         * lib/savedir.h (fdsavedir): New decl.
16392         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
16393         contains most of the former guts of savedir.
16394         (savedir): Use savedirstream.
16395         Include "openat.h".
16396
16397 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
16398
16399         * modules/obstack (Files): Add m4/ulonglong.m4.
16400         Problem reported by Davide Angelocola.
16401
16402 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
16403
16404         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
16405         coreutils no longer futzes with rounding modes.
16406
16407 2005-11-14  Jim Meyering  <jim@meyering.net>
16408
16409         * lib/mkstemp-safer.c: Include <config.h>, required for possible
16410         replacement of mkstemp.
16411
16412 2005-11-10  Simon Josefsson  <jas@extundo.com>
16413
16414         * lib/readline.c: Remove EOL.
16415
16416 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
16417
16418         * modules/gethrxtime (Depends-on): Add gettime.
16419
16420 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
16421
16422         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
16423         or gettimeofday; no longer needed.
16424
16425 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
16426
16427         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
16428         time business.
16429         (gethrxtime) [! (HAVE_NANOUPTIME
16430         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
16431         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
16432         our own approximation.
16433
16434 2005-11-08  Eric Blake  <ebb9@byu.net>
16435
16436         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
16437
16438 2005-11-08  Eric Blake  <ebb9@byu.net>
16439
16440         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
16441
16442 2005-11-04  Bruno Haible  <bruno@clisp.org>
16443
16444         * gnulib-tool: Implement --update mode.
16445
16446 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16447
16448         Fix porting problem reported by Theodoros V. Kalamatianos.
16449         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
16450         Don't assume that futimes failing means we must fail.
16451
16452 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16453
16454         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
16455         variables to suggest the intended function of the PATH_MAX check.
16456
16457 2005-10-30  Kean Johnston  <jkj@sco.com>
16458
16459         Trivial changes to support SCO systems.
16460         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
16461         as PATH_MAX.
16462         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
16463         where __ptr is null when no I/O is pending.
16464
16465 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
16466
16467         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
16468         leave errno alone.  Problem reported by Dmitry V. Levin.
16469
16470 2005-10-28  Simon Josefsson  <jas@extundo.com>
16471
16472         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
16473         Test more.
16474
16475         * tests/test-gc-md2.c, tests/test-md2.c: New files.
16476
16477         * modules/md2, modules/md2-tests: New files.
16478
16479 2005-10-28  Simon Josefsson  <jas@extundo.com>
16480
16481         * m4/inet_ntop.m4: More tests.
16482
16483         * m4/gc-md2.m4, md2.m4: New file.
16484
16485 2005-10-28  Simon Josefsson  <jas@extundo.com>
16486
16487         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
16488         "restrict" keywords, as per POSIX.  Protect the function
16489         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
16490         Don't use K&R prototypes.  Check the sprintf return values.
16491         Re-define EAFNOSUPPORT if not present.  Indent.
16492
16493         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
16494         suggested by Bruno Haible <bruno@clisp.org>.
16495
16496         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
16497
16498         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
16499
16500         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
16501         libgcrypt).
16502
16503         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
16504
16505         * lib/md2.h, lib/md2.c: New files.
16506
16507 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
16508
16509         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
16510         errno alone.  Problem reported by Frederic Jolliton.
16511
16512 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
16513
16514         * modules/verify (License): Change from GPL to LGPL.  This is a
16515         tiny module and there are apparently near-equivalents that are
16516         under the BSD license.
16517
16518 2005-10-24  Simon Josefsson  <jas@extundo.com>
16519
16520         * modules/sha1: Relicense to LGPL.
16521
16522 2005-10-24  Simon Josefsson  <jas@extundo.com>
16523
16524         * lib/md4.h: Shrink buffer size, now that we changed the type.
16525
16526 2005-10-23  Simon Josefsson  <jas@extundo.com>
16527
16528         * gnulib-tool (func_import): Fix --tests-base.
16529
16530 2005-10-22  Simon Josefsson  <jas@extundo.com>
16531
16532         * modules/arcfour (Depends-on): Need stdint.
16533
16534 2005-10-22  Simon Josefsson  <jas@extundo.com>
16535
16536         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
16537         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
16538
16539 2005-10-22  Simon Josefsson  <jas@extundo.com>
16540
16541         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
16542         suggested by Bruno Haible <bruno@clisp.org>.
16543
16544 2005-10-22  Simon Josefsson  <jas@extundo.com>
16545
16546         * lib/crc.h: Include stddef.h, for size_t.
16547
16548 2005-10-22  Simon Josefsson  <jas@extundo.com>
16549
16550         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
16551         arcfour_context struct (simplify test vector testing in GNU
16552         Shishi).
16553
16554 2005-10-21  Simon Josefsson  <jas@extundo.com>
16555
16556         * modules/des, modules/des-tests: New files.
16557
16558         * modules/gc-des, modules/gc-des-tests: New files.
16559
16560         * tests/test-des.c, tests/test-gc-des.c: New file.
16561
16562 2005-10-21  Simon Josefsson  <jas@extundo.com>
16563
16564         * modules/arctwo, modules/arctwo-tests: New files.
16565
16566         * tests/test-arctwo.c: New file.
16567
16568         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
16569
16570         * tests/test-gc-arctwo.c: New file.
16571
16572 2005-10-21  Simon Josefsson  <jas@extundo.com>
16573
16574         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
16575         Bruno Haible <bruno@clisp.org>.
16576
16577         * m4/gc-des.m4: New file.
16578
16579 2005-10-21  Simon Josefsson  <jas@extundo.com>
16580
16581         * m4/arctwo.m4: New file.
16582
16583         * m4/gc-arctwo.m4: New file.
16584
16585 2005-10-21  Simon Josefsson  <jas@extundo.com>
16586
16587         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
16588         block.
16589
16590 2005-10-21  Simon Josefsson  <jas@extundo.com>
16591
16592         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
16593         <bruno@clisp.org>.
16594
16595         * lib/hmac-sha1.c (hmac_sha1): Likewise.
16596
16597         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
16598         Bruno Haible <bruno@clisp.org>.
16599
16600         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
16601         <bruno@clisp.org>.
16602
16603 2005-10-21  Simon Josefsson  <jas@extundo.com>
16604
16605         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
16606
16607 2005-10-21  Simon Josefsson  <jas@extundo.com>
16608
16609         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
16610
16611 2005-10-21  Simon Josefsson  <jas@extundo.com>
16612
16613         * lib/des.h, lib/des.c: New files.
16614
16615         * lib/gc-gnulib.c: Support DES.c
16616
16617 2005-10-21  Simon Josefsson  <jas@extundo.com>
16618
16619         * lib/arctwo.h, lib/arctwo.c: New files.
16620
16621         * lib/gc-gnulib.c: Support ARCTWO.
16622
16623 2005-10-21  Simon Josefsson  <jas@extundo.com>
16624
16625         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
16626         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
16627
16628 2005-10-21  Simon Josefsson  <jas@extundo.com>
16629
16630         * gnulib-tool (func_import, func_create_testdir): Define automake
16631         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
16632         Makefile.am snippet),
16633         suggested by Bruno Haible <bruno@clisp.org>.
16634
16635         * modules/gc (Makefile.am): Use it.
16636
16637 2005-10-21  Bruno Haible  <bruno@clisp.org>
16638
16639         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
16640         patch.
16641
16642 2005-10-19  Simon Josefsson  <jas@extundo.com>
16643
16644         * tests/test-gc-rijndael.c: New file.
16645
16646         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
16647
16648 2005-10-19  Simon Josefsson  <jas@extundo.com>
16649
16650         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
16651         interface too.
16652
16653 2005-10-19  Simon Josefsson  <jas@extundo.com>
16654
16655         * tests/test-gc-arcfour.c: New file.
16656
16657         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
16658
16659 2005-10-19  Simon Josefsson  <jas@extundo.com>
16660
16661         * modules/gc-md4, modules/gc-md4-tests: New file.
16662
16663         * tests/test-gc-md4.c: New file.
16664
16665 2005-10-19  Simon Josefsson  <jas@extundo.com>
16666
16667         * m4/gc-md4.m4: New file.
16668
16669 2005-10-19  Simon Josefsson  <jas@extundo.com>
16670
16671         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
16672         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
16673         <kasal@ucw.cz>.
16674
16675 2005-10-19  Simon Josefsson  <jas@extundo.com>
16676
16677         * m4/gc-arcfour.m4: New file.
16678
16679         * m4/gc-rijndael.m4: New file.
16680
16681 2005-10-19  Simon Josefsson  <jas@extundo.com>
16682
16683         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
16684
16685 2005-10-19  Simon Josefsson  <jas@extundo.com>
16686
16687         * lib/gc-gnulib.c: Support ARCFOUR.
16688
16689 2005-10-19  Simon Josefsson  <jas@extundo.com>
16690
16691         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
16692         support.
16693
16694         * lib/gc.h: Add ECB enum type.
16695
16696         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
16697
16698 2005-10-18  Simon Josefsson  <jas@extundo.com>
16699
16700         * tests/test-md5.c: New file.
16701
16702         * modules/md5-tests: New file.
16703
16704 2005-10-18  Simon Josefsson  <jas@extundo.com>
16705
16706         * tests/test-md4.c: New file.
16707
16708         * modules/md4, modules/md4-tests: New files.
16709
16710 2005-10-18  Simon Josefsson  <jas@extundo.com>
16711
16712         * m4/md4.m4: New file.
16713
16714 2005-10-18  Simon Josefsson  <jas@extundo.com>
16715
16716         * lib/md4.h, lib/md4.c: New files, based on md5.?.
16717
16718 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
16719
16720         * gnulib-tool (func_create_testdir): Omit the second check whether
16721         BUILT_SOURCES in nonempty.
16722
16723 2005-10-17  Simon Josefsson  <jas@extundo.com>
16724
16725         * tests/test-rijndael.c: New file.
16726
16727 2005-10-17  Simon Josefsson  <jas@extundo.com>
16728
16729         * modules/sha1: Depend on stdint instead of md5.
16730
16731         * modules/md5: Depend on stdint, remove uint32_t.
16732
16733 2005-10-17  Simon Josefsson  <jas@extundo.com>
16734
16735         * modules/gc-sha1-tests: New file.
16736
16737         * tests/test-gc-sha1.c: New file.
16738
16739 2005-10-17  Simon Josefsson  <jas@extundo.com>
16740
16741         * m4/md5.m4: Remove call to uint32_t.m4.
16742
16743 2005-10-17  Simon Josefsson  <jas@extundo.com>
16744
16745         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
16746
16747         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
16748         md5.h.
16749
16750         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
16751
16752         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
16753
16754 2005-10-17  Simon Josefsson  <jas@extundo.com>
16755
16756         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
16757
16758 2005-10-17  Simon Josefsson  <jas@extundo.com>
16759
16760         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
16761
16762 2005-10-17  Simon Josefsson  <jas@extundo.com>
16763
16764         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
16765
16766         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
16767
16768 2005-10-17  Bruno Haible  <bruno@clisp.org>
16769
16770         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
16771         that it can also be used in a test.
16772
16773 2005-10-16  Bruno Haible  <bruno@clisp.org>
16774
16775         * gnulib-tool (func_emit_tests_Makefile_am): Also define
16776         TESTS_ENVIRONMENT, so that individual tests can augment it.
16777
16778         * gnulib-tool (func_create_testdir): Use an intermediate target for
16779         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
16780         macros, like $(ALLOCA_H), which cannot be passed through the command
16781         line.
16782
16783 2005-10-15  Simon Josefsson  <jas@extundo.com>
16784
16785         * modules/rijndael-tests: New file.
16786
16787         * modules/rijndael: New file.
16788
16789 2005-10-15  Simon Josefsson  <jas@extundo.com>
16790
16791         * m4/rijndael.m4: New file.
16792
16793 2005-10-15  Simon Josefsson  <jas@extundo.com>
16794
16795         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
16796
16797         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
16798
16799 2005-10-14  Simon Josefsson  <jas@extundo.com>
16800
16801         * tests/test-arcfour.c: New file.
16802
16803         * modules/arcfour, modules/arcfour-tests: New files.
16804
16805 2005-10-14  Simon Josefsson  <jas@extundo.com>
16806
16807         * m4/arcfour.m4: New file.
16808
16809 2005-10-14  Simon Josefsson  <jas@extundo.com>
16810
16811         * lib/arcfour.h, lib/arcfour.c: New files.
16812
16813 2005-10-14  Roland McGrath  <roland@redhat.com>
16814
16815         Import from libc.  [BZ #1331]
16816         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
16817         macro argument.
16818         Reported by Matej Vela <vela@debian.org>.
16819
16820 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
16821
16822         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
16823         include <wchar.h>; no longer needed.
16824
16825 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
16826
16827         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
16828
16829 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
16830         and  Ulrich Drepper  <drepper@redhat.com>
16831
16832         Import from libc.
16833         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
16834         instead of inline stream orientation test and two separate
16835         function calls.  Pay no attention to USE_IN_LIBIO.
16836
16837 2005-10-13  Simon Josefsson  <jas@extundo.com>
16838
16839         * modules/gc-hmac-md5-tests: New file.
16840
16841         * tests/test-gc-hmac-sha1.c: New file.
16842
16843         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
16844
16845         * modules/gc-hmac-md5-tests: New file.
16846
16847         * tests/test-gc-md5.c: New file.
16848
16849         * modules/gc-md5-tests: New file.
16850
16851 2005-10-13  Simon Josefsson  <jas@extundo.com>
16852
16853         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
16854         Move memory allocation outside of loop.
16855
16856 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
16857
16858         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
16859         intermediate directory is in a read-only file system.  Problem
16860         reported by Eric Blake.
16861
16862 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
16863
16864         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
16865
16866 2005-10-12  Simon Josefsson  <jas@extundo.com>
16867
16868         * tests/test-hmac-sha1.c: New file.
16869
16870         * modules/hmac-sha1-tests: New file.
16871
16872         * modules/hmac-sha1: New file.
16873
16874 2005-10-12  Simon Josefsson  <jas@extundo.com>
16875
16876         * modules/gc-sha1: New file.
16877
16878 2005-10-12  Simon Josefsson  <jas@extundo.com>
16879
16880         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
16881
16882         * tests/test-gc-pbkdf2-sha1.c: New file.
16883
16884 2005-10-12  Simon Josefsson  <jas@extundo.com>
16885
16886         * modules/gc-md5, modules/gc-hmac-md5: New files.
16887
16888         * modules/gc (Files): Remove md5, memxor and hmac files.
16889
16890 2005-10-12  Simon Josefsson  <jas@extundo.com>
16891
16892         * m4/gc-pbkdf2-sha1.m4: New file.
16893
16894         * m4/gc-hmac-sha1.m4: New file.
16895
16896         * m4/gc-sha1: New file.
16897
16898         * m4/hmac-sha1.m4: New file.
16899
16900 2005-10-12  Simon Josefsson  <jas@extundo.com>
16901
16902         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
16903
16904         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
16905
16906 2005-10-12  Simon Josefsson  <jas@extundo.com>
16907
16908         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
16909         suggested by Bruno Haible <bruno@clisp.org>.
16910
16911 2005-10-12  Simon Josefsson  <jas@extundo.com>
16912
16913         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
16914
16915 2005-10-12  Simon Josefsson  <jas@extundo.com>
16916
16917         * lib/gc-pbkdf2-sha1.c: New file.
16918
16919         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
16920
16921 2005-10-12  Simon Josefsson  <jas@extundo.com>
16922
16923         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
16924
16925         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
16926
16927 2005-10-12  Simon Josefsson  <jas@extundo.com>
16928
16929         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
16930         GC_USE_HMAC_MD5, respectively.
16931
16932         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
16933         (gc_md5): Fix typo.
16934
16935         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
16936
16937         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
16938
16939         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
16940
16941 2005-10-12  Bruno Haible  <bruno@clisp.org>
16942
16943         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
16944         Reported by Stepan Kasal <kasal@ucw.cz>.
16945
16946 2005-10-11  Simon Josefsson  <jas@extundo.com>
16947
16948         * tests/test-crc.c: New file.
16949
16950         * modules/crc, modules/crc-tests: New files.
16951
16952 2005-10-11  Simon Josefsson  <jas@extundo.com>
16953
16954         * m4/crc.m4: New file.
16955
16956 2005-10-11  Simon Josefsson  <jas@extundo.com>
16957
16958         * lib/gc.h: Add gc_hash and gc_hash_buffer.
16959
16960         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
16961
16962         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
16963
16964 2005-10-11  Simon Josefsson  <jas@extundo.com>
16965
16966         * lib/crc.h, lib/crc.c: New files.
16967
16968         * lib/gc.h (gc_hash_buffer): Add doc.
16969
16970 2005-10-11  Bruno Haible  <bruno@clisp.org>
16971
16972         * modules/c-strcasestr: New file.
16973         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
16974
16975 2005-10-11  Bruno Haible  <bruno@clisp.org>
16976
16977         * modules/c-strcase: New file.
16978         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
16979
16980 2005-10-11  Bruno Haible  <bruno@clisp.org>
16981
16982         * lib/strcasecmp.c: Include limits.h.
16983         (strcasecmp): Avoid integer overflow on exotic platforms.
16984         * lib/strncasecmp.c: Include limits.h.
16985         (strncasecmp): Avoid integer overflow on exotic platforms.
16986         Reported by Paul Eggert.
16987
16988 2005-10-11  Bruno Haible  <bruno@clisp.org>
16989
16990         * lib/c-strcasestr.h: New file, from GNU gettext.
16991         * lib/c-strcasestr.c: New file, from GNU gettext.
16992
16993 2005-10-11  Bruno Haible  <bruno@clisp.org>
16994
16995         * lib/c-strcase.h: New file, from GNU gettext.
16996         * lib/c-strcasecmp.c: New file, from GNU gettext.
16997         * lib/c-strncasecmp.c: New file, from GNU gettext.
16998
16999 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
17000
17001         * modules/mempcpy (License): GPL -> LGPL.
17002         * modules/strchrnul (License): Likewise.
17003         * modules/sysexits (License): Likewise.
17004
17005 2005-10-08  Simon Josefsson  <jas@extundo.com>
17006
17007         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
17008
17009 2005-10-07  Simon Josefsson  <jas@extundo.com>
17010
17011         * m4/memxor.m4: Remove gl_C_RESTRICT call.
17012
17013 2005-10-06  Simon Josefsson  <jas@extundo.com>
17014
17015         * tests/test-hmac-md5.c: New file.
17016
17017         * modules/hmac-md5-tests: New file.
17018
17019         * modules/hmac-md5: New file.
17020
17021 2005-10-06  Simon Josefsson  <jas@extundo.com>
17022
17023         * m4/hmac-md5.m4: New file.
17024
17025         * m4/memxor.m4: Require gl_C_RESTRICT.
17026
17027 2005-10-06  Simon Josefsson  <jas@extundo.com>
17028
17029         * lib/memxor.c (memxor): Avoid casts and warnings.
17030
17031 2005-10-06  Simon Josefsson  <jas@extundo.com>
17032
17033         * lib/hmac-md5.c: New file.
17034
17035         * lib/hmac.h: New file.
17036
17037 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
17038
17039         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
17040         promotes to int, not unsigned int, to catch the AIX 5.3
17041         compiler bug.
17042
17043 2005-10-05  Simon Josefsson  <jas@extundo.com>
17044
17045         * modules/memxor: New file.
17046
17047         * modules/iconv (Files): Move config.rpath to havelib, it is used
17048         there.
17049
17050         * modules/havelib (Files): Add config.rpath.
17051
17052 2005-10-05  Simon Josefsson  <jas@extundo.com>
17053
17054         * m4/memxor.m4: New file.
17055
17056 2005-10-05  Simon Josefsson  <jas@extundo.com>
17057
17058         * lib/memxor.c (memxor): Fix compiler error.
17059
17060         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
17061         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
17062
17063         * lib/memxor.h, lib/memxor.c: New files.
17064
17065         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
17066         we assume all systems have it, suggested by Jim Meyering
17067         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
17068         any systems lack sys/socket.h; mingw32 is known to lack it, but we
17069         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
17070         same reasons.
17071
17072 2005-10-05  Simon Josefsson  <jas@extundo.com>
17073
17074         * config/srclist.txt: Add glibc bug 1423 for md5.h.
17075
17076 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
17077
17078         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
17079         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
17080         needed, since the source code now assumes these .h files.
17081
17082 2005-10-05  Derek Price  <derek@ximbiot.com>
17083
17084         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
17085
17086 2005-10-05  Bruno Haible  <bruno@clisp.org>
17087
17088         * modules/stdint (License): Change to LGPL.
17089
17090 2005-10-04  Simon Josefsson  <jas@extundo.com>
17091
17092         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
17093         D. Baushke" <mdb@gnu.org>.
17094
17095 2005-10-04  Bruno Haible  <bruno@clisp.org>
17096
17097         * lib/verify.h (verify_true): Provide alternative definition for C++.
17098
17099 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
17100
17101         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
17102         (SSIZE_MAX): New macro, if not already defined.
17103         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
17104         than 2 GiB.
17105
17106 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
17107
17108         Sync from coreutils.
17109         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
17110         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
17111         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
17112         ULLONG_MAX doesn't work with 2.7.2.1.
17113
17114 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
17115
17116         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
17117         From Ben Pfaff.
17118
17119         * modules/exclude (Depends-on): Depend on verify.
17120         * modules/strtoimax (Depends-on): Likewise.
17121         * modules/utimecmp (Depends-on): Likewise.
17122
17123 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
17124
17125         * lib/exclude.c: Include verify.h.
17126         (verify): Remove.  All callers changed to use verify.h's version.
17127         * lib/strtoimax.c: Likewise.
17128         * lib/utimecmp.c: Likewis.e
17129
17130         Sync from coreutils.
17131         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
17132         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
17133         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
17134         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
17135         bother returning ENOSYS if settimeofday or stime fails; just let
17136         them return whatever errno they want to return.
17137         * lib/utimens.c: Include unistd.h, for dup2.
17138         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
17139         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
17140
17141 2005-10-02  Jim Meyering  <jim@meyering.net>
17142
17143         Sync from coreutils.
17144         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
17145         from glibc-2.2.5 that fails for read-only files.
17146
17147 2005-10-02  Jim Meyering  <jim@meyering.net>
17148
17149         Sync from coreutils.
17150         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
17151         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
17152         `#if HAVE_CONFIG_H'.
17153         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
17154         Remove AT_FDCWD test.
17155         Do not consume the fd unless successful.
17156         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
17157         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
17158         block, so that we don't even try to compile it if settimeofday is
17159         available.  This works around a compilation failure on OSF1 V5.1,
17160         due to stime requiring a `long int*' while tv_sec is `int'.
17161
17162 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
17163
17164         Sync from coreutils.
17165         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
17166         against `yes', rather than just testing for nonempty.
17167
17168 2005-10-01  Simon Josefsson  <jas@extundo.com>
17169
17170         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
17171         and Darwin.
17172
17173         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
17174         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
17175         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
17176         freeaddrinfo and gai_strerror are declared by the POSIX headers.
17177         Check if struct addrinfo is declared.
17178
17179 2005-10-01  Simon Josefsson  <jas@extundo.com>
17180
17181         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
17182         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
17183         AI_* and EAI_* definitions.  Protect function declarations.
17184
17185 2005-10-01  Jim Meyering  <jim@meyering.net>
17186
17187         Sync from coreutils.
17188
17189         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
17190         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
17191         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
17192         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
17193         in the inet and nsl libraries.  Required on Solaris 5.7.
17194
17195 2005-10-01  Jim Meyering  <jim@meyering.net>
17196
17197         Sync from coreutils.
17198         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
17199         in the inet and nsl libraries.  Required on Solaris 5.7.
17200
17201 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
17202
17203         * lib/getdelim.c (getdelim): Remove unused variables.
17204
17205 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
17206
17207         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
17208         so that the code works even with ancient cpp.  Portability problem
17209         with GCC 2.7.2.1 reported by Thomas M.Ott.
17210
17211 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
17212
17213         * modules/regex (Depends-on): Add strcase.
17214
17215         * modules/gethostname (Licence): Change from GPL to LGPL, since
17216         gethostname.c is a trivial implementation of a standard library
17217         function.
17218         * modules/poll (License): Change from GPL to LGPL, since it's
17219         derived from LGPL code.
17220
17221 2005-09-27  Jim Meyering  <jim@meyering.net>
17222
17223         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
17224         HAVE_CONFIG_H.
17225
17226         * lib/intprops.h (signed_type_or_expr__): Define.
17227         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
17228         for unsigned types.
17229
17230 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
17231
17232         * lib/verify.h (verify_expr): Remove, replacing with:
17233         (verify_true): New macro that returns true instead of void.
17234         (verify_type__): Remove.
17235         (verify): Use verify_true rather than verify_type__.
17236
17237 2005-09-26  Bruno Haible  <bruno@clisp.org>
17238
17239         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
17240         is necessary.
17241         (lib_SOURCES): Remove mbchar.c.
17242         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
17243         (Files): Add m4/mbrtowc.m4.
17244         * modules/mbiter: Likewise.
17245         * modules/mbuiter: Likewise.
17246
17247 2005-09-26  Bruno Haible  <bruno@clisp.org>
17248
17249         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
17250         compile mbchar.c if they are not both present.
17251         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
17252         * m4/mbiter.m4 (gl_MBITER): Likewise.
17253         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
17254         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
17255         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
17256
17257 2005-09-25  Jim Meyering  <jim@meyering.net>
17258
17259         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
17260         also uses socklen_t.
17261
17262 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
17263
17264         * lib/utimens.c (ENOSYS): Define if not already defined.
17265         (futimens): Support having a null PATH if the file descriptor
17266         is nonnegative.
17267
17268         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
17269         Remove.
17270         (__attribute): Define to empty unless GCC 3.1 or later.
17271         This works around a core dump on OpenBSD 3.4, which has GCC
17272         2.95.3, which dumps core when given __attribute__(()).  It also
17273         simplifies other tests, since we really don't want to bother with
17274         worrying about which ancient version of GCC supported what.
17275         Original problem reported by Yoann Vandoorselaere, with part of
17276         the fix suggested by Derek Price.
17277
17278 2005-09-24  Jim Meyering  <jim@meyering.net>
17279
17280         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
17281         so we can once again use a positive bitfield width of 1 -- now we
17282         don't have to explain why we were using a bitfield width of 2.
17283
17284 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
17285
17286         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
17287         and similarly for the other external symbols.  Problem reported
17288         by James Gallager.
17289
17290         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
17291         bug reported by Jim Meyering.
17292
17293         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
17294         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
17295         not needed, since socklen is a prerequisite module.
17296
17297 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
17298
17299         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
17300         Problem reported by Eric Blake.
17301         (getaddrinfo): Initialize se so that it's not garbage.
17302         Redo internal storage allocation so that it doesn't make unportable
17303         assumptions about alignment.
17304         Fix a memory leak.
17305
17306         * lib/utimens.c (futimens): Use futimesat if available.
17307         Prefer it to futimes since it doesn't have the futimes bug.
17308
17309         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
17310         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
17311         Instead, declare a function that returns a pointer to an array,
17312         and use verify_type__ to declare the size of the array.
17313         Problem and germ of a solution reported by Bruno Haible.
17314         (verify_type__): Use 2, not 1, for bitfield size, to avoid
17315         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
17316
17317 2005-09-23  Jim Meyering  <jim@meyering.net>
17318
17319         Sync from coreutils.
17320         Correct build failure (socklen_t not defined) on at least
17321         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
17322         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
17323
17324 2005-09-23  Jim Meyering  <jim@meyering.net>
17325
17326         * modules/getaddrinfo (Depends-on): Add socklen.
17327
17328 2005-09-23  Bruno Haible  <bruno@clisp.org>
17329
17330         * tests/test-verify.c: New file.
17331
17332 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17333
17334         Sync from coreutils.
17335
17336         * modules/argmatch (Depends-on): Add verify.
17337         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
17338         unistd-safer.
17339         * modules/save-cwd (Depends-on): Likewise.
17340
17341         * modules/openat (Files): Add lib/openat-die.c.
17342         (Depends-on): Remove error, exitfail.
17343         Add dirname.
17344
17345         * modules/verify: New file.
17346         * MODULES.html.sh (Diagnostics <assert.h>): New section,
17347         with "verify" module.
17348
17349 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17350
17351         Sync from coreutils.
17352
17353         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
17354         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
17355         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
17356         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
17357         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
17358         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
17359         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
17360         Don't bother checking for string.h, stdlib.h, unistd.h.
17361         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
17362         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
17363         module's job.
17364         * m4/jm-macros.m4 (gl_MACROS): Likewise.
17365         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
17366
17367         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
17368         (gl_GETDATE): Use it.
17369
17370         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
17371
17372 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17373
17374         Sync from coreutils.
17375
17376         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
17377         stat-time.h.
17378         * lib/argmatch.h: Include verify.h
17379         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
17380         (ARGMATCH_ASSERT): Remove; unused.
17381         * lib/canonicalize.c: Assume STDC_HEADERS.
17382         * lib/exclude.c: Include "strcase.h".
17383         * lib/regex_internal.h [!defined _LIBC]: Likewise.
17384         * lib/getusershell.c: Include stdio--.h rather than stdio.h
17385         and stdio-safer.h.
17386         (getusershell): Call fopen, not fopen_safer.
17387         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
17388         Do not include unistd-safer.h.
17389         (save_cwd): Don't call fd_safer; no longer needed
17390         now that we include fcntl--.h.
17391
17392         * lib/getdate.y (relative_time): New type.
17393         (RELATIVE_TIME_0): New constant.
17394         (parser_control): Use relative_time instead of doing it ourselves.
17395         (%union): Add new relative_time rel member.
17396         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
17397         Now typeless.
17398         (relunit, relunit_snumber): Now of type rel.
17399         (zone, rel, relunit, get_date): Adjust to above changes.
17400
17401         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
17402         Do not include unistd-safer.h.
17403         (getloadavg): Don't call fd_safer; no longer needed
17404         now that we include fcntl--.h.
17405
17406         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
17407         (make_dir_parents): Treat ENOSYS like EEXIST.
17408
17409         Improve quality of diagnostics on restore_cwd failure.
17410         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
17411         (make_dir_parents): Last arg is now int * (for errno), not bool *.
17412         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
17413         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
17414         each time through the loop.  Do not diagnose restore_cwd failure;
17415         that is the caller's job (and perhaps the caller does not care).
17416
17417         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
17418         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
17419         If the file already exists but is not a directory, don't bother
17420         to try to make its parents.
17421         Close potential file descriptor leak if we can't chdir("/") (!).
17422         Don't always return true if chdir($PWD) fails; return true only
17423         if the requested action was done successfully (except for the
17424         chdir($PWD)).
17425         Don't log final directory unless we actually made it.
17426         Refactor to avoid duplicate code to fix up permissions.
17427         Don't attempt to fix up parent permissions if chdir($PWD) fails.
17428
17429         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
17430         to make it a bit faster and (I hope) clearer.
17431         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
17432         Fix bug in formats like %2N.
17433
17434         * lib/verify.h: New file.
17435
17436 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17437
17438         Sync from coreutils.
17439         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
17440
17441 2005-09-22  Jim Meyering  <jim@meyering.net>
17442
17443         Sync from coreutils.
17444
17445         * m4/lstat.m4 (gl_FUNC_LSTAT):
17446         Use AC_LIBSOURCES to require lstat.c and lstat.h.
17447         Remove obsolete comment.
17448         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
17449         * m4/xstrtod.m4: Likewise.
17450
17451         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
17452
17453 2005-09-22  Jim Meyering  <jim@meyering.net>
17454
17455         Sync from coreutils.
17456
17457         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
17458
17459         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
17460         the .tm_year member, since otherwise gcc-4.0 would now warn about
17461         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
17462
17463         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
17464         order to avoid an unsuppressible warning from gcc on 64-bit systems.
17465
17466         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
17467         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
17468         when run in a time zone for which daylight savings time is in effect
17469         for the starting date.
17470
17471         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
17472         stop us from restricting permissions of just-created absolute-named
17473         directories.
17474         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
17475         to restore initial working directory.
17476         * lib/mkdir-p.c (make_dir_parents): New parameter:
17477         different_working_dir, to tell caller if/when we change the working
17478         directory and are unable to return to the initial one.
17479         * lib/mkdir-p.h (make_dir_parents): Update prototype.
17480         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
17481         `return false'.  This fixes a bug introduced on 2004-07-30.
17482
17483         * lib/openat.c (fdopendir): Be sure to close the supplied
17484         file descriptor before returning.  This makes our replacement
17485         implementation a little closer to Solaris's, where fdopendir
17486         ties the file descriptor to the returned DIR* pointer.
17487         * lib/openat.c (unlinkat): New function.
17488         * lib/openat.h (unlinkat): Add prototype.
17489         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
17490         (openat_restore_fail): Rename from openat_restore_die.
17491         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
17492
17493         Provide an alternative to exiting immediately upon save_cwd or
17494         restore_cwd failure.  Now, an application can arrange e.g.,
17495         to perform a longjump in that case.
17496         * lib/openat.c: Include dirname.h.
17497         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
17498         (rpl_openat, fdopendir, fstatat): Call openat_save_die
17499         and openat_restore_die rather than calling error directly.
17500         Don't include "error.h" or "exitfail.h"; they're no longer needed.
17501
17502         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
17503         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
17504         define.
17505
17506         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
17507         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
17508                             int utc, int nanoseconds);
17509         Background:
17510         date should not have to allocate a megabyte of virtual memory to
17511         handle a format argument like +%1048575T.  When implemented with
17512         strftime, it must allocate such a buffer, use strftime to fill it
17513         in, print it, then free it.
17514         With fprintftime, it simply prints everything and exits.
17515         With no need for memory allocation, that's one fewer way to fail.
17516         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
17517         optional field width, not before, so we accept %9:z, not %:9z.
17518         (my_strftime): Be sure to use L_('x') for literals.
17519
17520         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
17521         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
17522         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
17523         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
17524         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
17525         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
17526         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
17527         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
17528         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
17529         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
17530         * lib/xgethostname.c, lib/xreadlink.c:
17531         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
17532
17533         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
17534         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
17535         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
17536         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
17537         and don't include <sys/file.h>).
17538
17539 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
17540
17541         Sync from coreutils.
17542
17543         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
17544         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
17545         [!LDAV_DONE]: Avoid unused variable warning.
17546
17547 2005-09-21  Bruno Haible  <bruno@clisp.org>
17548
17549         * lib/unicodeio.h (unicode_to_mb): New declaration.
17550
17551 2005-09-20  Derek Price  <derek@ximbiot.com>
17552
17553         * lib/getaddrinfo.c: Don't include <netdb.h> included from
17554         getaddrinfo.h.
17555
17556 2005-09-20  Bruno Haible  <bruno@clisp.org>
17557
17558         * gnulib-tool: Remove trailing slashes from the values specified for
17559         --source-base, --m4-base, --tests-base, --aux-dir.
17560         Suggested by Simon Josefsson <jas@extundo.com>.
17561
17562 2005-09-20  Bruno Haible  <bruno@clisp.org>
17563
17564         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
17565         func_modules_to_filelist, func_import, func_create_testdir): Make all
17566         sorting results locale-independent, so that gnulib-cache.m4 doesn't
17567         change when gnulib-tool is invoked in a different locale.
17568
17569 2005-09-19  Simon Josefsson  <jas@extundo.com>
17570
17571         * m4/socklen.m4: Fix typo.
17572
17573 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
17574
17575         Use a consistent style for including <config.h>.
17576         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
17577         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
17578         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
17579         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
17580         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
17581         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
17582         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
17583         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
17584         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
17585         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
17586         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
17587         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
17588         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
17589         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
17590         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
17591         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
17592         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
17593         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
17594         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
17595         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
17596         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
17597         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
17598         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
17599         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
17600         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
17601         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
17602         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
17603         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
17604         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
17605         lib/xstrtoumax.c, lib/yesno.c:
17606         Standardize inclusion of config.h.
17607         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
17608         lib/inttostr.h:  Removed inclusion of config.h from header files.
17609         * lib/inttostr.c:  Adjusted in-tree users.
17610         * lib/timespec.h: Remove superfluous warning to include config.h.
17611         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
17612         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
17613         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
17614         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
17615         config.h with HAVE_CONFIG_H.
17616
17617 2005-09-19  Jim Meyering  <jim@meyering.net>
17618
17619         * modules/pathmax (License): Change to LGPL.
17620
17621 2005-09-19  Derek Price  <derek@ximbiot.com>
17622
17623         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
17624
17625 2005-09-19  Bruno Haible  <bruno@clisp.org>
17626
17627         * gnulib-tool (import): Provide default for --tests-base.
17628
17629 2005-09-19  Bruno Haible  <bruno@clisp.org>
17630
17631         * doc/quote.texi: New file, extracted from gnulib.texi.
17632         * doc/ctime.texi: New file, extracted from gnulib.texi.
17633         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
17634         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
17635         * doc/gnulib.texi: Include them.
17636
17637 2005-09-18  Bruno Haible  <bruno@clisp.org>
17638
17639         Portability fix.
17640         * gnulib-tool (func_readlink): New function.
17641         (func_ln_if_changed): Use it.
17642
17643 2005-09-18  Bruno Haible  <bruno@clisp.org>
17644
17645         * gnulib-tool: Support --with-tests also with --import.
17646         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
17647         (func_import): Use variables $testsbase and $inctests. Emit a
17648         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
17649         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
17650         SUBDIRS += $testsdir.
17651         (func_create_testdir): Update.
17652
17653 2005-09-18  Bruno Haible  <bruno@clisp.org>
17654
17655         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
17656         instead of $dry_run.
17657         (func_cp_if_changed, func_mv_if_changed): Remove functions.
17658         (func_ln_if_changed): Don't handle dry-run here.
17659         (func_import): In dry-run mode, detect more precisely which actions
17660         would be performed, and don't use "...ing" verbs.
17661
17662 2005-09-18  Bruno Haible  <bruno@clisp.org>
17663
17664         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
17665         (func_import): Use join on two temporary files instead of three nested
17666         loops, in order to determine which files are new or old.
17667
17668 2005-09-18  Bruno Haible  <bruno@clisp.org>
17669
17670         * gnulib-tool (func_import): Comment out code that spits out the
17671         new files with --dry-run.
17672
17673 2005-09-18  Bruno Haible  <bruno@clisp.org>
17674
17675         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
17676
17677 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
17678
17679         * lib/stat-time.h: New file.
17680         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
17681         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
17682         in a different way.
17683         (timespec_cmp): New function.
17684         * lib/utimecmp.c: Include stat-time.h.
17685         (SYSCALL_RESOLUTION): Depend on whether various struct stat
17686         members exist, not on the obsolescent ST_MTIM_NSEC.
17687         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
17688
17689 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
17690
17691         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
17692
17693 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
17694
17695         * MODULES.html.sh (File system functions): Add stat-time.
17696         * modules/stat-time: New file.
17697         * modules/timespec (Files): Remove m4/st_mtim.m4; this
17698         is now done in a different way, by the stat-time module.
17699         * modules/utimecmp (Depends-on): Add stat-time.
17700
17701 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
17702
17703         * m4/st_mtim.m4: Remove.  Superseded by...
17704         * m4/stat-time.m4: New file.
17705         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
17706         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
17707
17708 2005-09-15  Derek Price  <derek@ximbiot.com>
17709
17710         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
17711
17712 2005-09-15  Derek Price  <derek@ximbiot.com>
17713
17714         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
17715         * lib/regex_internal.c: Ditto, using this...
17716         (__GNUC_PREREQ): ...new macro.
17717         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
17718         using...
17719         (__GNUC_PREREQ): ...this new macro.
17720
17721         * lib/strstr.h: Include string.h. Define strstr as a macro here.
17722
17723 2005-09-15  Derek Price  <derek@ximbiot.com>
17724             Paul Eggert  <eggert@cs.ucla.edu>
17725
17726         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
17727         changes, consolidating in...
17728         * lib/regex_internal.h: ...this file.
17729
17730 2005-09-13  Jim Meyering  <jim@meyering.net>
17731
17732         * lib/canon-host.c: Filter through gnu indent and reword comments
17733         slightly.
17734         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
17735
17736 2005-09-13  Derek Price  <derek@ximbiot.com>
17737
17738         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
17739         failure.
17740         Reported by Jim Meyering  <jim@meyering.net>.
17741
17742 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
17743
17744         * lib/base64.c: Typo.
17745         (base64_encode): Put b64str in initialized data section.
17746
17747 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
17748
17749         Merge glibc and coreutils changes into gnulib, plus a few
17750         extra fixes.
17751         * lib/md5.c: Use #error rather than a string.
17752         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
17753         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
17754         (__attribute__): Define to empty for non recent-GCC.
17755         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
17756         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
17757         Renamed from their non-__ counterparts, with new macros replacing
17758         them if not _LIBC.  Add __THROW attribute.
17759         (rol): Remove.
17760         (struct md5_ctx): Align buffer if using GCC.
17761         * lib/sha1.h (struct sha1_ctx): Likewise.
17762         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
17763         The old name was backwards.
17764         (NOTSWAP): Remove; not used.
17765         (rol): New macro, moved here from md5.h.
17766         (sha1_process_block): Remove a FIXME that doesn't make sense.
17767
17768 2005-09-12  Derek Price  <derek@ximbiot.com>
17769
17770         Return usable errors from canon-host.
17771         * lib/canon-host.h: New file.
17772         * lib/canon-host.c (canon_host): Wrap...
17773         (canon_host_r): ...this new function, which now relies exclusively on
17774         getaddrinfo.
17775         (ch_strerror): New function.
17776         (last_cherror): New global.
17777         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
17778         interface.
17779         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
17780         void *.
17781         (freeaddrinfo): Free ai->ai_canonname when set.
17782
17783 2005-09-12  Derek Price  <derek@ximbiot.com>
17784
17785         Make canon-host require getaddrinfo.
17786         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
17787         AC_LIBSOURCE canon-host.h.  Call...
17788         (gl_PREREQ_CANON_HOST): ...this new function, which requires
17789         gl_GETADDRINFO.
17790         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
17791
17792 2005-09-12  Derek Price  <derek@ximbiot.com>
17793
17794         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
17795         LGPL.
17796         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
17797
17798 2005-09-12  Derek Price  <derek@ximbiot.com>
17799
17800         * lib/gai_strerror.c: Include config.h when available.  Include
17801         getaddrinfo.h before other headers to test interface.
17802         Reported by Larry Jones <lawrence.jones@ugs.com>.
17803
17804 2005-09-12  Derek Price  <derek@ximbiot.com>
17805             Paul Eggert  <eggert@cs.ucla.edu>
17806
17807         * modules/glob (Files): Add glob-libc.h.
17808
17809 2005-09-12  Derek Price  <derek@ximbiot.com>
17810             Paul Eggert  <eggert@cs.ucla.edu>
17811
17812         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
17813         glob_.h, glob-libc.h.
17814         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
17815
17816 2005-09-12  Derek Price  <derek@ximbiot.com>
17817             Paul Eggert  <eggert@cs.ucla.edu>
17818
17819         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
17820         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
17821         protecting things that should be done only in gnulib contexts.
17822         * lib/glob_.h: New file, containing only the glob things needed for
17823         gnulib.
17824         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
17825         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
17826         (glob, globfree, glob_pattern_p): Now defined simply in terms of
17827         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
17828         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
17829         and to respect the namespace rules better.
17830
17831 2005-09-08  Simon Josefsson  <jas@extundo.com>
17832
17833         * modules/socklen: New file.
17834
17835 2005-09-08  Simon Josefsson  <jas@extundo.com>
17836
17837         * m4/socklen.m4: New file.
17838
17839 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17840
17841         * modules/utimens (Files): Add m4/utimbuf.m4, since
17842         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
17843         Reported by Sergey Poznyakoff.
17844
17845 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17846
17847         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
17848         definitions, since that's the preferred style in glibc.
17849         Fix a minor spacing issue, and update copyright notice to match
17850         glibc's.
17851
17852 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17853
17854         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
17855
17856 2005-09-06  Simon Josefsson  <jas@extundo.com>
17857
17858         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
17859         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
17860
17861 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
17862
17863         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
17864         warning.
17865
17866 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
17867
17868         * config/srclist.txt: Add glibc bug 1302.
17869
17870 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
17871
17872         Change bitset word type from unsigned int to unsigned long int,
17873         as this has better performance on typical 64-bit hosts.
17874         Port bitset code to hosts with unusual word sizes.
17875         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
17876         (build_collating_symbol):
17877         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
17878         argument is a bitset.  This is merely a style issue, but it makes
17879         it clearer that an entire array is expected.
17880         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
17881         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
17882         Port to the case where bitset_word is not the same as unsigned int.
17883         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
17884         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
17885         Likewise.
17886         * lib/regexec.c (check_dst_limits_calc_pos_1,
17887         check_subexp_matching_top):
17888         (build_trtable, group_nodes_into_DFAstates):
17889         Likewise.
17890         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
17891         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
17892         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
17893         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
17894         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
17895         * lib/regcomp.c (optimize_subexps, lower_subexp):
17896         Work even if bitset_word has holes in its bitwise representation.
17897         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
17898         * lib/regexec.c (check_dst_limits_calc_pos_1,
17899         check_subexp_matching_top):
17900         Likewise.
17901         * lib/regex_internal.c (re_string_reconstruct):
17902         Don't assume UCHAR_MAX == 255.
17903         * lib/regex_internal.h (bitset_set_all): Likewise.
17904         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
17905         All uses changed.
17906         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
17907         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
17908         All uses changed.
17909         (BITSET_WORD_MAX): New macro.
17910         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
17911         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
17912         (bitset_empty, bitset_copy):
17913         Prefer sizeof (bitset) to multiplying it out ourselves.
17914         (bitset_not_merge): Remove; unused.
17915         (bitset_contain): Return bool, not unsigned int with one bit on.
17916         All callers changed.
17917         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
17918         alignment than re_node_set; do this by defining a new internal
17919         type struct dests_alloc and using it to allocate memory.
17920
17921 2005-09-05  Bruno Haible  <bruno@clisp.org>
17922
17923         * gnulib-tool (func_import): Fix comparison in handling of symbolic
17924         links.
17925
17926 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
17927
17928         * modules/size_max (Makefile.am): Add size_max.h
17929
17930 2005-09-04  Derek Price  <derek@ximbiot.com>
17931
17932         * gnulib-tool (func_import): Fix reversed $symbolic logic.
17933
17934 2005-09-03  Simon Josefsson  <jas@extundo.com>
17935
17936         * gnulib-tool: Fix typo.
17937
17938 2005-09-03  Simon Josefsson  <jas@extundo.com>
17939
17940         * config/srclist.txt: Add glibc bug 1293.
17941
17942 2005-09-03  Derek Price  <derek@ximbiot.com>
17943
17944         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
17945         From Larry Jones <lawrence.jones@ugs.com>.
17946
17947 2005-09-02  Simon Josefsson  <jas@extundo.com>
17948
17949         * modules/socklen: New file.
17950
17951 2005-09-02  Simon Josefsson  <jas@extundo.com>
17952
17953         * modules/havelib: New module.
17954
17955         * modules/gettext, modules/iconv, modules/lock, modules/readline:
17956         Use havelib.
17957
17958 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
17959
17960         Check for arithmetic overflow when calculating sizes, to prevent
17961         some buffer-overflow issues.  These patches are conservative, in the
17962         sense that when I couldn't determine whether an overflow was possible,
17963         I inserted a run-time check.
17964         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
17965         macros.
17966         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
17967         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
17968         (re_xnrealloc, re_x2nrealloc): New inline functions.
17969         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
17970         parse_bracket_exp):
17971         (build_equiv_class, build_charclass): Check for arithmetic overflow
17972         in size expression calculations.
17973         * lib/regex_internal.c (re_string_realloc_buffers):
17974         (build_wcs_upper_buffer, re_node_set_add_intersect):
17975         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
17976         (re_dfa_add_node, register_state): Likewise.
17977         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
17978         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
17979         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
17980         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
17981
17982 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
17983
17984         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
17985         m4/ulonglong.m4.  Problem reported by Martin Lambers.
17986
17987 2005-09-02  Bruno Haible  <bruno@clisp.org>
17988
17989         Support for lib vs. lib64 distinction on biarch platforms.
17990         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
17991         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
17992         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
17993
17994 2005-09-02  Bruno Haible  <bruno@clisp.org>
17995
17996         * gnulib-tool (import): In the other first-use case, provide defaults
17997         as well.
17998
17999 2005-09-02  Bruno Haible  <bruno@clisp.org>
18000
18001         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
18002         patches not yet found in the latest gettext release.
18003
18004 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
18005
18006         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
18007         to avoid a collision with bits/local_lim.h in glibc.
18008         All uses changed.  Problem reported by Dmitry V. Levin in
18009         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
18010
18011         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
18012         bugs in int versus size_t comparisons.
18013         (re_string_context_at): Fix bug where the code assumed that
18014         Idx is signed.
18015
18016         Use bool where appropriate.
18017         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
18018         All callers changed.
18019         (calc_eclosure_iter): Likewise, for ROOT arg.
18020         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
18021         (build_charclass_op): Likewise, for NON_MATCH arg.
18022         * lib/regex_internal.c (re_string_allocate, re_string_construct):
18023         (re_string_construct_common): Likewise, for ICASE arg.
18024         * lib/regexec.c (re_search_2_stub, re_search_stub):
18025         Likewise, for RET_LEN arg.
18026         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
18027         (set_regs): Likewise, for FL_BACKTRACK arg.
18028         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
18029         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
18030         (calc_eclosure_iter, parse_bracket_exp):
18031         Use bool for internal variables that are booleans.
18032         * lib/regexec.c (re_search_internal, check_matching,
18033         proceed_next_node):
18034         (set_regs, build_sifted_states, sift_states_bkref):
18035         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
18036         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
18037         (find_collation_sequence_value):
18038         Likewise.
18039         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
18040         (re_node_set_compare):
18041         Return bool, not int. All callers changed.
18042         * lib/regexec.c (check_halt_node_context, check_dst_limits):
18043         (build_trtable, check_node_accept): Likewise.
18044         * lib/regex_internal.h: Include stdbool.h.
18045
18046         Fix bugs uncovered when converting to bool.
18047         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
18048         failure instead of charging ahead blindly.
18049         * lib/regex_internal.c (register_state): Likewise.
18050         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
18051         for freeing internal storage.
18052         (group_nodes_into_DFA_states): Use unsigned int, not int, for
18053         bitset pieces used as boolean, to avoid undefined behavior
18054         on hosts that do int overflow checking.
18055
18056 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
18057
18058         * config/srclist.txt: Add glibc bugs 1285-1287.
18059
18060 2005-09-01  Jim Meyering  <jim@meyering.net>
18061
18062         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
18063         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
18064         Require gl_STAT_MACROS, too.
18065
18066 2005-09-01  Bruno Haible  <bruno@clisp.org>
18067
18068         * gnulib-tool (import): In the first-use case, provide defaults.
18069
18070 2005-09-01  Bruno Haible  <bruno@clisp.org>
18071
18072         * gnulib-tool (func_import): Remove the .tmp files.
18073
18074 2005-09-01  Bruno Haible  <bruno@clisp.org>
18075
18076         * gnulib-tool (func_import): Fix handling of symbolic links.
18077
18078 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
18079
18080         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
18081         old glibc regex code mishandles strings longer than 2**31 bytes.
18082         This patch fixes this when the regex code is used in gnulib
18083         (i.e., outside glibc).
18084
18085         This patch should not affect the use of the regex code inside
18086         glibc.  No doubt this problem also needs to be handled for glibc
18087         as well, but the result will be an incompatible change to the
18088         glibc ABI, and the old ABI will have to be supported too.  That
18089         can be the the subject for another patch.
18090
18091         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
18092         governing whether the rest of this patch is active.  By default,
18093         the macro is disabled and the patch has no effect.
18094         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
18095         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
18096         (struct re_pattern_buffer, re_search, re_search_2, re_match):
18097         (re_match_2, re_set_registers): Use the new types.
18098         * lib/regex_internal.h (Idx, re_hashval_t): New types.
18099         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
18100         New macros.
18101         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
18102         (re_string_context_at, bin_tree_t, re_dfastate_t):
18103         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
18104         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
18105         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
18106         (re_string_char_size_at, re_string_wchar_at):
18107         (re_string_elem_size_at):
18108         Use the new types and macros to port to 64-bit hosts.
18109         Use unsigned types for internal values, so that the code
18110         mostly works even for arrays larger than SSIZE_MAX.
18111         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
18112         (search_duplicated_node, calc_eclosure_iter, fetch_number):
18113         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
18114         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
18115         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
18116         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
18117         (calc_inveclosure, parse_dup_op, build_range_exp):
18118         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
18119         (fetch_number, create_token_tree, mark_opt_subexp):
18120         Likewise.
18121         * lib/regex_internal.c (re_string_construct_common,
18122         create_ci_newstate):
18123         (create_cd_newstate, re_string_allocate, re_string_construct):
18124         (re_string_realloc_buffers, build_wcs_upper_buffer):
18125         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
18126         (re_string_reconstruct, re_string_peek_byte_case):
18127         (re_string_fetch_byte_case, re_string_context_at):
18128         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
18129         (re_node_set_init_copy, re_node_set_add_intersect):
18130         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
18131         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
18132         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
18133         (re_acquire_state, re_acquire_state_context, register_state):
18134         Likewise.
18135         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
18136         search_cur_bkref_entry):
18137         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
18138         (re_search_internal, re_search_2_stub, re_search_stub)
18139         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
18140         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
18141         (update_cur_sifted_state, check_dst_limits):
18142         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
18143         (check_subexp_limits, sift_states_bkref, merge_state_array):
18144         (check_subexp_matching_top, get_subexp, get_subexp_sub):
18145         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
18146         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
18147         (expand_bkref_cache, check_node_accept_bytes):
18148         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
18149         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
18150         (acquire_init_state_context, check_halt_node_context):
18151         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
18152         (sift_states_backward, clean_state_log_if_needed):
18153         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
18154         (find_recover_state, transit_state_sb, transit_state_mb):
18155         (transit_state_bkref, build_trtable, match_ctx_clean):
18156         Likewise.
18157         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
18158         to work around an assumption that REG_MISSING is negative.
18159
18160         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
18161         (seek_collating_symbol_entry) [defined _LIBC]:
18162         (lookup_collation_sequence_value) [defined _LIBC]:
18163         (build_range_exp, build_collating_symbol) [defined _LIBC]:
18164         Use prototypes rather than old-style function definitions.
18165         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
18166         (transit_state_sb) [0]:
18167         (find_collation_sequence_value) [defined _LIBC]: Likewise.
18168
18169         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
18170         rm_eo.
18171
18172         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
18173         (optimize_subexps, lower_subexp):
18174         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
18175         since the signed shift might overflow.  Use 1u<<31 instead.
18176         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
18177         Likewise.
18178         * lib/regexec.c (check_dst_limits_calc_pos_1,
18179         check_subexp_matching_top): Likewise.
18180
18181         * lib/regcomp.c (optimize_subexps, lower_subexp):
18182         Use CHAR_BIT rather than 8, for clarity.
18183         * lib/regexec.c (check_dst_limits_calc_pos_1):
18184         (check_subexp_matching_top): Likewise.
18185         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
18186         have to worry about portability issues when shifting it left.
18187         Remove no-longer-needed test for table_size > 0.
18188         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
18189         in a word, as the resulting behavior is undefined.
18190         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
18191         in one case, a <= should have been an <, and in another case the
18192         whole test was missing.
18193         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
18194         the standard name CHAR_BIT.
18195         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
18196         this is not true on one's complement and signed-magnitude hosts.
18197
18198         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
18199         next_last_offset.
18200         (struct re_dfa_t): Remove unused member states_alloc.
18201         * lib/regcomp.c (init_dfa): Don't initialize unused members.
18202
18203 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
18204
18205         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
18206         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
18207         and large-file glibc and in 32-bit large-file Solaris.
18208
18209 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
18210
18211         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
18212         lengths fit in regoff_t; this isn't true if regoff_t is the same
18213         width as size_t.
18214         * lib/regex.c (re_search_internal): 5th arg is LAST_START
18215         (= START + RANGE) instead of RANGE.  This avoids overflow
18216         problems when regoff_t is the same width as size_t.
18217         All callers changed.
18218         (re_search_2_stub): Check for overflow when adding the
18219         sizes of the two strings.
18220         (re_search_stub): Check for overflow when adding START
18221         to RANGE; if it occurs, substitute the extreme value.
18222
18223 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
18224
18225         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
18226
18227 2005-08-31  Jim Meyering  <jim@meyering.net>
18228
18229         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
18230         a pointer-to-const.
18231         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
18232         (register_state): Likewise.
18233         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
18234         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
18235         (group_nodes_into_DFAstates): Likewise.
18236
18237 2005-08-31  Jim Meyering  <jim@meyering.net>
18238
18239         * check-module: Add a FIXME comment.
18240
18241 2005-08-31  Eric Blake  <ebb9@byu.net>
18242
18243         * modules/unistd-safer (Files): Add unistd--.h.
18244         * modules/stdio-safer (Files): Add stdio--.h.
18245
18246 2005-08-31  Derek Price  <derek@ximbiot.com>
18247
18248         * lib/getdelim.c (getdelim): Return EOF on EOF.
18249         Reported by Larry Jones <lawrence.jones@ugs.com>.
18250
18251 2005-08-31  Bruno Haible  <bruno@clisp.org>
18252
18253         Avoid unnecessary diffs in the generated lib/Makefile.am.
18254         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
18255         the generated files.
18256         (func_import): Don't set cmd.
18257
18258 2005-08-31  Bruno Haible  <bruno@clisp.org>
18259
18260         * lib/strstr.c: Include <stddef.h>, for NULL.
18261         * lib/strcasestr.c: Likewise.
18262         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
18263
18264 2005-08-31  Bruno Haible  <bruno@clisp.org>
18265
18266         * gnulib-tool: New option --macro-prefix.
18267         (func_import): Use macro_prefix.
18268         (import): Handle option --macro-prefix.
18269
18270 2005-08-31  Bruno Haible  <bruno@clisp.org>
18271
18272         * gnulib-tool (import): Rename most ac_* variables to cached_*.
18273         Also use new variables cached_lgpl, cached_libtool.
18274
18275 2005-08-31  Bruno Haible  <bruno@clisp.org>
18276
18277         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
18278         always instantiating them.
18279
18280 2005-08-31  Bruno Haible  <bruno@clisp.org>
18281
18282         * gnulib-tool (func_import): Read the previous cached settings
18283         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
18284         earlier added by gnulib but are now dropped. Warn when a gnulib file
18285         overwrites a non-gnulib file.
18286
18287 2005-08-31  Bruno Haible  <bruno@clisp.org>
18288
18289         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
18290         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
18291         projects that don't keep autogenerated files in CVS. Put into
18292         actioncmd only the specified modules, not the transitive closure.
18293
18294 2005-08-31  Bruno Haible  <bruno@clisp.org>
18295
18296         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
18297         Create directories that shall be filled.
18298         (import): Don't look for gl_* macros in configure.ac. Recurse across
18299         all directories containing a gnulib-cache.m4 files, if meaningful.
18300
18301 2005-08-31  Bruno Haible  <bruno@clisp.org>
18302
18303         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
18304         (import): Set seen_libtool when we see gl_LIBTOOL.
18305
18306 2005-08-31  Bruno Haible  <bruno@clisp.org>
18307
18308         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
18309         declaration macro definitions from generated gnulib.m4.
18310
18311 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
18312
18313         * lib/iconvme.h: Add prototype for iconv_alloc.
18314
18315 2005-08-29  Simon Josefsson  <jas@extundo.com>
18316
18317         * lib/iconvme.c: Fix errno.
18318
18319 2005-08-29  Bruno Haible  <bruno@clisp.org>
18320
18321         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
18322         that it works when the directory contains spaces.
18323
18324 2005-08-29  Bruno Haible  <bruno@clisp.org>
18325
18326         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
18327
18328 2005-08-29  Bruno Haible  <bruno@clisp.org>
18329
18330         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
18331         Emit more advice.
18332
18333 2005-08-29  Bruno Haible  <bruno@clisp.org>
18334         and Stepan Kasal  <kasal@ucw.cz>
18335
18336         * check-module: If more parameters are given, check each of them
18337         separately; add more exceptions, as noted by Jim Meyering.
18338         (check_module): New procedure.
18339         (%exempt_header): Now contains all exceptions.
18340
18341 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
18342
18343         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
18344
18345 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
18346
18347         * lib/iconvme.c: Split iconv_string into iconv_alloc.
18348
18349 2005-08-28  Bruno Haible  <bruno@clisp.org>
18350
18351         * m4/gnulib-tool.m4: New file.
18352
18353 2005-08-27  Jim Meyering  <jim@meyering.net>
18354
18355         * modules/unistd-safer (Files): Add pipe-safer.c.
18356         * modules/fcntl-safer (Files): Add creat-safer.c.
18357
18358 2005-08-27  Jim Meyering  <jim@meyering.net>
18359
18360         * m4/stdlib-safer.m4: New file.  From coreutils.
18361         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
18362         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
18363         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
18364         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
18365         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
18366
18367 2005-08-27  Jim Meyering  <jim@meyering.net>
18368
18369         * lib/fopen-safer.c: Merge minor changes from coreutils.
18370         * lib/dup-safer.c: Likewise.
18371         * lib/fd-safer.c: Likewise.
18372
18373         Merge from coreutils.
18374         * lib/stdio--.h: New file.
18375         * lib/stdlib--.h: New file.
18376         * lib/mkstemp-safer.c: New file.
18377
18378         GNU tar needs these.
18379         * lib/pipe-safer.c: New file.
18380         * lib/creat-safer.c: New file.
18381         * lib/fcntl--.h (creat): Define to creat_safer.
18382         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
18383         * lib/unistd--.h (pipe): Define to pipe_safer.
18384         * lib/unistd-safer.h: Declare pipe_safer.
18385
18386 2005-08-26  Simon Josefsson  <jas@extundo.com>
18387
18388         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
18389         Haible <bruno@clisp.org>.
18390
18391 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
18392
18393         * lib/regex_internal.h: Remove all references to
18394         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
18395         or better.
18396         (bitset_not, bitset_merge, bitset_not_merge):
18397         (bitset_mask, re_string_allocate, re_string_construct):
18398         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
18399         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
18400         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
18401         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
18402         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
18403         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
18404         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
18405         (re_acquire_state_context):
18406         Remove unnecessary forward decls.
18407         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
18408         Put __attribute at function definition,
18409         now that the function decl has been removed.
18410         * lib/regex_internal.c (re_string_peek_byte_case):
18411         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
18412         Likewise.
18413
18414 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
18415
18416         * m4/regex.m4: Add AC_PREREQ(2.50).
18417         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
18418
18419 2005-08-25  Simon Josefsson  <jas@extundo.com>
18420
18421         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
18422         __fsetlocking.
18423
18424 2005-08-25  Simon Josefsson  <jas@extundo.com>
18425
18426         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
18427         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
18428         GLIBC specific code.
18429
18430 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18431
18432         Make regex safe for g++.  This fixes one real bug (an "err"
18433         that should have been "*err").  g++ problem reported by
18434         Sam Steingold.
18435         * lib/regex_internal.h (re_calloc): New macro, consistent with
18436         re_malloc etc.  All callers of calloc changed to use re_calloc.
18437         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
18438         not int.  All callers changed.
18439         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
18440         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
18441         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
18442         (find_recover_state): Change "err" to "*err"; this fixes what
18443         appears to be a real bug.
18444         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
18445         versus int.
18446
18447 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18448
18449         * modules/regex (Depends-on): Add malloc, since the code
18450         assumes that !malloc(0) means failure.
18451
18452 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18453
18454         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
18455
18456         alloca modernization/simplification for regex.
18457         * lib/regex.c: Remove portability cruft for alloca.  This no longer
18458         needs to be at the start of the file, and can be moved into
18459         regex_internal.h and simplified.
18460         * lib/regex_internal.h: Include <alloca.h>.
18461         (__libc_use_alloca) [!defined _LIBC]: New macro.
18462         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
18463         now works outside glibc.
18464
18465 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18466
18467         * config/srclist.txt: Add glibc bugs 1241, 1245.
18468
18469 2005-08-25  Jim Meyering  <jim@meyering.net>
18470
18471         * lib/open-safer.c: Include <config.h>.
18472         Otherwise, we'd lose LARGEFILE support in any file using
18473         e.g. "fcntl--.h"
18474
18475 2005-08-25  Bruno Haible  <bruno@clisp.org>
18476
18477         * m4/minmax.m4: Require autoconf 2.52.
18478         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
18479         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
18480         alternatives of translit over the alphabet.
18481         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
18482
18483 2005-08-24  Simon Josefsson  <jas@extundo.com>
18484
18485         * tests/test-getpass.c: New file.
18486
18487 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
18488
18489         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
18490         for GNU regex features.
18491
18492 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
18493
18494         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
18495         * lib/regex.h (regerror): Likewise.
18496
18497         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
18498         requires this.  (The code never needed it.)
18499
18500         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
18501         All uses of recently-renamed identifiers changed to use the new,
18502         POSIX-compliant names.  The code will build and run just fine
18503         without these changes, but it's better to eat our own dog food
18504         and use the standard-conforming names.
18505
18506         * lib/regex.h: Fix a multitude of POSIX name space violations.
18507         These changes have an effect only for programs that define
18508         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
18509         do not change anything for programs compiled in the normal way.
18510         Also, there is no effect on the ABI.
18511
18512         (_REGEX_SOURCE): New macro.
18513         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
18514         defined and _GNU_SOURCE is not; this fixes a name space violation.
18515
18516         Rename the following macros to obey POSIX requirements.
18517         The old names are still visible as macros if _REGEX_SOURCE is defined.
18518         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
18519         RE_BACKSLASH_ESCAPE_IN_LISTS.
18520         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
18521         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
18522         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
18523         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
18524         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
18525         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
18526         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
18527         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
18528         (REG_INTERVALS): renamed from RE_INTERVALS.
18529         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
18530         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
18531         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
18532         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
18533         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
18534         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
18535         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
18536         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
18537         RE_UNMATCHED_RIGHT_PAREN_ORD.
18538         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
18539         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
18540         (REG_DEBUG): renamed from RE_DEBUG.
18541         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
18542         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
18543         unusual, since we can't clash with the POSIX REG_ICASE.
18544         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
18545         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
18546         (REG_NO_SUB): renamed from RE_NO_SUB.
18547         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
18548         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
18549         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
18550         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
18551         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
18552         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
18553         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
18554         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
18555         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
18556         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
18557         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
18558         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
18559         RE_SYNTAX_POSIX_MINIMAL_BASIC.
18560         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
18561         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
18562         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
18563         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
18564         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
18565         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
18566         (REG_FIXED): Renamed from REGS_FIXED.
18567         (REG_NREGS): Renamed from RE_NREGS.
18568
18569         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
18570         of other REG_* macros, since POSIX says the user is allowed to
18571         #undef these macros selectively.
18572
18573         (reg_errcode_t): Update comment stating what other tables need
18574         to be consistent.
18575
18576         Rename the following enum values to obey POSIX requirements.
18577         The old names are still visible as macros.
18578         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
18579         is not defined, since GNU is supposed to be a superset of POSIX as
18580         much as possible, and since we want reg_errcode_t to be a signed
18581         type for implementation consistency.
18582         (_REG_NOERROR): Renamed from REG_NOERROR.
18583         (_REG_NOMATCH): Renamed from REG_NOMATCH.
18584         (_REG_BADPAT): Renamed from REG_BADPAT.
18585         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
18586         (_REG_ECTYPE): Renamed from REG_ECTYPE.
18587         (_REG_EESCAPE): Renamed from REG_EESCAPE.
18588         (_REG_ESUBREG): Renamed from REG_ESUBREG.
18589         (_REG_EBRACK): Renamed from REG_EBRACK.
18590         (_REG_EPAREN): Renamed from REG_EPAREN.
18591         (_REG_EBRACE): Renamed from REG_EBRACE.
18592         (_REG_BADBR): Renamed from REG_BADBR.
18593         (_REG_ERANGE): Renamed from REG_ERANGE.
18594         (_REG_ESPACE): Renamed from REG_ESPACE.
18595         (_REG_BADRPT): Renamed from REG_BADRPT.
18596         (_REG_EEND): Renamed from REG_EEND.
18597         (_REG_ESIZE): Renamed from REG_ESIZE.
18598         (_REG_ERPAREN): Renamed from REG_ERPAREN.
18599         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
18600         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
18601         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
18602         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
18603
18604         (_REG_RE_NAME, _REG_RM_NAME): New macros.
18605         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
18606         changed.  But support the old name if the new one is not defined
18607         and if _REGEX_SOURCE.
18608
18609         Change the following member names in struct re_pattern_buffer.
18610         The old names are still supported if !_REGEX_SOURCE.
18611         The new names are always supported, regardless of _REGEX_SOURCE.
18612         (re_buffer): Renamed from buffer.
18613         (re_allocated): Renamed from allocated.
18614         (re_used): Renamed from used.
18615         (re_syntax): Renamed from syntax.
18616         (re_fastmap): Renamed from fastmap.
18617         (re_translate): Renamed from translate.
18618         (re_can_be_null): Renamed from can_be_null.
18619         (re_regs_allocated): Renamed from regs_allocated.
18620         (re_fastmap_accurate): Renamed from fastmap_accurate.
18621         (re_no_sub): Renamed from no_sub.
18622         (re_not_bol): Renamed from not_bol.
18623         (re_not_eol): Renamed from not_eol.
18624         (re_newline_anchor): Renamed from newline_anchor.
18625
18626         Change the following member names in struct re_registers.
18627         The old names are still supported if !_REGEX_SOURCE.
18628         The new names are always supported, regardless of _REGEX_SOURCE.
18629         (rm_num_regs): Renamed from num_regs.
18630         (rm_start): Renamed from start.
18631         (rm_end): Renamed from end.
18632
18633         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
18634         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
18635         Prepend __ to parameter names.
18636
18637         Undo yesterday's changes.
18638
18639 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
18640
18641         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
18642         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
18643         lib/regex.c.
18644
18645 2005-08-24  Jim Meyering  <jim@meyering.net>
18646
18647         Sync from coreutils.
18648         * m4/fcntl-safer.m4: New file.
18649
18650         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
18651         and object files for this module.
18652
18653 2005-08-24  Jim Meyering  <jim@meyering.net>
18654
18655         Sync from coreutils.
18656         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
18657
18658 2005-08-24  Jim Meyering  <jim@meyering.net>
18659
18660         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
18661         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
18662
18663 2005-08-24  Jim Meyering  <jim@meyering.net>
18664
18665         * modules/fcntl-safer: New module.
18666         * modules/fts (Depends-on): Add fcntl-safer.
18667         * MODULES.html.sh (File descriptor based Input/Output):
18668         Add fcntl-safer.
18669
18670 2005-08-24  Bruno Haible  <bruno@clisp.org>
18671
18672         Support for unit test modules.
18673         * modules/README: Mention tests modules.
18674         * modules/TEMPLATE-TESTS: New file.
18675         * gnulib-tool: New options --extract-tests-module, --with-tests and
18676         --tests-base (unused for the moment).
18677         (testsbase, inctests): New variables.
18678         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
18679         (func_verify_module): Exclude TEMPLATE-TESTS.
18680         (func_verify_nontests_module, func_verify_tests_module): New functions.
18681         (func_get_dependencies): Add implicit dependency for tests modules.
18682         (func_get_tests_module): New function.
18683         (func_modules_transitive_closure): When --with-tests was specified,
18684         include the unit tests as well, unless explicitly avoided.
18685         (func_emit_lib_Makefile_am): Ignore the tests modules here.
18686         (func_emit_tests_Makefile_am): New function.
18687         (func_create_testdir): When --with-tests was specified, emit a
18688         tests/ directory.
18689         * MODULES.html.sh (Future developments): Update.
18690
18691 2005-08-24  Bruno Haible  <bruno@clisp.org>
18692
18693         * modules/tls-tests: New file.
18694         * tests/test-tls.c: New file, from GNU gettext.
18695
18696 2005-08-24  Bruno Haible  <bruno@clisp.org>
18697
18698         * modules/lock-tests: New file.
18699         * tests/test-lock.c: New file, from GNU gettext.
18700
18701 2005-08-24  Bruno Haible  <bruno@clisp.org>
18702
18703         * lib/lock.h: Add multiple inclusion guard.
18704         * lib/tls.h: Add multiple inclusion guard.
18705
18706 2005-08-24  Bruno Haible  <bruno@clisp.org>
18707
18708         * gnulib-tool: Add support for the --aux-dir option to
18709         --create-testdir, --create-megatestdir, --test, --megatest.
18710         (func_create_testdir, func_create_megatestdir): Optionally emit a
18711         AC_CONFIG_AUX_DIR directive.
18712         (create-testdir, create-megatestdir, test, megatest): Provide a
18713         default value for $auxdir.
18714
18715 2005-08-24  Bruno Haible  <bruno@clisp.org>
18716
18717         * gnulib-tool (import): Use compound statement instead of subshell
18718         where possible.
18719
18720 2005-08-24  Bruno Haible  <bruno@clisp.org>
18721
18722         * gnulib-tool (import): Change --aux-dir default to "build-aux".
18723
18724 2005-08-24  Bruno Haible  <bruno@clisp.org>
18725
18726         * gnulib-tool (func_version): Update.
18727
18728 2005-08-24  Bruno Haible  <bruno@clisp.org>
18729
18730         * gnulib-tool (func_import, func_create_testdir,
18731         func_create_megatestdir): Quote all autoconf macro arguments.
18732
18733 2005-08-24  Bruno Haible  <bruno@clisp.org>
18734
18735         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
18736         option --force, because --force causes the aclocal.m4 of each
18737         subdirectory to be newer than the corresponding config.h.in.
18738
18739 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18740
18741         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
18742         All contents moved to gl_REGEX.
18743         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
18744         assume that it does.
18745
18746 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18747
18748         * lib/regex.h (REG_NOSYS)
18749         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
18750         Define, since POSIX requires it as of 2001.
18751         (_REG_ENOSYS)
18752         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
18753         New private symbol, used to keep the enum signed in all cases.
18754         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
18755         Youngman in
18756         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
18757
18758         * lib/regex_internal.c (re_string_skip_chars, register_state):
18759         (calc_state_hash):
18760         Remove forward decls; no longer needed now that we use prototypes.
18761         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
18762         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
18763         (clean_state_log_if_needed): Likewise.
18764
18765 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18766
18767         * config/srclist.txt: Add glibc bugs 1231-1233.
18768
18769 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18770
18771         Fix problems reported by Sam Steingold in
18772         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
18773         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
18774         assumed that reg_errcode_t is a signed type, which is not
18775         necessarily true if _XOPEN_SOURCE is not defined.
18776         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
18777         since some compilers warn about it otherwise.
18778
18779 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18780
18781         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
18782         (init_word_char, create_initial_state, duplicate_node_closure):
18783         (fetch_token, peek_token_bracket, build_range_exp):
18784         (build_collating_symbol): Remove forward decls; no longer needed
18785         now that we use prototypes.
18786
18787         * lib/regcomp.c:
18788         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
18789         (re_compile_fastmap_iter, regcomp, regerror, regfree):
18790         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
18791         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
18792         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
18793         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
18794         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
18795         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
18796         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
18797         (build_range_exp, build_collating_symbol, parse_bracket_exp):
18798         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
18799         (build_charclass, build_charclass_op, fetch_number, create_tree):
18800         (create_token_tree, mark_opt_subexp, duplicate_tree):
18801         Use prototypes rather than old-style definitions.
18802
18803         * lib/regex_internal.c:
18804         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
18805         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
18806         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
18807         (re_string_reconstruct, re_string_peek_byte_case):
18808         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
18809         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
18810         (re_node_set_init_copy, re_node_set_add_intersect):
18811         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
18812         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
18813         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
18814         (re_acquire_state, re_acquire_state_context, register_state):
18815         (create_ci_newstate, create_cd_newstate, free_state):
18816         Likewise.
18817         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
18818         re_search_2):
18819         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
18820         (re_search_internal, prune_impossible_nodes):
18821         (acquire_init_state_context, check_matching, static):
18822         (check_halt_node_context, check_halt_state_context, proceed_next_node):
18823         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
18824         (update_regs, sift_states_backward, build_sifted_states):
18825         (clean_state_log_if_needed, merge_state_array):
18826         (update_cur_sifted_state, add_epsilon_src_nodes):
18827         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
18828         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
18829         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
18830         (find_recover_state, check_subexp_matching_top, transit_state_mb):
18831         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
18832         (check_arrival, check_arrival_add_next_nodes):
18833         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
18834         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
18835         (check_node_accept_bytes, check_node_accept, extend_buffers):
18836         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
18837         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
18838         (sift_ctx_init):
18839         Likewise.
18840
18841         * lib/regex_internal.h:
18842         (re_string_allocate, re_string_construct, re_string_reconstruct):
18843         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
18844         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
18845         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
18846         (re_string_context_at, re_string_peek_byte_case):
18847         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
18848         is defined, since we now use prototypes always.
18849
18850         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
18851         C89 or better.  All uses removed.
18852
18853 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18854
18855         * config/srclist.txt: Add glibc bugs 1220-1227.
18856
18857 2005-08-20  Jim Meyering  <jim@meyering.net>
18858
18859         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
18860         of unused local, dfa.
18861
18862 2005-08-20  Bruno Haible  <bruno@clisp.org>
18863
18864         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
18865
18866 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18867
18868         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
18869         (re_node_set_insert_last, re_dfa_add_node):
18870         Rename local variables to avoid GCC shadowing warnings.
18871
18872 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18873
18874         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
18875         [defined lint]: Suppress bogus uninitialized-variable warnings.
18876
18877         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
18878         and let the caller return REG_ESPACE if out of space.  This
18879         removes an uninitialied-variable warning with GCC 4.0.1, and also
18880         avoids taking the address of a local variable.  All callers
18881         changed.
18882
18883 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18884
18885         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
18886         $LIBCSRC/posix/regexec.c.
18887         Add glibc bug 1217 for regcomp.c.
18888
18889 2005-08-19  Jim Meyering  <jim@meyering.net>
18890
18891         * lib/regexec.c (proceed_next_node): Redo local variables to
18892         avoid GCC shadowing warnings.
18893
18894 2005-08-18  Bruno Haible  <bruno@clisp.org>
18895
18896         * lib/strstr.c (strstr): Fix return value in multibyte case.
18897         * lib/strcasestr.c (strcasestr): Likewise.
18898
18899 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
18900
18901         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
18902
18903 2005-08-17  Jim Meyering  <jim@meyering.net>
18904
18905         Make the %s format (seconds since the epoch) work for a negative
18906         number and when used with a zero-padded field width, e.g. %015s.
18907
18908         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
18909         label so that it precedes the code to set `digits'.  Otherwise,
18910         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
18911         print `00-22'.  Now, it prints `-0022', as it should.
18912
18913 2005-08-17  Bruno Haible  <bruno@clisp.org>
18914
18915         * modules/strstr (Files): Add m4/mbrtowc.m4.
18916         (Depends-on): Add mbuiter.
18917
18918 2005-08-17  Bruno Haible  <bruno@clisp.org>
18919
18920         * modules/strcasestr: New file.
18921         * MODULES.html.sh (String handling, based on ANSI C 89): Add
18922         strcasestr.
18923
18924 2005-08-17  Bruno Haible  <bruno@clisp.org>
18925
18926         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
18927
18928 2005-08-17  Bruno Haible  <bruno@clisp.org>
18929
18930         * modules/mbuiter: New file.
18931         * MODULES.html.sh (Extended multibyte and wide character utilities):
18932         Add mbuiter.
18933
18934 2005-08-17  Bruno Haible  <bruno@clisp.org>
18935
18936         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
18937         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
18938
18939 2005-08-17  Bruno Haible  <bruno@clisp.org>
18940
18941         * m4/strcasestr.m4: New file.
18942
18943 2005-08-17  Bruno Haible  <bruno@clisp.org>
18944
18945         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
18946         * lib/strstr.c: Completely rewritten, with multibyte locale support.
18947
18948 2005-08-17  Bruno Haible  <bruno@clisp.org>
18949
18950         * lib/strcasestr.h: New file.
18951         * lib/strcasestr.c: New file.
18952
18953 2005-08-17  Bruno Haible  <bruno@clisp.org>
18954
18955         * lib/strcasecmp.c: Use mbuiter.h.
18956
18957 2005-08-17  Bruno Haible  <bruno@clisp.org>
18958
18959         * lib/mbuiter.h: New file.
18960
18961 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
18962
18963         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
18964         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
18965         and gl_GETOPT are both invoked via different paths (as happens
18966         with GNU tar CVS because it uses both argp and getopt), the former
18967         wins.
18968
18969 2005-08-16  Bruno Haible  <bruno@clisp.org>
18970
18971         * modules/tls: New file.
18972         * MODULES.html.sh (Multithreading): Add tls.
18973
18974 2005-08-16  Bruno Haible  <bruno@clisp.org>
18975
18976         * modules/strnlen1: New file.
18977         * MODULES.html.sh (String handling): Add strnlen1.
18978
18979 2005-08-16  Bruno Haible  <bruno@clisp.org>
18980
18981         * modules/strcase (Files): Add m4/mbrtowc.m4.
18982         (Depends-on): Add strnlen1, mbchar.
18983
18984 2005-08-16  Bruno Haible  <bruno@clisp.org>
18985
18986         * modules/mbiter: New file.
18987         * MODULES.html.sh (Extended multibyte and wide character utilities):
18988         Add mbiter.
18989
18990 2005-08-16  Bruno Haible  <bruno@clisp.org>
18991
18992         * modules/mbfile: New file.
18993         * MODULES.html.sh (Extended multibyte and wide character utilities):
18994         Add mbfile.
18995
18996 2005-08-16  Bruno Haible  <bruno@clisp.org>
18997
18998         * modules/mbchar: New file.
18999         * MODULES.html.sh (Extended multibyte and wide character utilities):
19000         New section.
19001
19002 2005-08-16  Bruno Haible  <bruno@clisp.org>
19003
19004         * m4/tls.m4: New file, from GNU gettext.
19005
19006 2005-08-16  Bruno Haible  <bruno@clisp.org>
19007
19008         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
19009         always.
19010         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
19011
19012 2005-08-16  Bruno Haible  <bruno@clisp.org>
19013
19014         * m4/mbiter.m4: New file.
19015
19016 2005-08-16  Bruno Haible  <bruno@clisp.org>
19017
19018         * m4/mbfile.m4: New file.
19019
19020 2005-08-16  Bruno Haible  <bruno@clisp.org>
19021
19022         * m4/mbchar.m4: New file.
19023
19024 2005-08-16  Bruno Haible  <bruno@clisp.org>
19025
19026         * lib/tls.h: New file, from GNU gettext.
19027         * lib/tls.c: New file, from GNU gettext.
19028
19029 2005-08-16  Bruno Haible  <bruno@clisp.org>
19030
19031         * lib/strnlen1.h: New file.
19032         * lib/strnlen1.c: New file.
19033
19034 2005-08-16  Bruno Haible  <bruno@clisp.org>
19035
19036         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
19037         (mbi_init): Update.
19038         (mbi_avail, mbi_advance): Let the iteration end before the terminating
19039         NUL byte, not after it.
19040
19041 2005-08-16  Bruno Haible  <bruno@clisp.org>
19042
19043         * lib/strcase.h (strcasecmp): Add note in comments.
19044         * lib/strncasecmp.c: Use code from strcasecmp.c.
19045         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
19046         (strcasecmp): Work correctly in multibyte locales.
19047
19048 2005-08-16  Bruno Haible  <bruno@clisp.org>
19049
19050         * lib/mbiter.h: New file.
19051
19052 2005-08-16  Bruno Haible  <bruno@clisp.org>
19053
19054         * lib/mbfile.h: New file.
19055
19056 2005-08-16  Bruno Haible  <bruno@clisp.org>
19057
19058         * lib/mbchar.h: New file.
19059         * lib/mbchar.c: New file.
19060
19061 2005-08-16  Bruno Haible  <bruno@clisp.org>
19062
19063         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
19064         the valid ones. Makes the comparison operations transitive:
19065         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
19066         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
19067
19068 2005-08-15  Simon Josefsson  <jas@extundo.com>
19069
19070         * modules/ssize_t (License): Change to 'unlimited'.
19071
19072         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
19073
19074 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
19075
19076         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
19077         Add comments for each pending glibc patch.
19078
19079 2005-08-15  Bruno Haible  <bruno@clisp.org>
19080
19081         * lib/regex.h (__restrict_arr): Don't define to __restrict if
19082         __cplusplus is defined.
19083
19084 2005-08-14  Jim Meyering  <jim@meyering.net>
19085
19086         Sync from coreutils.
19087
19088         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
19089         Use the hash-table-based cycle-detection code not just when
19090         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
19091         Reported by James Youngman in
19092         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
19093         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
19094         FTS_TIGHT_CYCLE_CHECK.
19095         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
19096         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
19097         once again.
19098         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
19099         * lib/fts.c (fd_safer): Remove decl.
19100         Include fcntl--.h rather than unistd-safer.h
19101         (fts_safe_changedir): Don't call fd_safer; no longer needed
19102         now that we include fcntl--.h.
19103
19104 2005-08-12  Simon Josefsson  <jas@extundo.com>
19105
19106         * modules/getndelim2: Use ssize_t module.
19107         * modules/getnline: Likewise.
19108         * modules/safe-read: Likewise.
19109         * modules/xreadlink: Likewise.
19110
19111         * modules/ssize_t: New file.
19112
19113 2005-08-12  Simon Josefsson  <jas@extundo.com>
19114
19115         * m4/readline.m4: Look for termcap, curses or ncurses if required.
19116
19117 2005-08-12  Simon Josefsson  <jas@extundo.com>
19118
19119         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
19120         ssize_t.
19121
19122 2005-08-12  Simon Josefsson  <jas@extundo.com>
19123
19124         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
19125         readline, getdelim and check_version.
19126         (Support for systems lacking ISO C 99: Sizes of integer types):
19127         Add size_max.
19128
19129 2005-08-12  Bruno Haible  <bruno@clisp.org>
19130
19131         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
19132
19133 2005-08-11  Simon Josefsson  <jas@extundo.com>
19134
19135         * modules/readline: New file.
19136
19137         * modules/strnlen (Files): Add strnlen.h.
19138
19139 2005-08-11  Simon Josefsson  <jas@extundo.com>
19140
19141         * m4/readline.m4: New file.
19142
19143 2005-08-11  Simon Josefsson  <jas@extundo.com>
19144
19145         * lib/readline.h, readline.c: New file.
19146
19147 2005-08-11  Simon Josefsson  <jas@extundo.com>
19148
19149         * doc/gnulib.texi (Initial import, Finishing touches): Mention
19150         gl_AVOID.
19151
19152 2005-08-11  Bruno Haible  <bruno@clisp.org>
19153
19154         * lib/strnlen.h (strnlen): Change parameter name to match comment.
19155
19156 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
19157
19158         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
19159
19160 2005-08-10  Simon Josefsson  <jas@extundo.com>
19161
19162         * tests/test-iconvme.c: New file.
19163
19164 2005-08-10  Simon Josefsson  <jas@extundo.com>
19165
19166         * m4/strnlen.m4: New file.
19167
19168         * m4/strndup.m4: Don't check for strnlen declaration, done in
19169         strnlen.m4.
19170
19171 2005-08-10  Simon Josefsson  <jas@extundo.com>
19172
19173         * lib/strndup.c: Use strnlen.h.
19174
19175         * lib/strnlen.h: New file.
19176
19177 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
19178
19179         * README: Typos.
19180
19181 2005-08-02  Simon Josefsson  <jas@extundo.com>
19182
19183         * modules/readline: New file.
19184
19185 2005-08-02  Simon Josefsson  <jas@extundo.com>
19186
19187         * modules/getdelim: New file.
19188
19189         * modules/getline: Rewrite, don't use getndelim2.
19190
19191 2005-08-02  Simon Josefsson  <jas@extundo.com>
19192
19193         * m4/getline.m4: Separate out getdelim stuff into separate module.
19194
19195         * m4/getdelim.m4: New file.
19196
19197 2005-08-02  Simon Josefsson  <jas@extundo.com>
19198
19199         * lib/getline.h, getline.c: Rewrite.
19200
19201         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
19202
19203 2005-07-31  Bruno Haible  <bruno@clisp.org>
19204
19205         * lib/lock.h (gl_lock_initializer): New macro.
19206         (gl_lock_define_initialized): Use it.
19207         (gl_rwlock_initializer): New macro.
19208         (gl_rwlock_define_initialized): Use it.
19209         (gl_recursive_lock_initializer): New macro.
19210         (gl_recursive_lock_define_initialized): Use it.
19211
19212 2005-07-30  Karl Berry  <karl@gnu.org>
19213
19214         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
19215         Report from Ben Pfaff, regarding getopt.
19216
19217 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
19218
19219         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
19220         normal way.
19221         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
19222         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
19223         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
19224         (gl_GETOPT): Use the new macros.  Most of the implementation
19225         is moved to the new macros.  This is for programs like Emacs
19226         that don't want all the functionality of gl_GETOPT.
19227
19228 2005-07-26  Bruno Haible  <bruno@clisp.org>
19229
19230         * m4/lock.m4: Update from GNU gettext.
19231
19232 2005-07-26  Bruno Haible  <bruno@clisp.org>
19233
19234         * lib/lock.h: Update from GNU gettext.
19235         * lib/lock.c: Update from GNU gettext.
19236
19237 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
19238
19239         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
19240         obsolescent AC_TRY_RUN.  Include the default includes files, for
19241         'exit'.
19242
19243 2005-07-24  Bruno Haible  <bruno@clisp.org>
19244
19245         * modules/visibility: New file.
19246         * MODULES.html.sh (Misc): Add visibility.
19247
19248 2005-07-24  Bruno Haible  <bruno@clisp.org>
19249
19250         * m4/visibility.m4: New file.
19251
19252 2005-07-24  Bruno Haible  <bruno@clisp.org>
19253
19254         * doc/visibility.texi: New file.
19255
19256 2005-07-22  Bruno Haible  <bruno@clisp.org>
19257
19258         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
19259         $(ALLOCA_H), redundant through BUILT_SOURCES.
19260         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
19261         redundant through BUILT_SOURCES.
19262         * modules/byteswap (Makefile.am): Remove explicit dependency on
19263         $(BYTESWAP_H), redundant through BUILT_SOURCES.
19264         * modules/fnmatch (Makefile.am): Remove explicit dependency on
19265         $(FNMATCH_H), redundant through BUILT_SOURCES.
19266         * modules/getopt (Makefile.am): Remove explicit dependency on
19267         $(GETOPT_H), redundant through BUILT_SOURCES.
19268         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
19269         redundant through BUILT_SOURCES.
19270         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
19271         redundant through BUILT_SOURCES.
19272         * modules/stdbool (Makefile.am): Remove explicit dependency on
19273         $(STDBOOL_H), redundant through BUILT_SOURCES.
19274         * modules/stdint (Makefile.am): Remove explicit dependency on
19275         $(STDINT_H), redundant through BUILT_SOURCES.
19276         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
19277         Remove explicit dependency on $(SYSEXITS_H).
19278         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
19279
19280 2005-07-18  Simon Josefsson  <jas@extundo.com>
19281
19282         * lib/check-version.c (check_version): Accept identical versions too.
19283
19284 2005-07-18  Bruno Haible  <bruno@clisp.org>
19285
19286         * modules/lock: New file.
19287         * MODULES.html.sh (Multithreading): New section.
19288
19289 2005-07-18  Bruno Haible  <bruno@clisp.org>
19290
19291         * m4/lock.m4: New file, from GNU gettext.
19292
19293 2005-07-18  Bruno Haible  <bruno@clisp.org>
19294
19295         * lib/lock.h: New file, from GNU gettext.
19296         * lib/lock.c: New file, from GNU gettext.
19297
19298 2005-07-18  Bruno Haible  <bruno@clisp.org>
19299
19300         * lib/lock.h (gl_once_t): New type.
19301         (gl_once_define, gl_once): New macros.
19302         * lib/lock.c (fresh_once): New variable.
19303         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
19304         functions.
19305
19306 2005-07-16  Simon Josefsson  <jas@extundo.com>
19307
19308         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
19309         workaround, suggested by Bruno.
19310
19311 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
19312
19313         * modules/xalloc (Depends-on): Add xalloc-die.
19314         * modules/xvasprintf (Depends-on): Add xalloc-die.
19315
19316 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
19317
19318         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
19319         with a minor change.
19320
19321 2005-07-15  Bruno Haible  <bruno@clisp.org>
19322
19323         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
19324         When using lib/poll.c, define poll as rpl_poll.
19325
19326 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
19327
19328         * modules/argp (Depends-on): Remove unlocked-io.
19329
19330 2005-07-14  Derek Price  <derek@ximbiot.com>
19331
19332         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
19333         for glob symlink bug.
19334
19335 2005-07-14  Bruno Haible  <bruno@clisp.org>
19336
19337         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
19338         Instead, test for *_unlocked function declarations directly.
19339
19340 2005-07-11  Simon Josefsson  <jas@extundo.com>
19341
19342         * modules/size_max: New file.
19343
19344         * modules/xsize: Depend on size_max module for size_max.m4.
19345
19346 2005-07-11  Simon Josefsson  <jas@extundo.com>
19347
19348         * lib/size_max.h: New file.
19349
19350 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
19351
19352         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
19353         copyright symbol and the year.
19354         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
19355         (version_etc_va): Use parameterized copyright notice.
19356         Reword to conform to the current GNU coding standards.
19357
19358 2005-07-11  Karl Berry  <karl@gnu.org>
19359
19360         * doc/gnulib.texi (Quoting): new node.
19361         (Initial import): more info, from Patrice.
19362
19363 2005-07-11  Bruno Haible  <bruno@clisp.org>
19364
19365         * gnulib-tool (func_usage): Document option --avoid.
19366         (Command line options): Handle --avoid.
19367         (func_acceptable): New function.
19368         (func_modules_transitive_closure): Use it.
19369
19370 2005-07-11  Bruno Haible  <bruno@clisp.org>
19371
19372         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
19373         Reported by Jim Meyering.
19374
19375 2005-07-10  Bruno Haible  <bruno@clisp.org>
19376
19377         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
19378         Needed when size_t is smaller than 'unsigned int'.
19379         Reported by Paul Eggert.
19380
19381 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
19382
19383         * modules/argp (Depends-on): Add unlocked-io
19384
19385 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
19386
19387         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
19388         block of defines.
19389
19390 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
19391
19392         * config/srclist.txt: Comment out regcomp.c, since we have a porting
19393         fix now.
19394
19395 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
19396         and Paul Eggert  <eggert@cs.ucla.edu>
19397
19398         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
19399         in wint_t, not wchar_t.  Remove now-unnecessary cast.
19400
19401 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19402
19403         * modules/regex (Files): Add lib/regex_internal.c,
19404         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
19405         (Depends-on): Add extensions.
19406         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
19407
19408 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19409
19410         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
19411         pathconf.
19412         * m4/same.m4 (gl_SAME): Likewise.
19413         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
19414
19415         * m4/regex.m4: Adjust to new libc regex implementation.
19416         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
19417         all the .c and .h parts of (the new) regex.
19418         Quote the m4 stuff better.
19419         Check for RE_ICASE bug of old gnulib.
19420         Check for REG_STARTEND of recent libc.
19421         Rename local variables from jm_* to gl_*.
19422         Quote operand of "test -f".
19423         Say "recent enough" version of libc, not "version 2".
19424         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
19425         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
19426         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
19427         Remove check for btowc, isascii.
19428         Require AM_LANGINFO_CODESET.
19429
19430 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19431
19432         * lib/regex.c, regex.h: Sync from libc.
19433         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
19434         * lib/regexec.c:
19435         New files, synced from libc, except that regex_internal.h
19436         currently has a small porting fix.
19437
19438 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19439
19440         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
19441         regex_internal.c, regexec.c.
19442         Add regex_internal.h too, but as a comment, since the libc version
19443         is currently broken in gnulib mode.
19444
19445 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
19446
19447         Support programs like Emacs that use gnulib but not gettext.
19448         * MODULES.html.sh (Internationalization functions): Add gettext-h.
19449         * modules/gettext-h: New file.
19450         * modules/gettext (Files): Remove lib/gettext.h.
19451         (Depends-on): Add gettext-h.
19452         (Makefile.am): Remove lib_SOURCES.
19453         * modules/argmatch, modules/c-stack, modules/closeout:
19454         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
19455         * modules/execute, modules/file-type, modules/getaddrinfo:
19456         * modules/getopt, modules/human, modules/javacomp:
19457         * modules/javaexec, modules/mkdir-p, modules/obstack:
19458         * modules/openat, modules/pagealign_alloc, modules/pipe:
19459         * modules/quotearg, modules/regex, modules/rpmatch:
19460         * modules/unicodeio, modules/userspec, modules/version-etc:
19461         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
19462         * modules/xsetenv:
19463         Depend on gettext-h, not gettext.
19464
19465 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
19466
19467         * gnulib-tool (func_import): Add support for 'public domain' license.
19468         * modules/alloca, modules/atexit, modules/memmove:
19469         Now public domain, not GPL.
19470         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
19471         * modules/realloc, modules/strerror, modules/strtod:
19472         Now LGPL, not GPL.
19473
19474 2005-07-05  Bruno Haible  <bruno@clisp.org>
19475
19476         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
19477         autoconf CVS. Needed for mingw.
19478
19479 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
19480
19481         Remove the dependency of the strftime module on the tzset module.
19482         * modules/strftime (Depends-on): Remove dependency on tzset.
19483
19484 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
19485
19486         Remove the dependency of the strftime module on the tzset module.
19487         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
19488         gl_FUNC_TZSET_CLOBBER.
19489
19490 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
19491
19492         Remove the dependency of the strftime module on the tzset module.
19493         * lib/strftime.c (my_strftime)
19494         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
19495         Copy the input structure, to work around some of the bug with
19496         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
19497         Solaris releases, you should also use the tzset module, but we won't
19498         require it as a dependency any more since we don't want LGPLed code
19499         to depend on GPLed code.
19500
19501 2005-07-02  Jim Meyering  <jim@meyering.net>
19502
19503         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
19504         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
19505         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
19506         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
19507
19508 2005-07-02  Jim Meyering  <jim@meyering.net>
19509
19510         * lib/backupfile.c (backup_args): Change a `0' to NULL.
19511
19512 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
19513
19514         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
19515         declares only 'struct timespec;' (!).
19516
19517 2005-07-01  Jim Meyering  <jim@meyering.net>
19518
19519         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
19520         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
19521         * lib/save-cwd.c, tempname.c:
19522         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
19523         and don't include <sys/file.h>).
19524
19525 2005-06-29  Jim Meyering  <jim@meyering.net>
19526
19527         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
19528         type name.  Use the variable name instead.
19529         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
19530         Likewise.
19531
19532 2005-06-28  Simon Josefsson  <jas@extundo.com>
19533
19534         * modules/check-version (Files): Add check-version.m4.
19535
19536 2005-06-28  Simon Josefsson  <jas@extundo.com>
19537
19538         * m4/check-version.m4: New file, suggested by Jim Meyering
19539         <jim@meyering.net>.
19540
19541 2005-06-28  Simon Josefsson  <jas@extundo.com>
19542
19543         * lib/check-version.h, lib/check-version.c: New files.
19544
19545 2005-06-28  Simon Josefsson  <jas@extundo.com>
19546
19547         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
19548         collision with global variable.  Better indentation.  Don't
19549         increment buffer pointer beyond buffer end.  Based on comments
19550         from Paul Eggert <eggert@cs.ucla.edu>.
19551
19552         * lib/base64.h: Indent.
19553
19554 2005-06-28  Simon Josefsson  <jas@extundo.com>
19555
19556         * doc/gnulib.texi (Library version handling): New section.
19557
19558 2005-06-28  Jim Meyering  <jim@meyering.net>
19559
19560         * check-module (find_included_lib_files): Hard-code another
19561         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
19562         but modules/fts-lgpl (correctly) does not list those files.
19563
19564         * modules/canonicalize (Files): Add lib/pathmax.h.
19565
19566 2005-06-25  Simon Josefsson  <jas@extundo.com>
19567
19568         * modules/check-version: New file.
19569
19570 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
19571
19572         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
19573         initializer of struct addrinfo, as an indication that we don't
19574         care how many members the structure has.
19575
19576 2005-06-24  Derek Price  <derek@ximbiot.com>
19577         and Bruno Haible  <bruno@clisp.org>
19578
19579         Remove stat module & update lstat.
19580         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
19581         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
19582         * m4/stat.m4: Remove this file.
19583
19584 2005-06-24  Derek Price  <derek@ximbiot.com>
19585         and Bruno Haible  <bruno@clisp.org>
19586
19587         Remove stat module & update lstat.
19588         * lib/stat.c: Remove this file...
19589         (slash_aware_lstat): ...moving this content and its support...
19590         * lib/lstat.c (rpl_lstat): ...into here.
19591         * lib/lstat.h: New file.
19592
19593 2005-06-24  Derek Price  <derek@ximbiot.com>
19594         and Bruno Haible  <bruno@clisp.org>
19595
19596         Remove stat module & update lstat.
19597         * config/srclist.txt (libc sources): Remove stat.
19598
19599 2005-06-24  Derek Price  <derek@ximbiot.com>
19600         and Bruno Haible  <bruno@clisp.org>
19601
19602         Remove stat module & update lstat.
19603         * MODULES.html.sh (stat): Remove.
19604         * MODULES.html: Regenerated.
19605         * modules/lstat (Description): Correct function name.
19606         (Files): Add "lstat.h".
19607         (Depends-on): Remove stat, add xalloc, stat-macros.
19608         * modules/stat: Remove this file.
19609         (Include): Add "lstat.h", remove <sys/stat.h>.
19610
19611 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
19612
19613         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
19614         (ranged_convert): Don't save conversion in a temporary struct.
19615         This causes a warning with GCC 4.0.0, and anyway in the typical
19616         case it's not worth the extra 100 bytes or so of code.
19617         (ranged_convert, __mktime_internal): When calling a function via a
19618         pointer P, use P () rather than (*P) (), as we now assume C89 or
19619         better.
19620
19621 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19622
19623         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
19624         "who -r" failed to give output.  Problem reported by Tim Waugh.
19625
19626         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
19627         (xcalloc): Use it to avoid needless tests.
19628         Problem reported by Jim Meyering.
19629
19630 2005-06-20  Derek Price  <derek@ximbiot.com>
19631
19632         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
19633         unnecessary for Autoconfs > 2.59c.
19634
19635 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19636
19637         * lib/argp.h (__option_is_short): Check upper limit of
19638         __key. Isprint() requires its argument to have the value
19639         of an unsigned char or EOF.
19640
19641 2005-06-16  Jim Meyering  <jim@meyering.net>
19642
19643         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
19644         when either N or S is zero.
19645
19646 2005-06-16  Derek Price  <derek@ximbiot.com>
19647
19648         * m4/bison.m4: Declare YACC & YFLAGS precious.
19649
19650 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
19651
19652         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
19653         multibyte string or pattern, fall back on unibyte matching.
19654         Problem reported by James Youngman.
19655
19656 2005-06-08  Bruno Haible  <bruno@clisp.org>
19657
19658         * modules/csharpcomp: New file.
19659         * MODULES.html.sh (C#): Add csharpcomp.
19660
19661 2005-06-08  Bruno Haible  <bruno@clisp.org>
19662
19663         * m4/csharpcomp.m4: New file, from GNU gettext.
19664
19665 2005-06-08  Bruno Haible  <bruno@clisp.org>
19666
19667         * lib/csharpcomp.h: New file, from GNU gettext.
19668         * lib/csharpcomp.c: New file, from GNU gettext.
19669         * lib/csharpcomp.sh.in: New file, from GNU gettext.
19670
19671 2005-06-08  Bruno Haible  <bruno@clisp.org>
19672
19673         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
19674         warning on mingw.
19675
19676 2005-06-07  Derek Price  <derek@ximbiot.com>
19677
19678         Sync from CVS.
19679         * lib/glob_.h: Indent nested #ifdef.
19680
19681 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19682
19683         Sync from coreutils.
19684         Use "file name" when talking about file names, instead of "filename"
19685         or "path", as per the GNU coding standards.
19686         * lib/mkdir-p.c: Renamed from makepath.c.
19687         (make_dir_parents): Renamed from make_path.  All callers changed.
19688         * lib/mkdir-p.h: Likewise.  All includers changed.
19689         * lib/filenamecat.c: Renamed from path-concat.c.
19690         (file_name_concat): Renamed from path_concat.  All callers changed.
19691         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
19692         * lib/filenamecat.h: Likewise.  All includers changed.
19693         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
19694         in comments or local variable names.
19695         * lib/basename.c: Likewise.
19696         * lib/canonicalize.c, canonicalize.h: Likewise.
19697         * lib/dirname.c, dirname.h: Likewise.
19698         * lib/euidaccess.c: Likewise.
19699         * lib/exclude.c: Likewise
19700         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
19701         * lib/fsusage.c, fsuage.h: Likewise.
19702         * lib/fts.c, fts_.h: Likewise.
19703         * lib/getcwd.c: Likewise.
19704         * lib/getloadavg.c: Likewise.
19705         * lib/mkstemp.c: Likewise.
19706         * lib/mountlist.c, mountlist.h: Likewise.
19707         * lib/openat.c, openat.h: Likewise.
19708         * lib/readlink-stub.c: Likewise.
19709         * lib/readutmp.c, readutmp.h: Likewise.
19710         * lib/rename.c: Likewise.
19711         * lib/rmdir.c: Likewise.
19712         * lib/same.c: Likewise.
19713         * lib/savedir.c: Likewise.
19714         * lib/stripslash.c: Likewise.
19715         * lib/tempname.c: Likewise.
19716         * lib/xreadlink.c: Likewise.
19717         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
19718         All uses changed.
19719         * lib/exclude.h: Likewise.
19720
19721         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
19722         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19723         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
19724         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19725         * lib/pathmax.h: Include <limits.h> unconditionally, since other
19726         files have been getting away with it for years (MORE/BSD 4.3
19727         is extinct now).
19728         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
19729         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19730
19731         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
19732         Define to 256, not 255, as per modern POSIX.
19733
19734 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19735
19736         Sync from coreutils.
19737         Use "file name" when talking about file names, instead of "filename"
19738         or "path", as per the GNU coding standards.
19739         * MODULES.html.sh: mkdir-p renamed from makepath.
19740         filenamecat renamed from path-concat.
19741         * modules/filenamecat: Renamed from modules/path-concat.
19742         (Files): filenamecat.h and filenamecat.c renamed from
19743         path-concat.h and path-concat.c.
19744         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
19745         (Include): filenamecat.h, not path-concat.h.
19746         * modules/mkdir-p: Renamed from modules/makepath.
19747         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
19748         makepath.c.
19749         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
19750         (Include): mkdir-p.h, not makepath.h.
19751
19752 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19753
19754         Sync from coreutils.
19755         * m4/mkdir-p.m4: Renamed from makepath.m4.
19756         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
19757         Rename files from makepath.c to mkdir-p.c, and from
19758         makepath.h to mkdir-p.h.
19759         * m4/filenamecat.m4: Renamed from path-concat.m4.
19760         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
19761         Rename files from path-concat.c to filenamecat.c,
19762         and from path-concat.h to filenamecat.h.
19763         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
19764         "file name" in local variables or comments.
19765         * m4/rename.m4: Likewise.
19766
19767 2005-06-01  Bruno Haible  <bruno@clisp.org>
19768
19769         * modules/csharpexec: New file.
19770         * MODULES.html.sh (C#): New section.
19771
19772 2005-06-01  Bruno Haible  <bruno@clisp.org>
19773
19774         * m4/csharp.m4: New file, from GNU gettext.
19775         * m4/csharpexec.m4: New file, from GNU gettext.
19776
19777 2005-06-01  Bruno Haible  <bruno@clisp.org>
19778
19779         * lib/csharpexec.h: New file, from GNU gettext.
19780         * lib/csharpexec.c: New file, from GNU gettext.
19781         * lib/csharpexec.sh.in: New file, from GNU gettext.
19782
19783 2005-05-31  Derek Price  <derek@ximbiot.com>
19784             Paul Eggert  <eggert@cs.ucla.edu>
19785
19786         Sync from cvs.
19787         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
19788
19789 2005-05-31  Derek Price  <derek@ximbiot.com>
19790             Paul Eggert  <eggert@cs.ucla.edu>
19791
19792         Sync from cvs.
19793         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
19794
19795 2005-05-29  Derek Price  <derek@ximbiot.com>
19796
19797         * config/srclist.txt (glob_.h, glob.c): Add these files.
19798
19799 2005-05-29  Derek Price  <derek@ximbiot.com>
19800
19801         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
19802         * modules/glob: New file.
19803         * modules/getlogin_r: Add link to POSIX spec in description.
19804
19805 2005-05-29  Derek Price  <derek@ximbiot.com>
19806             Paul Eggert  <eggert@cs.ucla.edu>
19807
19808         * m4/glob.m4: New file.
19809
19810 2005-05-29  Derek Price  <derek@ximbiot.com>
19811             Paul Eggert  <eggert@cs.ucla.edu>
19812
19813         * lib/glob_.h, lib/glob.c: New files.
19814
19815 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19816
19817         * modules/fts (Files): Remove m4/inttypes-pri.m4.
19818         * modules/fts-lgpl (Depends-on): Remove gettext.
19819
19820 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19821
19822         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
19823         and don't require gt_INTTYPES_PRI.
19824
19825 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19826
19827         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
19828
19829         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
19830         the configuration hassle isn't worth it.
19831         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
19832         (LONGEST_MODIFIER, PRIuMAX): Remove.
19833
19834 2005-05-27  Bruno Haible  <bruno@clisp.org>
19835
19836         * lib/getlogin_r.h: Remove second include of <stddef.h>.
19837
19838 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
19839
19840         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
19841         _POSIX_PTHREAD_SEMANTICS for Solaris.
19842
19843 2005-05-25  Derek Price  <derek@ximbiot.com>
19844
19845         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
19846
19847 2005-05-25  Derek Price  <derek@ximbiot.com>
19848             Paul Eggert  <eggert@cs.ucla.edu>
19849
19850         * modules/getlogin_r, m4/getlogin_r.m4: New files.
19851         * lib/getlogin_r.c, getlogin_r.h: New files.
19852
19853 2005-05-25  Bruno Haible  <bruno@clisp.org>
19854             Derek Price  <derek@ximbiot.com>
19855
19856         * lib/getlogin_r.h: Simplify API documentation.
19857
19858 2005-05-23  Derek Price  <derek@ximbiot.com>
19859
19860         * modules/minmax (Files): Add m4/minmax.m4.
19861         (configure.ac): Add gl_MINMAX.
19862
19863 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
19864
19865         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
19866         so that unistd-safer.h (GPL'ed code) need not be included.
19867
19868 2005-05-22  Bruno Haible  <bruno@clisp.org>
19869
19870         * m4/minmax.m4: New file.
19871         Based on a patch by Derek Price <derek@ximbiot.com>.
19872
19873 2005-05-22  Bruno Haible  <bruno@clisp.org>
19874
19875         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
19876         (INT64_MIN): Fix definition.
19877         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
19878
19879         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
19880         NEED_SIGNED_INT_TYPES.
19881
19882         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
19883         HAVE_SYSTEM_INTTYPES.
19884
19885 2005-05-22  Bruno Haible  <bruno@clisp.org>
19886
19887         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
19888         Also include <sys/param.h> if it defines MIN, MAX.
19889         Based on a patch by Derek Price <derek@ximbiot.com>.
19890
19891 2005-05-21  Jim Meyering  <jim@meyering.net>
19892
19893         * modules/fts (Files): Add m4/inttypes-pri.m4.
19894         (Depends-on): Add lstat and remove gettext.  Alphabetize.
19895
19896 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19897
19898         New fts module.
19899         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
19900         (setup_dir, free_dir): New functions.
19901         (enter_dir, leave_dir): Define trivial
19902         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
19903         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
19904         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
19905         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
19906         Move to fts-cycle.c.
19907         (fts_open): Use setup_dir.
19908         (fts_close): Use free_dir.
19909         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
19910         This adds a label and some gotos, but the alternatives were messier.
19911         Check for memory allocation failure when entering a dir.
19912         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
19913         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
19914         (FTS): New member fts_cycle, that is a union that contains the
19915         old active_dir_ht and cycle_state.  All uses changed to mention
19916         fts_cycle.ht and fts_cycle.state.
19917         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
19918         fts.c, with the following changes:
19919         (setup_dir, free_dir): New functions.
19920         (enter_dir): Now returns bool.  Return true if successful, false
19921         if memory exhausted.  All callers changed.
19922         Do not bother partly cleaning up on
19923         memory allocation failure; that is free_dir's job.
19924         However, free ad if hash_insert fails, to avoid memory leak.
19925         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
19926         fts->fts_options to see which union member to use.
19927
19928 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19929
19930         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
19931         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
19932
19933 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19934
19935         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
19936
19937 2005-05-20  Jim Meyering  <jim@meyering.net>
19938
19939         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
19940         Now a macro, to pacify GCC.
19941
19942 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
19943
19944         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
19945         of -1.
19946
19947 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
19948
19949         * lib/chown.c (rpl_chown): Return -1 on failure.
19950
19951 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
19952
19953         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
19954         Don't check for stddef.h.
19955         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
19956         don't use its results.
19957         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
19958         since we include them unconditionally.  Don't require
19959         AM_STDBOOL_H, since stdbool is a prerequisite.
19960         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
19961         since we assume C89 or better.
19962         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
19963         as we don't use their results.
19964         Don't check for fchdir, memmove, memset, strrchr, as we use
19965         them unconditionally.
19966         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
19967         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
19968
19969 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
19970
19971         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
19972         Include <stddef.h> unconditionally, since we assume C89 now.
19973         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
19974         * lib/fts.c: Include fts_.h first, to check interface.
19975         Do not include intprops.h; no longer needed.
19976         Include cycle-check.h and hash.h, since fts_.h no longer does.
19977         Remove unnecessary casts of closedir to void.
19978         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
19979         decide whether to decrement nlinks.
19980         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
19981         (FTS): Use struct hash_table * instead of Hash_table, so that
19982         we no longer need to include hash.h here.
19983
19984 2005-05-18  Jim Meyering  <jim@meyering.net>
19985
19986         * modules/dirfd (License): Change to LGPL.  Most of the code
19987         is already in the public domain.
19988
19989 2005-05-18  Jim Meyering  <jim@meyering.net>
19990
19991         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
19992         Reported by Yoann Vandoorselaere.
19993
19994 2005-05-17  Jim Meyering  <jim@meyering.net>
19995
19996         * m4/fts.m4: New file, from coreutils.
19997
19998 2005-05-17  Jim Meyering  <jim@meyering.net>
19999
20000         * lib/fts.c, lib/fts_.h: New files, from coreutils.
20001
20002 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
20003
20004         Sync from coreutils.
20005         * m4/unlinkdir.m4: New file.
20006
20007 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
20008
20009         Sync from coreutils.
20010         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
20011         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
20012         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
20013         White space changes only.
20014         * lib/makepath.c (make_path): Port to hosts where leading "//" is
20015         special.
20016         * lib/yesno.c: Include getline.h, not ctype.h.
20017         (yesno): Don't remove leading white space; POSIX doesn't allow it.
20018         Use getline to remove arbitrary restriction on response length.
20019
20020 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
20021
20022         * config/srclist-update: Spell out "Street" in FSF postal
20023         mail address; this is the style the FSF seems to prefer.
20024
20025         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
20026         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
20027         this updates FSF postal mail address.
20028
20029         Sync from coreutils.
20030         * modules/unlinkdir: New file.
20031         * modules/yesno (Depends-on): Add getline.
20032         * MODULES.html.sh (File system functions): Add unlinkdir.
20033
20034 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
20035
20036         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
20037         lib/strsep.h:
20038         Change the initial comment to refer to GPL, not LGPL.
20039         gnulib-tool will change it to LGPL as needed.
20040
20041         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
20042         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
20043         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
20044         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
20045         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
20046         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
20047         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
20048         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
20049         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
20050         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
20051         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
20052         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
20053         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
20054         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
20055         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
20056         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
20057         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
20058         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
20059         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
20060         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
20061         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
20062         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
20063         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
20064         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
20065         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
20066         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
20067         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
20068         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
20069         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
20070         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
20071         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
20072         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
20073         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
20074         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
20075         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
20076         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
20077         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
20078         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
20079         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
20080         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
20081         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
20082         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
20083         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
20084         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
20085         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
20086         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
20087         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
20088         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
20089         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
20090         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
20091         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
20092         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
20093         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
20094         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
20095         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
20096         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
20097         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
20098         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
20099         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
20100         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
20101         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
20102         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
20103         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
20104         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
20105         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
20106         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
20107         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
20108         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
20109         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
20110         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
20111         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
20112         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
20113         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
20114         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
20115         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
20116         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
20117         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
20118         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
20119         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
20120         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
20121         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
20122         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
20123         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
20124         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
20125         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
20126         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
20127         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
20128         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
20129         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
20130         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
20131         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
20132         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
20133         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
20134         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
20135         lib/yesno.c, lib/yesno.h:
20136         Update FSF postal mail address.
20137
20138 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
20139
20140         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
20141         tests/test-memmem.c, tests/test-stpncpy.c:
20142         Update FSF postal mail address.
20143
20144 2005-05-13  Bruno Haible  <bruno@clisp.org>
20145
20146         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
20147         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
20148         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
20149         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
20150         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
20151         Add support for 64-bit integers in the MSVC compiler.
20152
20153 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20154
20155         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
20156
20157 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
20158
20159         * gnulib-tool (func_import): Sort and uniquify recommended includes.
20160
20161 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
20162
20163         * doc/getdate.texi (General date syntax): Don't say that date
20164         date --iso-8601=ns generates acceptable dates; it doesn't yet.
20165         Problem reported by Nic Ferrier.
20166
20167 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
20168
20169         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
20170         specified in ai_socktype. Fix invalid ai_protocol
20171         check. ai_protocol is usually set to 0 or depending on
20172         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
20173         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
20174         ai_socktype / ai_protocol in the returned addrinfo structure.
20175
20176 2005-05-10  Simon Josefsson  <jas@extundo.com>
20177
20178         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
20179         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
20180
20181 2005-05-10  Karl Berry  <karl@gnu.org>
20182
20183         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
20184         (from http://www.gnu.org/licenses).
20185         * doc/COPYING.LIB: also rename to COPYING.LESSER.
20186         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
20187         fdl.texi suffices.
20188
20189 2005-05-10  Karl Berry  <karl@gnu.org>
20190
20191         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
20192         (COPYING.DOC): remove.
20193
20194         * config/srclist-update: new FSF address.
20195
20196 2005-05-10  Derek Price  <derek@ximbiot.com>
20197
20198         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
20199         possible.
20200
20201 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
20202             Bruno Haible  <bruno@clisp.org>
20203
20204         * modules/inet_ntop: New file.
20205         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
20206         inet_ntop.
20207
20208 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
20209             Bruno Haible  <bruno@clisp.org>
20210
20211         * m4/inet_ntop.m4: New file.
20212
20213 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
20214             Bruno Haible  <bruno@clisp.org>
20215
20216         * lib/inet_ntop.h: New file.
20217         * lib/inet_ntop.c: New file, from glibc with modifications.
20218
20219 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
20220
20221         * modules/time_r (License): Change to LGPL.
20222         * modules/extensions (License): Change to LGPL.  Actually,
20223         the license is more permissive than that, but currently gnulib-tool
20224         doesn't know how to handle more-permissive licenses.
20225
20226         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
20227         Problem reported by Dave Love.
20228
20229 2005-05-08  Jim Meyering  <jim@meyering.net>
20230
20231         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
20232         blank.
20233
20234 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
20235
20236         * modules/argmatch (Depends-on): Add stdbool.
20237         * modules/backupfile (Depends-on): Likewise.
20238         * modules/chdir-long (Depends-on): Likewise.
20239         * modules/closeout (Depends-on): Likewise.
20240         * modules/cycle-check (Depends-on): Likewise.
20241         * modules/dirname (Depends-on): Likewise.
20242         * modules/fnmatch (Depends-on): Likewise.
20243         * modules/fsusage (Depends-on): Likewise.
20244         * modules/fwriteerror (Depends-on): Likewise.
20245         * modules/getcwd (Depends-on): Likewise.
20246         * modules/getloadavg (Depends-on): Likewise.
20247         * modules/hard-locale (Depends-on): Likewise.
20248         * modules/makepath (Depends-on): Likewise.
20249         * modules/mountlist (Depends-on): Likewise.
20250         * modules/nanosleep (Depends-on): Likewise.
20251         * modules/posixtm (Depends-on): Likewise.
20252         * modules/quotearg (Depends-on): Likewise.
20253         * modules/readtokens (Depends-on): Likewise.
20254         * modules/readtokens0 (Depends-on): Likewise.
20255         * modules/readutmp (Depends-on): Likewise.
20256         * modules/save-cwd (Depends-on): Likewise.
20257         * modules/strftime (Depends-on): Likewise.
20258         * modules/userspec (Depends-on): Likewise.
20259         * modules/utimecmp (Depends-on): Likewise.
20260         * modules/xgetcwd (Depends-on): Likewise.
20261         * modules/xnanosleep (Depends-on): Likewise.
20262         * modules/xstrtod (Depends-on): Likewise.
20263         * modules/yesno (Depends-on): Likewise.
20264
20265 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
20266
20267         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
20268         needless checks.
20269
20270 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20271
20272         Merge from coreutils.  Among other things,
20273         add bulletproofing for cases where stdin, stdout, or stderr are closed.
20274         * lib/fd-safer.c: New file.
20275         * lib/fcntl-safer.h, open-safer.c: Remove.
20276         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
20277         * lib/dup-safer.c: Include unistd-safer.h first.
20278         Don't include errno.h.
20279         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
20280         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
20281         * lib/file-type.c: Rely on file-type.h change.
20282         * lib/getloadavg.c: Include unistd-safer.h.
20283         (getloadavg): Use safer open.
20284         * lib/getusershell.c: Include "stdio-safer.h".
20285         (getusershell): Use safer fopen.
20286         * lib/long-options.c (long_options): Use NULL rather than 0.
20287         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
20288         'free'.
20289         * lib/modechange.c: Likewise.
20290         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
20291         (MODE_DONE): New constant.
20292         (struct mode_change): Remove 'next' member.
20293         (make_node_op_equals): New function; like the old one of the
20294         same name, except it allocates an array.
20295         (mode_compile, mode_create_from_ref): Use it.
20296         (mode_compile): Allocate result as an array, not a linked list.
20297         Parse octal string ourself, so that we catch mistakes like "+0".
20298         (mode_adjust): Arg is an array, not a linked list.
20299         * lib/modechange.c: Include stat-macros.h, xalloc.h.
20300         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
20301         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
20302         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
20303         Remove.  This is now stat-macros.h's job.
20304         (talloc): Remove.  All callers replaced by xalloc, so that
20305         our invokers don't have to worry about reporting memory failures.
20306         (make_node_op_equals): Remove.
20307         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
20308         New constants.
20309         (struct mode_change): Moved here from modechange.h.
20310         (mode_append_entry): Remove.
20311         (mode_compile): Remove MASKED_OPS arg, since it encouraged
20312         apps to have incorrect behavior.  Use simpler algorithm for head
20313         and tail.  Don't futz with umask; that's now the job of mode_adjust.
20314         Detect more invalid usages rather than having somewhat-random behavior.
20315         Don't insert an "a=" action, as that leads to incorrect behavior.
20316         (mode_compile, mode_create_from_ref): Return NULL on error instead
20317         of an enum, since now there's only one way to have an error.  All
20318         callers changed.
20319         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
20320         at the correct time.  Simplify calculation of "+u" and its ilk.
20321         Don't mishandle "+X".
20322         (mode_free): Remove "register" and localize decls.
20323         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
20324         (struct mode_change): Move to modechange.c; callers don't
20325         need to see this stuff.
20326         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
20327         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
20328         (mode_change, mode_adjust): Reflect the new signatures noted above.
20329         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
20330         that might redefine system include files.
20331         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
20332         (my_usleep): Use NULL rather than (void *) 0.
20333         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
20334         Use siginterrupt to specify that system calls should be interrupted.
20335         (rpl_nanosleep): Move initialization of suspended closer to call of
20336         my_usleep.
20337         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
20338         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
20339         (desirable_utmp_entry): New function.
20340         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
20341         using x2nrealloc, to simplify logic.
20342         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
20343         size calculation.  Do not assume utmp file is a regular file.
20344         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
20345         (READ_UTMP_CHECK_PIDS): New constant.
20346         * lib/save-cwd.c: Include unistd-safer.h.
20347         (save_cwd): Use fd_safer.
20348         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
20349         [!_LIBC] Include "stat-macros.h" instead.
20350         * lib/unistd-safer.h (fd_safer): New decl.
20351
20352 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20353
20354         * modules/getloadavg (Depends-on): Add unistd-safer.
20355         * modules/getusershell (Depends-on): Add stdio-safer.
20356         * modules/lstat (Depends-on): Remove xalloc.
20357         * modules/mkstemp (Depends-on): Add stat-macros.
20358         * modules/modechange (Depends-on): Remove xstrtol.
20359         Add stat-macros, xalloc.
20360         * modules/save-cwd (Depends-on): Add unistd-safer.
20361         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
20362         * modules/unistd-safer (Files): Add lib/fd-safer.c
20363         (Makefile.am): Remove lib_SOURCES.
20364
20365         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
20366         Remove fcntl-safer; unistd-safer supersedes it.
20367
20368 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20369
20370         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
20371         AC_HEADER_STAT.
20372         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
20373         (gl_PREREQ_CHOWN): Remove.
20374         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
20375         it.  Don't require AC_HEADER_STAT.
20376         (gl_PREREQ_LSTAT): Remove.
20377         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
20378         Don't require AC_HEADER_STAT.
20379         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
20380         (gl_PREREQ_RMDIR): Remove.
20381         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
20382         mention stat-macros.h or AC_HEADER_STAT, since we'll make
20383         the stat-macros module a prerequisite.
20384         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
20385         * m4/filemode.m4 (gl_FILEMODE): Likewise.
20386         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
20387         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
20388         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
20389         variable names.
20390         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
20391         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
20392         variable prefixes.
20393         * m4/fcntl-safer.m4: Remove.
20394         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
20395         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
20396         Invoke gl_PREREQ_FD_SAFER.
20397         (gl_PREREQ_FD_SAFER): New macro.
20398         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
20399         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
20400         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
20401         Remove duplicate call to AC_LIBOBJ(readutmp).
20402         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
20403
20404         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
20405         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
20406
20407 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20408
20409         * MODULES.html.sh (Misc): Add byteswap.
20410
20411 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20412
20413         * modules/getcwd (Depends-on): Add extensions.
20414         * modules/openat (Depends-on): Likewise.
20415
20416 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20417
20418         * modules/byteswap: New file.
20419
20420 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20421
20422         * m4/byteswap.m4: New file.
20423
20424 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20425
20426         * lib/byteswap_.h: New file.
20427
20428 2005-04-25  Karl Berry  <karl@gnu.org>
20429
20430         * m4/gettext.m4: Update from GNU gettext 0.14.4.
20431
20432 2005-04-25  Albert Chin  <china@thewrittenword.com>
20433
20434         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
20435         Toolkit C bug.
20436
20437 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
20438
20439         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
20440         (func_ln_if_changed) Remove forcibly for no error message
20441         in case file does not exist.
20442
20443 2005-04-19  Simon Josefsson  <jas@extundo.com>
20444
20445         * gnulib-tool (Options): Make --symlink mean --symbolic.
20446
20447 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
20448
20449         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
20450
20451 2005-04-16  Simon Josefsson  <jas@extundo.com>
20452
20453         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
20454
20455 2005-04-15  Simon Josefsson  <jas@extundo.com>
20456
20457         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
20458
20459 2005-04-15  Simon Josefsson  <jas@extundo.com>
20460
20461         * gnulib-tool: Rename --symlink to --symbolic.
20462
20463 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
20464
20465         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
20466         symbolic links to files instead of copying/moving.  Add --aux-dir,
20467         specifying directory relative --dir where auxiliary build tools
20468         are placed.
20469
20470 2005-04-14  Bruno Haible  <bruno@clisp.org>
20471
20472         * modules/allocsa (License): Change to LGPL.
20473         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
20474
20475 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
20476
20477         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
20478         that "UTC +1 second" continues to work.  Problem reported
20479         by Dmitry V. Levin.
20480         (relunit_snumber): New rule.
20481         (relunit): Use it.
20482
20483 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
20484
20485         * lib/getdate.y (universal_time_zone_table): New constant.
20486         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
20487         universal_time_zone_table.
20488         (lookup_zone): Prefer universal_time_zone_table to
20489         local_time_zone_table, so that "GMT" time stamps are allowed in
20490         London during the summer.  Problem reported by Ian Abbott.
20491
20492 2005-04-12  Jim Meyering  <jim@meyering.net>
20493
20494         * lib/human.c (humblock): Set *options even when returning due to
20495         xstrtoumax conversion failure.  Thanks to a used-uninitialized
20496         warning from gcc-4.
20497
20498 2005-04-09  Jim Meyering  <jim@meyering.net>
20499
20500         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
20501         -Wuninitialized: initialize tm0.tm_year.
20502
20503 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
20504
20505         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
20506         count, since there's no maximum.  All uses changed.
20507         Add member dsts_seen.
20508         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
20509         not being INT_MAX.
20510         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
20511         Use pc_rels_seen to decide whther a date is absolute.
20512
20513         * lib/getdate.y (number): Don't overwrite year.
20514         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
20515         check.
20516
20517 2005-04-02  Simon Josefsson  <jas@extundo.com>
20518
20519         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
20520         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
20521
20522 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
20523
20524         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
20525         where no absolute path name can be longer than PATH_MAX.
20526
20527 2005-03-27  Jim Meyering  <jim@meyering.net>
20528
20529         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
20530
20531 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
20532
20533         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
20534         "one's complement" -> "ones' complement" in comment, as per Knuth.
20535         "value of type" -> "type or expression" in comment.
20536         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
20537
20538 2005-03-26  Jim Meyering  <jim@meyering.net>
20539
20540         Comment nits.
20541         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
20542         Correct typos: s/or/of/.
20543
20544 2005-03-26  Jim Meyering  <jim@meyering.net>
20545
20546         * modules/check-include-files: Move to ../ and rename to...
20547         * check-module: ...this.
20548
20549 2005-03-25  Jim Meyering  <jim@meyering.net>
20550
20551         * modules/xvasprintf (Files): Add xalloc.h.
20552
20553 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
20554
20555         * modules/gettext (Files): config/config.rpath ->
20556         build-aux/config.rpath
20557         * modules/iconv (Files): Likewise.
20558         Problem reported by Oskar Liljeblad.
20559
20560 2005-03-23  Jim Meyering  <jim@meyering.net>
20561
20562         * modules/check-include-files: New script to check for
20563         missing dependencies, multiple includes, etc.
20564
20565         * modules/c-strtold (Depends-on): Add xalloc.
20566         * modules/c-strtod (Depends-on): Add xalloc.
20567         * modules/hash (Depends-on): Add xalloc.
20568         (Files): Remove lib/xalloc.h.
20569
20570         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
20571         * modules/userspec (Files): Add lib/inttostr.h.
20572
20573 2005-03-23  Jim Meyering  <jim@meyering.net>
20574
20575         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
20576
20577 2005-03-22  Jim Meyering  <jim@meyering.net>
20578
20579         * modules/stat-macros: New module.
20580         * modules/canonicalize, modules/euidaccess, modules/file-type,
20581         * modules/filemode, modules/lchown, modules/makepath,
20582         * modules/rmdir, modules/stat: Depend on new stat-macros module
20583         rather than listing lib/stat-macros.h manually.
20584         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
20585
20586 2005-03-22  Jim Meyering  <jim@meyering.net>
20587
20588         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
20589
20590 2005-03-22  Bruno Haible  <bruno@clisp.org>
20591
20592         * config/srclist.txt: Replace target directory 'config' with
20593         'build-aux'.
20594         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
20595         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
20596         ../build-aux/.
20597
20598 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
20599
20600         * modules/chdir-long (Depends-on): Add mempcpy.
20601
20602         * modules/acl, modules/backupfile, modules/c-strtod,
20603         modules/c-strtold, modules/canon-host, modules/canonicalize,
20604         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
20605         modules/exclude, modules/exitfail, modules/file-type,
20606         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
20607         modules/getdate, modules/getline, modules/getpagesize,
20608         modules/getpass, modules/getugroups, modules/group-member,
20609         modules/hard-locale, modules/hash, modules/human, modules/idcache,
20610         modules/inttostr, modules/long-options, modules/makepath,
20611         modules/md5, modules/memcasecmp, modules/memcoll,
20612         modules/modechange, modules/mountlist, modules/path-concat,
20613         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
20614         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
20615         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
20616         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
20617         modules/strftime, modules/strndup, modules/strverscmp,
20618         modules/timespec, modules/unlocked-io, modules/userspec,
20619         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
20620         modules/yesno:
20621         Remove lib_SOURCES line from Makefile.am section, as this is now
20622         done automatically by the corresponding Autoconf macro.
20623
20624 2005-03-21  Jim Meyering  <jim@meyering.net>
20625
20626         Changes imported from coreutils.
20627
20628         * lib/cycle-check.c: Don't include xalloc.h.
20629
20630         * lib/path-concat.c: Don't include assert.h.
20631         (path_concat): Remove assertion that would have triggered
20632         for ABASE starting with more than one slash.
20633         Reported by Andreas Schwab.
20634
20635         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
20636         properly when ABASE is an absolute file name.
20637         Correct the description of this function.
20638         Include <assert.h>.
20639         Add an assertion and a test driver.
20640         This fixes a bug introduced on 2004-07-02.
20641         Andreas Schwab reported the resulting failure of cp --parents:
20642         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
20643
20644 2005-03-21  Jim Meyering  <jim@meyering.net>
20645
20646         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
20647         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
20648
20649 2005-03-21  Jim Meyering  <jim@meyering.net>
20650         and  Paul Eggert  <eggert@cs.ucla.edu>
20651
20652         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
20653         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
20654         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
20655         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
20656         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
20657         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
20658         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
20659         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
20660         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
20661         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
20662         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
20663         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
20664         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
20665         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
20666         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
20667         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
20668         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
20669         for these modules.
20670
20671 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
20672
20673         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
20674         (which shouldn't happen), generate nothing instead of returning 0
20675         immediately, so that nstrftime (NULL, ...) doesn't return 0.
20676
20677 2005-03-16  Bruno Haible  <bruno@clisp.org>
20678
20679         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
20680         HAVE_LONGLONG_64BIT.
20681
20682 2005-03-16  Bruno Haible  <bruno@clisp.org>
20683
20684         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
20685         HAVE_LONGLONG_64BIT.
20686
20687 2005-03-16  Bruno Haible  <bruno@clisp.org>
20688
20689         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
20690         HAVE_LONGLONG_64BIT.
20691
20692 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
20693
20694         * lib/strftime.c (my_strftime): Prepend space to format so that we can
20695         reliably distinguish strftime failure from empty output on POSIX
20696         hosts.
20697
20698 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
20699
20700         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
20701         (iconv_string): Don't guess a size-zero buffer, as that might cause
20702         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
20703         result would be 'too large', where 'too large' is (heuristically)
20704         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
20705         overflow concerns.  This will prevent some unwanted malloc failures
20706         when the inputs are very large.
20707
20708 2005-03-15  Karl Berry  <karl@gnu.org>
20709
20710         * config/srclist.txt (config.rpath): from gettext.
20711         * config/config.rpath: update.
20712
20713 2005-03-15  Bruno Haible  <bruno@clisp.org>
20714
20715         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
20716         to 'negate'.
20717
20718         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
20719         variable.
20720
20721         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
20722         results.
20723
20724 2005-03-14  Simon Josefsson  <jas@extundo.com>
20725
20726         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
20727         <fx@gnu.org>.
20728
20729 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
20730
20731         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
20732         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
20733         intprops.h.
20734         * lib/strtol.c: Likewise.
20735
20736 2005-03-14  Jim Meyering  <jim@meyering.net>
20737
20738         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
20739         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
20740         to be nonzero so that we (and caller) can detect the difference
20741         between a valid zero-length expansion and an error return, even
20742         when the underlying strftime fails before writing anything into
20743         that location.
20744
20745 2005-03-14  Bruno Haible  <bruno@clisp.org>
20746
20747         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
20748         Update from GNU gettext 0.14.3.
20749
20750 2005-03-10  Jim Meyering  <jim@meyering.net>
20751
20752         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
20753
20754 2005-03-10  Jim Meyering  <jim@meyering.net>
20755
20756         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
20757         so that this module works on systems without fchdir.
20758
20759 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
20760
20761         Factor int-properties macros into a single file, except for
20762         glibc-related files.
20763         * lib/intprops.h: New file.
20764         * lib/getloadavg.c: Include it instead of limits.h.
20765         (INT_STRLEN_BOUND): Remove.
20766         * lib/human.c: Include intprops.h.
20767         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
20768         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
20769         302/1000.
20770         * lib/inttostr.h: Include intprops.h instead of limits.h.
20771         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
20772         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
20773         for consistency with intprops.h.
20774         (time_t_is_integer, twos_complement_arithmetic): Use them.
20775         * lib/sig2str.h: Include <signal.h>, intprops.h.
20776         (INT_STRLEN_BOUND): Remove.
20777         * lib/strftime.c (TYPE_SIGNED): Remove.
20778         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
20779         * lib/strtol.c: Adjust comments to match intprops.h.
20780         * lib/userspec.c: Include intprops.h.
20781         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
20782         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
20783         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
20784         instead of rolling our own expressions.
20785         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
20786
20787         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
20788         instead of int.
20789         (my_strftime): Do not mishandle years close to INT_MAX, by doing
20790         the right thing even if adding 1900 would overflow.  Similarly
20791         for tm_mon + 1 and tm_yday + 1.
20792         Make %Y always equivalent to %C%y, and similarly for %G and %g.
20793         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
20794         (DO_SIGNED_NUMBER): New macro.
20795         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
20796
20797 2005-03-07  Bruno Haible  <bruno@clisp.org>
20798
20799         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
20800
20801 2005-03-07  Bruno Haible  <bruno@clisp.org>
20802
20803         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
20804
20805 2005-03-04  Derek R. Price  <derek@ximbiot.com>
20806
20807         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
20808         (func_import): Only replace files via --import when they have actually
20809         changed.
20810
20811 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20812
20813         * m4/mmap-anon.m4: New file.
20814         * m4/pagealign_alloc.m4: New file.
20815
20816 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20817             Bruno Haible  <bruno@clisp.org>
20818
20819         * modules/pagealign_alloc: New file.
20820         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
20821
20822 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20823             Bruno Haible  <bruno@clisp.org>
20824
20825         * lib/pagealign_alloc.h: New file.
20826         * lib/pagealign_alloc.c: New file.
20827
20828 2005-03-03  Bruno Haible  <bruno@clisp.org>
20829
20830         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
20831         Use an all-permissive copyright notice, recommended by RMS.
20832
20833 2005-03-02  Bruno Haible  <bruno@clisp.org>
20834
20835         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
20836         of AIX, the replacement has to be done only after <string.h> is
20837         included, therefore not in config.h. stpncpy.h does the replacement,
20838         and stpncpy.c uses it.
20839
20840 2005-03-02  Bruno Haible  <bruno@clisp.org>
20841
20842         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
20843         stpncpy.c uses it.
20844
20845 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20846
20847         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
20848         The workaround isn't strictly needed for POSIX conformance, and
20849         it's too much of a pain to configure and maintain.  We'll ask
20850         people to fix their kernels instead.
20851         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
20852         (NANOSLEEP_BUG_WORKAROUND): Remove.
20853         (xnanosleep): Remove the workaround.
20854
20855 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20856
20857         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
20858         Reported by Derek Price.
20859         (Include): Add "timespec.h".
20860
20861         * modules/xnanosleep (Depends-on): Remove gethrxtime.
20862
20863 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20864
20865         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
20866         to detect nanosleep bug.
20867
20868 2005-03-01  Bruno Haible  <bruno@clisp.org>
20869
20870         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
20871
20872 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
20873
20874         * modules/gethrxtime: New file.
20875         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
20876         (Depends-on): Add gethrxtime.
20877         (configure.ac): Add gl_XNANOSLEEP.
20878         (Makefile.am): Remove lib_SOURCES line.
20879
20880 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
20881
20882         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
20883         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
20884
20885 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
20886
20887         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
20888         * lib/timespec.h (gettime): Return void, since it always
20889         succeeds now.  All uses changed.
20890         * lib/gettime.c (gettime) Likewise.
20891         [HAVE_NANOTIME]: Prefer nanotime.
20892         Assume gettimeofday succeeds, as POSIX requires.
20893         Assime time () succeeds, since other code already does.
20894         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
20895         (timespec_subtract): Remove.
20896         (NANOSLEEP_BUG_WORKAROUND): New constant.
20897         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
20898         things considerably.  Use it only on GNU/Linux hosts, since the
20899         workaround shouldn't be needed elsewhere.
20900
20901 2005-02-24  Bruno Haible  <bruno@clisp.org>
20902
20903         * modules/gettext (Files): Add m4/glibc2.m4.
20904
20905 2005-02-24  Bruno Haible  <bruno@clisp.org>
20906
20907         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
20908         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
20909         * m4/progtest.m4:
20910         Update from GNU gettext 0.14.2.
20911         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
20912
20913 2005-02-24  Bruno Haible  <bruno@clisp.org>
20914
20915         * lib/localcharset.c: Update from GNU gettext 0.14.2.
20916         * lib/config.charset: Update from GNU gettext 0.14.2.
20917
20918 2005-02-24  Bruno Haible  <bruno@clisp.org>
20919
20920         * lib/gettext.h: Update from GNU gettext 0.14.2.
20921
20922 2005-02-23  Simon Josefsson  <jas@extundo.com>
20923
20924         * m4/iconvme.m4: New file.
20925
20926 2005-02-23  Jim Meyering  <jim@meyering.net>
20927
20928         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
20929         change.
20930         Thanks to Bruno Haible for catching it.
20931
20932 2005-02-22  Simon Josefsson  <jas@extundo.com>
20933
20934         * modules/iconvme: New file.
20935
20936         * MODULES.html.sh: Add iconvme.
20937
20938 2005-02-22  Simon Josefsson  <jas@extundo.com>
20939
20940         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
20941
20942 2005-02-22  Simon Josefsson  <jas@extundo.com>
20943
20944         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
20945
20946 2005-02-22  Jim Meyering  <jim@meyering.net>
20947
20948         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
20949         s/ifndef/ifdef/.
20950
20951 2005-02-20  Neil Conway  <neilc@samurai.com>
20952
20953         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
20954         returned by OSX/Darwin if the specified buffer is not large
20955         enough for the hostname.
20956
20957 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20958
20959         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
20960         pass it to _help, otherwise the latter coredumps trying to
20961         dereference state.root_argp.
20962
20963 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20964
20965         * modules/chdir-long (Depends-on): Add memrchr.
20966         * modules/memrchr (Files): Add lib/memrchr.h.
20967         (Include): "memrchr.h".
20968
20969 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20970
20971         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
20972
20973 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
20974
20975         * lib/memrchr.h: New file.
20976         * lib/chdir-long.c: Include it.
20977         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
20978         Don't bother including stddef.h.
20979
20980 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
20981
20982         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
20983         inclusion.
20984         Include <sys/types.h>, for dev_t.
20985         (ME_DUMMY, ME_REMOTE): Move from here....
20986         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
20987         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
20988         Dmitry V. Levin.
20989         Include mountlist.h first, to test the interface.
20990
20991 2005-01-29  Bruno Haible  <bruno@clisp.org>
20992
20993         * lib/progname.c (program_name): Initialize.
20994         Needed when linking statically on MacOS X.
20995
20996 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
20997
20998         Sync from coreutils.
20999         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
21000         (Depends-on): Add c-strtod.
21001         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
21002
21003 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
21004
21005         Sync from coreutils.
21006         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
21007
21008         Remove files that are specific to coreutils.
21009         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
21010
21011 2005-01-28  Bruno Haible  <bruno@clisp.org>
21012
21013         * modules/javacomp: New file.
21014         * MODULES.html.sh (Java): Add javacomp.
21015
21016 2005-01-28  Bruno Haible  <bruno@clisp.org>
21017
21018         * m4/javacomp.m4: New file, from GNU gettext.
21019
21020 2005-01-28  Bruno Haible  <bruno@clisp.org>
21021
21022         * lib/javacomp.sh.in: New file, from GNU gettext.
21023         * lib/javacomp.h: New file, from GNU gettext.
21024         * lib/javacomp.c: New file, from GNU gettext.
21025
21026 2005-01-26  Simon Josefsson  <jas@extundo.com>
21027
21028         * lib/gai_strerror.c: Use GPL in header.
21029
21030 2005-01-26  Bruno Haible  <bruno@clisp.org>
21031
21032         * modules/javaexec: New file.
21033         * MODULES.html.sh (Java): Add javaexec.
21034
21035 2005-01-26  Bruno Haible  <bruno@clisp.org>
21036
21037         * m4/javaexec.m4: New file, from GNU gettext.
21038
21039 2005-01-26  Bruno Haible  <bruno@clisp.org>
21040
21041         * lib/javaexec.sh.in: New file, from GNU gettext.
21042         * lib/javaexec.h: New file, from GNU gettext.
21043         * lib/javaexec.c: New file, from GNU gettext.
21044
21045 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21046
21047         * modules/lchown (Depends-on): Remove lchown.h
21048
21049 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21050
21051         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
21052         must be defined if the header file was not found, in order
21053         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
21054
21055 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21056
21057         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
21058         initializers for struct pentry_state.
21059         (__argp_error): Check return value of __asprintf
21060         (__argp_failure): Translate error message
21061
21062         * lib/argp-parse.c: Removed braces around the expansion of N_()
21063
21064 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
21065
21066         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
21067         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
21068         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
21069         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
21070         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
21071         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
21072         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
21073         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
21074         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
21075         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
21076         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
21077         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
21078         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
21079         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
21080         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
21081         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
21082         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
21083         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
21084         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
21085         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
21086         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
21087         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
21088         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
21089         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
21090         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
21091         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
21092         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
21093         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
21094         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
21095         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
21096         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
21097         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
21098         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
21099         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
21100         xstrtol.m4, xstrtoumax.m4, yesno.m4:
21101         Use an all-permissive copyright notice, recommended by RMS.
21102
21103 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
21104
21105         * modules/chdir-long (Depends-on): Remove mempcpy.
21106
21107 2005-01-21  Jim Meyering  <jim@meyering.net>
21108
21109         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
21110         same value as for Solaris 9.
21111
21112         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
21113         component length.  This included changing the parameter to be
21114         of type `char *' rather than `char const *'.
21115         * lib/chdir-long.h (chdir_long): Update prototype.
21116
21117         * lib/openat.c (fdopendir, fstatat): New functions.
21118         * lib/openat.h: Include headers required for use of DIR and struct
21119         stat.
21120         [AT_SYMLINK_NOFOLLOW]: Define.
21121         (fdopendir, fstatat): Add prototypes.
21122
21123 2005-01-21  Bruno Haible  <bruno@clisp.org>
21124
21125         * modules/classpath: New file.
21126         * MODULES.html.sh (Java): Add classpath.
21127
21128 2005-01-21  Bruno Haible  <bruno@clisp.org>
21129
21130         * lib/classpath.h: New file, from GNU gettext.
21131         * lib/classpath.c: New file, from GNU gettext.
21132
21133 2005-01-20  Simon Josefsson  <jas@extundo.com>
21134
21135         * modules/version-etc-fsf: New file.
21136
21137 2005-01-20  Simon Josefsson  <jas@extundo.com>
21138
21139         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
21140         * lib/version-etc.c: Remove version_etc_copyright.
21141         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
21142         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
21143
21144 2005-01-20  Simon Josefsson  <jas@extundo.com>
21145
21146         * lib/base64.h (isbase64): Add.
21147
21148         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
21149         using a unsigned prototype, don't inline.
21150         (base64_decode): Use it.
21151
21152 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
21153
21154         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
21155         it.
21156
21157 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
21158
21159         * lib/save-cwd.c (save_cwd): Remove code to support the case
21160         where fchdir is missing or flaky.
21161
21162 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
21163
21164         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
21165
21166 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
21167
21168         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
21169         AC_LIBSOURCES now does this.
21170         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
21171         with new ullong_max module.
21172
21173 2005-01-19  Bruno Haible  <bruno@clisp.org>
21174
21175         * modules/sh-quote: New file.
21176         * MODULES.html.sh (Executing programs): Add sh-quote.
21177
21178 2005-01-19  Bruno Haible  <bruno@clisp.org>
21179
21180         * lib/sh-quote.h: New file, from GNU gettext.
21181         * lib/sh-quote.c: New file, from GNU gettext.
21182
21183 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
21184
21185         Merge from coreutils.
21186         * m4/ullong_max.m4: New file.
21187         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
21188         (gl_MACROS): Assume localeconv exists.
21189
21190 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
21191
21192         Merge changes from coreutils, as described below in several
21193         changelogs dated today.
21194
21195         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
21196         (O_DIRECTORY): Remove; not needed here, since "." must be
21197         a directory.  All uses removed.
21198         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
21199         universal on Suns, and we also need to test for IRIX.
21200         Revamp code to use 'if' rather than '#if'.
21201         Avoid unnecessary comparison of cwd->desc to 0.
21202
21203         * lib/utimens.c (futimens): Robustify the previous patch, by checking
21204         for known valid error numbers rather than observed invalid ones.
21205
21206 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
21207
21208         * modules/ullong_max: New file.
21209
21210         * modules/chdir-long, modules/openat: New files.
21211         * modules/save-cwd (Depends-on): Depend on chdir-long.
21212         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
21213
21214 2005-01-18  Jim Meyering  <jim@meyering.net>
21215
21216         Merge from coreutils.
21217         * m4/chdir-long.m4, m4/openat.m4: New files.
21218         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
21219         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
21220         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
21221         is sane and DOES follow symlinks.  Besides, testing 20 different
21222         systems found no broken chown implementations.
21223         Prompted by a change in rsync's copy of this macro.
21224         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
21225
21226         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
21227
21228         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
21229         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
21230         NULL-means-set-to-current-time semantics.
21231         Remove temporary file immediately, rather than waiting
21232         for configure's at-exit trap code to do it.
21233
21234 2005-01-18  Jim Meyering  <jim@meyering.net>
21235
21236         * lib/version-etc.c (version_etc_copyright): Update copyright date.
21237
21238         * lib/utimens.c (futimens): Account for the fact that futimes
21239         can also fail with errno == ENOSYS or errno == ENOENT.
21240         Patch from Dmitry V. Levin.
21241
21242         Change the name of the robust chdir function from chdir to chdir_long.
21243         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
21244         (restore_cwd): Use chdir_long, not chdir.
21245         * lib/chdir-long.c: Renamed from chdir.c.
21246         * lib/chdir-long.h: Renamed from chdir.h.
21247         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
21248         Hurd.
21249
21250 2005-01-18  Bruno Haible  <bruno@clisp.org>
21251
21252         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
21253         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
21254         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
21255         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
21256         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
21257         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
21258         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
21259         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
21260         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
21261         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
21262         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
21263         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
21264         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
21265         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
21266         Use an all-permissive copyright notice, recommended by RMS.
21267
21268 2005-01-18  Bob Proulx  <bob@proulx.com>
21269
21270         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
21271         simplify offsetof() macro construct to avoid compile failure with
21272         native HP-UX 11.0 ANSI C compiler.
21273
21274 2005-01-17  Bruno Haible  <bruno@clisp.org>
21275
21276         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
21277         redundant because stpncpy.m4 takes care of it.
21278
21279 2005-01-17  Bruno Haible  <bruno@clisp.org>
21280
21281         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
21282
21283 2005-01-17  Bruno Haible  <bruno@clisp.org>
21284
21285         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
21286         used.
21287
21288 2005-01-17  Bruno Haible  <bruno@clisp.org>
21289
21290         * lib/fwriteerror.h (fwriteerror): Change specification to include
21291         fclose.
21292         * lib/fwriteerror.c: Include <stdbool.h>.
21293         (fwriteerror): At the end, close the file stream. Record whether
21294         stdout was already closed.
21295
21296 2005-01-17  Bruno Haible  <bruno@clisp.org>
21297
21298         * lib/execute.c (environ): Declare if needed.
21299         * lib/pipe.c (environ): Likewise.
21300         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
21301
21302 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21303
21304         * modules/argp: Depend on vsnprintf
21305
21306 2005-01-10  Jim Meyering  <jim@meyering.net>
21307
21308         * modules/closeout (Depends-on): Add atexit.
21309
21310 2005-01-06  Bruno Haible  <bruno@clisp.org>
21311
21312         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
21313
21314 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
21315
21316         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
21317         definitions to be after all include files, to avoid collisions.
21318         Problem reported by Bob Proulx.
21319
21320 2005-01-04  Jim Meyering  <jim@meyering.net>
21321
21322         Changes imported from coreutils.
21323         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
21324         as the mkstemp template, use a temporary directory and an
21325         8.3-friendly template to avoid trouble on systems like DJGPP.
21326         Reported by Juan M. Guerrero via Stepan Kasal.
21327         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
21328         close. Remove the temporary directory right away, rather than waiting
21329         for configure's at-exit trap code to do it.
21330         Suggestion from Stepan Kasal.
21331
21332 2005-01-01  Simon Josefsson  <jas@extundo.com>
21333
21334         * gnulib-tool: Print #include directives when --import'ing.
21335
21336 2004-12-28  Simon Josefsson  <jas@extundo.com>
21337
21338         * tests/test-base64.c: Include required header files.  Remove
21339         unused variables.
21340
21341 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
21342
21343         * modules/error (Depends-on): Remove gettext.
21344
21345 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
21346
21347         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
21348         not needed.  This removes a dependency on the gettext module.
21349         [defined _LIBC]: Do not include <libintl.h>; not needed.
21350
21351 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
21352
21353         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
21354         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
21355
21356 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
21357
21358         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
21359         HAVE_DECL_STRTOLD.
21360
21361 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
21362
21363         * modules/getdate (Depends-on): Remove alloca-opt.
21364
21365 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
21366
21367         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
21368
21369 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
21370
21371         * lib/argp-parse.c: Include <stddef.h>.
21372         (alignof, alignto): New macros.
21373         (parser_init): Don't assume that void * is aligned sufficiently
21374         for struct option.
21375
21376         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
21377         need to extend the stack.
21378         (YYINITDEPTH): New macro, so that the initial stack isn't overly
21379         large.
21380
21381 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21382
21383         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
21384
21385 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
21386
21387         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
21388         (2004-10-24) change.  Apparently this was a false alarm.
21389
21390         * modules/getdate: Depend on alloca-opt, not alloca.
21391
21392 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
21393
21394         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
21395         Remove now-obsolete comment about AIX.
21396         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
21397         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
21398         (YYMAXDEPTH): New macro.
21399
21400 2004-12-18  Simon Josefsson  <jas@extundo.com>
21401
21402         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
21403
21404 2004-12-18  Bruno Haible  <bruno@clisp.org>
21405
21406         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
21407
21408 2004-12-18  Bruno Haible  <bruno@clisp.org>
21409
21410         * lib/fatal-signal.c (fatal_signals): Make non-const.
21411         (init_fatal_signals): New function.
21412         (uninstall_handlers, install_handlers): Ignore signals that were set to
21413         SIG_IGN.
21414         (at_fatal_signal): Call init_fatal_signals.
21415         (init_fatal_signal_set): Likewise. Ignore signals that were set to
21416         SIG_IGN.
21417         Reported by Paul Eggert.
21418
21419 2004-12-18  Bruno Haible  <bruno@clisp.org>
21420
21421         * doc/alloca.texi: New file.
21422         * doc/alloca-opt.texi: New file.
21423
21424 2004-12-17  Jim Meyering  <jim@meyering.net>
21425
21426         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
21427         Otherwise, install-sh could exit with improper exit status when
21428         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
21429
21430 2004-12-16  Simon Josefsson  <jas@extundo.com>
21431
21432         * tests/test-base64.c: Add license.
21433
21434 2004-12-15  Stepan Kasal  <address@hidden>
21435
21436         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
21437
21438 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
21439
21440         * modules/getcwd (Files): Add m4/d-ino.m4.
21441         Suggested by Mark D. Baushke.
21442
21443 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
21444
21445         * lib/getdate.y (textint): New member "negative".
21446         (time_zone_hhmm): New function.
21447         Expect 14 shift-reduce conflicts, not 13.
21448         (o_colon_minutes): New rule.
21449         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
21450         (yylex): Set the "negative" member of signed numbers.
21451
21452 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
21453
21454         * doc/getdate.texi (Time of day items, Time zone items):
21455         Describe new formats +00:00, UTC+00:00.
21456
21457 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
21458
21459         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
21460         spurious "-l"s.  Problem reported by Stepan Kasal.
21461
21462 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
21463
21464         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
21465         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
21466
21467 2004-12-04  Simon Josefsson  <jas@extundo.com>
21468
21469         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
21470         Vandoorselaere <yoann@prelude-ids.org>.
21471
21472 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
21473
21474         Changes imported from coreutils.
21475         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
21476         exist.
21477         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
21478
21479 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
21480
21481         Changes imported from coreutils.
21482         * lib/hard-locale.c: Assume <locale.h> exists.
21483         Include "strdup.h".
21484         (GLIBC_VERSION): New macro.
21485         (hard_locale): Assume setlocale exists.
21486         Rewrite to avoid #ifdef.
21487         Use strdup rather than malloc + strcpy.
21488         * lib/human.c: Assume <locale.h> exists.
21489         (human_readable): Assume localeconv exists.
21490
21491 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
21492
21493         * modules/hard-locale (Depends-on): Add strdup.
21494
21495 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
21496
21497         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
21498         convert T2, not T.  (Imported from libc.)
21499
21500 2004-11-30  Simon Josefsson  <jas@extundo.com>
21501
21502         * modules/restrict (License): Change to LGPL.
21503
21504 2004-11-30  Simon Josefsson  <jas@extundo.com>
21505
21506         * m4/restrict.m4: Add copyright and copying conditions.
21507
21508 2004-11-30  Simon Josefsson  <jas@extundo.com>
21509
21510         * m4/base64.m4: New file.
21511
21512 2004-11-30  Simon Josefsson  <jas@extundo.com>
21513
21514         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
21515         base64.
21516
21517         * tests/test-base64.c: New file.
21518
21519         * modules/base64: New file.
21520
21521 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
21522
21523         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
21524         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
21525
21526         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
21527
21528 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
21529
21530         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
21531         (__getcwd.c): Don't restore errno; glibc doesn't.
21532         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
21533         first, falling back to our code only if its results look suspicious.
21534         Ensure that the resulting buffer is only as large as necessary.
21535
21536         * lib/readutmp.c: Include readutmp.h first.
21537         Include <errno.h>, since readutmp.h no longer does that.
21538         * lib/readutmp.h: Don't include <errno.h>,
21539         <sys/param.h>, <time.h>; not needed to establish interface.
21540         (errno): Remove decl.
21541         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
21542         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
21543         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
21544
21545 2004-11-28  Simon Josefsson  <jas@extundo.com>
21546
21547         * lib/base64.h, base64.c: New file.
21548
21549 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
21550
21551         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
21552
21553 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
21554
21555         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
21556         (Depends-on): Remove pathmax, same.  Add mempcpy.
21557         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
21558         (Makefile.am): Append getcwd.h to lib_SOURCES.
21559         (Include): Add getcwd.h.
21560         (Maintainer): Change from Jim Meyering to "all, glibc",
21561         since getdate now uses intended-for-glibc code.
21562         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
21563         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
21564
21565 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
21566
21567         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
21568         HP's ANSI C compiler.
21569         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
21570         Declaring int functions causes warnings on some modern systems and
21571         shouldn't be needed to compile on ancient ones.
21572         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
21573         defined.
21574
21575         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
21576         with the following changes.
21577         (__set_errno): Parenthesize properly.
21578         Include <stdbool.h>.
21579         (MIN, MAX, MATCHING_INO): New macros.
21580         (__getcwd): Define with prototype, not K&R form.
21581         Use heuristics to allocate default buffer on stack if possible.
21582         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
21583         behavior, and to avoid the PATH_MAX limit when computing
21584         ../../../../...
21585         Use MATCHING_INO to compare inode number to file.
21586         Check for arithmetic overflow in size calculations.
21587         Fix bug in reallocation of dot array that caused getcwd to fail
21588         on directories nested deeper than 75.
21589         Be more careful about saving errno on error.
21590         Do not use realloc; use only free+malloc, as this is a bit
21591         more flexible and avoids a needless copy operation.
21592         Do not inspect st_dev and st_ino for symbolic links; POSIX
21593         doesn't specify the latter.
21594         Check for closedir errors.
21595         Avoid needless casts.
21596         Use "#ifdef weak_alias" around weak_alias, to be like other
21597         glibc code.
21598         The following changes to getcwd.c have effect only when used in
21599         gnulib; they have no effect inside glibc proper.
21600         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
21601         as alloca isn't used.
21602         (alloca, __alloca): Likewise.
21603         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
21604         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
21605         unconditionally, as gnulib assumes C89 or better.
21606         Do not include <sys/param.h>.
21607         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
21608         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
21609         better.
21610         (NULL) [!defined NULL]: Remove; we assume C89 or better.
21611         Include <dirent.h> in a way that is compatible with modern Autoconf.
21612         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
21613         New macros, if not already defined.
21614         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
21615         Use "_LIBC", not "defined _LIBC", for consistency.
21616         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
21617         a mempcpy module.
21618         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
21619         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
21620         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
21621         credit only to Jim Meyering and adjust the copyright dates.
21622         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
21623         <stdlib.h>, <unistd.h>, "pathmax.h".
21624         Instead, include "xgetcwd.h" (first) and "getcwd.h".
21625         (INITIAL_BUFFER_SIZE): Remove.
21626         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
21627
21628 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
21629
21630         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
21631         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
21632         Use the _ONCE methods, for efficiency.
21633         Check for fcntl.h.  In test program, include <errno.h>
21634         and <fcntl.h> if available.  Remove old K&R cruft from
21635         test program.  Check for common errors in GNU/Linux,
21636         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
21637         don't do AC_LIBOBJ, as that's getcwd.m4's job.
21638         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
21639         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
21640         name accordingly.
21641         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
21642         accommodate new getcwd.c.
21643         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
21644         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
21645         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
21646         that's all we need now.
21647
21648 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21649
21650         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
21651         argp-parse.c depends on getopt internals, that means we should
21652         always use our getopt, to be on the safe side.
21653         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
21654         order not to spoil the result of an eventual previous invocation
21655         of gl_GETOPT_SUBSTITUTE.
21656
21657 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21658
21659         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
21660         redefinition warnings. To avoid them, include the defines
21661         in `#if !defined __need_getopt ... #endif'. The only place
21662         where __getopt_argv_const is used is in definitions
21663         of getopt_long and getopt_long_only below, which are as well
21664         protected by `#ifndef __need_getopt'.
21665         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
21666         __need_getopt after including <stdio.h> and <unistd.h> These
21667         headers might have defined it.
21668
21669 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
21670
21671         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
21672
21673 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
21674
21675         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
21676         (futimens): New function, which uses futimes if available.
21677         (futimens, utimens): Support timespec==NULL, with same semantics
21678         as utime and utimens.
21679         * lib/utimens.h (futimens): New decl.
21680
21681 2004-11-23  Jim Meyering  <jim@meyering.net>
21682
21683         * lib/getopt_.h: Remove trailing blanks.
21684
21685 2004-11-23  Jim Meyering  <jim@meyering.net>
21686
21687         * lib/__fpending.c: Add comment.
21688
21689 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
21690
21691         * modules/canonicalize (Depends-on): Add xreadlink.
21692         Problem reported by James Youngman.
21693
21694 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
21695
21696         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
21697         New macros.
21698         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
21699         optopt): Use them instead of invoking ## directly; otherwise, the
21700         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
21701
21702 2004-11-19  Bruno Haible  <bruno@clisp.org>
21703
21704         * lib/strtok_r.c: Move comments from here...
21705         * lib/strtok_r.h: ... to here.
21706
21707 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
21708
21709         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
21710         implementations that mishandle size_t overflow.
21711
21712 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
21713
21714         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
21715         might fail.  Problem reported by Yoann Vandoorselaere.
21716         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
21717         implementations that mishandle size_t overflow.
21718
21719 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21720
21721         * modules/canon-host (Depends-on): Add strdup.
21722
21723 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21724
21725         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
21726
21727 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21728
21729         * lib/canon-host.c: Include "strdup.h".
21730         (canon_host): Use getaddrinfo if available, so that IPv6 works.
21731         Use strdup instead of malloc/strcpy to duplicate strings.
21732
21733         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
21734         (human_space_before_unit): New constant.
21735         * lib/human.c (human_readable): Support it.
21736
21737         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
21738         (xgetcwd): Set errno correctly when failing.
21739         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
21740         the failure is actually due to a PATH_MAX problem.
21741
21742         Further getopt changes to make it more likely that glibc will
21743         buy the changes back.
21744         * lib/getopt.c (POSIXLY_CORRECT): New constant.
21745         (getopt): Use it, so to preserve glibc semantic
21746         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
21747         when compiling for libc.
21748         * lib/getopt_.h (__getopt_argv_const): Bring it back.
21749         (getopt_long, getopt_long_only): Use it.
21750
21751         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
21752         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
21753         (getopt): Argv is now char * const *, as per standard.
21754         (_getopt_internal_r, _getopt_internal): Argv is now char **,
21755         not char *__getopt_argv_const *.
21756         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
21757         _getopt_long_only_r): Likewise.
21758         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
21759         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
21760         _getopt_long_r, _getopt_long_only_r): Likewise.
21761         * lib/getopt_.h (__getopt_argv_const): Remove.
21762         (getopt): Argv is now char * const *, as per standard.
21763
21764         * lib/getdate.y (tORDINAL): New token.
21765         (day, relunit): Allow it for relative times.
21766         (relative_time_table): Use tORDINAL for ordinals.
21767
21768 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21769
21770         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
21771         Document that "second" isn't allowed as an ordinal number.
21772
21773 2004-11-16  Jim Meyering  <jim@meyering.net>
21774
21775         * modules/closeout (Depends-on): Add fpending.
21776
21777 2004-11-15  Jim Meyering  <jim@meyering.net>
21778
21779         * lib/closeout.c: Include "__fpending.h" once again.
21780         Include <stdbool.h>.
21781         (close_stdout): Don't fail just because stdout was closed initially,
21782         since some programs don't write to stdout in the normal course of
21783         operation (other than --version and --help), and we don't want this
21784         function to make e.g. `touch file >&-' fail.
21785         But do fail if it was closed and someone has tried to write to it.
21786         E.g., `printf foo >&-' must fail.
21787
21788 2004-11-13  Jim Meyering  <jim@meyering.net>
21789
21790         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
21791
21792 2004-11-12  Simon Josefsson  <jas@extundo.com>
21793
21794         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
21795         small doc fix is still pending.
21796
21797 2004-11-11  Simon Josefsson  <jas@extundo.com>
21798
21799         * modules/strtok_r: New file.
21800
21801         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21802         strtok_r.
21803
21804 2004-11-11  Simon Josefsson  <jas@extundo.com>
21805
21806         * m4/strtok_r.m4: New file.
21807
21808         * m4/getopt.m4: Replace opterr.
21809
21810 2004-11-11  Simon Josefsson  <jas@extundo.com>
21811
21812         * lib/strtok_r.h, strtok_r.c: New file.
21813
21814 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
21815
21816         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
21817         of replacing opterr, getopt, etc.  This should handle the
21818         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
21819
21820 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
21821
21822         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
21823         we can stop lying to compilers about the constness of argv when we
21824         are compiled outside glibc.
21825         (getopt, getopt_long, getopt_long_only): Use it.
21826         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
21827         _getopt_internal, getopt): Likewise.
21828         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
21829         _getopt_long_only_r): Likewise.
21830         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
21831         _getopt_long_r, _getopt_long_only_r): Likewise.
21832
21833         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
21834         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
21835         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
21836         the other external symbols.
21837         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
21838         declaration, since the above renaming now works around collisions.
21839
21840 2004-11-11  Jim Meyering  <jim@meyering.net>
21841
21842         * lib/linebreak.c: Remove trailing blanks.
21843         * lib/alloca_.h: Likewise.
21844         * lib/acosl.c: Likewise.
21845         * lib/euidaccess.c: Likewise.
21846         * lib/allocsa.h: Likewise.
21847
21848 2004-11-10  Simon Josefsson  <jas@extundo.com>
21849
21850         * m4/getaddrinfo.m4: New file.
21851
21852 2004-11-10  Simon Josefsson  <jas@extundo.com>
21853
21854         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
21855
21856 2004-11-10  Simon Josefsson  <jas@extundo.com>
21857
21858         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21859         getaddrinfo.
21860
21861         * modules/getaddrinfo: New file.
21862
21863 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
21864
21865         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
21866
21867 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
21868
21869         * lib/mktime.c (SHR): New macro, which is a portable
21870         substitute for >> that should work even on Crays.
21871         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
21872         Problem reported by Mark D. Baushke in
21873         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
21874         * lib/getdate.y (SHR): Likewise.
21875         (tm_diff): Use it.
21876         * lib/strftime.c (SHR): Likewise.
21877         (tm_diff): Use it.
21878         * lib/quotearg.c (struct quoting_options): Use unsigned int for
21879         quote_these_too, so that right shifts are well defined.  All uses
21880         changed.
21881
21882 2004-11-10  Jim Meyering  <jim@meyering.net>
21883
21884         Ensure that no close failure goes unreported.
21885         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
21886         return early when it seems there's nothing to flush.
21887         Don't include __fpending.h.
21888
21889 2004-11-10  Jim Meyering  <jim@meyering.net>
21890
21891         * modules/closeout (Depends-on): Remove fpending.
21892
21893 2004-11-10  Jim Meyering  <jim@meyering.net>
21894
21895         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
21896
21897 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
21898
21899         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
21900         gl_FUNC_STRFTIME.
21901         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
21902         and AC_REQUIRE when possible, to avoid duplicate checks.
21903         Check for <wchar.h>.
21904
21905 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
21906
21907         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
21908
21909 2004-11-09  Bruno Haible  <bruno@clisp.org>
21910
21911         * m4/sockpfaf.m4: New file.
21912
21913 2004-11-05  Bruno Haible  <bruno@clisp.org>
21914
21915         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
21916         Reported by Mark D. Baushke <mdb@cvshome.org>.
21917
21918 2004-11-04  Bruno Haible  <bruno@clisp.org>
21919
21920         2004-09-11  Bruno Haible  <bruno@clisp.org>
21921                 * allocsa.valgrind: New file.
21922         2004-02-06  Bruno Haible  <bruno@clisp.org>
21923                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
21924                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
21925                 Reported by Christopher Seip <chris.seip@hp.com>.
21926
21927 2004-11-04  Bruno Haible  <bruno@clisp.org>
21928
21929         * modules/allocsa (Files): Add lib/allocsa.valgrind.
21930         (Makefile.am): Distribute it.
21931
21932 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
21933
21934         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
21935         with errno == ERANGE if the buffer is too small.
21936         Problem reported by Mark D. Baushke.
21937
21938 2004-11-03  Albert Chin  <china@thewrittenword.com>
21939             Paul Eggert  <eggert@cs.ucla.edu>
21940
21941         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
21942         equivalent, substitute $ac_type for equivalent type rather than
21943         blindly using uint32_t *always* which won't work if uint32_t is not
21944         available.  Define _UINT32_T to work around typedef of uint32_t if
21945         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
21946         2.5.1.
21947
21948 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21949
21950         * m4/jm-macros.m4: Sync from coreutils.
21951         (gl_MACROS): Check for mbrlen, for pathchk.
21952         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
21953
21954 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21955
21956         * lib/xreadlink.c (MAXSIZE): New macro.
21957         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
21958         size does not exceed MAXSIZE.  Avoid cast.
21959         As suggested by Mark D. Baushke in
21960         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
21961         if readlink fails with buffer size just under MAXSIZE, try again
21962         with MAXSIZE.
21963
21964 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
21965
21966         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
21967
21968 2004-11-02  Derek R. Price  <derek@ximbiot.com>
21969         and  Paul Eggert  <eggert@cs.ucla.edu>
21970
21971         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
21972         (get_date): Overparenthesize to avoid GCC warning.
21973
21974 2004-11-02  Bruno Haible  <bruno@clisp.org>
21975
21976         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
21977         returns void.
21978
21979 2004-11-02  Bruno Haible  <bruno@clisp.org>
21980
21981         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
21982         function returns void.
21983
21984 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
21985
21986         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
21987         fflush_unlocked, flockfile, funlockfile, funlockfile,
21988         fputs_unlocked, putc_unlocked.
21989
21990 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
21991
21992         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
21993         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
21994         already declared.
21995
21996 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
21997
21998         * modules/getdate (Files): Add doc/getdate.texi.
21999         (Depends-on): Add setenv, xalloc.
22000
22001 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
22002
22003         * lib/getdate.y: Add support for TZ="foo" within a date string.
22004         Fix some bugs near time_t boundaries.  Reject dates with
22005         out-of-range components, e.g., "Sept 31".
22006         Include <stdlib.h>, "setenv.h", "xalloc.h".
22007         (ISDIGIT_LOCALE): Remove; unused.
22008         Note that the TZ and time functions used here are not reentrant.
22009         (mktime_ok, get_tz): New functions.
22010         (TZBUFSIZE): New constant.
22011         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
22012         This requires that we sometimes generate our own TZ="XXX..." setting.
22013
22014 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
22015
22016         * doc/getdate.texi: New file, from coreutils with modifications for
22017         the new TZ parsing.
22018
22019 2004-10-27  Derek R. Price  <derek@ximbiot.com>
22020
22021         * lib/mktime.c (not_equal_tm): Remove redundant check.
22022
22023 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
22024
22025         * modules/regex (lib_SOURCES): Add regex.c.
22026         Reported by James Youngman in
22027         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
22028
22029 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
22030
22031         * lib/getdate.y: Use Bison 1.875 features, and some minor
22032         code cleanups.  This change does not affect semantics.
22033         Don't include <stdlib.h>; no longer needed.
22034         Don't include unlocked-io.h; only the "#if TEST" code uses
22035         stdio, and performance isn't crucial there.
22036         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
22037         Bison 1.875 features as described below.
22038         All uses of "PC." replaced by "pc->".
22039         (YYSTYPE): Add a forward declaration.
22040         (yylex, yyerror): Use full prototypes in forward decls.
22041         Use "%pure-parser" rather than obsolescent "%pure_parser".
22042         Use %parse-param and %lex-param instead of obsolescent
22043         YYPARSE_PARAM and YYLEX_PARAM.
22044         (meridian_table, month_and_day_table, time_units_table,
22045         relative_time_table, time_zone_table, military_table,
22046         lookup_zone, lookup_word, get_date):
22047         Use NULL instead of 0 where appropriate.
22048         (to_hour): Avoid abort (), to avoid a dependency on
22049         stdlib.h.
22050         (yyerror, yylex): Now accepts parser_control * arg.
22051         (main) [TEST]: Use '\0' rather than 0 for char.
22052
22053 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
22054
22055         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
22056
22057 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
22058
22059         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
22060         It's now the caller's responsibility to handle the case where
22061         !HAVE_GETPAGESIZE && !defined getpagesize.
22062
22063         * lib/mktime.c (leapyear): Arg is long int, not int.
22064
22065 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
22066
22067         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
22068
22069 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
22070
22071         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
22072         missing.  Problem reported by James Youngman.
22073
22074 2004-10-16  Simon Josefsson  <jas@extundo.com>
22075
22076         * gnulib-tool: Fix comments.  Fix parse problem.
22077         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
22078
22079 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
22080
22081         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
22082         implementation of getopt_long.  Problem reported by Alexander Taler in:
22083         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
22084
22085 2004-10-15  Bruno Haible  <bruno@clisp.org>
22086
22087         * gnulib-tool: Untabify. Initialize supplied_libname.
22088         (func_usage): More homogenous output.
22089         (func_modules_transitive_closure, func_modules_to_filelist,
22090         func_emit_lib_Makefile_am): New functions.
22091         (func_import): New function, extracted from big case statement. Use
22092         func_get_license, func_modules_transitive_closure,
22093         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
22094         opt_lgpl. Don't use test -a, as it's not portable.
22095         (func_create_testdir): Use func_modules_transitive_closure,
22096         func_modules_to_filelist, func_emit_lib_Makefile_am.
22097
22098 2004-10-15  Bruno Haible  <bruno@clisp.org>
22099
22100         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
22101
22102 2004-10-15  Bruno Haible  <bruno@clisp.org>
22103
22104         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
22105         the portions belonging to each module.
22106         Suggested by Derek Robert Price <derek@ximbiot.com>.
22107
22108 2004-10-12  Simon Josefsson  <jas@extundo.com>
22109
22110         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
22111         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
22112         to real functions.
22113
22114 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22115
22116         * modules/vsnprintf: New file.
22117
22118 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22119
22120         * m4/vsnprintf.m4: New file.
22121
22122 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22123
22124         * lib/vsnprintf.h: New file.
22125         * lib/vsnprintf.c: New file.
22126
22127 2004-10-11  Bruno Haible  <bruno@clisp.org>
22128
22129         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
22130         vsnprintf.
22131
22132 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
22133
22134         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
22135
22136 2004-10-07  Bruno Haible  <bruno@clisp.org>
22137
22138         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
22139         fits into the provided buffer.
22140
22141 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
22142
22143         * lib/diacrit.c, diacrit.h: Add GPL notice.
22144
22145         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
22146         notice.
22147         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
22148         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
22149         This avoids a potential constant-folding bug.
22150
22151 2004-10-05  Bruno Haible  <bruno@clisp.org>
22152
22153         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
22154         for the declaration of strsep.
22155
22156 2004-10-05  Bruno Haible  <bruno@clisp.org>
22157
22158         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
22159
22160 2004-10-04  Simon Josefsson  <jas@extundo.com>
22161
22162         * modules/memmem: New file.
22163         * tests/test-memmem.c: New file.
22164         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
22165
22166 2004-10-04  Simon Josefsson  <jas@extundo.com>
22167
22168         * m4/memmem.m4: New file.
22169
22170 2004-10-04  Simon Josefsson  <jas@extundo.com>
22171
22172         * lib/memmem.h: New file.
22173         * lib/memmem.c: New file, taken from glibc.
22174
22175 2004-10-04  Simon Josefsson  <jas@extundo.com>
22176
22177         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
22178         '#ifdef USE_UNLOCKED_IO'.
22179
22180 2004-10-04  Simon Josefsson  <jas@extundo.com>
22181
22182         * config/srclist.txt: Add memmem from glibc.
22183
22184 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
22185
22186         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
22187
22188         * modules/argmatch, modules/argp, modules/closeout, modules/error,
22189         modules/exclude, modules/getdate, modules/getline,
22190         modules/getndelim2, modules/getpass, modules/getpass-gnu,
22191         modules/getusershell, modules/linebuffer, modules/md5,
22192         modules/mountlist, modules/posixtm, modules/readtokens,
22193         modules/readutmp, modules/regex, modules/sha1,
22194         modules/version-etc, modules/yesno:
22195         Remove dependency on unlocked-io.
22196
22197 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
22198
22199         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
22200
22201         * m4/unlocked-io.m4: Add copyright notice.
22202         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
22203
22204 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
22205
22206         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
22207         * lib/xmalloc.c (xmemdup): Likewise.
22208         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
22209         XFREE): Remove these long-obsolescent macros.
22210         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
22211         * lib/xstrdup.c: Remove.
22212
22213         * lib/regex.c (re_comp): Cast gettext return value to char *,
22214         Problem reported by Martin Neitzel via Mark D. Baushke.
22215
22216 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
22217
22218         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
22219         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
22220         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
22221         regex.c, sha1.c, version-etc.c, yesno.c:
22222         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
22223         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
22224         the includer's responsibility.
22225
22226         Sync from coreutils.
22227
22228         * lib/modechange.c (mode_compile): Don't decrement a pointer that
22229         points to the start of a string, as the C Standard says the
22230         resulting behavior is undefined.
22231
22232         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
22233         simple -> simple_backups, numbered_existing ->
22234         numbered_existing_backups, numbered -> numbered_backups
22235         to avoid shadowing problems.  All uses changed.
22236         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
22237         * lib/backupfile.c (check_extension, numbered_backup):
22238         Rename locals to avoid shadowing 'basename'.
22239         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
22240         once.
22241
22242         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
22243         * lib/.cvsignore: Add getopt.h.
22244
22245 2004-10-04  Bruno Haible  <bruno@clisp.org>
22246
22247         * modules/README: New file.
22248         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
22249         not a module.
22250
22251 2004-10-02  Jim Meyering  <jim@meyering.net>
22252
22253         * lib/dirfd.h, getpagesize.h: Add copyright notice.
22254
22255 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22256
22257         * modules/strsep: New file.
22258
22259 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22260
22261         * m4/strsep.m4: New file.
22262
22263 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22264
22265         * lib/strsep.h: New file.
22266         * lib/strsep.c: New file.
22267
22268 2004-10-01  Simon Josefsson  <jas@extundo.com>
22269
22270         * lib/snprintf.c (snprintf): Handle size==0.
22271
22272 2004-10-01  Simon Josefsson  <jas@extundo.com>
22273             Bruno Haible  <bruno@clisp.org>
22274
22275         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
22276         (snprintf): Declare 'args'.
22277
22278 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
22279
22280         * lib/snprintf.c: Remove comments as to why each header is needed.
22281
22282 2004-10-01  Bruno Haible  <bruno@clisp.org>
22283
22284         * MODULES.html.sh: Add strsep.
22285
22286 2004-09-30  Simon Josefsson  <jas@extundo.com>
22287
22288         * modules/snprintf: New file.
22289
22290 2004-09-30  Simon Josefsson  <jas@extundo.com>
22291
22292         * m4/snprintf.m4: New file.
22293
22294 2004-09-30  Simon Josefsson  <jas@extundo.com>
22295
22296         * lib/snprintf.h, lib/snprintf.c: New files.
22297
22298 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
22299
22300         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
22301         (hol_entry_help): Never translate an empty string.
22302         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
22303         * lib/argp.h (OPTION_NO_TRANS): New option.
22304
22305 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
22306
22307         * modules/argp (Maintainer): Replace Simon Josefsson
22308         by Sergey Poznyakoff.
22309
22310 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
22311
22312         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
22313         changes merged back into glibc.
22314
22315 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
22316
22317         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
22318
22319 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
22320
22321         * lib/xvasprintf.c: Include xalloc.h.
22322         (xvasprintf): Use xalloc_die, not xmalloc_die.
22323
22324 2004-09-29  Bruno Haible  <bruno@clisp.org>
22325
22326         * modules/alloca-opt: New file, derived from modules/alloca.
22327         * modules/allocsa: Depend on alloca-opt instead of alloca.
22328         * modules/setenv: Likewise.
22329         * modules/vasnprintf: Likewise.
22330         * MODULES.html.sh: Add alloca-opt.
22331
22332 2004-09-28  Simon Josefsson  <jas@extundo.com>
22333
22334         * gnulib-tool: New parameter --lgpl, to asseert that modules are
22335         LGPL, and to replace license template from GPL to LGPL.
22336
22337 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
22338
22339         * modules/dummy: Change license to LGPL.
22340
22341 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
22342
22343         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
22344
22345 2004-09-24  Simon Josefsson  <jas@extundo.com>
22346
22347         * modules/minmax (License): Change from GPL to LGPL.
22348
22349 2004-09-23  Simon Josefsson  <jas@extundo.com>
22350
22351         * gnulib-tool (--import): Typo.
22352
22353 2004-09-23  Simon Josefsson  <jas@extundo.com>
22354
22355         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
22356
22357 2004-09-22  Bruno Haible  <bruno@clisp.org>
22358
22359         * modules/*: Add 'License' field.
22360         * gnulib-tool: Accept --extract-license option.
22361         (func_get_license): New function.
22362
22363 2004-09-21  Bruno Haible  <bruno@clisp.org>
22364
22365         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
22366         Reported by Simon Josefsson.
22367
22368 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
22369
22370         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
22371         gl_AC_TYPE_LONG_LONG.
22372
22373 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
22374
22375         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
22376
22377 2004-09-18  Simon Josefsson  <jas@extundo.com>
22378         and  Paul Eggert  <eggert@cs.ucla.edu>
22379
22380         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
22381         calls with autoreconf.  Define GL_LIB.
22382
22383 2004-09-14  Karl Berry  <karl@gnu.org>
22384
22385         * config/srclist.txt: unsync setenv.c, sigh.
22386
22387 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
22388
22389         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
22390         Problem reported by Bruno Haible in:
22391         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
22392
22393 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
22394
22395         * config/srclist.txt: Comment out argp-pvh.c.
22396
22397 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
22398
22399         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
22400         in case some system header has #define'd it.  Problem reported by
22401         Soeren D. Schulze in
22402         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
22403
22404 2004-09-09  Karl Berry  <karl@gnu.org>
22405
22406         * regex.[ch]: delete from the root.  These were supposed to be
22407                 synced with emacs cvs, but this has not happened for about
22408                 a year, and anyway nothing else uses emacs regex.[ch].
22409                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
22410                 lib/regex[.ch] is untouched.
22411
22412 2004-09-09  Bruno Haible  <bruno@clisp.org>
22413
22414         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
22415
22416 2004-09-09  Bruno Haible  <bruno@clisp.org>
22417
22418         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
22419         modifications.
22420         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
22421
22422 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
22423
22424         * modules/xvasprintf: New file.
22425         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
22426
22427 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
22428
22429         * lib/xvasprintf.h: New file.
22430         * lib/xvasprintf.c: New file.
22431         * lib/xasprintf.c: New file.
22432
22433 2004-09-08  Bruno Haible  <bruno@clisp.org>
22434
22435         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
22436
22437 2004-09-08  Bruno Haible  <bruno@clisp.org>
22438
22439         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
22440         length is > INT_MAX.
22441         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
22442         more.
22443
22444 2004-09-08  Bruno Haible  <bruno@clisp.org>
22445
22446         * lib/stdint_.h: New file, taken from GNU clisp.
22447
22448 2004-09-08  Bruno Haible  <bruno@clisp.org>
22449             Oskar Liljeblad  <oskar@osk.mine.nu>
22450
22451         * modules/stdint: New file.
22452         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
22453
22454 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
22455
22456         Import from coreutils.
22457         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
22458         strings on unbounded length.  alloca's performance benefits aren't
22459         that important here.
22460         (V_STRDUP): Remove.
22461         (parse_with_separator): New function, with most of the internals
22462         of the old parse_user_spec.  Allow user to omit both user and group,
22463         for compatibility with FreeBSD.
22464         Clone only the user name, not the entire spec.
22465         Do not set *uid, *gid unless entirely successful.
22466         Avoid memory leak in some failing cases.
22467         Fix regression for USER.GROUP reported by Dmitry V. Levin in
22468         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
22469         (parse_user_spec): Rewrite to use parse_with_separator.
22470
22471 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
22472
22473         * modules/userspec: Don't depend on alloca.
22474
22475 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
22476
22477         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
22478
22479 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
22480
22481         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
22482         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
22483         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
22484
22485 2004-08-16  Simon Josefsson  <jas@extundo.com>
22486
22487         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
22488         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
22489         Add --dry-run for --import.
22490         Let user provided command line parameters override configure.ac
22491         settings.
22492
22493 2004-08-12  Simon Josefsson  <jas@extundo.com>
22494
22495         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
22496         as discussed with Paul Eggert in threads rooted at
22497         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
22498         and
22499         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
22500         Before, the test was empty, and relied on ELIDE_CODE in source
22501         code.)
22502         (gl_PREREQ_GETOPT): New macro.
22503         (gl_GETOPT): Use them.
22504
22505 2004-08-12  Simon Josefsson  <jas@extundo.com>
22506
22507         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
22508         * lib/getopt_.h: Renamed from getopt.h.
22509
22510 2004-08-12  Simon Josefsson  <jas@extundo.com>
22511
22512         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
22513         Change default library name from libfoo to libgnu.
22514         Now, if you have a configure.ac that says:
22515                 gl_SOURCE_BASE(gl)
22516                 gl_M4_BASE(gl/m4)
22517                 gl_MODULES(error getopt etcetera)
22518                 gl_INIT
22519         you can import all you need by running:
22520                 ../gnulib/gnulib-tool --import
22521
22522         * modules/getopt (Files): Rename getopt.h to getopt_.h.
22523         (Makefile.am): Rewrite, use logic from argz.
22524         (Include): Use <getopt.h> instead of "getopt.h".
22525
22526 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22527
22528         * modules/argp (Files): Add m4/unlocked-io.m4.
22529         (Depends-on): Add extensions.
22530
22531 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22532
22533         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
22534         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
22535         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
22536         Check for program_invocation_name, program_invocation_short_name,
22537         flockfile, funlockfile, features.h, _getopt_long_only_r.
22538
22539 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22540
22541         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
22542         its complicated substitute.
22543         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
22544         and program_invocation_name.
22545         (__argp_basename) [!_LIBC]: Remove; the only use was
22546         replaced by its body.
22547         (__argp_short_program_name): Change condition from
22548         !defined __argp_short_program_name to
22549         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
22550         to match argp-namefrob.h.
22551         (__argp_failure): Don't assume strerror_r returns char *.
22552         * lib/argp-parse.c (N_): Define unconditionally.
22553         (argp_default_options): Fill out initializers with 0 to avoid
22554         gcc warnings.
22555
22556 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22557
22558         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
22559         getopt1.c.
22560
22561 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
22562
22563         Merge from coreutils.
22564
22565         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
22566
22567         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
22568         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
22569
22570 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
22571
22572         Merge from coreutils.
22573
22574         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
22575         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
22576         for Reliant Unix 5.43.
22577
22578         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
22579         (union fooround): Use uintmax_t, not long int.
22580         The rest is a merge from libc:
22581         [defined _LIBC]: Include <shlib-compat.h>.
22582         (_obstack) [defined _LIBC]: Remove after 2.3.4.
22583
22584         * lib/settime.c (settime): Recode to avoid warning with
22585         Sun Forte C 6U2.
22586
22587         * lib/strverscmp.c: Convert to UTF-8.
22588
22589 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
22590
22591         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
22592         m4/uintmax_t.m4.
22593
22594 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
22595
22596         * modules/xalloc-die: New file.
22597         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
22598
22599         * modules/md5 (Files): Add m4/uint32_t.m4.
22600         * modules/sha1: Renamed from modules/sha.
22601         (Files):
22602         Rename lib/sha.h to lib/sha1.h.
22603         Rename lib/sha.c to lib/sha1.c.
22604         Rename m4/sha.m4 to m4/sha1.m4.
22605         (lib_SOURCES): Likewise.
22606         (configure.ac): Rename gl_SHA to gl_SHA1.
22607         (Include): sha.h -> sha1.h.
22608
22609 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
22610
22611         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
22612         * m4/sha1.m4: Renamed from sha.m4.
22613         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
22614
22615 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
22616
22617         * lib/obstack.h (obstack_empty_p):
22618         Don't assume that chunk->contents is suitably aligned.
22619         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
22620         Likewise. Problem reported by Benno in
22621         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
22622
22623         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
22624         readable.  This could be improved further but it'd take some work.
22625
22626 2004-08-08  Simon Josefsson  <jas@extundo.com>
22627
22628         * modules/xgethostname (Depends-on): Remove exit and error (not
22629         used).
22630
22631         * modules/getpass-gnu: Add getpass.h.
22632         (Depends-on): Add stdbool.
22633         * modules/getpass: Add getpass.h.
22634
22635 2004-08-08  Simon Josefsson  <jas@extundo.com>
22636
22637         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
22638         Check getpass declaration.
22639
22640 2004-08-08  Simon Josefsson  <jas@extundo.com>
22641
22642         * lib/xgethostname.c: Don't include error.h (not used).
22643
22644         * lib/getpass.h: Add.
22645         * lib/getpass.c: Include getpass.h first.
22646
22647 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
22648
22649         * lib/xalloc-die.c: New file.
22650         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
22651         All uses removed.
22652         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
22653         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
22654         xalloc-die.c.
22655         (_, N_, xalloc_die): Move to xalloc-die.c.
22656         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
22657         so that we needn't mess with xalloc_msg_memory_exhausted.
22658
22659         * lib/sha1.h: Renamed from sha.h.
22660         (SHA1_H): Renamed from _SHA_H.
22661         (sha1_ctx): Renamed from sha_ctx.
22662         (sha1_init_ctx): Renamed from sha_init_ctx.
22663         (sha1_process_block): Renamed from sha_process_block.
22664         (sha1_process_bytes): Renamed from sha_process_bytes.
22665         (sha1_finish_ctx): Renamed from sha_finish_ctx.
22666         (sha1_read_ctx): Renamed from sha_read_ctx.
22667         (sha1_stream): Renamed from sha_stream.
22668         (sha1_buffer): Renamed from sha_buffer.
22669         * lib/sha1.c: Likewise; renamed from sha.c.
22670         Do not include <sys/types.h>.
22671         Include <stddef.h> rather than <stdlib.h>.
22672
22673 2004-08-08  Bruno Haible  <bruno@clisp.org>
22674
22675         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
22676         FILESYSTEM_PREFIX_LEN.
22677         * lib/progreloc.c: Likewise.
22678         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
22679
22680 2004-08-06  Simon Josefsson  <jas@extundo.com>
22681
22682         * modules/progname (Depends-on): Don't depend on stdbool.
22683
22684 2004-08-06  Simon Josefsson  <jas@extundo.com>
22685
22686         * modules/getsubopt: New file.
22687         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
22688         getsubopt.
22689
22690 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22691
22692         More merge from coreutils.
22693
22694         * m4/utimens.m4, m4/utimecmp.m4: New files.
22695         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
22696         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
22697         prereq.m4, sha.m4: Import changes from coreutils.
22698
22699 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22700
22701         More merge from coreutils.
22702         * modules/raise, modules/readtokens0, modules/utimens:
22703         * modules/utimecmp, module/xnanosleep: New files.
22704         * modules/strftime: Add lib/strftime.h.
22705         Change include from <time.h> to "strftime.h".
22706         * modules/yesno: Add lib/yesno.h.
22707         * modules/backupfile: Remove lib/addext.c.
22708         * modules/euidaccess: Add stat-macros.h.
22709         * modules/canonicalize, modules/euidaccess,
22710         modules/filemode, modules/lchown, modules/makepath,
22711         modules/rmdir, modules/stat: Likewise.
22712
22713 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22714
22715         Merge from tar.
22716         * lib/argp-help.c (make_hol, hol_append): Don't assume that
22717         SIZE_MAX is a valid preprocessor constant.
22718         (__argp_basename): Change from "#ifndef _LIBC"
22719         to "#ifndef __argp_short_program_name", so that
22720         we don't compile these functions for tar.
22721
22722         More merges from coreutils.
22723         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
22724         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
22725         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
22726         * lib/addext.c: Remove; no longer needed.
22727         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
22728         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
22729         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
22730         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
22731         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
22732         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
22733         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
22734         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
22735         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
22736         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
22737         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
22738         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
22739         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
22740         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
22741         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
22742         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
22743         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
22744         Import changes from coreutils.
22745
22746 2004-08-05  Simon Josefsson  <jas@extundo.com>
22747
22748         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
22749
22750 2004-08-05  Simon Josefsson  <jas@extundo.com>
22751
22752         * m4/getsubopt.m4: New file.
22753
22754 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22755
22756         Merge from coreutils.
22757
22758         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
22759         * m4/getcwd-path-max.m4: New files.
22760
22761         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
22762         FILESYSTEM_PREFIX_LEN ->
22763         FILE_SYSTEM_PREFIX_LEN.
22764         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
22765         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
22766         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
22767         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
22768
22769         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
22770         prerequisite modules now handle the DOS stuff.
22771         Don't check for unistd.h.
22772
22773 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22774
22775         Merge from coreutils.
22776
22777         * lib/.gdb-history: Remove; this doesn't belong here.
22778
22779         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
22780         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
22781         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
22782         * lib/getcwd.c: New files.
22783
22784         * lib/dirname.h: Include <stdbool.h>.
22785         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
22786         for consistency with POSIX terminology.  All uses changed.
22787         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
22788         (strip_trailing_slashes): Use bool for booleans.
22789         * lib/stripslash.c (strip_trailing_slashes): Likewise.
22790
22791         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
22792         sometimes returns a positive errno value even when it succeeds.
22793         (print_errno_message) [!LIBC]: Fall back on strerror if
22794         __strerror_r fails.
22795
22796         * lib/path-concat.c (mempcpy): Don't define if a system header defines
22797         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
22798         (longest_relative_suffix): New function.
22799         (path_concat): Use it.  Assume first argument is not NULL.
22800         Port to DOS.  Omit redundant separators.
22801         Report an error instead of returning NULL.
22802         Use mempcpy instead of memcpy.
22803         (xpath_concat): Remove: not declared or used.
22804
22805         * lib/same.h: Include <stdbool.h>
22806         (same_name): Return bool, not int.
22807         * lib/same.c (same_name): Likewise.
22808         (errno): Don't declare; we assume C89 or better now.
22809
22810         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
22811         if not already defined.
22812
22813         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
22814         * lib/dup-safer.c (errno): Likewise.
22815
22816 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22817
22818         Merge from coreutils.
22819         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
22820         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
22821         * modules/path-concat: Don't depend on strdup.
22822
22823 2004-08-03  Simon Josefsson  <jas@extundo.com>
22824
22825         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
22826         * lib/progname.h: Don't include stdbool.h.
22827
22828 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22829
22830         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
22831         * MODULES.html.sh (func_all_modules): Remove fatal.
22832
22833 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22834
22835         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
22836
22837 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22838
22839         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
22840         working.
22841
22842 2004-08-02  Simon Josefsson  <jas@extundo.com>
22843
22844         * lib/getsubopt.h: New file, with comments from Bruno Haible.
22845         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
22846         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
22847
22848 2004-08-01  Simon Josefsson  <jas@extundo.com>
22849
22850         * lib/xgetdomainname.c: Include stdlib.h, for free().
22851
22852 2004-07-19  Bruno Haible  <bruno@clisp.org>
22853
22854         * MODULES.html.sh (func_all_modules): Add dummy.
22855
22856 2004-07-16  Simon Josefsson  <jas@extundo.com>
22857
22858         * modules/dummy: New file.
22859
22860 2004-07-16  Simon Josefsson  <jas@extundo.com>
22861
22862         * lib/dummy.c: New file.
22863
22864 2004-07-16  Bruno Haible  <bruno@clisp.org>
22865
22866         * lib/backupfile.h: Add extern "C" for C++.
22867         * lib/closeout.h: Likewise.
22868         * lib/copy-file.h: Likewise.
22869         * lib/findprog.h: Likewise.
22870         * lib/full-write.h: Likewise.
22871         * lib/pathname.h: Likewise.
22872         * lib/progname.h: Likewise.
22873         * lib/stpcpy.h: Likewise.
22874         * lib/stpncpy.h: Likewise.
22875         * lib/strcase.h: Likewise.
22876         * lib/strstr.h: Likewise.
22877         * lib/xalloc.h: Likewise.
22878
22879         * lib/mbswidth.h: Add extern "C" for C++.
22880         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
22881
22882 2004-07-13  Robert Millan  <robertmh@gnu.org>
22883
22884         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
22885
22886 2004-07-09  Simon Josefsson  <jas@extundo.com>
22887
22888         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
22889         failed without this.)
22890
22891 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
22892
22893         * modules/chown (Files): Add lib/fchown-stub.c, since
22894         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
22895
22896 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
22897
22898         * lib/fchown-stub.c: New file.
22899
22900 2004-06-24  Jim Meyering  <jim@meyering.net>
22901
22902         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
22903
22904 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22905
22906         * modules/argz: Omit "#include".
22907
22908         * MODULES.html.sh (func_all_modules): Add calloc, to match
22909         2004-06-01 addition of calloc module.
22910
22911 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22912
22913         * m4/argz.m4: New file, which is autoupdated from libtool.
22914
22915 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22916
22917         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
22918         libtool.
22919
22920 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
22921
22922         * config/srclist-update: Don't insist on "USA." before the
22923         close-comment, as libtool omits the period and puts the */ on a
22924         separate line.
22925         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
22926         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
22927
22928 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
22929
22930         * modules/argz: New file.
22931         * MODULES.html.sh (func_all_modules): Add argz.
22932
22933 2004-06-12  Jim Meyering  <jim@meyering.net>
22934         and  Paul Eggert  <eggert@cs.ucla.edu>
22935
22936         * modules/hash (Files): Add lib/xalloc.h.
22937         * modules/pipe (Depends-on): Add wait-process.
22938         * modules/stat (Depends-on): Add xalloc.
22939         * modules/userspec (Files): Add lib/userspec.h.
22940         * modules/xstrto
22941
22942         Upgrade from gettext-0.13.
22943         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
22944         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
22945         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
22946
22947 2004-06-10  Jim Meyering  <jim@meyering.net>
22948
22949         * lib/calloc.c: New file.
22950
22951 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
22952
22953         * lib/getdate.y (yylex): Allow space between sign and number.
22954         Problem reported by Dan Jacobson.
22955
22956 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
22957
22958         Merge from coreutils CVS.
22959
22960         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
22961         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
22962         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
22963         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
22964         xstrtol.m4: Fix copyright date and/or serial number.
22965
22966         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
22967         See if we need an fchown replacement.
22968         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
22969         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
22970         and use the replacement function if we detect either defect.
22971
22972         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
22973         gl_UTIMECMP.
22974
22975 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
22976         and  Jim Meyering  <jim@meyering.net>
22977
22978         Merge from coreutils CVS.
22979
22980         * lib/stat-macros.h: New file, with contents from file-type.h
22981         and coreutils' system.h.
22982         * lib/file-type.c: Include "stat-macros.h".
22983         * lib/file-type.h (file_type): Move all macro definitions to new file,
22984         stat-macros.h.
22985
22986         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
22987         Wrap old code with this conditional.
22988         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
22989         function that does not dereference symlinks.
22990         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
22991
22992         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
22993         dependency problems.
22994         (xreadlink): Accept new arg SIZE, for efficiency.
22995         All decls and uses changed.
22996         * lib/xreadlink.h: Include <stddef.h>, for size_t.
22997
22998         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
22999         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
23000
23001         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
23002         sysexits.h.
23003
23004 2004-06-01  Jim Meyering  <jim@meyering.net>
23005
23006         * m4/calloc.m4: New file.
23007
23008 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
23009
23010         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
23011         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
23012         Also, fix a typo in a diagnostic.
23013
23014 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
23015
23016         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
23017         or AC_FUNC_REALLOC.
23018
23019 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
23020
23021         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
23022         macros to be defined.
23023         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
23024         the allocator returns NULL because the requested size is zero.
23025
23026 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
23027
23028         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
23029         var.  Add comment explaining why libc still defines it.  This
23030         merges the following patch from glibc:
23031         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
23032
23033 2004-05-20  Andreas Schwab  <schwab@suse.de>
23034
23035         * m4/free.m4: Replace free if it not known to work, not the other
23036         way round.
23037
23038 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
23039
23040         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
23041         present in glibc since revision 1.1 of this file.
23042         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
23043         obstack_alignment_mask, obstack_alloc, obstack_base,
23044         obstack_blank, obstack_blank_fast, obstack_chunk_size,
23045         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
23046         obstack_grow0, obstack_init, obstack_int_grow,
23047         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
23048         obstack_next_free, obstack_object_size, obstack_ptr_grow,
23049         obstack_ptr_grow_fast, obstack_room): Remove declarations of
23050         nonexistent functions.
23051
23052 2004-05-18  Karl Berry  <karl@gnu.org>
23053
23054         * config/srclist.txt: break link for vasnprintf.c.
23055
23056 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
23057
23058         Port obstack to the AS/400, where pointers are 16 bytes wide and
23059         you cannot cast an integer to a valid pointer.  This patch is
23060         currently waiting to be integrated into glibc; see
23061         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
23062
23063         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
23064         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
23065         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
23066         (struct obstack): temp member is now a union of a pointer and
23067         an integer, instead of an integer.  All integer uses changed.
23068         This does not affect the physical layout of struct obstack,
23069         except on hosts (like the AS/400) where the size or alignment of
23070         void * is greater than that of ptrdiff_t.
23071         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
23072         __STDC__)]: Store temporary in pointer member of union, not
23073         integer member.
23074         * lib/obstack.c: Include <stddef.h>, for offsetof.
23075         (struct fooalign): Remove; it doesn't need a name.
23076         (union fooround): Change double to long double, and add void *.
23077         (DEFAULT_ALIGNMENT): Use offsetof to compute.
23078         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
23079         not a macro.  Hence the values are always int; so remove all
23080         casts-to-int in uses.
23081
23082 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
23083
23084         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
23085         we can get this patch merged into glibc.
23086
23087 2004-05-17  Derek R. Price  <derek@ximbiot.com>
23088             Paul Eggert  <eggert@cs.ucla.edu>
23089
23090         * m4/argp: Depend on alloca.
23091
23092 2004-05-17  Derek R. Price  <derek@ximbiot.com>
23093             Paul Eggert  <eggert@cs.ucla.edu>
23094
23095         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
23096         freecoding.
23097
23098 2004-05-17  Bruno Haible  <bruno@clisp.org>
23099
23100         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
23101         precision that consists of a '.' followed by an empty digit string.
23102         Patch by Tor Lillqvist <tml@iki.fi>.
23103
23104 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
23105
23106         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
23107         for backward compatibility with older code.  We need our own
23108         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
23109         it under some other name, and our alloca.h will define it.
23110
23111 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
23112             Derek Price  <derek@ximbiot.com>
23113
23114         * lib/alloca.c: Include <alloca.h>, to get our interface.
23115         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
23116         include <alloca.h> first.  Use C89 prototype for alloca; this
23117         requires including <stddef.h> for size_t.  Use extern "C" if C++.
23118         Use #elif for simplicity, since we can assume C89 now.
23119         Don't try to source the system alloca.h since it will not be found
23120         and to prevent recursively including its replacement.
23121         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
23122         * lib/regex.c: Likewise.
23123
23124 2004-05-16  Derek Price  <derek@ximbiot.com>
23125             Paul Eggert  <eggert@cs.ucla.edu>
23126
23127         getline cleanup.  This changes the getndelim2 API: both order of
23128         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
23129         no delimiter).
23130
23131         * lib/getline.c: Don't include stddef.h or stdio.h, since our
23132         interface does that.
23133         (getline): Always use getdelim, so that we don't have two
23134         copies of this code.
23135         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
23136         if available.
23137         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
23138         (GETNDELIM2_MAXIMUM): New macro.
23139         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
23140         instead of the old practice of delim2==0.  All callers changed.
23141         Return -1 on overflow, instead of returning junk.
23142         Do not set *linesize unless allocation succeeds.
23143         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
23144         that we include sys/types.h.
23145         * lib/getnline.h: Likewise.
23146         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
23147         (getndelim2): Reorder arguments.
23148         * lib/getnline.c (getnline, getndelim):
23149         Don't discard the NMAX argument.
23150         (getnline): Invoke getndelim, to avoid code duplication.
23151         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
23152         of (size_t) -1 by callers of the getnline family.
23153
23154 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
23155
23156         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
23157         Check for gettimeofday.
23158         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
23159         Check for settimeofday, stime.
23160
23161 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
23162
23163         * lib/nanosleep.c (suspended): Change its type from int to
23164         sig_atomic_t volatile.
23165         (first_call): Make it private to rpl_nanosleep, and have it
23166         be zero initially as that's a bit faster.
23167         (my_usleep): Round up fractional times instead of truncating them,
23168         as this is the usual meaning for 'sleep'.
23169
23170         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
23171         doesn't work.
23172         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
23173         (ENOSYS): Define if not defined.
23174         (settime): Fall back on stime if it exists and settimeofday fails.
23175         But don't bother with fallbacks if a method fails with errno == EPERM.
23176
23177 2004-05-11  Jim Meyering  <jim@meyering.net>
23178
23179         Prior to this change, the save_cwd caller required read access to the
23180         current directory on most systems (ones with the fchdir function).
23181
23182         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
23183         fails, try write-only, and finally, resort to using xgetcwd.
23184
23185 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
23186
23187         * lib/obstack.c, obstack.h: Import changes from libc.
23188
23189 2004-04-28  Bruno Haible  <bruno@clisp.org>
23190
23191         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
23192         also implicitly appends .exe to executables.
23193         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
23194         accepts Windows pathnames.
23195         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
23196         Treat Cygwin like Windows, since it now accepts Windows pathnames.
23197         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
23198         Treat Cygwin like Windows, since it now accepts Windows pathnames.
23199         Reported by Derek Robert Price <derek@ximbiot.com>.
23200
23201 2004-04-21  Karl Berry  <karl@gnu.org>
23202
23203         * config/srclist.txt (localcharset.c): break sync.
23204
23205 2004-04-20  Paul Eggert  <eggert@twinsun.com>
23206
23207         * m4/host-os.m4: Add a copyright notice.
23208
23209 2004-04-20  Jim Meyering  <jim@meyering.net>
23210
23211         Change UTILS_ to gl_ in AC_DEFINE'd names.
23212         Change utils_- and jm_-prefixed variables, too.
23213         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
23214         UTILS_FUNC_MKDIR_TRAILING_SLASH.
23215         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
23216
23217         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
23218         Don't emit trailing blanks.
23219         Also rename jm_-prefixed variables to have gl_ prefix.
23220
23221         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
23222         Also rename jm_-prefixed variables to have gl_ prefix.
23223
23224         * m4/jm-macros.m4: Reflect the renamings.
23225         * m4/prereq.m4: Likewise.
23226
23227 2004-04-20  Jim Meyering  <jim@meyering.net>
23228
23229         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
23230         memory.
23231
23232 2004-04-20  Jim Meyering  <jim@meyering.net>
23233             Bruno Haible  <bruno@clisp.org>
23234
23235         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
23236         memory when realloc fails.
23237
23238 2004-04-19  Jim Meyering  <jim@meyering.net>
23239
23240         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
23241         now that readutmp.c may call `free (0)'.
23242
23243 2004-04-19  Bruno Haible  <bruno@clisp.org>
23244
23245         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
23246         * m4/inttypes_h.m4: Likewise.
23247         * m4/stdint_h.m4: Likewise.
23248         * m4/intmax_t.m4: Likewise.
23249         * m4/uintmax_t.m4: Likewise.
23250
23251 2004-04-18  Jim Meyering  <jim@meyering.net>
23252
23253         * m4/prereq.m4: Don't forbid jm_ prefix.
23254
23255         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
23256         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
23257         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
23258         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
23259         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
23260         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
23261         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
23262         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
23263         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
23264         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
23265         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
23266         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
23267         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
23268         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
23269         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
23270         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
23271         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
23272         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
23273         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
23274
23275 2004-04-18  Jim Meyering  <jim@meyering.net>
23276
23277         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
23278         failure, don't leak memory and do call END_UTMP_ENT.
23279
23280 2004-04-16  Jim Meyering  <jim@meyering.net>
23281
23282         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
23283         coreutils' stat program.
23284         (gl_PREREQ): Don't require jm_PREREQ_STAT.
23285
23286 2004-04-11  Paul Eggert  <eggert@twinsun.com>
23287
23288         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
23289         C89.
23290         (CHAR_BIT): Remove, since we assume C89.
23291         Include <stdint.h> if available, as per current Autoconf CVS advice.
23292
23293 2004-03-31  Jim Meyering  <jim@meyering.net>
23294
23295         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
23296         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
23297         * m4/xalloc.m4: Likewise.
23298
23299 2004-03-30  Paul Eggert  <eggert@twinsun.com>
23300
23301         Merge from coreutils.
23302
23303         * m4/inttostr.m4: New file.
23304         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
23305         Require AM_STDBOOL_H and gl_TIMESPEC instead.
23306         Require gl_CLOCK_TIME.
23307         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
23308
23309 2004-03-30  Paul Eggert  <eggert@twinsun.com>
23310
23311         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
23312         not bool, to be more consistent with Unix conventions.
23313         Suggested by Bruno Haible.
23314
23315         Merge from coreutils.
23316
23317         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
23318         * lib/umaxtostr.c: New files.
23319
23320         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
23321         the usual <time.h> dance.
23322         (get_date): Change signature to support fractional time stamps.
23323         All callers changed.
23324         * lib/getdate.y: Include "getdate.h" first, as we can now
23325         assume C89 and don't need to worry about 'const'.
23326         Similarly, include "unlocked-io.h" near start, not in middle.
23327         Include <limits.h>.
23328         (textint.value): Use long int rather than int.
23329         (textint.digits): Use size_t rather than int.
23330         (BILLION, LOG10_BILLION): New constants.
23331         (parser_control): New member rel_ns.  Members day_ordinal,
23332         time_zone, month, day, hour, minutes, rel_year, rel_month,
23333         rel_day, rel_hour, rel_minutes, rel_seconds
23334         are now long int, not int.  Member seconds is now struct timespec,
23335         not int.  New member timespec_seen.  Members dates_seen, days_seen,
23336         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
23337         not int.
23338         (%union.intval): Now long int, not int.
23339         New member timespec.
23340         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
23341         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
23342         (spec): Now is a timespec or an item list.
23343         (timespec, items): New nonterminals.
23344         (time, rel, relunit, number, get_date):
23345         Add support for fractional seconds.
23346         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
23347         (gmtime, localtime, mktime): Remove decls; not needed with C89.
23348         (to_hour): First arg is now long int, not int.
23349         (to_year): Returns long int, not int.
23350         Don't treat year -70 like 70.
23351         (tm_diff): Returns long int, not int.
23352         (lookup_word): Use bool instead of int when appropriate.
23353         (yylex): Use size_t for count, not int.
23354         Detect overflow when parsing large integer constants.
23355         Add support for fractions.
23356         (get_date): Make pointers 'const' if possible.
23357         Use more-portable code to detect integer overflow.
23358         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
23359         Don't use ctime; it's not reliable if the year has >4 digits.
23360
23361         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
23362         This is for compatibility with BSD.
23363
23364         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
23365         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
23366         From coreutils' system.h.
23367
23368         * lib/userspec.c: Don't include "posixver.h".
23369         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
23370         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
23371         compatible extension.  Simplify code by removing a boolean int
23372         that was always nonzero if a string was nonnull.
23373
23374 2004-03-30  Jim Meyering  <jim@meyering.net>
23375
23376         Merge from coreutils.
23377
23378         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
23379         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
23380         on some systems one must include <grp.h> before it.
23381         Reported by Christian Krackowizer.
23382
23383 2004-03-30  Jim Meyering  <jim@meyering.net>
23384
23385         Merge from coreutils.
23386
23387         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
23388
23389         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
23390         an empty input stream.
23391
23392         * lib/readtokens.c: Include <stdbool.h>.
23393         (readtoken): Use `size_t' rather than int/long.
23394         All callers adjusted.
23395         Use `bool' rather than `int' where appropriate.
23396         Use memset rather than an explicit loop.
23397         Use x2nrealloc rather than xrealloc.
23398         Allow the use of `\0' as a delimiter.
23399         (readtokens): Likewise.
23400         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
23401
23402 2004-03-30  Jim Meyering  <jim@meyering.net>
23403
23404         * m4/realloc.m4: Remove file, since now it does no more than
23405         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
23406         the `configure.ac' section of module/realloc.
23407         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
23408
23409 2004-03-30  Bruno Haible  <bruno@clisp.org>
23410
23411         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
23412         nonnull.
23413
23414 2004-03-29  Paul Eggert  <eggert@twinsun.com>
23415
23416         Merge changes to getloadavg.c from coreutils and Emacs.
23417
23418         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
23419         Define to an expression, not to the empty string.
23420         Include cloexec.h and xalloc.h.
23421         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
23422         Use set_cloexec_flag rather than rolling our own.
23423         * lib/cloexec.c, lib/cloexec.h: New files.
23424
23425 2004-03-29  Paul Eggert  <eggert@twinsun.com>
23426
23427         * m4/cloexec.m4: New file.
23428
23429 2004-03-18  Paul Eggert  <eggert@twinsun.com>
23430
23431         * lib/getopt.h: Sync with libc CVS.
23432
23433 2004-03-18  Paul Eggert  <eggert@twinsun.com>
23434             Bruno Haible  <bruno@clisp.org>
23435
23436         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
23437         mbswidth.
23438
23439 2004-03-18  Paul Eggert  <eggert@twinsun.com>
23440             Bruno Haible  <bruno@clisp.org>
23441
23442         * lib/mbswidth.h: Include <wchar.h> only if
23443         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
23444         <wchar.h>.
23445         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
23446
23447 2004-03-09  Paul Eggert  <eggert@twinsun.com>
23448
23449         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
23450         Sync with libc CVS.
23451         * lib/getopt_int.h: New file, also synced from libc.
23452
23453 2004-03-09  Paul Eggert  <eggert@twinsun.com>
23454
23455         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
23456         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
23457         Bring back getopt.c, getopt.h, getopt1.c.
23458
23459 2004-03-07  Paul Eggert  <eggert@twinsun.com>
23460
23461         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
23462         All uses changed.  Check for sa_sigaction member; this fixes
23463         a bug first reported by Jason Andrade in
23464         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
23465
23466 2004-03-07  Paul Eggert  <eggert@twinsun.com>
23467
23468         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
23469         '#if' expressions.  Unlike the code it replaces, it does not
23470         depend on (defined _SC_PAGESIZE).  However, it does depend on
23471         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
23472         first reported by Jason Andrade in
23473         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
23474
23475 2004-02-25  Simon Josefsson  <jas@extundo.com>
23476
23477         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
23478
23479 2004-02-25  Simon Josefsson  <jas@extundo.com>
23480
23481         * lib/strdup.h: New file.
23482         * lib/strdup.c: Include it.
23483         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
23484         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
23485
23486 2004-02-23  Karl Berry  <karl@gnu.org>
23487
23488         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
23489         (from fencepost.gnu.org:/gd/gnuorg).
23490
23491 2004-02-23  Karl Berry  <karl@gnu.org>
23492
23493         * config/srclistvars.sh (GNUORG) [karl]: redefine.
23494         * config/srclist.txt: add maintain/standards documents.
23495
23496 2004-02-18  Bruno Haible  <bruno@clisp.org>
23497
23498         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
23499         Reported by Derek Robert Price <derek@ximbiot.com>.
23500
23501 2004-02-16  Karl Berry  <karl@gnu.org>
23502
23503         * config/mkinstalldirs, install-sh: update from automake.
23504
23505 2004-02-06  Karl Berry  <karl@gnu.org>
23506
23507         * m4/po.m4: update from gettext 0.14.1.
23508
23509 2004-02-06  Karl Berry  <karl@gnu.org>
23510
23511         * lib/config.charset: update from gettext 0.14.1.
23512
23513 2004-02-05  Paul Eggert  <eggert@twinsun.com>
23514
23515         Add comments and code, prompted by suggestions from Bruno Haible
23516         for sh-quote.
23517         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
23518         describing the enum quoting_style values.
23519         * lib/quotearg.c (quotearg_alloc): New function.
23520         (quotearg_buffer_restyled): Treat lone { and } as special.
23521         Treat = as special.  Work around bug with older shells
23522         that "see" a '\' that is really the 2nd byte of a multibyte char.
23523         Quote empty string with shell_quoting_style.
23524
23525 2004-02-03  Bruno Haible  <bruno@clisp.org>
23526
23527         * m4/pipe.m4: New file, from GNU gettext.
23528
23529 2004-02-03  Bruno Haible  <bruno@clisp.org>
23530
23531         * lib/pipe.h: New file, from GNU gettext.
23532         * lib/pipe.c: New file, from GNU gettext.
23533
23534 2004-01-27  Bruno Haible  <bruno@clisp.org>
23535
23536         * m4/execute.m4: New file, from GNU gettext.
23537
23538 2004-01-27  Bruno Haible  <bruno@clisp.org>
23539
23540         * lib/execute.h: New file, from GNU gettext.
23541         * lib/execute.c: New file, from GNU gettext.
23542         * lib/w32spawn.h: New file, from GNU gettext.
23543
23544 2004-01-24  Paul Eggert  <eggert@twinsun.com>
23545
23546         Merge from diffutils.
23547
23548         * lib/file-type.c (file_type): Add typed memory objects.
23549         * lib/file-type.h (S_TYPEISTMO): New macro.
23550
23551         * lib/c-stack.h (c_stack_action): Remove argv argument.
23552         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
23553         (die): Don't calculate message unless segv_action returns.
23554         (get_stack_location, min_address_from_argv, max_address_from_argv,
23555         volatile stack_base, volatile_stack_size): Remove.
23556         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
23557         that every segmentation violation is a stack overflow.  (Ouch!)
23558         See Debian bug 136249 (still outstanding) for more info about why
23559         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
23560
23561 2004-01-24  Paul Eggert  <eggert@twinsun.com>
23562
23563         Exit-status fix from coreutils.
23564
23565         Use exit_failure consistently in place of EXIT_FAILURE,
23566         so that program exit statuses are consistent on failure.
23567
23568         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
23569         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
23570         * lib/argmatch.h: Comment fix to match the above.
23571         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
23572         Now a macro referring to exit_failure, instead of a separate
23573         variable.  Include "exitfail.h" to get it.
23574         * lib/xstrtol.h: Include "exitfail.h".
23575         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
23576
23577         * lib/long-options.c (parse_long_options): Use prototype
23578         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
23579         for clarity.
23580
23581 2004-01-21  Jim Meyering  <jim@meyering.net>
23582
23583         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
23584         so as not to conflict with a different-sized __mktime_internal
23585         function in GNU libc.
23586         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
23587         Problem building statically-linked `ls' reported by Michael Brunnbauer.
23588
23589 2004-01-20  Karl Berry  <karl@gnu.org>
23590
23591         * config/config.guess: update from config.
23592
23593         * config/srclistvars.sh: GNUWWWLICENSES for karl.
23594
23595 2004-01-20  Bruno Haible  <bruno@clisp.org>
23596
23597         Safer stack allocation.
23598         * lib/setenv.c: Include allocsa.h.
23599         (alloca): Remove fallback definition.
23600         (freea): Remove macro.
23601         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
23602         instead of freea.
23603
23604 2004-01-20  Bruno Haible  <bruno@clisp.org>
23605
23606         * m4/eealloc.m4: New file, from GNU gettext.
23607
23608 2004-01-20  Bruno Haible  <bruno@clisp.org>
23609
23610         * m4/allocsa.m4: New file, from GNU gettext.
23611
23612 2004-01-20  Bruno Haible  <bruno@clisp.org>
23613
23614         * lib/xallocsa.h: New file, from GNU gettext.
23615         * lib/xallocsa.c: New file, from GNU gettext.
23616
23617 2004-01-20  Bruno Haible  <bruno@clisp.org>
23618
23619         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
23620
23621 2004-01-20  Bruno Haible  <bruno@clisp.org>
23622
23623         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
23624         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
23625         specially.
23626
23627 2004-01-20  Bruno Haible  <bruno@clisp.org>
23628
23629         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
23630         patch.
23631
23632 2004-01-20  Bruno Haible  <bruno@clisp.org>
23633
23634         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
23635
23636 2004-01-20  Bruno Haible  <bruno@clisp.org>
23637
23638         * lib/eealloc.h: New file.
23639
23640 2004-01-20  Bruno Haible  <bruno@clisp.org>
23641
23642         * lib/binary-io.h: Avoid warnings on Cygwin.
23643
23644 2004-01-20  Bruno Haible  <bruno@clisp.org>
23645
23646         * lib/allocsa.h: New file, from GNU gettext.
23647         * lib/allocsa.c: New file, from GNU gettext.
23648
23649 2004-01-18  Karl Berry  <karl@gnu.org>
23650
23651         * doc/gpl.texi, doc/lgpl.texi: new files.
23652
23653 2004-01-18  Karl Berry  <karl@gnu.org>
23654
23655         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
23656         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
23657
23658 2004-01-15  Paul Eggert  <eggert@twinsun.com>
23659
23660         Merge from coreutils.
23661
23662         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
23663         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
23664         (gl_DEFAULT_POSIX2_VERSION): Move
23665         the documentation from 'configure' into 'config.hin',
23666         so that 'configure --help' isn't burdened by it and
23667         we don't have to worry about its formatting there.
23668         Reword the documentation so that it's more succinct
23669         and can be run together into a single paragraph.
23670         * m4/same.m4 (gl_SAME): Check for pathconf.
23671
23672 2004-01-15  Paul Eggert  <eggert@twinsun.com>
23673
23674         Merge from coreutils.
23675
23676         * lib/posixver.c: Include posixver.h.
23677
23678         * lib/same.c: Include <stdbool.h>, <limits.h>.
23679         (_POSIX_NAME_MAX): Define if not defined.
23680         (MIN): New macro.
23681         (same_name): If file names are silently truncated, report
23682         that the file names are the same if they are the same after
23683         the silent truncation.
23684
23685         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
23686         conversion function.
23687         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
23688         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
23689         longer needed.
23690
23691 2004-01-15  Jim Meyering  <jim@meyering.net>
23692
23693         Merge from coreutils.
23694
23695         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
23696         if no library is required.
23697         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
23698         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
23699         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
23700         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
23701         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
23702         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
23703         value, $ac_cv_search_crypt, if it's "none required".
23704         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
23705         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
23706         not gl_FUNC_GETLOADAVG.
23707         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
23708         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
23709
23710 2004-01-15  Jim Meyering  <jim@meyering.net>
23711
23712         Merge from coreutils.
23713
23714         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
23715         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
23716         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
23717
23718         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
23719         optional configure-time default.
23720
23721         * lib/version-etc.c (version_etc_copyright): Update copyright date.
23722
23723         * lib/xreadlink.c (xreadlink): Correct outdated comment.
23724
23725 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
23726
23727         Merge from coreutils.
23728
23729         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
23730         value, $ac_cv_search_nanosleep, if it's "none required".
23731
23732 2004-01-14  Paul Eggert  <eggert@twinsun.com>
23733
23734         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
23735         with like-named macro in fnmatch.c.
23736         (EXT): Use an internal constant instead.
23737
23738         Merge fnmatch patches from glibc.
23739         * lib/fnmatch.c (mbsinit): Remove define.
23740         Add libc_hidden_ver (__fnmatch, fnmatch).
23741         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
23742         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
23743
23744 2004-01-14  Karl Berry  <karl@gnu.org>
23745
23746         * config/install-sh: update from automake.
23747
23748 2004-01-13  Karl Berry  <karl@gnu.org>
23749
23750         * config/install-sh: update from automake.
23751
23752 2004-01-09  Karl Berry  <karl@gnu.org>
23753
23754         * config/install-sh: update from automake.
23755
23756 2004-01-05  Karl Berry  <karl@gnu.org>
23757
23758         * config/config.{sub,guess}: update from config.
23759
23760 2003-12-31  Karl Berry  <karl@gnu.org>
23761
23762         * config/depcomp: update from automake.
23763
23764 2003-12-14  Karl Berry  <karl@gnu.org>
23765
23766         * lib/config.charset: update from gettext-runtime.
23767
23768 2003-12-03  Paul Eggert  <eggert@twinsun.com>
23769
23770         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
23771         Bug reported by Alfred M. Szmidt.
23772
23773 2003-12-03  Bruno Haible  <bruno@clisp.org>
23774
23775         * m4/gettext.m4: Upgrade from gettext-0.13.
23776         * m4/po.m4: Upgrade from gettext-0.13.
23777         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
23778         * m4/intmax.m4: New file, from gettext-0.13.
23779         * m4/printf-posix.m4: New file, from gettext-0.13.
23780
23781 2003-11-29  Karl Berry  <karl@gnu.org>
23782
23783         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
23784
23785 2003-11-25  Paul Eggert  <eggert@twinsun.com>
23786             Bruno Haible  <bruno@clisp.org>
23787
23788         * lib/printf-parse.h: Don't include sys/types.h.
23789         (ARG_NONE): New macro.
23790         (char_directive): Change type of *arg_index fields to size_t.
23791         * lib/printf-parse.c: Don't include sys/types.h.
23792         (SSIZE_MAX): Remove macro.
23793         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
23794         Remove unnecessary overflow check.
23795         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
23796         fields.
23797
23798 2003-11-25  Bruno Haible  <bruno@clisp.org>
23799
23800         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
23801
23802 2003-11-25  Bruno Haible  <bruno@clisp.org>
23803
23804         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
23805         gt_TYPE_SSIZE_T.
23806
23807 2003-11-24  Paul Eggert  <eggert@twinsun.com>
23808
23809         * modules/alloca: Remove dependency on xalloc.
23810
23811 2003-11-24  Paul Eggert  <eggert@twinsun.com>
23812
23813         * lib/alloca.c: Remove dependency on xalloc module.
23814         (xalloc_die): Remove.
23815         (memory_full) [!defined emacs]: New macro.
23816         [!defined emacs]: Don't include xalloc.h.
23817         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
23818         address arithmetic overflows.  Change datatypes a bit to avoid
23819         unnecessary casts.
23820
23821 2003-11-22  Jim Meyering  <jim@meyering.net>
23822
23823         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
23824         s/size/size_t/.
23825
23826 2003-11-21  Karl Berry  <karl@gnu.org>
23827
23828         * config/config.{sub,guess}: update from config.
23829
23830 2003-11-18  Karl Berry  <karl@gnu.org>
23831
23832         * config/config.{sub,guess}: update from config.
23833
23834         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
23835
23836 2003-11-17  Paul Eggert  <eggert@twinsun.com>
23837
23838         * README: Mention that S+T cannot overflow if S is the size of
23839         an existing object and T is sufficiently small.
23840
23841 2003-11-17  Jim Meyering  <jim@meyering.net>
23842
23843         On systems without utime and without a utimes function capable of
23844         dealing with a NULL struct utimbuf* argument, this utime replacement
23845         could -- in unusual circumstances -- leak a file descriptor.
23846         * lib/utime.c: Include <unistd.h> and <errno.h>.
23847         (utime_null): Be sure to close `fd' and to preserve errno.
23848         Reported by Geoff Collyer via Arnold Robbins.
23849
23850 2003-11-17  Bruno Haible  <bruno@clisp.org>
23851
23852         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
23853         (Depends-on): Add xsize.
23854
23855 2003-11-17  Bruno Haible  <bruno@clisp.org>
23856
23857         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
23858
23859 2003-11-17  Bruno Haible  <bruno@clisp.org>
23860
23861         * lib/vasnprintf.c (alloca): Remove fallback definition.
23862         (freea): Remove definition.
23863         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
23864         Reported by Paul Eggert.
23865
23866 2003-11-16  Paul Eggert  <eggert@twinsun.com>
23867             Bruno Haible  <bruno@clisp.org>
23868
23869         Protect against address arithmetic overflow.
23870         * lib/printf-args.h: Include stddef.h.
23871         (arguments): Change type of field 'count' to size_t.
23872         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
23873         'unsigned int' where appropriate.
23874         * lib/printf-parse.h: Include sys/types.h.
23875         (char_directive): Change type of *arg_index fields to ssize_t.
23876         (char_directives): Change type of fields 'count', max_*_length to
23877         size_t.
23878         * lib/printf-parse.c: Include sys/types.h and xsize.h.
23879         (SSIZE_MAX): Define fallback value.
23880         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
23881         instead of 'int' where appropriate. Check a_allocated, d_allocated
23882         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
23883         * lib/vasnprintf.c: Include xsize.h.
23884         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
23885         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
23886         overflow. Avoid wraparound when converting a width or precision from
23887         decimal to binary.
23888
23889 2003-11-16  Bruno Haible  <bruno@clisp.org>
23890
23891         Update from GNU gettext.
23892         * lib/printf-parse.c: Generalize to it can be compiled for wide
23893         strings.
23894         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
23895         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
23896         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
23897         SNPRINTF): New macros.
23898         Don't include <alloca.h> if the file is used inside libintl.
23899         (local_wcslen): New function, for Solaris 2.5.1.
23900         (VASNPRINTF): Use it instead of wcslen.
23901
23902 2003-11-16  Bruno Haible  <bruno@clisp.org>
23903
23904         * lib/xsize.h (xmax): New function.
23905         (xsum, xsum3, xsum4): Declare as "pure" functions.
23906
23907 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23908
23909         * modules/xalloc (Files): Undo latest change, since xalloc.h
23910         no longer needs SIZE_MAX or PTRDIFF_MAX.
23911
23912 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23913
23914         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
23915         gl_PTRDIFF_MAX.
23916
23917 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23918
23919         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
23920         "return", to pacify some unknown compiler.  Problem reported
23921         by Joerg Schilling.
23922
23923 2003-11-12  Paul Eggert  <eggert@twinsun.com>
23924
23925         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
23926         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
23927         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
23928         heuristic is just as accurate as far as we know, and it removes a
23929         dependency on size_max.m4 and ptrdiff_max.m4.
23930
23931 2003-11-11  Bruno Haible  <bruno@clisp.org>
23932
23933         * modules/xsize (Files): Add m4/size_max.m4.
23934         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
23935
23936 2003-11-11  Bruno Haible  <bruno@clisp.org>
23937
23938         * m4/size_max.m4: New file.
23939         * m4/ptrdiff_max.m4: New file.
23940         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
23941         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
23942         (gl_XALLOC): Invoke it.
23943
23944 2003-11-11  Bruno Haible  <bruno@clisp.org>
23945
23946         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
23947         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
23948         defined.
23949
23950 2003-11-10  Paul Eggert  <eggert@twinsun.com>
23951
23952         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
23953         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
23954         rejected some allocations of exactly SIZE_MAX - 2 bytes.
23955         From Bruno Haible.
23956         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
23957         not (size_t) -1, since it's defined here.
23958
23959 2003-11-09  Karl Berry  <karl@gnu.org>
23960
23961         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
23962
23963 2003-11-06  Paul Eggert  <eggert@twinsun.com>
23964
23965         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
23966         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
23967         Reject sizes of exactly SIZE_MAX bytes.
23968         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
23969         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
23970
23971 2003-11-05  Bruno Haible  <bruno@clisp.org>
23972
23973         * lib/xsize.h: Include limits.h, to avoid a possible collision with
23974         SIZE_MAX defined in <limits.h> on Solaris.
23975
23976 2003-11-04  Jim Meyering  <jim@meyering.net>
23977
23978         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
23979         variable names, rather than @VAR@.
23980         * modules/poll: Likewise.
23981
23982 2003-11-04  Bruno Haible  <bruno@clisp.org>
23983
23984         * modules/xsize: New file.
23985         * modules/linebreak: Depend on xsize.
23986         * MODULES.html.sh (func_all_modules): Add xsize.
23987
23988 2003-11-04  Bruno Haible  <bruno@clisp.org>
23989
23990         * m4/xsize.m4: New file.
23991
23992 2003-11-04  Bruno Haible  <bruno@clisp.org>
23993
23994         * lib/xsize.h: New file.
23995         * lib/linebreak.c: Include xsize.h.
23996         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
23997         argument for overflow.
23998         Suggested by Paul Eggert.
23999
24000 2003-11-03  Karl Berry  <karl@gnu.org>
24001
24002         * config/config.{guess,sub}: update from config.
24003
24004 2003-11-03  Jim Meyering  <jim@meyering.net>
24005
24006         * modules/userspec (lib_SOURCES): Add userspec.h.
24007         (Include): Add "userspec.h".
24008         Improve description.
24009
24010 2003-11-03  Jim Meyering  <jim@meyering.net>
24011
24012         * lib/userspec.c: Include "userspec.h".
24013         * lib/userspec.h: New file.
24014
24015 2003-11-03  Bruno Haible  <bruno@clisp.org>
24016
24017         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
24018
24019 2003-11-03  Bruno Haible  <bruno@clisp.org>
24020
24021         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
24022         available, to avoid (extremely rare) race condition.
24023         Suggested by Paul Eggert.
24024
24025 2003-11-02  Karl Berry  <karl@gnu.org>
24026
24027         * config/srclist.txt (vasprintf.c): sync broken, sigh.
24028
24029 2003-10-31  Paul Eggert  <eggert@twinsun.com>
24030
24031         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
24032         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
24033         (read_filesystem_list): Set and use me_type_malloced.
24034         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
24035         whatever the type happens to be), for brevity and consistency.
24036         Check for size calculation overflow on Alphas running OSF/1.
24037
24038 2003-10-31  Jim Meyering  <jim@meyering.net>
24039
24040         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
24041
24042         * lib/linebuffer.c: Include <string.h> for declaration of memset.
24043
24044 2003-10-30  Paul Eggert  <eggert@twinsun.com>
24045             Bruno Haible  <bruno@clisp.org>
24046
24047         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
24048         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
24049
24050 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
24051
24052         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
24053         netbsd*-gnu*.  Suggested by Robert Millan.
24054
24055 2003-10-29  Paul Eggert  <eggert@twinsun.com>
24056
24057         * modules/group-member: Depend on stdbool.
24058
24059 2003-10-29  Paul Eggert  <eggert@twinsun.com>
24060
24061         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
24062
24063 2003-10-29  Paul Eggert  <eggert@twinsun.com>
24064
24065         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
24066         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
24067         after the 'gnu' in these cases.  This fixes some bugs in the
24068         previous change, and is based on suggestions by Robert Millan.
24069
24070 2003-10-29  Paul Eggert  <eggert@twinsun.com>
24071
24072         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
24073         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
24074         no longer needed.
24075         * lib/quotearg.c (quotearg_n_options): Use it.
24076         * lib/group-member.c: Include <stdbool.h>.
24077         (free_group_info): Arg is now const *; don't free arg.
24078         (get_group_info): Now returns bool and accepts struct group_info *,
24079         rather than returning a malloc'ed struct group_info *.
24080         All uses changed.  Check for overflow in internal size calculation.
24081
24082         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
24083         rather than xmalloc/xrealloc.
24084         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
24085         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
24086         conformance bug: the old code used a pointer after freeing the
24087         storage that it addressed.
24088         * lib/hash.c (hash_initialize): Simplify the code by using
24089         xalloc_oversized rather than doing it by hand.
24090         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
24091         the buffer preserved.  Use free and xmalloc instead.
24092         * lib/quotearg.c (quotearg_n_options): Likewise.
24093         Use a simpler test for size overflow.  Don't use xalloc_oversized
24094         because unsigned int might be wider than size_t (!); this suggests
24095         that we should switch from unsigned int to size_t for slot numbers.
24096
24097 2003-10-28  Paul Eggert  <eggert@twinsun.com>
24098
24099         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
24100         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
24101         NetBSD kernels.  Requested by Richard Stallman.
24102
24103 2003-10-27  Paul Eggert  <eggert@twinsun.com>
24104
24105         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
24106         to allocate the returned structure.  Do not allocate a subarray,
24107         as x2nrealloc will do that.
24108         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
24109         instead of xnrealloc.
24110         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
24111
24112 2003-10-27  Bruno Haible  <bruno@clisp.org>
24113
24114         * lib/stdbool_.h: Better support for BeOS.
24115
24116 2003-10-26  Paul Eggert  <eggert@twinsun.com>
24117
24118         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
24119         now uses inline.
24120
24121 2003-10-26  Paul Eggert  <eggert@twinsun.com>
24122
24123         * lib/xalloc.h (xalloc_oversized): New static inline function, for
24124         callers that want to do their own size-overflow checking.  Include
24125         <stdbool.h>, since xalloc_oversized returns bool.
24126         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
24127         to use xalloc_oversized.
24128
24129         Add two functions x2realloc, x2nrealloc, for programs that grow
24130         arrays dynamically by doubling their sizes.
24131         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
24132         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
24133         New functions.
24134
24135         Port to C99 semantics for 'inline' of external functions.
24136         Bug reported by Bruno Haible.
24137         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
24138         with the old contents of xnmalloc.
24139         (xnmalloc, xmalloc): Use it.
24140         (xnrealloc_inline): New static inline function,
24141         with the old contents of xnrealloc.
24142         (xnrealloc, xrealloc): Use it.
24143
24144         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
24145         that.
24146
24147 2003-10-26  Karl Berry  <karl@gnu.org>
24148
24149         * config/srclist.txt (COPYING.DOC): no longer available from
24150         /gd/gnuorg; don't know where the ultimate source is.
24151
24152 2003-10-25  Paul Eggert  <eggert@twinsun.com>
24153
24154         Fix several address-calculation bugs in the hash modules,
24155         plus some minor code cleanup.
24156
24157         * lib/hash.h: Include <stdbool.h>, for bool.
24158         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
24159         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
24160         hash_get_n_entries, hash_get_max_bucket_length,
24161         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
24162         hash_rehash): Use size_t rather than unsigned.
24163         * lib/hash.c (struct hash_table, hash_get_n_buckets,
24164         hash_get_n_buckets_used, hash_get_n_entries,
24165         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
24166         hash_get_entries, hash_do_for_each, hash_string, is_prime,
24167         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
24168         Likewise.
24169         (SIZE_MAX): Define if not defined.
24170         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
24171         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
24172         hash_print):
24173         Use const * when possible.
24174         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
24175         (check_tuning): Fix bug: if tuning parameters were very close to
24176         0 or 1, rounding errors could have caused subscript violations.
24177         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
24178         (hash_initialize): Add 'fail:' label
24179         to free table and return NULL, and use it to simplify code.
24180         Use calloc rather than clearing the storage ourself.
24181         (hash_initialize, hash_rehash): Check for arithmetic overflow in
24182         buffer size calculations.
24183         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
24184         Include <stddef.h>, for size_t.
24185         * lib/hash-pjw.c (hash_pjw): Likewise.
24186         Switch to method described by Bruno Haible.
24187         Include <limits.h>, for CHAR_BIT.
24188         (SIZE_BITS): New macro.
24189
24190 2003-10-23  Paul Eggert  <eggert@twinsun.com>
24191
24192         * m4/getline.m4 (AM_FUNC_GETLINE):
24193         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
24194         hosts.  Problem reported by Derek Robert Price in
24195         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
24196         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
24197         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
24198
24199 2003-10-21  Paul Eggert  <eggert@twinsun.com>
24200
24201         * lib/getndelim2.c (getndelim2): When size calculation overflows,
24202         ceiling the allocation at NMAX bytes rather than silently
24203         discarding input bytes before NMAX is reached.  This makes
24204         a difference only if NMAX exceeds SIZE_MAX / 2.
24205
24206         * lib/obstack.c: Merge from glibc.
24207         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
24208         Add libc_hidden_def (_obstack_newchunk).
24209         (_obstack_free) [! defined _LIBC]: Remove.
24210         [defined _LIBC]: Make a strong alias from obstack_free, rather than
24211         a clone of the function body.
24212         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
24213         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
24214
24215         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
24216         glibc.
24217         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
24218         arg to memcpy.
24219
24220         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
24221         (obstack_ptr_grow_fast, obstack_int_grow_fast):
24222         Don't use lvalue casts, as GCC plans to remove support for them
24223         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
24224         was also present in the non-GCC version, indicating that this
24225         code had always been buggy and had never been widely used.
24226         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
24227         Use the fast variant of each macro, rather than copying the
24228         definiens of the fast variant; that way, we'll be more likely to
24229         catch future bugs in the fast variants.
24230
24231 2003-10-20  Bruno Haible  <bruno@clisp.org>
24232
24233         * modules/wait-process: New file.
24234         * MODULES.html.sh (func_all_modules): Add wait-process.
24235
24236 2003-10-20  Bruno Haible  <bruno@clisp.org>
24237
24238         * m4/wait-process.m4: New file.
24239
24240 2003-10-20  Bruno Haible  <bruno@clisp.org>
24241
24242         * lib/wait-process.h: New file, from GNU gettext.
24243         * lib/wait-process.c: New file, from GNU gettext.
24244
24245 2003-10-19  Jim Meyering  <jim@meyering.net>
24246
24247         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
24248         HPUX 10.20.
24249
24250 2003-10-18  Karl Berry  <karl@gnu.org>
24251
24252         * config/config.guess: update from config.
24253
24254 2003-10-16  Paul Eggert  <eggert@twinsun.com>
24255
24256         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
24257         (getgroups): First arg is int, not size_t.
24258         Don't let 'free' mangle errno.
24259
24260 2003-10-16  Paul Eggert  <eggert@twinsun.com>
24261
24262         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
24263
24264 2003-10-16  Karl Berry  <karl@gnu.org>
24265
24266         * config/config.{guess,sub}: update from config.
24267
24268 2003-10-16  Jim Meyering  <jim@meyering.net>
24269
24270         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
24271         memcpy.
24272
24273 2003-10-15  Paul Eggert  <eggert@twinsun.com>
24274
24275         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
24276         (SIZE_MAX): Remove.
24277         (new_exclude, add_exclude_file): Initial size no longer needs to
24278         be a power of 2.
24279         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
24280         our own address arithmetic overflow checking.
24281
24282         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
24283         (fnmatch): Do not alloca more than 2000 wide characters;
24284         instead, use malloc for large buffers.
24285         Check for address arithmetic overflow, and return -1
24286         with errno set to ENOMEM in that case.
24287         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
24288         (NEW_PATTERN): Do not alloca more than 8000 bytes;
24289         instead, return -1.  Check for address arithmetic overflow.
24290
24291 2003-10-14  Paul Eggert  <eggert@twinsun.com>
24292
24293         Handle invalid suffixes and overflow independently, so that
24294         callers can treat them independently as needed.  Fix some bugs in
24295         suffix handling, e.g., "100k@" was not diagnosed as an invalid
24296         suffix for a human-readable blocksize.  The major caller-visible
24297         change is the addition of a new
24298         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
24299         that both overflow and suffix chars were found.
24300
24301         * lib/human.c (humblock): Don't check separately for invalid suffix
24302         char; that is xstrtoumax's job (now that its bug is fixed).
24303         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
24304         INTMAX_MAX]: New macros.
24305         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
24306         TYPE_MAXIMUM): New macros.
24307         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
24308         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
24309         if overflow occurs, as it's what __strtol does and it's more useful
24310         in practice.
24311         (__xstrtol): If __strtol reports some error other than ERANGE,
24312         reflect it to the caller as LONGINT_INVALID.  If it reports
24313         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
24314         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
24315         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
24316         value.
24317         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
24318         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
24319         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
24320         [defined UINTMAX_MAX]: New macros.
24321
24322 2003-10-14  Bruno Haible  <bruno@clisp.org>
24323
24324         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
24325
24326 2003-10-14  Bruno Haible  <bruno@clisp.org>
24327
24328         * m4/sig_atomic_t: New file, from GNU gettext.
24329         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
24330
24331 2003-10-14  Bruno Haible  <bruno@clisp.org>
24332
24333         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
24334         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
24335         Also use volatile where needed.
24336
24337 2003-10-12  Paul Eggert  <eggert@twinsun.com>
24338
24339         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
24340         Change maintainer from Bruno Haible to 'all'.
24341
24342 2003-10-12  Paul Eggert  <eggert@twinsun.com>
24343
24344         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
24345
24346 2003-10-12  Paul Eggert  <eggert@twinsun.com>
24347
24348         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
24349         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
24350         and define in terms of the other primitives.
24351         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
24352         (SIZE_MAX): Define if not already defined.
24353         (array_size_overflow): New function.
24354         (xalloc_die): Abort instead of exiting if 'error' returns.
24355         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
24356         (xmalloc, xrealloc): Use them.
24357         (xcalloc): Check for address arithmetic overflow.
24358         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
24359         a bit faster than strcpy.
24360
24361 2003-10-10  Simon Josefsson  <jas@extundo.com>
24362
24363         * modules/argp (Depends-on): Add restrict and strcase.
24364
24365 2003-10-10  Simon Josefsson  <jas@extundo.com>
24366
24367         * m4/argp.m4: Add AC_C_INLINE.
24368
24369 2003-10-08  Paul Eggert  <eggert@twinsun.com>
24370
24371         Merge getpass from libc, plus a few fixes.
24372
24373         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
24374         Include <stdbool.h>.
24375         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
24376         __fsetlocking to empty.
24377         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
24378         do include <bits/libc-lock.h>.
24379         Do not include <fcntl.h>; not needed.
24380         [_LIBC]: Include <wchar.h>.
24381         (NOTCANCEL_MODE): New macro.
24382         (flockfile, funlockfile) [_LIBC]: New macros.
24383         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
24384         [!_LIBC]: New macros.
24385         (call_fclose): New function.
24386         (getpass): Use it.  Save tty stream separately; this simplifies the
24387         code and makes it more reliable if stdin happens to equal stdout.
24388         Invoke __fsetlocking on tty.
24389         Handle thread cancellation if needed.
24390         Namespace cleanup (use __tcgetattr, __getline).
24391         Use bool for Booleans.
24392         [USE_IN_LIBIO]: Handle wide streams.
24393         [!_LIBC]: Unconditionally do the fseek, since we don't know what
24394         stream might go where.
24395
24396         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
24397         doesn't have to include <stdio.h> before us.
24398         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
24399         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
24400         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
24401         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
24402         if not declared, so that we can use getpass.c code from libc without
24403         rewriting it.
24404         (flockfile, ftrylockfile, funlockfile): New macros.
24405
24406 2003-10-08  Paul Eggert  <eggert@twinsun.com>
24407
24408         * modules/getpass: Depend on stdbool.
24409
24410 2003-10-08  Paul Eggert  <eggert@twinsun.com>
24411
24412         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
24413
24414 2003-10-07  Karl Berry  <karl@gnu.org>
24415
24416         * config/config.{guess,sub}: update from config.
24417
24418 2003-10-06  Jim Meyering  <jim@meyering.net>
24419             Bruno Haible  <bruno@clisp.org>
24420
24421         This lets translators provide better translations for the
24422         "Written by ..." part of --version output.
24423         * lib/version-etc.h: Include stdarg.h.
24424         (version_etc_copyright): Declare as readonly.
24425         (version_etc): Make this function variadic with a NULL-terminated list
24426         of author name strings.
24427         (version_etc_va): New declaration.
24428         * lib/version-etc.c: Include stdarg.h, stdlib.h.
24429         (version_etc_copyright): Declare as readonly.
24430         (version_etc_va): New function. Provide a different translatable string
24431         for each possible number of authors < 10. Abbreviate when there are 10
24432         authors or more.
24433         (version_etc): Make this function variadic. Call version_etc_va.
24434         Suggestion from Gary V. Vaughan.
24435
24436         * lib/long-options.h (parse_long_options): Change prototype: the
24437         authors string is moved to the end and becomes variadic.
24438         * lib/long-options.c: Include stdarg.h.
24439         (parse_long_options): Make this function variadic, too.
24440         Call version_etc_va, not version_etc.
24441
24442 2003-10-06  Bruno Haible  <bruno@clisp.org>
24443
24444         * modules/version-etc-2: Remove file.
24445         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
24446
24447 2003-10-06  Bruno Haible  <bruno@clisp.org>
24448
24449         * modules/fatal-signal: New file.
24450         * MODULES.html.sh (func_all_modules): Add fatal-signal.
24451
24452 2003-10-06  Bruno Haible  <bruno@clisp.org>
24453
24454         * m4/fatal-signal.m4: New file.
24455         * m4/signalblocking.m4: New file, from GNU gettext.
24456
24457 2003-10-06  Bruno Haible  <bruno@clisp.org>
24458
24459         * lib/version-etc-2.h: Remove file.
24460         * lib/version-etc-2.c: Remove file.
24461
24462 2003-10-06  Bruno Haible  <bruno@clisp.org>
24463
24464         * lib/fatal-signal.h: New file, from GNU gettext.
24465         * lib/fatal-signal.c: New file, from GNU gettext.
24466
24467 2003-10-05  Paul Eggert  <eggert@twinsun.com>
24468
24469         * README: Rework advice for preventing empty .o files.
24470         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
24471         not <sys/types.h>.
24472
24473 2003-10-04  Karl Berry  <karl@gnu.org>
24474
24475         * lib/argp*: update from libc.
24476
24477 2003-10-04  Karl Berry  <karl@gnu.org>
24478
24479         * config/config.{guess,sub}: update from config.
24480
24481 2003-10-02  Bruno Haible  <bruno@clisp.org>
24482
24483         * modules/lchown (Include): Add lchown.h.
24484         * modules/time_r (Include): Use "..." syntax.
24485         * modules/xgetdomainname (Include): Add xgetdomainname.h.
24486
24487 2003-10-01  Simon Josefsson  <jas@extundo.com>
24488
24489         * MODULES.html.sh (func_all_modules): Move gethostname from section
24490         'based on' to section 'lacking' POSIX:2001.
24491
24492 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
24493
24494         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
24495         to output mode on the same stream.
24496
24497 2003-09-29  Paul Eggert  <eggert@twinsun.com>
24498
24499         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
24500         Fix arg typo in previous patch.
24501
24502 2003-09-28  Jim Meyering  <jim@meyering.net>
24503
24504         * lib/error.c: Correct cpp indentation.
24505
24506 2003-09-27  Paul Eggert  <eggert@twinsun.com>
24507
24508         * modules/free: New file.
24509
24510 2003-09-27  Paul Eggert  <eggert@twinsun.com>
24511
24512         * m4/free.m4: New file.
24513
24514 2003-09-27  Paul Eggert  <eggert@twinsun.com>
24515
24516         * lib/minmax.h (MIN, MAX)
24517         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
24518         Omit the special code that used __typeof__, since we worry that
24519         it could be more trouble than it's worth.  See:
24520         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
24521         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
24522
24523         * lib/free.c: New file.
24524
24525 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
24526
24527         Trivial fixes to Makefile.am parts of module listings.
24528         * modules/strstr: Append strstr.h to lib_SOURCES.
24529         * modules/strcase: Likewise, for strcase.h.
24530
24531 2003-09-27  Karl Berry  <karl@gnu.org>
24532
24533         * config/mkinstalldirs: update from automake.
24534
24535 2003-09-26  Paul Eggert  <eggert@twinsun.com>
24536
24537         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
24538         (error_tail): Do not loop, reallocating temporary buffer, since
24539         the output cannot contain more wide characters than the input
24540         contains bytes, the size must be big enough already.  This avoids
24541         one potential size overflow calculation.  Check for size overflow
24542         when calculating temporary buffer size.  Free temporary buffer
24543         when done, if it was allocated with malloc; this plugs a memory
24544         leak.  Remove casts from void * to pointers, that are no longer
24545         needed now that we're assuming C89 or better.
24546
24547         Merge error changes from glibc.
24548
24549         * lib/error.c, error.h: Update copyright notice header to match glibc.
24550         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
24551         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
24552         Disable cancellation while printing error.
24553         * lib/error.h: Prepend __ to parameter names.
24554
24555 2003-09-26  Jim Meyering  <jim@meyering.net>
24556
24557         * lib/error.c (error_tail): Move some declarations
24558         into inner scope where the local variables are used.
24559
24560 2003-09-26  Bruno Haible  <bruno@clisp.org>
24561
24562         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
24563         stpncpy().
24564         Don't define stpncpy through config.h; it's now done through stpncpy.h.
24565
24566 2003-09-26  Bruno Haible  <bruno@clisp.org>
24567
24568         * lib/stpncpy.h (gnu_stpncpy): New declaration.
24569         (stpncpy): Define as alias for gnu_stpncpy.
24570         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
24571
24572 2003-09-25  Simon Josefsson  <jas@extundo.com>
24573
24574         * lib/xgetdomainname.h: New file.
24575         * lib/xgetdomainname.c: New file.
24576
24577 2003-09-25  Simon Josefsson  <jas@extundo.com>
24578             Bruno Haible  <bruno@clisp.org>
24579
24580         * modules/getdomainname: New file.
24581         * modules/xgetdomainname: New file.
24582         * MODULES.html.sh (func_all_modules): Add getdomainname,
24583         xgetdomainname.
24584
24585 2003-09-25  Simon Josefsson  <jas@extundo.com>
24586             Bruno Haible  <bruno@clisp.org>
24587
24588         * m4/getdomainname.m4: New file.
24589
24590 2003-09-25  Simon Josefsson  <jas@extundo.com>
24591             Bruno Haible  <bruno@clisp.org>
24592
24593         * lib/getdomainname.h: New file.
24594         * lib/getdomainname.c: New file.
24595
24596 2003-09-25  Karl Berry  <karl@gnu.org>
24597
24598         * lib/argp-fmtstream.c, argp-help.c: update from libc.
24599
24600 2003-09-25  Karl Berry  <karl@gnu.org>
24601
24602         * config/install-sh: update from automake.
24603
24604 2003-09-25  Bruno Haible  <bruno@clisp.org>
24605
24606         * modules/version-etc-2: New file, from modules/version-etc with
24607         modifications.
24608         * MODULES.html.sh (func_all_modules): Add version-etc-2.
24609
24610 2003-09-25  Bruno Haible  <bruno@clisp.org>
24611
24612         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
24613         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
24614
24615 2003-09-24  Simon Josefsson  <jas@extundo.com>
24616
24617         * modules/xgethostname: Add xgethostname.h.
24618
24619 2003-09-24  Paul Eggert  <eggert@twinsun.com>
24620
24621         * lib/linebuffer.c (freebuffer): Don't free the argument, just
24622         the buffer associated with the argument.  Bug reported by
24623         Simon Josefsson.
24624
24625 2003-09-24  Paul Eggert  <eggert@twinsun.com>
24626
24627         * README: Document assumptions that 'int' is at least 32 bits
24628         wide, that integer arithmetic is 2's complement without overflow,
24629         that there are no holes in integer values, that adding sizes of
24630         two nonoverlapping objects can't overflow, and that all-bits-zero
24631         yields scalar zero.  Fix spelling and capitalization typos.
24632
24633 2003-09-19  Karl Berry  <karl@gnu.org>
24634
24635         * lib/argp.h: update from libc.
24636
24637 2003-09-17  Paul Eggert  <eggert@twinsun.com>
24638
24639         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
24640         to avoid spurious warnings like "AC_RUN_IFELSE was called before
24641         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
24642
24643 2003-09-17  Paul Eggert  <eggert@twinsun.com>
24644
24645         * gnulib-tool: Use "test -h", not "test -L", for portability
24646         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
24647         (tags_regexp): Remove, since \| doesn't conform to POSIX.
24648         (sed_extract_prog): Issue s commands one-by-one, rather than
24649         using \| in one s command.
24650
24651 2003-09-16  Paul Eggert  <eggert@twinsun.com>
24652
24653         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
24654         input error, instead of returning NULL the next time we are called
24655         (and therefore losing track of errno).
24656
24657 2003-09-16  Bruno Haible  <bruno@clisp.org>
24658
24659         * gnulib-tool (func_create_testdir): Warn about duplicated
24660         dependencies.
24661
24662 2003-09-15  Paul Eggert  <eggert@twinsun.com>
24663
24664         * modules/argmatch, modules/fatal, modules/obstack,
24665         modules/xalloc, modules/xgethostname: Sort dependencies by
24666         importance, not alphabetically.
24667
24668 2003-09-15  Paul Eggert  <eggert@twinsun.com>
24669
24670         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
24671         fails, so that the caller gets the proper errno.
24672
24673         * lib/readutmp.c (read_utmp): Likewise.
24674         Check for fstat error.  Close stream and free storage
24675         when failing.
24676
24677 2003-09-14  Karl Berry  <karl@gnu.org>
24678
24679         * config/srclist.txt (strdup.c): disable for c89 changes.
24680
24681 2003-09-14  Jim Meyering  <jim@meyering.net>
24682
24683         * lib/getloadavg.c: Correct cpp indentation.
24684         * lib/strdup.c: Likewise.
24685         * lib/vasnprintf.c: Likewise.
24686
24687 2003-09-14  Bruno Haible  <bruno@clisp.org>
24688
24689         * modules/fwriteerror: New file.
24690         * MODULES.html.sh (func_all_modules): Add fwriteerror.
24691
24692 2003-09-14  Bruno Haible  <bruno@clisp.org>
24693
24694         * lib/fwriteerror.h: New file.
24695         * lib/fwriteerror.c: New file.
24696
24697 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24698
24699         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
24700         modules/xgethostname, modules/xalloc: Depend on exit.
24701
24702 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24703
24704         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
24705
24706         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
24707         and AC_MINIX, too, so that their extensions are available.
24708
24709         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
24710         This macro has been superseded by gl_BACKUPFILE.
24711
24712         More patches to assume C89 or better.
24713
24714         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
24715
24716         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
24717         unconditionally.
24718         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
24719         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
24720         Include <string.h>, <stdlib.h> unconditionally.
24721         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
24722         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
24723         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
24724         headers or for string.h.
24725         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
24726         or strtoul.
24727
24728         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
24729         headers.
24730         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
24731         * m4/userspec.m4 (gl_USERSPEC): Likewise.
24732         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
24733         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
24734         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
24735         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
24736         memcpy, memset.
24737         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
24738         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
24739         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
24740         strtol.
24741         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
24742         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
24743         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
24744         strtoul.
24745
24746 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24747
24748         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
24749         * lib/obstack.c [!defined _LIBC]: Likewise.
24750         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
24751         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
24752         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
24753
24754         More changes to assume C89 or better.
24755
24756         * lib/error.c (error_tail): Assume vprintf.
24757
24758         * lib/argmatch.c (getenv): Remove decl.
24759         * lib/progreloc.c (get_full_program_name): Define via prototype.
24760         * lib/setenv.c (clearenv): Likewise.
24761         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
24762         needed.
24763         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
24764         (malloc, memcpy): Remove decls.
24765         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
24766         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
24767         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
24768         (memcpy): Remove macro.
24769         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
24770         (__P): Remove.  All uses removed.
24771         (PTR): Remove.  All uses changed to void *.
24772         (CHAR_BIT, NULL): Remove.
24773         (spaces, zeros, memset_space, memset_zero)
24774         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
24775         Remove.
24776         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
24777         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
24778         Define with prototype.
24779         Remove now-unnecessary prototype decl.
24780         (extra_args_spec): Assume ANSI C.  All uses changed.
24781         (extra_args_spec_iso): Remove.
24782         (my_strftime, emacs_strftimeu): Define via prototype.
24783         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
24784         unconditionally.
24785         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
24786         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
24787         (strtoul, strtol): Remove decls.
24788         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
24789         LONG_MAX): Remove.
24790         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
24791         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
24792         (LOCALE_PARAM_PROTO): New macro.
24793         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
24794         (INTERNAL (strtol), strtol): Define with a prototype.
24795         (PARAMS): Remove.  All uses removed.
24796         * lib/tempname.c: Include <string.h> unconditionally.
24797         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
24798         * lib/xgethostname.c (main): Define with a prototype.
24799         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
24800         Include <stdlib.h> unconditionally.
24801         (calloc, malloc, realloc, free): Remove decls.
24802         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
24803         Include <stdlib.h> unconditionally.  Sort include file names.
24804         (strtod): Remove.
24805         (xstrtod): Define with a prototype.
24806         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
24807         (strtol, strtoul): Remove decls.
24808
24809 2003-09-11  Paul Eggert  <eggert@twinsun.com>
24810
24811         More patches to assume C89 or better.
24812         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
24813         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
24814         string.h, memchr, STDC_HEADERS.
24815
24816 2003-09-11  Paul Eggert  <eggert@twinsun.com>
24817
24818         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
24819         Include <stdlib.h>, <string.h> unconditionally.
24820         Remove now-unnecessary cast to char *.
24821         * lib/strnlen.c: Include <string.h> unconditionally.
24822         * lib/yesno.c (yesno): Define with a prototype.
24823
24824 2003-09-11  Bruno Haible  <bruno@clisp.org>
24825
24826         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
24827
24828 2003-09-10  Jim Meyering  <jim@meyering.net>
24829
24830         * lib/error.c: Correct indentation of cpp directives.
24831
24832 2003-09-10  Bruno Haible  <bruno@clisp.org>
24833
24834         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
24835         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
24836         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
24837         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
24838         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
24839         <stdlib.h> and <string.h> checks.
24840         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
24841         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
24842
24843 2003-09-10  Bruno Haible  <bruno@clisp.org>
24844
24845         * lib/strcspn.c: Include <string.h> unconditionally.
24846         * lib/strpbrk.c: Include <string.h> unconditionally.
24847         * lib/strstr.c: Include <string.h> unconditionally.
24848         * lib/unicodeio.c: Include <string.h> unconditionally.
24849         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
24850         * lib/unsetenv.c: Likewise.
24851         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
24852         * lib/yesno.c: Include <stdlib.h> unconditionally.
24853         (rpmatch): Add prototype.
24854
24855 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24856
24857         More patches to assume C89 or better.
24858         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
24859         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
24860         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
24861         or for string.h.
24862         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
24863         stdlib.h.
24864         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
24865         C headers.
24866         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
24867         string.h.
24868         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
24869         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
24870         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
24871         or for string.h.
24872         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
24873         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
24874         C headers.
24875         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
24876         memcpy.
24877         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
24878         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
24879         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
24880         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
24881         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
24882         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
24883         string.h, free.
24884         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
24885         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
24886         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
24887         C headers, or for string.h.
24888         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
24889         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
24890         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
24891         headers, memory.h, stdlib.h, string.h, strings.h.
24892         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
24893         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
24894         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
24895         strchr.
24896         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
24897         headers, memory.h, string.h.
24898         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
24899         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
24900         free.
24901         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
24902         headers.
24903         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
24904         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
24905         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
24906         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
24907         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
24908
24909 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24910
24911         More K&R removal.
24912
24913         * lib/acosl.c (main): Use a prototype.
24914         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
24915         tanl.c: Likewise.
24916
24917         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
24918
24919         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
24920         (getopt, etopt_long, getopt_long_only, _getopt_internal)
24921         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
24922         with a prototype.
24923         * lib/getopt.c (const): Remove macro.
24924         Include <string.h> unconditionally.
24925         (my_index): Remove; all uses changed to strchr.
24926         (strlen): Remove decl.
24927         (exchange): Remove forward decl; no longer needed.
24928         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
24929         Define with prototype.
24930         * lib/getopt1.c (const): Remove macro.
24931         (getopt_long, getopt_long_only, main): Define with prototype.
24932
24933         * lib/getugroups.c: Include <string.h> unconditionally.
24934
24935         * lib/getusershell.c: Include <stdlib.h> unconditionally.
24936         (getusershell, setusershell, endusershell, readname, main):
24937         Define with prototypes.
24938
24939         * lib/group-member.c: Include group-member.h first.
24940         Include <stdlib.h> unconditionally.
24941
24942         * lib/hard-locale.c: Include hard-locale.h first.
24943         Include <stdlib.h>, <string.h> unconditionally.
24944
24945         * lib/hash.c (free, malloc): Remove decls.
24946         Include <stdlib.h> unconditionally.
24947
24948         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
24949         (getenv): Do not declare.
24950
24951         * lib/idcache.c: Include <string.h> unconditionally.
24952
24953         * lib/long-options.c: Include long-options.h first, to test interface.
24954         Include <stdlib.h> unconditionally.
24955
24956         * lib/makepath.c: Include makepath.h first, to test interface.
24957         Include <stdlib.h> and <string.h> unconditionally.
24958
24959         * lib/linebuffer.c: Include <stdlib.h>.
24960         (free): Remove decl.
24961
24962         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
24963         stddef.h. rpl_malloc returns void *, not char *.
24964         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
24965         prototype.
24966
24967         * lib/md5.h: Include <limits.h> unconditionally.
24968         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
24969         (__P): Remove; all uses removed.
24970         * lib/md5.c: Include "md5.h" first.
24971         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
24972         md5_buffer, md5_process_bytes, md5_process_block):
24973         Define with prototypes.
24974         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
24975         * lib/sha.c: Include "sha.h" first.
24976         Include <stdlib.h>, <string.h> unconditionally.
24977
24978         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
24979         * lib/memcmp.c (__ptr_t): Likewise.
24980         * lib/memrchr.c (__ptr_t): Likewise.
24981         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
24982         Include <string.h> unconditionally.
24983         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
24984         * lib/memchr.c: Include <stdlib.h> unconditionally.
24985         * lib/memchr.c (LONG_MAX): Remove.
24986         * lib/memrchr.c (LONG_MAX): Likewise.
24987         * lib/memchr.c (__memchr): Define via a prototype.
24988         * lib/memrchr.c (__memrchr): Likewise.
24989         * lib/memcmp.c (__P): Remove, and remove all uses.
24990         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
24991         Remove forward decls; no longer needed.
24992         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
24993         Use types required by C89 in prototype.
24994
24995         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
24996         * lib/savedir.c: Likewise.
24997         * lib/mkdir.c (free): Remove decl.
24998         * lib/rmdir.c (rmdir): Define with a prototype.
24999         * lib/savedir.c: Include savedir.h first, to test interface.
25000
25001         * lib/mktime.c (STDC_HEADERS): Remove.
25002         Include <stdlib.h>, <string.h> unconditionally.
25003
25004         * lib/modechange.c: Include <stdlib.h> unconditionally.
25005         (malloc): Remove decl.
25006
25007         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
25008         (free): Remove decl.
25009
25010         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
25011         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
25012         (This type really should be intptr_t, but that's a C99ism.)
25013         (_obstack_memcpy): Remove: all uses changed to memcpy.
25014         Include <string.h> unconditionally.
25015         (struct obstack): Assume __STDC__ for types of members
25016         chunkfun, freefun, extra_arg.
25017         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
25018         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
25019         obstack_begin, obstack_specify_allocation,
25020         obstack_specify_allocation_with_arg, obstack_chunkfun,
25021         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
25022         Remove unprototyped decls and the macros that use them.
25023         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
25024         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
25025         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
25026         (defined __STDC__ && __STDC__)]:
25027         Remove nonprototyped code.
25028         Include <stdlib.h> unconditionally.
25029         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
25030         _obstack_allocated_p, _obstack_free, obstack_free,
25031         _obstack_memory_used, print_and_abort):
25032         Define using prototypes.
25033         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
25034         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
25035         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
25036         obstack_next_free, obstack_object_size, obstack_room) [0]:
25037         Remove unused, unprototyped code.
25038
25039         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
25040
25041         * lib/physmem.c (physmem_total, physmem_available, main): Define
25042         with prototypes.
25043
25044         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
25045         (main): Define with a prototype.
25046
25047         * lib/posixver.c (getenv): Remove decl.
25048
25049         * lib/putenv.c (malloc): Returns void *, not char *.
25050         Include <string.h> unconditionally.
25051         (strchr, memcpy, NULL): Do not define.
25052
25053         * lib/readtokens.c: Include readtokens.h first, to test interface.
25054         Include <stdlib.h>, <string.h> unconditionally.
25055         (init_tokenbuffer): Define with a prototype.
25056
25057         * lib/regex.c (PARAMS): Remove.  All uses removed.
25058         All uses of _RE_ARGS removed, too.
25059         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
25060         unconditionally.
25061         (bzero): Assume memset exists.
25062         (memcmp, memcpy, NULL): Remove.
25063         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
25064         char, or assignments to local vars of type signed char.
25065         (init_syntax_once, PREFIX(extract_number_and_incr),
25066         PREFIX(print_partial_compiled_pattern),
25067         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
25068         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
25069         PREFIX(regex_grow_registers), PREFIX(regex_compile),
25070         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
25071         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
25072         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
25073         wcs_compile_range, byte_compile_range, truncate_wchar,
25074         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
25075         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
25076         count_mbs_length, wcs_re_match_2_internal,
25077         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
25078         PREFIX(alt_match_null_string_p),
25079         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
25080         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
25081         regfree, PREFIX(extract_number)): Define with prototype.  Remove
25082         now-unnecessary declaration, if any.
25083         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
25084         regcomp, regexec):
25085         Remove now-unnecessary casts among pointer types.
25086         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
25087
25088         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
25089         (free): Remove decl.
25090
25091         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
25092
25093         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
25094         (free): Remove decl.
25095
25096         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
25097         * lib/xgetcwd.c: Likewise.
25098
25099         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
25100         (free): Remove decl.
25101
25102         * lib/strchrnul.c (strchrnul): Define with a prototype.
25103         Fix bug: c_in was not converted to char before searching.
25104
25105         The following changes are not K&R related:
25106
25107         * lib/group-member.h: Include <sys/types.h>, so that this file is
25108         self-contained.
25109         * lib/makepath.h: Likewise.
25110
25111         * lib/getusershell.c (readname, default_index, line_size, readname):
25112         Use size_t, not int, for sizes.
25113         (readname): If the size overflows, report an error instead of
25114         looping forever.
25115
25116 2003-09-09  Paul Eggert  <eggert@twinsun.com>
25117
25118         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
25119         libc.
25120
25121 2003-09-09  Paul Eggert  <eggert@twinsun.com>
25122
25123         * README: New section: portability guidelines.
25124
25125 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
25126
25127         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
25128         C89 spec.
25129
25130 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
25131
25132         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
25133
25134 2003-09-08  Paul Eggert  <eggert@twinsun.com>
25135
25136         Assume C89 or better; remove K&R cruft.
25137         A few of these changes were first proposed by Derek Robert Price
25138         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
25139
25140         * lib/addext.c: Include <string.h> unconditionally.
25141         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
25142         Don't declare getenv or malloc.
25143
25144         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
25145         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
25146         (NULL): Remove.
25147         (find_stack_direction, alloca): Use prototypes.
25148
25149         * lib/atexit.c (atexit): Define using a prototype.
25150
25151         * lib/basename.c, dirname.c, stripslash.c:
25152         Include <string.h> unconditionally.
25153
25154         * lib/bcopy.c: Include <stddef.h>.
25155         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
25156
25157         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
25158
25159         * lib/error.h (error, error_at_line, error_print_progname)
25160         [! (defined (__STDC__) && __STDC__)]: Remove decls.
25161         * lib/error.c: Include error.h first, to check interface.
25162         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
25163         (VA_START): Remove; all uses changeed to va_start.
25164         (exit, strerror): Remove decls.
25165         (error_print_progname): Prototype uncondionally.
25166         Don't include <errno.h>; no longer needed.
25167         (private_strerror): Remove.
25168         (error_tail): Always define.
25169         (error, error_at_line): Assume C89 or better; always use prototypes.
25170         * lib/fatal.c: Include "fatal.h" first, to test interface.
25171         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
25172         (VA_START): Remove; all uses changed to va_start.
25173         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
25174         this case.
25175         (exit): Remove decl.
25176         (fatal): Prototype unconditionally.  Assume va_start works.
25177         Abort at end, to pacify gcc.
25178
25179         * lib/euidaccess.c (main): Define with a prototype.
25180
25181         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
25182
25183         * lib/exitfail.c: Include <stdlib.h> unconditionally.
25184
25185         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
25186         prototypes.
25187         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
25188         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
25189         (getenv): Remove decl.
25190         (fnmatch): Define using a prototype.
25191         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
25192         (FCT): Define using a prototype.
25193
25194         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
25195
25196         * lib/gethostname.c: Include <stddef.h>.
25197         (gethostname): Define with prototype.  Length is size_t, not int.
25198
25199 2003-09-08  Paul Eggert  <eggert@twinsun.com>
25200
25201         Assume C89 or better; remove K&R cruft.
25202         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
25203         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
25204         string.h, getenv, malloc.
25205         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
25206         headers.
25207         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
25208         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
25209         do not check for strerror.
25210         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
25211         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
25212         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
25213         do not check for doprnt or vprintf.
25214         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
25215         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
25216
25217 2003-09-08  Paul Eggert  <eggert@twinsun.com>
25218
25219         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
25220         getversion.c should have been removed then, but was accidentally
25221         preserved.
25222
25223         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
25224         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
25225
25226 2003-09-08  Karl Berry  <karl@gnu.org>
25227
25228         * config/config.sub, config.guess, srclistvars.sh: update from savannah
25229                 config, forget about prep.
25230
25231         * config/depcomp, missing: update from automake.
25232
25233 2003-09-07  Paul Eggert  <eggert@twinsun.com>
25234
25235         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
25236         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
25237
25238 2003-09-07  Paul Eggert  <eggert@twinsun.com>
25239
25240         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
25241         copy_tm_result.  Bug reported by Simon Josefsson in
25242         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
25243
25244 2003-09-06  Paul Eggert  <eggert@twinsun.com>
25245
25246         * m4/time_r.m4: New file.
25247         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
25248         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
25249         is. Check for timegm declaration.
25250         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
25251         Do not check for gmtime_r.
25252         Replace mktime if __mktime_internal does not exist and if mktime
25253         hasn't been replaced already.
25254
25255 2003-09-06  Paul Eggert  <eggert@twinsun.com>
25256
25257         * lib/time_r.c, lib/time_r.h: New files.
25258
25259         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
25260         __localtime_r.
25261         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
25262         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
25263
25264         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
25265         __gmtime_r.
25266         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
25267         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
25268         Include <time_r.h>.
25269
25270         * lib/timegm.c: Switch to glibc implementation, with the following
25271         changes:
25272         [defined HAVE_CONFIG_H]: Include <config.h>.
25273         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
25274         (__mktime_internal) [!defined _LIBC]: New decl.
25275         (__gmtime_r) [!defined _LIBC]: New macro and function.
25276         (timegm): Use a prototype, since gnulib assumes C89.
25277         Do not bother declaring tmp to be const, as it's not really usefu.
25278         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
25279         (timegm): Declare only if HAVE_DECL_TIMEGM.
25280
25281 2003-09-06  Paul Eggert  <eggert@twinsun.com>
25282
25283         * MODULES.html.sh (func_all_modules): Add time_r.
25284         * modules/time_r: New file.
25285         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
25286         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
25287
25288 2003-09-03  Paul Eggert  <eggert@twinsun.com>
25289
25290         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
25291         Bug reported by Lute Kamstra in
25292         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
25293
25294         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
25295         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
25296         course with correspondingly smaller numbers for tomorrow and
25297         yesterday.  From Tadayoshi Funaba.  Originally installed into
25298         sh-utils on 1999-08-07, but the patch got lost (I guess during the
25299         coreutils merge?).
25300
25301 2003-08-31  Simon Josefsson  <jas@extundo.com>
25302
25303         * modules/timegm: New file.
25304         * MODULES.html.sh (func_all_modules): Add timegm.
25305
25306 2003-08-31  Simon Josefsson  <jas@extundo.com>
25307
25308         * m4/timegm.m4: New file.
25309
25310 2003-08-31  Simon Josefsson  <jas@extundo.com>
25311
25312         * lib/timegm.h: New file.
25313         * lib/timegm.c: New file.  Based on
25314         wget-1.8.2/src/http.c:mktime_from_utc.
25315
25316 2003-08-31  Karl Berry  <karl@gnu.org>
25317
25318         * lib/argp.h: update from libc.
25319
25320 2003-08-28  Bruno Haible  <bruno@clisp.org>
25321
25322         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
25323         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
25324         followed by '#define fnmatch fnmatch_posix' gives an error.
25325
25326 2003-08-28  Bruno Haible  <bruno@clisp.org>
25327
25328         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
25329         warning on QNX, which defines O_BINARY to 000000.
25330
25331 2003-08-27  Jim Meyering  <jim@meyering.net>
25332
25333         * m4/mkstemp.m4: Require that the system mkstemp be able to create
25334         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
25335         would fail after 32.  Reported by Danny Levinson.  Details here:
25336         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
25337
25338 2003-08-24  Bruno Haible  <bruno@clisp.org>
25339
25340         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
25341         MSVC7 <stdio.h> is included later.
25342
25343 2003-08-22  Simon Josefsson  <jas@extundo.com>
25344
25345         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
25346
25347 2003-08-20  Karl Berry  <karl@gnu.org>
25348
25349         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
25350
25351 2003-08-20  Bruno Haible  <bruno@clisp.org>
25352
25353         * modules/progname: New file.
25354         * MODULES.html.sh (func_all_modules): Add progname.
25355
25356 2003-08-20  Bruno Haible  <bruno@clisp.org>
25357
25358         * lib/progname.h: New file, from GNU gettext.
25359         * lib/progname.c: New file, from GNU gettext.
25360         * lib/progreloc.c: New file, from GNU gettext.
25361
25362 2003-08-19  Jim Meyering  <jim@meyering.net>
25363
25364         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
25365         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
25366
25367 2003-08-19  Bruno Haible  <bruno@clisp.org>
25368
25369         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
25370         more.
25371
25372 2003-08-19  Bruno Haible  <bruno@clisp.org>
25373
25374         * lib/xstrdup.c: Assume <string.h> exists.
25375
25376 2003-08-18  Paul Eggert  <eggert@twinsun.com>
25377
25378         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
25379         in makefile rules.
25380
25381 2003-08-18  Jim Meyering  <jim@meyering.net>
25382
25383         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
25384         * m4/lib-ld.m4: Likewise.
25385
25386 2003-08-18  Jim Meyering  <jim@meyering.net>
25387
25388         * lib/setenv.h: Indent nested cpp directive.
25389         * lib/vasnprintf.c: Remove trailing blanks.
25390
25391 2003-08-17  Simon Josefsson  <jas@extundo.com>
25392
25393         * modules/xstrndup: New file.
25394         * MODULES.html.sh (func_all_modules): Add xstrndup.
25395
25396 2003-08-17  Simon Josefsson  <jas@extundo.com>
25397
25398         * modules/argp: Fix autoconf macro name. Add more dependencies.
25399
25400 2003-08-17  Simon Josefsson  <jas@extundo.com>
25401
25402         * m4/xstrndup.m4: New file.
25403
25404 2003-08-17  Simon Josefsson  <jas@extundo.com>
25405
25406         * m4/argp.m4: New file.
25407
25408 2003-08-17  Simon Josefsson  <jas@extundo.com>
25409             Bruno Haible  <bruno@clisp.org>
25410
25411         * lib/xstrndup.h: New file.
25412         * lib/xstrndup.c: New file.
25413
25414 2003-08-17  Bruno Haible  <bruno@clisp.org>
25415
25416         * modules/strndup (Files, Include): Add lib/strndup.h.
25417
25418 2003-08-17  Bruno Haible  <bruno@clisp.org>
25419
25420         * modules/euidaccess (Files): Add lib/euidaccess.h.
25421
25422 2003-08-17  Bruno Haible  <bruno@clisp.org>
25423
25424         * lib/strndup.h: New file.
25425
25426 2003-08-17  Bruno Haible  <bruno@clisp.org>
25427
25428         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
25429         like AC_GNU_SOURCE.
25430         * modules/extensions (configure.ac): Comment out the invocation of
25431         gl_USE_SYSTEM_EXTENSIONS.
25432
25433 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25434
25435         Merges from coreutils, etc.
25436         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
25437         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
25438         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
25439         fixing a typo.
25440         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
25441         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
25442
25443 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25444
25445         Document merge from coreutils.
25446         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
25447         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
25448         * modules/utime: Add m4/utimes-null.m4.
25449
25450 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25451
25452         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
25453         space, undoing this 2003-08-12 change:
25454         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
25455
25456 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25457
25458         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
25459         strtoul.c from libc, undoing this 2003-08-12 change:
25460         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
25461
25462 2003-08-16  Jim Meyering  <jim@meyering.net>
25463
25464         Merges from coreutils.
25465         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
25466         prefix.  Adjust cache variables similarly.  Create 500 rather than
25467         just 300 files, to exercise bug on Darwin6.5, too.
25468         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
25469         $missing_dir.
25470         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
25471         AM_SYS_POSIX_TERMIOS.
25472         Reported by mkc@mathdogs.com.
25473         Also change use of $am_cv_sys_posix_termios
25474         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
25475         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
25476         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
25477         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
25478         in /proc/mounts until it finds one with matching device number.  This
25479         is unnecessary when the FILE argument *is* a mount point.  No stat call
25480         is necessary in that case.  So, disable the statvfs-testing code on
25481         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
25482         as RedHat bug# 84846.
25483         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
25484         to 1MB, so as not to render systems with no stack size limit (e.g.,
25485         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
25486         Include <unistd.h>.  On some systems,
25487         it is required for the definition of _SC_PAGESIZE.
25488
25489 2003-08-16  Jim Meyering  <jim@meyering.net>
25490
25491         Merge from coreutils.
25492         * lib/xstrtoimax.c: #else #if -> #elif.
25493         * lib/xstrtoumax.c: Likewise.
25494
25495 2003-08-16  Jim Meyering  <jim@meyering.net>
25496
25497         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
25498         * m4/utimes.m4: Removed.
25499         * m4/utimes-null.m4: Renamed from utimes.m4.
25500
25501         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
25502         to 1MB, so as not to render systems with no stack size limit (e.g.,
25503         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
25504         Include <unistd.h>.  On some systems,
25505         it is required for the definition of _SC_PAGESIZE.
25506
25507 2003-08-16  Jim Meyering  <jim@meyering.net>
25508         and Paul Eggert  <eggert@cs.ucla.edu>
25509
25510         Merges from coreutils, etc.
25511
25512         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
25513         using the latest version from cvs.  This avoids problems with #line
25514         directives using a vendor (Sun) compiler.
25515         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
25516         Don't set GETGROUPS_LIB here; now it's
25517         done via getgroups.m4's wrapper function.
25518         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
25519         rather than just in sh-util/configure.in, so that the
25520         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
25521         same.
25522         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
25523         AC_FUNC_GETLOADAVG where to find getloadavg.c.
25524         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
25525         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
25526         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
25527         Remove code that is now done by the newly-required macros.
25528         Append $(EXEEXT) to DF_PROG.
25529         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
25530         Do not invoke or require the following here,
25531         since prereq.m4 or some gnulib .m4 now does this for us:
25532         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
25533         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
25534         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
25535         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
25536         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
25537         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
25538         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
25539         AC_FUNC_OBSTACK.
25540         Do not replace the following functions, as this is now the job
25541         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
25542         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
25543         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
25544         atexit getpass, strdup, getpagesize.
25545         Replace 'raise'.
25546         Do not check for the following functions, as this is now the job
25547         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
25548         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
25549         setregid.
25550         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
25551         Check for sys/sysctl.h.
25552         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
25553         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
25554         of checking for ssize_t ourselves.
25555
25556         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
25557         Require every macro that gnulib/modules/* suggests for us.
25558         (jm_PREREQ_ADDEXT): New macro.
25559         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
25560         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
25561
25562         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
25563         (gl_PHYSMEM): Use it.
25564         Also check for `table' function.
25565         Check for new headers and functions.
25566         Add check for sys/sysmp.h.
25567         With suggestions from Kaveh Ghazi.
25568         Ignore headers that are present but cannot be compiled.  This
25569         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
25570         C 5.4.
25571
25572 2003-08-15  Paul Eggert  <eggert@twinsun.com>
25573
25574         Document merge from coreutils.
25575         * modules/userspec: Depend on posixver.
25576         * modules/strftime: Depend on tzset.
25577
25578 2003-08-15  Paul Eggert  <eggert@twinsun.com>
25579
25580         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
25581         rather than tab, after '#' in shell-script copyright notices.
25582         Suggested by Bruno Haible.
25583
25584 2003-08-15  Paul Eggert  <eggert@twinsun.com>
25585
25586         * config/srclist-update: Use three spaces, rather than tab, after '#'
25587         in shell-script copyright notices.  Suggested by Bruno Haible.
25588         Remove unnecessary parenthesization in regular expression.
25589
25590 2003-08-15  Jim Meyering  <jim@meyering.net>
25591
25592         Merge from coreutils.
25593         * lib/xgethostname.c: Include <stdlib.h>.
25594         (xghostname): Don't exit for anything other than memory-related
25595         failure; just return NULL.
25596         * lib/userspec.c: Include "posixver.h".
25597         (parse_user_spec): Accept `.' as a separator only
25598         in pre-POSIX-200112 mode.
25599         * lib/strtoimax.c: Use #elif rather than #else #if.
25600         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
25601         Remove function, now that we can rely on a working tzset function.
25602         [!_LIBC]: Ensure that the required autoconf test has been run.
25603         [!defined _NL_CURRENT && HAVE_STRFTIME]:
25604         Use underlying_strftime for %r.
25605         * lib/sha.c: Merge in some clean-up and optimization changes from
25606         glibc.
25607         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
25608         Ensure that it is a multiple of 64.
25609         Rearrange loop exit tests so as to avoid performing an
25610         additional fread after encountering an error or EOF.
25611         * lib/realloc.c: Update copyright date.
25612
25613 2003-08-15  Jim Meyering  <jim@meyering.net>
25614         and Paul Eggert  <eggert@twinsun.com>
25615
25616         Merge from coreutils.
25617         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
25618         member but strut utmpx does not.  Needed for AIX 4.3.3.
25619         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
25620
25621 2003-08-15  Jim Meyering  <jim@meyering.net>
25622         and Paul Eggert  <eggert@cs.ucla.edu>
25623
25624         Merges from coreutils, etc.
25625         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
25626         Require gl_FUNC_TZSET_CLOBBER.
25627         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
25628         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
25629         members.
25630
25631 2003-08-14  Paul Eggert  <eggert@twinsun.com>
25632
25633         Help the merge from coreutils.
25634         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
25635         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
25636         * m4/tzset.m4: Use it too.
25637
25638 2003-08-14  Paul Eggert  <eggert@twinsun.com>
25639
25640         * modules/tzset: New file.
25641
25642 2003-08-14  Jim Meyering  <jim@meyering.net>
25643
25644         Merges from coreutils.
25645         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
25646         variable names, rather than @FNMATCH_H@.
25647         * modules/alloca: Likewise for $(ALLOCA_H).
25648
25649         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
25650         the three copies of the literal target, `fnmatch.h'.
25651         * modules/alloca (alloca.h): Likewise.
25652
25653 2003-08-14  Jim Meyering  <jim@meyering.net>
25654
25655         Merge from coreutils.
25656         * m4/tzset.m4: New file.
25657         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
25658         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
25659         otherwise, AIX 5.1 systems would end up using the latter.
25660         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
25661         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
25662         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
25663         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
25664
25665 2003-08-14  Jim Meyering  <jim@meyering.net>
25666
25667         Merge from coreutils.
25668         * lib/obstack.h: Whitespace changes.
25669         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
25670         and xcalloc return values.
25671         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
25672         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
25673         hang on OSF/1 5.1 for DIR on both local and remote file systems.
25674         Reported by (and fix confirmed by) Nelson H. F. Beebe.
25675         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
25676         error from mntctl.
25677         Use mntctl's return value to drive the entry-processing loop, since
25678         we can't rely on the value of the vmt_length member in the last
25679         entry.  On some systems doing so could result in exhausting
25680         virtual memory.  Based in part on a patch from Mike Jetzer.
25681
25682 2003-08-14  Jim Meyering  <jim@meyering.net>
25683         and Paul Eggert  <eggert@twinsun.com>
25684
25685         Merges from coreutils, plus other fixes.
25686         * lib/physmem.c: Merge in portability changes from gcc/libiberty
25687         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
25688         for credits and details.  Thanks to Kaveh Ghazi for helping
25689         to keep these files in sync.
25690         (ARRAY_SIZE): Define it.
25691         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
25692         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
25693         (memcasecmp): Don't assume size_t fits in unsigned int.
25694         Remove casts and duplicate code.
25695         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
25696         (memcpy): Remove definition.
25697         Merge in some clean-up and optimization changes from glibc.
25698         [BLOCKSIZE]: Move definition to top of file.
25699         Ensure that it is a multiple of 64.
25700         Rearrange loop exit tests so as to avoid performing an
25701         additional fread after encountering an error or EOF.
25702         * lib/md5.h (md5_uintptr): Define.
25703         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
25704         return to the initial working directory.  Preserve errno
25705         for caller.
25706         * lib/idcache.c: Include "xalloc.h".
25707         (xmalloc, xrealloc): Remove decls.
25708         (getuser): Remove casts no longer required in C89.
25709         * lib/human.c: Include stdio.h, for sprintf.
25710         * lib/group-member.c: Include "xalloc.h".
25711         (xmalloc, xrealloc): Remove decls.
25712         (get_group_info): Remove casts no longer required in C89.
25713         * lib/getusershell.c (readname): Remove casts no longer required in
25714         C89.
25715         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
25716         * lib/getline.c: Whitespace fix, from coreutils.
25717
25718 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25719
25720         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
25721         Check for isascii.
25722
25723         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
25724         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
25725         Undo previous (whitespace-only) change.
25726
25727 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25728
25729         * lib/exclude.c: Include <ctype.h>
25730         (IN_CTYPE_DOMAIN): New macro.
25731         (is_space): New fn.
25732         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
25733         and empty lines.
25734
25735         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
25736         Undo previous (whitespace-only) change.
25737
25738 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25739
25740         * config/srclist-update: Change update back to the old behavior,
25741         leaving whitespace alone.  Use one 'sed' command rather than a
25742         pipeline.
25743         (fixlicense): Now a variable, not a function.
25744         (remove_trailing_blanks): Remove.
25745         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
25746         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
25747         Undo previous (whitespace-only) change.
25748
25749 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25750
25751         Merge from coreutils.
25752         * modules/euidaccess: Add lib_SOURCES, include for new
25753         file euidaccess.h
25754
25755 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25756
25757         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
25758         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
25759         Normalize leading white space and remove trailing white space.
25760
25761         Merge from coreutils
25762         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
25763
25764         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
25765         0.12.1.  These files are now being upgraded automatically by
25766         ../config/srclist-update.
25767
25768 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25769
25770         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
25771         Normalize leading white space and remove trailing white space.
25772         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
25773         notice, as per ../config/srclist-update.
25774
25775         Merge from coreutils.
25776         * lib/euidaccess.h: New file.
25777         * lib/euidaccess.c: Include it.
25778         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
25779         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
25780         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
25781
25782 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25783
25784         * config/srclist-update: Add copyright notice.
25785         (remove_id_lines, remove_trailing_blanks): New constants.
25786         (fixfile): Use them to normalize spacing a bit in copied files.
25787         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
25788         Normalize leading white space and remove trailing white space.
25789
25790         * config/texinfo.tex: Sync with texinfo.
25791
25792         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
25793         strtoul.c from libc, to merge coreutils whitespace changes.
25794
25795         * config/srclist.txt: Get the following m4 files from gettext:
25796         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
25797         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
25798         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
25799         wint_t.m4.
25800
25801 2003-08-12  Karl Berry  <karl@gnu.org>
25802
25803         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
25804         been made.
25805
25806 2003-08-11  Paul Eggert  <eggert@twinsun.com>
25807
25808         * modules/gnu-source, m4/gnu-source.m4:
25809         Remove; we're assuming Autoconf 2.54 or later now.
25810         Suggested by Bruno Haible.
25811         * MODULES.html.sh (func_all_modules): Remove gnu-source.
25812
25813 2003-08-11  Bruno Haible  <bruno@clisp.org>
25814
25815         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
25816
25817 2003-08-11  Bruno Haible  <bruno@clisp.org>
25818
25819         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
25820         (vasnprintf): Use it instead of wcslen.
25821
25822 2003-08-11  Bruno Haible  <bruno@clisp.org>
25823
25824         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
25825         value to ensure that _Bool promotes to int. Use #define for _Bool when
25826         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
25827
25828 2003-08-10  Karl Berry  <karl@gnu.org>
25829
25830         * lib/regex.h: update from libc (whitespace fix).
25831
25832 2003-08-09  Paul Eggert  <eggert@twinsun.com>
25833
25834         Merge some files from coreutils.  These changes were
25835         originally made by Jim Meyering.
25836         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
25837         many older Unixes require this.
25838         * lib/alloca.c (alloca): Remove cast to argument of free;
25839         no longer needed in C89.
25840         * lib/alloca_.h, regex.h: Fix white space to match
25841         what GNU indent does.
25842
25843 2003-08-09  Paul Eggert  <eggert@twinsun.com>
25844
25845         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
25846         apparently Emacs's Unicode mode got confused before my 2003-08-05
25847         checkin.
25848
25849 2003-08-08  Paul Eggert  <eggert@twinsun.com>
25850
25851         * m4/extensions.m4: New file.
25852         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
25853         Require gl_USE_SYSTEM_EXTENSIONS.
25854         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
25855         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
25856
25857 2003-08-08  Paul Eggert  <eggert@twinsun.com>
25858
25859         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
25860         * modules/extensions, modules/gnu-source: New files.
25861         * modules/timespec, modules/unlocked-io: Depend on extensions.
25862
25863 2003-08-07  Paul Eggert  <eggert@twinsun.com>
25864
25865         * modules/restrict: New file.
25866         * MODULES.html.sh (func_all_modules): Add restrict.
25867         * modules/regex: Depend on restrict.
25868
25869 2003-08-07  Paul Eggert  <eggert@twinsun.com>
25870
25871         * m4/restrict.m4: New file.
25872         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
25873
25874 2003-08-07  Bruno Haible  <bruno@clisp.org>
25875
25876         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
25877         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
25878
25879 2003-08-07  Bruno Haible  <bruno@clisp.org>
25880
25881         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
25882         makes the module 'getndelim2' compatible with the module 'getline'.
25883
25884 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25885
25886         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
25887         byte with "\201" to avoid glitches when editing that source file
25888         with multi-gnome-terminal.
25889
25890 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25891
25892         * lib/bumpalloc.h: Remove.
25893
25894 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25895
25896         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
25897         * modules/bumpalloc: Remove.
25898
25899 2003-08-04  Paul Eggert  <eggert@twinsun.com>
25900
25901         * lib/getloadavg.c: Change copyright notice and spacing to conform to
25902         GNU coding style.
25903
25904         Merge from coreutils.
25905         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
25906         1. From glibc.
25907         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
25908         from Karl Berry, implemented by Jim Meyering.
25909         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
25910         from Dmitry V. Levin.
25911         Remove anachronistic cast of xrealloc.
25912         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
25913         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
25914         type. Otherwise, it wouldn't compile with at least /bin/cc on
25915         ymp-cray-unicos9.0.2.X.
25916         Combine two mostly-identical uses of alloca into one.
25917         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
25918
25919 2003-08-04  Dave Love  <d.love@dl.ac.uk>
25920
25921         [From Emacs.]
25922
25923         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
25924         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
25925         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
25926         obsolete NLIST_NAME_UNION.
25927         [__GNU__]: Undef BSD and FSCALE.
25928         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
25929
25930 2003-08-03  Paul Eggert  <eggert@twinsun.com>
25931
25932         * lib/stdbool_.h (_Bool): Make it signed char, instead of
25933         an enum type, so that it's guaranteed to promote to int.  See:
25934         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
25935
25936 2003-08-03  Karl Berry  <karl@gnu.org>
25937
25938         * config/depcomp: update from automake.
25939
25940 2003-07-31  Paul Eggert  <eggert@twinsun.com>
25941
25942         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
25943         (strerror): Don't assume that a printable int fits in 14 bytes.
25944
25945 2003-07-31  Bruno Haible  <bruno@clisp.org>
25946
25947         * modules/getpass-gnu: New file.
25948         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
25949
25950 2003-07-31  Bruno Haible  <bruno@clisp.org>
25951
25952         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
25953
25954 2003-07-24  Karl Berry  <karl@gnu.org>
25955
25956         * config/missing: update from automake.
25957
25958 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
25959             Bruno Haible  <bruno@clisp.org>
25960
25961         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
25962         * lib/getline.c (getline, getdelim): Likewise.
25963         Remove _GNU_SOURCE define; now it's defined in config.h through
25964         m4/getline.m4.
25965
25966 2003-07-23  Karl Berry  <karl@gnu.org>
25967
25968         * config/config.sub: update from prep.
25969
25970 2003-07-22  Paul Eggert  <eggert@twinsun.com>
25971
25972         * modules/xalloc (Depends-on): Add exitfail.
25973         * modules/xmemcoll: Likewise.
25974
25975 2003-07-22  Paul Eggert  <eggert@twinsun.com>
25976
25977         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
25978         over-parenthesization in macros.
25979
25980         Sync with coreutils.
25981
25982         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
25983         required by C99.
25984
25985         Use `exit_failure' for xalloc and xmemcoll instead of their own
25986         private exit-failure variables.
25987         * lib/xalloc.h (xalloc_exit_failure): Remove.
25988         * lib/xmalloc.c: Likewise.  Include exitfail.h.
25989         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
25990         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
25991         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
25992         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
25993
25994 2003-07-20  Jim Meyering  <jim@meyering.net>
25995
25996         * modules/closeout (Depends-on): Add exitfail.
25997         Suggestion from Bruno Haible.
25998
25999 2003-07-19  Karl Berry  <karl@gnu.org>
26000
26001         * config/config.sub: update from prep.
26002
26003 2003-07-18  Paul Eggert  <eggert@twinsun.com>
26004
26005         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
26006         Remove.
26007         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
26008         to test that it can stand by itself.  Include "exitfail.h".
26009         Clients should set exit_failure instead.
26010         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
26011
26012 2003-07-18  Bruno Haible  <bruno@clisp.org>
26013
26014         * modules/getndelim2: New file.
26015         * modules/getline: Share files with module getndelim2.
26016         * modules/getnline: Depend on getndelim2 instead of sharing files with
26017         it. Add getnline.c to lib_SOURCES.
26018         * MODULES.html.sh (func_all_modules): Add getndelim2.
26019
26020 2003-07-18  Bruno Haible  <bruno@clisp.org>
26021
26022         * m4/getndelim2.m4: New file.
26023         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
26024         invoke gl_PREREQ_GETNDELIM2.
26025         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
26026         gl_PREREQ_GETNDELIM2.
26027         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
26028         gl_GETNDELIM2.
26029
26030 2003-07-18  Bruno Haible  <bruno@clisp.org>
26031
26032         * lib/getndelim2.h: New file.
26033         * lib/getndelim2.c: Make into a module of its own. Include config.h,
26034         getndelim2.h.
26035         (getndelim2): Make non-static. Change return type to ssize_t.
26036         * lib/getline.h: Change argument names.
26037         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
26038         * lib/getnline.c: Include getndelim2.h.
26039
26040 2003-07-18  Andreas Schwab  <schwab@suse.de>
26041
26042         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
26043
26044 2003-07-17  Karl Berry  <karl@gnu.org>
26045
26046         * config/config.sub: update from prep.
26047
26048 2003-07-17  Bruno Haible  <bruno@clisp.org>
26049
26050         * modules/getnline: New file.
26051         * modules/getline: Add lib/getndelim2.c to source file list.
26052         * MODULES.html.sh (func_all_modules): Add getnline.
26053
26054 2003-07-17  Bruno Haible  <bruno@clisp.org>
26055
26056         * m4/getnline.m4: New file.
26057
26058 2003-07-17  Bruno Haible  <bruno@clisp.org>
26059
26060         * m4/Makefile.am.in: Remove file.
26061         * m4/Makefile.am: Remove file.
26062         * m4/Makefile.in: Remove file.
26063
26064 2003-07-17  Bruno Haible  <bruno@clisp.org>
26065
26066         * lib/getnline.h: New file.
26067         * lib/getnline.c: New file.
26068         * lib/getndelim2.c: New file, extracted from getline.c.
26069         (getndelim2): Renamed from getdelim2, with added nmax argument.
26070         * lib/getline.c: Include getndelim2.c.
26071         (getdelim2): Moved out to getndelim2.c.
26072         (getline, getdelim): Update.
26073
26074 2003-07-17  Bruno Haible  <bruno@clisp.org>
26075
26076         * lib/Makefile.am: Remove file.
26077         * lib/Makefile.in: Remove file.
26078
26079 2003-07-17  Bruno Haible  <bruno@clisp.org>
26080
26081         * configure.in: Remove file.
26082         * Makefile.in: Remove file.
26083
26084 2003-07-17  Bruno Haible  <bruno@clisp.org>
26085
26086         * MODULES.html.sh: Put the </BODY> right before </HTML>.
26087
26088 2003-07-16  Karl Berry  <karl@gnu.org>
26089
26090         * config/srclist-update: was running fixlicense twice, which caused
26091                 texinfo.tex to be nullified for some reason.  Simplify,
26092                 $gplsrc is no longer needed as far as I can see?
26093
26094 2003-07-16  Jim Meyering  <jim@meyering.net>
26095
26096         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
26097
26098 2003-07-15  Paul Eggert  <eggert@twinsun.com>
26099
26100         * config/srclist.txt: Get the following files from gettext-runtime/intl
26101         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
26102         ref-del.sin.  From Bruno Haible.
26103         * config/srclist-update (fixfile): Change grep pattern again, since the
26104         previous fix didn't work (there was another trailing $).  Use
26105         '[$]' to escape the $s.
26106
26107 2003-07-15  Karl Berry  <karl@gnu.org>
26108
26109         * lib/vasnprintf.c: update from gettext.
26110
26111 2003-07-15  Karl Berry  <karl@gnu.org>
26112
26113         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
26114         gets expanded when surrounded by '$'.
26115
26116 2003-07-15  Jim Meyering  <jim@meyering.net>
26117
26118         * modules/save-cwd: Don't depend on error.  From Derek Price.
26119
26120 2003-07-15  Jim Meyering  <jim@meyering.net>
26121
26122         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
26123
26124 2003-07-14  Simon Josefsson  <jas@extundo.com>
26125
26126         * modules/mempcpy: New file.
26127         * MODULES.html.sh (func_all_modules): Add mempcpy.
26128
26129 2003-07-14  Simon Josefsson  <jas@extundo.com>
26130
26131         * m4/mempcpy.m4: New file.
26132
26133 2003-07-14  Simon Josefsson  <jas@extundo.com>
26134
26135         * lib/mempcpy.h: New file.
26136         * lib/mempcpy.c: New file.
26137
26138 2003-07-14  Paul Eggert  <eggert@twinsun.com>
26139
26140         * modules/getdate, modules/posixtm: Depend on mktime.
26141
26142 2003-07-14  Paul Eggert  <eggert@twinsun.com>
26143
26144         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
26145         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
26146         unicodeio.c, unicodeio.h, unlocked-io.h:
26147         Switch from LGPL to GPL.
26148
26149 2003-07-14  Paul Eggert  <eggert@twinsun.com>
26150
26151         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
26152         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
26153         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
26154         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
26155         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
26156         updated automatically by ../config/srclist-update.  This changes
26157         their license from LPGL to GPL.
26158
26159 2003-07-14  Paul Eggert  <eggert@twinsun.com>
26160
26161         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
26162         assumed to refer to the root of the most recent stable gettext version.
26163         * config/srclistvars.sh: Add defaults for eggert.
26164         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
26165         Match "This program" as well as "The program".  This is needed
26166         for gettext.
26167
26168 2003-07-14  Jim Meyering  <jim@meyering.net>
26169
26170         Don't emit diagnostics.  Let callers do that.
26171         * lib/save-cwd.c: Don't include "error.h".
26172         (save_cwd): Don't call error.  Ensure that errno is valid
26173         when returning nonzero.
26174
26175         * lib/save-cwd.h (restore_cwd): Update prototype.
26176         * lib/save-cwd.c (restore_cwd): Remove two parameters.
26177         Simplify.  Don't call error upon failure.  Let callers do that.
26178         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
26179         when auditing is enabled.  But don't bother updating the #if.
26180
26181 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
26182
26183         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
26184         it breaks C++ compilation.
26185         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
26186
26187 2003-07-10  Simon Josefsson  <jas@extundo.com>
26188
26189         * modules/strchrnul (Makefile.am): Add strchrnul.h.
26190
26191 2003-07-10  Jim Meyering  <jim@meyering.net>
26192
26193         * m4/clock_time.m4: Remove trailing blank.
26194         * m4/intmax_t.m4: Likewise.
26195
26196 2003-07-10  Jim Meyering  <jim@meyering.net>
26197
26198         * lib/vasnprintf.c: Remove trailing blanks.
26199         Make cpp indentation consistent.
26200
26201 2003-07-09  Paul Eggert  <eggert@twinsun.com>
26202
26203         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
26204         posixver.c, strftime.c, strnlen.c, strverscmp.c:
26205         Switch from LGPL to GPL.
26206
26207 2003-07-09  Paul Eggert  <eggert@twinsun.com>
26208
26209         * config/srclist.txt: Sort sublists.  Add
26210         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
26211         that differ from gnulib for one reason or another; we'd like this list
26212         to be smaller but for now let's document what we have.
26213
26214 2003-07-08  Paul Eggert  <eggert@twinsun.com>
26215
26216         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
26217         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
26218         and sweeter "eval x=$x".
26219         * config/srclist.txt: Get lib/argp* from glibc.
26220
26221 2003-07-07  Paul Eggert  <eggert@twinsun.com>
26222
26223         * lib/mktime.c: Fix some boundary cases and remove need for floating
26224         point.
26225
26226         Issue a compile-time diagnostic if time_t is floating point, or if
26227         two's complement arithmetic is not in effect, or if arithmetic
26228         right shift does not propagate the sign.  These assumptions were
26229         all in the original code but they weren't checked.
26230
26231         (TIME_T_MIDPOINT, verify): New macros.
26232         (__isleap): Remove; it has integer overflow problems.
26233         (leapyear): New function, without those problems.
26234         (ydhms_tm_diff): Remove; splitting into two parts.
26235         (ydhms_diff): New function, containing the arithmetic part of
26236         the old ydhms_tm_diff function.  Issue a compile-time
26237         diagnostic if we are not using C99 integer division.
26238         Avoid casts when possible.
26239         (guess_time_tm): New function, containing the checking part of
26240         the old ydhms_tm_diff function.  Return the new value, rather than
26241         the difference between it and the old.  Accept a new argument T
26242         so that *T specifies the old value.  Check for overflow in the result.
26243
26244         (__mktime_internal): Use a time_t offset, not a long int offset.
26245         This undoes the 2003-06-04 change, which is no longer needed now
26246         that we have better overflow checking.
26247         (localtime_offset): Likewise.
26248
26249         (__mktime_internal): Avoid harmful overflow on hosts where time_t
26250         and long are 64-bit but int is only 32-bit.
26251         (ydhms_diff): Use long int to store year1 and yday1.
26252         Issue a compile-time diagnostic if long int is not wide enough.
26253
26254         (__mktime_internal): Use long int to store adjusted year and yday.
26255         Use plain C rather than preprocessor commands, if that doesn't
26256         affect efficiency.
26257         Check for overflow (and try to repair) after each probe
26258         rather than checking only at the very end.  This avoids some bugs
26259         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
26260         does not equal GMT offset at maximum time).
26261         Use integer to check for overflow rather than floating point; this
26262         is more portable to non-IEEE hosts, and is a tad faster.
26263         When we detect that we are oscillating between two values,
26264         don't check whether tm_isdst has the requested value, since
26265         we already know the answer.  When tm_isdst has the wrong value,
26266         use a different heuristic to find the right one, based on the
26267         extreme values actually observed in practice in tz2003a,
26268         rather than the (overly optimistic) "previous 3 calendar quarters".
26269
26270         (not_equal_tm, print_tm, check_result): Use "const T" rather than
26271         "T const" to accommodate glibc style.
26272         (check_result): Use less-confusing report format.  "long" -> "long int.
26273         (main): Likewise.
26274         Don't loop if the iteration overflows time_t.
26275         Allow a negative step in the iteration.
26276
26277 2003-07-06  Karl Berry  <karl@gnu.org>
26278
26279         * config/depcomp: update from automake.
26280         * config/config.sub: update from prep.
26281
26282 2003-07-03  Karl Berry  <karl@gnu.org>
26283
26284         * config/config.guess: update from prep.
26285
26286 2003-07-01  Paul Eggert  <eggert@twinsun.com>
26287
26288         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
26289         xreadlink.c now includes it unconditionally.
26290
26291 2003-07-01  Paul Eggert  <eggert@twinsun.com>
26292
26293         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
26294         having it depend on HAVE_SYS_TYPES_H.
26295
26296 2003-07-01  Bruno Haible  <bruno@clisp.org>
26297
26298         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
26299         <sys/types.h> should be sufficient.
26300         Reported by Paul Eggert.
26301
26302 2003-06-26  Karl Berry  <karl@gnu.org>
26303
26304         * config/depcomp: update from automake.
26305
26306 2003-06-26  Bruno Haible  <bruno@clisp.org>
26307
26308         * modules/human: Depend on module stdbool.
26309
26310 2003-06-25  Bruno Haible  <bruno@clisp.org>
26311
26312         * modules/readlink: New file.
26313         * modules/xreadlink: Depend on it.
26314         * MODULES.html.sh (func_all_modules): Add readlink.
26315
26316 2003-06-25  Bruno Haible  <bruno@clisp.org>
26317
26318         * m4/readlink.m4: New file.
26319
26320 2003-06-25  Bruno Haible  <bruno@clisp.org>
26321
26322         * lib/readlink.c: New file.
26323
26324 2003-06-22  Karl Berry  <karl@gnu.org>
26325
26326         * config/srclist.txt: update mkinstalldirs from automake.
26327         * config/mkinstalldirs: update.
26328
26329 2003-06-22  Bruno Haible  <bruno@clisp.org>
26330
26331         Portability to mingw32.
26332         * m4/ssize_t.m4: New file, from GNU gettext.
26333         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
26334         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
26335
26336 2003-06-22  Bruno Haible  <bruno@clisp.org>
26337
26338         * modules/safe-read: Add m4/ssize_t.m4.
26339         * modules/xreadlink: Add m4/ssize_t.m4.
26340
26341 2003-06-20  Bruno Haible  <bruno@clisp.org>
26342
26343         Assume C89, so PARAMS isn't needed.
26344         * lib/unicodeio.h (PARAMS): Remove.
26345         * lib/unicodeio.c: Don't use PARAMS.
26346
26347 2003-06-18  Karl Berry  <karl@gnu.org>
26348
26349         * config/config.{guess,sub}: update from prep.
26350
26351 2003-06-18  Jim Meyering  <jim@meyering.net>
26352
26353         Merge changes from coreutils.
26354         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
26355         Remove explicit declarations of xmalloc and realloc.
26356         Include xalloc.h.
26357         (read_utmp): Remove anachronistic cast of xmalloc.
26358
26359 2003-06-17  Paul Eggert  <eggert@twinsun.com>
26360
26361         Assume C89, so PARAMS isn't needed.
26362         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
26363         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
26364         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
26365         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
26366         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
26367         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
26368         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
26369         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
26370         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
26371         lib/xstrtod.h, lib/xstrtol.h: Likewise.
26372         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
26373         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
26374         no longer needed. Anyway, config.h should always be included before any
26375         other file.
26376
26377 2003-06-11  Simon Josefsson  <jas@extundo.com>
26378
26379         * modules/sysexits: New file.
26380         * MODULES.html.sh (func_all_modules): Add sysexits.
26381
26382 2003-06-11  Simon Josefsson  <jas@extundo.com>
26383
26384         * lib/sysexit_.h: New file.
26385
26386 2003-06-11  Derek Price  <derek@ximbiot.com>
26387
26388         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
26389         necessary.
26390
26391 2003-06-11  Bruno Haible  <bruno@clisp.org>
26392
26393         * m4/sysexits.m4: New file.
26394
26395 2003-06-10  Simon Josefsson  <jas@extundo.com>
26396
26397         * lib/argp.h: New file, from glibc.
26398         * lib/argp-ba.c: New file, from glibc.
26399         * lib/argp-eexst.c: New file, from glibc.
26400         * lib/argp-fmtstream.c: New file, from glibc.
26401         * lib/argp-fmtstream.h: New file, from glibc.
26402         * lib/argp-fs-xinl.c: New file, from glibc.
26403         * lib/argp-help.c: New file, from glibc.
26404         * lib/argp-namefrob.h: New file, from glibc.
26405         * lib/argp-parse.c: New file, from glibc.
26406         * lib/argp-pv.c: New file, from glibc.
26407         * lib/argp-pvh.c: New file, from glibc.
26408         * lib/argp-xinl.c: New file, from glibc.
26409
26410 2003-06-10  Simon Josefsson  <jas@extundo.com>
26411
26412         * modules/strchrnul: New file.
26413
26414 2003-06-10  Simon Josefsson  <jas@extundo.com>
26415
26416         * modules/argp: New file.
26417
26418 2003-06-10  Simon Josefsson  <jas@extundo.com>
26419
26420         * m4/strchrnul.m4: New file.
26421
26422 2003-06-10  Simon Josefsson  <jas@extundo.com>
26423
26424         * lib/strchrnul.h: New file.
26425         * lib/strchrnul.c: New file.
26426
26427 2003-06-10  Bruno Haible  <bruno@clisp.org>
26428
26429         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
26430
26431 2003-06-07  Karl Berry  <karl@gnu.org>
26432
26433         * config/config.{guess,sub}: update from prep.
26434
26435 2003-06-07  Jim Meyering  <jim@meyering.net>
26436
26437         * modules/strtod: Use $(...) notation, not @...@ for
26438         AC_REPLACE'd variables.
26439         * modules/localcharset: Likewise.
26440
26441 2003-06-07  Jim Meyering  <jim@meyering.net>
26442
26443         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
26444         in place of my name in the copyright comment.
26445         Remove definition and uses of __P.
26446
26447         From coreutils.
26448         * lib/stat.c: Don't declare xmalloc explicitly.
26449         Instead, include "xalloc.h".
26450         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
26451         xrealloc, and xcalloc return values.
26452         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
26453         Improve comment.
26454         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
26455
26456 2003-06-07  Bruno Haible  <bruno@clisp.org>
26457
26458         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
26459         avoid AC_CONFIG_LINKS.
26460         * modules/fnmatch (Makefile.am): Use explicit creation rule for
26461         fnmatch.h, to avoid AC_CONFIG_LINKS.
26462         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
26463
26464 2003-06-07  Bruno Haible  <bruno@clisp.org>
26465
26466         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
26467         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
26468         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
26469         directory.
26470         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
26471         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
26472         directory.
26473
26474 2003-06-06  Jim Meyering  <jim@meyering.net>
26475
26476         Merge from coreutils.
26477         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
26478         Consolidate declarations and initializations of *_base* locals.
26479
26480         Merge from coreutils.
26481         This avoids a core dump on systems without GNU putenv,
26482         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
26483         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
26484         (unsetenv): New static function, from GNU libc.
26485         (rpl_putenv): Use it.
26486
26487         * lib/modechange.c: Remove trailing blanks.
26488
26489         Merge from coreutils.
26490         * lib/fsusage.c: Remove declaration of statfs.
26491         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
26492
26493         * lib/posixtm.c: Include <stdbool.h> unconditionally.
26494
26495 2003-06-06  Jim Meyering  <jim@meyering.net>
26496
26497         * lib/stdbool_.h: Renamed from stdbool.h.in.
26498
26499 2003-06-06  Jim Meyering  <jim@meyering.net>
26500             Bruno Haible  <bruno@clisp.org>
26501
26502         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
26503         Adjust Makefile.am snippet not to redirect directly to target.
26504         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
26505
26506 2003-06-05  Paul Eggert  <eggert@twinsun.com>
26507
26508         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
26509         mismatch, look in future quarters as well as past.  This fixes a
26510         bug when processing fall-backwards gaps immediately after a long
26511         period of daylight-saving time.
26512
26513         * lib/mktime.c: Assume freestanding C89 or better.
26514         (HAVE_LIMITS_H): Remove.  Assume it's 1.
26515         (__P): Remove; not used.
26516         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
26517         (mktime, not_equal_tm, print_tm, check_result,
26518         main): Use prototypes.  Use const * where appropriate.
26519         (main): Fix typo in testing code that uncovered by above changes.
26520         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
26521
26522 2003-06-04  Paul Eggert  <eggert@twinsun.com>
26523
26524         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
26525         locale.h, localeconv.  This merges changes from coreutils.
26526
26527         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
26528         It can be removed after the next Autoconf is released.
26529         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
26530         needed.
26531
26532 2003-06-04  Paul Eggert  <eggert@twinsun.com>
26533
26534         * lib/mktime.c: Fix Debian bug 177940
26535         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
26536         (localtime_offset): Now long int, not time_t, because we want it
26537         to be guaranteed to be signed.  All uses changed.
26538         (__mktime_internal): If overflow would occur when adding offset,
26539         don't add it.
26540
26541         Merge 'human' changes from coreutils.  Rewrite to support
26542         locale-specific notations like thousands separators.
26543         * lib/human.c: Simplify authorship notice.
26544         Include human.h immediately after config.h.
26545         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
26546         <limits.h>: Do not include, since human.h does.
26547         (SIZE_MAX, UINTMAX_MAX): New macros.
26548         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
26549         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
26550         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
26551         (power_letter): Renamed from suffixes.
26552         (generate_suffix_backwards): Remove.
26553         (adjust_value): Now takes int style (because of human.h changes)
26554         and long double value (for greater precision on some platforms).
26555         (group_number): New function.
26556         (human_readable): Use it.  Use integer options, not enum.
26557         Put the options before the sizes in the arg list.
26558         Support all the new options.
26559         The old human_readable function has been removed;
26560         use inttostr.h instead.
26561         (human_readable, default_block_size, humblock):
26562         Use uintmax_t, not int, for block sizes.
26563         (human_readable_inexact, block_size_types): Remove.
26564         (block_size_opts): New constant.
26565         (human_options): Renamed from human_block_size, with new signature
26566         that allows block sizes up to UINTMAX_MAX.  All callers changed.
26567         * lib/human.h: Add copyright and authorship notice.
26568         Include <limits.h> and <stdbool.h> unconditionally.
26569         (PARAMS): Remove.  All uses removed.
26570         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
26571         (enum human_inexact_style): Remove tag; now a nameless enum.
26572         (human_floor, human_ceiling, human_round_to_even): Now have
26573         values 2, 0, 1 rather than -1, 1, 0.
26574         (human_group_digits, human_suppress_point_zero, human_autoscale,
26575         human_base_1024, human_SI, human_B): New constants.
26576         (human_readable_inexact, human_block_size): Remove.
26577         (human_readable): Size args are now uintmax_t, not int.
26578         (human_options): New decl.
26579
26580         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
26581         unnecessary now that we assume C89 or better.  This change
26582         imported from coreutils.
26583
26584         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
26585         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
26586         in the 2003-05-30 sync from glibc.
26587
26588         .h files should stand alone, but we shouldn't include <sys/types.h>
26589         if we can get away with just <stddef.h>.
26590
26591         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
26592         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
26593         rather than <sys/types.h>, as we merely need size_t.
26594         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
26595         to get size_t.
26596         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
26597         Include <stdio.h>, to get FILE.
26598         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
26599         memcasecmp.h has included <stddef.h> and all we need is size_t.
26600         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
26601         our interface, instead of including <sys/types.h>
26602
26603 2003-06-04  Paul Eggert  <eggert@twinsun.com>
26604
26605         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
26606         now, as glibc mktime is buggy on non-glibc systems.
26607
26608 2003-06-03  Karl Berry  <karl@gnu.org>
26609
26610         * config/config.sub: update from prep.
26611
26612 2003-06-02  Paul Eggert  <eggert@twinsun.com>
26613
26614         [from coreutils]
26615         Fix some minor time-related bugs with POSIX time arguments.
26616         Some valid time stamps were being rejected (notably -1, and
26617         time stamps before 1900 on 64-bit hosts).  And some invalid
26618         time stamps were being accepted, e.g. September 31.
26619
26620         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
26621         that we can return (time_t) -1 successfully.
26622         * lib/posixtm.c: Likewise.
26623         [HAVE_STDBOOL_H]: Include <stdbool.h>.
26624         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
26625         (t): Remove static var.
26626         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
26627         of static var.  All uses changed.
26628         (year): Do not reject years before 1900; they can occur with
26629         64-bit time_t.
26630         (posix_time_parse): Do not check for out-of-range components;
26631         that is now the caller's responsibility, since our checks were
26632         only approximations.
26633         (posixtime): Use mktime to check for out-of-range components,
26634         since it knows them exactly.
26635         If mktime returns (time_t) -1, check whether an error actually occurred
26636         by invoking localtime on -1.
26637         (main) [TEST_POSIXTIME]: Check for input data errors, and report
26638         posixtime failures better.
26639         Improve the test data (in comments only).
26640
26641 2003-06-02  Karl Berry  <karl@gnu.org>
26642
26643         * config/mkinstalldirs (version): new variable.
26644         (--version): new option.
26645         (usage): improve message.
26646
26647 2003-05-30  Karl Berry  <karl@gnu.org>
26648
26649         * lib/mktime.c: update from libc.
26650
26651 2003-05-30  Bruno Haible  <bruno@clisp.org>
26652
26653         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
26654         * config/config.rpath: Upgrade to gettext-0.12.1.
26655
26656 2003-05-30  Bruno Haible  <bruno@clisp.org>
26657
26658         * m4/gettext.m4: Upgrade to gettext-0.12.1.
26659         * m4/nls.m4: New file, from gettext-0.12.1.
26660         * m4/po.m4: New file, from gettext-0.12.1.
26661         * m4/progtest.m4: Upgrade to gettext-0.12.1.
26662
26663 2003-05-30  Bruno Haible  <bruno@clisp.org>
26664
26665         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
26666         * lib/localcharset.h: Likewise.
26667         * lib/localcharset.c: Likewise.
26668
26669 2003-05-29  Karl Berry  <karl@gnu.org>
26670
26671         * config/config.rpath: update from gettext.
26672
26673 2003-05-28  Paul Eggert  <eggert@twinsun.com>
26674
26675         Assume the headers required for C89 freestanding compilers.
26676         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
26677         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
26678         * m4/human.m4 (gl_HUMAN): Likewise.
26679         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
26680         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
26681         * m4/userspec.m4 (gl_USERSPEC): Likewise.
26682         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
26683         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
26684         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
26685
26686 2003-05-28  Paul Eggert  <eggert@twinsun.com>
26687
26688         Assume the headers required for C89 freestanding compilers.
26689         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
26690         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
26691         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
26692         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
26693         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
26694         define, since <limits.h> is guaranteed to do that.
26695         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
26696         * lib/exclude.c: Include <stdbool.h> unconditionally.
26697         * lib/tempname.c: Include <stddef.h> unconditionally.
26698         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
26699         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
26700         <stddef.h> does that.
26701         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
26702         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
26703         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
26704         needed.
26705         * lib/xstrtol.c: Likewise.
26706         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
26707         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
26708
26709         * lib/addext.c (addext): Use assignment rather than cast, to avoid
26710         warnings on some platforms.
26711
26712         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
26713         arbitrarily.
26714
26715 2003-05-26  Jim Meyering  <jim@meyering.net>
26716
26717         Merge in a change from coreutils:
26718         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
26719         that is guaranteed to be `no'.  Use `no_such_member' to indicate
26720         that condition, rather than `-1' which is slightly misleading.
26721         Change the name of the cache variable to have the gl_ prefix.
26722         Prompted by a patch from Richard Dawe for DJGPP.
26723
26724 2003-05-24  Karl Berry  <karl@gnu.org>
26725
26726         * config/config.guess: update from prep.
26727
26728 2003-05-22  Karl Berry  <karl@gnu.org>
26729
26730         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
26731
26732 2003-05-20  Karl Berry  <karl@gnu.org>
26733
26734         * config/config.guess: update from prep.
26735
26736 2003-05-18  Karl Berry  <karl@gnu.org>
26737
26738         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
26739         might actually be set by the user.
26740
26741         * config/depcomp, install-sh, mdate-sh: update from automake.
26742
26743 2003-05-17  Bruno Haible  <bruno@clisp.org>
26744
26745         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
26746         invalid expansion for AC_EGREP_CPP.
26747         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
26748         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
26749         Suggested by Akim Demaille <akim@epita.fr> in
26750         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
26751
26752 2003-05-12  Jim Meyering  <jim@meyering.net>
26753
26754         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
26755         the space-padded-by-default conversion specifiers, %e, %k, %l.
26756
26757 2003-05-12  Bruno Haible  <bruno@clisp.org>
26758
26759         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
26760         the string is longer than 4 KB.
26761
26762 2003-05-11  Karl Berry  <karl@gnu.org>
26763
26764         * config/config.{guess,sub}: update from prep.
26765
26766 2003-05-09  Bruno Haible  <bruno@clisp.org>
26767
26768         * modules/error: Add m4/strerror_r.m4 to file list.
26769
26770 2003-05-03  Bruno Haible  <bruno@clisp.org>
26771
26772         Upgrade to Unicode-4.0.
26773         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
26774         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
26775         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
26776         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
26777         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
26778         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
26779         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
26780         Change width of U+E0100..U+E01EF from 1 to 0.
26781
26782 2003-04-25  Jim Meyering  <jim@meyering.net>
26783
26784         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
26785         of type size_t, not int.
26786
26787 2003-04-25  Bruno Haible  <bruno@clisp.org>
26788
26789         * lib/copy-file.c: Include <stddef.h>, for size_t.
26790
26791 2003-04-21  Paul Eggert  <eggert@twinsun.com>
26792
26793         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
26794         code which expansion is under static control.  Patch imported from
26795         Akim Demaille's patch to Bison; see
26796         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
26797
26798 2003-04-14  Bruno Haible  <bruno@clisp.org>
26799
26800         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
26801
26802 2003-04-11  Jim Meyering  <jim@meyering.net>
26803
26804         Merge changes from Coreutils.
26805
26806         2003-03-22  Jim Meyering  <jim@meyering.net>
26807
26808         * lib/strftime.c (widen): Cast alloca return value to proper type.
26809
26810         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
26811
26812         From GNU libc.
26813         * lib/strftime.c (my_strftime): Handle very large width
26814         specifications for numeric values correctly.  Improve checks for
26815         overflow.
26816
26817         2003-01-19  Jim Meyering  <jim@meyering.net>
26818
26819         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
26820         definitions.
26821         (nl_get_alt_digit) [! defined my_strftime]: Define.
26822         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
26823         _nl_get_alt_digit and _nl_get_walt_digit.
26824
26825         * lib/strftime.c (my_strftime): Merge in locale-related changes from
26826         libc. These changes have no effect outside of _LIBC.
26827
26828 2003-04-10  Bruno Haible  <bruno@clisp.org>
26829
26830         * modules/findprog: New file.
26831         * MODULES.html.sh (func_all_modules): Add it.
26832
26833 2003-04-10  Bruno Haible  <bruno@clisp.org>
26834
26835         * m4/findprog.m4: New file.
26836         * m4/eaccess.m4: New file.
26837
26838 2003-04-10  Bruno Haible  <bruno@clisp.org>
26839
26840         * lib/findprog.h: New file, from GNU gettext.
26841         * lib/findprog.c: New file, from GNU gettext.
26842
26843 2003-04-05  Jim Meyering  <jim@meyering.net>
26844
26845         Merge changes from Coreutils.
26846
26847         * lib/exclude.h (PARAMS): Remove definition and uses.
26848         * lib/exclude.c: Remove uses of `PARAMS'.
26849
26850         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
26851         Add test-cases for DOS filenames. Declare program_name.
26852         (main): Set up program_name.  Patch by Rich Dawe.
26853
26854         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
26855         error from mntctl.
26856         Use mntctl's return value to drive the entry-processing loop, since
26857         we can't rely on the value of the vmt_length member in the last
26858         entry.  On some systems doing so could result in exhausting
26859         virtual memory.  Based in part on a patch from Mike Jetzer.
26860
26861 2003-04-04  Bruno Haible  <bruno@clisp.org>
26862
26863         * modules/linebreak: New file.
26864         * MODULES.html.sh (func_all_modules): Add it.
26865
26866 2003-04-04  Bruno Haible  <bruno@clisp.org>
26867
26868         * m4/linebreak.m4: New file.
26869
26870 2003-04-04  Bruno Haible  <bruno@clisp.org>
26871
26872         * lib/linebreak.h: New file, from GNU gettext.
26873         * lib/linebreak.c: New file, from GNU gettext with slight
26874         modifications.
26875         * lib/lbrkprop.h: New file, from GNU gettext.
26876
26877 2003-04-03  Bruno Haible  <bruno@clisp.org>
26878
26879         * modules/utf8-ucs4: New file.
26880         * modules/utf16-ucs4: New file.
26881         * modules/ucs4-utf8: New file.
26882         * modules/ucs4-utf16: New file.
26883         * MODULES.html.sh (func_all_modules): Add them.
26884
26885 2003-04-03  Bruno Haible  <bruno@clisp.org>
26886
26887         * m4/utf-ucs4.m4: New file.
26888         * m4/ucs4-utf.m4: New file.
26889
26890 2003-04-03  Bruno Haible  <bruno@clisp.org>
26891
26892         * lib/utf8-ucs4.h: New file, from GNU gettext.
26893         * lib/utf16-ucs4.h: New file, from GNU gettext.
26894         * lib/ucs4-utf8.h: New file, from GNU gettext.
26895         * lib/ucs4-utf16.h: New file, from GNU gettext.
26896
26897 2003-04-02  Bruno Haible  <bruno@clisp.org>
26898
26899         * modules/binary-io: New file.
26900         * MODULES.html.sh (func_all_modules): Add it.
26901
26902 2003-04-02  Bruno Haible  <bruno@clisp.org>
26903
26904         * lib/binary-io.h: New file, from GNU gettext.
26905
26906 2003-04-01  Bruno Haible  <bruno@clisp.org>
26907
26908         * modules/pathname: New file.
26909         * MODULES.html.sh (func_all_modules): Add it.
26910
26911 2003-04-01  Bruno Haible  <bruno@clisp.org>
26912
26913         * lib/pathname.h: New file, from GNU gettext.
26914         * lib/concatpath.c: New file, from GNU gettext.
26915
26916 2003-03-30  Bruno Haible  <bruno@clisp.org>
26917
26918         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
26919
26920 2003-03-30  Bruno Haible  <bruno@clisp.org>
26921
26922         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
26923         function chown() doesn't exist.
26924
26925 2003-03-28  Bruno Haible  <bruno@clisp.org>
26926
26927         * modules/copy-file: New file.
26928         * MODULES.html.sh (func_all_modules): Add it.
26929
26930 2003-03-28  Bruno Haible  <bruno@clisp.org>
26931
26932         * m4/copy-file.m4: New file.
26933
26934 2003-03-28  Bruno Haible  <bruno@clisp.org>
26935
26936         * lib/copy-file.h: New file, from GNU gettext.
26937         * lib/copy-file.c: New file, from GNU gettext.
26938
26939 2003-03-18  Jim Meyering  <jim@meyering.net>
26940
26941         * lib/quote.c (quote_n): Fix typo in comment.
26942
26943 2003-03-18  Bruno Haible  <bruno@clisp.org>
26944
26945         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
26946         checking.
26947         * m4/onceonly_2_57.m4: Likewise.
26948
26949 2003-03-17  Bruno Haible  <bruno@clisp.org>
26950
26951         * m4/onceonly.m4: Require autoconf 2.54 or newer.
26952         (m4_quote): Remove macro.
26953         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
26954
26955 2003-03-14  Jim Meyering  <jim@meyering.net>
26956
26957         Merge changes from Coreutils.
26958         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
26959         to be const, in order to avoid warnings.
26960         (obstack_room): Likewise.
26961         (obstack_empty_p): Likewise.
26962
26963 2003-03-14  Bruno Haible  <bruno@clisp.org>
26964
26965         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
26966         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
26967
26968 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26969
26970         Merge changes from Bison.
26971         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
26972         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
26973         when compiling Bison 1.875's `bitset bset = obstack_alloc
26974         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
26975         * lib/hash.c: Include <stdbool.h> unconditionally.
26976
26977 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26978
26979         * m4/onceonly.m4 (m4_quote): New macro.
26980         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
26981         Quote AC_FOREACH variable-expansions properly.
26982
26983 2003-03-13  Paul Eggert  <eggert@twinsun.com>
26984
26985         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
26986
26987 2003-03-09  Paul Eggert  <eggert@twinsun.com>
26988
26989         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
26990         Reported by Bruce Becker; see:
26991         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
26992
26993 2003-03-03  Paul Eggert  <eggert@twinsun.com>
26994             Bruno Haible  <bruno@clisp.org>
26995
26996         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
26997         Reported by John Hughes, see
26998         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
26999
27000 2003-02-20  Bruno Haible  <bruno@clisp.org>
27001
27002         * MODULES.html.sh (func_all_modules): Add poll.
27003
27004 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
27005
27006         * modules/poll: New file.
27007
27008 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
27009
27010         * lib/poll_.h: New file.
27011         * lib/poll.c: New file.
27012
27013 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
27014
27015         * m4/poll.m4: New file.
27016
27017 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
27018
27019         * modules/mathl: New file.
27020
27021 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
27022
27023         * lib/mathl.h: New file.
27024         * lib/acosl.c: New file.
27025         * lib/asinl.c: New file.
27026         * lib/atanl.c: New file.
27027         * lib/ceill.c: New file.
27028         * lib/cosl.c: New file.
27029         * lib/expl.c: New file.
27030         * lib/floorl.c: New file.
27031         * lib/frexpl.c: New file.
27032         * lib/ldexpl.c: New file.
27033         * lib/logl.c: New file.
27034         * lib/sincosl.c: New file.
27035         * lib/sinl.c: New file.
27036         * lib/sqrtl.c: New file.
27037         * lib/tanl.c: New file.
27038         * lib/trigl.c: New file.
27039         * lib/trigl.h: New file.
27040
27041 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
27042
27043         * m4/mathl.m4: New file.
27044
27045 2003-02-18  Bruno Haible  <bruno@clisp.org>
27046
27047         * MODULES.html.sh (func_all_modules): Add mathl.
27048
27049 2003-02-17  Bruno Haible  <bruno@clisp.org>
27050
27051         * modules/mkdtemp: New module.
27052         * MODULES.html.sh (func_all_modules): Add it.
27053
27054 2003-02-17  Bruno Haible  <bruno@clisp.org>
27055
27056         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
27057
27058 2003-02-17  Bruno Haible  <bruno@clisp.org>
27059
27060         * lib/mkdtemp.h: New file, from GNU gettext.
27061         * lib/mkdtemp.c: New file, from GNU gettext.
27062
27063 2003-02-02  Jim Meyering  <jim@meyering.net>
27064
27065         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
27066         e.g. glibc-2.2.93.
27067
27068 2003-01-31  Bruno Haible  <bruno@clisp.org>
27069
27070         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
27071         'rpl_rename'.
27072         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
27073         'rpl_strnlen'.
27074         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
27075         'rpl_strtod'.
27076         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
27077         'rpl_utime'.
27078
27079 2003-01-31  Bruno Haible  <bruno@clisp.org>
27080
27081         * lib/rename.c: #undef rename before defining rpl_rename.
27082         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
27083
27084 2003-01-30  Bruno Haible  <bruno@clisp.org>
27085
27086         * modules/vasnprintf, modules/vasprintf: New modules.
27087         * MODULES.html.sh (func_all_modules): Add them.
27088
27089 2003-01-30  Bruno Haible  <bruno@clisp.org>
27090
27091         * m4/signed.m4: New file, from GNU gettext.
27092         * m4/longdouble.m4: New file, from GNU gettext.
27093         * m4/wchar_t.m4: New file, from GNU gettext.
27094         * m4/wint_t.m4: New file, from GNU gettext.
27095         * m4/vasnprintf.m4: New file.
27096         * m4/vasprintf.m4: New file.
27097
27098 2003-01-30  Bruno Haible  <bruno@clisp.org>
27099
27100         * lib/printf-args.h: New file, from GNU gettext.
27101         * lib/printf-args.c: New file, from GNU gettext.
27102         * lib/printf-parse.h: New file, from GNU gettext.
27103         * lib/printf-parse.c: New file, from GNU gettext.
27104         * lib/vasnprintf.h: New file, from GNU gettext.
27105         * lib/vasnprintf.c: New file, from GNU gettext.
27106         * lib/asnprintf.c: New file, from GNU gettext.
27107         * lib/vasprintf.h: New file, from GNU gettext with modifications.
27108         * lib/vasprintf.c: New file, from GNU gettext.
27109         * lib/asprintf.c: New file, from GNU gettext.
27110
27111 2003-01-29  Bruno Haible  <bruno@clisp.org>
27112
27113         * modules/stpncpy: New module.
27114         * MODULES.html.sh (func_all_modules): Add it.
27115
27116 2003-01-29  Bruno Haible  <bruno@clisp.org>
27117
27118         * m4/stpncpy.m4: New file.
27119
27120 2003-01-29  Bruno Haible  <bruno@clisp.org>
27121
27122         * lib/stpncpy.h: New file, from GNU gettext with modifications.
27123         * lib/stpncpy.c: New file, from GNU gettext with modifications.
27124
27125 2003-01-28  Bruno Haible  <bruno@clisp.org>
27126
27127         * modules/c-ctype: New module.
27128         * MODULES.html.sh (func_all_modules): Add it.
27129
27130 2003-01-28  Bruno Haible  <bruno@clisp.org>
27131
27132         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
27133         Paul Eggert.
27134         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
27135         Paul Eggert.
27136
27137 2003-01-27  Bruno Haible  <bruno@clisp.org>
27138
27139         * modules/xsetenv: New module.
27140         * MODULES.html.sh (func_all_modules): Add it.
27141
27142 2003-01-27  Bruno Haible  <bruno@clisp.org>
27143
27144         * lib/xsetenv.h: New file, from GNU gettext.
27145         * lib/xsetenv.c: New file, from GNU gettext.
27146
27147 2003-01-23  Jim Meyering  <jim@meyering.net>
27148
27149         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
27150         from working on systems without dirfd (at least Irix and OSF1/Tru64).
27151
27152 2003-01-23  Bruno Haible  <bruno@clisp.org>
27153
27154         * modules/minmax: New module.
27155         * MODULES.html.sh (func_all_modules): Add it.
27156
27157 2003-01-23  Bruno Haible  <bruno@clisp.org>
27158
27159         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
27160         Eggert.
27161
27162 2003-01-22  Bruno Haible  <bruno@clisp.org>
27163
27164         * modules/exit: New module.
27165         * MODULES.html.sh (func_all_modules): Add it.
27166
27167 2003-01-22  Bruno Haible  <bruno@clisp.org>
27168
27169         * lib/exit.h: New file, from GNU gettext.
27170
27171 2003-01-19  Bruno Haible  <bruno@clisp.org>
27172
27173         * gnulib-tool: Recognize option --extract-maintainer.
27174         (func_get_maintainer): New function.
27175         * modules/*: Add Maintainer entry.
27176
27177 2003-01-16  Jim Meyering  <jim@meyering.net>
27178
27179         * m4/regex.m4: The `regex' struct is both input and output.
27180         Initialize it before each use.  Patch by Tim Waugh.
27181
27182 2003-01-16  Bruno Haible  <bruno@clisp.org>
27183
27184         * MODULES.html.sh: Add a table of contents. Add the module name as
27185         leftmost column. Add hyperlinks.
27186
27187 2003-01-15  Bruno Haible  <bruno@clisp.org>
27188
27189         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
27190
27191 2003-01-15  Bruno Haible  <bruno@clisp.org>
27192
27193         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
27194         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
27195         suffix.
27196
27197 2003-01-15  Bruno Haible  <bruno@clisp.org>
27198
27199         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
27200
27201 2003-01-15  Bruno Haible  <bruno@clisp.org>
27202
27203         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
27204         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
27205
27206 2003-01-14  Jim Meyering  <jim@meyering.net>
27207
27208         * lib/same.c (same_name): Tweak a comment.
27209
27210 2003-01-14  Bruno Haible  <bruno@clisp.org>
27211
27212         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
27213         when a string comparison is sufficient.
27214
27215 2003-01-14  Bruno Haible  <bruno@clisp.org>
27216
27217         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
27218         'unsigned int'.
27219
27220 2003-01-14  Bruno Haible  <bruno@clisp.org>
27221
27222         * lib/hash-pjw.c: Add comment about low quality of this function.
27223
27224 2003-01-13  Bruno Haible  <bruno@clisp.org>
27225
27226         * modules/stpcpy: Distribute lib/stpcpy.h.
27227         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
27228
27229 2003-01-13  Bruno Haible  <bruno@clisp.org>
27230
27231         * modules/*: Add a description.
27232         * modules/strpbrk: Fix Makefile.am snippet.
27233         * modules/strtoimax: Fix dependencies.
27234         * modules/strtoumax: Likewise.
27235
27236 2003-01-13  Bruno Haible  <bruno@clisp.org>
27237
27238         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
27239         * modules/alloca (Makefile.am): All object files depend on alloca.h.
27240         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
27241
27242 2003-01-13  Bruno Haible  <bruno@clisp.org>
27243
27244         * gnulib-tool (func_create_testdir): Store config/* files in the main
27245         directory.
27246         * config.rpath: Move to ...
27247         * config/config.rpath: ... here.
27248         * modules/gettext: Contains config/config.rpath, not config.rpath.
27249         * modules/iconv: Likewise.
27250
27251 2003-01-12  Paul Eggert  <eggert@twinsun.com>
27252
27253         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
27254         to avoid collisions with libcurses and libreadline.
27255
27256         * m4/getstr.m4: Remove.
27257         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
27258
27259 2003-01-12  Paul Eggert  <eggert@twinsun.com>
27260
27261         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
27262         to avoid collisions with libcurses and libreadline.
27263
27264         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
27265         * lib/getstr.h, getstr.c: Remove.
27266         * lib/getline.c: Include "getline.h", to check interface.
27267         Move body of old getstr.c here: this defines MIN_CHUNK and
27268         declares getdelim2, which is renamed from getstr.
27269         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
27270
27271         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
27272         All uses changed.
27273         * lib/linebuffer.h: Likewise.
27274         (readline): Remove backward-compatibility macro.
27275
27276 2003-01-12  Paul Eggert  <eggert@twinsun.com>
27277
27278         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
27279         to avoid collisions with libcurses and libreadline.
27280         * getstr: Remove.
27281         * MODULES.html.sh: Remove getstr.
27282         * modules/getline: Depend on unlocked-io, not getstr.
27283
27284 2003-01-12  Jim Meyering  <jim@meyering.net>
27285
27286         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
27287
27288 2003-01-10  Bruno Haible  <bruno@clisp.org>
27289
27290         * modules/alloca: Change Makefile.am requirements. Simplify Include
27291         requirements. Add lib/alloca_.h to file list.
27292
27293 2003-01-10  Bruno Haible  <bruno@clisp.org>
27294
27295         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
27296
27297 2003-01-10  Bruno Haible  <bruno@clisp.org>
27298
27299         * lib/alloca_.h: New file.
27300         * lib/getdate.y: Unconditionally include alloca.h.
27301         * lib/makepath.c: Likewise.
27302         * lib/setenv.c: Likewise.
27303         * lib/userspec.c: Likewise.
27304
27305 2003-01-09  Karl Berry  <karl@gnu.org>
27306
27307         * MODULES.html.sh: include `dirname $0` in PATH, to find
27308         gnulib-tool.
27309
27310 2003-01-09  Bruno Haible  <bruno@clisp.org>
27311
27312         * modules/stdbool: Change configure.ac, Makefile.am requirements.
27313         Simplify Include requirements. Add lib/stdbool.h.in to file list.
27314
27315 2003-01-09  Bruno Haible  <bruno@clisp.org>
27316
27317         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
27318
27319 2003-01-09  Bruno Haible  <bruno@clisp.org>
27320
27321         * lib/stdbool.h.in: New file.
27322
27323 2003-01-09  Bruno Haible  <bruno@clisp.org>
27324
27325         * gnulib-tool (func_all_modules): Ignore files ending in ~.
27326         * MODULES.html.sh: Likewise.
27327
27328 2003-01-08  Jim Meyering  <jim@meyering.net>
27329
27330         * lib/full-write.c: Undefine and define-away `const' after inclusion
27331         of errno.h, not before.  Suggestion from Bruno Haible.
27332
27333 2003-01-08  Bruno Haible  <bruno@clisp.org>
27334
27335         * modules/full-read: Depend on full-write.
27336
27337 2003-01-08  Bruno Haible  <bruno@clisp.org>
27338
27339         * lib/safe-read.c: Include specification header first, to ensure its
27340         selfcontainedness.
27341         * lib/full-write.c: Likewise.
27342
27343 2003-01-07  Jim Meyering  <jim@meyering.net>
27344
27345         * lib/full-write.c: Rework so that it may serve to define full_read,
27346         too.
27347         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
27348
27349 2003-01-07  Bruno Haible  <bruno@clisp.org>
27350
27351         * lib/strtoimax.c: Include <stdint.h> as an alternative to
27352         <inttypes.h>.
27353         * lib/xstrtol.h: Likewise.
27354         * lib/xstrtoimax.c: Likewise.
27355         * lib/xstrtoumax.c: Likewise.
27356         * lib/human.h: Likewise.
27357
27358         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
27359         on systems that have <inttypes.h> but not <stdint.h>.
27360
27361 2003-01-07  Bruno Haible  <bruno@clisp.org>
27362
27363         * MODULES.html.sh: Add copyright notice.
27364         (missed_files): Omit CVS directory entries.
27365         (func_module): Make it work with sed-3.02.
27366         * MODULES.txt: Remove file.
27367
27368 2003-01-06  Jim Meyering  <jim@meyering.net>
27369
27370         * lib/version-etc.c: Update year in translatable copyright string.
27371
27372 2003-01-03  Karl Berry  <karl@gnu.org>
27373
27374         * config/config.{guess,sub}: update from prep.
27375
27376 2003-01-02  Karl Berry  <karl@gnu.org>
27377
27378         * doc/COPYING.DOC: belatedly updated to 1.2.
27379
27380 2003-01-01  Karl Berry  <karl@gnu.org>
27381
27382         * gnulib-tool (func_verify_module): report module name $module in
27383         error message, not $1.
27384         * gnulib-tool (create-testdir): don't complain if destdir couldn't
27385         be created, only if it doesn't exist.
27386         * gnulib-tool (last_checkin_date): don't expand the $Date here.
27387
27388 2002-12-31  Paul Eggert  <eggert@twinsun.com>
27389
27390         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
27391
27392 2002-12-31  Paul Eggert  <eggert@twinsun.com>
27393
27394         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
27395         memcmp if strcoll doesn't work.
27396
27397 2002-12-31  Bruno Haible  <bruno@clisp.org>
27398
27399         * lib/utime.c (utime_null): No need to call ftruncate if the file was
27400         nonempty.
27401
27402 2002-12-31  Bruno Haible  <bruno@clisp.org>
27403
27404         * lib/memcoll.c (STRCOLL): New macro.
27405         (memcoll): Use it.
27406
27407 2002-12-31  Bruno Haible  <bruno@clisp.org>
27408
27409         * lib/localcharset.h: New file.
27410         * lib/localcharset.c: Include it.
27411         * lib/unicodeio.c: Likewise.
27412
27413 2002-12-31  Bruno Haible  <bruno@clisp.org>
27414
27415         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
27416         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
27417
27418 2002-12-31  Bruno Haible  <bruno@clisp.org>
27419
27420         * lib/getline.h: Include <stddef.h>, for size_t.
27421
27422         * lib/unicodeio.h: Include <stddef.h>, for size_t.
27423         * lib/unicodeio.c: Don't include <stddef.h>.
27424
27425 2002-12-31  Bruno Haible  <bruno@clisp.org>
27426
27427         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
27428         HAVE_TM_ZONE.
27429
27430 2002-12-24  Karl Berry  <karl@gnu.org>
27431
27432         * config/config.guess: update from prep.
27433
27434 2002-12-24  Bruno Haible  <bruno@clisp.org>
27435
27436         General infrasructure.
27437         * m4/README: Rewritten.
27438         * m4/onceonly.m4: New file.
27439         * m4/onceonly_2_57.m4: New file.
27440
27441         Module atexit.
27442         * m4/atexit.m4: New file.
27443
27444         Module strtod.
27445         * m4/strtod.m4: New file.
27446
27447         Module strtol.
27448         * m4/strtol.m4: New file.
27449
27450         Module strtoul.
27451         * m4/strtoul.m4: New file.
27452
27453         Module memchr.
27454         * m4/memchr.m4: New file.
27455
27456         Module memcmp.
27457         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
27458         (jm_FUNC_MEMCMP): Invoke it.
27459
27460         Module memcpy.
27461         * m4/memcpy.m4: New file.
27462
27463         Module memmove.
27464         * m4/memmove.m4: New file.
27465
27466         Module memset.
27467         * m4/memset.m4: New file.
27468
27469         Module strcspn.
27470         * m4/strcspn.m4: New file.
27471
27472         Module strpbrk.
27473         * m4/strpbrk.m4: New file.
27474
27475         Module strstr.
27476         * m4/strstr.m4: New file.
27477
27478         Module strerror.
27479         * m4/strerror.m4: New file.
27480
27481         Module mktime.
27482         * m4/mktime.m4: Renamed from jm-mktime.m4.
27483         (gl_PREREQ_MKTIME): New macro.
27484         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
27485
27486         Module malloc.
27487         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
27488         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
27489         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
27490
27491         Module realloc.
27492         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
27493         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
27494         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
27495
27496         Module strftime.
27497         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
27498         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
27499         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
27500         gl_TM_GMTOFF.
27501         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
27502
27503         Module xalloc.
27504         * m4/xalloc.m4: New file.
27505
27506         Module alloca.
27507         * m4/alloca.m4: New file.
27508
27509         Module putenv.
27510         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
27511         (jm_FUNC_PUTENV): Invoke it.
27512
27513         Module setenv.
27514         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
27515         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
27516         when invoked twice.
27517         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
27518         gt_FUNC_SETENV.
27519
27520         Module memrchr.
27521         * m4/memrchr.m4: New file.
27522
27523         Module stpcpy.
27524         * m4/stpcpy.m4: New file.
27525
27526         Module strcase.
27527         * m4/strcase.m4: New file.
27528
27529         Module strdup.
27530         * m4/strdup.m4: New file.
27531
27532         Module strnlen.
27533         * m4/strnlen.m4: New file.
27534
27535         Module strndup.
27536         * m4/strndup.m4: New file.
27537
27538         Module xstrtod.
27539         * m4/xstrtod.m4: New file.
27540
27541         Module xstrtol.
27542         * m4/xstrtol.m4: New file.
27543
27544         Module getdate.
27545         * m4/getdate.m4: New file.
27546
27547         Module unlocked-io.
27548         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
27549         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
27550         * m4/jm-glibc-io.m4n: Remove file.
27551
27552         Module long-options.
27553         * m4/long-options.m4: New file.
27554
27555         Module md5.
27556         * m4/md5.m4: New file.
27557
27558         Module sha.
27559         * m4/sha.m4: New file.
27560
27561         Module getstr.
27562         * m4/getstr.m4: New file.
27563
27564         Module getline.
27565         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
27566         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
27567         <sys/types.h>, for size_t. Use the function name gnu_getline, not
27568         simply getline. Infoke gl_PREREQ_GETLINE.
27569
27570         Module obstack.
27571         * m4/obstack.m4: New file.
27572
27573         Module hash.
27574         * m4/hash.m4: New file.
27575
27576         Module readtokens.
27577         * m4/readtokens.m4: New file.
27578
27579         Module strverscmp.
27580         * m4/strverscmp.m4: New file.
27581
27582         Module stdbool.
27583         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
27584         OSF/1.
27585
27586         Module strtoll.
27587         * m4/strtoll.m4: New file.
27588
27589         Module strtoull.
27590         * m4/strtoull.m4: New file.
27591
27592         Module strtoimax.
27593         * m4/strtoimax.m4: New file.
27594
27595         Module strtoumax.
27596         * m4/strtoumax.m4: New file.
27597
27598         Module xstrtoimax.
27599         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
27600         jm_AC_PREREQ_XSTRTOIMAX.
27601         Moved the strtol prerequisites to strtol.m4.
27602         Moved the strtoll prerequisites to strtoll.m4.
27603         Moved the strtoimax prerequisites to strtoimax.m4.
27604
27605         Module xstrtoumax.
27606         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
27607         jm_AC_PREREQ_XSTRTOUMAX.
27608         Moved the strtoul prerequisites to strtoul.m4.
27609         Moved the strtoull prerequisites to strtoull.m4.
27610         Moved the strtoumax prerequisites to strtoumax.m4.
27611
27612         Module chown.
27613         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
27614         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
27615
27616         Module dup2.
27617         * m4/dup2.m4: New file.
27618
27619         Module ftruncate.
27620         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
27621         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
27622
27623         Module getgroups.
27624         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
27625         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
27626
27627         Module gettimeofday.
27628         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
27629         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
27630         gl_PREREQ_GETTIMEOFDAY.
27631
27632         Module mkdir.
27633         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
27634         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
27635
27636         Module mkstemp.
27637         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
27638         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
27639         jm_AC_TYPE_UINTMAX_T.
27640         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
27641
27642         Module stat.
27643         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
27644         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
27645
27646         Module lstat.
27647         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
27648         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
27649
27650         Module timespec.
27651         * m4/timespec.m4 (gl_TIMESPEC): New macro.
27652         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
27653         * m4/st_mtim.m4: Indentation.
27654
27655         Module nanosleep.
27656         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
27657         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
27658         gl_PREREQ_NANOSLEEP.
27659
27660         Module regex.
27661         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
27662         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
27663         (gl_REGEX): New macro.
27664
27665         Module rename.
27666         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
27667         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
27668
27669         Module rmdir.
27670         * m4/rmdir.m4: New file.
27671
27672         Module utime.
27673         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
27674         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
27675         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
27676
27677         Module dirname.
27678         * m4/dirname.m4: New file.
27679
27680         Module getopt.
27681         * m4/getopt.m4: New file.
27682
27683         Module unistd-safer.
27684         * m4/unistd-safer.m4: New file.
27685
27686         Module fnmatch.
27687         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
27688         declaration.
27689         (gl_PREREQ_FNMATCH_EXTRA): New macro.
27690         (gl_FUNC_FNMATCH_POSIX): New macro.
27691         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
27692         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
27693         simply fnmatch.
27694
27695         Module exclude.
27696         * m4/exclude.m4: New file.
27697
27698         Module human.
27699         * m4/human.m4: New file.
27700
27701         Module acl.
27702         * m4/acl.m4: Nop.
27703
27704         Module backupfile.
27705         * m4/backupfile.m4: New file.
27706         * m4/d-ino.m4: Indentation.
27707
27708         Module fsusage.
27709         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
27710         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
27711         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
27712
27713         Module dirfd.
27714         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
27715         requirements.
27716
27717         Module euidaccess.
27718         * m4/euidaccess.m4: New file.
27719
27720         Module file-type.
27721         * m4/file-type.m4: New file.
27722
27723         Module fileblocks.
27724         * m4/fileblocks.m4: New file.
27725
27726         Module filemode.
27727         * m4/filemode.m4: New file.
27728
27729         Module isdir.
27730         * m4/isdir.m4: New file.
27731
27732         Module lchown.
27733         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
27734         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
27735
27736         Module makepath.
27737         * m4/makepath.m4: New file.
27738
27739         Module modechange.
27740         * m4/modechange.m4: New file.
27741
27742         Module mountlist.
27743         * m4/mountlist.m4: New file.
27744         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
27745         Indentation.
27746
27747         Module path-concat.
27748         * m4/path-concat.m4: New file.
27749
27750         Module pathmax.
27751         * m4/pathmax.m4: New file.
27752
27753         Module same.
27754         * m4/same.m4: New file.
27755
27756         Module save-cwd.
27757         * m4/save-cwd.m4: New file.
27758
27759         Module savedir.
27760         * m4/savedir.m4: New file.
27761
27762         Module xgetcwd.
27763         * m4/xgetcwd.m4: New file.
27764         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
27765
27766         Module xreadlink.
27767         * m4/xreadlink.m4: New file.
27768
27769         Module safe-read.
27770         * m4/safe-read.m4: New file.
27771
27772         Module safe-write.
27773         * m4/safe-write.m4: New file.
27774
27775         Module closeout.
27776         * m4/closeout.m4: New file.
27777
27778         Module stdio-safer.
27779         * m4/stdio-safer.m4: New file.
27780
27781         Module getpass.
27782         * m4/getpass.m4: New file.
27783
27784         Module getugroups.
27785         * m4/getugroups.m4: New file.
27786
27787         Module group-member.
27788         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
27789         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
27790
27791         Module idcache.
27792         * m4/idcache.m4: New file.
27793
27794         Module userspec.
27795         * m4/userspec.m4: New file.
27796
27797         Module gettime.
27798         * m4/clock_time.m4: New file.
27799         * m4/gettime.m4: New file.
27800
27801         Module settime.
27802         * m4/settime.m4: New file.
27803
27804         Module posixtm.
27805         * m4/posixtm.m4: New file.
27806
27807         Module gethostname.
27808         * m4/gethostname.m4: New file.
27809
27810         Module canon-host.
27811         * m4/canon-host.m4: New file.
27812
27813         Module gettext.
27814         * m4/codeset.m4: New file, from gettext-0.11.5.
27815         * m4/gettext.m4: New file, from gettext-0.11.5.
27816         * m4/glibc21.m4: New file, from gettext-0.11.5.
27817         * m4/iconv.m4: New file, from gettext-0.11.5.
27818         * m4/intdiv0.m4: New file, from gettext-0.11.5.
27819         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
27820         * m4/inttypes.m4: New file, from gettext-0.11.5.
27821         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
27822         * m4/isc-posix.m4: New file, from gettext-0.11.5.
27823         * m4/lcmessage.m4: New file, from gettext-0.11.5.
27824         * m4/lib-ld.m4: New file, from gettext-0.11.5.
27825         * m4/lib-link.m4: New file, from gettext-0.11.5.
27826         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
27827         * m4/progtest.m4: New file, from gettext-0.11.5.
27828         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
27829         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
27830         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
27831
27832         Module localcharset.
27833         * m4/localcharset.m4: New file.
27834
27835         Module hard-locale.
27836         * m4/hard-locale.m4: New file.
27837
27838         Module mbswidth.
27839         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
27840         onceonly macros.
27841         * m4/mbrtowc.m4: Add comment.
27842
27843         Module memcasecmp.
27844         * m4/memcasecmp.m4: New file.
27845
27846         Module memcoll.
27847         * m4/memcoll.m4: New file.
27848
27849         Module unicodeio.
27850         * m4/unicodeio.m4: New file.
27851
27852         Module rpmatch.
27853         * m4/rpmatch.m4: New file.
27854
27855         Module yesno.
27856         * m4/yesno.m4: New file.
27857
27858         Module exitfail.
27859         * m4/exitfail.m4: New file.
27860
27861         Module c-stack.
27862         * m4/c-stack.m4 (gl_C_STACK): New macro.
27863         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
27864
27865         Module error.
27866         * m4/error.m4 (gl_ERROR): New macro.
27867         (jm_PREREQ_ERROR): Use onceonly macros.
27868
27869         Module fatal.
27870         * m4/fatal.m4: New file.
27871
27872         Module getloadavg.
27873         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
27874         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
27875
27876         Module getpagesize.
27877         * m4/getpagesize.m4: New file.
27878
27879         Module getusershell.
27880         * m4/getusershell.m4: New file.
27881
27882         Module physmem.
27883         * m4/physmem.m4: New file.
27884
27885         Module posixver.
27886         * m4/posixver.m4: New file.
27887
27888         Module quotearg.
27889         * m4/quotearg.m4: New file.
27890
27891         Module quote.
27892         * m4/quote.m4: New file.
27893
27894         Module readutmp.
27895         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
27896
27897         Module sig2str.
27898         * m4/sig2str.m4: New file.
27899
27900         Other.
27901         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
27902         ulonglong.m4.
27903         * m4/intmax_t.m4: New file.
27904         * m4/d-type.m4: Indentation.
27905         * m4/jm-macros.m4: Update.
27906         * m4/prereq.m4 (jm_PREREQ): Update.
27907         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
27908         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
27909         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
27910         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
27911         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
27912         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
27913         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
27914         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
27915         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
27916         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
27917         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
27918         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
27919         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
27920         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
27921         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
27922         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
27923         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
27924         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
27925         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
27926
27927 2002-12-24  Bruno Haible  <bruno@clisp.org>
27928
27929         * MODULES.txt: Update according to m4/ changes.
27930
27931         Module gettext.
27932         * config.rpath: New file, from gettext-0.11.5.
27933
27934         * modules/*: New module descriptions.
27935         * gnulib-tool: New file.
27936         * MODULES.html.sh: New file.
27937
27938 2002-12-21  Karl Berry  <karl@gnu.org>
27939
27940         * doc/fdl.texi: update to version 1.2.
27941
27942 2002-12-19  Karl Berry  <karl@gnu.org>
27943
27944         * config/config.guess: update from prep.
27945
27946 2002-12-18  Bruno Haible  <bruno@clisp.org>
27947
27948         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
27949         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
27950
27951 2002-12-17  Bruno Haible  <bruno@clisp.org>
27952
27953         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
27954         stdlib.h, string.h.
27955
27956 2002-12-17  Bruno Haible  <bruno@clisp.org>
27957
27958         * lib/canon-host.c (strdup): Remove unused declaration.
27959
27960         * lib/fsusage.c: Include full_read.h.
27961         (get_fs_usage): Use full_read instead of safe_read.
27962
27963         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
27964
27965 2002-12-12  Karl Berry  <karl@gnu.org>
27966
27967         * config/config.guess: update from prep.
27968
27969 2002-12-11  Bruno Haible  <bruno@clisp.org>
27970
27971         * m4/setenv.m4: New file, from gettext-0.11.5.
27972
27973 2002-12-11  Bruno Haible  <bruno@clisp.org>
27974
27975         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
27976         not unsetenv().
27977         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
27978         modifications:
27979
27980         2002-12-11  Bruno Haible  <bruno@clisp.org>
27981
27982                 * setenv.c (alloca): Fall back to malloc.
27983                 (freea): New macro.
27984                 (setenv): Use freea() to free memory allocated with alloca().
27985
27986         2002-11-13  Bruno Haible  <bruno@clisp.org>
27987
27988                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
27989                 function declarations.
27990                 * unsetenv.c (unsetenv): Likewise.
27991
27992         2002-03-04  Bruno Haible  <bruno@clisp.org>
27993
27994                 Portability to AIX 4.3.3.
27995                 * unsetenv.c: New file, extracted from setenv.c.
27996                 * setenv.c: Move the unsetenv() function to unsetenv.c.
27997
27998         2001-12-20  Bruno Haible  <bruno@clisp.org>
27999
28000                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
28001                 use malloc instead. For SunOS 4.
28002
28003         2001-12-11  Bruno Haible  <bruno@clisp.org>
28004
28005                 * setenv.c: Declare alloca.
28006                 (compar_fn_t): New typedef.
28007                 (KNOWN_VALUE, STORE_VALUE): Use it.
28008
28009         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
28010         setenv.h.
28011
28012 2002-12-10  Paul Eggert  <eggert@twinsun.com>
28013
28014         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
28015         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
28016         Choose values that are less likely to collide with system fnmatch
28017         options.
28018         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
28019         defined (e.g., a pure POSIX system).
28020         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
28021         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
28022
28023 2002-12-06  Paul Eggert  <eggert@twinsun.com>
28024
28025         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
28026         a pain in practice to deal with generated m4 files.  This change
28027         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
28028
28029         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
28030         and jm-glibc-io.m4, as they are no longer a special case.
28031         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
28032         kludge and the auto-generation stuff.  Check only whether the
28033         functions are declared, not whether they exist, since older hosts
28034         that don't declare the functions can't use the optimization anyway.
28035
28036 2002-12-06  Jim Meyering  <jim@meyering.net>
28037
28038         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
28039
28040         Merge in changes from libc's misc/error.c, in preparation
28041         for the merge of gnulib's changes back into libc.
28042
28043         * lib/error.c (_): Define only if not already defined.
28044         Move definition to follow all #include directives.
28045         Include unlocked-io.h only if !_LIBC.
28046         [_LIBC]: Include <libio/libioP.h>.
28047         [USE_IN_LIBIO]: Include <libio/iolibio.h>
28048         (fflush): Tweak definition to use INTUSE.
28049         (putc): Define.
28050
28051 2002-12-05  Paul Eggert  <eggert@twinsun.com>
28052
28053         * lib/alloca.c [defined emacs]: Include "lisp.h".
28054         (xalloc_die) [defined emacs]: New macro.
28055         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
28056         [! defined emacs]: Include <xalloc.h>.
28057         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
28058         (pointer): Typedef to POINTER_TYPE *.
28059         (malloc): Remove decl; we now always use xmalloc.
28060         (alloca): Use old-style definition, since Emacs needs this.
28061         Check for arithmetic overflow when computing combined size.
28062
28063 2002-12-04  Paul Eggert  <eggert@twinsun.com>
28064
28065         Do not generate unlocked-io.h automatically, since it's easier to
28066         maintain it by hand.
28067
28068         * lib/unlocked-io.h: New file, from GNU diffutils,
28069         but with proper copyright notice and attribution.
28070         * lib/gen-uio: Remove.
28071         * lib/Makefile.am: Add copyright notice.
28072         (libfetish_a_SOURCES): Add unlocked-io.h.
28073         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
28074         (DISTCLEANFILES, io_functions): Remove macros.
28075         (EXTRA_DIST): Remove gen_uio.
28076         (unlocked-io.h): Remove rule.
28077
28078 2002-12-04  Jim Meyering  <jim@meyering.net>
28079
28080         Reflect the fact that stat.c and lstat.c are no longer generated.
28081         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
28082         (DISTCLEANFILES): Likewise.
28083         (EXTRA_DIST): Likewise.
28084         (all_local): Don't depend on stat.c or lstat.c.
28085         (stat.c, lstat.c): Remove rules.
28086         (EXTRA_DIST): Remove xstat.in.
28087
28088         * lib/xstat.in: Remove file.  Contents moved into stat.c.
28089         * lib/stat.c: New file.  Contents mostly from xstat.in.
28090         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
28091         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
28092
28093         * lib/safe-read.c: Rework so that it may serve to define safe_write,
28094         too.
28095         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
28096
28097 2002-12-03  Jim Meyering  <jim@meyering.net>
28098
28099         * lib/safe-read.c, safe-write.c: Change variable names and comments,
28100         but not semantics, to minimize the differences between these two files.
28101         (safe_read): Change comment to mention SAFE_READ_ERROR.
28102
28103         * lib/safe-read.c (IS_EINTR): Define.
28104         (safe_read): Use IS_EINTR in place of in-function cpp directives.
28105
28106 2002-12-02  Jim Meyering  <jim@meyering.net>
28107
28108         * lib/safe-read.c (EINTR): Define.
28109         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
28110         (INT_MAX): Provide fallback.
28111         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
28112
28113         * lib/safe-read.h (SAFE_READ_ERROR): Define.
28114
28115 2002-12-02  Bruno Haible  <bruno@clisp.org>
28116
28117         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
28118         Define, taken from safe-read.c.
28119         (INT_MAX): Provide fallback.
28120         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
28121         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
28122
28123         * lib/safe-read.c (EINTR): Remove definition.
28124         (safe_read): Don't use EINTR if it is absent.
28125
28126 2002-12-01  Jim Meyering  <jim@meyering.net>
28127
28128         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
28129         zero.
28130         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
28131
28132 2002-11-27  Paul Eggert  <eggert@twinsun.com>
28133
28134         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
28135         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
28136         with `if (! (value < limit)) abort ();', for readability.
28137
28138 2002-11-26  Karl Berry  <karl@gnu.org>
28139
28140         * lib/strdup.c: copy from libc again, with jim's ok.
28141         * lib/.cppi-disable: re-add strdup.c
28142
28143 2002-11-25  Karl Berry  <karl@gnu.org>
28144
28145         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
28146         instead of "strtol.c".
28147
28148 2002-11-25  Karl Berry  <karl@gnu.org>
28149
28150         * config/install-sh: update from automake for variable quoting, $0 in
28151         error msgs, etc.
28152
28153         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
28154         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
28155         entry.
28156
28157 2002-11-25  Jim Meyering  <jim@meyering.net>
28158
28159         * lib/mktime.c: Sync from libc, now that it has the latest fix.
28160
28161 2002-11-24  Karl Berry  <karl@gnu.org>
28162
28163         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
28164         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
28165
28166 2002-11-24  Jim Meyering  <jim@meyering.net>
28167
28168         Update from coreutils:
28169
28170         * lib/mktime.c: Merge in changes from libc.
28171
28172         Avoid a link-time failure on some Linux systems.
28173         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
28174         (otherwise).
28175         (__mon_yday): Declare with the STATIC attribute.
28176         (__mktime_internal): Likewise.
28177         Based on a report from Greg Schafer.
28178
28179 2002-11-23  Jim Meyering  <jim@meyering.net>
28180
28181         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
28182         Use `unsigned', not `int', as type of index.
28183
28184         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
28185
28186         * lib/fsusage.c: Remove unneeded parentheses around operands of
28187         `defined'.
28188
28189 2002-11-22  Paul Eggert  <eggert@twinsun.com>
28190
28191         * lib/quotearg.h: Allow multiple inclusion by surrounding with
28192         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
28193         so that we can be included first.
28194         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
28195         * lib/quotearg.c: Include quotearg.h immediately after config.h.
28196         No need to include stddef.h or sys/types.h any more.
28197         Surround local include files with "", not "<>".
28198         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
28199         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
28200         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
28201         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
28202         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
28203         (ISPRINT): Remove; no longer needed now that we assume C89.
28204
28205         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
28206         Preserve errno.
28207
28208         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
28209         quotearg_char): Use SIZE_MAX rather than
28210         (size_t) -1 when we are talking about "infinity".
28211
28212         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
28213
28214 2002-11-22  Paul Eggert  <eggert@twinsun.com>
28215
28216         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
28217         hint that one should use `if (! x) abort ();' rather than `assert
28218         (x);', and anyway it's one less thing to worry about configuring.
28219         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
28220         hash_rehash, hash_insert): Use abort rather than assert.
28221
28222 2002-11-22  Bruno Haible  <bruno@clisp.org>
28223
28224         * lib/safe-read.h: Assume C89. Add comments.
28225         (safe_read): Change return type to size_t.
28226         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
28227         byte counts > SSIZE_MAX correctly.
28228         * lib/safe-write.h: New file.
28229         * lib/safe-write.c: New file.
28230         * lib/full-read.h: New file.
28231         * lib/full-read.c: New file.
28232         * lib/full-write.h: Assume C89. Add comments.
28233         * lib/full-write.c: Include safe-write.h.
28234         (full_write): Rewritten to use safe_write.
28235         Suggested by Jim Meyering and Paul Eggert.
28236
28237 2002-11-21  Jim Meyering  <jim@meyering.net>
28238
28239         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
28240
28241         Merge in changes from the coreutils.
28242
28243         2002-09-25  Paul Eggert  <eggert@twinsun.com>
28244         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
28245         <stdint.h>.
28246         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
28247         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
28248         int.  Work more efficiently if X is the same width as uintmax_t.
28249         Do not compare X to -1, to avoid bogus compiler warning.
28250         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
28251         Don't assume that f_frsize and f_bsize are the same type.
28252
28253         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
28254         warning on FreeBSD.
28255
28256         * lib/makepath.c (make_path): Restore umask *before* creating the final
28257         component.
28258         (make_path): Minor reformatting.
28259
28260         * lib/xmalloc.c: Adjust to work with new autoconf macros,
28261         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
28262         HAVE_MALLOC/HAVE_REALLOC.
28263
28264         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
28265         dummy ones.  At least on GNU/Linux systems, `auto' means something
28266         else.
28267         From Michael Stone.
28268
28269 2002-11-21  Bruno Haible  <bruno@clisp.org>
28270
28271         Remove case insensitive option matching.
28272         * lib/argmatch.h (argcasematch): Remove declaration.
28273         (ARGCASEMATCH): Remove macro.
28274         (__xargmatch_internal): Remove case_sensitive argument.
28275         (XARGMATCH): Update.
28276         (XARGCASEMATCH): Remove macro.
28277         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
28278         case_sensitive argument.
28279         (argcasematch): Remove function.
28280         (__xargmatch_internal): Remove case_sensitive argument.
28281         (main): Use XARGMATCH instead of XARGCASEMATCH.
28282
28283         * lib/xmalloc.c: Change compile-time error message. Add comment about
28284         required autoconf version.
28285
28286 2002-11-20  Paul Eggert  <eggert@twinsun.com>
28287
28288         Merge argmatch cleanups from Bison.  Assume C89.
28289
28290         * lib/argmatch.c: Include config.h here, not in argmatch.h.
28291         Include stdlib.h, for EXIT_FAILURE.
28292         Always include <string.h>, since we assume C89.
28293         (EXIT_FAILURE): Remove pre-C89 bug workaround.
28294         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
28295         Include <stddef.h> instead, since it's all we need for size_t.
28296         (PARAMS): Remove.  All uses removed.
28297         (ARRAY_CARDINALITY): Do not bother to #undef.
28298         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
28299         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
28300         Remove unnecessary parentheses.
28301         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
28302         Insert necessary parentheses.
28303         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
28304         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
28305
28306 2002-11-19  Bruno Haible  <bruno@clisp.org>
28307
28308         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
28309         * lib/mbswidth.h: Include <stddef.h>, for size_t.
28310
28311         * lib/mbswidth.h (PARAMS): Remove macro.
28312         (mbswidth, mbsnwidth): Use ANSI C function declarations.
28313         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
28314
28315         * lib/gcd.h (PARAMS): Remove macro.
28316         (gcd): Use ANSI C function declarations.
28317         * lib/gcd.c (gcd): Likewise.
28318
28319 2002-11-15  Bruno Haible  <bruno@clisp.org>
28320
28321         * lib/strcspn.c: Include <stddef.h>.
28322         (strcspn): Use ANSI C function declaration. Change return type to
28323         size_t. Use NULL.
28324         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
28325         (strpbrk): Use NULL.
28326         * lib/strpbrk.h (PARAMS): Remove macro.
28327         (strpbrk): Use ANSI C function declaration.
28328         * lib/strstr.c: Don't include <sys/types.h>.
28329         * lib/strstr.h (PARAMS): Remove macro.
28330         (strstr): Use ANSI C function declarations.
28331
28332 2002-11-14  Karl Berry  <karl@gnu.org>
28333
28334         * config/mkinstalldirs: `do' on separate line, instead of
28335         `for var; do'.
28336
28337 2002-11-06  Bruno Haible  <bruno@clisp.org>
28338
28339         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
28340         * lib/gcd.c (gcd): Likewise.
28341
28342 2002-11-05  Bruno Haible  <bruno@clisp.org>
28343
28344         * lib/gcd.h: New file, from gettext-0.11.5.
28345         * lib/gcd.c: New file, from gettext-0.11.5.
28346
28347 2002-11-05  Bruno Haible  <bruno@clisp.org>
28348
28349         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28350         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28351         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28352         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28353
28354         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
28355         <libintl.h>.
28356         * lib/makepath.c: Include gettext.h instead of <locale.h> and
28357         <libintl.h>.
28358
28359         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
28360         * lib/human.c: Include gettext.h instead of <libintl.h>.
28361         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
28362         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
28363         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
28364         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
28365         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
28366         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
28367         (textdomain): Remove definition.
28368         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
28369
28370         * lib/long-options.c: Remove include of <libintl.h> and definition of
28371         _.
28372         * lib/same.c: Remove include of <libintl.h> and definition of _.
28373
28374 2002-11-04  Owen Taylor  <otaylor@redhat.com>
28375
28376         * lib/config.charset: A few additions for Solaris.
28377
28378 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
28379
28380         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
28381         * lib/localcharset.c (locale_charset): Declare as extern "C".
28382
28383 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
28384
28385         * lib/config.charset: msdos in uk_UA uses CP1125.
28386
28387 2002-11-04  Bruno Haible  <bruno@clisp.org>
28388
28389         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
28390         * lib/strcase.h: New file, from GNU gettext-0.11.5.
28391         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
28392         * lib/strstr.h: New file, from GNU gettext-0.11.5.
28393         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
28394
28395 2002-11-04  Bruno Haible  <bruno@clisp.org>
28396
28397         * lib/localcharset.c (locale_charset): Don't return an empty string.
28398
28399 2002-11-04  Bruno Haible  <bruno@clisp.org>
28400
28401         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
28402         aliases.
28403
28404 2002-11-04  Bruno Haible  <bruno@clisp.org>
28405
28406         * lib/config.charset: Update for newest glibc. Add canonical names
28407         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
28408
28409 2002-11-04  Bruno Haible  <bruno@clisp.org>
28410
28411         * lib/config.charset: Add support for NetBSD.
28412
28413 2002-11-04  Bruno Haible  <bruno@clisp.org>
28414
28415         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
28416
28417 2002-11-01  Bruno Haible  <bruno@clisp.org>
28418
28419         * configure.in: Add AC_CONFIG_AUX_DIR call.
28420         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
28421         test/Makefile.
28422         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
28423
28424 2002-09-28  Karl Berry  <karl@gnu.org>
28425
28426         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
28427         installed automake until the next release, since changes have been
28428         made.
28429
28430 2002-09-25  Karl Berry  <karl@gnu.org>
28431
28432         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
28433         * lib/getopt*: copy from libc/posix.
28434         * lib/gettext.h: copy from gettext.
28435         * lib/.cppi-disable: add strdup.c, gettext.h.
28436
28437 2002-09-25  Karl Berry  <karl@gnu.org>
28438
28439         * config/srclist.txt: enable gettext.h check.
28440         * config/config.{guess,sub}: update from prep.
28441         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
28442                 from automake 1.6.3.
28443         See srclist*.
28444
28445 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
28446
28447         * regex.c (PATFETCH): Remove the translating fetch.
28448         (PATFETCH_RAW): Rename to PATFETCH.
28449         (set_image_of_range): New fun.
28450         (SET_RANGE_TABLE_WORK_AREA): Use it.
28451         (regex_compile): Don't translate the pattern chars so eagerly.
28452         Only do it when inserting an `exactn' bytecode or when handling
28453         a char-range.
28454         (mutually_exclusive_p): Avoid empty statement.
28455
28456 2002-07-06  Jim Meyering  <meyering@lucent.com>
28457
28458         * m4/README: Don't mention Makefile.am.in.
28459         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
28460
28461 2002-07-01  Jim Meyering  <meyering@lucent.com>
28462
28463         * lib/c-stack.c: Include sys/time.h.
28464         From Volker Borchert.
28465
28466 2002-06-26  Paul Eggert  <eggert@twinsun.com>
28467
28468         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
28469
28470 2002-06-26  Paul Eggert  <eggert@twinsun.com>
28471
28472         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
28473         New macro.  Use it uniformly instead of
28474         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
28475         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
28476         reported by Vin Shelton.
28477
28478 2002-06-22  Paul Eggert  <eggert@twinsun.com>
28479
28480         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
28481         Do not assume SA_SIGINFO behavior.
28482         Bug reported by Jim Meyering on NetBSD 1.5.2.
28483
28484 2002-06-22  Jim Meyering  <meyering@lucent.com>
28485
28486         * m4/c-stack.m4: New file, from diffutils-2.8.2.
28487         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
28488
28489         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
28490         now that configure.ac uses AC_GNU_SOURCE.
28491         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
28492         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
28493
28494         Update to latest tools.  Suggestions from Paul Eggert.
28495         * m4/stdbool.m4: New file, from diffutils-2.8.2.
28496         * m4/gnu-source.m4: Update from diffutils-2.8.2.
28497         * m4/fnmatch.m4: Likewise.
28498         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
28499         to AC_HEADER_STDBOOL
28500
28501 2002-06-22  Jim Meyering  <meyering@lucent.com>
28502
28503         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
28504         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
28505
28506 2002-06-22  Jim Meyering  <meyering@lucent.com>
28507
28508         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
28509
28510         * lib/exitfail.c, exitfail.h: Likewise.
28511         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
28512
28513         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
28514         of fnmatch.h.
28515         (EXTRA_DIST): Add fnmatch_loop.c.
28516         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
28517
28518         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
28519         * lib/fnmatch.c: Update from diffutils-2.8.2.
28520         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
28521         * lib/fnmatch.h: Remove file.
28522
28523 2002-06-21  Jim Meyering  <meyering@lucent.com>
28524
28525         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
28526         * m4/mbrtowc.m4: Likewise.
28527
28528         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
28529         * m4/mbswidth.m4: Reflect name change:
28530         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
28531         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
28532
28533         * m4/lib-link.m4: Update from gettext-0.11.2.
28534         * m4/gettext.m4: Likewise.
28535
28536         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
28537         From Alfred M. Szmidt.
28538
28539 2002-06-18  Paul Eggert  <eggert@twinsun.com>
28540
28541         * lib/file-type.h: Report an error if neither S_ISREG nor
28542         S_IFREG is defined, instead of using a test specific to glibc
28543         2.2.  This should be safe, since POSIX requires S_ISREG and
28544         Unix Version 7 had S_IFREG.  We don't need to check for
28545         <sys/types.h> since we don't use any symbols that it defines.
28546
28547 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
28548
28549         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
28550         $@-t, so that each temporary file name is unique and valid in the first
28551         8 characters, for operation under DOS.
28552
28553 2002-06-15  Paul Eggert  <eggert@twinsun.com>
28554
28555         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
28556
28557 2002-06-15  Jim Meyering  <meyering@lucent.com>
28558
28559         Work even with DJGPP 2.03, which lacks support for symlinks.
28560         From Richard Dawe.
28561         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
28562         is defined.
28563         * lib/lchown.c (S_ISLNK): Likewise.
28564
28565 2002-06-15  Jim Meyering  <meyering@lucent.com>
28566
28567         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
28568         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
28569         have been included before this file.
28570
28571 2002-06-14  Jim Meyering  <meyering@lucent.com>
28572
28573         * lib/file-type.h: Use the version from diffutils-2.8.2.
28574         * lib/file-type.c: Likewise.
28575
28576 2002-06-07  Jim Meyering  <meyering@lucent.com>
28577
28578         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
28579         They're needed at least for NetBSD 1.5.2.
28580         ($statxfs_includes): Include those same headers.
28581         ($statxfs_includes): Include sys/vfs.h if available.
28582         ($statxfs_includes): Likewise for sys/statvfs.h.
28583         Check for the following members in both structs statfs and statvfs:
28584         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
28585
28586 2002-06-01  Jim Meyering  <meyering@lucent.com>
28587
28588         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
28589         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
28590
28591 2002-05-28  Jim Meyering  <meyering@lucent.com>
28592
28593         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
28594         Reported by Volker Borchert.
28595
28596 2002-05-27  Jim Meyering  <meyering@lucent.com>
28597
28598         Fix a problem seen only on nonconforming systems whereby ls.c's
28599         use of localtime, and then of gettimeofday would cause trouble:
28600         the localtime call used to initialize rpl_gettimeofday's save
28601         mechanism would clobber ls's current local time information so
28602         that in any long listing the first file would always be listed
28603         with date 1970-01-01.  Analysis by Volker Borchert.
28604
28605         * lib/gettimeofday.c (localtime): Undefine.
28606         (rpl_localtime): New function.
28607
28608 2002-05-27  Jim Meyering  <meyering@lucent.com>
28609
28610         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
28611         localtime.
28612
28613         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
28614         use the replacement function; it wouldn't resolve at link time.
28615         Reported by Volker Borchert.
28616
28617 2002-05-22  Jim Meyering  <meyering@lucent.com>
28618
28619         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
28620         file-type.h.
28621         * lib/file-type.h: New file.
28622         * lib/file-type.c (file_type): New file/function.  Extracted from
28623         diffutils.
28624
28625 2002-04-30  Jim Meyering  <meyering@lucent.com>
28626
28627         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
28628
28629 2002-04-29  Paul Eggert  <eggert@twinsun.com>
28630
28631         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
28632
28633 2002-04-29  Paul Eggert  <eggert@twinsun.com>
28634
28635         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
28636         Do not check for alloca.h (no longer used) or stdbool.h (was never
28637         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
28638
28639 2002-04-29  Paul Eggert  <eggert@twinsun.com>
28640
28641         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
28642
28643 2002-04-29  Jim Meyering  <meyering@lucent.com>
28644
28645         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
28646         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
28647         Use AC_FUNC_STRNLEN here instead.
28648
28649         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
28650         With autoconf-2.53a, it's part of AC_PROG_CC.
28651
28652 2002-04-28  Paul Eggert  <eggert@twinsun.com>
28653
28654         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
28655         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
28656
28657 2002-04-28  Paul Eggert  <eggert@twinsun.com>
28658
28659         * lib/sig2str.h, lib/sig2str.c: New files.
28660         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
28661
28662 2002-04-28  Paul Eggert  <eggert@twinsun.com>
28663
28664         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
28665         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
28666         of 127, since 64 is the largest conceivable number for ancient
28667         nonstandard hosts.
28668         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
28669
28670 2002-04-28  Jim Meyering  <meyering@lucent.com>
28671
28672         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
28673
28674 2002-04-24  Jim Meyering  <meyering@lucent.com>
28675
28676         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
28677         (jm_PREREQ): Use it.
28678
28679         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
28680         mach/mach.h fcntl.h.
28681         Check for this function: setlocale.
28682
28683 2002-04-24  Jim Meyering  <meyering@lucent.com>
28684
28685         * lib/gettext.h: New file, from Gettext.
28686         * lib/Makefile.am (INCLUDES): Remove -I../intl.
28687         (libfetish_a_SOURCES): Add gettext.h.
28688
28689 2002-04-16  Jim Meyering  <meyering@lucent.com>
28690
28691         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
28692         ut_pid, ut_id, ut_exit.
28693
28694 2002-04-16  Jim Meyering  <meyering@lucent.com>
28695
28696         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
28697         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
28698         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
28699
28700 2002-04-12  Jim Meyering  <meyering@lucent.com>
28701
28702         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
28703         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
28704         existence of the getmntinfo function.  Needed for Darwin 5.3.
28705
28706         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
28707         This is necessary at least on Darwin 5.3.
28708
28709         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
28710         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
28711         strnlen.o in the library, and that makes some versions of ranlib
28712         object.
28713
28714 2002-04-12  Jim Meyering  <meyering@lucent.com>
28715
28716         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
28717
28718 2002-04-09  Jim Meyering  <meyering@lucent.com>
28719
28720         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
28721         to be more precise.  Rather than saying we're checking whether the
28722         function `works', say what we're testing.
28723         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
28724         Reported by Bruno Haible.
28725
28726 2002-03-10  Jim Meyering  <meyering@lucent.com>
28727
28728         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
28729         Suggestion from Santiago Vila.
28730
28731 2002-03-08  Jim Meyering  <meyering@lucent.com>
28732
28733         * lib/rename.c: Mention that this wrapper is needed also on
28734         mips-dec-ultrix4.4 systems.
28735
28736 2002-03-02  Jim Meyering  <meyering@lucent.com>
28737
28738         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
28739         not HAVE_CLOCK_SETTIME.
28740
28741 2002-02-27  Paul Eggert  <eggert@twinsun.com>
28742
28743         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
28744         Check for clock_settime.
28745
28746 2002-02-27  Paul Eggert  <eggert@twinsun.com>
28747
28748         * lib/nanosleep.h: Rename to....
28749         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
28750
28751         * lib/gettime.c: New file.
28752         * lib/settime.c: New file.
28753         * lib/stime.c: Remove.
28754
28755         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
28756         timespec.h.  Remove nanosleep.h.
28757
28758 2002-02-25  Paul Eggert  <eggert@twinsun.com>
28759
28760         * m4/acl.m4: New file.
28761         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
28762         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
28763
28764 2002-02-25  Paul Eggert  <eggert@twinsun.com>
28765
28766         * lib/acl.c, lib/acl.h: New files.
28767         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
28768
28769 2002-02-24  Jim Meyering  <meyering@lucent.com>
28770
28771         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
28772         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
28773         cause trouble.  Reported by Nelson Beebe.
28774
28775 2002-02-23  Paul Eggert  <eggert@twinsun.com>
28776
28777         * lib/path-concat.c (xpath_concat): Reorder code to pacify
28778         compilers that don't know that xalloc_die never returns.
28779
28780 2002-02-20  Jim Meyering  <meyering@lucent.com>
28781
28782         * lib/getdate.c: Regenerate using bison-1.33.
28783
28784 2002-02-17  Jim Meyering  <meyering@lucent.com>
28785
28786         * config/config.guess (main): Don't use `head -1'; it's no longer
28787         portable. Use `sed 1q' instead.
28788
28789 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
28790
28791         * m4/codeset.m4: Upgrade to gettext-0.11.
28792         * m4/gettext.m4: Upgrade to gettext-0.11.
28793         * m4/glibc21.m4: Upgrade to gettext-0.11.
28794         * m4/iconv.m4: Upgrade to gettext-0.11.
28795         * m4/isc-posix.m4: Upgrade to gettext-0.11.
28796         * m4/lcmessage.m4: Upgrade to gettext-0.11.
28797         * m4/lib-ld.m4: New file, from gettext-0.11.
28798         * m4/lib-link.m4: New file, from gettext-0.11.
28799         * m4/lib-prefix.m4: New file, from gettext-0.11.
28800         * m4/progtest.m4: Upgrade to gettext-0.11.
28801
28802 2002-02-15  Paul Eggert  <eggert@twinsun.com>
28803
28804         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
28805         (jm_PREREQ): Use it.
28806
28807 2002-02-15  Paul Eggert  <eggert@twinsun.com>
28808
28809         * lib/posixver.c, lib/posixver.h: New files.
28810         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
28811
28812 2002-02-02  Paul Eggert  <eggert@twinsun.com>
28813             Bruno Haible  <bruno@clisp.org>
28814
28815         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
28816         (fwrite_success_callback): New declaration.
28817         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
28818         print_unicode_char. Call failure callback instead of error.
28819         (fwrite_success_callback): New function.
28820         (exit_failure_callback): New function.
28821         (fallback_failure_callback): New function.
28822         (print_unicode_char): Call unicode_to_mb.
28823
28824 2002-01-26  Jim Meyering  <meyering@lucent.com>
28825
28826         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
28827         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
28828
28829 2002-01-26  Jim Meyering  <meyering@lucent.com>
28830
28831         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
28832
28833 2002-01-22  Paul Eggert  <eggert@twinsun.com>
28834
28835         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
28836
28837 2002-01-22  Jim Meyering  <meyering@lucent.com>
28838
28839         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
28840         Otherwise, some versions of automake would omit the rule that makes
28841         Makefile from Makefile.in.
28842
28843 2002-01-21  Paul Eggert  <eggert@twinsun.com>
28844
28845         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
28846         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
28847         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
28848         (memcoll): Set errno to zero if there is no error.
28849
28850         * lib/quotearg.c (quotearg_buffer_restyled):
28851         Fix bug with quoting buffers containing NUL when backslashing escapes.
28852         This bug was exposed by the other changes in this patch.
28853         (quotearg_n_options): New arg ARGSIZE.
28854         All callers changed.
28855         (quoting_options_from_style): New function.
28856         (quotearg_n_style): Use it.
28857         (quotearg_n_style_mem): New function.
28858
28859         * lib/quotearg.h (quotearg_n_style_mem): New function.
28860
28861 2002-01-19  Jim Meyering  <meyering@lucent.com>
28862
28863         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
28864         Remove useless quotes: DF_PROG="df".
28865         * m4/strnlen.m4: New file.
28866
28867 2002-01-16  Paul Eggert  <eggert@twinsun.com>
28868
28869         * lib/backupfile.c (ISDIGIT): Comment fix.
28870         * lib/getdate.y (ISDIGIT): Likewise.
28871         * lib/posixtm.c (ISDIGIT, year): Likewise.
28872         * lib/strverscmp.c (ISDIGIT): Likewise.
28873         * lib/userspec.c (ISDIGIT): Likewise.
28874
28875 2002-01-16  Jim Meyering  <meyering@lucent.com>
28876
28877         * lib/getdate.y: Add three semicolons, each just before a closing
28878         brace. Bison (as of version 1.31) no longer papers over that mistake.
28879
28880 2002-01-05  Jim Meyering  <meyering@lucent.com>
28881
28882         * lib/version-etc.c (version_etc_copyright): Update copyright year.
28883
28884 2001-12-19  Paul Eggert  <eggert@twinsun.com>
28885
28886         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
28887         not silently exit merely because the output buffer happens to
28888         have nothing pending.
28889
28890 2001-12-18  Paul Eggert  <eggert@twinsun.com>
28891
28892         See the big note in ../ChangeLog.
28893         * lib/human.c (suffixes): Prefer K to k for 1024.
28894         (generate_suffix_backwards): New function.
28895         (human_readable_inexact): Use it.
28896         * lib/xstrtol.c (__xstrtol): If there is no number but there
28897         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
28898         Accept 'K' as well as 'k'.
28899
28900 2001-12-15  Jim Meyering  <meyering@lucent.com>
28901
28902         * lib/regex.h (__restrict_arr): Update from libc.
28903
28904         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
28905         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
28906         (STREQ): Define.
28907
28908 2001-12-14  Jim Meyering  <meyering@lucent.com>
28909
28910         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
28911         Suggestion from Bruno Haible.
28912
28913 2001-12-10  Jim Meyering  <meyering@lucent.com>
28914
28915         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
28916         xrealloc, Instead, include "xalloc.h".
28917         (initbuffer): Don't cast xmalloc return value to char*.
28918         (readline): Reword comment.
28919         Don't cast xrealloc return value to char*
28920         Return NULL, not 0.
28921
28922 2001-12-09  Jim Meyering  <meyering@lucent.com>
28923
28924         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
28925         about `signed and unsigned type in conditional expression'.
28926         * lib/posixtm.c (posix_time_parse): Likewise.
28927
28928         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
28929
28930         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
28931         to avoid a pedantic warning.
28932
28933         * lib/getstr.c: Don't include assert.h.
28934         (getstr): Remove warning-evoking assertions.
28935         Return -1 if offset parameter is out of bounds.
28936         Change the type of a local from int to size_t.
28937
28938         * lib/strftime.c (my_strftime_localtime_r): Include this function
28939         definition in the `#if ! HAVE_TM_GMTOFF' block.
28940
28941         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
28942         Include xalloc.h instead.
28943
28944 2001-12-02  Jim Meyering  <meyering@lucent.com>
28945
28946         * lib/tempname.c: Don't declare getenv, thus reverting the change of
28947         2001-11-18.  It's no longer necessary, now that stdlib.h is always
28948         included.
28949
28950         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
28951         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
28952
28953 2001-11-30  Akim Demaille  <akim@epita.fr>
28954
28955         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
28956         before being defined.
28957
28958 2001-11-27  Paul Eggert  <eggert@twinsun.com>
28959
28960         * lib/quotearg.h (quotearg_n, quotearg_n_style):
28961         First arg is int, not unsigned.
28962         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
28963         (SIZE_MAX, UINT_MAX): New macros.
28964         (quotearg_n_options): Abort if N is negative.
28965         Avoid overflow check on hosts where size_t is 64 bits and int
28966         is 32 bits, as overflow is impossible there.
28967         Fix off-by-one typo that caused unnecessary reallocation.
28968
28969 2001-11-27  Jim Meyering  <meyering@lucent.com>
28970
28971         * lib/tempname.c: Merge with version from libc.
28972         * lib/regex.c: Likewise.
28973
28974         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
28975         systems for which STDC_HEADERS is 0, it was not included, resulting in
28976         a warning about an integer-to-pointer conversion problem with getenv.
28977         Reported by Volker Borchert.
28978
28979 2001-11-26  Jim Meyering  <meyering@lucent.com>
28980
28981         * lib/gtod.h: Remove file.
28982         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
28983         * lib/gettimeofday.c: Don't include gtod.h.
28984         (GTOD_init): Remove function.
28985         (rpl_gettimeofday): Do its job here instead, rather than aborting.
28986         Suggestion from Volker Borchert.
28987
28988 2001-11-23  Jim Meyering  <meyering@lucent.com>
28989
28990         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
28991         it.
28992         * lib/hash.c (struct hash_table): Define it here instead.
28993
28994 2001-11-22  Jim Meyering  <meyering@lucent.com>
28995
28996         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
28997
28998 2001-11-20  Jim Meyering  <meyering@lucent.com>
28999
29000         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
29001         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
29002
29003 2001-11-19  Jim Meyering  <meyering@lucent.com>
29004
29005         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
29006         directory.  Use "conftestXXXXXX" as the template.
29007         Suggestion from Paul Eggert.
29008
29009         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
29010         immediately, so the test doesn't mistakenly hit the max-open-files
29011         limit.
29012
29013 2001-11-18  Paul Eggert  <eggert@twinsun.com>
29014
29015         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
29016         (TEMPORARIES): New macro.
29017         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
29018         removes an artificial limitation (e.g. HP-UX 10.20, where
29019         TMP_MAX is 17576).
29020
29021 2001-11-18  Jim Meyering  <meyering@lucent.com>
29022
29023         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
29024
29025 2001-11-18  Jim Meyering  <meyering@lucent.com>
29026
29027         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
29028         on SunOS 4.
29029
29030         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
29031         files will be created before anything else.
29032
29033 2001-11-17  Paul Eggert  <eggert@twinsun.com>
29034
29035         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
29036         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
29037
29038 2001-11-17  Jim Meyering  <meyering@lucent.com>
29039
29040         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
29041         Prompted by a report from Bob Proulx.
29042
29043         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
29044         Instead, require UTILS_FUNC_MKSTEMP.
29045
29046 2001-11-17  Jim Meyering  <meyering@lucent.com>
29047
29048         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
29049         Now, that's done as part of AC_FUNC_STRTOD.
29050
29051 2001-11-17  Jim Meyering  <meyering@lucent.com>
29052
29053         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
29054         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
29055         rather than group writable.  Patch by Juan F. Codagnone.
29056
29057         * lib/readtokens.c: Remove explicit declarations of xmalloc and
29058         xrealloc, Instead, include "xalloc.h".
29059
29060         * lib/mountlist.c: Include unlocked-io.h after all system headers.
29061         Remove explicit declarations of xmalloc, xrealloc,
29062         and xstrdup.  Instead, include "xalloc.h".
29063
29064         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
29065         unlocked-io.h.
29066         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
29067         Likewise.
29068         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
29069
29070         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
29071         Reported by Padraig Brady.
29072
29073         * lib/mkstemp.c: #undef mkstemp.
29074         Include config.h.
29075         (rpl_mkstemp): Rename from mkstemp.
29076         Protoize.
29077
29078 2001-11-16  Jim Meyering  <meyering@lucent.com>
29079
29080         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
29081         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
29082         determine the amount of total physical memory, use pstat_getstatic.
29083         HPUX-11 doesn't define _SC_PHYS_PAGES.
29084         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
29085         If sysconf couldn't be used to determine the amount of available
29086         physical memory, use both pstat_getstatic and pstat_getdynamic.
29087         Based on a patch from Bob Proulx.
29088
29089 2001-11-10  Jim Meyering  <meyering@lucent.com>
29090
29091         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
29092         (jm_PREREQ): Use it.
29093
29094 2001-11-09  Jim Meyering  <meyering@lucent.com>
29095
29096         * m4/jm-macros.m4: Require autoconf-2.52f.
29097         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
29098         Use these AC_-prefixed names, not the AM_-prefixed ones.
29099
29100         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
29101
29102 2001-11-05  Jim Meyering  <meyering@lucent.com>
29103
29104         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
29105
29106 2001-11-04  Jim Meyering  <meyering@lucent.com>
29107
29108         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
29109         $DEFS.
29110
29111 2001-11-03  Jim Meyering  <meyering@lucent.com>
29112
29113         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
29114         of AC_DEFUN.
29115
29116         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
29117         know the name of the variable in the macro definition.
29118
29119 2001-11-03  Jim Meyering  <meyering@lucent.com>
29120
29121         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
29122         in argmatch_to_argument call.
29123
29124         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
29125         argument.
29126
29127         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
29128         e.g., a fault due to an attempt to free a NULL pointer.
29129
29130 2001-11-01  Jim Meyering  <meyering@lucent.com>
29131
29132         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
29133         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
29134
29135 2001-11-01  Jim Meyering  <meyering@lucent.com>
29136
29137         * lib/dirfd.c, lib/dirfd.h: New files.
29138         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
29139
29140         * lib/hash.c (hash_print) [TESTING]: Clean up.
29141
29142 2001-10-22  Paul Eggert  <eggert@twinsun.com>
29143
29144         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
29145         to avoid a warning if -Wall.
29146
29147 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
29148
29149         * README: New file
29150         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
29151         (per RMS's instructions, this is now the canonical source)
29152         * lgpl/, gpl/: New directories.
29153
29154 2001-10-21  Paul Eggert  <eggert@twinsun.com>
29155
29156         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
29157
29158 2001-10-21  Jim Meyering  <meyering@lucent.com>
29159
29160         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
29161         this code would end up calling gettext even in packages built
29162         with --disable-nls.
29163         * lib/getopt.c (_): Likewise.
29164         * lib/regex.c (_): Likewise.
29165
29166 2001-10-20  Paul Eggert  <eggert@twinsun.com>
29167
29168         * m4/error.m4 (jm_PREREQ_ERROR):
29169         Do not invoke AC_CHECK_FUNCS with strerror_r, as
29170         AC_FUNC_STRERROR_R does that.
29171         Check for strerror declaration.
29172
29173         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
29174         are supposed to have them these days.
29175         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
29176         Merge changes from latest Autoconf CVS.
29177         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
29178         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
29179         POSIX decided to standardize on the int flavor of strerror_r.
29180
29181 2001-10-20  Paul Eggert  <eggert@twinsun.com>
29182
29183         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
29184         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
29185         Use strerror_r that is only a macro, even if it is not a function.
29186         (strerror): Check for HAVE_DECL_STRERROR before declaring.
29187         (private_strerror): Use prototypes, not old-style function definition.
29188         (print_errno_message): New function.
29189         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
29190         char*-flavored one.
29191         (error_tail, error, error_at_line): Use it.
29192
29193 2001-10-11  Jim Meyering  <meyering@lucent.com>
29194
29195         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
29196         and quote_n (1, ... to avoid clobbering a buffer.
29197
29198 2001-10-05  Jim Meyering  <meyering@lucent.com>
29199
29200         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
29201         hash-pjw.h.
29202         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
29203         * lib/hash-pjw.h: New file.
29204
29205 2001-09-30  Jim Meyering  <meyering@lucent.com>
29206
29207         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
29208         `struct fsstat' has the `f_fstypename' member.
29209         Use that to define FS_TYPE, which is now used to make
29210         the getfsstat link test tighter.
29211
29212 2001-09-30  Jim Meyering  <meyering@lucent.com>
29213
29214         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
29215         Include <sys/ucred.h>, for Apple Darwin.
29216         Include sys/mount.h and sys/fs_types.h only if available.
29217         (FS_TYPE): Define.
29218         (read_filesystem_list): Use FS_TYPE.
29219
29220 2001-09-29  Paul Eggert  <eggert@twinsun.com>
29221
29222         * lib/exclude.c (excluded_filename): 0 -> false, since it's
29223         a boolean context.
29224
29225 2001-09-29  Jim Meyering  <meyering@lucent.com>
29226
29227         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
29228         [one-argument getmntent function]): Include stdio.h before mntent.h.
29229         SunOS 4.1.x needs it for the declaration of `FILE'.
29230         Patch by Volker Borchert.
29231
29232         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
29233         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
29234         sys/fs_types.h, and make the link-test for getfsstat guard #include
29235         directives with appropriate #if HAVE_*_H tests so that we can
29236         detect getfsstat on Apple Darwin1.3.7 systems.
29237         Reported by Nelson Beebe.
29238         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
29239
29240 2001-09-28  Paul Eggert  <eggert@twinsun.com>
29241
29242         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
29243         #defines strtoimax.  Also treat the other strto* functions
29244         like strtoimax.
29245
29246         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
29247         Check for strtoul and strtoumax,
29248         as those declarations are made even in the signed case.
29249         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
29250         Likewise, for strtol and strtoimax.
29251
29252 2001-09-28  Paul Eggert  <eggert@twinsun.com>
29253
29254         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
29255         #defines strtoimax.  Also treat the other strto* functions
29256         like strtoimax.
29257
29258         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
29259         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
29260         (strtoimax, strtoumax): Do not declare if already defined as a macro.
29261
29262 2001-09-26  Jim Meyering  <meyering@lucent.com>
29263
29264         Most macros in unlocked-io.h had the wrong number of arguments.
29265         * lib/gen-uio: New script.
29266         (USE_UNLOCKED_IO): Define to 1 if not already defined.
29267         * lib/unlocked-io.hin: Remove file.
29268         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
29269         rather than trying to embed it here.
29270         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
29271         Reported by Padraig Brady.
29272
29273 2001-09-25  Volker Borchert  <bt@teknon.de>
29274
29275         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
29276         `result'.
29277
29278 2001-09-24  Jim Meyering  <meyering@lucent.com>
29279
29280         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
29281
29282 2001-09-23  Jim Meyering  <meyering@lucent.com>
29283
29284         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
29285         instead of the mere test for existence of mntent.h.  The latter
29286         would get a false-positive on AIX 3.4 systems.
29287         In the outer getmntent if-block, don't die if neither of the getmntent
29288         tests succeeds.  Instead, just fall through and continue with the
29289         remaining tests.
29290
29291 2001-09-23  Jim Meyering  <meyering@lucent.com>
29292
29293         * lib/mountlist.c: Remove useless parentheses in #if directives.
29294         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
29295         the deprecated MOUNTED symbol is no longer defined in mntent.h.
29296
29297 2001-09-22  Jim Meyering  <meyering@lucent.com>
29298
29299         * m4/gettext.m4: New file.  From gettext.
29300         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
29301         * m4/progtest.m4: Likewise
29302         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
29303         * m4/glibc21.m4: Likewise.
29304
29305         * m4/libintl.m4: Remove.  No longer used.
29306
29307 2001-09-22  Jim Meyering  <meyering@lucent.com>
29308
29309         * lib/localcharset.c: Update from latest gettext.
29310         * lib/config.charset: Likewise.
29311
29312 2001-09-20  Jim Meyering  <meyering@lucent.com>
29313
29314         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
29315         strtoimax.
29316         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
29317         strtoumax.
29318
29319 2001-09-20  Jim Meyering  <meyering@lucent.com>
29320
29321         * lib/xstrtol.c (strtoimax): Guard declaration with
29322         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
29323         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
29324         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
29325         (strtoumax): Likewise, for completeness (it wasn't necessary).
29326
29327 2001-09-17  Paul Eggert  <eggert@twinsun.com>
29328
29329         * lib/strtoimax.c (HAVE_LONG_LONG):
29330         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
29331         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
29332         to work around bug in IBM C compiler.
29333
29334 2001-09-17  Jim Meyering  <meyering@lucent.com>
29335
29336         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
29337         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
29338         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
29339         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
29340         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
29341         whenever the right hand side need not be expanded by the shell.
29342
29343 2001-09-16  Paul Eggert  <eggert@twinsun.com>
29344
29345         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
29346         library.  It's not correct, as some older glibcs are buggy.
29347         fnmatch wasn't fixed until glibc 2.2.
29348
29349         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
29350         special shell magic here.
29351
29352 2001-09-16  Jim Meyering  <meyering@lucent.com>
29353
29354         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
29355         * m4/jm-macros.m4: Require it.
29356
29357 2001-09-16  Jim Meyering  <meyering@lucent.com>
29358
29359         * lib/mkdir.c: New file.
29360
29361 2001-09-15  Jim Meyering  <meyering@lucent.com>
29362
29363         * m4/jm-macros.m4: Check for help2man.
29364
29365 2001-09-11  Jim Meyering  <meyering@lucent.com>
29366
29367         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
29368         The body, by Paul Eggert, was moved here from configure.in.
29369         * m4/jm-macros.m4: Require UTILS_HOST_OS.
29370
29371 2001-09-04  Paul Eggert  <eggert@twinsun.com>
29372
29373         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
29374         (jm_PREREQ): Use it.
29375
29376 2001-09-04  Paul Eggert  <eggert@twinsun.com>
29377
29378         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
29379         Use ssize_t, not int, to store result of readlink.
29380         Check for ssize_t overflow as well as size_t overflow,
29381         as POSIX says the result of readlink is implementation-defined
29382         when ssize_t overflows.
29383         Remove unnecessary cast to char*.
29384         Use free+malloc instead of realloc, as the storage doesn't need
29385         to be preserved and it's clearer and can be more efficient that way.
29386         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
29387         * lib/xreadlink.h (xreadlink): Update prototype.
29388
29389 2001-09-04  Paul Eggert  <eggert@twinsun.com>
29390
29391         * lib/xgetcwd.c: Revert some of the previous change; intead,
29392         fix the HAVE_GETCWD_NULL code to behave more like the
29393         !HAVE_GETCWD_NULL code used to.
29394
29395         Include "xalloc.h".
29396         (xgetcwd): Do not return NULL when memory is exhausted; instead,
29397         invoke xalloc_die.
29398
29399 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29400
29401         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
29402         sys/param.h, as pathmax.h includes them.
29403
29404 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29405
29406         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
29407         (jm_PREREQ_XGETCWD): New macro.
29408
29409         * m4/getcwd.m4: New file.
29410
29411 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29412
29413         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
29414         like the HAVE_GETCWD_NULL code.
29415         Include pathmax.h if not HAVE_GETCWD.
29416         Do not include xalloc.h.
29417         (INITIAL_BUFFER_SIZE): New symbol.
29418         Do not use xmalloc / xrealloc, since the caller is responsible for
29419         handling errors.  Preserve errno around `free' during failure.
29420         Do not overrun buffer when using getwd.
29421
29422 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29423
29424         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
29425         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
29426         getcwd (NULL, 0).
29427
29428 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29429
29430         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
29431         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
29432         spotted by Jim Meyering.
29433
29434 2001-09-03  Jim Meyering  <meyering@lucent.com>
29435
29436         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
29437         failure.
29438
29439 2001-09-02  Jim Meyering  <meyering@lucent.com>
29440
29441         * lib/error.c: Update from GNU libc.
29442
29443 2001-09-01  Jim Meyering  <meyering@lucent.com>
29444
29445         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
29446         Used by df.
29447
29448 2001-09-01  Jim Meyering  <meyering@lucent.com>
29449
29450         * lib/xreadlink.c: New file.
29451         * lib/xreadlink.h: New file.
29452         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
29453         xreadlink.h.
29454
29455         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
29456         doesn't conflict with sparc Solaris 7's definition in
29457         /usr/include/sys/int_types.h.
29458
29459         * lib/exclude.c: Use `""', not `<>' to #include non-system header
29460         files.
29461         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
29462         and strncasecmp as r-values.  Unixware didn't have declarations.
29463
29464 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29465
29466         * lib/xstrtol.h: Add copyright notice.
29467         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
29468         LONGINT_INVALID_SUFFIX_CHAR.
29469
29470 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29471
29472         * lib/xstrtol.c (strtoimax): New decl.
29473
29474 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29475
29476         * lib/xgetcwd.c: Don't include pathmax.h.
29477         Include stdlib.h and unistd.h if available.
29478         Include xalloc.h.
29479         (xmalloc, xstrdup, free): Remove decls.
29480         (xgetcwd): Don't assume sizes fit in unsigned.
29481         Check for overflow when computing sizes.
29482         Simplify reallocation code.
29483
29484 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29485
29486         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
29487         a directory's st_size can have an arbitrary value, so the old
29488         usage could waste an arbitrary amount of memory.  All uses
29489         changed.
29490         * lib/savedir.h: Update prototype.
29491
29492 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29493
29494         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
29495
29496         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
29497         old strtoimax.c.
29498
29499         Also, make the following further changes to make this file's
29500         configuration more similar to that of strtol.c:
29501         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
29502         (strtoumax, uintmax_t, strtoull, strtol): Remove.
29503         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
29504         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
29505         changed to signed values.
29506
29507         And make the following changes as well:
29508         Fix copyright notice, as 1999 was missing.
29509         (verify): New macro.
29510         (strtoimax): Check sizes at compile-time, not run-time.
29511         Prefer strtol to strtoll if both work.
29512         (main): Remove; it was not that useful and was a pain to maintain.
29513
29514         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
29515
29516 2001-08-31  Jim Meyering  <meyering@lucent.com>
29517
29518         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
29519         Use an initial, malloc'd, buffer of length 128 rather than
29520         a statically allocated one of length 1024.
29521
29522 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29523
29524         Simplify code, partly by assuming autoconf 2.52 semantics.
29525
29526         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
29527
29528         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
29529         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
29530         All uses removed.
29531         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
29532         Move AC_REQUIRE to next-to-top level, to avoid confusion.
29533         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
29534         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
29535         jm_AC_HEADER_INTTYPES_H.
29536         * m4/jm-macros.m4 (jm_MACROS): Likewise.
29537
29538         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
29539
29540         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
29541         Quote first arg of AC_DEFUN.
29542         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
29543         since they are needed to parse the include file even if we need
29544         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
29545         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
29546         but with opposite signedness.
29547
29548 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29549
29550         Merge 'exclude' changes from tar 1.13.22.
29551         This fixes one or two unlikely storage allocation overflow bugs,
29552         but doesn't change user-visible behavior otherwise.
29553
29554 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29555
29556         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
29557         (jm_PREREQ_EXCLUDE): New macro.
29558
29559 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29560
29561         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
29562         tm to be declared.
29563
29564 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29565
29566         * lib/hash.c: Remove '2001' from copyright notice.
29567
29568 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29569
29570         * lib/full-write.h: New file.
29571         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
29572         * lib/full-write.c: Correct credits, as cccp.c no longer
29573         exists and anyway it was so heavily changed from the old cccp
29574         code as to be unrecognizable.  Include full-write.h.
29575         (full_write) Return size_t, with short writes meaning failure.
29576         All callers changed.  This fixes a bug with large buffers
29577         on 64-bit hosts.
29578         * lib/utime.c: Include full-write.h.
29579
29580 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29581
29582         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
29583         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
29584         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
29585         Include if available.
29586         (<xalloc.h>): Include
29587         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
29588         (verify): New macro.  Use it to verify that EXCLUDE macros do not
29589         collide with FNM macros.
29590         (struct patopts): New struct.
29591         (struct exclude): Use it, as exclude patterns now come with options.
29592         (new_exclude): Support above changes.
29593         (new_exclude, add_exclude_file):
29594         Initial size must now be a power of two to simplify overflow checking.
29595         (free_exclude, fnmatch_no_wildcards): New function.
29596         (excluded_filename): No longer requires options arg, as the options
29597         are determined by add_exclude.  Now returns bool, not int.
29598         (excluded_filename, add_exclude):
29599         Add support for the fancy new exclusion options.
29600         (add_exclude, add_exclude_file): Now takes int options arg.
29601         Check for arithmetic overflow when computing sizes.
29602         (add_exclude_file): xrealloc might modify errno, so don't
29603         realloc until after errno might be used.
29604
29605         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
29606         New macros.
29607         (free_exclude): New decl.
29608         (add_exclude, add_exclude_file): Now takes int options arg.
29609         (excluded_filename): No longer requires options arg, as the options
29610         are determined by add_exclude.  Now returns bool, not int.
29611
29612 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29613
29614         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
29615
29616 2001-08-27  Jim Meyering  <meyering@lucent.com>
29617
29618         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
29619
29620         * lib/version-etc.c (N_): Remove definition.
29621         Revert most of last change.
29622         Instead, simply don't mark the `Copyright...' string for translation.
29623         Based on advice from Paul Eggert.
29624
29625         * lib/strtoxmax.c: Tweak comment.
29626
29627 2001-08-26  Jim Meyering  <meyering@lucent.com>
29628
29629         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
29630
29631         * m4/xstrtoimax.m4: New file.
29632         * m4/xstrtoumax.m4: Add comments explaining why we
29633         AC_REPLACE_FUNCS(strtol).
29634
29635 2001-08-26  Jim Meyering  <meyering@lucent.com>
29636
29637         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
29638         of copyright with `%s' so translators don't get an untranslated
29639         message in 2002.
29640         (COPYRIGHT_YEAR): Define.
29641         (version_etc): Use fprintf rather than fputs.
29642         Suggestion from Ulrich Drepper.
29643
29644         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
29645
29646         * lib/strtoll.c: New file, from GNU libc.
29647         * lib/xstrtoimax.c: New file.
29648
29649         * lib/xstrtol.h: Add xstrtoimax.
29650         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
29651         * lib/strtoimax.c: New file.  Likewise, but first define
29652         STRTOUXMAX_SIGNED.
29653
29654         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
29655         ...
29656         * lib/strtoxmax.c: ... then renamed to this.
29657
29658 2001-08-18  Paul Eggert  <eggert@twinsun.com>
29659
29660         * m4/inttypes.m4: Add AC_PREREQ(2.13).
29661         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
29662         (jm_AC_TYPE_INTMAX_T): New macro.
29663         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
29664
29665         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
29666
29667         * m4/longlong.m4: Renamed from ulonglong.m4.
29668         * m4/inttypes.m4: Renamed from inttypes_h.m4.
29669         * m4/uintmax_t.m4: Removed.
29670
29671 2001-08-13  Paul Eggert  <eggert@twinsun.com>
29672
29673         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
29674         Port to Solaris 8, where 'sed' requires a space after the 'r'
29675         command, and where sh dislikes "$/".  Clean up the spacing a bit.
29676         Redirect output to $tmp just once.
29677
29678 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
29679
29680         * lib/addext.c (<errno.h>): Include.
29681         (errno): Declare if not defined.
29682         (addext): Work correctly when pathconf returns -1 and leaves
29683         errno alone because there is no limit.  Also, work even if
29684         pathconf returns a value greater than SIZE_MAX.
29685
29686 2001-08-12  Jim Meyering  <meyering@lucent.com>
29687
29688         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
29689         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
29690         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
29691         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
29692         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
29693         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
29694         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
29695         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
29696         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
29697         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
29698         utime.m4, utimes.m4, xstrtoumax.m4:
29699         Quote the first argument in each use of AC_DEFUN.
29700
29701 2001-08-12  Jim Meyering  <meyering@lucent.com>
29702
29703         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
29704         Simply `return getcwd (NULL, 0);'.
29705         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
29706         Use 1300 as initial value for length, not PATH_MAX.
29707
29708         * lib/pathmax.h: Clean up cpp syntax.
29709
29710 2001-08-12  Jim Meyering  <meyering@lucent.com>
29711
29712         * lib/gettimeofday.c: New file.
29713         * lib/gtod.h: New file.
29714         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
29715
29716 2001-08-05  Jim Meyering  <meyering@lucent.com>
29717
29718         * m4/jm-macros.m4: Require autoconf-2.52.
29719
29720 2001-08-04  Jim Meyering  <meyering@lucent.com>
29721
29722         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
29723         stmt, to get in sync with glibc.
29724
29725 2001-08-03  Paul Eggert  <eggert@twinsun.com>
29726
29727         The following changes are from gettext 0.10.39 as maintained by
29728         Bruno Haible.
29729
29730         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
29731         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
29732         with inverted sense.  All uses changed.
29733
29734         * lib/mbswidth.c: Don't include <limits.h>.
29735         Include <stdlib.h> and <string.h> unconditionally.
29736         (iswcntrl, mbsinit, ISCNTRL): New macros.
29737         (mbsnwidth): Use K&R style function declarations.
29738         Don't bother checking for MB_LEN_MAX == 1, since the compiler
29739         can optimize it when MB_CUR_MAX == 1.
29740         The width of control characters is zero, not 1.
29741
29742 2001-08-03  Paul Eggert  <eggert@twinsun.com>
29743
29744         The following changes are from gettext 0.10.39 as maintained by
29745         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
29746
29747         * m4/codeset.m4: Upgrade to serial AM1.
29748         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
29749         all uses changed.  Quote first arg of AC_DEFUN.
29750         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
29751
29752         * m4/iconv.m4: Upgrade to serial AM2.
29753         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
29754         Add --with-libconv-prefix.
29755         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
29756         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
29757         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
29758         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
29759         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
29760
29761         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
29762         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
29763         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
29764         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
29765         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
29766         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
29767         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
29768         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
29769         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
29770
29771         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
29772         string.h any more.
29773
29774         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
29775         not the default value.
29776
29777         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
29778         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
29779         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
29780         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
29781         Also check for iswcntrl, used for wcwidth fallback.
29782         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
29783         to Autoconf 2.13.
29784
29785 2001-08-03  Jim Meyering  <meyering@lucent.com>
29786
29787         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
29788         as it was in the original.  Reported by Paul Eggert.
29789
29790 2001-07-16  Jim Meyering  <meyering@lucent.com>
29791
29792         * m4/gettimeofday.m4: New file.
29793         Prompted by a report from Bernhard Baehr.
29794
29795 2001-07-15  Jim Meyering  <meyering@lucent.com>
29796
29797         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
29798         stuff. Now it's in ../Makefile.cfg.
29799
29800 2001-07-15  Jim Meyering  <meyering@lucent.com>
29801
29802         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
29803         (BUILT_SOURCES): Add unlocked-io.h.
29804         (io_functions): Define.
29805         (unlocked-io.h): New rule.
29806         (DISTCLEANFILES): Add unlocked-io.h.
29807         (all-local): Depend on unlocked-io.h, to ensure it is created.
29808
29809         * lib/unlocked-io.hin: New file
29810
29811         * lib/regex.c: Update from glibc.
29812
29813 2001-07-05  Jim Meyering  <meyering@lucent.com>
29814
29815         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
29816         recommendation.
29817         (libfetish_a_SOURCES): Put all .h files here instead.
29818         Remove a thus-exposed (better checks in automake) duplicate and
29819         two unnecessary .h files.
29820
29821 2001-07-04  Jim Meyering  <meyering@lucent.com>
29822
29823         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
29824         that generates jm-glibc-io.m4 so that it doesn't trigger any make
29825         distcheck failure.
29826
29827 2001-07-02  Jim Meyering  <meyering@lucent.com>
29828
29829         The following changes were prompted by suggestions from Bruno Haible.
29830
29831         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
29832         is now generated.
29833         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
29834         definition of EXTRA_DIST.
29835         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
29836         ensure that the generated file is created/updated whenever the list
29837         of $(unlocked_functions) is changed.
29838         (jm-glibc-io.m4): New rule.
29839         (unlocked-io.h): New rule -- currently unused.
29840
29841 2001-06-24  Jim Meyering  <meyering@lucent.com>
29842
29843         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
29844         unmatched right bracket, rather than kludging it with an extra,
29845         falsely-matching quote in a comment.  Patch by Akim Demaille.
29846
29847 2001-06-11  Jim Meyering  <meyering@lucent.com>
29848
29849         * lib/regex.c: Update from GNU libc.
29850
29851 2001-05-27  Jim Meyering  <meyering@lucent.com>
29852
29853         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
29854         Check for ut_type in struct utmp.
29855
29856 2001-05-27  Jim Meyering  <meyering@lucent.com>
29857
29858         * lib/readutmp.h (UT_TYPE): Define.
29859
29860 2001-05-24  Jim Meyering  <meyering@lucent.com>
29861
29862         * lib/argmatch.c: Include "quote.h".
29863         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
29864         quote function.  Reported by Göran Uddeborg.
29865
29866 2001-05-22  Jim Meyering  <meyering@lucent.com>
29867
29868         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
29869         now that we use the package-supplied version unconditionally.
29870         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
29871
29872 2001-05-21  Jim Meyering  <meyering@lucent.com>
29873
29874         * m4/regex.m4: Change a couple backticks to single quotes to avoid
29875         shell syntax errors.
29876
29877 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
29878
29879         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
29880
29881 2001-05-20  Paul Eggert  <eggert@twinsun.com>
29882
29883         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
29884         Don't bother to check library strftime, since
29885         we'll be using our own my_strftime function anyway.
29886         Define my_strftime instead of strftime.
29887
29888 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
29889
29890         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
29891         which is not yet declared.
29892
29893 2001-05-15  Jim Meyering  <meyering@lucent.com>
29894
29895         * m4/regex.m4: Use proper quoting so brackets appear in the test
29896         program.
29897         Reported by, and with help from, Bruno Haible.
29898
29899 2001-05-13  Jim Meyering  <meyering@lucent.com>
29900
29901         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
29902         undefined.
29903
29904 2001-05-11  Paul Eggert  <eggert@twinsun.com>
29905
29906         dirname code cleanup.  base_name now behaves more compatibly
29907         with POSIX basename when given file names that have trailing
29908         slashes, and similarly for dir_name.  Add new primitives
29909         base_len and dir_len.  Put the directory-name-related decls
29910         into dirname.h.
29911
29912         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
29913         * lib/backupfile.c (base_name): Likewise.
29914         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
29915         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
29916         * lib/makepath.c (strip_trailing_slashes): Likewise.
29917         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
29918         ISSLASH): Likewise.
29919         * lib/rename.c (strip_trailing_slashes): Likewise.
29920         * lib/same.c (base_name): Likewise.
29921         * lib/stripslash.c (ISSLASH): Likewise.
29922
29923         * lib/addext.c: Include <dirname.h> after size_t is defined.
29924         * lib/backupfile.c: Likewise.
29925
29926         * lib/addext.c (addext): Use base_len to trim redundant
29927         trailing slashes instead of doing it ourselves.
29928         But do not trim the last slash if it is not redundant.
29929
29930         * lib/backupfile.c (find_backup_file_name,
29931         max_backup_version): Use base_len instead of rolling it ourselves.
29932         Handle the case of "" and (on DOS) "C:" correctly.
29933
29934         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
29935         needed. Include <string.h>, <dirname.h>.
29936         (base_name): Allow file names ending in slashes, other than names
29937         that are all slashes.  In this case, return the basename followed
29938         by the slashes.  This is more general, and can be used in places
29939         where the original base_name purposely had an assertion failure.
29940         (base_len): New function.
29941
29942         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
29943         Do not include <assert.h>; no longer needed.
29944         Include xalloc.h.
29945         (memrchr): Remove decl.
29946         (dir_name_r): Remove.
29947         (dir_len): Renamed from dirlen.  All callers changed.
29948         Rewrite in terms of base_name, for simplicity and consistency.
29949         (dir_name): Never return NULL.  All callers changed.
29950         Do not include <stdlib.h> in test program; no longer needed.
29951         return 0; is fine for test program.
29952
29953         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
29954         New macros.
29955         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
29956
29957         * lib/path-concat.c (path_concat): Use base_len to compute
29958         base length, not strlen; this means we cannot rely on memcpy
29959         to null-terminate.
29960
29961         * lib/same.c (STREQ): Remove.
29962         (same_name): Handle the case where the basename ends in trailing '/'.
29963
29964         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
29965         a slash was stripped.  Do not strip the last slash after a
29966         file system prefix.
29967
29968 2001-05-11  Paul Eggert  <eggert@twinsun.com>
29969
29970         * lib/Makefile.am (libfetish_a_SOURCES):
29971         Add strftime.c, since we now compile it on all hosts.
29972
29973         * lib/strftime.c (my_strftime):
29974         Define to nstrftime if emacs, but only if my_strftime is not defined.
29975         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
29976         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
29977         Add one more extra argument: a nanoseconds value.
29978         All uses changed.
29979         (ns): New macro.
29980         (my_strftime function): Add %N format.
29981         (emacs_strftimeu): Renamed from emacs_strftime,
29982         with extra ut argument.
29983
29984 2001-05-09  Paul Eggert  <eggert@twinsun.com>
29985
29986         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
29987
29988 2001-04-21  Jim Meyering  <meyering@lucent.com>
29989
29990         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
29991         doesn't interfere.
29992
29993 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
29994
29995         * m4/ftruncate.m4: Check for chsize.
29996         Link with ftruncate.o unconditionally if ftruncate is missing.
29997         This was required when cross-compiling to i586-mingw32msvc.
29998
29999 2001-04-08  Jim Meyering  <meyering@lucent.com>
30000
30001         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
30002         recomputed; that's necessary when the offset spans a DST transition.
30003         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
30004
30005 2001-04-02  Jim Meyering  <meyering@lucent.com>
30006
30007         * lib/regex.h, regex.c: Update from GNU libc.
30008
30009 2001-03-24  Jim Meyering  <meyering@lucent.com>
30010
30011         * m4/jm-macros.m4: Require autoconf-2.49d.
30012
30013 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
30014
30015         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
30016
30017 2001-03-19  Paul Eggert  <eggert@twinsun.com>
30018
30019         * lib/version-etc.c (version_etc_copyright): Update to 2001.
30020
30021 2001-03-17  Jim Meyering  <meyering@lucent.com>
30022
30023         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
30024         now that the version in autoconf is equivalent.
30025         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
30026
30027         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
30028         Suggestion from Akim Demaille.
30029
30030         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
30031         (jm_PREREQ_TEMPNAME): New function.
30032
30033 2001-03-16  Paul Eggert  <eggert@twinsun.com>
30034
30035         * lib/tempname.c (uint64_t): Define to uintmax_t if
30036         not defined, and if UINT64_MAX is not defined.
30037         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
30038         Reported by John David Anglin.
30039
30040 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
30041
30042         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
30043         resolve alias if codeset is empty.
30044         * lib/config.charset (BeOS): Use wildcard syntax.
30045
30046 2001-03-13  Jim Meyering  <meyering@lucent.com>
30047
30048         * lib/path-concat.c (path_concat)
30049         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
30050         concatenating e.g., `C:' and `foo'.
30051         From Bruno Haible.
30052
30053 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
30054
30055         * lib/localcharset.c (locale_charset): Don't use
30056         setlocale(LC_CTYPE,NULL). Don't return NULL.
30057         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
30058
30059 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
30060
30061         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
30062         support for DOS/DJGPP.
30063
30064 2001-03-01  Paul Eggert  <eggert@twinsun.com>
30065
30066         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
30067         lacks mkstemp.  Compile our own tempname.c if we compile our own
30068         mkstemp.c, as mkstemp relies on tempname.
30069
30070 2001-03-01  Jim Meyering  <meyering@lucent.com>
30071
30072         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
30073         AH_VERBATIM really does output its argument verbatim.
30074
30075 2001-02-28  Paul Eggert  <eggert@twinsun.com>
30076
30077         * lib/Makefile.am (libfetish_a_SOURCES):
30078         Add dup-safer.c, fopen-safer.c.
30079         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
30080
30081         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
30082         * lib/unistd-safer.h: New files.
30083
30084 2001-02-25  Paul Eggert  <eggert@twinsun.com>
30085
30086         The mkstemp replacement is taken from glibc 2.2.2, with some
30087         portability fixes for use outside glibc, as follows:
30088
30089         * lib/tempname.c (struct_stat64): New macro.
30090         (direxists, __gen_tempname): Use it.
30091         This avoids a portability problem with Solaris 8.
30092
30093         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
30094         (<stddef.h>, <stdint.h>, <string.h>):
30095         Include only if STDC_HEADERS || _LIBC.
30096         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
30097         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
30098         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
30099         (__set_errno): Define this macro if <errno.h> doesn't.
30100         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
30101         Define these macros if <stdio.h> doesn't.
30102         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
30103         Define these macros if <sys/stat.h>
30104         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
30105         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
30106         __xstat64): Define if not _LIBC.
30107         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
30108         (__gen_tempname): Invoke gettimeofday only if
30109         HAVE_GETTIMEOFDAY || _LIBC;
30110         otherwise, fall back on plain "time".
30111         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
30112
30113         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
30114
30115         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
30116
30117 2001-02-18  Paul Eggert  <eggert@twinsun.com>
30118
30119         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
30120
30121 2001-02-17  Paul Eggert  <eggert@twinsun.com>
30122
30123         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
30124         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
30125         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
30126         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
30127
30128 2001-02-17  Paul Eggert  <eggert@twinsun.com>
30129
30130         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
30131         Remove workaround macros for hosts that have mbrtowc but not
30132         mbstate_t, as we now insist on proper declarations for both
30133         before using mbrtowc.
30134
30135 2001-02-17  Jim Meyering  <meyering@lucent.com>
30136
30137         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
30138         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
30139         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
30140         UnixWare 7.1.1.
30141
30142         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
30143         rather than AC_CACHE_VAL.
30144
30145 2001-02-17  Jim Meyering  <meyering@lucent.com>
30146
30147         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
30148         around included file name.
30149
30150         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
30151
30152         * lib/strftime.c: Update from GNU libc (the only changes were to
30153         comments).
30154
30155 2001-02-17  Jim Meyering  <meyering@lucent.com>
30156
30157         * lib/regex.c: Update from libc.
30158
30159 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
30160
30161         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
30162         clash.
30163
30164 2001-02-16  Paul Eggert  <eggert@twinsun.com>
30165
30166         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
30167         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
30168         Reported by Mark Hounschell via Paul Eggert.
30169
30170 2001-02-07  Jim Meyering  <meyering@lucent.com>
30171
30172         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
30173
30174 2001-02-05  Jim Meyering  <meyering@lucent.com>
30175
30176         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
30177         it includes the patch required for `large file' support with at least
30178         HP-UX's 10.20 /bin/cc.
30179
30180 2001-02-03  Jim Meyering  <meyering@lucent.com>
30181
30182         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
30183         AS_IF, now that it works once again (mysteriously).
30184         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
30185
30186 2001-01-30  Jim Meyering  <meyering@lucent.com>
30187
30188         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
30189         * m4/chown.m4: Rename conftestchown to conftest.chown.
30190         * m4/rename.m4: s/conftestdir/conftest.d1/ and
30191         s/conftestdir2/conftest.d2/.
30192         * m4/utimes.m4: s/conftestdata/conftest.data/
30193         Inspired by Pavel Roskin's change in autoconf.
30194
30195 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
30196
30197         * lib/config.charset: Update for FreeBSD 4.2.
30198
30199 2001-01-27  Jim Meyering  <meyering@lucent.com>
30200
30201         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
30202         a use of AS_IF.
30203         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
30204
30205 2001-01-26  Jim Meyering  <meyering@lucent.com>
30206
30207         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
30208         quotearg.c includes it.
30209
30210 2001-01-26  Jim Meyering  <meyering@lucent.com>
30211
30212         * lib/quotearg.c: Include stddef.h.
30213         * lib/quote.c: Include stddef.h.
30214         Reported by Axel Kittenberger.
30215
30216         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
30217         line in double quotes so that it evokes a better diagnostic.
30218         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
30219         Reported by Axel Kittenberger.
30220
30221 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
30222
30223         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
30224         as if it was a `charset'.
30225
30226 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
30227
30228         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
30229         has const.
30230
30231 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
30232
30233         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
30234         to avoid a warning.  Add back 'const' to inptr.
30235
30236 2001-01-20  Jim Meyering  <meyering@lucent.com>
30237
30238         Be sure that headers are checked before used in code compiled
30239         for the type checks.
30240         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
30241         In place of that, invoke jm_CHECK_ALL_TYPES.
30242         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
30243         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
30244         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
30245         The check for ssize_t was mistakenly run before the test for unistd.h.
30246
30247         The configure-time check for stdbool.h was missing.
30248         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
30249         (jm_PREREQ_HASH): New function.
30250
30251 2001-01-17  Jim Meyering  <meyering@lucent.com>
30252
30253         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
30254         for autoconf-2.49c.
30255         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
30256
30257 2001-01-16  Jim Meyering  <meyering@lucent.com>
30258
30259         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
30260         From Bruno Haible.
30261
30262 2001-01-14  Jim Meyering  <meyering@lucent.com>
30263
30264         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
30265         foo and bar.  Create conftestdir/ in the script, not in the C code.
30266         Remove directories in the script, not in the C code.
30267         Remove conftestdir{,2} before trying to create the directory.
30268         Make the entire configure script fail if the mkdir fails.
30269
30270 2001-01-14  Jim Meyering  <meyering@lucent.com>
30271
30272         * lib/rename.c: New file.  From Volker Borchert.
30273         Include stdlib.h, string.h or strings.h, and xalloc.h.
30274         Use strip_trailing_slashes rather than open-coding it.
30275
30276 2001-01-03  Paul Eggert  <eggert@twinsun.com>
30277
30278         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
30279
30280 2001-01-03  Jim Meyering  <meyering@lucent.com>
30281
30282         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
30283         of local `inptr' to avoid warning with some system declarations of
30284         iconv.
30285
30286 2001-01-02  Volker Borchert  <bt@teknon.de>
30287
30288         * m4/rename.m4: New file.
30289         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
30290
30291 2001-01-01  Jim Meyering  <meyering@lucent.com>
30292
30293         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
30294         even on systems with utmpx.h.  It's necessary for the declaration of
30295         utmp's ut_user member.  Reported by Andreas Jaeger.
30296
30297         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
30298         available. They are required for the declarations of getgrgid and
30299         getpwuid resp.
30300         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
30301         Reported by Andreas Jaeger.
30302
30303 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
30304
30305         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
30306         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
30307         so `make install' also works in VPATH builds.
30308
30309 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
30310
30311         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
30312         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
30313         can be used in subdirectories.
30314
30315 2000-12-29  Paul Eggert  <eggert@twinsun.com>
30316
30317         * lib/modechange.c: Do not assume that mode_t uses the
30318         traditional octal encoding.  E.g. "chmod 1 FOO" should set
30319         the other-execute bit of FOO even if S_IXOTH != 1.
30320
30321         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
30322         WOTH, XOTH, ALLM): New macros.
30323         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
30324          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
30325         Use them.
30326         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
30327         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
30328         (mode_compile):
30329         No need to use uintmax_t; unsigned long is long enough.
30330         Don't bother to get suffix since we don't use it.
30331
30332 2000-12-26  Jim Meyering  <meyering@lucent.com>
30333
30334         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
30335         better with autoheader.
30336
30337 2000-12-24  Jim Meyering  <meyering@lucent.com>
30338
30339         * lib/hash.c (is_prime): Return explicit boolean values.
30340         (hash_get_first): Return NULL to appease Irix5.6's 89.
30341         Reported by Nelson Beebe.
30342
30343 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
30344
30345         * lib/localcharset.c (locale_charset): Add support for Win32.
30346
30347 2000-12-18  Paul Eggert  <eggert@twinsun.com>
30348
30349         * lib/physmem.h, lib/physmem.c: New files.
30350
30351         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
30352         (noinst_HEADERS): Add physmem.h.
30353
30354         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
30355         't' for compatibility with Solaris 8 sort.
30356
30357 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
30358
30359         * lib/config.charset: Add support for BeOS.
30360
30361 2000-12-17  Jim Meyering  <meyering@lucent.com>
30362
30363         * m4/dos.m4 (jm_AC_DOS): New file and macro.
30364         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
30365
30366 2000-12-16  Jim Meyering  <meyering@lucent.com>
30367
30368         This bug had a serious impact on chown: `chown N:M FILE' (for integer
30369         N and M) would have treated it like `chown N:N FILE'.
30370
30371         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
30372
30373 2000-12-16  Jim Meyering  <meyering@lucent.com>
30374
30375         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
30376         SHELLS_FILE to a file name that's useful on djgpp systems.
30377         Include stdlib.h.
30378         (ADDITIONAL_DEFAULT_SHELLS): Define.
30379         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
30380         Based mostly on a patch from Prashant TR.
30381
30382 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
30383
30384         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
30385         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
30386         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
30387
30388 2000-12-08  Andreas Schwab  <schwab@suse.de>
30389
30390         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
30391         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
30392
30393 2000-12-07  Jim Meyering  <meyering@lucent.com>
30394
30395         * lib/stripslash.c (ISSLASH): Define.
30396         (strip_trailing_slashes): Use ISSLASH rather than comparing against
30397         `/'.
30398         From Prashant TR.
30399
30400         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
30401         (dir_name_r): Declare this function as static.
30402         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
30403         manifest itself on a name containing a mix of slashes and
30404         backslashes.
30405         Make this function work with names starting with a DOS-style
30406         drive letter and colon prefix.
30407         (dir_name): Append `.' if necessary.
30408         Based mostly on patches from Prashant TR and Eli Zaretskii.
30409
30410         * lib/dirname.h (dir_name_r): Remove prototype.
30411
30412 2000-12-06  Paul Eggert  <eggert@twinsun.com>
30413
30414         * m4/off_t-format.m4: Remove this file.
30415         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
30416
30417 2000-12-06  Jim Meyering  <meyering@lucent.com>
30418
30419         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
30420         replacement strtoull, we may well need the replacement strtoul, too.
30421         Check for declarations of strtoul and strtoull.
30422         Check for strtol.  Mainly as a cue to cause automake to include
30423         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
30424         Check for limits.h -- strtol.c needs it.
30425
30426 2000-12-05  Jim Meyering  <meyering@lucent.com>
30427
30428         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
30429
30430 2000-12-04  Jim Meyering  <meyering@lucent.com>
30431
30432         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
30433         Also include memory.h, stdlib.h, unistd.h if appropriate.
30434         Reported by Andreas Jaeger (conflicting declaration of malloc).
30435
30436 2000-12-02  Jim Meyering  <meyering@lucent.com>
30437
30438         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
30439         * m4/jm-macros.m4 (jm_MACROS): require it.
30440
30441 2000-12-02  Jim Meyering  <meyering@lucent.com>
30442
30443         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
30444
30445 2000-12-01  Paul Eggert  <eggert@twinsun.com>
30446
30447         * lib/memrchr.c: Include <config.h> before any system include file.
30448
30449 2000-11-30  Jim Meyering  <meyering@lucent.com>
30450
30451         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
30452
30453 2000-11-30  Jim Meyering  <meyering@lucent.com>
30454
30455         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
30456
30457 2000-11-29  Paul Eggert  <eggert@twinsun.com>
30458
30459         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
30460
30461 2000-11-26  Jim Meyering  <meyering@lucent.com>
30462
30463         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
30464
30465 2000-11-22  Paul Eggert  <eggert@twinsun.com>
30466
30467         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
30468         size of (size_t) -1; it's not portable.
30469
30470 2000-11-17  Jim Meyering  <meyering@lucent.com>
30471
30472         * lib/strstr.c: Update from GNU libc.
30473
30474 2000-11-17  Akim Demaille  <akim@epita.fr>
30475
30476         * lib/obstack.h: Formatting changes.
30477         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
30478         prevent type checking.
30479         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
30480         cast the value to (void *): assigning a `foo *' to a `void *'
30481         variable is valid.
30482         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
30483
30484 2000-11-16  Jim Meyering  <meyering@lucent.com>
30485
30486         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
30487
30488 2000-11-11  Jim Meyering  <meyering@lucent.com>
30489
30490         * lib/error.c: Add a couple #includes, merging from GNU libc version.
30491
30492 2000-11-10  Jim Meyering  <meyering@lucent.com>
30493
30494         * lib/obstack.h: Update from GNU libc.
30495         * lib/obstack.c: Likewise.
30496
30497 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
30498
30499         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
30500
30501 2000-11-06  Paul Eggert  <eggert@twinsun.com>
30502
30503         * lib/getusershell.c (setusershell): Use rewind rather than
30504         fseek/fseeko, to avoid configuration hassles with fseeko.
30505         Don't bother opening SHELLS_FILE if shellstream is NULL;
30506         it's not necessary.
30507
30508 2000-11-05  Jim Meyering  <meyering@lucent.com>
30509
30510         * lib/makepath.h (make_dir): Declare.
30511         * lib/makepath.c (make_dir): Remove `static' attribute.
30512         Tweak a comment.
30513
30514 2000-11-04  Jim Meyering  <meyering@lucent.com>
30515
30516         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
30517
30518 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
30519
30520         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
30521         last one in a bucket, advance to the next bucket.
30522
30523 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
30524
30525         * lib/fnmatch.c: Do not comment out all the code if we are using
30526         the GNU C library, because in some cases we are replacing buggy
30527         code in the GNU C library itself.
30528
30529 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
30530
30531         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
30532         (regex_compile): Catch bogus \(\1\).
30533
30534 2000-10-30  Paul Eggert  <eggert@twinsun.com>
30535
30536         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
30537         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
30538         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
30539
30540 2000-10-30  Paul Eggert  <eggert@twinsun.com>
30541
30542         * lib/error.h, getline.h, modechange.h:
30543         Remove "2000" from Copyright line, as the file hasn't been
30544         changed this year other than in the copyright notice.
30545
30546         * lib/xalloc.h: Add "2000" to Copyright line, as this file
30547         was changed this year.
30548
30549 2000-10-29  Jim Meyering  <meyering@lucent.com>
30550
30551         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
30552         renaming.
30553         * m4/ls-mntd-fs.m4: Likewise
30554
30555 2000-10-29  Jim Meyering  <meyering@lucent.com>
30556
30557         * lib/xstat.in: Fix grammar in comment.
30558
30559 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
30560
30561         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
30562         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
30563         doesn't define __restrict_arr.
30564
30565 2000-10-28  Jim Meyering  <meyering@lucent.com>
30566
30567         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
30568         (jm_PREREQ_MEMCHR): New function.
30569
30570 2000-10-28  Jim Meyering  <meyering@lucent.com>
30571
30572         * lib/memchr.c: Update from libc.
30573         Adjust for portability:
30574         [HAVE_STDLIB_H]: Include stdlib.h.
30575         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
30576         Undef __memchr, too.
30577         [!weak_alias]: Define __memchr to memchr.
30578
30579         * lib/regex.c: Update from libc.
30580         * lib/regex.h: Likewise.
30581         * lib/getopt1.c: Likewise.
30582         * lib/memcmp.c: Likewise.
30583
30584         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
30585         Avoid using fseek, when possible -- it's broken by design.
30586         Patch by Ulrich Drepper.
30587
30588 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
30589
30590         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
30591         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
30592         Giving in to popular pressure to shut up the compiler with casts.
30593
30594 2000-10-26  Jim Meyering  <meyering@lucent.com>
30595
30596         * lib/strftime.c: Update from libc.
30597
30598 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
30599
30600         * regex.c: More `unsigned char' -> `re_char' changes.
30601         Also change several `int' into `re_wchar_t'.
30602         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
30603         (PUSH_FAILURE_POINTER): Don't cast any more.
30604         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
30605         We want GCC to complain, since this piece of code makes
30606         re_match non-reentrant, which *should* be fixed.
30607         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
30608         (EXTEND_BUFFER): Use RETALLOC.
30609         (SET_LIST_BIT): Don't cast.
30610         (re_wchar_t): New type.
30611         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
30612         that those two functions will always properly return.
30613         (IMMEDIATE_QUIT_CHECK): Cast to void.
30614         (analyse_first): Use recursion rather than an explicit stack.
30615         (re_compile_fastmap): Can't fail anymore.
30616         (re_search_2): Don't check re_compile_fastmap for failure.
30617         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
30618         Now also sets the new value (passed in a new argument).
30619         (re_match_2_internal): Use it.
30620         Also, use a new var `reg' of type size_t when looping through regs
30621         rather than reuse the inappropriate `mcnt'.
30622
30623 2000-10-25  Jim Meyering  <meyering@lucent.com>
30624
30625         * lib/obstack.c: Update from libc.
30626
30627 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
30628
30629         * regex.c (regex_compile): Change the way of handling a range from
30630         a char less than 256 to a char not less than 256.
30631
30632 2000-10-24  Andrew Innes  <andrewi@gnu.org>
30633
30634         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
30635         NT-Emacs only.
30636         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
30637         so that re_search functions only quit when callers expect them to.
30638
30639 2000-10-23  Jim Meyering  <meyering@lucent.com>
30640
30641         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
30642         wrong.  That set_locale call must not have any side effects.
30643         From Paul Eggert.
30644
30645 2000-10-22  Jim Meyering  <meyering@lucent.com>
30646
30647         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
30648         [CYCLIC]: Remove now-unused definition.
30649
30650         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
30651         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
30652         Suggestion from Ulrich Drepper.
30653
30654 2000-10-21  Jim Meyering  <meyering@lucent.com>
30655
30656         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
30657         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
30658         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
30659
30660 2000-10-21  Jim Meyering  <meyering@lucent.com>
30661
30662         * lib/dirname.c (memrchr): Declare if necessary.
30663         (dir_name): Remove the restriction that there be no
30664         trailing slashes.  Now, this code skips past them, effectively
30665         ignoring them.
30666         [TEST_DIRNAME] (main): New unit tests.
30667
30668         * lib/memrchr.c: New file from GNU libc.
30669         Undef __memrchr, too.
30670         [!weak_alias]: Define __memrchr to memrchr.
30671         Guard weak_alias use with `#ifdef weak_alias'.
30672
30673 2000-10-21  Jim Meyering  <meyering@lucent.com>
30674
30675         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
30676         (dir_name): Use dir_name_r.
30677         * lib/dirname.h (dir_name_r): Declare it.
30678
30679 2000-10-17  Jim Meyering  <meyering@lucent.com>
30680
30681         * lib/quote.h (PARAMS): Define and use.
30682         Reported by Akim Demaille.
30683
30684         * lib/getopt.c: Update from libc.
30685
30686 2000-10-16  Jim Meyering  <meyering@lucent.com>
30687
30688         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
30689         setlocale.
30690         From Jan Fedak.
30691
30692 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
30693
30694         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
30695
30696 2000-09-25  Jim Meyering  <meyering@lucent.com>
30697
30698         * lib/md5.h (rol): Define (from GnuPG).
30699
30700         * lib/sha.c: Give credit (GnuPG) where due.
30701         (M): Use rol rather than open-coding it.
30702         Add a FIXME comment.
30703
30704 2000-09-21  Jim Meyering  <meyering@lucent.com>
30705
30706         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
30707         Reported by Michael Stone.
30708
30709 2000-09-20  Jim Meyering  <meyering@lucent.com>
30710
30711         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
30712         (noinst_HEADERS): Add sha.h.
30713         Based on code from Scott G. Miller and from GnuPG.
30714
30715 2000-09-18  Jim Meyering  <meyering@lucent.com>
30716
30717         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
30718         LIBS. Otherwise, everyone ends up linking with -lelf for some
30719         configurations.
30720         Reported by Mike Stone.
30721
30722 2000-09-15  Jim Meyering  <meyering@lucent.com>
30723
30724         * lib/regex.c: Update from libc.
30725
30726 2000-09-10  Jim Meyering  <meyering@lucent.com>
30727
30728         * lib/getopt.c (_getopt_internal): Update from glibc.
30729
30730 2000-09-09  Jim Meyering  <meyering@lucent.com>
30731
30732         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
30733         think it should be used as a general replacement for isascii.
30734         * lib/fnmatch.c: Likewise.
30735         * lib/mbswidth.c: Likewise
30736         * lib/regex.c: Likewise.
30737
30738         Don't use atoi.
30739         * lib/userspec.c: Include sys/param.h and limits.h.
30740         Include xstrtol.h.
30741         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
30742         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
30743         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
30744         UID, GID.  Check range.
30745
30746 2000-09-06  Jim Meyering  <meyering@lucent.com>
30747
30748         * lib/getopt.c (_getopt_internal): Update from glibc.
30749
30750 2000-08-30  Jim Meyering  <meyering@lucent.com>
30751
30752         * lib/strftime.c: Merge in changes from GNU libc.
30753
30754 2000-08-26  Jim Meyering  <meyering@lucent.com>
30755
30756         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
30757         * m4/fpending.m4: New file.
30758
30759 2000-08-26  Jim Meyering  <meyering@lucent.com>
30760
30761         * lib/closeout.c: Include "__fpending.h".
30762         (close_stdout_status): Return right away if there's nothing to flush.
30763
30764         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
30765         * lib/__fpending.c: New file.
30766         * lib/__fpending.h: New file.
30767
30768 2000-08-20  Jim Meyering  <meyering@lucent.com>
30769
30770         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
30771         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
30772         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
30773
30774 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
30775
30776         Improve fileutils installation on systems where running
30777         programs (like install) can't be unlinked.
30778         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
30779         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
30780
30781 2000-08-07  Paul Eggert  <eggert@twinsun.com>
30782
30783         Standardize on "memory exhausted" instead of "Memory exhausted"
30784         or "virtual memory exhausted".
30785         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
30786         "virtual memory exhausted".
30787         * lib/same.c (same_name): Invoke xalloc_die instead of printing
30788         our own message.
30789         * lib/userspec.c (parse_user_spec): Likewise.
30790         * lib/bumpalloc.h: comment fix
30791         * lib/same.c, userspec.c: Include xalloc.h.
30792
30793         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
30794         not char *const and pointing to a constant array.
30795         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
30796         (xrealloc): Comment fix.
30797
30798         * lib/userspec.c (parse_user_spec):
30799         Don't translate a message until just before returning,
30800         to avoid unnecessary translation.
30801
30802 2000-08-07  Jim Meyering  <meyering@lucent.com>
30803
30804         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
30805         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
30806         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
30807         getgroups.c, gethostname.c, getopt.h, group-member.c,
30808         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
30809         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
30810         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
30811         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
30812         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
30813         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
30814         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
30815         yesno.c: Back out Copyright date changes for each file with no change
30816         this year.  This eases coordination with other programs using the same
30817         source code modules.  From Paul Eggert.
30818
30819 2000-08-06  Paul Eggert  <eggert@twinsun.com>
30820
30821         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
30822         not char, for compatibility with glibc 2.1.3 strftime.c.
30823
30824 2000-08-03  Greg McGary  <greg@mcgary.org>
30825
30826         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
30827         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
30828         (EXTEND_BUFFER): Use them.
30829
30830 2000-08-01  Jim Meyering  <meyering@lucent.com>
30831
30832         * lib/dirname.c (ISSLASH): Define.
30833         (BACKSLASH_IS_PATH_SEPARATOR): Define.
30834         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
30835         both `\' and `/' may be use as path separators.
30836         Based on a patch from Prashant TR.
30837
30838 2000-07-31  Paul Eggert  <eggert@twinsun.com>
30839
30840         * lib/quotearg.c (quotearg_n_options): Don't make the initial
30841         slot vector a constant, since it might get modified.
30842
30843 2000-07-31  Jim Meyering  <meyering@lucent.com>
30844
30845         * lib/xmalloc.c: Use `virtual memory exhausted', not
30846         `Memory exhausted'.
30847         * lib/obstack.c (print_and_abort): Likewise.
30848
30849 2000-07-30  Paul Eggert  <eggert@twinsun.com>
30850
30851         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
30852         buffer, so that the caller can always quote one small
30853         component of a "memory exhausted" message in slot 0.
30854         From a suggestion by Jim Meyering.
30855
30856 2000-07-30  Jim Meyering  <meyering@lucent.com>
30857
30858         * lib/makepath.c (make_path): Quote the other instance, too.
30859
30860         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
30861         (STATIC_BUF_SIZE): Define.
30862         (quotearg_n_options): Use only statically allocated storage when
30863         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
30864         than STATIC_BUF_SIZE.
30865
30866 2000-07-29  Jim Meyering  <meyering@lucent.com>
30867
30868         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
30869         * lib/dirname.c (dir_name): Likewise.
30870
30871         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
30872         `/'.
30873
30874         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
30875         (dir_name): Assert that there are no trailing slashes.
30876
30877 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
30878
30879         * lib/mbswidth.h (mbswidth): Add a flags argument.
30880         (mbswidth): New declaration.
30881         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
30882         * lib/mbswidth.c (mbswidth): Add a flags argument.
30883         (mbsnwidth): New function.
30884
30885 2000-07-24  Jim Meyering  <meyering@lucent.com>
30886
30887         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
30888
30889 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30890
30891         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
30892
30893 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30894
30895         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
30896         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
30897         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
30898         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
30899         invoke multibyte primitives.
30900
30901 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30902
30903         * lib/quotearg.c:
30904         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
30905         so that mbstate_t is always defined.
30906
30907         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
30908         be 1 in at least one GCC installation, and this configuration
30909         error is likely to be common.  Ignoring MB_LEN_MAX hurts
30910         performance on hosts that have mbrtowc but have only unibyte
30911         locales, but I assume these hosts are rare.
30912
30913 2000-07-23  Paul Eggert  <eggert@twinsun.com>
30914
30915         * lib/mbswidth.c (_XOPEN_SOURCE):
30916         Don't define; this causes problems on Solaris 7.
30917         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
30918
30919 2000-07-23  Jim Meyering  <meyering@lucent.com>
30920
30921         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
30922         too: getgrgid, getpwuid, getuid.
30923
30924 2000-07-23  Jim Meyering  <meyering@lucent.com>
30925
30926         * lib/basename.c (base_name): Add an assertion.
30927
30928 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
30929
30930         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
30931         shadow its mbsinit function.
30932
30933 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
30934
30935         * lib/mbswidth.h: New file.
30936         * lib/mbswidth.c: New file.
30937         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
30938         (noinst_HEADERS): Add mbswidth.h.
30939
30940 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
30941
30942         * lib/config.charset: Add support for FreeBSD. Improve support for
30943         HP-UX and IRIX 6.
30944
30945 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
30946
30947         * m4/mbswidth.m4: New file.
30948         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
30949
30950 2000-07-15  Jim Meyering  <meyering@lucent.com>
30951
30952         * lib/makepath.c: Include quote.h.
30953         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
30954         corresponding argument in a `quote (...)' call.
30955         Give better diagnostics.
30956
30957         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
30958         (noinst_HEADERS): Add quote.h.
30959
30960         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
30961         from tar's src/misc.c.
30962         * lib/quote.h: New file.  Prototypes for same.
30963
30964 2000-07-14  Paul Eggert  <eggert@twinsun.com>
30965
30966         From a suggestion by Bruno Haible.
30967         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
30968         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
30969         to decide whether to define the BeOS workaround macro;
30970         this adjusts to the change to AC_MBSTATE_T.
30971
30972 2000-07-14  Jim Meyering  <meyering@lucent.com>
30973
30974         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
30975         jm_AC_TYPE_UINTMAX_T.
30976
30977 2000-07-13  Paul Eggert  <eggert@twinsun.com>
30978
30979         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
30980
30981         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
30982         quotearg_buffer_restyled): Add support for
30983         clocale_quoting_style.  Undo previous change to
30984         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
30985         and "{RIGHT QUOTATION MARK}" msgids.
30986
30987 2000-07-10  Paul Eggert  <eggert@twinsun.com>
30988
30989         From a suggestion by Bruno Haible.
30990         * m4/mbstate_t.m4 (AC_MBSTATE_T):
30991         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
30992         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
30993         and mbstate_t, to a single-part test that simply defines mbstate_t.
30994         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
30995         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
30996
30997 2000-07-10  Jim Meyering  <meyering@lucent.com>
30998
30999         * m4/strerror_r.m4: Mirror the correction made in autoconf.
31000
31001         * m4/gnu-source.m4: Output to confdefs.h directly.
31002         Suggestion from Akim Demaille.
31003
31004 2000-07-09  Paul Eggert  <eggert@twinsun.com>
31005
31006         The old behavior of quoting `like this' doesn't look good with
31007         newer, ISO-style fonts.  See:
31008         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
31009
31010         Instead, quote "like this" by default.  Let the translator
31011         tailor the locale-specific quoting behavior by providing
31012         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
31013
31014         * lib/quotearg.c (N_): New macro.
31015         (gettext_default): New function.
31016         (quotearg_buffer_restyled): Use
31017         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
31018         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
31019
31020 2000-07-09  Jim Meyering  <meyering@lucent.com>
31021
31022         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
31023         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
31024
31025         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
31026         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
31027
31028 2000-07-09  Jim Meyering  <meyering@lucent.com>
31029
31030         * lib/Most files: Update copyright dates to include 2000.
31031
31032 2000-07-08  Jim Meyering  <meyering@lucent.com>
31033
31034         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
31035         if not defined.
31036         (xgethostname): Remove now-unnecessary #ifdef.
31037         Move declaration of `err' into loop where it's used.
31038
31039 2000-07-05  Paul Eggert  <eggert@twinsun.com>
31040         and Bruno Haible  <haible@clisp.cons.org>
31041
31042         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
31043         only if the test for an object-type mbstate_t fails.  This
31044         prevents us from mistakenly reporting that mbstate_t is a
31045         system object type after we "#define mbstate_t int" to work
31046         around its lack.
31047
31048 2000-07-05  Paul Eggert  <eggert@twinsun.com>
31049         and Bruno Haible  <haible@clisp.cons.org>
31050
31051         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
31052
31053 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
31054
31055         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
31056         to strerror_r.
31057         Include <ctype.h> for use of isalpha.
31058
31059 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
31060
31061         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
31062         by allocating a larger buffer. Test the gethostname return value for
31063         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
31064         returns an error and ENAMETOOLONG isn't defined.
31065
31066 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
31067
31068         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
31069         dimension.
31070
31071 2000-07-04  Jim Meyering  <meyering@lucent.com>
31072
31073         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
31074         of the deprecated AC_CHECKING.
31075
31076 2000-07-04  Jim Meyering  <meyering@lucent.com>
31077
31078         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
31079         Reported by Bruno Haible.
31080
31081 2000-07-04  Jim Meyering  <meyering@lucent.com>
31082
31083         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
31084         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
31085         lacks mbrtowc.
31086
31087 2000-07-03  Paul Eggert  <eggert@twinsun.com>
31088
31089         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
31090         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
31091
31092 2000-07-03  Paul Eggert  <eggert@twinsun.com>
31093         and Bruno Haible  <haible@clisp.cons.org>
31094
31095         * lib/quotearg.c (mbrtowc):
31096         Assign to *pwc, and return 1 only if result is nonzero.
31097         (iswprint): Use ISPRINT when substituting our own mbrtowc.
31098
31099 2000-07-03  Jim Meyering  <meyering@lucent.com>
31100
31101         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
31102
31103 2000-07-03  Jim Meyering  <meyering@lucent.com>
31104
31105         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
31106         This is necessary to get a definition of e.g., UTMP_FILE on
31107         HP-UX 10.20.
31108         From Bob Proulx.
31109
31110 2000-07-02  Jim Meyering  <meyering@lucent.com>
31111
31112         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
31113
31114         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
31115         AC_LIBOBJ(function_name).
31116         * m4/chown.m4: Likewise.
31117         * m4/fnmatch.m4: Likewise.
31118         * m4/ftruncate.m4: Likewise.
31119         * m4/getgroups.m4: Likewise.
31120         * m4/getline.m4: Likewise.
31121         * m4/group-member.m4: Likewise.
31122         * m4/jm-macros.m4: Likewise.
31123         * m4/lstat.m4: Likewise.
31124         * m4/malloc.m4: Likewise.
31125         * m4/memcmp.m4: Likewise.
31126         * m4/nanosleep.m4: Likewise.
31127         * m4/putenv.m4: Likewise.
31128         * m4/realloc.m4: Likewise.
31129         * m4/regex.m4: Likewise.
31130         * m4/stat.m4: Likewise.
31131         * m4/strftime.m4: Likewise.
31132
31133 2000-07-02  Jim Meyering  <meyering@lucent.com>
31134
31135         * lib/quotearg.c (mbstate_t): Don't define here.
31136
31137 2000-07-02  Jim Meyering  <meyering@lucent.com>
31138
31139         * lib/nanosleep.c (SIGCONT): Define if not already defined.
31140
31141 2000-07-01  Jim Meyering  <meyering@lucent.com>
31142
31143         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
31144
31145 2000-07-01  Jim Meyering  <meyering@lucent.com>
31146
31147         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
31148         problem.
31149
31150 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
31151
31152         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
31153         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
31154
31155 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
31156
31157         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
31158         per change in ../m4/ls-mntd-fs.m4.
31159         (read_filesystem_list): Ignore symbolic links.
31160
31161 2000-06-29  Jim Meyering  <meyering@lucent.com>
31162
31163         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
31164         for declaration of strcmp.
31165
31166         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
31167
31168         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
31169         Avoid warning by casting result to `char *' to remove `const'.
31170
31171 2000-06-28  Jim Meyering  <meyering@lucent.com>
31172
31173         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
31174         included by quotearg.c, for which we perform this test.  From
31175         Bruno Haible.
31176
31177 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
31178
31179         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
31180         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
31181         <utmpx.h> exists, put readutmp.o into LIBOBJS.
31182
31183 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
31184
31185         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
31186
31187 2000-06-26  Paul Eggert  <eggert@twinsun.com>
31188
31189         savedir now sets errno on failure and invokes xmalloc to get memory.
31190         Fix a couple of other minor bugs while we're at it.
31191
31192         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
31193         (NAMLEN): Remove macro.
31194         (malloc, realloc): Remove decls.
31195         (stpcpy): Likewise.
31196         ("xalloc.h"): Include.
31197         (NAME_SIZE_DEFAULT): New macro.
31198         (savedir): Use xmalloc / xrealloc to allocate memory.
31199         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
31200         Skip "" directory entries.
31201         Use strlen to calculate directory entry length, since the old method
31202         is rarely used these days and isn't worth supporting.
31203         Don't use a pointer after freeing it.
31204         Check for integer overflow when calculating allocation size.
31205         Use memcpy to copy entries, instead of stpcpy.
31206         Set errno properly when returning NULL.
31207         Check for readdir error.
31208
31209 2000-06-26  Jim Meyering  <meyering@lucent.com>
31210
31211         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
31212
31213 2000-06-25  Jim Meyering  <meyering@lucent.com>
31214
31215         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
31216         Linux header bug when _XOPEN_SOURCE is defined to 500.
31217
31218 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
31219
31220         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
31221         deficiency.
31222
31223 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
31224
31225         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
31226         Include xalloc.h.
31227         Don't include <stdlib.h>.  Don't declare malloc, realloc.
31228
31229 2000-06-24  Jim Meyering  <meyering@lucent.com>
31230
31231         * m4/strerror_r.m4: Revive this file -- to try out an experimental
31232         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
31233         for which strerror does return char*, but which lacks a conveniently
31234         accessible declaration of the function.  If the compile-test says
31235         strerror_r doesn't work, then resort to a `run'-test that works on
31236         BeOS and segfaults on DEC Unix.
31237
31238 2000-06-24  Jim Meyering  <meyering@lucent.com>
31239
31240         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
31241
31242 2000-06-23  Paul Eggert  <eggert@twinsun.com>
31243
31244         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
31245         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
31246
31247 2000-06-23  Paul Eggert  <eggert@twinsun.com>
31248
31249         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
31250         (mbrtowc, mbstate_t): Define substitutes if
31251         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
31252         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
31253         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
31254
31255 2000-06-23  Jim Meyering  <meyering@lucent.com>
31256
31257         * m4/afs.m4: Add missing AC_MSG_RESULT.
31258         Reported by Bruno Haible.
31259
31260         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
31261         Suggestion from Bruno Haible.
31262
31263 2000-06-23  Jim Meyering  <meyering@lucent.com>
31264
31265         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
31266
31267 2000-06-21  Jim Meyering  <meyering@lucent.com>
31268
31269         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
31270
31271 2000-06-21  Jim Meyering  <meyering@lucent.com>
31272
31273         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
31274         (noinst_HEADERS): Add getstr.h.
31275
31276         * lib/getline.c (getstr): Move into a separate file.
31277         * lib/getstr.c (getstr): New file, extracted from getline.c, with
31278         the following changes: new parameter, delim2; both delim[12]
31279         parameters have type `int', not `char'.  The latter would lose
31280         with 8-bit delimiters.
31281         * lib/getstr.h: New file.
31282
31283 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
31284
31285         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
31286         than 1024, return a memory chunk of least possible size, instead
31287         of size PATH_MAX + 2. In the loop, increment the size proportionally.
31288         Use free/xmalloc instead of xrealloc to avoid copying for very long
31289         paths.
31290
31291 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
31292
31293         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
31294         the empty string.
31295
31296 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
31297
31298         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
31299         address, not strdup.  Include <stdlib.h> and don't declare free().
31300
31301 2000-06-19  Jim Meyering  <meyering@lucent.com>
31302
31303         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
31304
31305 2000-06-18  Jim Meyering  <meyering@lucent.com>
31306
31307         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
31308
31309         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
31310         `checking whether...' message to be consistent with that of the
31311         lstat test.
31312
31313 2000-06-18  Jim Meyering  <meyering@lucent.com>
31314
31315         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
31316         Besides, these days every porting target provides a mkdir function.
31317
31318         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
31319         needed. (this snippet comes from src/system.h).
31320
31321 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
31322
31323         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
31324
31325 2000-06-15  Paul Eggert  <eggert@twinsun.com>
31326
31327         * lib/human.c (adjust_value): New function.
31328         (human_readable_inexact): Apply rounding style even when
31329         printing approximate values.
31330
31331 2000-06-14  Paul Eggert  <eggert@twinsun.com>
31332
31333         * lib/human.c (human_readable_inexact): Allow an input block
31334         size that is not a multiple of the output block size, and vice versa.
31335         Reported by Piergiorgio Sartor.
31336
31337 2000-06-14  Paul Eggert  <eggert@twinsun.com>
31338
31339         * lib/getdate.y (get_date): Apply relative times after time
31340         zone indicator, not before.  Reported by Todd A. Jacobs.
31341
31342 2000-06-13  Jim Meyering  <meyering@lucent.com>
31343
31344         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
31345
31346         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
31347
31348 2000-06-12  Paul Eggert  <eggert@twinsun.com>
31349
31350         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
31351
31352 2000-06-12  Jim Meyering  <meyering@lucent.com>
31353
31354         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
31355         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
31356         optional argument.
31357         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
31358         the optional argument, `lib'.
31359
31360 2000-06-08  Jim Meyering  <meyering@lucent.com>
31361
31362         * m4/largefile.m4: Remove file (now that it's part of autoconf).
31363
31364 2000-06-04  Paul Eggert  <eggert@twinsun.com>
31365
31366         Rewrite largefile configuration so that we don't need to run
31367         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
31368         AC_CANONICAL_HOST in configure.in -- jmm]
31369
31370         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
31371         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
31372         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
31373         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
31374         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
31375         All uses changed.
31376         Instead of inspecting the output of getconf, try to compile the
31377         test program without and with the macro definition.
31378         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
31379         for getconf.  Instead, check for the needed flags by compiling
31380         test programs.
31381
31382 2000-06-04  Paul Eggert  <eggert@twinsun.com>
31383
31384         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
31385
31386 2000-06-04  Jim Meyering  <meyering@lucent.com>
31387
31388         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
31389         SunOS 4.1.4 for which gid_t is an unsigned type.
31390
31391 2000-06-03  Jim Meyering  <meyering@lucent.com>
31392
31393         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
31394         now that autoconf requires that.
31395
31396         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
31397         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
31398         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
31399
31400 2000-06-03  Jim Meyering  <meyering@lucent.com>
31401
31402         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
31403
31404 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
31405
31406         * m4/glibc21.m4: New file.
31407         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
31408
31409 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
31410
31411         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
31412         newer, don't install charset.alias.
31413         * lib/config.charset: Change the Linux/glibc rules so they become empty
31414         on glibc-2.1 or newer.
31415
31416 2000-06-02  Jim Meyering  <meyering@lucent.com>
31417
31418         * lib/mountlist.c: Back out last change.  Instead, do this...
31419         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
31420         me_dummy member using the same `ignore'-testing code.
31421         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
31422         fs_type strings.
31423         From Mark D. Roth.
31424
31425 2000-05-29  Jim Meyering  <meyering@lucent.com>
31426
31427         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
31428         mounts with the `ignore' attribute.  Based on a patch from
31429         Mark D. Roth.
31430
31431 2000-05-28  Jim Meyering  <meyering@lucent.com>
31432
31433         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
31434         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
31435         * m4/stat.m4: Likewise.
31436         * m4/lstat.m4: Likewise.
31437         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
31438
31439         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
31440         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
31441
31442 2000-05-26  Jim Meyering  <meyering@lucent.com>
31443
31444         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
31445
31446 2000-05-24  Jim Meyering  <meyering@lucent.com>
31447
31448         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
31449         autoconf requires that.
31450         * m4/lib-check.m4: Likewise.
31451         * m4/jm-macros.m4: Likewise.
31452         * m4/strftime.m4: Likewise.
31453
31454         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
31455         AC_CHECK_DECLS, now that autoconf requires that.
31456
31457 2000-05-22  Jim Meyering  <meyering@lucent.com>
31458
31459         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
31460         * m4/lstat.m4: Likewise.
31461
31462 2000-05-22  Jim Meyering  <meyering@lucent.com>
31463
31464         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
31465
31466 2000-05-20  Jim Meyering  <meyering@lucent.com>
31467
31468         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
31469         (jm_PREREQ): Use it.
31470
31471 2000-05-18  Jim Meyering  <meyering@lucent.com>
31472
31473         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
31474         back, too, since it may have been modified by allocate_entry.
31475         (hash_delete): Rewrite to use neither the assignment operator
31476         nor the comma operator in an if-expression.
31477
31478 2000-05-15  Paul Eggert  <eggert@twinsun.com>
31479
31480         * lib/closeout.c:
31481         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
31482         Remove; no longer needed.
31483         "quotearg.h": Add include.
31484         (file_name): Do not bother to explicitly initialize to NULL; it's less
31485         efficient on some hosts.
31486         (close_stdout_status): Remove test as to whether stdout was already
31487         closed; it breaks for the case "echo x | sort >&-".
31488         Quote file name colons.
31489         Do not assume that _("write error") lacks format strings.
31490
31491 2000-05-15  Jim Meyering  <meyering@lucent.com>
31492
31493         * lib/version-etc.c (version_etc_copyright): Update the copyright
31494         string used in all --version output.
31495
31496 2000-05-14  Jim Meyering  <meyering@lucent.com>
31497
31498         * lib/closeout.c (close_stdout_set_file_name): New function.
31499         (close_stdout_status): Use new file-scoped global.
31500         Return right away if fstat says the stdout file descriptor is invalid.
31501         * lib/closeout.h (close_stdout_set_file_name): Declare.
31502
31503 2000-05-10  Jim Meyering  <meyering@lucent.com>
31504
31505         * lib/closeout.c [default_exit_status]: New file-scoped variable.
31506         (close_stdout_set_status): New function.
31507         * lib/closeout.h (close_stdout_set_status): Declare.
31508
31509 2000-05-09  Jim Meyering  <meyering@lucent.com>
31510
31511         * m4/gettext.m4: Rename this...
31512         * m4/libintl.m4: ...to this.
31513
31514 2000-05-08  Jim Meyering  <meyering@lucent.com>
31515
31516         * lib/long-options.c: Don't include closeout.h.
31517         (parse_long_options): Don't call close_stdout for --version.
31518
31519 2000-05-06  Paul Eggert  <eggert@twinsun.com>
31520
31521         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
31522         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
31523         2.1.3 bug.  This avoids a clash when files like regex.c define
31524         _GNU_SOURCE.
31525
31526 2000-05-06  Jim Meyering  <meyering@lucent.com>
31527
31528         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
31529         (AC_REPLACE_FUNCS): Add strnlen.
31530
31531         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
31532         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
31533
31534         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
31535         AC_SEARCH_LIBS call for nanosleep.
31536         (LIB_NANOSLEEP): Set and AC_SUBST.
31537
31538 2000-05-06  Jim Meyering  <meyering@lucent.com>
31539
31540         * lib/strnlen.c: Undefine __strnlen and strnlen.
31541         [!weak_alias]: Define __strnlen to strnlen.
31542
31543         * lib/atexit.c: New file, from libiberty.
31544
31545 2000-05-06  Jim Meyering  <meyering@lucent.com>
31546
31547         * lib/closeout.c (close_stdout_status): Also check for errors on the
31548         stderr stream.
31549
31550 2000-05-05  Jim Meyering  <meyering@lucent.com>
31551
31552         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
31553         AC_SEARCH_LIBS call for clock_gettime.
31554         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
31555
31556         * m4/search-libs.m4: Update from autoconf.
31557
31558         su doesn't work on Solaris 2.6.
31559         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
31560         <shadow.h>.  Reported by Dragos Harabor.
31561
31562 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
31563
31564         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
31565         memcpy instead of xmalloc, xrealloc, path_concat.
31566         (locale_charset): Treat empty environment variables as absent.
31567         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
31568
31569 2000-05-04  Jim Meyering  <meyering@lucent.com>
31570
31571         * lib/getopt.c: Update from glibc.
31572         * lib/obstack.c: Likewise.
31573         * lib/obstack.h: Likewise.
31574         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
31575         file
31576
31577         * lib/regex.h: Likewise.
31578         * lib/strndup.c: Likewise.
31579         * lib/strnlen.c: New file, from glibc.
31580
31581 2000-05-03  Jim Meyering  <meyering@lucent.com>
31582
31583         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
31584
31585 2000-05-02  Paul Eggert  <eggert@twinsun.com>
31586
31587         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
31588         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
31589         compile-time test, rather than inspecting host and OS, to
31590         decide whether to define _LARGEFILE_SOURCE.
31591
31592 2000-05-01  Jim Meyering  <meyering@lucent.com>
31593
31594         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
31595
31596         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
31597         Based on a patch from Bruno Haible.
31598
31599 2000-05-01  Jim Meyering  <meyering@lucent.com>
31600
31601         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
31602
31603 2000-04-29  Jim Meyering  <meyering@lucent.com>
31604
31605         * lib/path-concat.c: Declare strdup only if it's not defined.
31606         * lib/canon-host.c: Likewise.
31607
31608 2000-04-28  Jim Meyering  <meyering@lucent.com>
31609
31610         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
31611         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
31612         is included first, then limits.h is included by locale.h by libintl.h.
31613         From John David Anglin.
31614
31615 2000-04-25  Jim Meyering  <meyering@lucent.com>
31616
31617         * lib/makepath.c (S_IRWXUGO): Define.
31618         (make_path): Always perform explicit chmod if MODE specifies any
31619         of the `special' permission bits.  Prompted by a bug report against
31620         install from Mate Wierdl and Joost van Baal.
31621
31622 2000-04-18  Jim Meyering  <meyering@lucent.com>
31623
31624         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
31625         (jm_PREREQ): Use it.
31626
31627 2000-04-18  Jim Meyering  <meyering@lucent.com>
31628
31629         * lib/README: New file.
31630
31631         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
31632         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
31633
31634 2000-04-17  Jim Meyering  <meyering@lucent.com>
31635
31636         Get it right :-)
31637         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
31638         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
31639         Suggestion from Akim Demaille.
31640
31641 2000-04-17  Jim Meyering  <meyering@lucent.com>
31642
31643         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
31644         the definition of it to rpl_strftime also defined-away the system's
31645         declaration.
31646
31647 2000-04-15  Jim Meyering  <meyering@lucent.com>
31648
31649         Use `C' to denote so-called `contiguous' files, the same way
31650         that tar does.
31651         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
31652         (ftypelet): Use S_ISCTG.
31653         From Michael Deutschmann.
31654
31655 2000-04-14  Jim Meyering  <meyering@lucent.com>
31656
31657         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
31658         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
31659         clobbered.
31660
31661 2000-04-14  Jim Meyering  <meyering@lucent.com>
31662
31663         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
31664
31665 2000-04-13  Jim Meyering  <meyering@lucent.com>
31666
31667         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
31668         AH_VERBATIM to insert required #ifndef into config.h.in.
31669         Suggestion from Akim Demaille.
31670
31671 2000-04-12  Jim Meyering  <meyering@lucent.com>
31672
31673         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
31674         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
31675         Christian Krackowizer.
31676
31677         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
31678         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
31679         (AC_SYS_LARGEFILE): Require.
31680         (AM_C_PROTOTYPES): Require.
31681
31682 2000-04-08  Jim Meyering  <meyering@lucent.com>
31683
31684         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
31685         names don't conflict.  Reported by Eli Zaretskii.
31686
31687 2000-04-07  Jim Meyering  <meyering@lucent.com>
31688
31689         * lib/putenv.c: Move inclusion of errno.h so it follows that of
31690         sys/types.h, to work around system header problems on AIX 3.2.5.
31691         From Bruno Haible.
31692
31693 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
31694
31695         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
31696         bug.  Deal with the different error behavior of Irix iconv.
31697
31698 2000-04-05  Paul Eggert  <eggert@twinsun.com>
31699
31700         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
31701         IRIX if the installer said otherwise.
31702
31703 2000-04-05  Jim Meyering  <meyering@lucent.com>
31704
31705         Portability tweaks required for ultrix4.3.
31706         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
31707         (jm_CHECK_DECLS): Add getutent to the list of functions.
31708         (_jm_DECL_HEADERS): Add utmpx.h.
31709         From John David Anglin.
31710
31711         * m4/strftime.m4: Back out the 2000-04-02 change.
31712         Instead of that change, simply undefine putenv in the test program.
31713
31714 2000-04-05  Jim Meyering  <meyering@lucent.com>
31715
31716         Portability tweaks required for ultrix4.3.
31717         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
31718         getutent.
31719         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
31720         * lib/canon-host.c: Declare strdup.
31721         * lib/path-concat.c: Likewise.
31722         From John David Anglin.
31723
31724 2000-04-04  Jim Meyering  <meyering@lucent.com>
31725
31726         Be more DOS 8.3-friendly.
31727         * lib/ref-add.sin: Renamed from ref-add.sed.in.
31728         * lib/ref-del.sin: Renamed from ref-del.sed.in.
31729         * lib/Makefile.am: Reflect renaming.
31730         Reported by Eli Zaretskii.
31731
31732         Use a temporary file name that won't clash with `charset.alias'
31733         in the DOS 8.3 name space.
31734         * lib/Makefile.am (charset_tmp): Define.
31735         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
31736         (uninstall-local): Likewise.
31737         Reported by Eli Zaretskii.
31738
31739 2000-04-03  Jim Meyering  <meyering@lucent.com>
31740
31741         * m4/gettext.m4: Fix typo in comment.
31742
31743         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
31744         textutils/configure.in).  Suggestion from Paul Eggert.
31745         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
31746
31747 2000-04-02  Paul Eggert  <eggert@twinsun.com>
31748
31749         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
31750         variable in the shell rather than using putenv, which isn't
31751         portable.  This avoids the configure-time inter-test dependency
31752         on the potentially-renamed putenv function.
31753
31754 2000-03-30  Paul Eggert  <eggert@twinsun.com>
31755
31756         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
31757         before checking struct stat.st_blksize, so that
31758         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
31759
31760 2000-03-29  Paul Eggert  <eggert@twinsun.com>
31761
31762         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
31763         since strftime.c uses HAVE_STRFTIME to decide whether to use
31764         the underlying strftime.
31765
31766 2000-03-29  Paul Eggert  <eggert@twinsun.com>
31767
31768         * lib/time/strftime.c (my_strftime): Make sure we call the system
31769         strftime, not ourselves, when invoking the underlying strftime.
31770
31771 2000-03-24  Jim Meyering  <meyering@lucent.com>
31772
31773         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
31774         (charset_alias): Define.
31775         (install-exec-local): Factor out common code.
31776         (uninstall-local): Split lines longer than 80.
31777         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
31778         (SUFFIXES): Define.
31779         (.sed.in.sed): New rule.  Don't redirect directly to $@.
31780         (CLEANFILES): Add ref-add.sed and ref-del.sed.
31781
31782 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
31783
31784         * lib/config.charset: Output a line containing "Packages using this
31785         file".
31786         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
31787         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
31788         ref-del.sed): New rules.
31789
31790 2000-03-17  Jim Meyering  <meyering@lucent.com>
31791
31792         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
31793         Otherwise, include <strings.h>
31794
31795 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
31796
31797         * lib/unicodeio.c (utf8_wctomb): New function.
31798         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
31799         format instead of in UCS-4 with platform dependent endianness.
31800
31801 2000-03-10  Jim Meyering  <meyering@lucent.com>
31802
31803         * m4/lib-check.m4: Look for getspnam in -lgen, too.
31804         From Marco Franzen.
31805
31806 2000-03-07  Paul Eggert  <eggert@twinsun.com>
31807
31808         * lib/savedir.c (savedir): Work even if directory size is
31809         negative; this can happen with some screwy NFS configurations.
31810
31811 2000-03-06  Jim Meyering  <meyering@lucent.com>
31812
31813         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
31814         if it's NULL (because we ran out of memory).  From Bruno Haible.
31815
31816 2000-03-05  Jim Meyering  <meyering@lucent.com>
31817
31818         * lib/localcharset.c ("path-concat.h"): Include.
31819         (get_charset_aliases): Use path_concat instead of ANSI string
31820         concatenation.
31821
31822         * lib/unicodeio.h (PARAMS): Define.
31823         Use it to guard prototype.
31824
31825 2000-03-04  Jim Meyering  <meyering@lucent.com>
31826
31827         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
31828         for lib/localcharset.c.
31829
31830 2000-03-04  Jim Meyering  <meyering@lucent.com>
31831
31832         * lib/Makefile.am (install-exec-local): Create $(libdir) before
31833         installing into it.
31834         (uninstall-local): Uncomment this rule so `make distcheck' works
31835         once again.
31836
31837         * lib/unicodeio.c (<errno.h>): Include it.
31838         (errno): Declare if not defined.
31839
31840         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
31841
31842         * lib/config.charset: New version, incorporating remarks from a linux
31843         i18n mailing list.  From Bruno Haible.
31844
31845 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
31846
31847         * m4/codeset.m4: New file.
31848         * m4/iconv.m4: New file.
31849         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
31850
31851 2000-03-03  Jim Meyering  <meyering@lucent.com>
31852
31853         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
31854
31855 2000-03-02  Jim Meyering  <meyering@lucent.com>
31856
31857         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
31858         the messages come out on separate lines.
31859
31860         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
31861         rather than jm_CHECK_DECLARATIONS.
31862         * m4/decl.m4: Remove now-unused file.
31863
31864         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
31865         geteuid.
31866
31867 2000-03-02  Jim Meyering  <meyering@lucent.com>
31868
31869         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
31870
31871 2000-03-01  Jim Meyering  <meyering@lucent.com>
31872
31873         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
31874         * lib/unicodeio.c: Likewise.
31875
31876 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
31877
31878         * lib/config.charset: New file.
31879         * lib/localcharset.c: New file.
31880         * lib/unicodeio.h, lib/unicodeio.c: New files.
31881         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
31882         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
31883         (noinst_HEADERS): Add unicodeio.h.
31884         (all-local, install-exec-local, charset.alias): New targets.
31885
31886 2000-02-28  Paul Eggert  <eggert@twinsun.com>
31887
31888         * lib/quotearg.c (ALERT_CHAR): New macro.
31889         (quotearg_buffer_restyled): Use it.
31890
31891 2000-02-27  Jim Meyering  <meyering@lucent.com>
31892
31893         * m4/check-decl.m4: Add getenv to the list.
31894
31895 2000-02-27  Jim Meyering  <meyering@lucent.com>
31896
31897         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
31898         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
31899
31900         * lib/backupfile.c: Guard inclusion of stdlib.h with
31901         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
31902         Declare malloc if needed.
31903
31904         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
31905         `#ifndef HAVE_DECL..'
31906         now that autoconf always defines the HAVE_DECL_ symbols.
31907         * lib/human.c: Likewise.
31908         * lib/same.c: Likewise.
31909         * lib/strtoumax.c: Likewise.
31910
31911         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
31912         declaration check was not run.
31913         * lib/hash.c: Likewise.
31914         * lib/human.c: Likewise.
31915         * lib/same.c: Likewise.
31916         * lib/strtoumax.c: Likewise.
31917
31918         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
31919         `.', then first look up the entire `.'-containing string as a login
31920         name.
31921
31922 2000-02-23  Jim Meyering  <meyering@lucent.com>
31923
31924         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
31925         in place of my hack.
31926
31927 2000-02-18  Paul Eggert  <eggert@twinsun.com>
31928
31929         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
31930         (textint): New typedef.
31931         (parser_control): Member year changed from int to textint.
31932         All uses changed.
31933         (YYSTYPE): Removed; replaced by %union with int and textint members.
31934         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
31935         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
31936         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
31937         (tSNUMBER, tUNUMBER): Now of type <textintval>.
31938         (date, number, to_year): Use width of number in digits, not its value,
31939         to determine whether it's a 2-digit year, or a 2-digit time.
31940         (yylex): Store number of digits of numeric tokens.
31941         Reported by John Kendall.
31942
31943         (parser_control): Changed from struct parser_control to typedef (for
31944         consistency).  All uses changed.
31945
31946         (tID): Removed; not used.
31947         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
31948
31949 2000-02-14  Paul Eggert  <eggert@twinsun.com>
31950
31951         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
31952         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
31953
31954 2000-02-12  Jim Meyering  <meyering@lucent.com>
31955
31956         * lib/userspec.c (ISDIGIT): Define it.
31957         (isdigit): Remove definition.
31958         (is_number): Use ISDIGIT, not isdigit.
31959         <libintl.h>: Include.
31960         (_ and N_): Define.
31961         (parse_user_spec): Mark translatable strings.
31962
31963 2000-02-10  Jim Meyering  <meyering@lucent.com>
31964
31965         With these changes, nanosleep.[ch] are finally enough like the other
31966         lib/* replacement files to compile on a few more losing systems.
31967
31968         * lib/nanosleep.h: Don't include config.h.
31969         Remove prototype from declaration of nanosleep.
31970         (PARAMS): Remove now-unneeded definition.
31971         * lib/nanosleep.c: #undef nanosleep.
31972         (rpl_nanosleep): Rename from nanosleep.
31973
31974 2000-02-10  Jim Meyering  <meyering@lucent.com>
31975
31976         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
31977         gnu_nanosleep to rpl_nanosleep.
31978
31979 2000-02-09  Jim Meyering  <meyering@lucent.com>
31980
31981         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
31982         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
31983
31984 2000-02-08  Akim Demaille  <akim@epita.fr>
31985
31986         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
31987         `[' and `]' and remove uses of `changequote'.
31988         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
31989         (AC_SYS_LARGEFILE): Likewise.
31990         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
31991         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
31992         of changequote.
31993         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
31994         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
31995         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
31996         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
31997
31998 2000-02-05  Jim Meyering  <meyering@lucent.com>
31999
32000         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
32001         Remove explicit use of AC_HEADER_TIME.  It is required by
32002         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
32003         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
32004         in autoconf whereby the expansion of the latter ended up preceding
32005         the expansion of its prerequisite, AC_HEADER_TIME.
32006         Reported by Volker Borchert.
32007
32008 2000-02-03  Jim Meyering  <meyering@lucent.com>
32009
32010         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
32011
32012 2000-02-03  Jim Meyering  <meyering@lucent.com>
32013
32014         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
32015         rather than with `#if HAVE_UTMPNAME'.
32016
32017 2000-02-02  Jim Meyering  <meyering@lucent.com>
32018
32019         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
32020         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
32021         Reported by Eli Zaretskii.
32022
32023 2000-02-01  Jim Meyering  <meyering@lucent.com>
32024
32025         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
32026
32027 2000-01-31  Jim Meyering  <meyering@lucent.com>
32028
32029         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
32030         functions.  Add the time.h and sys/time.h headers along with the
32031         AC_REQUIRE'ment of AC_HEADER_TIME.
32032
32033 2000-01-31  Jim Meyering  <meyering@lucent.com>
32034
32035         * lib/nanosleep.h (nanosleep): Guard declaration with
32036         `#if ! HAVE_DECL_NANOSLEEP'.
32037         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
32038         the declaration in that vendor's sys/timers.h.
32039         Reported by Christian Krackowizer.
32040
32041         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
32042         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
32043         (ISPRINT): Likewise.
32044         Reported by Tom Tromey.
32045
32046 2000-01-30  Jim Meyering  <meyering@lucent.com>
32047
32048         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
32049
32050         * m4/prereq.m4 (utmp_includes): Define.
32051         Check for ut_user and ut_name members in both struct utmpx
32052         and struct utmp.
32053
32054 2000-01-30  Jim Meyering  <meyering@lucent.com>
32055
32056         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
32057         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
32058         header files where only utmpx.ut_user is declared.
32059
32060         * lib/readutmp.h (UT_USER): Define.
32061
32062 2000-01-29  Jim Meyering  <meyering@lucent.com>
32063
32064         * m4/lib-check.m4: New file containing library-related checks from
32065         fileutils and sh-utils (textutils had none).
32066
32067 2000-01-28  Jim Meyering  <meyering@lucent.com>
32068
32069         * m4/perl.m4: Change format of warning message to look more like that
32070         from the missing script.  Suggestion from François Pinard.
32071
32072 2000-01-25  Jim Meyering  <meyering@lucent.com>
32073
32074         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
32075         well as time.h in the compile check.
32076         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
32077         Fix typo in cross-compiling case: s/yes/no/.
32078
32079 2000-01-23  Jim Meyering  <meyering@lucent.com>
32080
32081         * m4/jm-macros.m4: Move df-related tests here from
32082         fileutils/configure.in
32083
32084         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
32085         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
32086
32087         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
32088         s/space/ac_fsusage_space/.
32089         (jm_FILE_SYSTEM_USAGE): Take two parameters.
32090
32091         * m4/ftruncate.m4: New file (derived from part of
32092         fileutils/configure.in).
32093         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
32094         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
32095
32096         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
32097         AC_SUBST these here, rather than just in sh-util/configure.in, so
32098         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
32099         all the same.
32100         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
32101         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
32102         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
32103         (AC_SUBST(POW_LIBM)): Likewise.
32104         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
32105
32106 2000-01-23  Jim Meyering  <meyering@lucent.com>
32107
32108         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
32109         obstack.c.
32110
32111 2000-01-22  Jim Meyering  <meyering@lucent.com>
32112
32113         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
32114
32115         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
32116
32117         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
32118         configure.in
32119         (AC_CHECK_HEADERS): Likewise for sh-utils.
32120         (AC_CHECK_HEADERS): Likewise for textutils.
32121         Merge the three lists of headers.
32122
32123         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
32124         from fileutils' configure.in.
32125
32126         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
32127         code. Moved tests into their own function (_jm_DECL_HEADERS) in
32128         check-decl.m4.
32129
32130         * m4/check-decl.m4: Use #if rather than #ifdef.
32131         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
32132         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
32133         (_jm_DECL_HEADERS): Define new function.
32134         (jm_CHECK_DECLARATIONS): Require it.
32135
32136 2000-01-22  Jim Meyering  <meyering@lucent.com>
32137
32138         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
32139         [! HAVE_DECL_STRTOULL]: Declare strtoull.
32140         Required for some AIX systems.  Reported by Christian Krackowizer.
32141         [TESTING] (main): New function.
32142
32143         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
32144         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
32145         letters.
32146
32147         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
32148         iswprint.
32149
32150         * lib/strverscmp.c (ISDIGIT): Define.
32151         (strverscmp): Use ISDIGIT, not isdigit.
32152
32153 2000-01-19  Jim Meyering  <meyering@lucent.com>
32154
32155         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
32156         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
32157         defines `struct timespec' in <sys/time.h>
32158
32159         * m4/c-bs-a.m4: Remove uses of changequote altogether.
32160         Thanks to Akim for explaining.
32161
32162 2000-01-17  Paul Eggert  <eggert@twinsun.com>
32163
32164         * lib/nanosleep.c (nanosleep):
32165         Don't use SA_INTERRUPT to decide whether to call sigaction, as
32166         POSIX.1 doesn't require SA_INTERRUPT and some systems
32167         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
32168         it's been part of POSIX.1 since day 1 (in 1988).
32169
32170 2000-01-17  Jim Meyering  <meyering@lucent.com>
32171
32172         * lib/interlock: Remove unused file.  Reported by François Pinard.
32173
32174 2000-01-16  Paul Eggert  <eggert@twinsun.com>
32175
32176         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
32177         alert, backslash, formfeed, and vertical tab unnecessarily in
32178         shell quoting style.
32179
32180 2000-01-16  Jim Meyering  <meyering@lucent.com>
32181
32182         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
32183         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
32184         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
32185         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
32186
32187 2000-01-16  Jim Meyering  <meyering@lucent.com>
32188
32189         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
32190         because the latter didn't work.
32191
32192 2000-01-15  Jim Meyering  <meyering@lucent.com>
32193
32194         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
32195         (AC_REPLACE_FUNCS): Add memcpy and memset.
32196         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
32197         Add strpbrk.
32198         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
32199
32200 2000-01-12  Jim Meyering  <meyering@lucent.com>
32201
32202         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
32203         (jm_PREREQ): Use it.
32204         (jm_PREREQ_READUTMP): New macro.
32205         (jm_PREREQ): Use it.
32206
32207 2000-01-11  Paul Eggert  <eggert@twinsun.com>
32208
32209         Quote multibyte characters correctly.
32210         * m4/c-bs-a.m4: New file.
32211         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
32212         (jm_PREREQ): Use it.
32213
32214 2000-01-11  Paul Eggert  <eggert@twinsun.com>
32215
32216         * m4/uintmax_t.m4: Port to autoconf 2.13.
32217
32218 2000-01-08  Jim Meyering  <meyering@ascend.com>
32219
32220         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
32221         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
32222
32223 2000-01-04  Jim Meyering  <meyering@ascend.com>
32224
32225         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
32226         jm_STRUCT_DIRENT_D_TYPE.
32227         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
32228         jm_STRUCT_DIRENT_D_INO.
32229         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
32230         jm_STRUCT_UTIMBUF.
32231         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
32232         renamings.
32233         * m4/utime.m4: Likewise.
32234
32235         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
32236         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
32237
32238 2000-01-03  Paul Eggert  <eggert@twinsun.com>
32239
32240         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
32241         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
32242
32243 2000-01-02  Jim Meyering  <meyering@ascend.com>
32244
32245         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
32246         remember if this is necessary.
32247
32248 1999-12-26  Jim Meyering  <meyering@ascend.com>
32249
32250         * m4/jm-macros.m4: Use it here.
32251         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
32252
32253 1999-12-23  Jim Meyering  <meyering@ascend.com>
32254
32255         * m4/jm-macros.m4: Check for clock_gettime (moved from
32256         fileutils/configure.in)
32257         Check for gettimeofday.
32258
32259 1999-12-20  Jim Meyering  <meyering@ascend.com>
32260
32261         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
32262         autoconf-2.14a-1999-12-20.
32263
32264 1999-12-19  Jim Meyering  <meyering@ascend.com>
32265
32266         * m4/lstat-slash.m4: New file.
32267         * m4/jm-macros.m4: Use the new macro:
32268         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
32269
32270 1999-12-07  Jim Meyering  <meyering@ascend.com>
32271
32272         * m4/perl.m4: Require that File::Compare be available, too.
32273         Too many systems seem to lack it.
32274
32275         * m4/strftime.m4: Add checks for most of the cpp macros tested in
32276         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
32277
32278 1999-11-18  Paul Eggert  <eggert@twinsun.com>
32279
32280         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
32281         problem with the QNX 4.25 shell, which doesn't propagate exit
32282         status of failed commands inside shell assignments.
32283
32284 1999-11-17  Jim Meyering  <meyering@ascend.com>
32285
32286         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
32287
32288 1999-11-07  Jim Meyering  <meyering@ascend.com>
32289
32290         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
32291
32292 1999-11-06  Jim Meyering  <meyering@ascend.com>
32293
32294         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
32295         * m4/jm-macros.m4 (jm_MACROS): Use it here.
32296
32297 1999-11-05  Jim Meyering  <meyering@ascend.com>
32298
32299         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
32300         configure.in of textutils, fileutils, and sh-utils into this one
32301         (shared between those packages) file.
32302         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
32303         AC_STRUCT_ST_BLKSIZE.
32304
32305 1999-11-03  Jim Meyering  <meyering@ascend.com>
32306
32307         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
32308         of AC_CHECK_TYPE checks includes unistd.h.
32309         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
32310         Suggestion from Akim Demaille.
32311
32312 1999-10-30  Jim Meyering  <meyering@ascend.com>
32313
32314         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
32315         m4-quoted string.
32316         * m4/ls-mntd-fs.m4: Likewise.
32317         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
32318         * m4/jm-winsz1.m4: Likewise.
32319
32320         * m4/const.m4: Remove file, since the fix made it into the experimental
32321         version of autoconf.
32322         * m4/mktime.m4: Likewise.
32323
32324         * m4/check-type.m4: Remove file, now that the latest version of
32325         AC_CHECK_TYPE takes a third arg to specify additional #includes.
32326
32327         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
32328         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
32329         AC_CHECK_TYPE.
32330
32331 1999-10-04  Jim Meyering  <meyering@ascend.com>
32332
32333         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
32334
32335 1999-09-22  Paul Eggert  <eggert@twinsun.com>
32336
32337         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
32338         2.95.1 bug with HP-UX 10.20.
32339
32340 1999-09-17  Jim Meyering  <meyering@ascend.com>
32341
32342         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
32343         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
32344         due to missing strdup (against sh-utils-2.0).
32345
32346 1999-08-29  Jim Meyering  <meyering@ascend.com>
32347
32348         * m4/jm-macros.m4: Require jm_BISON.
32349         * m4/bison.m4: New file.
32350
32351 1999-08-17  Paul Eggert  <eggert@twinsun.com>
32352
32353         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
32354         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
32355
32356 1999-08-05  Jim Meyering  <meyering@ascend.com>
32357
32358         * m4/getline.m4: Rename test file from conftestdata to conftest.data
32359         to avoid conflicts with `conftest' on 8+3 filesystems.
32360         Suggestion from Eli Zaretskii.
32361
32362 1999-08-04  Jim Meyering  <meyering@ascend.com>
32363
32364         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
32365         fileutils and sh-utils (textutils's getline test was inadequate).
32366         (AM_FUNC_GETLINE): Run this test.
32367         (AC_CHECK_FUNCS): Check for getdelim.
32368         Reported by Bob Proulx.
32369
32370 1999-08-02  Jim Meyering  <meyering@ascend.com>
32371
32372         * m4/jm-macros.m4: Add a comment.
32373
32374 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32375
32376         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
32377         <inttypes.h> defines strtoumax as a macro (and not as a
32378         function).
32379
32380 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32381
32382         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
32383         that we can shift, multiply and divide unsigned long long
32384         values; Ultrix cc can't do it.
32385
32386 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32387
32388         * m4/mktime.m4: New file, which is a preview of what should appear
32389         in the next public autoconf release.
32390
32391 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32392
32393         * m4/lfs.m4: Remove this file.
32394         * m4/largefile.m4: New file.  It contains the old contents of
32395         lfs.m4, except that all names with prefix AC_LFS have been
32396         changed to use the prefix AC_SYS_LARGEFILE instead, to be
32397         compatible with future autoconf versions.  Also, some minor m4
32398         quoting problems have been fixed.
32399
32400 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32401
32402         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
32403         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
32404         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
32405         and simplify the shell code.
32406
32407 1999-08-01  Jim Meyering  <meyering@ascend.com>
32408
32409         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
32410         m4.
32411
32412 1999-07-20  Jim Meyering  <meyering@ascend.com>
32413
32414         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
32415
32416 1999-07-15  Jim Meyering  <meyering@ascend.com>
32417
32418         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
32419
32420 1999-05-22  Jim Meyering  <meyering@ascend.com>
32421
32422         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
32423
32424 1999-05-20  Jim Meyering  <meyering@ascend.com>
32425
32426         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
32427         Add a colon after each `then' in case $4 is empty.
32428
32429 1999-05-16  Jim Meyering  <meyering@ascend.com>
32430
32431         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
32432
32433 1999-05-10  Jim Meyering  <meyering@ascend.com>
32434
32435         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
32436
32437         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
32438         AC_FUNC_MKTIME.
32439
32440 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
32441
32442         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
32443
32444 1999-05-04  Paul Eggert  <eggert@twinsun.com>
32445
32446         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
32447         not CPPFLAGS, so that linking works correctly in IRIX.
32448
32449 1999-04-30  Paul Eggert  <eggert@twinsun.com>
32450
32451         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
32452
32453 1999-04-20  Paul Eggert  <eggert@twinsun.com>
32454
32455         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
32456         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
32457         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
32458         jm_AC_TYPE_UNSIGNED_LONG_LONG.
32459         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
32460
32461         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
32462
32463 1999-04-20  Jim Meyering  <meyering@ascend.com>
32464
32465         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
32466         AC_REPLACE xstroull if necessary.  From Paul Eggert.
32467         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
32468
32469 1999-04-18  Jim Meyering  <meyering@ascend.com>
32470
32471         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
32472         * m4/jm-macros.m4: Use it.
32473
32474 1999-04-06  Jim Meyering  <meyering@ascend.com>
32475
32476         * m4/strftime.m4: Remove test for %f.
32477
32478 1999-03-29  Jim Meyering  <meyering@ascend.com>
32479
32480         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
32481         superset of the AC_TYPE_* checks in the textutils, fileutils,
32482         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
32483         AC_TYPE_PID_T.
32484
32485 1999-03-28  Jim Meyering  <meyering@ascend.com>
32486
32487         * m4/jm-macros.m4: Define GNU_PACKAGE here.
32488         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
32489         replaced e.g., in the *.sh files of the sh-utils.
32490
32491 1999-03-20  Jim Meyering  <meyering@ascend.com>
32492
32493         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
32494         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
32495         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
32496
32497 1999-03-19  Jim Meyering  <meyering@ascend.com>
32498
32499         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
32500
32501 1999-03-12  Jim Meyering  <meyering@ascend.com>
32502
32503         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
32504
32505 1999-03-07  Jim Meyering  <meyering@ascend.com>
32506
32507         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
32508         declared.
32509
32510 1999-02-17  Jim Meyering  <meyering@ascend.com>
32511
32512         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
32513         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
32514
32515 1999-02-07  Jim Meyering  <meyering@ascend.com>
32516
32517         * m4/group-member.m4: New file -- extracted from sh-utils'
32518         configure.in.
32519
32520         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
32521         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
32522
32523 1999-02-06  Jim Meyering  <meyering@ascend.com>
32524
32525         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
32526         * m4/fnmatch.m4: Likewise.
32527         * m4/getgroups.m4: Likewise.
32528         * m4/lstat.m4: Likewise.
32529         * m4/malloc.m4: Likewise.
32530         * m4/putenv.m4: Likewise.
32531         * m4/realloc.m4: Likewise.
32532         * m4/regex.m4: Likewise.
32533         * m4/stat.m4: Likewise.
32534         * m4/strftime.m4: Likewise.
32535         Suggestion from Alain Magloire.
32536
32537         * m4/chown.m4: Use `.$ac_objext', not `.o'.
32538         * m4/fnmatch.m4: Likewise.
32539         * m4/getgroups.m4: Likewise.
32540         * m4/getline.m4: Likewise.
32541         * m4/lstat.m4: Likewise.
32542         * m4/malloc.m4: Likewise.
32543         * m4/memcmp.m4: Likewise.
32544         * m4/putenv.m4: Likewise.
32545         * m4/realloc.m4: Likewise.
32546         * m4/regex.m4: Likewise.
32547         * m4/stat.m4: Likewise.
32548         * m4/strftime.m4: Likewise.
32549         Suggestion from Alain Magloire.
32550
32551         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
32552         an argument.
32553
32554         * m4/regex.m4: Add a run-time Test for proper operation of
32555         re_compile_pattern.
32556
32557 1999-01-31  Jim Meyering  <meyering@ascend.com>
32558
32559         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
32560
32561 1999-01-30  Jim Meyering  <meyering@ascend.com>
32562
32563         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
32564
32565         * m4/jm-mktime.m4: Make this a wrapper around the official
32566         AM_FUNC_MKTIME rather than my private copy, now that the official one
32567         is up to date.
32568         * m4/mktime.m4: Remove file.
32569
32570         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
32571         * m4/uptime.m4: Likewise.
32572         * m4/uintmax_t.m4: Likewise.
32573
32574 1999-01-28  Jim Meyering  <meyering@ascend.com>
32575
32576         * m4/jm-macros.m4: Use jm_AFS.
32577         * m4/afs.m4: New file (from fileutils' configure.in).
32578
32579         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
32580         * m4/chown.m4: Likewise.
32581         * m4/d-ino.m4: Likewise.
32582         * m4/d-type.m4: Likewise.
32583         * m4/fnmatch.m4: Likewise.
32584         * m4/getgroups.m4: Likewise.
32585         * m4/gettext.m4: Likewise.
32586         * m4/jm-mktime.m4: Likewise.
32587         * m4/jm-winsz2.m4: Likewise.
32588         * m4/lcmessage.m4: Likewise.
32589         * m4/ls-mntd-fs.m4: Likewise.
32590         * m4/malloc.m4: Likewise.
32591         * m4/memcmp.m4: Likewise.
32592         * m4/putenv.m4: Likewise.
32593         * m4/realloc.m4: Likewise.
32594         * m4/st_mtim.m4: Likewise.
32595         * m4/strftime.m4: Likewise.
32596
32597 1999-01-16  Jim Meyering  <meyering@ascend.com>
32598
32599         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
32600         (ARGMATCH_DIE_DECL): Define.
32601
32602 1999-01-12  Jim Meyering  <meyering@ascend.com>
32603
32604         * m4/Makefile.am.in: Rewrite to avoid using fmt.
32605         Reported by Lars Hecking.
32606
32607 1999-01-10  Jim Meyering  <meyering@ascend.com>
32608
32609         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
32610         gross kludge.
32611         * m4/inttypes_h.m4: Likewise.
32612         * m4/lstat.m4: Likewise.
32613         * m4/malloc.m4: Likewise.
32614         * m4/readdir.m4: Likewise.
32615         * m4/realloc.m4: Likewise.
32616         * m4/st_dm_mode.m4: Likewise.
32617         * m4/stat.m4: Likewise.
32618         * m4/utimbuf.m4: Likewise.
32619         * m4/utimes.m4: Likewise.
32620
32621         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
32622         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
32623         comments in config.h.in are meaningful.
32624
32625         * m4/jm-macros.m4: Require autoconf-2.13 here.
32626
32627         * m4/regex.m4: By default, don't use the included regex.c on systems
32628         with glibc 2.  Suggestion from Uli Drepper.
32629
32630 1999-01-02  Jim Meyering  <meyering@ascend.com>
32631
32632         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
32633
32634 1998-12-18  Jim Meyering  <meyering@ascend.com>
32635
32636         * m4/Makefile.am.in (Makefile.am): Simplify rule.
32637         Based on a suggestion from Lars Hecking.
32638
32639 1998-11-16  Paul Eggert  <eggert@twinsun.com>
32640
32641         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
32642
32643 1998-11-16  Jim Meyering  <meyering@ascend.com>
32644
32645         * m4/lfs.m4: Double-quote the `uname...` expression.
32646
32647 1998-11-14  Jim Meyering  <meyering@ascend.com>
32648
32649         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
32650         * m4/stat.m4: Likewise.
32651
32652 1998-11-03  Jim Meyering  <meyering@ascend.com>
32653
32654         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
32655         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
32656
32657 1998-10-18  Jim Meyering  <meyering@ascend.com>
32658
32659         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
32660
32661 1998-10-17  Jim Meyering  <meyering@ascend.com>
32662
32663         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
32664         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
32665         calls for those previously hard-coded headers.  Instead, take a new
32666         parameter.
32667         (jm_CHECK_DECLARATIONS): Reflect interface change.
32668         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
32669         (jm_CHECK_DECL_LOCALTIME_R): New macro.
32670
32671         * m4/mktime.m4: Test for spring-forward gap before long-running test.
32672
32673 1998-10-14  Jim Meyering  <meyering@ascend.com>
32674
32675         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
32676         instead of "TZ=America/Vancouver".  From Paul Eggert.
32677
32678 1998-10-11  Jim Meyering  <meyering@ascend.com>
32679
32680         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
32681         This adds a test for a recently added compatibility fix for mktime.c.
32682         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
32683
32684 1998-09-27  Jim Meyering  <meyering@ascend.com>
32685
32686         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
32687
32688         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
32689         ../configure.in, including a change from Gordon Matzigkeit to allow
32690         cross-compiling for the Hurd.
32691
32692         * m4/glibc.m4: New file/macro to test for the GNU C Library
32693         versions 1 and 2.  From Gordon Matzigkeit.
32694         Indent.
32695
32696 1998-09-21  Jim Meyering  <meyering@ascend.com>
32697
32698         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
32699
32700 1998-08-18  Paul Eggert  <eggert@twinsun.com>
32701
32702         Port nanosecond-resolution times to UnixWare 2.1.2 and
32703         pedantic Solaris 2.6.
32704
32705         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
32706         AC_STRUCT_ST_MTIM.
32707         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
32708         Generate name of ns member, instead of just 1 or undef.
32709         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
32710
32711 1998-08-15  Jim Meyering  <meyering@ascend.com>
32712
32713         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
32714         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
32715         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
32716         instead of jm_TYPE_SSIZE_T.
32717
32718 1998-08-12  Jim Meyering  <meyering@ascend.com>
32719
32720         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
32721
32722 1998-08-02  Jim Meyering  <meyering@ascend.com>
32723
32724         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
32725         in acconfig.h manually.
32726
32727 1998-07-31  Paul Eggert  <eggert@twinsun.com>
32728
32729         * m4/st_mtim.m4: New file.
32730
32731 1998-07-28  Jim Meyering  <meyering@ascend.com>
32732
32733         * m4/utimes.m4: Undef stat.
32734
32735 1998-07-25  Jim Meyering  <meyering@ascend.com>
32736
32737         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
32738         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
32739
32740 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
32741
32742         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
32743         uid and gid actually remain unchanged.
32744
32745 1998-07-07  Jim Meyering  <meyering@ascend.com>
32746
32747         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
32748
32749 1998-07-04  Jim Meyering  <meyering@ascend.com>
32750
32751         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
32752         to prove that this macro can be used in packages without regex.c.
32753
32754 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
32755
32756         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
32757         is to be used.
32758
32759 1998-07-03  Jim Meyering  <meyering@ascend.com>
32760
32761         * m4/gettext.m4: Add -lintl if it's found to be necessary.
32762
32763         * m4/gettext.m4: New file -- from gettext-0.10.35.
32764         * m4/lcmessage.m4: Likewise.
32765         * m4/progtest.m4: Likewise.
32766
32767         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
32768         * m4/jm-macros.m4: Require the new macro.
32769
32770 1998-06-29  Jim Meyering  <meyering@ascend.com>
32771
32772         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
32773         for the definition of NGROUPS (used in a system header included
32774         by sys/mount.h).
32775
32776 1998-06-28  Jim Meyering  <meyering@ascend.com>
32777
32778         * m4/ls-mntd-fs.m4: New file.
32779         * m4/fstypename.m4: New file.
32780
32781         * m4/jm-macros.m4: Require the new macro.
32782         * m4/jm-glibc-io.m4: New file.
32783
32784 1998-05-19  Jim Meyering  <meyering@ascend.com>
32785
32786         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
32787         * m4/lchown.m4: New file.
32788
32789         * m4/Makefile.am.in: New file.
32790         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
32791
32792 1998-05-14  Jim Meyering  <meyering@ascend.com>
32793
32794         * m4/Makefile.am (EXTRA_DIST): Add them.
32795         * m4/jm-macros.m4: New file.
32796         * m4/utimbuf.m4: New file.
32797
32798 1998-05-12  Jim Meyering  <meyering@ascend.com>
32799
32800         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
32801
32802 1998-05-11  Jim Meyering  <meyering@ascend.com>
32803
32804         * m4/isc-posix.m4: New file.
32805
32806 1998-05-10  Jim Meyering  <meyering@ascend.com>