Set errno to ENOMEM when malloc/realloc fails. Needed on mingw.
[pspp] / ChangeLog
1 2007-09-09  Bruno Haible  <bruno@clisp.org>
2
3         * lib/canonicalize-lgpl.c (__realpath): Set errno to ENOMEM when
4         malloc or realloc fails.
5
6 2007-09-09  Bruno Haible  <bruno@clisp.org>
7
8         * modules/getcwd (Depends-on): Add malloc-posix.
9         * modules/glob (Depends-on): Likewise.
10         * modules/putenv (Depends-on): Likewise.
11         * modules/strdup (Depends-on): Likewise.
12         * modules/getdelim (Depends-on): Add realloc-posix.
13         * modules/read-file (Depends-on): Likewise.
14
15 2007-09-09  Bruno Haible  <bruno@clisp.org>
16
17         * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): New macro.
18         (gl_FUNC_MALLOC_POSIX): Require it.
19         * m4/realloc.m4 (gl_FUNC_REALLOC_POSIX): Likewise.
20         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): Likewise.
21         * modules/realloc (Files): Add m4/malloc.m4.
22         * modules/calloc (Files): Likewise.
23
24 2007-09-09  Bruno Haible  <bruno@clisp.org>
25
26         * modules/malloc-posix: New file.
27         * modules/malloc (Depends-on): Add malloc-posix.
28         * lib/malloc.c: Include errno.h.
29         (rpl_malloc): Merge the requirements of a glibc-compatible malloc
30         and a POSIX-compatible malloc into a single function. Set ENOMEM
31         when returning NULL.
32         * m4/malloc.m4: New file.
33         * doc/functions/malloc.texi: Mention the malloc-posix module.
34         * lib/stdlib_.h (malloc): New declaration.
35         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
36         GNULIB_MALLOC_POSIX and HAVE_MALLOC_POSIX.
37         * modules/stdlib (stdlib.h): Substitute also GNULIB_MALLOC_POSIX
38         and HAVE_MALLOC_POSIX.
39
40 2007-09-09  Bruno Haible  <bruno@clisp.org>
41
42         * modules/realloc-posix: New file.
43         * modules/realloc (Depends-on): Add realloc-posix.
44         * lib/realloc.c: Include errno.h.
45         (rpl_realloc): Merge the requirements of a glibc-compatible realloc
46         and a POSIX-compatible realloc into a single function. Set ENOMEM
47         when returning NULL.
48         * m4/realloc.m4: New file.
49         * doc/functions/realloc.texi: Mention the realloc-posix module.
50         * lib/stdlib_.h (realloc): New declaration.
51         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
52         GNULIB_REALLOC_POSIX and HAVE_REALLOC_POSIX.
53         * modules/stdlib (stdlib.h): Substitute also GNULIB_REALLOC_POSIX
54         and HAVE_REALLOC_POSIX.
55
56 2007-09-09  Bruno Haible  <bruno@clisp.org>
57
58         * modules/calloc-posix: New file.
59         * modules/calloc (Depends-on): Add calloc-posix.
60         * lib/calloc.c: Include errno.h.
61         (rpl_calloc): Merge the requirements of a glibc-compatible calloc
62         and a POSIX-compatible calloc into a single function. Set ENOMEM
63         when returning NULL.
64         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): New macro.
65         * doc/functions/calloc.texi: Mention the calloc-posix module.
66         * lib/stdlib_.h (calloc): New declaration.
67         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
68         GNULIB_CALLOC_POSIX and HAVE_CALLOC_POSIX.
69         * modules/stdlib (stdlib.h): Substitute also GNULIB_CALLOC_POSIX
70         and HAVE_CALLOC_POSIX.
71
72 2007-09-09  Bruno Haible  <bruno@clisp.org>
73
74         Allow for modules to show an arbitrary notice.
75         * modules/TEMPLATE-EXTENDED: Add 'Notice' field.
76         * gnulib-tool: New option --extract-notice.
77         (func_usage): Document it.
78         (sed_extract_prog): Update.
79         (func_get_notice): New function.
80         (func_modules_notice): New function.
81         (func_import, func_create_testdir): Invoke it.
82         Suggested by Jim Meyering.
83
84 2007-09-09  Bruno Haible  <bruno@clisp.org>
85
86         * gnulib-tool: New options --verbose, --quiet.
87         (func_usage): Document them.
88         (verbose): New variable.
89         (func_execute_command): New function.
90         (func_import): Don't show the module list and the file list if
91         $verbose < 0.
92         (func_create_testdir): Likewise. Use func_execute_command.
93         (func_create_megatestdir): Use func_execute_command.
94
95 2007-09-08  Bruno Haible  <bruno@clisp.org>
96
97         * gnulib-tool (func_import): Prefer rsync over wget when available,
98         for fetching the PO files.
99
100 2007-09-08  Bruno Haible  <bruno@clisp.org>
101
102         * posix-modules: New file. Portions copied from gnulib-tool.
103         * doc/gnulib.texi (POSIX Substitutes Library): New chapter.
104
105 2007-09-08  Jim Meyering  <jim@meyering.net>
106
107         Rename __fpending.c -> fpending.c and __fpending.h -> fpending.h
108         * lib/fpending.h: Rename from __fpending.h.
109         * lib/fpending.c: Rename from __fpending.c.
110         Include "fpending.h", not "__fpending.h".
111         * lib/__fpending.h, lib/__fpending.c: Remove files.
112         * modules/fpending (Files): Reflect new file names.
113         * lib/close-stream.c: Include "fpending.h", not "__fpending.h".
114
115 2007-09-08  Bruno Haible  <bruno@clisp.org>
116
117         * m4/inttypes-h.m4: Remove stub file.
118
119 2007-09-07  Simon Josefsson  <simon@josefsson.org>
120
121         * doc/headers/stdint.texi: Discuss #include_next issue.
122
123 2007-09-06  Paul Eggert  <eggert@cs.ucla.edu>
124
125         * build-aux/bootstrap: Remove obsolete comment about wget --help.
126
127 2007-09-06  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
128
129         * m4/time_h.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Fix misspelling
130         in variable name.
131
132 2007-09-03  Jim Meyering  <jim@meyering.net>
133
134         New module: git-version-gen.
135         * modules/git-version-gen: New file.
136
137         Import changes from coreutils for bootstrap script.
138
139         * build-aux/bootstrap (WGET_COMMAND): Remove code to set this variable.
140
141         bootstrap: uses rsync to download the .po files
142         * build-aux/bootstrap (po_download_command_format): New global.
143         (download_po_files): Use rsync.
144         (update_po_files): Don't remove .po files after download,
145         so future rsync runs can take advantage of the copies.
146
147         * build-aux/bootstrap (gnulib_tool): Make sha1sum check quietly.
148
149         Solve the unnecessary-.po-file-regeneration problem once and for all.
150         * build-aux/bootstrap (download_po_files): New function, renamed from
151         get_translations.  Now, downloads, but doesn't update LINGUAS.
152         (update_po_files): New function.
153
154         bootstrap: Ignore more.
155         * build-aux/bootstrap (symlink_to_dir): Add a directory name like
156         uniwidth to e.g., lib/.gitignore.
157         (slurp): Handle the sys_stat_.h -> sys mapping, too.
158
159         * build-aux/bootstrap: New setting: vc_ignore.
160         (insert_sorted_if_absent): Create $file if absent.
161         Adapt to new, possibly empty, list: $vc_ignore.
162
163         bootstrap: generate more ignorable names
164         * build-aux/bootstrap (slurp): When generating ignorable names,
165         also map .sin to .sed, .gperf to .c, and .y to .c.
166
167 2007-09-03  Jim Meyering  <jim@meyering.net>
168
169         * build-aux/git-version-gen: New file, from coreutils.  For details, see
170         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commitdiff;h=bfe49f506
171
172 2007-09-02  Bruno Haible  <bruno@clisp.org>
173
174         Fix mis-recognition of 'mcs' on QNX 6.
175         * m4/csharpcomp.m4 (gt_CSHARPCOMP): Test whether the "mcs --version"
176         output contains the string "Mono".
177         * lib/csharpcomp.c (compile_csharp_using_mono): Likewise.
178         Reported by <kraai@ftbfs.org> at <https://savannah.gnu.org/bugs/?18337>.
179
180 2007-09-01  Bruno Haible  <bruno@clisp.org>
181
182         Fix collision between uniwidth/* and linebreak modules.
183         * lib/linebreak.h (locale_charset, uc_width, u8_width, u16_width,
184         u32_width): Remove declarations.
185         * lib/linebreak.c: Include uniwidth.h, uniwidth/cjk.h, streq.h.
186         (u32_mbtouc_unsafe, streq9, streq8, streq7, streq6, streq5, streq4,
187         streq3, streq2, streq1, streq0): Remove functions.
188         (STREQ): Remove macro.
189         (is_cjk_encoding): Remove function.
190         (nonspacing_table_data, nonspacing_table_ind): Remove constants.
191         (uc_width, u8_width, u16_width, u32_width): Remove functions.
192         * modules/linebreak (Depends-on): Add streq, uniwidth/width.
193         * NEWS: Document the change.
194
195 2007-09-01  Bruno Haible  <bruno@clisp.org>
196
197         * lib/streq.h: Add double-inclusion guard.
198
199 2007-09-01  Karl Berry  <karl@gnu.org>
200
201         * MODULES.html.sh: Rename mreadlink_with_size to areadlink_with_size.
202
203 2007-08-28  Jim Meyering  <jim@meyering.net>
204
205         Rename mreadlink_with_size to areadlink_with_size.
206         * NEWS: Document the change.
207         * lib/mreadlink-with-size.c (mreadlink_with_size): Rename this to...
208         * lib/areadlink-with-size.c (areadlink_with_size): ...this.
209         * lib/mreadlink.h: Rename this to...
210         * lib/areadlink.h: ...this.
211         * modules/mreadlink-with-size: Rename this to...
212         * modules/areadlink-with-size: ...this.
213         * lib/canonicalize.c: Reflect the renaming.
214         * modules/canonicalize: Likewise.
215
216 2007-08-26  Bruno Haible  <bruno@clisp.org>
217
218         * gnulib-tool (func_import): When deciding which files to remove,
219         consider also dangling symbolic links.
220         Reported by Eric Blake.
221
222 2007-08-26  Bruno Haible  <bruno@clisp.org>
223
224         * gnulib-tool (func_ln_if_changed): Use "test -h", not "test -L".
225
226 2007-08-23  Simon Josefsson  <simon@josefsson.org>
227
228         * lib/readline.c: Don't include getline.h, the prototype is now
229         found in stdio.h.
230
231 2007-08-23  Jim Meyering  <jim@meyering.net>
232
233         Getdelim touchup.
234         * lib/getdelim.c (getdelim): Don't bother to save/restore errno
235         around the funlockfile call, since funlockfile never sets errno.
236         Don't set errno upon failed realloc.
237
238 2007-08-22  Eric Blake  <ebb9@byu.net>
239
240         Getline touchups.
241         * lib/getdelim.c (getdelim): Revert regression that required *n to
242         be 0 when *lineptr is NULL.  Preserve errno across funlockfile.
243         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Check for declaration of
244         getdelim, rather than whether implementation is missing.
245         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise for getline.
246         * lib/stdio_.h (getline): Also declare if replacement is
247         required.
248         * doc/functions/getdelim.texi: New file.
249         * doc/functions/getline.texi: Likewise.
250         * doc/gnulib.texi (Function Substitutes): Add new files.
251         Reported by Bruno Haible.
252
253 2007-08-22  Ludovic Courtès  <ludo@gnu.org>
254
255         * users.txt: Add Guile.
256
257 2007-08-22  Eric Blake  <ebb9@byu.net>
258
259         * tests/test-getdelim.c (main): Use remove, not unlink.
260         * tests/test-getline.c (main): Likewise.
261
262         Move getline and getdelim into stdio.h, per POSIX 200x.
263         * modules/getline (Files): Remove getline.h.
264         (Depends-on): Add stdio.
265         (configure.ac): Add module indicator.
266         * modules/getdelim (Files): Remove getdelim.h.
267         (Depends-on): Add stdio.
268         (configure.ac): Add module indicator.
269         * modules/stdio (Makefile.am): Work with new indicators.
270         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add new defaults.
271         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Work with stdio needs.
272         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
273         * lib/getdelim.h: Delete.
274         * lib/getline.h: Delete.
275         * lib/stdio_.h (getdelim, getline): Declare.
276         * modules/getdelim-tests: New module.
277         * modules/getline-tests: Likewise.
278         * tests/test-getdelim.c: New file.
279         * tests/test-getline.c: Likewise.
280         * NEWS: Document the change.
281         * lib/getline.c: Update choice of header.
282         * lib/csharpcomp.c: Likewise.
283         * lib/getpass.c: Likewise.
284         * lib/javacomp.c: Likewise.
285         * lib/javaversion.c: Likewise.
286         * lib/yesno.c: Likewise.
287         * lib/getdelim.c: Likewise.
288         (getdelim): Set errno on failure, and avoid memory leak.
289
290 2007-08-19  Bruno Haible  <bruno@clisp.org>
291
292         * modules/closein (Depends-on): Add freadahead.
293         * lib/closein.c: Include freadahead.h.
294         (close_stdin): Skip the fseeko and fflush calls if freadahead(stdin)
295         is zero.
296
297 2007-08-19  Bruno Haible  <bruno@clisp.org>
298
299         * modules/freadahead-tests: New file.
300         * tests/test-freadahead.sh: New file.
301         * tests/test-freadahead.c: New file.
302
303         * modules/freadahead: New file.
304         * lib/freadahead.h: New file.
305         * lib/freadahead.c: New file.
306         * MODULES.html.sh (File stream based Input/Output): Add freadahead,
307         fbufmode, fpurge, freadable, fwritable.
308
309 2007-08-19  Eric Blake  <ebb9@byu.net>
310
311         Test yesno in combination with closein.
312         * lib/yesno.c (yesno): Document use of stdin.
313         * modules/yesno-tests (Files): New module.
314         * tests/test-yesno.c (main): New file.
315         * tests/test-yesno.sh: Likewise.
316
317 2007-08-19  Bruno Haible  <bruno@clisp.org>
318
319         * lib/fbufmode.c (fbufmode): Add tentative support for Solaris/AMD64.
320         * lib/fseeko.c (rpl_fseeko): Likewise.
321         * lib/fseterr.c (fseterr): Likewise.
322
323 2007-08-19  Bruno Haible  <bruno@clisp.org>
324
325         * tests/test-lseek.c (main): Disable a test for BeOS.
326         * doc/functions/lseek.texi: Document the BeOS bug.
327
328 2007-08-19  Bruno Haible  <bruno@clisp.org>
329             Eric Blake  <ebb9@byu.net>
330
331         * lib/lseek.c: Include <sys/stat.h>.
332         (rpl_lseek): Add workaround code also for Unix platforms.
333         Needed for BeOS.
334         * m4/lseek.m4 (gl_FUNC_LSEEK): When cross-compiling, fail on BeOS.
335         * doc/functions/lseek.texi: Document BeOS definiency.
336
337 2007-08-18  Bruno Haible  <bruno@clisp.org>
338
339         * modules/fstrcmp-tests: New file.
340         * tests/test-fstrcmp.c: New file.
341
342 2007-08-18  Bruno Haible  <bruno@clisp.org>
343
344         * modules/fstrcmp: New file, from GNU gettext with modifications.
345         * lib/fstrcmp.h: New file, from GNU gettext.
346         * lib/fstrcmp.c: New file, from GNU gettext.
347         * MODULES.html.sh (String handling): Add fstrcmp.
348
349 2007-08-18  Bruno Haible  <bruno@clisp.org>
350
351         * lib/diffseq.h (struct context): Change type of 'heuristic' field to
352         'bool'.
353         (diag, compareseq): Remove const from the ctxt argument.
354         (USE_HEURISTIC): Undefine at the end.
355
356 2007-08-18  Jim Meyering  <jim@meyering.net>
357
358         New file: lib/idcache.h
359         * NEWS: Mention the addition.
360         * modules/idcache (Files): Add lib/idcache.h
361         * lib/idcache.c: Include "idcache.h".
362         Don't include <sys/types.h>.
363         Add a FIXME comment.
364         Move file-scoped "static" declarations to the top.
365         * lib/idcache.h: New file.  Include <sys/types.h> here, instead.
366
367 2007-08-17  Bruno Haible  <bruno@clisp.org>
368         and Paul Eggert  <eggert@cs.ucla.edu>
369
370         * MODULES.html.sh: Add diffseq.
371         * modules/diffseq: New file.
372         * lib/diffseq.h: New file, from GNU gettext with a few minor changes,
373         extracted from GNU gettext's fstrcmp.c and GNU diff's analyze.c.
374
375 2007-08-15  Paul Eggert  <eggert@cs.ucla.edu>
376
377         Import changes from coreutils for bootstrap script.
378
379         2007-07-21  Paul Eggert  <eggert@cs.ucla.edu>
380
381         * build-aux/bootstrap (slurp): Work even in environments where
382         "ls" defaults to "ls -A".  Put in a FIXME, though, since the
383         current code does not slurp files whose names start with ".", and
384         this looks like it might be a troublesome area.
385
386         2007-07-11  Jim Meyering  <jim@meyering.net>
387
388         If there's a GPL vN copyright comment, require that N == 3.
389
390         2007-07-08  Jim Meyering  <jim@meyering.net>
391
392         Run the coreutils-specific code only if tests/Makefile.am.in exists.
393         * build-aux/bootstrap (mam_template): Move definition out of loop.
394
395         Create symlinks for gl/{lib,m4}/*, just as for gnulib/{lib,m4}/*.
396
397         * build-aux/bootstrap (symlink_to_dir): Rename function from
398         symlink_to_gnulib.  Add a directory parameter.  Update all
399         callers.
400         (cp_mark_as_generated): Also check for -- and link to -- files in
401         gl/.
402
403         2007-07-08  Jim Meyering  <jim@meyering.net>
404
405         Adapt to deeper hierarchy in gnulib.
406         * build-aux/bootstrap (symlink_to_dir): If the destination
407         directory doesn't exist, create it. This is required at least for
408         "lib/uniwidth/cjk.h".
409
410         2007-05-15  Jim Meyering  <jim@meyering.net>
411
412         * build-aux/bootstrap: Now that generated Makefile.am files
413         are no longer under version control, they must be created at
414         bootstrap time.
415
416 2007-08-14  Ben Pfaff  <blp@gnu.org>
417
418         * lib/count-one-bits.h: Add comments.  From Bruno Haible.
419
420 2007-08-14  Paul Eggert  <eggert@cs.ucla.edu>
421
422         * lib/count-one-bits.h: Don't include <limits.h>; no longer needed
423         given the changes below.
424         (COUNT_ONE_BITS): Use 'verify' rather than 'verify_true'.  Work
425         even on hosts that have padding bits beyond the supported 64.
426
427 2007-08-10  Paul Eggert  <eggert@cs.ucla.edu>
428
429         * NEWS: In xstrtol, remove STRTOL_FATAL_ERROR and add xstrtol_fatal.
430         * lib/xstrtol.h: Don't include exitfail.h; that's now internal to
431         xstrtol.c.  Include getopt.h, since xstrtol_fatal's signature
432         depends on it.
433         (xstrtol_error): Remove.
434         (xstrtol_fatal): New decl, replacing the functionality of xstrtol_error
435         but with a different signature.
436         (ATTRIBUTE_NORETURN, __attribute__): New macros.
437         * lib/xstrtol-error.c: Include exitfail.h.
438         (xstrtol_fatal): New function, with a different signature from the
439         old xstrtol_error, so that the caller need not worry about passing
440         in an exit status, or about storage management of the option argument.
441         (xstrtol_error): Now a static function.  Redo signature to
442         implement xstrtol_fatal.  Output the correct number of hyphens in
443         front of the option so that the caller need not worry about
444         storage management.
445         (N_): New macro.
446         (_): Remove; not used now.
447         * modules/xstrtol: Depend on getopt.
448         * tests/test-xstrtol.c (main): Use new xstrtol_error function instead
449         of old STRTOL_FATAL_ERROR macro.
450         * tests/test-xstrtol.sh (t-xstrtol.xo): Adjust to match new behavior
451         of test program.
452         * tests/test-xstrtoimax.sh (t-xstrtoimax.xo): Likewise.
453         * tests/test-xstrtoumax.sh (t-xstrtoumax.xo): Likewise.
454
455 2007-08-08  Eric Blake  <ebb9@byu.net>
456
457         * lib/xstrtol-error.c: Add missing include.
458
459         Move xstrtol messages into gnulib domain, when --pobase is used.
460         * lib/xstrtol.h (_STRTOL_ERROR): Move messages out of macro...
461         * lib/xstrtol-error.c (xstrtol_error): ...into new file.
462         * modules/xstrtol (Files): Distribute new file.
463         * m4/xstrtol.m4 (gl_XSTRTOL): Build new file.
464         * lib/xstrtol.c (TESTING_XSTRTO): Move tests...
465         * tests/test-xstrtol.c: ...into new file.
466         * tests/test-xstrtoul.c: Also test xstrtoul.
467         * tests/test-xstrtoimax.c: Also test xstrtoimax.
468         * tests/test-xstrtoumax.c: Also test xstrtoumax.
469         * tests/test-xstrtol.sh: Drive the tests.
470         * tests/test-xstrtoimax.sh: Likewise.
471         * tests/test-xstrtoumax.sh: Likewise.
472         * modules/xstrtol-tests: New module.
473         * modules/xstrtoimax-tests: Likewise.
474         * modules/xstrtoumax-tests: Likewise.
475
476 2007-08-08  Jim Meyering  <jim@meyering.net>
477
478         New function: mfile_name_concat.
479         * lib/filenamecat.c (mfile_name_concat): New function, just like
480         file_name_concat, but return NULL upon failure rather than exiting
481         with a diagnostic.
482         * lib/filenamecat.h: Declare it.
483
484 2007-08-07  Bruno Haible  <bruno@clisp.org>
485
486         * m4/inttypes.m4 (gl_INTTYPES_H): Use GL_TRIGGER_STDC_LIMIT_MACROS
487         instead of __STDC_LIMIT_MACROS_TRIGGER. This avoids a redefinition
488         warning from gcc.
489         Reported by Eric Blake.
490
491 2007-08-07  Simon Josefsson  <simon@josefsson.org>
492
493         * modules/crypto/arctwo (License): Use the synonymous term "LGPLv2+".
494         * modules/crypto/arcfour (License): Likewise.
495         * modules/crypto/des-tests (License): Likewise.
496         * modules/crypto/gc-arctwo-tests (License): Likewise.
497         * modules/crypto/gc-des-tests (License): Likewise.
498         * modules/crypto/gc-hmac-md5-tests (License): Likewise.
499         * modules/crypto/gc-hmac-sha1-tests (License): Likewise.
500         * modules/crypto/gc-md2-tests (License): Likewise.
501         * modules/crypto/gc-md4-tests (License): Likewise.
502         * modules/crypto/gc-md5-tests (License): Likewise.
503         * modules/crypto/gc-pbkdf2-sha1-tests (License): Likewise.
504         * modules/crypto/gc-rijndael-tests (License): Likewise.
505         * modules/crypto/gc-sha1-tests (License): Likewise.
506         * modules/crypto/gc-tests (License): Likewise.
507         * modules/crypto/hmac-md5 (License): Likewise.
508         * modules/crypto/hmac-sha1 (License): Likewise.
509         * modules/crypto/md2-tests (License): Likewise.
510         * modules/crypto/md4-tests (License): Likewise.
511         * modules/crypto/md5 (License): Likewise.
512         * modules/crypto/rijndael (License): Likewise.
513         * modules/crypto/sha1 (License): Likewise.
514         * modules/memxor (License): Likewise.
515
516 2007-08-06  Paul Eggert  <eggert@cs.ucla.edu>
517         and Bruno Haible  <bruno@clisp.org>
518
519         * NEWS: Describe interface changes to human, xstrtol.
520         * lib/human.h: Include <xstrtol.h>.
521         (human_options): Return enum strtol_error, not int.  Remove
522         bool arg; take int * instead.
523         * lib/human.c: Don't include "gettext.h".
524         (_): Remove; no longer used.
525         Don't include <xstrtol.h>, since human.h does it.
526         (human_options): Adjust to abovementioned interface changes.
527         Do not report error to stderr; that's now the caller's
528         responsibility.
529         * lib/xstrtol.c (main) [defined TESTING_XSTRTO]: Adjust to
530         interface change.
531         * lib/xstrtol.h (_STRTOL_ERROR): Take Option, Arg rather than
532         Str, Argument_type_string.  All uses changed.  Put " argument"
533         in diagnostics to make them clearer.  Change wording of suffix
534         message for clarity.
535         (STRTOL_FATAL_ERROR): Take Option, Arg rather than Str,
536         Argument_type_string.
537         (STRTOL_FATAL_WARN): Remove; no longer used.
538         * modules/human (Depends-on): Remove gettext-h.
539
540 2007-08-06  Simon Josefsson  <simon@josefsson.org>
541
542         * build-aux/maint.mk, build-aux/GNUmakefile: Relicense to GPLv3+.
543
544 2007-07-31  Bruno Haible  <bruno@clisp.org>
545
546         * m4/stdint.m4 (gl_STDINT_H): Test whether WCHAR_MIN and WCHAR_MAX
547         are defined by <stdint.h> (as opposed to <wchar.h>, as on Dragonfly).
548         Reported by Joerg Sonnenberger <joerg@britannica.bec.de>.
549
550 2007-07-31  Bruno Haible  <bruno@clisp.org>
551
552         * lib/fflush.c (rpl_fflush): On BSD systems, use the __SNPT flag.
553         Suggested by Joerg Sonnenberger <joerg@britannica.bec.de>.
554
555 2007-07-30  Bruno Haible  <bruno@clisp.org>
556
557         * modules/base64 (License): Use the synonymous term "LGPLv2+".
558         * modules/c-ctype (License): Likewise.
559         * modules/c-strcase (License): Likewise.
560         * modules/check-version (License): Likewise.
561         * modules/iconv (License): Likewise.
562         * modules/iconv_open (License): Likewise.
563         * modules/read-file (License): Likewise.
564         * modules/striconv (License): Likewise.
565         * modules/strverscmp (License): Likewise.
566         * modules/vasprintf (License): Likewise.
567         * modules/crypto/des (License): Likewise.
568         * modules/crypto/gc (License): Likewise.
569         * modules/crypto/gc-arcfour (License): Likewise.
570         * modules/crypto/gc-arctwo (License): Likewise.
571         * modules/crypto/gc-des (License): Likewise.
572         * modules/crypto/gc-hmac-md5 (License): Likewise.
573         * modules/crypto/gc-hmac-sha1 (License): Likewise.
574         * modules/crypto/gc-md2 (License): Likewise.
575         * modules/crypto/gc-md4 (License): Likewise.
576         * modules/crypto/gc-md5 (License): Likewise.
577         * modules/crypto/gc-pbkdf2-sha1 (License): Likewise.
578         * modules/crypto/gc-random (License): Likewise.
579         * modules/crypto/gc-rijndael (License): Likewise.
580         * modules/crypto/gc-sha1 (License): Likewise.
581         * modules/crypto/md2 (License): Likewise.
582         * modules/crypto/md4 (License): Likewise.
583
584 2007-07-30  Jim Meyering  <jim@meyering.net>
585
586         * lib/fts.c (fts_read): Upon failure to chdir into a subdirectory,
587         set fts_info to FTS_DNR, not to FTS_ERR, so that the caller knows
588         it has valid stat data.  This bug would cause du not to count the
589         sizes of inaccessible directories.
590         Patch by Bryan Mason <bmason@redhat.com>, via Jose Maria Plans
591         in <http://bugzilla.redhat.com/250077>.
592
593 2007-07-25  Peter O'Gorman  <peter@pogma.com>
594             Bruno Haible  <bruno@clisp.org>
595
596         * m4/include_next.m4 (gl_INCLUDE_NEXT): Test whether #include_next
597         really works. Needed because AIX 4.3 "xlc -E" doesn't understand
598         #include_next, gives a diagnostic about it, but reports no error in
599         the exit code.
600         Reported by Gary V. Vaughan <gary@thewrittenword.com>.
601
602 2007-07-24  Ben Pfaff  <blp@gnu.org>
603
604         Improve name: "count-one-bits" is better than "popcount".
605         * MODULES.html.sh: Update name.
606         * lib/popcount.h: Renamed lib/count-one-bits.h.
607         (popcount): Renamed count_one_bits.
608         (popcountl): Renamed count_one_bits_l.
609         (popcountll): Renamed count_one_bits_ll.
610         * m4/popcount.m4: Renamed m4/count-one-bits.m4.
611         * modules/popcount: Renamed module/count-one-bits.
612         * modules/popcount-tests: Renamed module/count-one-bits-tests.
613         * tests/test-popcount.c: Renamed tests/test-count-one-bits.c.
614
615 2007-07-23  Ben Pfaff  <blp@gnu.org>
616
617         * lib/popcount.h (popcount32): Reduce size of constants, to allow
618         better code generation, and add U to large constants to avoid
619         warnings, in non-GCC case.
620         Suggested by Bruno Haible.
621
622 2007-07-23  Ben Pfaff  <blp@gnu.org>
623
624         * lib/popcount.h: Use verify_true instead of if...abort.
625         * modules/popcount: Depend on verify module.
626         Suggested by Jim Meyering.
627
628 2007-07-23  Bruno Haible  <bruno@clisp.org>
629
630         * gnulib-tool (func_import): Create a .cvsignore file also when the
631         directory is not yet in CVS but the toplevel directory is. When
632         creating a .cvsignore file, add ".deps" and ".dirstamp" to it.
633         Reported by Karl Berry.
634
635 2007-07-22  Ben Pfaff  <blp@gnu.org>
636
637         * lib/popcount.h: Use faster, branchless algorithm for non-GCC
638         case.
639         Suggested by Eric Blake.
640
641 2007-07-22  Ben Pfaff  <blp@gnu.org>
642
643         New module: popcount.
644         * MODULES.html.sh: Add popcount.
645         * modules/popcount: New file.
646         * modules/popcount-tests: New file.
647         * tests/test-popcount.c: New file.
648         * lib/popcount.h: New file.
649         * m4/popcount.m4: New file.
650
651 2007-07-22  Paul Eggert  <eggert@cs.ucla.edu>
652
653         * build-aux/announce-gen: Update to GPLv3.
654
655         * build-aux/config.guess: Update from config.
656
657 2007-07-21  Bruno Haible  <bruno@clisp.org>
658
659         * lib/error.c (_) [ENABLE_NLS]: Define to gettext.
660         * lib/verror.c (_) [ENABLE_NLS]: Likewise.
661
662 2007-07-20  Jim Meyering  <jim@meyering.net>
663
664         * check-module: Diagnose a self-dependency.
665
666 2007-07-19  Bruno Haible  <bruno@clisp.org>
667
668         * gnulib-tool (func_import): Don't abort if pobase or po_domain is
669         empty.
670         Reported by Eric Blake.
671
672 2007-07-18  Bruno Haible  <bruno@clisp.org>
673
674         * gnulib-tool: New options --po-base, --po-domain.
675         (func_usage): Document them.
676         (pobase, po_domain): New variables.
677         (func_emit_lib_Makefile_am): Augment AM_CPPFLAGS, defining
678         DEFAULT_TEXT_DOMAIN.
679         (func_emit_po_Makevars, func_emit_po_POTFILES_in): New functions.
680         (func_import): Consider pobase and po_domain. Create a po/ directory.
681         (func_create_testdir): Set pobase and po_domain to empty.
682         * build-aux/po/Makefile.in.in: New file, from GNU gettext 0.16.1.
683         * build-aux/po/remove-potcdate.sin: New file, from GNU gettext 0.16.1.
684
685 2007-07-18  Bruno Haible  <bruno@clisp.org>
686
687         * gnulib-tool (func_get_automake_snippet): Synthesize also an
688         EXTRA_DIST augmentation for files in build-aux/.
689
690 2007-07-16  Bruno Haible  <bruno@clisp.org>
691
692         * modules/lseek (License): Use the synonymous term "LGPLv2+".
693         * modules/getdelim (License): Likewise.
694
695 2007-07-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
696
697         * modules/arpa_inet (License): Use the synonymous term LGPLv2+.
698         * modules/d-type (License): Likewise.
699         * modules/extensions (License): Likewise.
700         * modules/fnmatch (License): Likewise.
701         * modules/fseeko (License): Likewise.
702         * modules/getaddrinfo (License): Likewise.
703         * modules/getline (License): Likewise.
704         * modules/getlogin_r (License): Likewise.
705         * modules/getpass (License): Likewise.
706         * modules/gettimeofday (License): Likewise.
707         * modules/glob (License): Likewise.
708         * modules/inet_ntop (License): Likewise.
709         * modules/malloc (License): Likewise.
710         * modules/malloca (License): Likewise.
711         * modules/memmem (License): Likewise.
712         * modules/mempcpy (License): Likewise.
713         * modules/memset (License): Likewise.
714         * modules/minmax (License): Likewise.
715         * modules/mktime (License): Likewise.
716         * modules/netinet_in (License): Likewise.
717         * modules/pathmax (License): Likewise.
718         * modules/poll (License): Likewise.
719         * modules/regex (License): Likewise.
720         * modules/snprintf (License): Likewise.
721         * modules/stdbool (License): Likewise.
722         * modules/stdint (License): Likewise.
723         * modules/stdio (License): Likewise.
724         * modules/strcase (License): Likewise.
725         * modules/strcasestr (License): Likewise.
726         * modules/strdup (License): Likewise.
727         * modules/string (License): Likewise.
728         * modules/strndup (License): Likewise.
729         * modules/strnlen (License): Likewise.
730         * modules/strpbrk (License): Likewise.
731         * modules/strptime (License): Likewise.
732         * modules/strsep (License): Likewise.
733         * modules/sys_select (License): Likewise.
734         * modules/sys_socket (License): Likewise.
735         * modules/sys_stat (License): Likewise.
736         * modules/sys_time (License): Likewise.
737         * modules/time (License): Likewise.
738         * modules/time_r (License): Likewise.
739         * modules/timegm (License): Likewise.
740         * modules/unistd (License): Likewise.
741         * modules/vsnprintf (License): Likewise.
742         * modules/wctype (License): Likewise.
743
744 2007-07-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
745
746         * modules/argz (License): LGPLv2+.
747
748 2007-07-15  Karl Berry  <karl@gnu.org>
749
750         * doc/gnulib.texi: revise node structure per new fdl.texi.
751
752 2007-07-14  Bruno Haible  <bruno@clisp.org>
753
754         * lib/uniname/gen-uninames.lisp (main): Emit a "do not edit" line to
755         the output file.
756         * lib/uniname/uninames.h: Regenerated.
757
758 2007-07-14  Karl Berry  <karl@gnu.org>
759
760         * doc/*gpl*.texi, doc/fdl.texi: new versions, consistently
761         omitting sectioning and index commands.
762
763 2007-07-13  Bruno Haible  <bruno@clisp.org>
764
765         New gnulib-tool option --more-symlinks.
766         * gnulib-tool (func_usage): Document --more-symlinks.
767         (do_copyrights): New variable.
768         Recognize option --more-symlinks.
769         (func_import): Don't add a copyright notice transform to
770         sed_transform_lib_file if do_copyrights is empty.
771
772 2007-07-13  Bruno Haible  <bruno@clisp.org>
773
774         * lib/vasnprintf.c (decimal_point_char): Define also if
775         (NEED_PRINTF_LONG_DOUBLE || NEED_PRINTF_INFINITE_DOUBLE)
776         && !NEED_PRINTF_DIRECTIVE_A.
777         Reported by Clemens Koller <clemens.koller@anagramm.de> via
778         Gary V. Vaughan <gary@gnu.org>.
779
780 2007-07-13  Paul Eggert  <eggert@cs.ucla.edu>
781
782         * lib/inttypes_.h: Undo previous change, since it was fixed
783         in a different way in the 2007-07-02 fix to m4/inttypes.m4.
784
785 2007-07-13  Bruno Haible  <bruno@clisp.org>
786
787         * lib/stdint_.h: Fix typo: _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H was
788         misspelled as _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H.
789
790 2007-07-13  Jim Meyering  <jim@meyering.net>
791
792         df: Don't fail for Tru64's "file-on-file mount".
793         * m4/fsusage.m4 (gl_FSUSAGE): Reject Tru64's buggy statvfs,
794         so we fall through and use statfs instead.  Details here:
795         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/10878>
796         Reported by Albert Chin.
797
798 2007-07-13  Bruno Haible  <bruno@clisp.org>
799
800         * modules/alloca-opt (License): Use the synonymous term "LGPLv2+".
801         * modules/configmake (License): Likewise.
802         * modules/gettext (License): Likewise.
803         * modules/gettext-h (License): Likewise.
804         * modules/include_next (License): Likewise.
805         * modules/link-warning (License): Likewise.
806         * modules/localcharset (License): Likewise.
807         * modules/localename (License): Likewise.
808         * modules/lock (License): Likewise.
809         * modules/relocatable-lib-lgpl (License): Likewise.
810         * modules/size_max (License): Likewise.
811         * modules/vasnprintf (License): Likewise.
812         * modules/wchar (License): Likewise.
813         * modules/xsize (License): Likewise.
814
815 2007-07-13  Bruno Haible  <bruno@clisp.org>
816
817         * gnulib-tool (func_import): Treat LGPLv2 as synonymous to LGPL.
818         (func_create_testdir): Handle copying terms "GPLv2+" and "LGPLv2+".
819
820 2007-07-12  Bruno Haible  <bruno@clisp.org>
821
822         * doc/gnulib-intro.texi (Copyright): Clarify the license abbreviations
823         in the modules files.
824
825 2007-07-11  Karl Berry  <karl@gnu.org>
826
827         * MODULES.html.sh (func_module): use
828          sed -e '\|^'"${includefile}"'$|d'
829          instead of /.../d, to avoid errors on $includefile's containing /.
830
831 2007-07-10  Sergey Poznyakoff  <gray@gnu.org.ua>
832
833         * gnulib-tool (func_import): Avoid duplication of --avoid
834         statements
835         (func_dest_tmpfilename,func_create_testdir): Translate `-' in file
836         names to `_' in variable names.
837
838 2007-07-10  Eric Blake  <ebb9@byu.net>
839
840         * lib/version-etc.c (version_etc_va): Default to GPLv3+.
841         * NEWS: Document this change.
842
843 2007-07-08  Bruno Haible  <bruno@clisp.org>
844
845         Update to Unicode 5.0.
846         * lib/uniwidth/width.c (nonspacing_table_data): Add U+00AD,
847         U+0350..U+035F, U+05A2, U+05BA, U+05C5, U+05C7, U+0600..U+0603,
848         U+0610..U+0615, U+0656..U+065E, U+07EB..U+07F3, U+0A01, U+0AE2..U+0AE3,
849         U+0CBC. Remove U+0CBF, U+0CC6. Add U+0CE2..U+0CE3, U+135F,
850         U+17B4..U+17B5, U+17DD. Remove U+180E. Add U+1920..U+1922,
851         U+1927..U+192B, U+1932, U+1939..U+193B, U+1A17..U+1A18, U+1B00..U+1B03,
852         U+1B34, U+1B36..U+1B3A, U+1B3C, U+1B42, U+1B6B..U+1B73, U+1DC0..U+1DCA,
853         U+1DFE..U+1DFF, U+20EB..U+20EF, U+A802, U+A806, U+A80B, U+A825..U+A826,
854         U+10A01..U+10A03, U+10A05..U+10A06, U+10A0C..U+10A0F, U+10A38..U+10A3A,
855         U+10A3F, U+1D242..U+1D244.
856         (nonspacing_table_ind): Update.
857         (uc_width): Assign width 0 to U+E0100..U+E01EF. Assign width 1 to
858         U+4DC0..U+4DFF. Assign width 2 to U+2329..U+232A, U+FE10..U+FE1F.
859
860 2007-07-08  Bruno Haible  <bruno@clisp.org>
861
862         Update to Unicode 5.0.
863         * lib/uniname/gen-uninames.lisp (main): Add the range 0x12xxx to the
864         code transform. Extend the name index field of unicode_name_to_code and
865         unicode_code_to_name from 16 to 24 bits.
866         * lib/uniname/uniname.c (unicode_character_name,
867         unicode_name_character): Add the range 0x12xxx to the code transform.
868         * lib/uniname/uninames.h: Regenerated.
869         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.0.
870
871 2007-07-07  Bruno Haible  <bruno@clisp.org>
872
873         * modules/wcwidth-tests: New file.
874         * tests/test-wcwidth.c: New file.
875
876         Work around MacOS X wcwidth() bug.
877         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test against MacOS X 10.3 bug.
878         * lib/wcwidth.c: Include localcharset.h, streq.h, uniwidth.h.
879         (rpl_wcwidth): Special-case the UTF-8 locales. Fall back to the
880         original wcwidth in non-UTF-8 locales.
881         * modules/wcwidth (Depends-on): Add localcharset, streq,
882         uniwidth/width.
883         * doc/functions/wcwidth.texi: Update.
884
885 2007-07-07  Bruno Haible  <bruno@clisp.org>
886
887         * lib/wchar_.h: Include the GL_LINK_WARNING macro.
888         (wcwidth): New declaration.
889         * m4/wchar.m4 (gl_WCHAR_MODULE_INDICATOR, gl_WCHAR_H_DEFAULTS): New
890         macros.
891         (gl_WCHAR_H): Require gl_WCHAR_H_DEFAULTS. Don't set WCHAR_H to empty
892         here. Prepare for creating <wchar.h> unconditionally.
893         * modules/wchar (Depends-on): Add link-warning.
894         (Makefile.am): Substitute also GNULIB_WCWIDTH, HAVE_DECL_WCWIDTH,
895         REPLACE_WCWIDTH, and GL_LINK_WARNING.
896         * lib/wcwidth.h: Remove file.
897         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gl_WCHAR_H_DEFAULTS. Set
898         HAVE_DECL_WCWIDTH, REPLACE_WCWIDTH, WCHAR_H.
899         * modules/wcwidth (Files): Remove lib/wcwidth.h.
900         (configure.ac): Invoke gl_WCHAR_MODULE_INDICATOR.
901         (Include): Replace wcwidth.h with <wchar.h>.
902         * lib/wcwidth.c: Include <wchar.h> instead of wcwidth.h.
903         * lib/mbchar.h: Don't include wcwidth.h.
904         * lib/mbswidth.c: Likewise.
905         * NEWS: Mention the change.
906
907 2007-07-07  Bruno Haible  <bruno@clisp.org>
908
909         * lib/wcwidth.c: New file, extracted from lib/wcwidth.h.
910         * lib/wcwidth.h: Don't include wctype.h. Replace inline function
911         definition with an external declaration.
912         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Use wcwidth.c when wcwidth is not
913         defined as a function. Remove AC_C_INLINE requirement.
914         * modules/wcwidth (Files): Add lib/wcwidth.c.
915         (Makefile.am): Remove redundant statement.
916
917 2007-07-07  Bruno Haible  <bruno@clisp.org>
918
919         * MODULES.html.sh (Unicode string functions): Add the new modules.
920
921         * tests/uniwidth/test-u32-strwidth.c: New file.
922         * modules/uniwidth/u32-strwidth-tests: New file.
923
924         * lib/uniwidth/u32-strwidth.c: New file.
925         * modules/uniwidth/u32-strwidth: New file.
926
927         * tests/uniwidth/test-u16-strwidth.c: New file.
928         * modules/uniwidth/u16-strwidth-tests: New file.
929
930         * lib/uniwidth/u16-strwidth.c: New file.
931         * modules/uniwidth/u16-strwidth: New file.
932
933         * tests/uniwidth/test-u8-strwidth.c: New file.
934         * modules/uniwidth/u8-strwidth-tests: New file.
935
936         * lib/uniwidth/u8-strwidth.c: New file.
937         * modules/uniwidth/u8-strwidth: New file.
938
939         * tests/uniwidth/test-u32-width.c: New file.
940         * modules/uniwidth/u32-width-tests: New file.
941
942         * lib/uniwidth/u32-width.c: New file.
943         * modules/uniwidth/u32-width: New file.
944
945         * tests/uniwidth/test-u16-width.c: New file.
946         * modules/uniwidth/u16-width-tests: New file.
947
948         * lib/uniwidth/u16-width.c: New file.
949         * modules/uniwidth/u16-width: New file.
950
951         * tests/uniwidth/test-u8-width.c: New file.
952         * modules/uniwidth/u8-width-tests: New file.
953
954         * lib/uniwidth/u8-width.c: New file.
955         * modules/uniwidth/u8-width: New file.
956
957         * tests/uniwidth/test-uc_width.c: New file.
958         * modules/uniwidth/width-tests: New file.
959
960         * lib/uniwidth/width.c: New file, from GNU libiconv.
961         * lib/uniwidth/cjk.h: New file, from GNU libiconv.
962         * modules/uniwidth/width: New file.
963
964         * lib/uniwidth.h: New file, from GNU libiconv.
965         * modules/uniwidth/base: New file.
966
967 2007-07-07  Bruno Haible  <bruno@clisp.org>
968
969         * lib/uniname.h: New file, from GNU gettext.
970         * lib/uniname/gen-uninames.lisp: New file, from GNU gettext.
971         * lib/uniname/uninames.h: New file, from GNU gettext.
972         * lib/uniname/uniname.c: New file, from GNU gettext.
973         * tests/uniname/test-uninames.sh: New file.
974         * tests/uniname/test-uninames.c: New file, from GNU gettext.
975         * tests/uniname/UnicodeDataNames.txt: New file, from GNU gettext.
976         * modules/uniname/base: New file.
977         * modules/uniname/uniname: New file.
978         * modules/uniname/uniname-tests: New file.
979         * MODULES.html.sh (Unicode string functions): Add the new modules.
980
981 2007-07-06  Bruno Haible  <bruno@clisp.org>
982
983         * doc/Makefile (TEXI2HTML): Specify a --reference-limit.
984
985 2007-07-06  Bruno Haible  <bruno@clisp.org>
986
987         * lib/sys_time_.h: Use a recursion-safe inclusion guard rather than
988         a split double-inclusion guard. Needed for cygwin, where <sys/time.h>
989         includes <cygwin/sys_time.h> which includes <sys/select.h> which
990         include <sys/time.h>.
991         Reported by Eric Blake.
992
993 2007-07-06  Eric Blake  <ebb9@byu.net>
994
995         Fix testing canonicalize on cygwin.
996         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
997         Revert patch from 2007-06-19.
998         * tests/test-canonicalize-lgpl.c (main): Instead, skip test when
999         canonicalize module is also in use.
1000         * tests/test-canonicalize.c: New file.
1001         * tests/test-canonicalize.sh: Likewise.
1002         * modules/canonicalize-tests: Likewise.
1003
1004 2007-07-06  Jim Meyering  <jim@meyering.net>
1005
1006         * lib/getugroups.c (getugroups): Detect getgrent failure.
1007         Adjust comment to reflect reality: this function may return -1.
1008
1009 2007-07-05  Sergey Poznyakoff  <gray@gnu.org.ua>
1010
1011         * build-aux/bootstrap (TP_URL,get_translations): Update to use
1012         the new TP address.
1013         (usage): Fix typo
1014         (gnulib_mk): New variable.
1015
1016 2007-07-05  Jim Meyering  <jim@meyering.net>
1017
1018         Don't let endgrent clobber errno, no matter how improbable.
1019         * lib/getugroups.c (getugroups): Save and restore errno around
1020         endgrent call.
1021
1022         Close the group DB even when failing with 2^31 or more members.
1023         * lib/getugroups.c (getugroups): Don't return without calling endgrent.
1024
1025 2007-07-04  Jim Meyering  <jim@meyering.net>
1026
1027         * lib/getugroups.h: New file.
1028         * lib/getugroups.c: Include "getugroups.h".
1029         Remove uses of "register" keyword.
1030         Move local variable, "cp", down into scope where used.
1031         Give "username" parameter the "const" attribute.
1032         * modules/getugroups (Files): Add lib/getugroups.h
1033
1034 2007-07-04  Karl Berry  <karl@gnu.org>
1035
1036         * MODULES.html.sh (func_all_modules): Complete rename of
1037         gpl/lgpl to gpl-2.0 and lgpl-2.1, and add gpl-3.0.
1038
1039 2007-07-02  Bruno Haible  <bruno@clisp.org>
1040
1041         * m4/inttypes.m4 (gl_INTTYPES_H): Define __STDC_LIMIT_MACROS in C++
1042         mode, when inttypes.h comes from gnulib.
1043         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
1044
1045 2007-07-02  Simon Josefsson  <simon@josefsson.org>
1046
1047         * NEWS: Mention lgpl module name change.
1048
1049         * modules/lgpl-2.1: Renamed from lgpl.
1050
1051         * NEWS: Mention gpl module name change.
1052
1053         * modules/gpl-3.0: New file, based on gpl-2.0.
1054
1055         * modules/gpl-2.0: Renamed from gpl.
1056
1057         * modules/gpl: Fix filename, doc/gpl.texi is now found at
1058         doc/gpl-2.0.texi.
1059
1060 2007-07-02  Paul Eggert  <eggert@cs.ucla.edu>
1061
1062         * lib/inttypes_.h [defined __cplusplus&&!defined __STDC_LIMIT_MACROS]:
1063         #define __STDC_LIMIT_MACROS temporarily while including
1064         <stdint.h>, so that __STDC_LIMIT_MACROS is defined.
1065         Problem reported by Joel E. Denny in
1066         <http://lists.gnu.org/archive/html/bug-gnulib/2007-07/msg00008.html>.
1067
1068 2007-07-01  Bruno Haible  <bruno@clisp.org>
1069
1070         * lib/unistdio.h: New file.
1071         * lib/unistdio/u-asnprintf.h: New file.
1072         * lib/unistdio/u-asprintf.h: New file.
1073         * lib/unistdio/u-printf-args.c: New file.
1074         * lib/unistdio/u-printf-args.h: New file.
1075         * lib/unistdio/u-printf-parse.h: New file.
1076         * lib/unistdio/u-snprintf.h: New file.
1077         * lib/unistdio/u-sprintf.h: New file.
1078         * lib/unistdio/u-vasprintf.h: New file.
1079         * lib/unistdio/u-vsnprintf.h: New file.
1080         * lib/unistdio/u-vsprintf.h: New file.
1081         * lib/unistdio/ulc-asnprintf.c: New file.
1082         * lib/unistdio/ulc-asprintf.c: New file.
1083         * lib/unistdio/ulc-fprintf.c: New file, based on lib/fprintf.c.
1084         * lib/unistdio/ulc-printf-parse.c: New file.
1085         * lib/unistdio/ulc-snprintf.c: New file.
1086         * lib/unistdio/ulc-sprintf.c: New file.
1087         * lib/unistdio/ulc-vasnprintf.c: New file.
1088         * lib/unistdio/ulc-vasprintf.c: New file.
1089         * lib/unistdio/ulc-vfprintf.c: New file, based on lib/vfprintf.c.
1090         * lib/unistdio/ulc-vsnprintf.c: New file.
1091         * lib/unistdio/ulc-vsprintf.c: New file.
1092         * lib/unistdio/u8-asnprintf.c: New file.
1093         * lib/unistdio/u8-asprintf.c: New file.
1094         * lib/unistdio/u8-printf-parse.c: New file.
1095         * lib/unistdio/u8-snprintf.c: New file.
1096         * lib/unistdio/u8-sprintf.c: New file.
1097         * lib/unistdio/u8-vasnprintf.c: New file.
1098         * lib/unistdio/u8-vasprintf.c: New file.
1099         * lib/unistdio/u8-vsnprintf.c: New file.
1100         * lib/unistdio/u8-vsprintf.c: New file.
1101         * lib/unistdio/u8-u8-asnprintf.c: New file.
1102         * lib/unistdio/u8-u8-asprintf.c: New file.
1103         * lib/unistdio/u8-u8-snprintf.c: New file.
1104         * lib/unistdio/u8-u8-sprintf.c: New file.
1105         * lib/unistdio/u8-u8-vasnprintf.c: New file.
1106         * lib/unistdio/u8-u8-vasprintf.c: New file.
1107         * lib/unistdio/u8-u8-vsnprintf.c: New file.
1108         * lib/unistdio/u8-u8-vsprintf.c: New file.
1109         * lib/unistdio/u16-asnprintf.c: New file.
1110         * lib/unistdio/u16-asprintf.c: New file.
1111         * lib/unistdio/u16-printf-parse.c: New file.
1112         * lib/unistdio/u16-snprintf.c: New file.
1113         * lib/unistdio/u16-sprintf.c: New file.
1114         * lib/unistdio/u16-vasnprintf.c: New file.
1115         * lib/unistdio/u16-vasprintf.c: New file.
1116         * lib/unistdio/u16-vsnprintf.c: New file.
1117         * lib/unistdio/u16-vsprintf.c: New file.
1118         * lib/unistdio/u16-u16-asnprintf.c: New file.
1119         * lib/unistdio/u16-u16-asprintf.c: New file.
1120         * lib/unistdio/u16-u16-snprintf.c: New file.
1121         * lib/unistdio/u16-u16-sprintf.c: New file.
1122         * lib/unistdio/u16-u16-vasnprintf.c: New file.
1123         * lib/unistdio/u16-u16-vasprintf.c: New file.
1124         * lib/unistdio/u16-u16-vsnprintf.c: New file.
1125         * lib/unistdio/u16-u16-vsprintf.c: New file.
1126         * lib/unistdio/u32-asnprintf.c: New file.
1127         * lib/unistdio/u32-asprintf.c: New file.
1128         * lib/unistdio/u32-printf-parse.c: New file.
1129         * lib/unistdio/u32-snprintf.c: New file.
1130         * lib/unistdio/u32-sprintf.c: New file.
1131         * lib/unistdio/u32-vasnprintf.c: New file.
1132         * lib/unistdio/u32-vasprintf.c: New file.
1133         * lib/unistdio/u32-vsnprintf.c: New file.
1134         * lib/unistdio/u32-vsprintf.c: New file.
1135         * lib/unistdio/u32-u32-asnprintf.c: New file.
1136         * lib/unistdio/u32-u32-asprintf.c: New file.
1137         * lib/unistdio/u32-u32-snprintf.c: New file.
1138         * lib/unistdio/u32-u32-sprintf.c: New file.
1139         * lib/unistdio/u32-u32-vasnprintf.c: New file.
1140         * lib/unistdio/u32-u32-vasprintf.c: New file.
1141         * lib/unistdio/u32-u32-vsnprintf.c: New file.
1142         * lib/unistdio/u32-u32-vsprintf.c: New file.
1143         * tests/unistdio/test-ulc-asnprintf1.c: New file.
1144         * tests/unistdio/test-ulc-asnprintf1.h: New file.
1145         * tests/unistdio/test-ulc-printf1.h: New file.
1146         * tests/unistdio/test-ulc-vasnprintf1.c: New file.
1147         * tests/unistdio/test-ulc-vasnprintf2.c: New file.
1148         * tests/unistdio/test-ulc-vasnprintf2.sh: New file.
1149         * tests/unistdio/test-ulc-vasnprintf3.c: New file.
1150         * tests/unistdio/test-ulc-vasnprintf3.sh: New file.
1151         * tests/unistdio/test-ulc-vasprintf1.c: New file.
1152         * tests/unistdio/test-ulc-vsnprintf1.c: New file.
1153         * tests/unistdio/test-ulc-vsprintf1.c: New file.
1154         * tests/unistdio/test-u8-asnprintf1.c: New file.
1155         * tests/unistdio/test-u8-asnprintf1.h: New file.
1156         * tests/unistdio/test-u8-printf1.h: New file.
1157         * tests/unistdio/test-u8-vasnprintf1.c: New file.
1158         * tests/unistdio/test-u8-vasnprintf2.c: New file.
1159         * tests/unistdio/test-u8-vasnprintf2.sh: New file.
1160         * tests/unistdio/test-u8-vasnprintf3.c: New file.
1161         * tests/unistdio/test-u8-vasnprintf3.sh: New file.
1162         * tests/unistdio/test-u8-vasprintf1.c: New file.
1163         * tests/unistdio/test-u8-vsnprintf1.c: New file.
1164         * tests/unistdio/test-u8-vsprintf1.c: New file.
1165         * tests/unistdio/test-u16-asnprintf1.c: New file.
1166         * tests/unistdio/test-u16-asnprintf1.h: New file.
1167         * tests/unistdio/test-u16-printf1.h: New file.
1168         * tests/unistdio/test-u16-vasnprintf1.c: New file.
1169         * tests/unistdio/test-u16-vasnprintf2.c: New file.
1170         * tests/unistdio/test-u16-vasnprintf2.sh: New file.
1171         * tests/unistdio/test-u16-vasnprintf3.c: New file.
1172         * tests/unistdio/test-u16-vasnprintf3.sh: New file.
1173         * tests/unistdio/test-u16-vasprintf1.c: New file.
1174         * tests/unistdio/test-u16-vsnprintf1.c: New file.
1175         * tests/unistdio/test-u16-vsprintf1.c: New file.
1176         * tests/unistdio/test-u32-asnprintf1.c: New file.
1177         * tests/unistdio/test-u32-asnprintf1.h: New file.
1178         * tests/unistdio/test-u32-printf1.h: New file.
1179         * tests/unistdio/test-u32-vasnprintf1.c: New file.
1180         * tests/unistdio/test-u32-vasnprintf2.c: New file.
1181         * tests/unistdio/test-u32-vasnprintf2.sh: New file.
1182         * tests/unistdio/test-u32-vasnprintf3.c: New file.
1183         * tests/unistdio/test-u32-vasnprintf3.sh: New file.
1184         * tests/unistdio/test-u32-vasprintf1.c: New file.
1185         * tests/unistdio/test-u32-vsnprintf1.c: New file.
1186         * tests/unistdio/test-u32-vsprintf1.c: New file.
1187         * modules/unistdio/base: New file.
1188         * modules/unistdio/u-printf-args: New file.
1189         * modules/unistdio/ulc-asnprintf: New file.
1190         * modules/unistdio/ulc-asprintf: New file.
1191         * modules/unistdio/ulc-fprintf: New file.
1192         * modules/unistdio/ulc-printf-parse: New file.
1193         * modules/unistdio/ulc-snprintf: New file.
1194         * modules/unistdio/ulc-sprintf: New file.
1195         * modules/unistdio/ulc-vasnprintf: New file.
1196         * modules/unistdio/ulc-vasprintf: New file.
1197         * modules/unistdio/ulc-vfprintf: New file.
1198         * modules/unistdio/ulc-vsnprintf: New file.
1199         * modules/unistdio/ulc-vsprintf: New file.
1200         * modules/unistdio/u8-asnprintf: New file.
1201         * modules/unistdio/u8-asprintf: New file.
1202         * modules/unistdio/u8-printf-parse: New file.
1203         * modules/unistdio/u8-snprintf: New file.
1204         * modules/unistdio/u8-sprintf: New file.
1205         * modules/unistdio/u8-vasnprintf: New file.
1206         * modules/unistdio/u8-vasprintf: New file.
1207         * modules/unistdio/u8-vsnprintf: New file.
1208         * modules/unistdio/u8-vsprintf: New file.
1209         * modules/unistdio/u8-u8-asnprintf: New file.
1210         * modules/unistdio/u8-u8-asprintf: New file.
1211         * modules/unistdio/u8-u8-snprintf: New file.
1212         * modules/unistdio/u8-u8-sprintf: New file.
1213         * modules/unistdio/u8-u8-vasnprintf: New file.
1214         * modules/unistdio/u8-u8-vasprintf: New file.
1215         * modules/unistdio/u8-u8-vsnprintf: New file.
1216         * modules/unistdio/u8-u8-vsprintf: New file.
1217         * modules/unistdio/u16-asnprintf: New file.
1218         * modules/unistdio/u16-asprintf: New file.
1219         * modules/unistdio/u16-printf-parse: New file.
1220         * modules/unistdio/u16-snprintf: New file.
1221         * modules/unistdio/u16-sprintf: New file.
1222         * modules/unistdio/u16-vasnprintf: New file.
1223         * modules/unistdio/u16-vasprintf: New file.
1224         * modules/unistdio/u16-vsnprintf: New file.
1225         * modules/unistdio/u16-vsprintf: New file.
1226         * modules/unistdio/u16-u16-asnprintf: New file.
1227         * modules/unistdio/u16-u16-asprintf: New file.
1228         * modules/unistdio/u16-u16-snprintf: New file.
1229         * modules/unistdio/u16-u16-sprintf: New file.
1230         * modules/unistdio/u16-u16-vasnprintf: New file.
1231         * modules/unistdio/u16-u16-vasprintf: New file.
1232         * modules/unistdio/u16-u16-vsnprintf: New file.
1233         * modules/unistdio/u16-u16-vsprintf: New file.
1234         * modules/unistdio/u32-asnprintf: New file.
1235         * modules/unistdio/u32-asprintf: New file.
1236         * modules/unistdio/u32-printf-parse: New file.
1237         * modules/unistdio/u32-snprintf: New file.
1238         * modules/unistdio/u32-sprintf: New file.
1239         * modules/unistdio/u32-vasnprintf: New file.
1240         * modules/unistdio/u32-vasprintf: New file.
1241         * modules/unistdio/u32-vsnprintf: New file.
1242         * modules/unistdio/u32-vsprintf: New file.
1243         * modules/unistdio/u32-u32-asnprintf: New file.
1244         * modules/unistdio/u32-u32-asprintf: New file.
1245         * modules/unistdio/u32-u32-snprintf: New file.
1246         * modules/unistdio/u32-u32-sprintf: New file.
1247         * modules/unistdio/u32-u32-vasnprintf: New file.
1248         * modules/unistdio/u32-u32-vasprintf: New file.
1249         * modules/unistdio/u32-u32-vsnprintf: New file.
1250         * modules/unistdio/u32-u32-vsprintf: New file.
1251         * modules/unistdio/ulc-asnprintf-tests: New file.
1252         * modules/unistdio/ulc-vasnprintf-tests: New file.
1253         * modules/unistdio/ulc-vasprintf-tests: New file.
1254         * modules/unistdio/ulc-vsnprintf-tests: New file.
1255         * modules/unistdio/ulc-vsprintf-tests: New file.
1256         * modules/unistdio/u8-asnprintf-tests: New file.
1257         * modules/unistdio/u8-vasnprintf-tests: New file.
1258         * modules/unistdio/u8-vasprintf-tests: New file.
1259         * modules/unistdio/u8-vsnprintf-tests: New file.
1260         * modules/unistdio/u8-vsprintf-tests: New file.
1261         * modules/unistdio/u16-asnprintf-tests: New file.
1262         * modules/unistdio/u16-vasnprintf-tests: New file.
1263         * modules/unistdio/u16-vasprintf-tests: New file.
1264         * modules/unistdio/u16-vsnprintf-tests: New file.
1265         * modules/unistdio/u16-vsprintf-tests: New file.
1266         * modules/unistdio/u32-asnprintf-tests: New file.
1267         * modules/unistdio/u32-vasnprintf-tests: New file.
1268         * modules/unistdio/u32-vasprintf-tests: New file.
1269         * modules/unistdio/u32-vsnprintf-tests: New file.
1270         * modules/unistdio/u32-vsprintf-tests: New file.
1271         * MODULES.html.sh (Unicode string functions): Add the new modules.
1272
1273 2007-07-01  Bruno Haible  <bruno@clisp.org>
1274
1275         * lib/sprintf.c (sprintf): Limit the available length estimation,
1276         to avoid address wraparound.
1277         * lib/vsprintf.c (vsprintf): Likewise.
1278         * modules/sprintf-posix (Dependencies): Add stdint.
1279         * modules/vsprintf-posix (Dependencies): Likewise.
1280
1281 2007-07-01  Bruno Haible  <bruno@clisp.org>
1282
1283         * gnulib-tool (self_abspathname): Determine PATH_SEPARATOR and handle
1284         Windows PATH as well. Conservative double-quoting. Comments.
1285
1286 2007-07-01  Bruno Haible  <bruno@clisp.org>
1287             Eric Blake  <ebb9@byu.net>
1288             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1289
1290         * gnulib-tool (self_abspathname): Fix algorithm to cope with
1291         empty components in $PATH, denoting '.'.
1292
1293 2007-07-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1294
1295         * gnulib-tool: Fix indentation.
1296         (func_create_megatestdir): Likewise.
1297         Report by Bruno Haible.
1298
1299 2007-06-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1300
1301         Sync from Automake.
1302         * build-aux/gnupload: Fix shell portability issues with for loops.
1303         Report by Karl Berry.
1304
1305 2007-06-29  Simon Josefsson  <simon@josefsson.org>
1306
1307         * build-aux/maint.mk (POURL): Use translationproject.org.
1308
1309 2007-06-27  Simon Josefsson  <simon@josefsson.org>
1310             Bruno Haible  <bruno@clisp.org>
1311
1312         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Require gl_HEADER_SYS_SOCKET
1313         before using HAVE_WS2TCPIP_H. Check for gai_strerror through an
1314         explicit link test, rather than AC_REPLACE_FUNCS - for mingw.
1315         (gl_PREREQ_GETADDRINFO): Require gl_HEADER_SYS_SOCKET before using
1316         HAVE_SYS_SOCKET_H and HAVE_WS2TCPIP_H.
1317
1318 2007-06-27  Bruno Haible  <bruno@clisp.org>
1319
1320         * build-aux/config.rpath: Upgrade to libtool-1.5.24.
1321         * build-aux/config.libpath: Upgrade to libtool-1.5.24.
1322
1323 2007-06-26  Karl Berry  <karl@gnu.org>
1324
1325         * MODULES.html.sh: remove xreadlink-with-size.
1326
1327 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
1328
1329         * lib/time_.h: Port to Solaris 8 with Sun Studio 11, using a
1330         method that I hope also handles the double-include problem noted
1331         by Bruno Haible in
1332         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00186.html>.
1333
1334 2007-06-23  Bruno Haible  <bruno@clisp.org>
1335
1336         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
1337         Don't let the 'mostlyclean' target fail if the last subdirectory could
1338         not be removed.
1339         Reported by Karl Berry.
1340
1341 2007-06-23  Bruno Haible  <bruno@clisp.org>
1342
1343         * gnulib-tool (echo): Add a speedier workaround for ksh.
1344         * tests/test-echo.sh: Likewise.
1345
1346 2007-06-23  Bruno Haible  <bruno@clisp.org>
1347
1348         * gnulib-tool (echo): Add workarounds also for bash versions < 2.04.
1349         * tests/test-echo.sh: Likewise.
1350
1351 2007-06-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1352
1353         * gnulib-tool (IFS): Initialize early, so we don't set it to
1354         empty later.
1355         (self_abspathname): Rewrite algorithm to set it, reindent.
1356         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am)
1357         (func_create_megatestdir): Merge some sed scripts.
1358
1359 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
1360
1361         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Check some typos
1362         exposed by Sun Studio 11 cc on Solaris 8.
1363
1364 2007-06-22  Bruno Haible  <bruno@clisp.org>
1365
1366         * gnulib-tool (echo): Ensure the echo primitive does not interpret
1367         backslashes.
1368         * tests/test-echo.sh: New file.
1369
1370 2007-06-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1371
1372         * gnulib-tool (func_add_or_update, func_create_testdir): Do not
1373         simplify `sed_replace_build_aux' scripts, they are portable but
1374         echoing them with `echo' is not.
1375         Report and analysis by Fernando Ferreira <fernando.prog@netcabo.pt>.
1376
1377 2007-06-21  Karl Berry  <karl@gnu.org>
1378
1379         * config/srclist.txt: guess we can't handle the licenses via
1380         srclist at the moment.
1381
1382 2007-06-21  Paul Eggert  <eggert@cs.ucla.edu>
1383
1384         * MODULES.html.sh: Add include_next.
1385         * modules/include_next: New file.
1386
1387 2007-06-20  Paul Eggert  <eggert@cs.ucla.edu>
1388
1389         * m4/include_next.m4 (gl_INCLUDE_NEXT): Define and AC_SUBST
1390         INCLUDE_NEXT.
1391         (gl_CHECK_NEXT_HEADERS): New macro.
1392         * m4/fcntl_h.m4 (gl_FCNTL_H): use gl_CHECK_NEXT_HEADERS instead of
1393         the obsolescent gl_ABSOLUTE_HEADER.
1394         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
1395         * m4/float_h.m4 (gl_FLOAT_H): Likewise.
1396         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
1397         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
1398         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
1399         * m4/math_h.m4 (gl_MATH_H): Likewise.
1400         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
1401         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
1402         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
1403         * m4/stdint.m4 (gl_STDINT_H): Likewise.
1404         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
1405         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
1406         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
1407         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
1408         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
1409         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
1410         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
1411         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
1412         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Likewise.
1413         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
1414         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
1415         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
1416         * m4/inttypes.m4 (gl_INTTYPES_H): Define
1417         _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H to avoid the problem of unclean
1418         builds, since ABSOLUTE_INTTYPES_H is no longer being defined.
1419         * m4/stdint.m4 (gl_STDINT_H): Likewise, for
1420         _GL_JUST_INCLUDE_SYSTEM_STDINT_H.
1421         * lib/fcntl_.h: Use @INCLUDE_NEXT@ @NEXT_foo_H@
1422         rather than @HAVE_INCLUDE_NEXT@ and @ABSOLUTE_foo_H@.
1423         * lib/float_.h: Likewise.
1424         * lib/inttypes_.h: Likewise.
1425         * lib/math_.h: Likewise.
1426         * lib/search_.h: Likewise.
1427         * lib/signal_.h: Likewise.
1428         * lib/stdint_.h: Likewise.
1429         * lib/stdio_.h: Likewise.
1430         * lib/stdlib_.h: Likewise.
1431         * lib/string_.h: Likewise.
1432         * lib/sys_stat_.h: Likewise.
1433         * lib/sys_time_.h: Likewise.
1434         * lib/time_.h: Likewise.
1435         * lib/unistd_.h: Likewise.
1436         * lib/wchar_.h: Likewise.
1437         * lib/wctype_.h: Likewise.
1438         * lib/dirent_.h: Likewise.
1439         * lib/iconv_.h: Likewise.
1440         * lib/locale_.h: Likewise.
1441         * lib/netinet_in_.h: Likewise.
1442         * lib/sys_select_.h: Likewise.
1443         * lib/sys_socket_.h: Likewise.
1444         * lib/sysexits_.h: Likewise.
1445         * modules/fcntl (Depends-on): Depend on include_next, not
1446         absolute_header.
1447         (Makefile): Substitute INCLUDE_NEXT and NEXT_foo_H, not
1448         HAVE_INCLUDE_NEXT and ABSOLUTE_foo_H.
1449         * modules/fchdir: Likewise.
1450         * modules/float: Likewise.
1451         * modules/iconv_open: Likewise.
1452         * modules/inttypes: Likewise.
1453         * modules/locale: Likewise.
1454         * modules/math: Likewise.
1455         * modules/netinet_in: Likewise.
1456         * modules/search: Likewise.
1457         * modules/signal: Likewise.
1458         * modules/stdint: Likewise.
1459         * modules/stdio: Likewise.
1460         * modules/stdlib: Likewise.
1461         * modules/string: Likewise.
1462         * modules/sys_select: Likewise.
1463         * modules/sys_socket: Likewise.
1464         * modules/sys_stat: Likewise.
1465         * modules/sys_time: Likewise.
1466         * modules/sysexits: Likewise.
1467         * modules/time: Likewise.
1468         * modules/unistd: Likewise.
1469         * modules/wchar: Likewise.
1470         * modules/wctype: Likewise.
1471         * modules/sys_stat: Change maintainer to "all".
1472         * modules/unistd: Likewise.
1473
1474 2007-06-20  Karl Berry  <karl@gnu.org>
1475
1476         * config/srclist.txt: track www changes in license files.
1477
1478 2007-06-20  Sergey Poznyakoff  <gray@gnu.org.ua>
1479
1480         * build-aux/bootstrap: Remove stray dot.
1481         Make sure build_aux settings are honored when linking
1482         gnulib_extra_files.
1483
1484 2007-06-19  Eric Blake  <ebb9@byu.net>
1485
1486         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
1487         Allow compilation on cygwin.
1488
1489 2007-06-19  Jim Meyering  <jim@meyering.net>
1490
1491         xreadlink-with-size: Remove module.  No longer used.
1492         Ex-callers now use xreadlink or mreadlink-with-size.
1493         * modules/xreadlink-with-size: Remove module.
1494         * lib/xreadlink-with-size.c: Remove file.
1495         * lib/xreadlink.h (xreadlink_with_size): Remove prototype.
1496         (xreadlink): Remove inaccurate comment.  The one in xreadlink.c,
1497         just before the function definition *is* accurate.
1498
1499         Eliminate one way canonicalize_filename_mode could exit.
1500         * lib/canonicalize.c (canonicalize_filename_mode):
1501         Use mreadlink_with_size, not xreadlink_with_size.
1502
1503 2007-06-18  Paul Eggert  <eggert@cs.ucla.edu>
1504
1505         Detect porting problems to FreeBSD/arm, which has time_t wider than
1506         long int.  Original problem reported for GNU diff by Xin Li in
1507         <http://lists.gnu.org/archive/html/bug-gnu-utils/2007-06/msg00091.html>.
1508         * modules/getdate (Depends-on): Add intprops, verify.
1509         * lib/getdate.y: Include intprops.h, verify.h.  Verify that time_t
1510         is an integer type no wider than long int.
1511
1512 2007-06-18  Jim Meyering  <jim@meyering.net>
1513
1514         New module: mreadlink-with-size.
1515         * MODULES.html.sh: Add mreadlink-with-size.
1516         * modules/mreadlink-with-size: New module
1517         * modules/canonicalize (Depends-on): Depend on mreadlink-with-size,
1518         not xreadlink-with-size.
1519         * lib/mreadlink-with-size.c, lib/mreadlink.h: New files.
1520
1521 2007-06-16  Bruno Haible  <bruno@clisp.org>
1522
1523         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Catch the MacOS X 10.4 bug.
1524         * doc/functions/frexpl.texi: Document the MacOS X 10.4 bug.
1525         Reported by Gary V. Vaughan <gary@gnu.org>.
1526
1527 2007-06-15  Paul Eggert  <eggert@cs.ucla.edu>
1528
1529         Revamp lchown so that it lives in unistd.h where it belongs.
1530         * lib/lchown.h: Remove.
1531         * lib/dirchownmod.c: Don't include lib/lchown.h.
1532         * lib/fchownat.c: Likewise.
1533         * lib/openat.c: Likewise.
1534         * lib/lchown.c (REPLACE_CHOWN): Define to 0 if the system chown
1535         does not follow symlinks.
1536         (EOPNOTSUPP): Define if not defined.
1537         * lib/unistd_.h (chown): Do not replace if REPLADE_CHOWN
1538         is defined to 0.
1539         (lchown): New decl.
1540         * m4/lchown.m4 (gl_FUNC_LCHOWN): Require gl_UNISTD_H_DEFAULTS.
1541         Do not check for lchown decl.
1542         Set REPLACE_LCHOWN.
1543         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set GNULIB_LCHOWN,
1544         REPLACE_LCHOWN.
1545         * modules/chown: Make it clear it follows symlinks.
1546         * modules/lchown: Make it clear it doesn't follow symlinks.
1547         (Files): Remove lib/lchown.h
1548         (Depends-on): Add unistd.
1549         (configure.ac): Add gl_UNISTD_MODULE_INDICATOR([lchown]).
1550         (Include): Include <unistd.h>, not "lchown.h".
1551         * modules/unistd (unistd.h): Substitude GNULIB_LCHOWN and
1552         REPLACE_LCHOWN.
1553
1554 2007-06-15  Jim Meyering  <jim@meyering.net>
1555
1556         Change license (GPL to LGPL) of fsusage and dependents.
1557         * modules/fsusage (License): Change to LGPL.
1558         * modules/full-read (License): Likewise.
1559         * modules/full-write (License): Likewise.
1560         * modules/safe-read (License): Likewise.
1561         * modules/safe-write (License): Likewise.
1562
1563 2007-06-14  Ben Pfaff  <blp@gnu.org>
1564
1565         Missing part of allocsa -> malloca transition.
1566         * modules/relocatable-prog-wrapper: gl_ALLOCSA should be
1567         gl_MALLOCA.
1568
1569 2007-06-12  Bruno Haible  <bruno@clisp.org>
1570
1571         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Guess no when cross-compiling
1572         to ia64, x86_64, i386.
1573         Reported by Eric Blake.
1574
1575 2007-06-12  Bruno Haible  <bruno@clisp.org>
1576
1577         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Guess no also when
1578         cross-compiling to x86_64.
1579
1580 2007-06-12  Paul Eggert  <eggert@cs.ucla.edu>
1581
1582         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Fix POSIX sed portability
1583         glitch reported by Ralf Wildenhues in
1584         <http://lists.gnu.org/archive/html/bug-gnulib/2007-06/msg00114.html>.
1585
1586         * m4/regex.m4 (gl_REGEX): Catch a bug with [[:alnum:]_-] reported by
1587         Vin Shelton.
1588
1589 2007-06-11  Bruno Haible  <bruno@clisp.org>
1590
1591         * lib/printf-args.c (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Fix NULL
1592         replacement string.
1593         Reported by Eric Blake.
1594
1595 2007-06-10  Bruno Haible  <bruno@clisp.org>
1596
1597         Prepare vasnprintf code for use with Unicode strings.
1598         * lib/printf-args.h (PRINTF_FETCHARGS): New macro.
1599         (arg_type) [ENABLE_UNISTDIO]: Define TYPE_U8_STRING, TYPE_U16_STRING,
1600         TYPE_U32_STRING.
1601         (argument) [ENABLE_UNISTDIO]: Add a_u8_string, a_u16_string,
1602         a_u32_string variants.
1603         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
1604         * lib/printf-args.c: Don't include config.h and the specification
1605         header if PRINTF_FETCHARGS is already defined.
1606         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
1607         (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Add code for TYPE_U8_STRING,
1608         TYPE_U16_STRING, TYPE_U32_STRING.
1609         * lib/printf-parse.h [ENABLE_UNISTDIO] (u8_directive, u8_directives,
1610         u16_directive, u16_directives, u32_directive, u32_directives): New
1611         types.
1612         (ulc_printf_parse, u8_printf_parse, u16_printf_parse, u32_printf_parse):
1613         New declarations.
1614         * lib/printf-parse.c: Don't include config.h and the specification
1615         header if PRINTF_PARSE is already defined. Eliminate the set of
1616         parameters for WIDE_CHAR_VERSION; the user of this file must provide
1617         them now. Include c-ctype.h.
1618         (PRINTF_PARSE) [ENABLE_UNISTDIO]: Add code implementing the 'U'
1619         directive and CHAR_T_ONLY_ASCII.
1620         * lib/vasnprintf.c: Don't include config.h and the specification header
1621         if VASNPRINTF is already defined.
1622         (DCHAR_IS_TCHAR, DCHAR_CPY): New macros.
1623         (VASNPRINTF): Use PRINTF_FETCHARGS instead of printf_fetchargs. Use
1624         DCHAR_CPY. Handle the case that DCHAR_T and FCHAR_T are not the same
1625         type. Handle the case that TCHAR_T and FCHAR_T are not of the same
1626         size. Handle the case that DCHAR_T and TCHAR_T are not the same type,
1627         add a conversion from TCHAR_T[] to DCHAR_T[], and rework the padding
1628         code accordingly.
1629         (VASNPRINTF) [ENABLE_UNISTDIO]: Implement the 'U' directive. Enable
1630         pad_ourselves also in this case, with the 'c' and 's' directives, and
1631         with a different notion of "width".
1632         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): New macros.
1633
1634 2007-06-10  Bruno Haible  <bruno@clisp.org>
1635
1636         * modules/unistr/u32-mbsnlen: New file.
1637         * lib/unistr/u32-mbsnlen.c: New file.
1638
1639         * modules/unistr/u16-mbsnlen: New file.
1640         * lib/unistr/u16-mbsnlen.c: New file.
1641
1642         * modules/unistr/u8-mbsnlen: New file.
1643         * lib/unistr/u8-mbsnlen.c: New file.
1644
1645         * lib/unistr.h (u8_mbsnlen, u16_mbsnlen, u32_mbsnlen): New
1646         declarations.
1647
1648 2007-06-10  Bruno Haible  <bruno@clisp.org>
1649
1650         * lib/string_.h (mbsnlen): New declaration.
1651         * lib/mbsnlen.c: New file.
1652         * m4/mbsnlen.m4: New file.
1653         * modules/mbsnlen: New file.
1654         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set GNULIB_MBSNLEN.
1655         * modules/string (string.h): Substitute GNULIB_MBSNLEN.
1656         * MODULES.html.sh (Internationalization functions): Add mbsnlen.
1657
1658 2007-06-10  Bruno Haible  <bruno@clisp.org>
1659
1660         * lib/mbslen.c: Include <stdlib.h>, needed for MB_CUR_MAX.
1661
1662 2007-06-10  Bruno Haible  <bruno@clisp.org>
1663
1664         * lib/mbiter.h: Include <stddef.h>, needed for ptrdiff_t.
1665         * lib/mbuiter.h: Likewise.
1666
1667 2007-06-10  Bruno Haible  <bruno@clisp.org>
1668
1669         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Check for _snprintf
1670         declaration.
1671
1672 2007-06-10  Karl Berry  <karl@gnu.org>
1673
1674         * config/srclist.txt: remove gettext entries, Bruno prefers
1675         to update individually.
1676
1677 2007-06-10  Bruno Haible  <bruno@clisp.org>
1678
1679         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Remove variable
1680         'maxlen'. Ensure only length + width bytes are allocated, not
1681         length + 1 + width.
1682
1683 2007-06-09  Bruno Haible  <bruno@clisp.org>
1684
1685         * lib/vasnprintf.c (FCHAR_T, DCHAR_T, TCHAR_T): New macros.
1686         (CHAR_T): Remove macro.
1687         (VASNPRINTF): Update.
1688
1689 2007-06-09  Bruno Haible  <bruno@clisp.org>
1690
1691         * MODULES.html.sh (Unicode string functions): Add the new modules.
1692
1693         * modules/uniconv/u32-conv-to-enc: New file.
1694         * lib/uniconv/u32-conv-to-enc.c: New file.
1695         * modules/uniconv/u32-conv-to-enc-tests: New file.
1696         * tests/uniconv/test-u32-conv-to-enc.c: New file.
1697
1698         * modules/uniconv/u16-conv-to-enc: New file.
1699         * lib/uniconv/u16-conv-to-enc.c: New file.
1700         * lib/uniconv/u-conv-to-enc.h: New file.
1701         * modules/uniconv/u16-conv-to-enc-tests: New file.
1702         * tests/uniconv/test-u16-conv-to-enc.c: New file.
1703
1704         * modules/uniconv/u8-conv-to-enc: New file.
1705         * lib/uniconv/u8-conv-to-enc.c: New file.
1706         * modules/uniconv/u8-conv-to-enc-tests: New file.
1707         * tests/uniconv/test-u8-conv-to-enc.c: New file.
1708
1709         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
1710         u32_conv_to_encoding): New declarations.
1711
1712 2007-06-09  Bruno Haible  <bruno@clisp.org>
1713
1714         * tests/uniconv/test-u32-strconv-to-enc.c (main): Remove unused code.
1715
1716 2007-06-09  Bruno Haible  <bruno@clisp.org>
1717
1718         Rename 'allocsa' -> 'malloca', 'freesa' -> 'freea'.
1719         * modules/malloca: Renamed from modules/allocsa, updated.
1720         * lib/malloca.h: Renamed from lib/allocsa.h, updated.
1721         * lib/malloca.c: Renamed from lib/allocsa.c, updated.
1722         * lib/malloca.valgrind: Renamed from lib/allocsa.valgrind, updated.
1723         * m4/malloca.m4: Renamed from m4/allocsa.m4, updated.
1724         * modules/malloca-tests: Renamed from modules/allocsa-tests, updated.
1725         * tests/test-malloca.c: Renamed from tests/test-allocsa.c, updated.
1726         * modules/xmalloca: Renamed from modules/xallocsa, updated.
1727         * lib/xmalloca.h: Renamed from lib/xallocsa.h, updated.
1728         * lib/xmalloca.c: Renamed from lib/xallocsa.c, updated.
1729         * modules/c-strcasestr (Depends-on): Update.
1730         * lib/c-strcasestr.c: Update.
1731         * modules/c-strstr (Depends-on): Update.
1732         * lib/c-strstr.c: Update.
1733         * modules/canonicalize-lgpl (Depends-on): Update.
1734         * lib/canonicalize-lgpl.c: Update.
1735         * modules/clean-temp (Depends-on): Update.
1736         * lib/clean-temp.c: Update.
1737         * modules/csharpcomp (Depends-on): Update.
1738         * lib/csharpcomp.c: Update.
1739         * modules/csharpexec (Depends-on): Update.
1740         * lib/csharpexec.c: Update.
1741         * modules/javacomp (Depends-on): Update.
1742         * lib/javacomp.c: Update.
1743         * modules/javaexec (Depends-on): Update.
1744         * lib/javaexec.c: Update.
1745         * modules/mbscasestr (Depends-on): Update.
1746         * lib/mbscasestr.c: Update.
1747         * modules/mbsstr (Depends-on): Update.
1748         * lib/mbsstr.c: Update.
1749         * modules/setenv (Depends-on): Update.
1750         * lib/setenv.c: Update.
1751         * modules/strcasestr (Depends-on): Update.
1752         * lib/strcasestr.c: Update.
1753         * modules/striconveha (Depends-on): Update.
1754         * lib/striconveha.c: Update.
1755         * modules/relocatable-prog-wrapper (Files): Update.
1756         * lib/relocwrapper.c: Update.
1757         * build-aux/install-reloc: Update.
1758         * MODULES.html.sh (Memory management functions <stdlib.h>): Update.
1759
1760 2007-06-08  Bruno Haible  <bruno@clisp.org>
1761
1762         Port to uClibc.
1763         * lib/fbufmode.c (fbufmode): Add special code for uClibc.
1764         * lib/fpurge.c (fpurge): Likewise.
1765         * lib/freading.c (freading): Likewise.
1766         * lib/fseeko.c (rpl_fseeko): Likewise.
1767         * lib/fseterr.c (fseterr): Likewise.
1768         * lib/fwriting.c (fwriting): Likewise.
1769         * tests/test-fflush.c (main): Avoid a failure on uClibc.
1770
1771 2007-06-08  Bruno Haible  <bruno@clisp.org>
1772
1773         * m4/intlmacosx.m4: New file, extracted from gettext.m4.
1774         * m4/gettext.m4 (gt_INTL_MACOSX): Remove macro, moved to intlmacosx.m4.
1775         * modules/gettext (Files): Add m4/intlmacosx.m4.
1776
1777 2007-06-07  Bruno Haible  <bruno@clisp.org>
1778
1779         * modules/localename-tests: New file.
1780         * tests/test-localename.c: New file.
1781
1782         New module 'localename'.
1783         * lib/localename.h: New file.
1784         * lib/localename.c: New file, from GNU gettext.
1785         * m4/localename.m4: New file.
1786         * modules/localename: New file.
1787
1788 2007-06-07  Bruno Haible  <bruno@clisp.org>
1789
1790         Work around the lack of <wchar.h> on some builds of uClibc.
1791         * doc/headers/wchar.texi: Update.
1792         * lib/wchar_.h: Include <wchar.h> only if it exists.
1793         * m4/wchar.m4 (gl_WCHAR_H): Check for <wchar.h>. Set HAVE_WCHAR_H.
1794         * m4/stdint.m4 (gl_STDINT_H): Check for <wchar.h>.
1795         (gl_STDINT_TYPE_PROPERTIES): Don't try to include <wchar.h> if it
1796         doesn't exist.
1797         * modules/wchar (wchar.h): Substitute HAVE_WCHAR_H.
1798         * modules/mbfile (Depends-on): Add wchar.
1799         * modules/mbiter (Depends-on): Likewise.
1800         * modules/mbuiter (Depends-on): Likewise.
1801         Reported by Simon Josefsson.
1802
1803 2007-06-06  Paul Eggert  <eggert@cs.ucla.edu>
1804
1805         Work around problem reported by Steven M. Schweda in
1806         <http://lists.gnu.org/archive/html/bug-tar/2007-06/msg00002.html>:
1807         Tru64 5.1B with the Compaq compiler environment installed declares
1808         an 'isblank' function but does not define it in the C library.
1809         * lib/fnmatch.c (isblank): Check for HAVE_ISBLANK, too.
1810         * lib/regex_internal.h (isblank): Likewise.
1811         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for isblank existence.
1812         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
1813
1814 2007-06-05  Bruno Haible  <bruno@clisp.org>
1815
1816         Fix *printf so that it recognizes non-IEEE numbers on i386, x86_64,
1817         ia64.
1818         * modules/printf-safe: New file.
1819         * modules/fprintf-posix (Depends-on): Add printf-safe.
1820         * modules/printf-posix (Depends-on): Likewise.
1821         * modules/snprintf-posix (Depends-on): Likewise.
1822         * modules/sprintf-posix (Depends-on): Likewise.
1823         * modules/vasnprintf-posix (Depends-on): Likewise.
1824         * modules/vasprintf-posix (Depends-on): Likewise.
1825         * modules/vfprintf-posix (Depends-on): Likewise.
1826         * modules/vprintf-posix (Depends-on): Likewise.
1827         * modules/vsnprintf-posix (Depends-on): Likewise.
1828         * modules/vsprintf-posix (Depends-on): Likewise.
1829         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Require
1830         AC_C_BIGENDIAN. Define CHECK_PRINTF_SAFE if printf-safe is used. Test
1831         non-IEEE numbers on i386, x86_64, ia64. When cross-compiling, guess
1832         "no" on i386, x86_64, ia64.
1833         * tests/test-snprintf-posix.h (LDBL80_WORDS): New macro.
1834         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1835         on i386, x86_64, ia64.
1836         * tests/test-sprintf-posix.h (LDBL80_WORDS): New macro.
1837         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1838         on i386, x86_64, ia64.
1839         * tests/test-vasnprintf-posix.c: Include float.h.
1840         (LDBL80_WORDS): New macro.
1841         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1842         on i386, x86_64, ia64.
1843         * tests/test-vasprintf-posix.c: Include float.h.
1844         (LDBL80_WORDS): New macro.
1845         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
1846         on i386, x86_64, ia64.
1847         * tests/test-snprintf-posix.c: Include float.h.
1848         * tests/test-sprintf-posix.c: Likewise.
1849         * tests/test-vsnprintf-posix.c: Likewise.
1850         * tests/test-vsprintf-posix.c: Likewise.
1851
1852 2007-06-05  Bruno Haible  <bruno@clisp.org>
1853
1854         Fix isnanl so that it recognizes non-IEEE numbers on i386, x86_64, ia64.
1855         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Require AC_C_BIGENDIAN. Test
1856         non-IEEE numbers on i386, x86_64, ia64.
1857         (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require AC_C_BIGENDIAN.
1858         * lib/isnan.c (FUNC): Add special code for i386, x86_64, ia64.
1859         * tests/test-isnanl.h: Include float.h.
1860         (main): Check also non-IEEE numbers on i386, x86_64, ia64.
1861
1862 2007-06-05  Bruno Haible  <bruno@clisp.org>
1863
1864         * lib/vasnprintf.c (VASNPRINTF): Do the extra handling of NaN and Inf
1865         also the %a / %A. Handle the %a / %A code before this extra handling.
1866
1867 2007-06-05  Bruno Haible  <bruno@clisp.org>
1868
1869         * lib/vasnprintf.c [NEED_PRINTF_LONG_DOUBLE ||
1870         NEED_PRINTF_INFINITE_LONG_DOUBLE]: Include fpucw.h.
1871
1872 2007-06-05  Bruno Haible  <bruno@clisp.org>
1873
1874         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): Fix
1875         typo in variable name.
1876
1877 2007-06-05  Eric Blake  <ebb9@byu.net>
1878
1879         * m4/lseek.m4 (gl_FUNC_LSEEK): Work when cross-compiling.
1880         Reported by Simon Josefsson.
1881
1882 2007-06-04  Bruno Haible  <bruno@clisp.org>
1883
1884         Avoid test failures on some PowerPC platforms.
1885         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP):
1886         Define differently for PowerPC.
1887         * tests/test-frexpl.c (MIN_NORMAL_EXP): Likewise.
1888         Reported by Gary V. Vaughan <gary@gnu.org>.
1889
1890 2007-06-02  Bruno Haible  <bruno@clisp.org>
1891
1892         Fix test-stdint failure on FreeBSD/ia64.
1893         * m4/stdint.m4 (gl_STDINT_H): Check the values of PTRDIFF_MIN,
1894         PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN,
1895         WCHAR_MAX, WINT_MIN, WINT_MAX entirely, not only for plausibility.
1896         * doc/headers/stdint.texi: Update.
1897
1898 2007-06-01  Bruno Haible  <bruno@clisp.org>
1899
1900         * tests/test-binary-io.c (main): Pass a third argument to open().
1901         Reported by Gary V. Vaughan <gary@gnu.org>.
1902
1903 2007-06-01  Bruno Haible  <bruno@clisp.org>
1904
1905         * doc/functions/frexpl.texi: Update for mingw.
1906
1907 2007-06-01  Bruno Haible  <bruno@clisp.org>
1908
1909         * tests/test-lseek.c (main): Disable test of errno for invalid third
1910         argument.
1911         * doc/functions/lseek.texi: Update.
1912         Reported by Gary V. Vaughan <gary@gnu.org>.
1913
1914 2007-05-28  Bruno Haible  <bruno@clisp.org>
1915
1916         * m4/intl.m4 (AM_INTL_SUBDIR): Substitute variables WOE32, WINDRES.
1917
1918 2007-05-31  Eric Blake  <ebb9@byu.net>
1919
1920         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Guess no on mingw when
1921         cross compiling.
1922
1923 2007-05-30  Eric Blake  <ebb9@byu.net>
1924         and Bruno Haible  <bruno@clisp.org>
1925
1926         Work around mingw test failures exposed by m4-1.4.9b.
1927         * m4/stdint.m4 (gl_STDINT_H): Detect mingw bug.
1928         * tests/test-unistd.c: Disable uid_t and git_t tests for the
1929         moment.
1930
1931 2007-05-30  Bruno Haible  <bruno@clisp.org>
1932
1933         * tests/test-lseek.c: Explicitly close file descriptors 0 and 1 before
1934         assuming that they are closed. Needed on HP-UX 11.
1935
1936 2007-05-29  Bruno Haible  <bruno@clisp.org>
1937
1938         Fix a problem with #include_next.
1939         * lib/dirent_.h: Split the double-inclusion guard.
1940         * lib/fcntl_.h: Likewise.
1941         * lib/float_.h: Likewise.
1942         * lib/iconv_.h: Likewise.
1943         * lib/inttypes_.h: Likewise.
1944         * lib/locale_.h: Likewise.
1945         * lib/math_.h: Likewise.
1946         * lib/netinet_in_.h: Likewise.
1947         * lib/search_.h: Likewise.
1948         * lib/signal_.h: Likewise.
1949         * lib/stdint_.h: Likewise.
1950         * lib/stdio_.h: Likewise.
1951         * lib/stdlib_.h: Likewise.
1952         * lib/string_.h: Likewise.
1953         * lib/sys_select_.h: Likewise.
1954         * lib/sys_socket_.h: Likewise.
1955         * lib/sys_stat_.h: Likewise.
1956         * lib/sys_time_.h: Likewise.
1957         * lib/sysexits_.h: Likewise.
1958         * lib/time_.h: Likewise.
1959         * lib/unistd_.h: Likewise.
1960         * lib/wchar_.h: Likewise.
1961         * lib/wctype_.h: Likewise.
1962
1963 2007-05-29  Bruno Haible  <bruno@clisp.org>
1964
1965         * tests/test-unistd.c: Disable the tests for useconds_t and intptr_t
1966         for the moment.
1967
1968 2007-05-29  Bruno Haible  <bruno@clisp.org>
1969
1970         * m4/isnan.m4 (gl_DOUBLE_EXPONENT_LOCATION): Silence the AC_C_BIGENDIAN
1971         invocation.
1972         Reported by Eric Blake.
1973
1974 2007-05-29  Bruno Haible  <bruno@clisp.org>
1975
1976         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Fix typo in cross-
1977         compiling case.
1978
1979 2007-05-29  Eric Blake  <ebb9@byu.net>
1980             Bruno Haible  <bruno@clisp.org>
1981
1982         * m4/isnanf.m4 (gl_FUNC_ISNANF_NO_LIBM): Avoid syntax error on
1983         cross compiles.
1984
1985 2007-05-28  Eric Blake  <ebb9@byu.net>
1986
1987         * modules/closein-tests (test_closein_LDADD): Support test on
1988         cygwin with libtool.
1989
1990 2007-05-28  Bruno Haible  <bruno@clisp.org>
1991
1992         * tests/uniconv/test-u16-conv-from-enc.c: Remove #ifdef HAVE_CONFIG_H.
1993         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
1994         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
1995         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
1996         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
1997         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
1998         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
1999         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
2000         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
2001
2002 2007-05-28  Eric Blake  <ebb9@byu.net>
2003
2004         Unconditionally include <config.h> in unit tests.
2005         * tests/test-alloca-opt.c: Remove #ifdef HAVE_CONFIG_H.
2006         * tests/test-allocsa.c, tests/test-arcfour.c,
2007         tests/test-arctwo.c, tests/test-argmatch.c, tests/test-argp.c,
2008         tests/test-array_list.c, tests/test-array_oset.c,
2009         tests/test-atexit.c, test-avltree_list.c, test-avltree_oset.c,
2010         test-avltreehash_list.c, test-base64.c, test-binary-io.c,
2011         test-c-ctype.c, test-c-strcasecmp.c, test-c-strcasestr.c,
2012         test-c-strncasecmp.c, test-c-strstr.c, test-canonicalize-lgpl.c,
2013         test-carray_list.c, test-crc.c, test-des.c, test-dirname.c,
2014         test-fflush.c, test-fprintf-posix.c, test-gc-arcfour.c,
2015         test-gc-arctwo.c, test-gc-des.c, test-gc-hmac-md5.c,
2016         test-gc-hmac-sha1.c, test-gc-md2.c, test-gc-md4.c, test-gc-md5.c,
2017         test-gc-pbkdf2-sha1.c, test-gc-rijndael.c, test-gc-sha1.c,
2018         test-gc.c, test-getpass.c, test-hmac-md5.c, test-hmac-sha1.c,
2019         test-iconv.c, test-linked_list.c, test-linkedhash_list.c,
2020         test-lock.c, test-mbscasecmp.c, test-mbscasestr1.c,
2021         test-mbscasestr2.c, test-mbscasestr3.c, test-mbscasestr4.c,
2022         test-mbschr.c, test-mbscspn.c, test-mbsncasecmp.c, test-mbspbrk.c,
2023         test-mbspcasecmp.c, test-mbsrchr.c, test-mbsspn.c, test-mbsstr1.c,
2024         test-mbsstr2.c, test-mbsstr3.c, test-md2.c, test-md4.c,
2025         test-md5.c, test-memmem.c, test-printf-posix.c,
2026         test-rbtree_list.c, test-rbtree_oset.c, test-rbtreehash_list.c,
2027         test-read-file.c, test-rijndael.c, test-snprintf-posix.c,
2028         test-snprintf.c, test-sprintf-posix.c, test-stdint.c,
2029         test-strcasestr.c, test-striconv.c, test-striconveh.c,
2030         test-striconveha.c, test-tls.c, test-vasnprintf-posix.c,
2031         test-vasnprintf-posix2.c, test-vasnprintf.c,
2032         test-vasprintf-posix.c, test-vasprintf.c, test-verify.c,
2033         test-vfprintf-posix.c, test-vprintf-posix.c,
2034         test-vsnprintf-posix.c, test-vsnprintf.c, test-vsprintf-posix.c,
2035         test-xvasprintf.c: Likewise.
2036
2037 2007-05-28  Bruno Haible  <bruno@clisp.org>
2038
2039         * gnulib-tool (func_import): Remember the --with-tests command-line
2040         option through the macro gl_WITH_TESTS in the gnulib-cache.m4.
2041         Reported by Eric Blake.
2042
2043 2007-05-28  Bruno Haible  <bruno@clisp.org>
2044
2045         * modules/ftell-tests: New file.
2046         * tests/test-ftell.c: New file, based on tests/test-ftello.c.
2047         * tests/test-ftell.sh: New file, based on tests/test-ftello.sh.
2048
2049         * lib/ftell.c: New file.
2050         * modules/ftell: New file.
2051         * m4/ftell.m4: New file.
2052         * doc/functions/ftell.texi: Update.
2053         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELL,
2054         REPLACE_FTELL.
2055         * lib/stdio_.h (rpl_ftell): New declaration.
2056         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELL,
2057         REPLACE_FTELL.
2058
2059 2007-05-28  Eric Blake  <ebb9@byu.net>
2060
2061         * lib/allocsa.h (safe_alloca): Avoid compiler warning.
2062
2063 2007-05-28  Bruno Haible  <bruno@clisp.org>
2064
2065         * modules/fseek-tests: New file.
2066         * tests/test-fseek.c: New file, based on tests/test-fseeko.c.
2067         * tests/test-fseek.sh: New file, based on tests/test-fseeko.sh.
2068
2069         * lib/fseek.c: New file.
2070         * modules/fseek: New file.
2071         * m4/fseek.m4: New file.
2072         * doc/functions/fseek.texi: Update.
2073         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEK,
2074         REPLACE_FSEEK.
2075         * lib/stdio_.h (rpl_fseek): New declaration.
2076         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEK,
2077         REPLACE_FSEEK.
2078
2079 2007-05-28  Bruno Haible  <bruno@clisp.org>
2080
2081         * lib/stdio_.h (fflush): More comments.
2082
2083 2007-05-28  Bruno Haible  <bruno@clisp.org>
2084
2085         * m4/lseek.m4 (gl_FUNC_LSEEK): When not cross-compiling, perform a real
2086         runtime test.
2087
2088 2007-05-28  Eric Blake  <ebb9@byu.net>
2089
2090         Improve lseek module.
2091         * lib/lseek.c (rpl_lseek): Detect EBADF on mingw.
2092         * lib/unistd_.h (lseek): Scale back link warning message.
2093         * tests/test-lseek.c: Beef up test.
2094         * tests/test-lseek.sh: Exercise more facets of lseek.
2095         Reported by Bruno Haible.
2096
2097 2007-05-28  Bruno Haible  <bruno@clisp.org>
2098
2099         * tests/test-unistd.c: Test all the types that <unistd.h> is expected
2100         to define.
2101
2102 2007-05-27  Bruno Haible  <bruno@clisp.org>
2103
2104         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-31 patch.
2105
2106 2007-05-27  Bruno Haible  <bruno@clisp.org>
2107
2108         * modules/openmp: New file.
2109         * m4/openmp.m4: New file, taken from autoconf's CVS with changes by
2110         Noah Misch.
2111
2112 2007-05-26  Bruno Haible  <bruno@clisp.org>
2113
2114         * modules/chdir-long (Depends-on): Add fchdir.
2115         * modules/chdir-safer (Depends-on): Likewise.
2116         * modules/fts (Depends-on): Likewise.
2117         * modules/fts-lgpl (Depends-on): Likewise.
2118         * modules/openat (Depends-on): Likewise.
2119         * modules/savewd (Depends-on): Likewise.
2120
2121 2007-05-24  Eric Blake  <ebb9@byu.net>
2122
2123         Fix lseek on mingw.
2124         * modules/lseek: New module.
2125         * m4/lseek.m4: New file.
2126         * lib/lseek.c: New file.
2127         * modules/lseek-tests: New file.
2128         * tests/test-lseek.c: New file.
2129         * tests/test-lseek.sh: New file.
2130         * MODULES.html.sh: Document lseek module.
2131         * modules/fflush (Depends-on): Add lseek, fseeko.
2132         * modules/fseeko (Depends-on): Likewise.
2133         * modules/ftello (Depends-on): Likewise.
2134         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Replace fseek[o] if lseek is
2135         broken.
2136         * m4/ftello.m4 (gl_FUNC_FTELLO): Replace ftell[o] if lseek is
2137         broken.
2138         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Trigger fseeko module.
2139         * lib/fseeko.c (rpl_fseeko): Quit early on non-seekable files.
2140         * lib/ftello.c (rpl_ftello): Likewise.
2141         * tests/test-fseeko.c (main): Test this.
2142         * tests/test-fseeko.sh: Likewise.
2143         * tests/test-ftello.c (main): Likewise.
2144         * tests/test-ftello.sh: Likewise.
2145         * lib/stdio_.h (fseek, ftell): Simplify, since missing fseeko now
2146         implies replacing fseek.
2147         * modules/stdio (Makefile.am): No longer need HAVE_FSEEKO,
2148         HAVE_FTELLO.
2149         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add lseek info.
2150         * modules/unistd (Makefile.am): Likewise.
2151         * lib/unistd_.h (lseek): Declare a replacement.
2152         * doc/functions/lseek.texi (lseek): Document this fix.
2153         * doc/functions/fseek.texi (fseek): Likewise.
2154         * doc/functions/ftell.texi (ftell): Likewise.
2155
2156 2007-05-24  Bruno Haible  <bruno@clisp.org>
2157
2158         * tests/test-vasnprintf-posix.c (test_function): Allow up to 50 bytes
2159         in the printed representation of a NaN.
2160         * tests/test-vasprintf-posix.c (test_function): Likewise.
2161         * tests/test-snprintf-posix.h (test_function): Likewise.
2162         * tests/test-sprintf-posix.h (test_function): Likewise.
2163         Reported by Eric Blake.
2164
2165 2007-05-23  Eric Blake  <ebb9@byu.net>
2166
2167         Fix fseeko/ftello on cygwin 1.5.24.
2168         * doc/functions/fseeko.texi (fseeko): Document the fix.
2169         * doc/functions/ftello.texi (ftello): Document the fix.
2170         * doc/functions/stdin.texi (stdin): Document the cygwin bug.
2171         * doc/functions/stdout.text (stdout): New file.
2172         * doc/functions/stderr.text (stderr): New file.
2173         * doc/gnulib.texi (Function Substitutes): Use new files.
2174         * tests/test-fseeko.c (main): Check for broken fseeko on cygwin
2175         prior to 1.7.0.
2176         * tests/test-ftello.c (main): Likewise for ftello.
2177         * tests/test-fseeko.sh: New file.
2178         * tests/test-ftello.sh: New file.
2179         * modules/fseeko-tests (Makefile.am): Ensure test-fseeko is run
2180         with seekable stdin.
2181         * modules/ftello-tests (Makefile.am): Likewise for test-ftello.
2182         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Detect the cygwin bug.
2183         (gl_REPLACE_FSEEKO): New macro.
2184         * m4/ftello.m4 (gl_FUNC_FTELLO, gl_REPLACE_FTELLO): Likewise.
2185         * modules/fseeko (Files): Distribute fseeko.c.
2186         * modules/ftello (Files): Distribute ftello.c.
2187         * lib/fseeko.c (rpl_fseeko) [__CYGWIN__]: Convert stdin to 64-bit
2188         mode.
2189         * lib/ftello.c (rpl_ftello): New file.
2190         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Allow replacement of
2191         fseeko, ftello.
2192         (gl_STDIN_LARGE_OFFSET): New macro.
2193         * modules/stdio (Makefile.am): Perform the replacement.
2194         * lib/stdio_.h (rpl_fseeko, rpl_ftello): Define when needed.
2195
2196 2007-05-23  Bruno Haible  <bruno@clisp.org>
2197
2198         * lib/stdio_.h (fseeko, ftello): Provide a link warning only if
2199         GNULIB_POSIXCHECK is defined.
2200
2201 2007-05-21  Bruno Haible  <bruno@clisp.org>
2202
2203         * m4/printf.m4 (gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE):
2204         Check also the output for NaN arguments. When cross-compiling, guess
2205         no on IRIX.
2206         * lib/vasnprintf.c: Update comments.
2207         * tests/test-vasnprintf-posix.c (strisnan): New function.
2208         (test_function): Use it.
2209         * tests/test-vasprintf-posix.c (strisnan): New function.
2210         (test_function): Use it.
2211         * tests/test-snprintf-posix.h (strisnan): New function.
2212         (test_function): Use it.
2213         * tests/test-sprintf-posix.h (strisnan): New function.
2214         (test_function): Use it.
2215         Reported by Eric Blake.
2216
2217 2007-05-20  Bruno Haible  <bruno@clisp.org>
2218
2219         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Add test for large finite
2220         numbers that fails on BeOS.
2221         * doc/functions/frexpl.texi: Update.
2222
2223 2007-05-20  Jim Meyering  <jim@meyering.net>
2224
2225         * NEWS: Mention the incompatible change (s/futimens/gl_futimens/)
2226         forced upon us by glibc-2.6.
2227
2228 2007-05-20  Bruno Haible  <bruno@clisp.org>
2229
2230         Fix *printf result for NaN, Inf on AIX, Solaris, OSF/1.
2231         * m4/printf.m4 (gl_PRINTF_INFINITE): Update cross-compiling guesses.
2232         (gl_PRINTF_INFINITE_LONG_DOUBLE): New macro.
2233         * lib/vasnprintf.c: Use NEED_PRINTF_INFINITE_DOUBLE instead of
2234         NEED_PRINTF_INFINITE.
2235         (is_infinitel): New function.
2236         (VASNPRINTF): Handle NEED_PRINTF_INFINITE_LONG_DOUBLE case.
2237         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE): Renamed from
2238         gl_PREREQ_VASNPRINTF_INFINITE.
2239         (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): New macro.
2240         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
2241         gl_PRINTF_INFINITE_LONG_DOUBLE and test its result. Invoke
2242         gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE and
2243         gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE instead of
2244         gl_PREREQ_VASNPRINTF_INFINITE.
2245         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
2246         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2247         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2248         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2249         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2250         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2251         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2252         * doc/functions/fprintf.texi: Update.
2253         * doc/functions/printf.texi: Update.
2254         * doc/functions/snprintf.texi: Update.
2255         * doc/functions/sprintf.texi: Update.
2256         * doc/functions/vfprintf.texi: Update.
2257         * doc/functions/vprintf.texi: Update.
2258         * doc/functions/vsnprintf.texi: Update.
2259         * doc/functions/vsprintf.texi: Update.
2260
2261 2007-05-20  Bruno Haible  <bruno@clisp.org>
2262
2263         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): Set REPLACE_FREXPL if frexpl
2264         was not found in libc.
2265         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
2266
2267 2007-05-20  Bruno Haible  <bruno@clisp.org>
2268
2269         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
2270         printed as "-nan" instead of "nan".
2271         * tests/test-vasprintf-posix.c (test_function): Likewise.
2272         * tests/test-snprintf-posix.h (test_function): Likewise.
2273         * tests/test-sprintf-posix.h (test_function): Likewise.
2274         Needed for HP-UX 11.
2275
2276 2007-05-20  Jim Meyering  <jim@meyering.net>
2277
2278         Fix buggy test for the fchownat-deref bug.
2279         * m4/openat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Create the dangling
2280         symlink required for the run-test.  Without it, this test would
2281         always declare that fchownat doesn't work, and client code would
2282         unnecessarily use the replacement function with fixed libc.
2283         (gl_FUNC_FCHOWNAT): Eliminate a variable that wasn't initialized.
2284         Reported by Greg Schafer.
2285
2286 2007-05-19  Bruno Haible  <bruno@clisp.org>
2287
2288         * m4/isnanf.m4 (gl_ISNANF_WORKS): New macro.
2289         (gl_FUNC_ISNANF_NO_LIBM): Invoke it.
2290         * lib/isnan.c (FUNC): Use run-time expressions for SGI compiler.
2291         Needed for IRIX 6.5 and Solaris 2.5.1.
2292
2293 2007-05-19  Bruno Haible  <bruno@clisp.org>
2294
2295         * tests/test-vasnprintf-posix.c (have_minus_zero): New function.
2296         (test_function): Skip tests involving -0.0 on platforms where
2297         -0.0 = 0.0.
2298         * tests/test-vasprintf-posix.c (have_minus_zero): New function.
2299         (test_function): Skip tests involving -0.0 on platforms where
2300         -0.0 = 0.0.
2301         * tests/test-snprintf-posix.h (have_minus_zero): New function.
2302         (test_function): Skip tests involving -0.0 on platforms where
2303         -0.0 = 0.0.
2304         * tests/test-sprintf-posix.h (have_minus_zero): New function.
2305         (test_function): Skip tests involving -0.0 on platforms where
2306         -0.0 = 0.0.
2307         * tests/test-fprintf-posix.h (test_function): Remove all -0.0 related
2308         tests.
2309         * tests/test-printf-posix.h (test_function): Likewise.
2310         * tests/test-printf-posix.output: Remove all -0.0 related results.
2311         Needed for IRIX 6.5.
2312
2313 2007-05-19  Bruno Haible  <bruno@clisp.org>
2314
2315         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
2316         printed as "nan0x7fffffff" instead of "nan".
2317         * tests/test-vasprintf-posix.c (test_function): Likewise.
2318         * tests/test-snprintf-posix.h (test_function): Likewise.
2319         * tests/test-sprintf-posix.h (test_function): Likewise.
2320         * tests/test-fprintf-posix.h (NaN): Remove macro.
2321         (test_function): Remove all NaN related tests.
2322         * tests/test-printf-posix.h (NaN): Remove macro.
2323         (test_function): Remove all NaN related tests.
2324         * tests/test-printf-posix.output: Remove all NaN related results.
2325         Needed for IRIX 6.5.
2326
2327 2007-05-19  Bruno Haible  <bruno@clisp.org>
2328
2329         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Fix C89 syntax error in test code.
2330         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
2331
2332 2007-05-19  Bruno Haible  <bruno@clisp.org>
2333
2334         * lib/float_.h: New file.
2335         * m4/float_h.m4: New file.
2336         * modules/float: New file.
2337         * modules/isnanl (Dependencies): Add float.
2338         * modules/isnanl-nolibm (Dependencies): Likewise.
2339         * modules/mathl (Dependencies): Likewise.
2340         * modules/printf-frexpl (Dependencies): Likewise.
2341         * modules/signbit (Dependencies): Likewise.
2342         * modules/vasnprintf (Dependencies): Likewise.
2343         * doc/headers/float.texi: Update.
2344
2345 2007-05-19  Jim Meyering  <jim@meyering.net>
2346
2347         * lib/utimens.c (gl_futimens): Rename from futimens,
2348         now that glibc-2.6 declares futimens.
2349         * lib/utimens.h: Likewise.
2350
2351 2007-05-19  Bruno Haible  <bruno@clisp.org>
2352
2353         Avoid test failures on mingw.
2354         * tests/test-fprintf-posix.sh: Convert CR/LF to LF in output.
2355         * tests/test-printf-posix.sh: Likewise.
2356         * tests/test-vfprintf-posix.sh: Likewise.
2357         * tests/test-vprintf-posix.sh: Likewise.
2358
2359 2007-05-19  Bruno Haible  <bruno@clisp.org>
2360
2361         Fix *printf result for NaN, Inf, -0.0 on mingw.
2362         * m4/printf.m4 (gl_PRINTF_INFINITE): New macro.
2363         * lib/vasnprintf.c: Include math.h and isnan.h.
2364         (is_infinite_or_zero): New function.
2365         (VASNPRINTF): Fix also the handling of infinite or zero 'double'
2366         values in the %f, %F, %e, %E, %g, %G directives.
2367         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE): New macro.
2368         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
2369         gl_PRINTF_INFINITE and test its result. Invoke
2370         gl_PREREQ_VASNPRINTF_INFINITE.
2371         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
2372         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2373         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2374         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2375         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2376         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2377         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2378         * doc/functions/fprintf.texi: Update.
2379         * doc/functions/printf.texi: Update.
2380         * doc/functions/snprintf.texi: Update.
2381         * doc/functions/sprintf.texi: Update.
2382         * doc/functions/vfprintf.texi: Update.
2383         * doc/functions/vprintf.texi: Update.
2384         * doc/functions/vsnprintf.texi: Update.
2385         * doc/functions/vsprintf.texi: Update.
2386
2387 2007-05-19  Bruno Haible  <bruno@clisp.org>
2388
2389         * lib/vasnprintf.c (convert_to_decimal): Add an extra_zeroes argument.
2390         (scale10_round_decimal_long_double): Inline scale10_round_long_double.
2391         Instead of multiplying with 10^k, set extra_zeroes to k.
2392         (scale10_round_long_double): Remove function.
2393
2394 2007-05-18  Bruno Haible  <bruno@clisp.org>
2395
2396         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Fix logic bug
2397         introduced on 2007-05-06.
2398
2399 2007-05-18  Bruno Haible  <bruno@clisp.org>
2400
2401         * tests/test-vasnprintf-posix.c (test_function): Also test the %e and
2402         %g directives.
2403         * tests/test-vasprintf-posix.c (test_function): Likewise.
2404         * tests/test-snprintf-posix.h (test_function): Likewise.
2405         * tests/test-sprintf-posix.h (test_function): Likewise.
2406
2407 2007-05-18  Bruno Haible  <bruno@clisp.org>
2408
2409         * tests/test-vasnprintf-posix.c (SIZEOF): New macro.
2410         (strmatch): New function.
2411         (test_function): Test the %f directive on numbers of various exponents.
2412         * tests/test-vasprintf-posix.c (SIZEOF): New macro.
2413         (strmatch): New function.
2414         (test_function): Test the %f directive on numbers of various exponents.
2415         * tests/test-snprintf-posix.h (strmatch): New function.
2416         (test_function): Test the %f directive on numbers of various exponents.
2417         * tests/test-sprintf-posix.h (strmatch): New function.
2418         (test_function): Test the %f directive on numbers of various exponents.
2419         * tests/test-snprintf-posix.c (SIZEOF): New macro.
2420         * tests/test-sprintf-posix.c (SIZEOF): New macro.
2421         * tests/test-vsnprintf-posix.c (SIZEOF): New macro.
2422         * tests/test-vsprintf-posix.c (SIZEOF): New macro.
2423
2424 2007-05-18  Bruno Haible  <bruno@clisp.org>
2425
2426         Add support for 'long double' number output.
2427         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE): New macro.
2428         * lib/vasnprintf.c: Include math.h and float+.h.
2429         (mp_limb_t): New type.
2430         (GMP_LIMB_BITS): New macro.
2431         (mp_twolimb_t): New type.
2432         (GMP_TWOLIMB_BITS): New macro.
2433         (mpn_t): New type.
2434         (multiply, divide, convert_to_decimal, decode_long_double,
2435         scale10_round_long_double, scale10_round_decimal_long_double,
2436         floorlog10l): New functions.
2437         (VASNPRINTF) [NEED_PRINTF_LONG_DOUBLE]: Implement 'long double' support
2438         for the %f, %F, %e, %E, %g, %G directives.
2439         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_LONG_DOUBLE): New macro.
2440         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
2441         gl_PRINTF_LONG_DOUBLE and test its result. Invoke
2442         gl_PREREQ_VASNPRINTF_LONG_DOUBLE.
2443         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
2444         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2445         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2446         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2447         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2448         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2449         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2450         * modules/fprintf-posix (Depends-on): Add frexpl-nolibm.
2451         * modules/snprintf-posix (Depends-on): Likewise.
2452         * modules/sprintf-posix (Depends-on): Likewise.
2453         * modules/vasnprintf-posix (Depends-on): Likewise.
2454         * modules/vasprintf-posix (Depends-on): Likewise.
2455         * modules/vfprintf-posix (Depends-on): Likewise.
2456         * modules/vsnprintf-posix (Depends-on): Likewise.
2457         * modules/vsprintf-posix (Depends-on): Likewise.
2458         * modules/vasnprintf (Files): Add lib/float+.h.
2459         * doc/functions/fprintf.texi: Update.
2460         * doc/functions/printf.texi: Update.
2461         * doc/functions/snprintf.texi: Update.
2462         * doc/functions/sprintf.texi: Update.
2463         * doc/functions/vfprintf.texi: Update.
2464         * doc/functions/vprintf.texi: Update.
2465         * doc/functions/vsnprintf.texi: Update.
2466         * doc/functions/vsprintf.texi: Update.
2467
2468 2007-05-18  Bruno Haible  <bruno@clisp.org>
2469
2470         * lib/vasnprintf.c (USE_SNPRINTF): Define to 0 on BeOS.
2471
2472 2007-05-18  Bruno Haible  <bruno@clisp.org>
2473
2474         * lib/vasnprintf.c (VASNPRINTF) [WIN32]: Use %I64d instead of %lld
2475         for printing 64-bit integers. Needed for mingw.
2476
2477 2007-05-18  Bruno Haible  <bruno@clisp.org>
2478
2479         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
2480         gl_FUNC_FREXPL_WORKS.
2481         * modules/printf-frexpl (Files): Add m4/frexpl.m4.
2482
2483 2007-05-18  Bruno Haible  <bruno@clisp.org>
2484
2485         * modules/frexpl-nolibm-tests: New file.
2486
2487         * modules/frexpl-nolibm: New file.
2488         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): New macro.
2489
2490 2007-05-17  Paul Eggert  <eggert@cs.ucla.edu>
2491
2492         * lib/dirent_.h: Prefer #include_next <foo.h> to #include
2493         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
2494         GCC 4.2, which otherwise issues a lot of warnings.
2495         * lib/iconv_.h, lib/locale_.h, lib/netinet_in_.h, lib/sys_select_.h:
2496         * lib/sys_socket_.h, lib/sys_stat_.h, lib/sysexits_.h, lib/unistd_.h:
2497         Likewise.
2498         * modules/fchdir (dirent.h): Substitute @HAVE_INCLUDE_NEXT@.
2499         * modules/iconv_open (iconv.h): Likewise.
2500         * modules/locale (locale.h): Likewise.
2501         * modules/netinet_in (netinet/in.h): Likewise.
2502         * modules/sys_select (sys_select.h): Likewise.
2503         * modules/sys_socket (sys/socket.h): Likewise.
2504         * modules/sys_stat (sys/stat.h): Likewise.
2505         * modules/sysexits (sysexits.h): Likewise.
2506         * modules/unistd (unistd.h): Likewise.
2507
2508 2007-05-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2509
2510         * modules/closein-tests (Makefile.am): Distribute
2511         `test-closein.sh'.
2512
2513 2007-05-17  Bruno Haible  <bruno@clisp.org>
2514
2515         * tests/test-printf-posix.output: Renamed from
2516         tests/test-fprintf-posix.out.
2517         * modules/fprintf-posix-tests: Update.
2518         * modules/printf-posix-tests: Update.
2519         * modules/vfprintf-posix-tests: Update.
2520         * modules/vprintf-posix-tests: Update.
2521         * tests/test-fprintf-posix.sh: Update.
2522         * tests/test-printf-posix.sh: Update.
2523         * tests/test-vfprintf-posix.sh: Update.
2524         * tests/test-vprintf-posix.sh: Update.
2525         Reported by Ralf Wildenhues.
2526
2527 2007-05-16  Paul Eggert  <eggert@cs.ucla.edu>
2528
2529         * lib/fcntl_.h: Prefer #include_next <foo.h> to #include
2530         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
2531         GCC 4.2, which otherwise issues a lot of warnings.
2532         * lib/inttypes_.h, lib/math_.h, lib/search_.h, lib/signal_.h:
2533         * lib/stdint_.h, lib/stdio_.h, lib/stdlib_.h, lib/string_.h:
2534         * lib/sys_time_.h, lib/time_.h, lib/wchar_.h, lib/wctype_.h: Likewise.
2535         * lib/stdlib_.h: Don't bother with #pragma GCC system_header, as
2536         it should no longer be needed.
2537         * lib/string_.h: Likewise.
2538         * modules/absolute-header (HAVE_INCLUDE_NEXT): New 'make' define.
2539         * modules/fcntl (fcntl.h): Substitute @HAVE_INCLUDE_NEXT@.
2540         * modules/inttypes (inttypes.h): Likewise.
2541         * modules/math (math.h): Likewise.
2542         * modules/search (search.h): Likewise.
2543         * modules/signal (signal.h): Likewise.
2544         * modules/stdint (stdint.h): Likewise.
2545         * modules/stdio (stdio.h): Likewise.
2546         * modules/stdlib (stdlib.h): Likewise.
2547         * modules/string (string.h): Likewise.
2548         * modules/sys_time (sys/time.h): Likewise.
2549         * modules/time (time.h): Likewise.
2550         * modules/wchar (wchar.h): Likewise.
2551         * modules/wctype (wtype.h): Likewise.
2552
2553 2007-05-16  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
2554
2555         * doc/gnulib-tool.texi (CVS Issues): Fix typo.
2556
2557 2007-05-13  Bruno Haible  <bruno@clisp.org>
2558
2559         * stpcpy.m4 (gl_FUNC_STPCPY): Require AC_C_RESTRICT.
2560         * stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
2561         * strsep.m4 (gl_FUNC_STRSEP): Likewise.
2562         * strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
2563         (gl_PREREQ_STRTOK_R): Don't require it here.
2564
2565 2007-05-13  Bruno Haible  <bruno@clisp.org>
2566
2567         * lib/stdlib_.h (mkdtemp, mkstemp): Comment out argument name. Needed
2568         when used in C++ mode.
2569
2570 2007-05-12  Bruno Haible  <bruno@clisp.org>
2571
2572         * lib/linebuffer.h: Tweak doc.
2573         * lib/linebuffer.c: Likewise.
2574
2575 2007-05-12  James Youngman  <jay@gnu.org>
2576
2577         * lib/linebuffer.c (readlinebuffer_delim): New function,
2578         like readlinebuffer, but use a caller-specified delimiter.
2579         (readlinebuffer): Just call readlinebuffer_delim with '\n'
2580         as the delimiter.
2581         * lib/linebuffer.h (readlinebuffer_delim): Declare it.
2582
2583 2007-05-12  Sergey Poznyakoff  <gray@gnu.org.ua>
2584
2585         * m4/openat.m4 (gl_FUNC_OPENAT): Do not require openat-die.
2586         * modules/openat (Files): Remove openat-die.c.
2587         (Depends-on): Add openat-die.
2588         * modules/openat-die: New module.
2589
2590 2007-05-06  Bruno Haible  <bruno@clisp.org>
2591
2592         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING, gl_VSNPRINTF_ZEROSIZE_C99):
2593         Update with info about Cygwin.
2594         * doc/functions/fprintf.texi: Update.
2595         * doc/functions/printf.texi: Update.
2596         * doc/functions/snprintf.texi: Update.
2597         * doc/functions/sprintf.texi: Update.
2598         * doc/functions/vfprintf.texi: Update.
2599         * doc/functions/vprintf.texi: Update.
2600         * doc/functions/vsnprintf.texi: Update.
2601         * doc/functions/vsprintf.texi: Update.
2602         Reported by Eric Blake.
2603
2604 2007-05-06  Bruno Haible  <bruno@clisp.org>
2605
2606         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Perform the
2607         padding ourselves for the floating-point directives.
2608         * m4/printf.m4 (gl_PRINTF_FLAG_ZERO): New macro.
2609         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ZERO): New macro.
2610         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2611         gl_PRINTF_FLAG_ZERO and test its result. Invoke
2612         gl_PREREQ_VASNPRINTF_FLAG_ZERO.
2613         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2614         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
2615         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2616         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2617         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2618         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2619         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2620         * tests/test-snprintf-posix.h (test_function): Also check the width
2621         and some flags in the %f directive.
2622         * tests/test-sprintf-posix.h (test_function): Likewise.
2623         * tests/test-vasnprintf-posix.c (test_function): Likewise.
2624         * tests/test-vasprintf-posix.c (test_function): Likewise.
2625         * doc/functions/fprintf.texi: Update.
2626         * doc/functions/printf.texi: Update.
2627         * doc/functions/snprintf.texi: Update.
2628         * doc/functions/sprintf.texi: Update.
2629         * doc/functions/vfprintf.texi: Update.
2630         * doc/functions/vprintf.texi: Update.
2631         * doc/functions/vsnprintf.texi: Update.
2632         * doc/functions/vsprintf.texi: Update.
2633
2634 2007-05-06  Bruno Haible  <bruno@clisp.org>
2635
2636         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_GROUPING]: Don't
2637         pass the ' flag character to sprintf or snprintf.
2638         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING): New macro.
2639         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_GROUPING): New macro.
2640         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2641         gl_PRINTF_FLAG_GROUPING and test its result. Invoke
2642         gl_PREREQ_VASNPRINTF_FLAG_GROUPING.
2643         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2644         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
2645         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2646         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2647         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2648         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2649         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2650         * tests/test-snprintf-posix.h (test_function): Also check the grouping
2651         flag.
2652         * tests/test-sprintf-posix.h (test_function): Likewise.
2653         * tests/test-vasnprintf-posix.c (test_function): Likewise.
2654         * tests/test-vasprintf-posix.c (test_function): Likewise.
2655         * doc/functions/fprintf.texi: Update.
2656         * doc/functions/printf.texi: Update.
2657         * doc/functions/snprintf.texi: Update.
2658         * doc/functions/sprintf.texi: Update.
2659         * doc/functions/vfprintf.texi: Update.
2660         * doc/functions/vprintf.texi: Update.
2661         * doc/functions/vsnprintf.texi: Update.
2662         * doc/functions/vsprintf.texi: Update.
2663
2664 2007-05-01  Bruno Haible  <bruno@clisp.org>
2665
2666         * tests/test-argp-2.sh (func_compare): Drop .exe suffix.
2667
2668 2007-05-03  Paul Eggert  <eggert@cs.ucla.edu>
2669
2670         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use better
2671         comment for D_INO_IN_DIRENT.  Problem reported by James Youngman.
2672
2673 2007-05-02  Paul Eggert  <eggert@cs.ucla.edu>
2674
2675         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Test whether
2676         readdir returns garbage in d_ino.  Problem reported by Kaz Sasayama in
2677         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00021.html>.
2678
2679 2007-05-02  Sergey Poznyakoff  <gray@gnu.org.ua>
2680
2681         * lib/argp-help.c (struct hol_entry): New member `ord'.
2682         (HOL_ENTRY_PTRCMP): Use ord for comparison
2683         (hol_sort): Initialize ord.
2684
2685 2007-05-01  Bruno Haible  <bruno@clisp.org>
2686
2687         * doc/functions/_Exit_C99.texi: Renamed from doc/functions/_Exit.texi.
2688         Reported by Eric Blake.
2689         * doc/gnulib.texi (Function Substitutes): Update.
2690
2691 2007-05-01  Bruno Haible  <bruno@clisp.org>
2692
2693         * doc/functions.texi: Remove file, now redundant through
2694         doc/functions/*.texi.
2695
2696 2007-05-01  Bruno Haible  <bruno@clisp.org>
2697
2698         * modules/argp (Depends-on): Add sleep.
2699
2700 2007-05-01  Bruno Haible  <bruno@clisp.org>
2701
2702         * modules/sleep-tests: New file.
2703         * tests/test-sleep.c: New file.
2704
2705         * modules/sleep: New file.
2706         * lib/sleep.c: New file.
2707         * m4/sleep.m4: New file.
2708         * lib/unistd_.h (sleep): New declaration.
2709         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_SLEEP,
2710         HAVE_SLEEP.
2711         * modules/unistd (Makefile.am): Substitute GNULIB_SLEEP, HAVE_SLEEP.
2712         * doc/functions/sleep.texi: Document the sleep module.
2713
2714 2007-05-01  Bruno Haible  <bruno@clisp.org>
2715
2716         * lib/sigprocmask.h: Remove file.
2717         * lib/signal_.h: Incorporate the previous contents of sigprocmask.h.
2718         * lib/sigprocmask.c: Include <signal.h> instead of sigprocmask.h.
2719         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Substitute GNULIB_SIGPROCMASK,
2720         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T.
2721         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
2722         gl_SIGNAL_H_DEFAULTS. Set HAVE_POSIX_SIGNALBLOCKING as a shell variable.
2723         (gl_PREREQ_SIGPROCMASK): Require gl_SIGNAL_H_DEFAULTS. Set
2724         HAVE_SIGSET_T as a shell variable.
2725         * modules/signal (Makefile.am): Substitute GNULIB_SIGPROCMASK,
2726         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T into signal.h.
2727         * modules/sigprocmask (Files): Remove lib/sigprocmask.h.
2728         (Depends-on): Add signal. Remove verify.
2729         (configure.ac): Invoke gl_SIGNAL_MODULE_INDICATOR.
2730         (Include): Mention <signal.h> instead of sigprocmask.h.
2731         * NEWS: Mention the change.
2732         * lib/fatal-signal.c: Don't include sigprocmask.h.
2733
2734 2007-05-01  Bruno Haible  <bruno@clisp.org>
2735
2736         * modules/signal: New file.
2737         * lib/signal_.h: New file.
2738         * m4/signal_h.m4: New file.
2739
2740 2007-05-01  Bruno Haible  <bruno@clisp.org>
2741
2742         * lib/wctype_.h: Test HAVE_ISWCNTRL at configure time.
2743         * m4/wctype.m4 (gl_WCTYPE_H): Substitute HAVE_ISWCNTRL.
2744         * modules/wctype (Makefile.am): Substitute HAVE_ISWCNTRL instead of
2745         HAVE_WCTYPE_CTMP_BUG into wctype.h.
2746
2747 2007-05-01  Bruno Haible  <bruno@clisp.org>
2748
2749         * lib/sys_stat_.h: Test HAVE_LSTAT, HAVE_DECL_MKDIR, HAVE_IO_H at
2750         configure time.
2751         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Substitute HAVE_LSTAT,
2752         HAVE_DECL_MKDIR, HAVE_IO_H via AC_SUBST.
2753         * modules/sys_stat (Makefile.am): Substitute their values into
2754         sys/stat.h.
2755
2756 2007-05-01  Bruno Haible  <bruno@clisp.org>
2757
2758         * lib/glob_.h: Test HAVE_SYS_CDEFS_H at configure time.
2759         * m4/glob.m4 (gl_PREREQ_GLOB): Substitute HAVE_SYS_CDEFS_H via AC_SUBST.
2760         * modules/glob (Makefile.am): Put HAVE_SYS_CDEFS_H value into glob.h.
2761
2762 2007-05-01  Bruno Haible  <bruno@clisp.org>
2763
2764         * doc/header/assert.texi: Undo last change: don't mention the gnulib
2765         'assert' module here.
2766
2767 2007-05-01  Bruno Haible  <bruno@clisp.org>
2768
2769         * doc/functions/*.texi: New files.
2770         * doc/functions/google-ranking.txt: New file.
2771         * doc/gnulib.texi (Function Substitutes): New chapter.
2772         (ctime, inet_ntoa): Remove sections.
2773         * doc/ctime.texi: Remove file.
2774         * doc/inet_ntoa.texi: Remove file.
2775         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Update
2776         dependencies.
2777         (%.info): New rule, specifying a --reference-limit.
2778
2779 2007-05-01  Bruno Haible  <bruno@clisp.org>
2780
2781         * MODULES.html.sh (posix_functions): Remove 'exec', 'toc'.
2782
2783 2007-05-01  Bruno Haible  <bruno@clisp.org>
2784
2785         * modules/mkdir (Depends-on): Add sys_stat, because sys_stat provides
2786         the portability of 'mkdir' to mingw systems.
2787
2788 2007-05-01  Bruno Haible  <bruno@clisp.org>
2789
2790         * doc/headers/google-ranking.txt: New file.
2791
2792 2007-04-30  Eric Blake  <ebb9@byu.net>
2793
2794         Prefer fseeko to fseek.
2795         * modules/getpass (Depends-on): Add fseeko.
2796         * lib/getpass.c (getpass): Use fseeko, not fseek.
2797
2798 2007-04-30  Sergey Poznyakoff  <gray@gnu.org.ua>
2799
2800         * lib/argp-help.c (hol_entry_cmp): Option sorting algorithm
2801         assumes the sorting is stable, while most qsort implementations
2802         are not.  Use argument addresses to ensure they never compare as
2803         equal.
2804
2805         * tests/test-argp-2.sh (usage-indent test): Fix output
2806         (func_compare): Restore diff options
2807         * tests/test-argp.c: Restore #include "progname.h"
2808
2809 2007-04-29  Bruno Haible  <bruno@clisp.org>
2810
2811         * m4/printf.m4 (gl_VSNPRINTF_ZEROSIZE_C99): New macro.
2812         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
2813         gl_VSNPRINTF_ZEROSIZE_C99. Test gl_cv_func_vsnprintf_zerosize_c99.
2814         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2815         * modules/snprintf-posix-tests (Files): Add tests/test-snprintf.c.
2816         (configure.ac): Define CHECK_SNPRINTF_POSIX.
2817         (TESTS, check_PROGRAMS): Add test-snprintf.
2818         * modules/vsnprintf-posix-tests (Files): Add tests/test-vsnprintf.c.
2819         (configure.ac): Define CHECK_VSNPRINTF_POSIX.
2820         (TESTS, check_PROGRAMS): Add test-vsnprintf.
2821         * tests/test-snprintf.c (main) [!CHECK_SNPRINTF_POSIX]: Disable
2822         assertions that fail on HP-UX, OSF/1, or IRIX.
2823         * tests/test-vsnprintf.c (main) [!CHECK_VSNPRINTF_POSIX]: Likewise.
2824
2825 2007-04-29  Bruno Haible  <bruno@clisp.org>
2826
2827         * MODULES.html.sh (posix_functions): Remove 'contents'.
2828
2829 2007-04-29  Karl Berry  <karl@gnu.org>
2830
2831         * config/srclist.txt (gendocs_template_min): new entry.
2832
2833 2007-04-29  Bruno Haible  <bruno@clisp.org>
2834
2835         Work around fpurge bug on BSD systems.
2836         * modules/fpurge (Makefile.am): Compile fpurge.c unconditionally.
2837         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't invoke AC_LIBOBJ.
2838         * lib/fpurge.h (fpurge): Don't handle __fpurge wrapper here. Define
2839         fpurge to rpl_fpurge if the system already has this function.
2840         * lib/fpurge.c (fpurge): Handle also the __fpurge wrapper case and
2841         the case where the system already has this function. Correct invariants
2842         on BSD systems.
2843         * lib/fseeko.c (rpl_fseeko): Update recognition of preceding fflush on
2844         BSD systems.
2845
2846 2007-04-29  Sergey Poznyakoff  <gray@gnu.org.ua>
2847
2848         * lib/argp-help.c (hol_cluster_cmp): Reverse comparison.  Change
2849         proposed by Sven Verdoolaege.
2850
2851         * tests/test-argp.c: Fix option ordering.  Test deeply clustered
2852         options.
2853         * tests/test-argp-2.sh (func_compare): Use diff instead of cmp.
2854         (usage and help tests): Update
2855
2856 2007-04-29  Bruno Haible  <bruno@clisp.org>
2857
2858         * tests/test-fflush.c (main): Use a file of size 17, not 10.
2859         Print more information in case of failure. Disable a test on BeOS.
2860
2861 2007-04-29  Bruno Haible  <bruno@clisp.org>
2862
2863         * tests/**/test-*.[hc] (ASSERT): Use fprintf to show the line number.
2864         This helps debugging on systems on which no gdb is available.
2865
2866 2007-04-29  Bruno Haible  <bruno@clisp.org>
2867
2868         * lib/freading.h: Improve comments.
2869         * lib/fwriting.h: Likewise.
2870         * tests/test-freading.c (main): Don't check freading immediately after
2871         repositioning. Needed for glibc.
2872
2873 2007-04-29  Bruno Haible  <bruno@clisp.org>
2874
2875         * lib/freading.c (freading): Trivial simplification.
2876
2877 2007-04-28  Bruno Haible  <bruno@clisp.org>
2878
2879         * tests/test-fwriting.c (main): Also test the interaction between
2880         fflush and fwriting.
2881         * modules/fwriting-tests (Depends-on): Add fflush.
2882
2883         * tests/test-freading.c (main): Also test the interaction between
2884         fflush and freading.
2885         * modules/freading-tests (Depends-on): Add fflush.
2886
2887 2007-04-28  Bruno Haible  <bruno@clisp.org>
2888
2889         * lib/stdio_.h (fseek, ftell): Provide link warnings suggesting to use
2890         fseeko and ftello.
2891         Suggested by Eric Blake.
2892
2893 2007-04-28  Jim Meyering  <jim@meyering.net>
2894
2895         Avoid false-negative in gl_STDINT_H's C99 conformance test.
2896         * m4/stdint.m4 (gl_STDINT_H): When checking whether stdint.h conforms
2897         to C99, include all of gl_STDINT_INCLUDES, not just <stddef.h>.
2898
2899 2007-04-27  Eric Blake  <ebb9@byu.net>
2900
2901         * doc/headers/assert.texi (assert.h): Document assert module use.
2902
2903 2007-04-27  Bruno Haible  <bruno@clisp.org>
2904
2905         * doc/headers/*.texi: New files.
2906         * doc/gnulib.texi (Header File Substitutes): New chapter.
2907         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Specify
2908         dependencies.
2909         (standards.info ,standards.html, standards.dvi): Update dependencies.
2910         (mostlyclean, clean): New targets.
2911
2912 2007-04-27  Bruno Haible  <bruno@clisp.org>
2913
2914         * lib/sysexits_.h: Renamed from lib/sysexit_.h.
2915         * modules/sysexits (Files, Makefile.am): Update.
2916
2917         * lib/sys_socket_.h: Renamed from lib/socket_.h.
2918         * modules/sys_socket (Files, Makefile.am): Update.
2919
2920         * lib/sys_stat_.h: Renamed from lib/stat_.h.
2921         * modules/sys_stat (Files, Makefile.am): Update.
2922
2923 2007-04-27  Eric Blake  <ebb9@byu.net>
2924
2925         * lib/freading.h: Improve comments.
2926         * lib/fwriting.h: Likewise.
2927         * lib/fflush.c: Likewise.
2928
2929         Fix closein for mingw.
2930         * modules/closein-tests: Add tests for closein.
2931         * tests/test-closein.c: New file.
2932         * tests/test-closein.sh: Likewise.
2933         * lib/unistd_.h [!SEEK_CUR]: Mingw also needs stdlib.h for _exit.
2934         * lib/closein.c (close_stdin): Don't fflush non-seekable streams.
2935
2936 2007-04-27  Bruno Haible  <bruno@clisp.org>
2937
2938         * lib/inttypes_.h [_DECC]: Don't use #include_next if the compiler
2939         version is < 6.
2940         * lib/math_.h [__DECC]: Likewise.
2941         * lib/stdio_.h [__DECC]: Likewise.
2942         * lib/stdlib_.h [__DECC]: Likewise.
2943         * lib/string_.h [__DECC]: Likewise.
2944         * lib/time_.h [__DECC]: Likewise.
2945         * lib/wchar_.h [__DECC]: Likewise.
2946         * lib/wctype_.h [__DECC]: Likewise.
2947
2948 2007-04-27  Bruno Haible  <bruno@clisp.org>
2949
2950         * tests/test-fbufmode.c (main): Relax test, to avoid failure on mingw.
2951
2952 2007-04-27  Bruno Haible  <bruno@clisp.org>
2953
2954         * lib/fflush.c: Add comments.
2955         * modules/fpurge-tests (Depends-on): Add fflush.
2956         * modules/freadable-tests (Depends-on): Likewise.
2957         * modules/fwritable-tests (Depends-on): Likewise.
2958
2959 2007-04-27  Charles Wilson  <libtool@cwilson.fastmail.fm>
2960
2961         * m4/argz.m4 (gl_FUNC_ARGZ): Use !HAVE_WORKING_ARGZ instead of
2962         SYSTEM_ARGZ_IS_BROKEN.  Also, minor stylistic improvements.
2963         Report by Bruno Haible <bruno@clisp.org>.
2964
2965 2007-04-26  Eric Blake  <ebb9@byu.net>
2966
2967         Fix fflush on mingw.
2968         * modules/fflush (Depends-on): Add freading.
2969         * lib/fflush.c (rpl_fflush): Use freading to avoid losing buffered
2970         but unread data.
2971
2972 2007-04-26  Eric Blake  <ebb9@byu.net>
2973         and Bruno Haible  <bruno@clisp.org>
2974
2975         Implement freading and fwriting.
2976         * lib/freading.c: New file.
2977         * lib/freading.h: Likewise.
2978         * m4/freading.m4: Likewise.
2979         * modules/freading: Likewise.
2980         * modules/freading-tests: Likewise.
2981         * tests/test-freading.c: Likewise.
2982         * lib/fwriting.c: New file.
2983         * lib/fwriting.h: Likewise.
2984         * m4/fwriting.m4: Likewise.
2985         * modules/fwriting: Likewise.
2986         * modules/fwriting-tests: Likewise.
2987         * tests/test-fwriting.c: Likewise.
2988         * MODULES.html.sh (File stream based Input/Output): Mention them.
2989
2990 2007-04-26  Bruno Haible  <bruno@clisp.org>
2991
2992         * lib/stdio_.h (fseeko, ftello): Check that off_t has the same size as
2993         'long' when we assume it.
2994         Suggested by Eric Blake.
2995
2996 2007-04-26  Bruno Haible  <bruno@clisp.org>
2997
2998         Ensure fseeko, ftello are declared on glibc systems.
2999         * modules/fflush (configure.ac-early): Require AC_FUNC_FSEEKO.
3000         * modules/fseeko (configure.ac-early): Likewise.
3001         * modules/ftello (configure.ac-early): Likewise.
3002         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't define HAVE_FSEEKO, rely on
3003         AC_FUNC_FSEEKO for this.
3004         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Inline gl_CHECK_FSEEKO.
3005         (gl_CHECK_FSEEKO): Remove macro.
3006
3007 2007-04-26  Bruno Haible  <bruno@clisp.org>
3008
3009         * tests/test-fflush.c (main): Also check the ftell result after
3010         fflush and fseek/fseeko.
3011         * lib/fflush.c (rpl_fflush): For BSD implementations, update the
3012         file descriptor position cache in the stream.
3013         * lib/fseeko.c (rpl_fseeko): Likewise.
3014
3015 2007-04-26  Bruno Haible  <bruno@clisp.org>
3016
3017         * modules/fflush-tests (Depends-on): Add fseeko.
3018
3019 2007-04-25  Charles Wilson  <libtool@cwilson.fastmail.fm>
3020             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3021
3022         * lib/argz_.h: ensure error_t definition is obtained in same
3023         mechanism system argz.h would have.
3024         * m4/argz.m4 (gl_FUNC_ARGZ): add new test to check if $host's
3025         argz facilities are known bad.  Err on the side of caution if
3026         cross-compiling.
3027
3028 2007-04-25  Eric Blake  <ebb9@byu.net>
3029
3030         * lib/fpurge.c (includes): Use stdlib.h for free.
3031         * tests/test-fflush.c (main): Also test fflush-fseeko.
3032
3033 2007-04-25  Bruno Haible  <bruno@clisp.org>
3034
3035         Make fflush+fseek POSIX-compliant on FreeBSD and MacOS X.
3036         * lib/fseeko.c: New file.
3037         * lib/stdio_.h: Include <sys/types.h> when off_t is needed.
3038         (fseeko, fseek): Define to replacements if REPLACE_FFLUSH.
3039         * m4/fseeko.m4 (gl_CHECK_FSEEKO): New macro, extracted from
3040         gl_FUNC_FSEEKO.
3041         (gl_FUNC_FSEEKO): Invoke it.
3042         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Arrange to compile fseeko.c. Invoke
3043         gl_CHECK_FSEEKO. Define HAVE_FSEEKO.
3044         * modules/fflush (Files): Add lib/fseeko.c, m4/fseeko.m4.
3045
3046 2007-04-25  Bruno Haible  <bruno@clisp.org>
3047
3048         * modules/fflush (Depends-on): Add ftello.
3049
3050 2007-04-25  Bruno Haible  <bruno@clisp.org>
3051
3052         * modules/ftello-tests: New file.
3053         * tests/test-ftello.c: New file.
3054
3055         * modules/ftello: New file.
3056         * m4/ftello.m4: New file.
3057         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELLO,
3058         HAVE_FTELLO.
3059         * lib/stdio_.h (ftello): New declaration.
3060         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELLO,
3061         HAVE_FTELLO.
3062
3063 2007-04-25  Bruno Haible  <bruno@clisp.org>
3064
3065         * modules/fseeko-tests: New file.
3066         * tests/test-fseeko.c: New file.
3067
3068         * modules/fseeko: New file.
3069         * m4/fseeko.m4: New file.
3070         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEKO,
3071         HAVE_FSEEKO.
3072         * lib/stdio_.h (fseeko): New declaration.
3073         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEKO,
3074         HAVE_FSEEKO.
3075
3076 2007-04-25  Bruno Haible  <bruno@clisp.org>
3077
3078         * lib/stdio_.h (fflush): Add support for GNULIB_POSIXCHECK.
3079
3080 2007-04-25  Bruno Haible  <bruno@clisp.org>
3081
3082         * lib/unistd_.h: Include <stdio.h> if needed to get the SEEK_* macros.
3083         * tests/test-stdio.c: Check that the various SEEK_* macros are defined.
3084         * tests/test-unistd.c: Likewise.
3085         * tests/test-fcntl.c: Likewise.
3086
3087 2007-04-23  Eric Blake  <ebb9@byu.net>
3088
3089         * lib/fflush.c: Fix missing include.
3090         Reported by Bruno Haible.
3091
3092 2007-04-23  Bruno Haible  <bruno@clisp.org>
3093
3094         * lib/fpurge.c (fpurge) [glibc, BSD]: Free a malloc()ed ungetc buffer.
3095         Reported by Eric Blake.
3096
3097 2007-04-23  Bruno Haible  <bruno@clisp.org>
3098
3099         * lib/fbufmode.c (fbufmode): Port to Solaris/SPARC64.
3100
3101 2007-04-23  Bruno Haible  <bruno@clisp.org>
3102
3103         * lib/fseterr.c (fseterr): Don't hardcode the value of _IOERR.
3104
3105 2007-04-23  Bruno Haible  <bruno@clisp.org>
3106
3107         * tests/test-fbufmode.c (main): Be prepared to a failure of setvbuf.
3108         Needed on HP-UX 11.
3109
3110 2007-04-16  Eric Blake  <ebb9@byu.net>
3111
3112         Make fflush rely on fpurge.
3113         * lib/fflush.c (rpl_fflush): Rely on fpurge module, rather than
3114         open coding all variants.
3115         * modules/fflush (Depends-on): Add fpurge and unistd.
3116         * modules/fflush-tests (Depends-on): Unistd is no longer extra.
3117         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Simplify.
3118
3119         Fix --with-tests compilation on cygwin.
3120         * modules/argmatch-tests (Makefile.am): List gnulib library first
3121         in LDADD.
3122         * modules/argp-tests (Makefile.am): Likewise.
3123         * modules/array-list-tests (Makefile.am): Likewise.
3124         * modules/array-oset-tests (Makefile.am): Likewise.
3125         * modules/avltree-list-tests (Makefile.am): Likewise.
3126         * modules/avltree-oset-tests (Makefile.am): Likewise.
3127         * modules/avltreehash-list-tests (Makefile.am): Likewise.
3128         * modules/carray-list-tests (Makefile.am): Likewise.
3129         * modules/dirname-tests (Makefile.am): Likewise.
3130         * modules/frexp-tests (Makefile.am): Likewise.
3131         * modules/isnanl-tests (Makefile.am): Likewise.
3132         * modules/linked-list-tests (Makefile.am): Likewise.
3133         * modules/linkedhash-list-tests (Makefile.am): Likewise.
3134         * modules/lock-tests (Makefile.am): Likewise.
3135         * modules/rbtree-list-tests (Makefile.am): Likewise.
3136         * modules/rbtree-oset-tests (Makefile.am): Likewise.
3137         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
3138         * modules/tls-tests (Makefile.am): Likewise.
3139         * modules/tsearch-tests (Makefile.am): Likewise.
3140         * modules/xvasprintf-tests (Makefile.am): Likewise.
3141
3142         Fix fpurge for cygwin.
3143         * lib/fpurge.c (fpurge): Fix order of operation flub, and return a
3144         value.
3145         * modules/fpurge-tests (Depends-on): Clean up trash.
3146
3147 2007-04-16  Simon Josefsson  <simon@josefsson.org>
3148
3149         * lib/gc-libgcrypt.c (gc_hash_open): Shut up compiler warnings.
3150
3151         * m4/autobuild.m4: Re-indent.
3152
3153 2007-04-13  Bruno Haible  <bruno@clisp.org>
3154
3155         * modules/fpurge-tests: New file.
3156         * tests/test-fpurge.c: New file.
3157
3158         * modules/fpurge: New file.
3159         * lib/fpurge.h: New file.
3160         * lib/fpurge.c: New file.
3161         * m4/fpurge.m4: New file.
3162
3163 2007-04-13  Bruno Haible  <bruno@clisp.org>
3164
3165         * modules/fbufmode-tests: New file.
3166         * tests/test-fbufmode.c: New file.
3167
3168         * modules/fbufmode: New file.
3169         * lib/fbufmode.h: New file.
3170         * lib/fbufmode.c: New file.
3171         * m4/fbufmode.m4: New file.
3172
3173 2007-04-13  Bruno Haible  <bruno@clisp.org>
3174
3175         * modules/fwritable-tests: New file.
3176         * tests/test-fwritable.c: New file.
3177
3178         * modules/fwritable: New file.
3179         * lib/fwritable.h: New file.
3180         * lib/fwritable.c: New file.
3181         * m4/fwritable.m4: New file.
3182
3183 2007-04-13  Bruno Haible  <bruno@clisp.org>
3184
3185         * modules/freadable-tests: New file.
3186         * tests/test-freadable.c: New file.
3187
3188         * modules/freadable: New file.
3189         * lib/freadable.h: New file.
3190         * lib/freadable.c: New file.
3191         * m4/freadable.m4: New file.
3192
3193 2007-04-13  Bruno Haible  <bruno@clisp.org>
3194
3195         * modules/fflush-tests (Makefile.am): Remove EXTRA_DIST. Augment
3196         MOSTLYCLEANFILES.
3197
3198 2007-04-13  Paul Eggert  <eggert@cs.ucla.edu>
3199
3200         * build-aux/bootstrap (gnulib_tool_option_extras): New var, used by
3201         gzip bootstrap.conf to avoid dragging in i18n machinery.
3202         (gnulib_tool_option): Use it.
3203
3204 2007-04-13  Bruno Haible  <bruno@clisp.org>
3205
3206         * tests/test-vasnprintf-posix.c (test_function): Add tests for %f and
3207         %F directives.
3208         * tests/test-vasprintf-posix.c (test_function): Likewise.
3209         * tests/test-snprintf-posix.h (test_function): Likewise.
3210         * tests/test-sprintf-posix.h (test_function): Likewise.
3211         * tests/test-fprintf-posix.h (test_function): Likewise.
3212         * tests/test-printf-posix.h (test_function): Likewise.
3213         * tests/test-fprintf-posix.out: Likewise.
3214
3215 2007-04-13  Bruno Haible  <bruno@clisp.org>
3216
3217         * modules/lock-tests (configure.ac): For LIBSCHED, try also -lposix4.
3218         * modules/tls-tests (configure.ac): Likewise.
3219         Reported by Arto C. Nirkko <anirkko@insel.ch>.
3220
3221 2007-04-13  Bruno Haible  <bruno@clisp.org>
3222
3223         * lib/tls.c (glthread_tls_get): Fix return type.
3224         Patch by Arto C. Nirkko <anirkko@insel.ch>.
3225
3226 2007-04-12  Eric Blake  <ebb9@byu.net>
3227
3228         * modules/gettime (Depends-on): Remove gettime.
3229         Reported by Dmitry V. Levin.
3230
3231 2007-04-12  Bruno Haible  <bruno@clisp.org>
3232
3233         * modules/fflush (Include): Mention <stdio.h>.
3234         * modules/strtoimax (Include): Mention <inttypes.h>.
3235         * modules/strtoumax (Include): Likewise.
3236
3237 2007-04-12  Eric Blake  <ebb9@byu.net>
3238
3239         * .cvsignore: New file.
3240         * .gitignore: Likewise.
3241
3242 2007-04-12  Bruno Haible  <bruno@clisp.org>
3243
3244         * modules/iconv-tests (test_iconv_LDADD): Mention -liconv after LDADD,
3245         not before, since $(LDADD) often contains libgnu.a.
3246         * modules/striconv-tests (test_striconv_LDADD): Likewise.
3247         * modules/striconveh-tests (test_striconveh_LDADD): Likewise.
3248         * modules/striconveha-tests (test_striconveha_LDADD): Likewise.
3249         Needed on Cygwin.
3250
3251 2007-04-12  Eric Blake  <ebb9@byu.net>
3252
3253         Work around glibc's failure to flush stdin on fclose.
3254         * lib/closein.c (close_stdin): Flush stdin before closing.
3255
3256         Work around glibc's failure to reset seekable stdin on exit.
3257         * modules/closein: New module.
3258         * lib/closein.c: New file.
3259         * lib/closein.h: Likewise.
3260         * m4/closein.m4: Likewise.
3261         * MODULES.html.sh (File stream based Input/Output): Document it.
3262
3263 2007-04-12  Simon Josefsson  <simon@josefsson.org>
3264
3265         * gnulib-tool: Rename generated 'autobuild' script to
3266         'do-autobuild' in --create-megatestdir output.
3267
3268         * doc/gnulib.texi (Build robot for gnulib): Fix.
3269
3270 2007-04-12  Simon Josefsson  <simon@josefsson.org>
3271
3272         * modules/sysexits (Depends-on): Add absolute-header.
3273
3274 2007-04-12  Eric Blake  <ebb9@byu.net>
3275
3276         No need to preserve errno on success.
3277         * lib/fflush.c (rpl_fflush): Simplify errno tracking.
3278         Reported by Bruno Haible.
3279
3280 2007-04-12  Simon Josefsson  <simon@josefsson.org>
3281
3282         * MODULES.html.sh (Support for maintaining and releasing
3283         projects): Add autobuild.  Suggested by Eric Blake <ebb9@byu.net>.
3284
3285 2007-04-12  Simon Josefsson  <simon@josefsson.org>
3286
3287         * gnulib-tool (func_modules_add_dummy): Respect --avoid=dummy.
3288
3289 2007-04-12  Simon Josefsson  <simon@josefsson.org>
3290
3291         * modules/autobuild: New module.
3292
3293         * m4/autobuild.m4: New file.
3294
3295 2007-04-11  Bruno Haible  <bruno@clisp.org>
3296
3297         * lib/vasnprintf.c (VASNPRINTF): Implement the %F directive using the
3298         %f directive, if NEED_PRINTF_DIRECTIVE_F is defined.
3299         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): New macro.
3300         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_F): New macro.
3301         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
3302         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3303         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3304         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
3305         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3306         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3307         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Invoke
3308         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3309         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3310         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Invoke
3311         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3312         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3313         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Invoke
3314         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3315         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3316         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Invoke
3317         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3318         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3319         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Invoke
3320         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3321         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3322         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Invoke
3323         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
3324         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
3325         Reported by Eric Blake.
3326
3327 2007-04-11  Bruno Haible  <bruno@clisp.org>
3328
3329         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Fix test. It always failed.
3330
3331 2007-04-10  Bruno Haible  <bruno@clisp.org>
3332
3333         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
3334         for NaN and Infinity. Needed on FreeBSD 6.1.
3335         * tests/test-vasnprintf-posix.c (test_function): Undo last change
3336         regarding results for "%010a" of Infinity and NaN.
3337         * tests/test-vasprintf-posix.c (test_function): Likewise.
3338         * tests/test-snprintf-posix.h (test_function): Likewise.
3339         * tests/test-sprintf-posix.h (test_function): Likewise.
3340         * tests/test-fprintf-posix.h (test_function): Likewise.
3341         * tests/test-printf-posix.h (test_function): Likewise.
3342         * tests/test-fprintf-posix.out: Likewise.
3343
3344 2007-04-10  Bruno Haible  <bruno@clisp.org>
3345
3346         * modules/locale-tests: New file.
3347         * tests/test-locale.c: New file.
3348
3349         * modules/locale: New file.
3350         * lib/locale_.h: New file.
3351         * m4/locale_h.m4: New file.
3352
3353 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
3354             Bruno Haible  <bruno@clisp.org>
3355
3356         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
3357         be determined, test for availability of the copysignf, copysign,
3358         copysignl functions.
3359         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
3360         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
3361         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
3362
3363 2007-04-09  Eric Blake  <ebb9@byu.net>
3364
3365         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
3366         * modules/stdio (Makefile.am): Support fflush.
3367         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
3368         * modules/fflush: New file.
3369         * lib/fflush.c: Likewise.
3370         * m4/fflush.m4: Likewise.
3371         * modules/fflush-tests: New test.
3372         * tests/test-fflush.c: Likewise.
3373         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
3374
3375 2007-04-06  Bruno Haible  <bruno@clisp.org>
3376
3377         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
3378         (VASNPRINTF): Use signbit for faster determination whether to print a
3379         minus sign.
3380         * modules/vasnprintf (Files): Remove lib/float+.h.
3381         * modules/fprintf-posix (Depends-on): Add signbit.
3382         * modules/snprintf-posix (Depends-on): Likewise.
3383         * modules/sprintf-posix (Depends-on): Likewise.
3384         * modules/vasnprintf-posix (Depends-on): Likewise.
3385         * modules/vasprintf-posix (Depends-on): Likewise.
3386         * modules/vfprintf-posix (Depends-on): Likewise.
3387         * modules/vsnprintf-posix (Depends-on): Likewise.
3388         * modules/vsprintf-posix (Depends-on): Likewise.
3389
3390 2007-04-06  Bruno Haible  <bruno@clisp.org>
3391
3392         * tests/test-frexp.c (main): Test also the sign bit of zero results.
3393         * tests/test-frexpl.c (main): Likewise.
3394         * tests/test-ldexpl.c (main): Likewise.
3395         * modules/frexp-tests (Depends-on): Add signbit.
3396         * modules/frexpl-tests (Depdends-on): Likewise.
3397         * modules/ldexpl-tests (Depdends-on): Likewise.
3398
3399 2007-04-06  Bruno Haible  <bruno@clisp.org>
3400
3401         * modules/signbit-tests: New file.
3402         * tests/test-signbit.c: New file.
3403
3404         * modules/signbit: New file.
3405         * lib/signbitf.c: New file.
3406         * lib/signbitd.c: New file.
3407         * lib/signbitl.c: New file.
3408         * m4/signbit.m4: New file.
3409         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
3410         (signbit): New macro.
3411         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
3412         REPLACE_SIGNBIT.
3413         * modules/math (Makefile.am) Substibute also GNULIB_SIGNBIT and
3414         REPLACE_FREXPL into math.h.
3415
3416 2007-04-06  Bruno Haible  <bruno@clisp.org>
3417
3418         * modules/isnanf-nolibm-tests: New file.
3419         * tests/test-isnanf.c: New file.
3420
3421         * modules/isnanf-nolibm: New file.
3422         * lib/isnanf.h: New file.
3423         * lib/isnanf.c: New file.
3424         * lib/isnan.c: Consider the USE_FLOAT macro.
3425         * m4/isnanf.m4: New file.
3426
3427 2007-04-06  Bruno Haible  <bruno@clisp.org>
3428
3429         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
3430         (Link): New section.
3431
3432         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
3433
3434 2007-04-06  Bruno Haible  <bruno@clisp.org>
3435
3436         Assume the 'long double' type.
3437         * m4/longdouble.m4: Remove file.
3438         * config/srclist.txt: Don't mention longdouble.m4.
3439         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
3440         * lib/float+.h: Likewise.
3441         * lib/frexp.c: Likewise.
3442         * lib/printf-args.h: Likewise.
3443         * lib/printf-args.c: Likewise.
3444         * lib/printf-frexp.c: Likewise.
3445         * lib/printf-parse.c: Likewise.
3446         * lib/vasnprintf.c: Likewise.
3447         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
3448         * m4/intl.m4: Likewise.
3449         * m4/isnanl.m4: Likewise.
3450         * m4/printf.m4: Likewise.
3451         * m4/printf-frexpl.m4: Likewise.
3452         * m4/vasnprintf.m4: Likewise.
3453         * modules/allocsa (Files): Remove m4/longdouble.m4.
3454         * modules/gettext (Files): Likewise.
3455         * modules/relocatable-prog-wrapper (Files): Likewise.
3456         * modules/vasnprintf (Files): Likewise.
3457         * modules/isnanl (Files): Likewise.
3458         (Include): Simplify.
3459         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
3460         (Include): Simplify.
3461         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
3462         (Include): Simplify.
3463         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
3464         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3465         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
3466         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3467         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
3468         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3469         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
3470         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3471         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
3472         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3473         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
3474         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
3475         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
3476         * tests/test-isnanl.c: Likewise.
3477         * tests/test-snprintf-posix.h: Likewise.
3478         * tests/test-sprintf-posix.h: Likewise.
3479         * tests/test-vasnprintf-posix.c: Likewise.
3480         * tests/test-vasnprintf-posix2.c: Likewise.
3481         * tests/test-vasprintf-posix.c: Likewise.
3482
3483 2007-04-06  Bruno Haible  <bruno@clisp.org>
3484
3485         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
3486         * lib/math_.h [__DECC]: Include the overridden include file through
3487         #include_next, outside the double-inclusion guard.
3488         * lib/stdio_.h [__DECC]: Likewise.
3489         * lib/stdlib_.h [__DECC]: Likewise.
3490         * lib/string_.h [__DECC]: Likewise.
3491         * lib/time_.h [__DECC]: Likewise.
3492         * lib/wchar_.h [__DECC]: Likewise.
3493         * lib/wctype_.h [__DECC]: Likewise.
3494         * lib/inttypes_.h [__DECC]: Likewise.
3495         Reported by Albert Chin <china@thewrittenword.com> in
3496         <http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00088.html>.
3497
3498 2007-04-04  Eric Blake  <ebb9@byu.net>
3499
3500         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
3501         1.5.x.
3502
3503 2007-04-04  Bruno Haible  <bruno@clisp.org>
3504
3505         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
3506         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
3507
3508 2007-04-04  Bruno Haible  <bruno@clisp.org>
3509
3510         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
3511         results for "%010a" of Infinity and NaN.
3512         * tests/test-vasprintf-posix.c (test_function): Likewise.
3513         * tests/test-snprintf-posix.h (test_function): Likewise.
3514         * tests/test-sprintf-posix.h (test_function): Likewise.
3515         * tests/test-fprintf-posix.h (test_function): Remove these tests.
3516         * tests/test-printf-posix.h (test_function): Likewise.
3517         * tests/test-fprintf-posix.out: Update.
3518         Needed for FreeBSD 6.1.
3519
3520 2007-04-04  Bruno Haible  <bruno@clisp.org>
3521
3522         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
3523         directly used by the gnulib modules nor by gnulib-tool.
3524
3525 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
3526
3527         * DEPENDENCIES: Give overall description of version dependency
3528         desirability.  Use more-typical names for apps.
3529         Add shell, coreutils, diffutils, grep, tar, gzip.
3530
3531 2007-04-04  Simon Josefsson  <simon@josefsson.org>
3532
3533         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
3534
3535 2007-04-04  Karl Berry  <karl@gnu.org>
3536
3537         * MODULES.html.sh (func_module): missing '.
3538
3539 2007-04-03  Bruno Haible  <bruno@clisp.org>
3540
3541         * modules/argmatch-tests (Makefile.am): New variable
3542         test_argmatch_LDADD.
3543         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
3544         * modules/array-list-tests (Makefile.am): New variable
3545         test_array_list_LDADD.
3546         * modules/array-oset-tests (Makefile.am): New variable
3547         test_array_oset_LDADD.
3548         * modules/avltree-list-tests (Makefile.am): New variable
3549         test_avltree_list_LDADD.
3550         * modules/avltree-oset-tests (Makefile.am): New variable
3551         test_avltree_oset_LDADD.
3552         * modules/avltreehash-list-tests (Makefile.am): New variable
3553         test_avltreehash_list_LDADD.
3554         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
3555         test_canonicalize_lgpl_LDADD.
3556         * modules/carray-list-tests (Makefile.am): New variable
3557         test_carray_list_LDADD.
3558         * modules/dirname-tests (Makefile.am): New variable
3559         test_dirname_LDADD.
3560         * modules/linked-list-tests (Makefile.am): New variable
3561         test_linked_list_LDADD.
3562         * modules/linkedhash-list-tests (Makefile.am): New variable
3563         test_linkedhash_list_LDADD.
3564         * modules/rbtree-list-tests (Makefile.am): New variable
3565         test_rbtree_list_LDADD.
3566         * modules/rbtree-oset-tests (Makefile.am): New variable
3567         test_rbtree_oset_LDADD.
3568         * modules/rbtreehash-list-tests (Makefile.am): New variable
3569         test_rbtreehash_list_LDADD.
3570         * modules/xvasprintf-tests (Makefile.am): New variable
3571         test_xvasprintf_LDADD.
3572         Reported by Eric Blake.
3573
3574 2007-04-03  Eric Blake  <ebb9@byu.net>
3575
3576         * DEPENDENCIES: Weaken m4 requirements.
3577
3578 2007-04-03  Bruno Haible  <bruno@clisp.org>
3579
3580         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
3581         * modules/isnanl-tests (configure.ac): Likewise.
3582
3583 2007-04-03  Ben Pfaff  <blp@gnu.org>
3584
3585         * modules/iconv_open: Add $(srcdir)/ to source directory
3586         references in Makefile fragments that call gperf, to fix VPATH
3587         builds.
3588
3589 2007-04-03  Bruno Haible  <bruno@clisp.org>
3590
3591         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
3592         * lib/ldexpl.c: Undo last change.
3593
3594 2007-04-03  Bruno Haible  <bruno@clisp.org>
3595
3596         * modules/printf-frexpl (Depends-on): Undo last change.
3597         (Files): Add m4/ldexpl.m4.
3598
3599 2007-04-03  Bruno Haible  <bruno@clisp.org>
3600
3601         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
3602         * modules/isnanl (Link): New section.
3603
3604         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
3605         * modules/frexp (Link): New section.
3606
3607         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
3608         * modules/frexpl (Link): New section.
3609
3610         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
3611         * modules/ldexpl (Link): New section.
3612
3613 2007-04-03  Bruno Haible  <bruno@clisp.org>
3614
3615         * modules/TEMPLATE-EXTENDED: New file.
3616         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
3617
3618 2007-04-03  Bruno Haible  <bruno@clisp.org>
3619
3620         * DEPENDENCIES: New file.
3621         Suggested by Simon Josefsson.
3622
3623 2007-04-03  Bruno Haible  <bruno@clisp.org>
3624
3625         * doc/gnulib.texi: Escape @.
3626
3627 2007-04-03  James Youngman  <jay@gnu.org>
3628         and Paul Eggert  <eggert@cs.ucla.edu>
3629
3630         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
3631         birthtime on all systems that have birthtime, not just those which
3632         use st_birthtimensec rather than st_birthtim.  Putting zero in
3633         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
3634         that the birth time is not available for files on an NFS mount.
3635
3636 2007-04-03  Simon Josefsson  <simon@josefsson.org>
3637
3638         * modules/memxor: Move back from crypto/, suggested by Bruno.
3639         * modules/crypto/hmac-sha1: Fix memxor dependency.
3640
3641         * modules/crypto/gc: Moved from ../.
3642
3643 2007-04-02  Eric Blake  <ebb9@byu.net>
3644
3645         * lib/ldexpl.c (includes): Avoid libm.
3646
3647         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
3648
3649 2007-04-02  Bruno Haible  <bruno@clisp.org>
3650
3651         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
3652         on IRIX.
3653
3654 2007-04-02  Bruno Haible  <bruno@clisp.org>
3655
3656         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
3657         x86 or x86_64 platforms running MacOS X.
3658         Reported by Ryan Schmidt <@ryandesign.com>.
3659
3660 2007-04-02  Bruno Haible  <bruno@clisp.org>
3661
3662         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
3663         i386.
3664
3665 2007-04-01  Simon Josefsson  <simon@josefsson.org>
3666
3667         * modules/crypto/arcfour: Moved from ../.
3668         * modules/crypto/arcfour-tests: Moved from ../.
3669         * modules/crypto/arctwo: Moved from ../.
3670         * modules/crypto/arctwo-tests: Moved from ../.
3671         * modules/crypto/des: Moved from ../.
3672         * modules/crypto/des-tests: Moved from ../.
3673         * modules/crypto/gc-arcfour: Moved from ../.
3674         * modules/crypto/gc-arcfour-tests: Moved from ../.
3675         * modules/crypto/gc-arctwo: Moved from ../.
3676         * modules/crypto/gc-arctwo-tests: Moved from ../.
3677         * modules/crypto/gc-des: Moved from ../.
3678         * modules/crypto/gc-des-tests: Moved from ../.
3679         * modules/crypto/gc-hmac-md5: Moved from ../.
3680         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
3681         * modules/crypto/gc-hmac-sha1: Moved from ../.
3682         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
3683         * modules/crypto/gc-md2: Moved from ../.
3684         * modules/crypto/gc-md2-tests: Moved from ../.
3685         * modules/crypto/gc-md4: Moved from ../.
3686         * modules/crypto/gc-md4-tests: Moved from ../.
3687         * modules/crypto/gc-md5: Moved from ../.
3688         * modules/crypto/gc-md5-tests: Moved from ../.
3689         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
3690         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
3691         * modules/crypto/gc-random: Moved from ../.
3692         * modules/crypto/gc-rijndael: Moved from ../.
3693         * modules/crypto/gc-rijndael-tests: Moved from ../.
3694         * modules/crypto/gc-sha1: Moved from ../.
3695         * modules/crypto/gc-sha1-tests: Moved from ../.
3696         * modules/crypto/gc-tests: Moved from ../.
3697         * modules/crypto/hmac-md5: Moved from ../.
3698         * modules/crypto/hmac-md5-tests: Moved from ../.
3699         * modules/crypto/hmac-sha1: Moved from ../.
3700         * modules/crypto/hmac-sha1-tests: Moved from ../.
3701         * modules/crypto/md2: Moved from ../.
3702         * modules/crypto/md2-tests: Moved from ../.
3703         * modules/crypto/md4: Moved from ../.
3704         * modules/crypto/md4-tests: Moved from ../.
3705         * modules/crypto/md5: Moved from ../.
3706         * modules/crypto/md5-tests: Moved from ../.
3707         * modules/crypto/memxor: Moved from ../.
3708         * modules/crypto/rijndael: Moved from ../.
3709         * modules/crypto/rijndael-tests: Moved from ../.
3710         * modules/crypto/sha1: Moved from ../.
3711
3712 2007-03-30  James Youngman  <jay@gnu.org>
3713
3714         * tests/test-stat-time.c (prepare_test): use chmod() rather than
3715         rename() to change the ctime of a file (because ctime is unaffected
3716         by rename on jfs2 on AIX 5.1).
3717         (main): Start by doing cleanup, in case a previous run failed leaving
3718         test files behind.
3719
3720 2007-03-31  Bruno Haible  <bruno@clisp.org>
3721
3722         Support old proprietary implementations of iconv.
3723         * modules/iconv_open: New file.
3724         * lib/iconv_.h: New file.
3725         * m4/iconv_h.m4: New file.
3726         * lib/iconv_open.c: New file.
3727         * lib/iconv_open-aix.gperf: New file.
3728         * lib/iconv_open-hpux.gperf: New file.
3729         * lib/iconv_open-irix.gperf: New file.
3730         * lib/iconv_open-osf.gperf: New file.
3731         * m4/iconv_open.m4: New file.
3732         * modules/linebreak (Depends-on): Add iconv_open.
3733         * modules/striconv (Depends-on): Likewise.
3734         * modules/striconveh (Depends-on): Likewise.
3735         * modules/unicodeio (Depends-on): Likewise.
3736         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
3737         (iconv_t)(-1).
3738         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
3739         conversion if cd is (iconv_t)(-1).
3740         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
3741         is not possible.
3742
3743 2007-03-31  Bruno Haible  <bruno@clisp.org>
3744
3745         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
3746         work on Solaris either. Protect also second use of "autodetect_jp".
3747
3748 2007-03-31  Bruno Haible  <bruno@clisp.org>
3749
3750         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
3751         the function is not present.
3752
3753 2007-03-31  Bruno Haible  <bruno@clisp.org>
3754
3755         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
3756         the function is not present.
3757
3758 2007-03-31  Bruno Haible  <bruno@clisp.org>
3759
3760         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
3761         a bug in HP-UX iconv_open().
3762
3763 2007-03-31  Bruno Haible  <bruno@clisp.org>
3764
3765         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
3766         (Mathematics <math.h>): New section, add fpieee.
3767         (Input/output <stdio.h>): Add fseterr.
3768         (Mathematics <math.h>): New section, add printf-frexp.
3769         (Container data structures): Add sublist.
3770         (Core language properties): Add fpucw, inline.
3771         (Functions for greatest-width integer types <inttypes.h>): Add
3772         imaxabs, imaxdiv, inttypes.
3773         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
3774         isnanl-nolibm, ldexp.
3775         (Mathematics <math.h>): New section, add printf-frexpl.
3776         (Support for systems lacking POSIX:2001): Add fprintf-posix,
3777         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
3778         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
3779         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
3780         (Unicode string functions): Add unistr/u*-mbtoucr.
3781         (Java): Add javacomp-script, javaexec-script.
3782         (C#): Add csharpcomp-script, csharpexec-script.
3783         (Support for building libraries and executables): Add havelib,
3784         relocatable-*.
3785         (Support for maintaining and releasing projects): Renamed from
3786         'Support for maintaining and release projects'. Add announce-gen.
3787
3788 2007-03-31  Bruno Haible  <bruno@clisp.org>
3789
3790         * README: Talk primarily about git.
3791         (git and CVS): Renamed from CVS.
3792         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
3793         gnulib is available through git.
3794         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
3795
3796 2007-03-30  Bruno Haible  <bruno@clisp.org>
3797
3798         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
3799         * lib/poll_.h: Likewise.
3800         * lib/stat_.h: Likewise.
3801         * lib/sys_time_.h: Likewise.
3802         * lib/sysexit_.h: Likewise.
3803         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
3804         * lib/stdbool_.h: Likewise.
3805         * lib/byteswap_.h: Add double-inclusion guard.
3806
3807 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
3808
3809         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
3810
3811 2007-03-30  Karl Berry  <karl@gnu.org>
3812
3813         * config/srclist-update: double space after USA in the license
3814         substitution, since that's how it's usually (?) written.
3815
3816 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
3817
3818         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
3819         reported by Bruno Haible.
3820
3821 2007-03-29  Bruno Haible  <bruno@clisp.org>
3822
3823         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
3824         a bug in AIX iconv().
3825
3826 2007-03-29  Bruno Haible  <bruno@clisp.org>
3827
3828         * modules/ldexpl-tests: New file.
3829         * tests/test-ldexpl.c: New file.
3830
3831 2007-03-29  Bruno Haible  <bruno@clisp.org>
3832
3833         * lib/ldexpl.c: Include fpucw.h.
3834         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
3835         multiplication.
3836         * modules/ldexpl (Depends-on): Add fpucw.
3837
3838 2007-03-29  Bruno Haible  <bruno@clisp.org>
3839
3840         * modules/ldexpl: New file.
3841         * m4/ldexpl.m4: New file.
3842         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
3843         set.
3844         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
3845         REPLACE_LDEXPL.
3846         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
3847         REPLACE_LDEXPL.
3848         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
3849         gl_FUNC_LDEXPL_WORKS.
3850         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
3851         * modules/mathl (Files): Remove lib/ldexpl.c.
3852         (Depends-on): Add ldexpl.
3853
3854 2007-03-29  Bruno Haible  <bruno@clisp.org>
3855
3856         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
3857
3858 2007-03-29  Bruno Haible  <bruno@clisp.org>
3859
3860         * tests/test-striconveh.c (main): Don't assume that a direct conversion
3861         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
3862         and possibly also HP-UX.
3863         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
3864         work on AIX, IRIX, HP-UX, OSF/1.
3865         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
3866         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
3867         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
3868         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
3869         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
3870         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
3871
3872 2007-03-29  Bruno Haible  <bruno@clisp.org>
3873
3874         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
3875
3876 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
3877
3878         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
3879         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
3880
3881 2007-03-29  Eric Blake  <ebb9@byu.net>
3882
3883         * lib/acl-internal.h: Remove redundant include.
3884         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
3885         Cygwin when a file is locked.
3886
3887 2007-03-29  Bruno Haible  <bruno@clisp.org>
3888
3889         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
3890         file.
3891         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
3892
3893 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
3894
3895         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
3896         try to remove a parent directory if the child couldn't be removed
3897         (except for the first rmdir, which could fail because the child
3898         doesn't exist).  Problem reported by Jeff Blaine in
3899         <http://lists.gnu.org/archive/html/bug-tar/2007-03/msg00014.html>.
3900
3901 2007-03-28  Bruno Haible  <bruno@clisp.org>
3902
3903         * lib/striconveh.c (utf8conv_carefully): New function.
3904         (mem_cd_iconveh_internal): Invoke it.
3905
3906 2007-03-28  Bruno Haible  <bruno@clisp.org>
3907
3908         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
3909         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
3910         input.
3911         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
3912         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
3913         unistr/u8-uctomb.
3914
3915 2007-03-28  Bruno Haible  <bruno@clisp.org>
3916
3917         * modules/unistr/u8-mbtoucr: New file.
3918         * lib/unistr/u8-mbtoucr.c: New file.
3919         * modules/unistr/u16-mbtoucr: New file.
3920         * lib/unistr/u16-mbtoucr.c: New file.
3921         * modules/unistr/u16-mbtoucr: New file.
3922         * lib/unistr/u16-mbtoucr.c: New file.
3923         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
3924
3925 2007-03-27  Simon Josefsson  <simon@josefsson.org>
3926             Bruno Haible  <bruno@clisp.org>
3927
3928         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
3929         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
3930         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
3931
3932         * m4/stdio_h.m4: Add stubs for vasprintf too.
3933
3934         * modules/stdio: Support vasprintf in sed command.
3935
3936         * modules/vasprintf: Depend on stdio for prototypes.  Remove
3937         vasprintf.h.  Add stdio module indicator.
3938
3939         * lib/stdio_.h: Declare asprintf and vasprintf, based on
3940         vasprintf.h.
3941
3942         * lib/vasprintf.h: File removed.
3943
3944         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
3945         * lib/vasprintf.c: Ditto.
3946         * lib/xvasprintf.c: Ditto.
3947         * tests/test-vasprintf-posix.c: Ditto.
3948         * tests/test-vasprintf.c: Ditto.
3949
3950 2007-03-27  Bruno Haible  <bruno@clisp.org>
3951
3952         Make vasnprintf multithread-safe.
3953         * lib/vasnprintf.c (decimal_point_char): New function.
3954         (VASNPRINTF): Use it.
3955         Suggested by Simon Josefsson.
3956
3957 2007-03-27  Eric Blake  <ebb9@byu.net>
3958
3959         Support sub-second birthtime on cygwin.
3960         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
3961         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
3962         (get_stat_birthtime): Also work with st_birthtim.
3963
3964 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
3965
3966         * lib/stat-time.h (USE_BIRTHTIME): Remove.
3967         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
3968         (get_stat_birthtime_ns): Do not try to use "spare" fields.
3969         (get_stat_birthtime_ns): Simplify compile-time tests.
3970         (get_stat_birthtime): Change the API to look like
3971         get_stat_mtime etc., except return a negative tv_nsec on error.
3972         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
3973         Don't check for "spare" fields.
3974         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
3975         or for struct stat.st_birthtime, as these tests aren't used.
3976         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
3977
3978 2007-03-27  Bruno Haible  <bruno@clisp.org>
3979
3980         * lib/stat-time.h: Include <sys/stat.h>.
3981
3982 2007-03-27  James Youngman  <jay@gnu.org>
3983
3984         * lib/stat-time.h (get_stat_birthtime): New function for
3985           retrieving st_birthtime as provided by UFS2 (hence *BSD).
3986         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
3987           and its variants.
3988         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
3989         * modules/stat-time-test: New file.
3990         * tests/test-stat-time.c: New test, devised by Bruno Haible.
3991
3992 2007-03-26  Bruno Haible  <bruno@clisp.org>
3993
3994         Better support of signalling NaNs.
3995         * lib/atanl.c: Include isnanl.h.
3996         (atanl): Perform test for NaN at the beginning of the function and
3997         through a call to isnanl.
3998         * lib/cosl.c: Include isnanl.h.
3999         (cosl): Perform test for NaN at the beginning of the function and
4000         through a call to isnanl.
4001         * lib/ldexpl.c: Include isnanl.h.
4002         (ldexpl): Perform test for NaN through a call to isnanl.
4003         * lib/logl.c: Include isnanl.h.
4004         (logl): Perform test for NaN at the beginning of the function and
4005         through a call to isnanl.
4006         * lib/sinl.c: Include isnanl.h.
4007         (sinl): Perform test for NaN at the beginning of the function and
4008         through a call to isnanl.
4009         * lib/sqrtl.c: Include isnanl.h.
4010         (sqrtl): Perform test for NaN at the beginning of the function and
4011         through a call to isnanl.
4012         * lib/tanl.c: Include isnanl.h.
4013         (tanl): Perform test for NaN at the beginning of the function and
4014         through a call to isnanl.
4015         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
4016         * modules/mathl (Depends-on): Add isnanl.
4017
4018 2007-03-26  Eric Blake  <ebb9@byu.net>
4019
4020         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
4021         regression in logic sense of previous patch.
4022
4023 2007-03-26  Bruno Haible  <bruno@clisp.org>
4024
4025         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
4026         unportable shell command "if ! ...".
4027         Reported by Ralf Wildenhues.
4028
4029 2007-03-25  Bruno Haible  <bruno@clisp.org>
4030
4031         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
4032         <sysexits.h> file, and only add EX_CONFIG.
4033         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
4034         absolute file name and whether it is sufficient. Substitute also
4035         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
4036         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
4037         ABSOLUTE_SYSEXITS_H into sysexits.h.
4038
4039 2007-03-25  Bruno Haible  <bruno@clisp.org>
4040
4041         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
4042         hints is NULL.
4043
4044 2007-03-25  Bruno Haible  <bruno@clisp.org>
4045
4046         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
4047         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
4048
4049 2007-03-25  Bruno Haible  <bruno@clisp.org>
4050
4051         * lib/vasnprintf.c: Include langinfo.h.
4052         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
4053         multithread-safe.
4054         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
4055         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
4056         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
4057         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
4058         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
4059         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
4060         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
4061         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
4062         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
4063         Reported by Simon Josefsson.
4064
4065 2007-03-25  Bruno Haible  <bruno@clisp.org>
4066
4067         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
4068         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
4069         * modules/vasnprintf (Depends-on): Add stdint.
4070
4071 2007-03-25  Bruno Haible  <bruno@clisp.org>
4072
4073         * modules/fpieee: New file.
4074         * m4/fpieee.m4: New file.
4075         * modules/isnan-nolibm (Depends-on): Add fpieee.
4076         * modules/isnanl-nolibm (Depends-on): Add fpieee.
4077         * modules/isnanl (Depends-on): Add fpieee.
4078
4079 2007-03-25  Bruno Haible  <bruno@clisp.org>
4080
4081         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
4082
4083 2007-03-25  Bruno Haible  <bruno@clisp.org>
4084
4085         Avoid test failures on IRIX 6.5.
4086         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
4087         (main): Use it.
4088         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
4089         macros.
4090         (main): Use them.
4091
4092 2007-03-25  Bruno Haible  <bruno@clisp.org>
4093
4094         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
4095         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
4096         exists but doesn't work.
4097         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
4098         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
4099         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
4100         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
4101
4102 2007-03-25  Bruno Haible  <bruno@clisp.org>
4103
4104         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
4105         returns inf. Needed on IRIX 6.5.
4106
4107 2007-03-25  Bruno Haible  <bruno@clisp.org>
4108
4109         * tests/test-frexpl.c: Include isnanl-nolibm.h.
4110         (main): Use isnanl instead of x != x idiom.
4111         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
4112
4113         * tests/test-frexp.c: Include isnan.h.
4114         (main): Use isnan instead of x != x idiom.
4115         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
4116
4117 2007-03-25  Bruno Haible  <bruno@clisp.org>
4118
4119         * tests/test-frexp.c (NaN): New function/macro.
4120         (main): Use it instead of 0.0 / 0.0.
4121         * tests/test-isnan.c (NaN): New function/macro.
4122         (main): Use it instead of 0.0 / 0.0.
4123         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
4124         (test_function): Use it instead of 0.0 / 0.0.
4125         * tests/test-vasprintf-posix.c (NaN): New function/macro.
4126         (test_function): Use it instead of 0.0 / 0.0.
4127         * tests/test-snprintf-posix.h (NaN): New function/macro.
4128         (test_function): Use it instead of 0.0 / 0.0.
4129         * tests/test-sprintf-posix.h (NaN): New function/macro.
4130         (test_function): Use it instead of 0.0 / 0.0.
4131         * tests/test-fprintf-posix.h (NaN): New function/macro.
4132         (test_function): Use it instead of 0.0 / 0.0.
4133         * tests/test-printf-posix.h (NaN): New function/macro.
4134         (test_function): Use it instead of 0.0 / 0.0.
4135
4136         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
4137
4138 2007-03-25  Bruno Haible  <bruno@clisp.org>
4139
4140         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
4141
4142 2007-03-25  Bruno Haible  <bruno@clisp.org>
4143
4144         * lib/regexec.c (merge_state_with_log): Make static.
4145
4146 2007-03-25  Bruno Haible  <bruno@clisp.org>
4147
4148         * lib/trigl.c (kernel_rem_pio2): Make static.
4149
4150 2007-03-25  Bruno Haible  <bruno@clisp.org>
4151
4152         * lib/sincosl.c (sincosl_table): Make static.
4153
4154 2007-03-25  Bruno Haible  <bruno@clisp.org>
4155
4156         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
4157         if the compiler does not support C99.
4158
4159 2007-03-25  Bruno Haible  <bruno@clisp.org>
4160
4161         * modules/time (Makefile.am): Ensure all rule action lines start with a
4162         tab.
4163
4164 2007-03-24  Bruno Haible  <bruno@clisp.org>
4165
4166         * modules/tsearch-tests: New file.
4167         * tests/test-tsearch.sh: New file.
4168         * tests/test-tsearch.c: New file, mostly copied from glibc.
4169
4170         * modules/search-tests: New file.
4171         * tests/test-search.c: New file.
4172
4173         * modules/search: New file.
4174         * lib/search_.h: New file, incorporating lib/tsearch.h.
4175         * m4/search_h.m4: New file.
4176         * lib/tsearch.h: Remove file.
4177         * lib/tsearch.c: Include search.h instead of tsearch.h.
4178         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
4179         HAVE_TSEARCH.
4180         * modules/tsearch (Files): Remove lib/tsearch.h.
4181         (Depends-on): Add search.
4182         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
4183         (Include): Change tsearch.h into search.h.
4184
4185 2007-03-24  Bruno Haible  <bruno@clisp.org>
4186
4187         * modules/fpucw: New file.
4188         * lib/fpucw.h: New file.
4189         * lib/frexp.c: Include fpucw.h.
4190         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
4191         (FUNC): Use them.
4192         * lib/printf-frexp.c: Include fpucw.h.
4193         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
4194         (FUNC): Use them.
4195         * lib/vasnprintf.c: Include fpucw.h.
4196         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
4197         'long double' calculations.
4198         * tests/test-frexpl.c: Include fpucw.h.
4199         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
4200         * tests/test-printf-frexpl.c: Include fpucw.h.
4201         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
4202         * modules/frexpl (Depends-on): Add fpucw.
4203         * modules/printf-frexpl (Depends-on): Likewise.
4204         * modules/fprintf-posix (Depends-on): Likewise.
4205         * modules/snprintf-posix (Depends-on): Likewise.
4206         * modules/sprintf-posix (Depends-on): Likewise.
4207         * modules/vasnprintf-posix (Depends-on): Likewise.
4208         * modules/vasprintf-posix (Depends-on): Likewise.
4209         * modules/vfprintf-posix (Depends-on): Likewise.
4210         * modules/vsnprintf-posix (Depends-on): Likewise.
4211         * modules/vsprintf-posix (Depends-on): Likewise.
4212         * modules/frexpl-tests (Depends-on): Likewise.
4213         * modules/printf-frexpl-tests (Depends-on): Likewise.
4214
4215 2007-03-24  Bruno Haible  <bruno@clisp.org>
4216
4217         * lib/float+.h: New file.
4218         * lib/isnan.c: Include float+.h.
4219         (SIZE): New macro.
4220         (FUNC): Compare only SIZE bytes of the value.
4221         * lib/vasnprintf.c: Include float+.h.
4222         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
4223         SIZEOF_LDBL or SIZEOF_DBL bytes.
4224         * modules/isnan-nolibm (Files): Add lib/float+.h.
4225         * modules/isnanl-nolibm (Files): Add lib/float+.h.
4226         * modules/isnanl (Files): Add lib/float+.h.
4227         * modules/vasnprintf (Files): Add lib/float+.h.
4228
4229 2007-03-24  Bruno Haible  <bruno@clisp.org>
4230
4231         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
4232         include isnanl-nolibm.h.
4233
4234 2007-03-24  Bruno Haible  <bruno@clisp.org>
4235
4236         * tests/test-read-file.c (main): Don't produce spurious output for
4237         expected situations. Make the test fail if it encountered unexpected
4238         results.
4239
4240 2007-03-24  Bruno Haible  <bruno@clisp.org>
4241
4242         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
4243         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
4244
4245 2007-03-24  Bruno Haible  <bruno@clisp.org>
4246
4247         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
4248
4249 2007-03-24  Bruno Haible  <bruno@clisp.org>
4250
4251         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
4252         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
4253
4254         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
4255         * modules/utf8-ucs4: Turn into a symbolic link to module
4256         unistr/u8-mbtouc.
4257
4258         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
4259         utf8-ucs4-unsafe.
4260         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
4261         unistr/u8-mbtouc-unsafe.
4262
4263         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
4264         * modules/utf16-ucs4: Turn into a symbolic link to module
4265         unistr/u16-mbtouc.
4266
4267         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
4268         utf16-ucs4-unsafe.
4269         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
4270         unistr/u16-mbtouc-unsafe.
4271
4272         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
4273         * modules/ucs4-utf8: Turn into a symbolic link to module
4274         unistr/u8-ubtomb.
4275
4276         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
4277         * modules/ucs4-utf16: Turn into a symbolic link to module
4278         unistr/u16-ubtomb.
4279
4280 2007-03-24  Bruno Haible  <bruno@clisp.org>
4281
4282         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
4283         Enable the function only if HAVE_INLINE.
4284         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
4285         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
4286         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
4287         Enable the function only if HAVE_INLINE.
4288         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
4289         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
4290         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
4291         Enable the function only if HAVE_INLINE.
4292         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
4293         Enable the function only if HAVE_INLINE.
4294         * modules/utf8-ucs4: Update.
4295         * modules/utf8-ucs4-unsafe: Update.
4296         * modules/utf16-ucs4: Update.
4297         * modules/utf16-ucs4-unsafe: Update.
4298         * modules/ucs4-utf8: Update.
4299         * modules/ucs4-utf16: Update.
4300
4301 2007-03-24  Bruno Haible  <bruno@clisp.org>
4302
4303         * lib/utf8-ucs4.h: Remove file.
4304         * lib/utf8-ucs4-unsafe.h: Remove file.
4305         * lib/utf16-ucs4.h: Remove file.
4306         * lib/utf16-ucs4-unsafe.h: Remove file.
4307         * lib/ucs4-utf8.h: Remove file.
4308         * lib/ucs4-utf16.h: Remove file.
4309         * lib/unistr.h: Include their previous contents.
4310         * m4/utf-ucs4.m4: Remove file.
4311         * m4/ucs4-utf.m4: Remove file.
4312         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
4313         (Depends-on): Add unistr/base.
4314         (configure.ac): Remove gl_UTF_UCS4.
4315         (Makefile.am): Update.
4316         (Include): Change to unistr.h.
4317         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
4318         (Depends-on): Add unistr/base.
4319         (configure.ac): Remove gl_UTF_UCS4.
4320         (Makefile.am): Update.
4321         (Include): Change to unistr.h.
4322         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
4323         (Depends-on): Add unistr/base.
4324         (configure.ac): Remove gl_UTF_UCS4.
4325         (Makefile.am): Update.
4326         (Include): Change to unistr.h.
4327         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
4328         (Depends-on): Add unistr/base.
4329         (configure.ac): Remove gl_UTF_UCS4.
4330         (Makefile.am): Update.
4331         (Include): Change to unistr.h.
4332         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
4333         (Depends-on): Add unistr/base.
4334         (configure.ac): Remove gl_UCS4_UTF.
4335         (Makefile.am): Update.
4336         (Include): Change to unistr.h.
4337         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
4338         (Depends-on): Add unistr/base.
4339         (configure.ac): Remove gl_UCS4_UTF.
4340         (Makefile.am): Update.
4341         (Include): Change to unistr.h.
4342         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
4343         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
4344         utf8-ucs4-unsafe.h.
4345         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
4346         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
4347         utf16-ucs4-unsafe.h.
4348         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
4349         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
4350         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
4351         * lib/unistr/u8-strchr.c: Likewise.
4352         * lib/unistr/u8-strrchr.c: Likewise.
4353         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
4354         * lib/unistr/u16-strchr.c: Likewise.
4355         * lib/unistr/u16-strrchr.c: Likewise.
4356         * lib/striconveh.c: Update.
4357         * lib/linebreak.c: Update.
4358
4359 2007-03-24  Bruno Haible  <bruno@clisp.org>
4360
4361         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
4362         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
4363
4364 2007-03-22  Bruno Haible  <bruno@clisp.org>
4365
4366         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
4367
4368 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
4369
4370         * MODULES.html.sh (File system functions): New module write-any-file.
4371         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
4372         * m4/write-any-file.m4: New files.
4373
4374 2007-03-23  Eric Blake  <ebb9@byu.net>
4375
4376         * gnulib-tool: Rearrange space-tab sequences, since some editors
4377         like to eat them.
4378
4379 2007-03-23  Eric Blake  <ebb9@byu.net>
4380
4381         * lib/version-etc.c (version_etc_va): Update license wording to
4382         be more concise.  Recommended by Richard Stallman.
4383
4384 2007-03-22  Bruno Haible  <bruno@clisp.org>
4385
4386         * lib/poll.c (MSG_PEEK): New fallback definition.
4387
4388 2007-03-22  Bruno Haible  <bruno@clisp.org>
4389
4390         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
4391         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
4392         (main): Update.
4393         Fixes a compilation error on BeOS.
4394
4395 2007-03-22  Bruno Haible  <bruno@clisp.org>
4396
4397         * modules/frexpl-tests: New file.
4398         * tests/test-frexpl.c: New file.
4399
4400         * modules/frexpl: New file.
4401         * m4/frexpl.m4: New file.
4402         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
4403         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
4404         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
4405         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
4406         (Depends-on): Add frexpl. Remove isnanl-nolibm.
4407         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
4408
4409 2007-03-22  Bruno Haible  <bruno@clisp.org>
4410
4411         * lib/frexpl.c: Share code with lib/frexp.c.
4412         * modules/mathl (Files): Add lib/frexp.c.
4413         (Depends-on): Add isnanl-nolibm.
4414
4415 2007-03-22  Bruno Haible  <bruno@clisp.org>
4416
4417         * modules/printf-frexp (Files): Add m4/frexp.m4.
4418         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
4419         only if the found frexp function actually works.
4420
4421 2007-03-22  Bruno Haible  <bruno@clisp.org>
4422
4423         * lib/frexp.c: Remove older implementation that uses divisions.
4424
4425 2007-03-21  Bruno Haible  <bruno@clisp.org>
4426
4427         * modules/frexp-tests: New file.
4428         * tests/test-frexp.c: New file.
4429
4430         * modules/frexp: New file.
4431         * lib/frexp.c: New file.
4432         * m4/frexp.m4: New file.
4433         * lib/math_.h (frexp): New declaration.
4434         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
4435         REPLACE_FREXP.
4436         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
4437
4438 2007-03-21  Bruno Haible  <bruno@clisp.org>
4439
4440         * modules/isnanl-tests: New file.
4441         * tests/test-isnanl.c: New file.
4442
4443         * modules/isnanl: New file.
4444         * lib/isnanl.h: New file.
4445         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
4446         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
4447         gl_FUNC_ISNANL_WORKS.
4448         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
4449         New macros.
4450
4451 2007-03-21  Bruno Haible  <bruno@clisp.org>
4452
4453         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
4454         lib/isnanl.h.
4455         (Include): Update.
4456         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
4457         * lib/vasnprintf.c: Update.
4458         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
4459         tests/test-isnanl.h, remove tests/test-isnanl.c.
4460         (Makefile.am): Update.
4461         * tests/test-isnanl-nolibm.c: New file.
4462         * tests/test-isnanl.h: New file.
4463         * tests/test-isnanl.c: Remove file.
4464
4465 2007-03-21  Jim Meyering  <jim@meyering.net>
4466
4467         When trying to open ".", treat ESTALE like EACCES.
4468         * lib/savewd.c (savewd_save): Resort to forking not just upon
4469         failure with EACCES, but also when errno is ESTALE.
4470
4471 2007-03-20  Bruno Haible  <bruno@clisp.org>
4472
4473         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
4474         Needed on AIX 5.1. Reported by Matthew Woehlke.
4475
4476 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
4477
4478         Suggestions by Bruno Haible:
4479         * lib/acl-internal.h: Include "gettext.h" rather than rolling
4480         our own.
4481         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
4482         * modules/acl (Depends-on): Add gettext.
4483
4484 2007-03-19  Bruno Haible  <bruno@clisp.org>
4485
4486         * modules/iconvme: Remove file.
4487         * lib/iconvme.h: Remove file.
4488         * lib/iconvme.c: Remove file.
4489         * m4/iconvme.m4: Remove file.
4490
4491 2007-03-19  Bruno Haible  <bruno@clisp.org>
4492
4493         * doc/relocatable-maint.texi: Break long shell script line.
4494         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
4495
4496 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
4497
4498         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
4499         handle file_has_acl.
4500         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
4501         * lib/acl.c: Move header inclusions and related macro defns into
4502         lib/acl-internal.h.
4503         (S_ISLNK): Remove defn, since that's now done for us.
4504         (file_has_acl): Move to lib/file-has-acl.c.
4505         Call acl_trivial if available.  This is the crucial part of the fix.
4506         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
4507         shared within the library.  Rewrite a bit, partly to make it compatible
4508         with the GNU coding style.
4509         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
4510         Remove unnecessary double-quotes.
4511         Don't test for acl_to_text; the build will catch that.
4512         Replace acl_entries if it doesn't exist and it is needed.
4513         Check for -lsec and acl_trivial (as used on Solaris 10).
4514         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
4515         lib/file-has-acl.c.
4516         (Depends-on): Add sys_stat, for S_ISLNK.
4517
4518 2007-03-19  Ben Pfaff  <blp@gnu.org>
4519
4520         * doc/gnulib.texi: Fix typos.
4521         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
4522
4523 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
4524
4525         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
4526         If size is zero here, buf must be zero.
4527
4528 2007-03-19  Simon Josefsson  <simon@josefsson.org>
4529
4530         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
4531         <bruno@clisp.org>.
4532
4533 2007-03-18  Bruno Haible  <bruno@clisp.org>
4534
4535         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
4536         Suggested by Eric Blake.
4537
4538 2007-03-18  Ben Pfaff  <blp@gnu.org>
4539
4540         * doc/relocatable.texi: Recommend using as prefix a directory
4541         that does not exist and will never be created.  Based on
4542         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
4543         and others.
4544
4545 2007-03-17  Bruno Haible  <bruno@clisp.org>
4546
4547         * lib/fchownat.c: Include lchown.h.
4548
4549 2007-03-17  Bruno Haible  <bruno@clisp.org>
4550
4551         Fix endless loop when the given allocated size was > INT_MAX.
4552         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
4553         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
4554         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
4555         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
4556         * lib/sprintf.c (sprintf): Likewise.
4557
4558 2007-03-17  Bruno Haible  <bruno@clisp.org>
4559
4560         * tests/test-argp-2.sh (func_compare): Output a context diff.
4561
4562 2007-03-17  Bruno Haible  <bruno@clisp.org>
4563
4564         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
4565         locale's decimal-point character.
4566
4567 2007-03-17  Bruno Haible  <bruno@clisp.org>
4568
4569         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
4570         before comparing it. Needed because on some platforms (e.g. x86) a
4571         'long double' occupies less bytes than sizeof (long double).
4572
4573 2007-03-17  Bruno Haible  <bruno@clisp.org>
4574
4575         * tests/test-crc.c (main): Make printf statements 64-bit clean.
4576         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
4577         * tests/test-getaddrinfo.c (simple): Likewise.
4578         * tests/test-read-file.c (main): Likewise.
4579
4580 2007-03-17  Bruno Haible  <bruno@clisp.org>
4581
4582         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
4583
4584 2007-03-17  Bruno Haible  <bruno@clisp.org>
4585
4586         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
4587         unused variable.
4588
4589 2007-03-17  Bruno Haible  <bruno@clisp.org>
4590
4591         * tests/test-c-strcasecmp.c: Include c-strcase.h.
4592         * tests/test-c-strncasecmp.c: Likewise.
4593
4594 2007-03-17  Bruno Haible  <bruno@clisp.org>
4595
4596         * modules/stdlib (Depends-on): Add unistd.
4597         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
4598         Needed for MacOS X 10.3.
4599
4600 2007-03-17  Bruno Haible  <bruno@clisp.org>
4601
4602         * lib/unistr/u-strdup.h: Include <stdlib.h>.
4603
4604 2007-03-17  Bruno Haible  <bruno@clisp.org>
4605
4606         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
4607
4608 2007-03-17  Bruno Haible  <bruno@clisp.org>
4609
4610         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
4611         to reflect files copied from gnulib (with or without modifications).
4612         Suggested by Jim Meyering.
4613
4614 2007-03-17  Eric Blake  <ebb9@byu.net>
4615
4616         * NEWS: Document stdlib change from 2007-02-18.
4617
4618 2007-03-17  Jim Meyering  <jim@meyering.net>
4619
4620         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
4621         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
4622         someone uses a name containing shell meta-characters.
4623         Reported by Alfred M. Szmidt.
4624
4625         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
4626
4627 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
4628
4629         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
4630         and copy gettext configuration files only if configure.ac contains
4631         a use of AM_GNU_GETTEXT_VERSION.
4632
4633 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
4634
4635         * build-aux/bootstrap (gnulib_name): New variable.
4636         (gnulib_tool_options): Use it.
4637
4638 2007-03-13  Simon Josefsson  <simon@josefsson.org>
4639
4640         * tests/test-des.c: Use new namespace.
4641
4642 2007-03-15  Bruno Haible  <bruno@clisp.org>
4643
4644         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
4645         Reported by James Youngman <jay@gnu.org>.
4646
4647 2007-03-15  Bruno Haible  <bruno@clisp.org>
4648
4649         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
4650         declared prototype. Needed with cc on OSF/1 5.1.
4651
4652 2007-03-15  Bruno Haible  <bruno@clisp.org>
4653
4654         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
4655         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
4656         (struct gl_list_implementation): Add dispose_fn argument to the
4657         'create_empty', 'create' methods.
4658         (struct gl_list_impl_base): Add field 'dispose_fn'.
4659         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
4660         argument.
4661         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
4662         dispose_fn argument.
4663         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
4664         dispose_fn on the dropped values.
4665         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
4666         dispose_fn argument.
4667         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
4668         dropped values.
4669         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
4670         (gl_tree_remove_node): Call dispose_fn on the dropped value.
4671         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
4672         (gl_tree_remove_node): Call dispose_fn on the dropped value.
4673         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
4674         argument.
4675         (gl_tree_list_free): Call dispose_fn on the dropped values.
4676         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
4677         the dropped values.
4678         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
4679         Add dispose_fn argument.
4680         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
4681         Call dispose_fn on the dropped values.
4682         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
4683         Add dispose_fn argument.
4684         (gl_sublist_create): Initialize the 'dispose_fn' field.
4685         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
4686         * tests/test-array_list.c (main): Update.
4687         * tests/test-carray_list.c (main): Update.
4688         * tests/test-avltree_list.c (main): Update.
4689         * tests/test-rbtree_list.c (main): Update.
4690         * tests/test-avltreehash_list.c (main): Update.
4691         * tests/test-rbtreehash_list.c (main): Update.
4692         * tests/test-linked_list.c (main): Update.
4693         * tests/test-linkedhash_list.c (main): Update.
4694         * tests/test-array_oset.c (main): Update.
4695
4696 2007-03-15  Bruno Haible  <bruno@clisp.org>
4697
4698         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
4699         (gl_oset_create_empty): Add dispose_fn argument.
4700         (struct gl_oset_implementation): Add dispose_fn argument to
4701         'create_empty' method.
4702         (struct gl_oset_impl_base): Add dispose_fn field.
4703         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
4704         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
4705         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
4706         values.
4707         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
4708         (gl_tree_oset_free): Call dispose_fn on the dropped values.
4709         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
4710         dropped value.
4711         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
4712         dropped value.
4713         * tests/test-array_oset.c (main): Update.
4714         * tests/test-avltree_oset.c (main): Update.
4715         * tests/test-rbtree_oset.c (main): Update.
4716         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
4717
4718 2007-03-13  Bruno Haible  <bruno@clisp.org>
4719
4720         * tests/test-stdbool.c (i): Update after last patch.
4721
4722 2007-03-12  Bruno Haible  <bruno@clisp.org>
4723
4724         * lib/quotearg.c: Include <wctype.h> early, before the definition of
4725         the iswprint macro. Needed on Solaris 2.5.1.
4726
4727 2007-03-12  Bruno Haible  <bruno@clisp.org>
4728
4729         * tests/test-printf-frexp.c (main): Declare x as volatile.
4730
4731 2007-03-12  Simon Josefsson  <simon@josefsson.org>
4732
4733         * doc/gnulib.texi (Build robot for gnulib): New section.
4734
4735 2007-03-12  Jim Meyering  <jim@meyering.net>
4736
4737         * build-aux/bootstrap: New file.
4738         * build-aux/bootstrap.conf: New file, from coreutils.
4739
4740 2007-03-11  Bruno Haible  <bruno@clisp.org>
4741
4742         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
4743
4744 2007-03-12  Simon Josefsson  <simon@josefsson.org>
4745
4746         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
4747         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
4748         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
4749
4750 2007-03-11  Bruno Haible  <bruno@clisp.org>
4751
4752         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
4753         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
4754
4755 2007-03-11  Bruno Haible  <bruno@clisp.org>
4756
4757         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
4758         formula. Needed for SunPRO C 5.0.
4759
4760 2007-03-11  Bruno Haible  <bruno@clisp.org>
4761
4762         * modules/long-options (Depends-on): Add getopt.
4763
4764 2007-03-11  Bruno Haible  <bruno@clisp.org>
4765
4766         * modules/modechange (Depends-on): Add stdbool.
4767
4768 2007-03-11  Bruno Haible  <bruno@clisp.org>
4769
4770         * modules/i-ring (Depends-on): Add stdbool.
4771
4772 2007-03-11  Bruno Haible  <bruno@clisp.org>
4773
4774         * modules/gc-des (Depends-on): Add stdbool.
4775
4776 2007-03-11  Bruno Haible  <bruno@clisp.org>
4777
4778         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
4779
4780 2007-03-11  Bruno Haible  <bruno@clisp.org>
4781
4782         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
4783
4784 2007-03-11  Bruno Haible  <bruno@clisp.org>
4785
4786         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
4787
4788 2007-03-11  Bruno Haible  <bruno@clisp.org>
4789
4790         * lib/vasnprintf.c (sprintf): Undefine.
4791
4792 2007-03-11  Bruno Haible  <bruno@clisp.org>
4793
4794         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
4795         initializers in SunPRO C and Compaq C compilers.
4796
4797 2007-03-11  Bruno Haible  <bruno@clisp.org>
4798
4799         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
4800         decrementing code ANSI C compliant.
4801
4802 2007-03-11  Bruno Haible  <bruno@clisp.org>
4803
4804         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
4805         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
4806
4807 2007-03-11  Bruno Haible  <bruno@clisp.org>
4808
4809         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
4810         <stdbool.h> substitute doesn't pass.
4811
4812 2007-03-11  Bruno Haible  <bruno@clisp.org>
4813
4814         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
4815
4816 2007-03-11  Bruno Haible  <bruno@clisp.org>
4817
4818         * gnulib-tool (func_create_megatestdir): Create also an autobuild
4819         script, for submission to autobuild.josefsson.org.
4820
4821 2007-03-10  Bruno Haible  <bruno@clisp.org>
4822
4823         * modules/canonicalize-lgpl-tests: New file.
4824         * tests/test-canonicalize-lgpl.sh: New file.
4825         * tests/test-canonicalize-lgpl.c: New file.
4826
4827         * modules/c-strcase-tests: New file.
4828         * tests/test-c-strcase.sh: New file.
4829         * tests/test-c-strcasecmp.c: New file.
4830         * tests/test-c-strncasecmp.c: New file.
4831
4832         * modules/atexit-tests: New file.
4833         * tests/test-atexit.sh: New file.
4834         * tests/test-atexit.c: New file.
4835
4836 2007-03-10  Bruno Haible  <bruno@clisp.org>
4837
4838         * tests/test-binary-io.sh: Use temporary filenames that are not so
4839         likely to clash with those of other tests (in a parallel make).
4840         * tests/test-binary-io.c: Likewise.
4841
4842 2007-03-10  Bruno Haible  <bruno@clisp.org>
4843
4844         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
4845         fallback; use #error instead.
4846         Suggested by Simon Josefsson.
4847
4848 2007-03-10  Bruno Haible  <bruno@clisp.org>
4849
4850         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
4851         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
4852         first and the last.
4853
4854 2007-03-10  Bruno Haible  <bruno@clisp.org>
4855
4856         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
4857
4858 2007-03-10  Bruno Haible  <bruno@clisp.org>
4859
4860         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
4861         "make distcheck".
4862         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
4863         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
4864         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
4865
4866 2007-03-10  Bruno Haible  <bruno@clisp.org>
4867
4868         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
4869         variable.
4870         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
4871         variable.
4872
4873 2007-03-09  Eric Blake  <ebb9@byu.net>
4874         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
4875
4876         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
4877         types are not being provided by gnulib.
4878         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
4879         types are supported.
4880
4881 2007-03-10  Bruno Haible  <bruno@clisp.org>
4882
4883         * lib/stdio_.h (__attribute__): New macro.
4884         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
4885         vsprintf): Specify __attribute__ __format__ for GCC.
4886         Suggested by Eric Blake.
4887
4888 2007-03-09  Bruno Haible  <bruno@clisp.org>
4889
4890         * modules/printf-posix-tests: New file.
4891         * tests/test-printf-posix.sh: New file.
4892         * tests/test-printf-posix.c: New file.
4893
4894         * modules/printf-posix: New file.
4895         * lib/printf.c: New file.
4896         * m4/printf-posix-rpl.m4: New file.
4897         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
4898         REPLACE_PRINTF.
4899         * lib/stdio_.h (printf): New declaration.
4900         (format, __format__, ____printf____, ____scanf____, ____strftime____,
4901         ____strfmon____): New macros.
4902         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
4903         REPLACE_PRINTF.
4904
4905 2007-03-09  Bruno Haible  <bruno@clisp.org>
4906
4907         * tests/test-vasnprintf-posix2.sh: New file.
4908         * tests/test-vasnprintf-posix2.c: New file.
4909         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
4910         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
4911         (Makefile.am): Activate test-vasnprintf-posix2.sh.
4912
4913         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
4914         a locale dependent decimal point, rather than always '.'.
4915
4916 2007-03-09  Eric Blake  <ebb9@byu.net>
4917
4918         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
4919         spite of platforms like Tandem/NSK that define it to -1.
4920
4921 2007-03-08  Bruno Haible  <bruno@clisp.org>
4922
4923         * modules/vprintf-posix-tests: New file.
4924         * tests/test-vprintf-posix.sh: New file.
4925         * tests/test-vprintf-posix.c: New file.
4926         * tests/test-printf-posix.h: New file.
4927
4928         * modules/vprintf-posix: New file.
4929         * lib/vprintf.c: New file.
4930         * m4/vprintf-posix.m4: New file.
4931         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
4932         REPLACE_VPRINTF.
4933         * lib/stdio_.h (vprintf): New declaration.
4934         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
4935         REPLACE_VPRINTF.
4936
4937 2007-03-08  Bruno Haible  <bruno@clisp.org>
4938
4939         * modules/fprintf-posix-tests: New file.
4940         * tests/test-fprintf-posix.sh: New file.
4941         * tests/test-fprintf-posix.c: New file.
4942
4943         * modules/fprintf-posix: New file.
4944         * lib/fprintf.c: New file.
4945         * m4/fprintf-posix.m4: New file.
4946         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
4947         REPLACE_FPRINTF.
4948         * lib/stdio_.h (fprintf): New declaration.
4949         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
4950         REPLACE_FPRINTF.
4951
4952 2007-03-08  Bruno Haible  <bruno@clisp.org>
4953
4954         * modules/vfprintf-posix-tests: New file.
4955         * tests/test-vfprintf-posix.sh: New file.
4956         * tests/test-vfprintf-posix.c: New file.
4957         * tests/test-fprintf-posix.h: New file.
4958         * tests/test-fprintf-posix.out: New file.
4959
4960         * modules/vfprintf-posix: New file.
4961         * lib/vfprintf.c: New file.
4962         * m4/vfprintf-posix.m4: New file.
4963         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
4964         REPLACE_VFPRINTF.
4965         * lib/stdio_.h (vfprintf): New declaration.
4966         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
4967         REPLACE_VFPRINTF.
4968
4969 2007-03-08  Bruno Haible  <bruno@clisp.org>
4970
4971         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
4972
4973 2007-03-08  Bruno Haible  <bruno@clisp.org>
4974
4975         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
4976         instead of 'expr' invocations.
4977         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
4978         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
4979         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
4980         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
4981         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
4982         Suggested by Paul Eggert.
4983
4984 2007-03-08  Bruno Haible  <bruno@clisp.org>
4985
4986         * modules/fseterr-tests: New file.
4987         * tests/test-fseterr.c: New file.
4988
4989         * modules/fseterr: New file.
4990         * lib/fseterr.h: New file.
4991         * lib/fseterr.c: New file.
4992
4993 2007-03-08  Bruno Haible  <bruno@clisp.org>
4994
4995         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
4996         * lib/getopt_.h: Likewise.
4997         * lib/mbswidth.h: Likewise.
4998         * lib/setenv.h: Likewise.
4999         * lib/vasnprintf.h: Likewise.
5000         * lib/vasprintf.h: Likewise.
5001         * lib/verror.h: Likewise.
5002         * lib/xsetenv.h: Likewise.
5003         * lib/xvasprintf.h: Likewise.
5004
5005 2007-03-08  Jim Meyering  <jim@meyering.net>
5006
5007         * users.txt: Add parted.
5008
5009         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
5010
5011 2007-03-07  Bruno Haible  <bruno@clisp.org>
5012
5013         * m4/printf.m4: Make the shell script snippets copy&pastable.
5014
5015 2007-03-02  Bruno Haible  <bruno@clisp.org>
5016
5017         * lib/netinet_in_.h: New file.
5018         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
5019         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
5020         * modules/netinet_in (Files): Add lib/netinet_in_.h.
5021         (Depends-on): Add absolute-header.
5022         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
5023         into netinet/in.h.
5024
5025 2007-03-03  Bruno Haible  <bruno@clisp.org>
5026
5027         * lib/sys_select_.h: New file.
5028         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
5029         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
5030         * modules/sys_select (Files): Add lib/sys_select_.h.
5031         (Depends-on): Add absolute-header.
5032         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
5033         into sys/select.h.
5034
5035 2007-03-02  Bruno Haible  <bruno@clisp.org>
5036
5037         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
5038         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
5039         values.
5040         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
5041         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
5042         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
5043         * modules/sys_socket (Depends-on): Add absolute-header.
5044         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
5045         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
5046         (Include): Remove requirement of inclusion of <sys/types.h>.
5047
5048 2007-03-02  Bruno Haible  <bruno@clisp.org>
5049
5050         * lib/byteswap_.h (bswap_32): Fix formula.
5051
5052 2007-03-06  Bruno Haible  <bruno@clisp.org>
5053
5054         * modules/sprintf-posix-tests: New file.
5055         * tests/test-sprintf-posix.c: New file.
5056
5057         * modules/sprintf-posix: New file.
5058         * lib/sprintf.c: New file.
5059         * m4/sprintf-posix.m4: New file.
5060         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
5061         REPLACE_SPRINTF.
5062         * lib/stdio_.h (sprintf): New declaration.
5063         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
5064         REPLACE_SPRINTF.
5065
5066 2007-03-06  Bruno Haible  <bruno@clisp.org>
5067
5068         * modules/vsprintf-posix-tests: New file.
5069         * tests/test-vsprintf-posix.c: New file.
5070         * tests/test-sprintf-posix.h: New file.
5071
5072         * modules/vsprintf-posix: New file.
5073         * lib/vsprintf.c: New file.
5074         * m4/vsprintf-posix.m4: New file.
5075         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
5076         REPLACE_VSPRINTF.
5077         * lib/stdio_.h (vsprintf): New declaration.
5078         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
5079         REPLACE_VSPRINTF.
5080
5081 2007-03-06  Bruno Haible  <bruno@clisp.org>
5082
5083         * modules/vsnprintf (Depend-on): Remove minmax.
5084
5085 2007-03-06  Bruno Haible  <bruno@clisp.org>
5086
5087         * modules/snprintf-posix-tests: New file.
5088         * tests/test-snprintf-posix.c: New file.
5089
5090         * modules/snprintf-posix: New file.
5091         * m4/snprintf-posix.m4: New file.
5092         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
5093         gl_FUNC_SNPRINTF.
5094         (gl_FUNC_SNPRINTF): Invoke it.
5095         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
5096         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
5097         is set.
5098         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
5099
5100 2007-03-06  Bruno Haible  <bruno@clisp.org>
5101
5102         * modules/vsnprintf-posix-tests: New file.
5103         * tests/test-vsnprintf-posix.c: New file.
5104         * tests/test-snprintf-posix.h: New file.
5105
5106         * modules/vsnprintf-posix: New file.
5107         * m4/vsnprintf-posix.m4: New file.
5108         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
5109         gl_FUNC_VSNPRINTF.
5110         (gl_FUNC_VSNPRINTF): Invoke it.
5111         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
5112         * lib/stdio_.h (vsnprintf): Define as a replacement if
5113         REPLACE_VSNPRINTF is set.
5114         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
5115
5116 2007-03-06  Bruno Haible  <bruno@clisp.org>
5117
5118         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
5119         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
5120
5121 2007-03-06  Bruno Haible  <bruno@clisp.org>
5122
5123         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
5124         (asinl): Declare also if HAVE_DECL_ASINL is set.
5125         (atanl): Declare also if HAVE_DECL_ATANL is set.
5126         (ceill): Declare also if HAVE_DECL_CEILL is set.
5127         (cosl): Declare also if HAVE_DECL_COSL is set.
5128         (expl): Declare also if HAVE_DECL_EXPL is set.
5129         (floorl): Declare also if HAVE_DECL_FLOORL is set.
5130         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
5131         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
5132         (logl): Declare also if HAVE_DECL_LOGL is set.
5133         (sinl): Declare also if HAVE_DECL_SINL is set.
5134         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
5135         (tanl): Declare also if HAVE_DECL_TANL is set.
5136         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
5137         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
5138         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
5139         declaration of frexpl, ldexpl.
5140         * modules/printf-frexpl (Depends-on): Add math.
5141         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
5142
5143 2007-03-05  Bruno Haible  <bruno@clisp.org>
5144
5145         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
5146         frexpl and ldexpl are declared.
5147         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
5148
5149 2007-03-05  Bruno Haible  <bruno@clisp.org>
5150
5151         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
5152         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
5153
5154 2007-03-05  Bruno Haible  <bruno@clisp.org>
5155
5156         * lib/stdio_.h: Include <stddef.h>.
5157
5158 2007-03-05  Bruno Haible  <bruno@clisp.org>
5159
5160         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
5161
5162 2007-03-05  Bruno Haible  <bruno@clisp.org>
5163
5164         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
5165         NetBSD 4, from Ralf Wildenhues.
5166
5167 2007-03-04  Bruno Haible  <bruno@clisp.org>
5168
5169         * lib/vasprintf.h: Update #if logic for the case when the functions
5170         exist but are overridden.
5171
5172 2007-03-04  Bruno Haible  <bruno@clisp.org>
5173
5174         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
5175         implementations: glibc-2.4 and MacOS X 10.3.
5176         * tests/test-vasnprintf-posix.c (test_function): Test also the case
5177         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
5178         * tests/test-vasprintf-posix.c (test_function): Likewise.
5179
5180 2007-03-04  Bruno Haible  <bruno@clisp.org>
5181
5182         * modules/vasprintf-posix-tests: New file.
5183         * tests/test-vasprintf-posix.c: New file.
5184
5185         * modules/vasprintf-posix: New file.
5186         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
5187         defined.
5188         * m4/vasprintf-posix.m4: New file.
5189         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
5190         gl_FUNC_VASPRINTF.
5191         (gl_FUNC_VASPRINTF): Invoke it.
5192         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
5193         here.
5194         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
5195
5196 2007-03-04  Bruno Haible  <bruno@clisp.org>
5197
5198         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
5199         REPLACE_GETTIMEOFDAY.
5200         * modules/sys_time (Makefile.am): Likewise.
5201         * m4/sys_time_h.m4: Likewise.
5202         * m4/gettimeofday.m4: Likewise.
5203
5204 2007-03-04  Bruno Haible  <bruno@clisp.org>
5205
5206         * modules/vasnprintf-posix-tests: New file.
5207         * tests/test-vasnprintf-posix.c: New file.
5208
5209         * modules/vasnprintf-posix: New file.
5210         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
5211         printf-frexpl.h.
5212         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
5213         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
5214         REPLACE_VASNPRINTF is defined.
5215         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
5216         gl_FUNC_VASNPRINTF.
5217         (gl_FUNC_VASNPRINTF): Invoke it.
5218         * m4/vasnprintf-posix.m4: New file.
5219         * m4/printf.m4: New file.
5220
5221 2007-03-04  Bruno Haible  <bruno@clisp.org>
5222
5223         Compile progreloc.c only if --enable-relocatable is specified.
5224         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
5225         if --enable-relocatable was specified.
5226         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
5227         lib_SOURCES.
5228
5229 2007-03-04  Jim Meyering  <jim@meyering.net>
5230
5231         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
5232         Use it consistently, rather than enumerating errno constants.
5233
5234 2007-03-04  Bruno Haible  <bruno@clisp.org>
5235
5236         * modules/xvasprintf-tests: New file.
5237         * tests/test-xvasprintf.c: New file.
5238
5239         * modules/vasprintf-tests: New file.
5240         * tests/test-vasprintf.c: New file.
5241
5242         * modules/vasnprintf-tests: New file.
5243         * tests/test-vasnprintf.c: New file.
5244
5245         * modules/vsnprintf-tests: New file.
5246         * tests/test-vsnprintf.c: New file.
5247
5248         * modules/snprintf-tests: New file.
5249         * tests/test-snprintf.c: New file.
5250
5251 2007-03-04  Bruno Haible  <bruno@clisp.org>
5252
5253         Compile relocatable.c only if --enable-relocatable is specified.
5254         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
5255         gl_RELOCATABLE_LIBRARY.
5256         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
5257         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
5258         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
5259         gl_RELOCATABLE_LIBRARY.
5260         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
5261         (Makefile.am): Remove lib_SOURCES.
5262         * modules/relocatable-lib-lgpl (configure.ac): Invoke
5263         gl_RELOCATABLE_LIBRARY.
5264         (Makefile.am): Remove lib_SOURCES.
5265         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
5266         always.
5267         * modules/relocatable-prog-wrapper (configure.ac): Invoke
5268         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
5269
5270 2007-03-04  Bruno Haible  <bruno@clisp.org>
5271
5272         * modules/argmatch-tests: New file.
5273         * tests/test-argmatch.c: New file.
5274
5275         * tests/test-allocsa.c (main): Halve the number of loop runs.
5276
5277         * modules/alloca-opt-tests: New file.
5278         * tests/test-alloca-opt.c: New file.
5279
5280 2007-03-04  Jim Meyering  <jim@meyering.net>
5281
5282         Work around difference between Linux ACLs and Solaris 10 ZFS.
5283         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
5284         for EINVAL.
5285
5286 2007-03-03  Bruno Haible  <bruno@clisp.org>
5287
5288         * modules/relocatable-prog (Depends-on): Add back progreloc's
5289         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
5290
5291 2007-03-03  Bruno Haible  <bruno@clisp.org>
5292
5293         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
5294         * modules/relocatable-lib: New file.
5295
5296 2007-03-03  Bruno Haible  <bruno@clisp.org>
5297
5298         * modules/relocatable-prog: Renamed from modules/relocatable.
5299         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
5300
5301 2007-03-03  Bruno Haible  <bruno@clisp.org>
5302
5303         * modules/relocatable-script (Files): Add doc/relocatable.texi,
5304         m4/relocatable-lib.m4.
5305         (Depends-on): Remove 'relocatable'.
5306         (configure.ac): Add gl_RELOCATABLE_NOP.
5307
5308 2007-03-03  Bruno Haible  <bruno@clisp.org>
5309
5310         * modules/relocatable-prog-wrapper: New file.
5311         * modules/relocatable (Depends-on): Add it. Remove all other
5312         dependencies except progname.
5313         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
5314
5315         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
5316         (gl_FUNC_STRERROR): Nop.
5317         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
5318
5319         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
5320         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
5321
5322         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
5323         (gl_FUNC_READLINK): Update.
5324
5325         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
5326
5327 2007-03-03  Bruno Haible  <bruno@clisp.org>
5328
5329         * lib/xreadlink.c: Include <unistd.h> unconditionally.
5330         * modules/xreadlink (Depends-on): Add unistd.
5331         * modules/xreadlink-with-size (Depends-on): Likewise.
5332
5333 2007-03-03  Bruno Haible  <bruno@clisp.org>
5334
5335         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
5336         extracted from gt_FUNC_SETENV.
5337         (gt_FUNC_SETENV): Remove macro.
5338         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
5339         remove gt_FUNC_SETENV.
5340
5341 2007-03-03  Bruno Haible  <bruno@clisp.org>
5342
5343         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
5344         ENABLE_RELOCATABLE here.
5345         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
5346
5347 2007-03-03  Bruno Haible  <bruno@clisp.org>
5348
5349         * modules/rbtreehash-list-tests (Depends-on): Add progname.
5350         * tests/test-rbtreehash_list.c: Include progname.h.
5351         (main): Call set_program_name.
5352
5353         * modules/rbtree-oset-tests (Depends-on): Add progname.
5354         * tests/test-rbtree_oset.c: Include progname.h.
5355         (main): Call set_program_name.
5356
5357         * modules/rbtree-list-tests (Depends-on): Add progname.
5358         * tests/test-rbtree_list.c: Include progname.h.
5359         (main): Call set_program_name.
5360
5361         * modules/linked-list-tests (Depends-on): Add progname.
5362         * tests/test-linked_list.c: Include progname.h.
5363         (main): Call set_program_name.
5364
5365 2007-03-03  Bruno Haible  <bruno@clisp.org>
5366
5367         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
5368         All uses of __restrict changed to _Restrict_.
5369         * lib/glob_.h (__restrict): Remove macro.
5370
5371 2007-03-02  Bruno Haible  <bruno@clisp.org>
5372
5373         * modules/gettext (configure.ac): Require gettext infrastructure
5374         from version 0.16.1.
5375
5376 2007-03-02  Bruno Haible  <bruno@clisp.org>
5377
5378         * modules/linkedhash-list-tests (Depends-on): Add progname.
5379         * tests/test-linkedhash_list.c: Include progname.h.
5380         (main): Call set_program_name.
5381
5382         * modules/carray-list-tests (Depends-on): Add progname.
5383         * tests/test-carray_list.c: Include progname.h.
5384         (main): Call set_program_name.
5385
5386         * modules/avltreehash-list-tests (Depends-on): Add progname.
5387         * tests/test-avltreehash_list.c: Include progname.h.
5388         (main): Call set_program_name.
5389
5390         * modules/avltree-oset-tests (Depends-on): Add progname.
5391         * tests/test-avltree_oset.c: Include progname.h.
5392         (main): Call set_program_name.
5393
5394         * modules/avltree-list-tests (Depends-on): Add progname.
5395         * tests/test-avltree_list.c: Include progname.h.
5396         (main): Call set_program_name.
5397
5398         * modules/array-oset-tests (Depends-on): Add progname.
5399         * tests/test-array_oset.c: Include progname.h.
5400         (main): Call set_program_name.
5401
5402         * modules/array-list-tests (Depends-on): Add progname.
5403         * tests/test-array_list.c: Include progname.h.
5404         (main): Call set_program_name.
5405
5406         * modules/argp-tests (Depends-on): Add progname.
5407         * tests/test-argp.c: Include argp.h first. Include progname.h.
5408         (main): Call set_program_name.
5409
5410 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
5411
5412         * doc/gnulib-tool.texi (Initial import): Reword description of
5413         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
5414         limited effect even if defined after the first system include.
5415
5416 2007-03-01  Bruno Haible  <bruno@clisp.org>
5417
5418         * build-aux/config.libpath: Update to libtool-1.5.22.
5419         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
5420
5421 2007-03-01  Bruno Haible  <bruno@clisp.org>
5422
5423         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
5424         foo_CFLAGS.
5425         Reported by Ralf Wildenhues.
5426
5427 2007-03-01  Bruno Haible  <bruno@clisp.org>
5428
5429         * build-aux/install-reloc: Remove object files left over by some
5430         compilers.
5431         Reported by Ralf Wildenhues.
5432
5433 2007-03-01  Bruno Haible  <bruno@clisp.org>
5434
5435         * build-aux/install-reloc: Break long lines.
5436
5437 2007-03-01  Bruno Haible  <bruno@clisp.org>
5438
5439         * doc/relocatable.texi: Document that it may not work on OpenBSD.
5440         Reported by Ralf Wildenhues.
5441
5442 2007-03-01  Bruno Haible  <bruno@clisp.org>
5443
5444         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
5445         include ordering constraints.
5446
5447 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
5448
5449         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
5450         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
5451         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
5452         as another example.
5453         * lib/time_.h: Fix misspelling.
5454         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
5455         Require gl_HEADER_TIME_H_DEFAULTS.
5456         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
5457         * m4/time_r.m4 (gl_TIME_R): Likewise.
5458         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
5459
5460 2007-03-01  Bruno Haible  <bruno@clisp.org>
5461
5462         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
5463         * m4/utimens.m4 (gl_UTIMENS): Likewise.
5464
5465 2007-03-01  Jim Meyering  <jim@meyering.net>
5466
5467         * modules/xreadlink (Maintainer): Add my name.
5468         * modules/xreadlink-with-size (Depends-on): Alphabetize.
5469
5470 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
5471             Bruno Haible  <bruno@clisp.org>
5472
5473         * build-aux/install-reloc: Compile also c-ctype.c.
5474         * build-aux/relocatable.sh.in: New file.
5475         * doc/relocatable.texi: New file.
5476         * doc/relocatable-maint.texi: New file.
5477         * doc/gnulib.texi: Include relocatable-maint.texi.
5478         * lib/progreloc.c: Include unistd.h unconditionally.
5479         * lib/relocwrapper.c: Include unistd.h unconditionally.
5480         Include c-ctype.h.
5481         (add_dotbin): Use c_tolower.
5482         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
5483         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
5484         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
5485         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
5486         to m4/relocatable-lib.m4.
5487         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
5488         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
5489         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
5490         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
5491         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
5492         * modules/relocatable: New file.
5493         * modules/relocatable-lib: New file.
5494         * modules/relocatable-script: New file.
5495
5496 2007-02-28  Bruno Haible  <bruno@clisp.org>
5497
5498         Import --enable-relocatable infrastructure.
5499         * build-aux/config.libpath: New file, from GNU gettext.
5500         * build-aux/install-reloc: New file, from GNU gettext.
5501         * build-aux/reloc-ldflags: New file, from GNU gettext.
5502         * lib/relocatable.h: New file, from GNU gettext.
5503         * lib/relocatable.c: New file, from GNU gettext.
5504         * lib/relocwrapper.c: New file, from GNU gettext.
5505         * m4/relocatable.m4: New file, from GNU gettext.
5506
5507 2007-02-28  Bruno Haible  <bruno@clisp.org>
5508
5509         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
5510
5511         * modules/xreadlink: New file, from GNU gettext with modifications.
5512         * lib/xreadlink.c: New file, from GNU gettext.
5513         * lib/xreadlink.h: Add comments.
5514         (xreadlink): New declaration.
5515
5516         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
5517         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
5518         lib/xreadlink-with-size.c.
5519         (configure.ac): Remove gl_XREADLINK invocation.
5520         (Makefile.am): Augment lib_SOURCES.
5521         * m4/xreadlink.m4: Remove file.
5522         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
5523         (xreadlink_with_size): Renamed from xreadink.
5524         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
5525         * modules/canonicalize (Depends-on): Replace xreadlink with
5526         xreadlink-with-size.
5527         * lib/canonicalize.c (canonicalize_filename_mode): Update.
5528
5529 2007-02-25  Jim Meyering  <jim@meyering.net>
5530
5531         * build-aux/announce-gen: When complaining about excess arguments,
5532         list them.
5533
5534 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
5535
5536         * README: Document signed integer overflow situation more
5537         accurately.
5538
5539 2007-02-25  Bruno Haible  <bruno@clisp.org>
5540
5541         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
5542         'a' or 'A' conversion.
5543
5544 2007-02-25  Bruno Haible  <bruno@clisp.org>
5545
5546         * modules/filename: Renamed from modules/pathname.
5547         (Files): Replace lib/pathname.h with lib/filename.h. Replace
5548         lib/concatpath.c with lib/concat-filename.c.
5549         (Makefile.am): Update.
5550         (Include): Replace pathname.h with filename.h.
5551         * lib/filename.h: Renamed from lib/pathname.h.
5552         (concatenated_filename): Renamed from concatenated_pathname.
5553         * lib/concat-filename.c: Renamed from lib/concatpath.c.
5554         (concatenated_filename): Renamed from concatenated_pathname.
5555         * lib/findprog.c: Include filename.h instead of pathname.h.
5556         (find_in_path): Update.
5557         * lib/javacomp.c: Include filename.h instead of pathname.h.
5558         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
5559         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
5560         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
5561         is_oldgcj_14_13_usable, is_javac_usable): Update.
5562         * lib/javaexec.c: Include filename.h instead of pathname.h.
5563         (execute_java_class): Update.
5564         * modules/findprog: Update.
5565         * modules/javacomp: Update.
5566         * modules/javaexec: Update.
5567         * MODULES.html.sh (File system functions): Add 'filename', remove
5568         'pathname'.
5569
5570 2007-02-25  Bruno Haible  <bruno@clisp.org>
5571
5572         * modules/printf-frexpl-tests: New file.
5573         * tests/test-printf-frexpl.c: New file.
5574
5575         * modules/printf-frexpl: New file.
5576         * lib/printf-frexpl.h: New file.
5577         * lib/printf-frexpl.c: New file.
5578         * m4/printf-frexpl.m4: New file.
5579
5580 2007-02-25  Bruno Haible  <bruno@clisp.org>
5581
5582         * modules/printf-frexp-tests: New file.
5583         * tests/test-printf-frexp.c: New file.
5584
5585         * modules/printf-frexp: New file.
5586         * lib/printf-frexp.h: New file.
5587         * lib/printf-frexp.c: New file.
5588         * m4/printf-frexp.m4: New file.
5589
5590 2007-02-25  Bruno Haible  <bruno@clisp.org>
5591
5592         Assume automake >= 1.10 for the tests.
5593         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
5594         * modules/arctwo-tests: Likewise.
5595         * modules/argp-tests: Likewise.
5596         * modules/avltree-list-tests: Likewise.
5597         * modules/avltree-oset-tests: Likewise.
5598         * modules/avltreehash-list-tests: Likewise.
5599         * modules/carray-list-tests: Likewise.
5600         * modules/crc-tests: Likewise.
5601         * modules/des-tests: Likewise.
5602         * modules/gc-arcfour-tests: Likewise.
5603         * modules/gc-arctwo-tests: Likewise.
5604         * modules/gc-des-tests: Likewise.
5605         * modules/gc-hmac-md5-tests: Likewise.
5606         * modules/gc-hmac-sha1-tests: Likewise.
5607         * modules/gc-md2-tests: Likewise.
5608         * modules/gc-md4-tests: Likewise.
5609         * modules/gc-md5-tests: Likewise.
5610         * modules/gc-pbkdf2-sha1-tests: Likewise.
5611         * modules/gc-rijndael-tests: Likewise.
5612         * modules/gc-sha1-tests: Likewise.
5613         * modules/gc-tests: Likewise.
5614         * modules/getaddrinfo-tests: Likewise.
5615         * modules/hmac-md5-tests: Likewise.
5616         * modules/hmac-sha1-tests: Likewise.
5617         * modules/linked-list-tests: Likewise.
5618         * modules/linkedhash-list-tests: Likewise.
5619         * modules/lock-tests: Likewise.
5620         * modules/md2-tests: Likewise.
5621         * modules/md4-tests: Likewise.
5622         * modules/md5-tests: Likewise.
5623         * modules/rbtree-list-tests: Likewise.
5624         * modules/rbtree-oset-tests: Likewise.
5625         * modules/rbtreehash-list-tests: Likewise.
5626         * modules/read-file-tests: Likewise.
5627         * modules/rijndael-tests: Likewise.
5628         * modules/stdint-tests: Likewise.
5629         * modules/tls-tests: Likewise.
5630
5631 2007-02-24  Bruno Haible  <bruno@clisp.org>
5632
5633         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
5634         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
5635         function; instead check whether isnan with a double argument links.
5636         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
5637         function; instead check whether isnan with a 'long double' argument
5638         links.
5639         Reported by Eric Blake <ebb9@byu.net>.
5640
5641 2007-02-24  Bruno Haible  <bruno@clisp.org>
5642
5643         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
5644         defined.
5645         * lib/isnanl.c: Remove all code. Just include isnan.c.
5646         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
5647
5648 2007-02-25  Jim Meyering  <jim@meyering.net>
5649
5650         Avoid conflicting types for 'unsetenv' on FreeBSD.
5651         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
5652         conflicting with FreeBSD's (5.0 and 6.1) function declaration
5653         in stdlib.h.
5654
5655 2007-02-24  Bruno Haible  <bruno@clisp.org>
5656
5657         * modules/isnanl-nolibm-tests: New file.
5658         * tests/test-isnanl.c: New file.
5659
5660         * modules/isnanl-nolibm: New file.
5661         * lib/isnanl.h: New file.
5662         * lib/isnanl.c: New file.
5663         * m4/isnanl.m4: New file.
5664
5665 2007-02-24  Bruno Haible  <bruno@clisp.org>
5666
5667         * modules/isnan-nolibm-tests: New file.
5668         * tests/test-isnan.c: New file.
5669
5670         * modules/isnan-nolibm: New file.
5671         * lib/isnan.h: New file.
5672         * lib/isnan.c: New file.
5673         * m4/isnan.m4: New file.
5674
5675 2007-02-24  Bruno Haible  <bruno@clisp.org>
5676
5677         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
5678         assume that an exponent fits in 20 bits.
5679
5680 2007-02-24  Jim Meyering  <jim@meyering.net>
5681
5682         * m4/regex.m4: Update the description of the configure-time option,
5683         --without-included-regex, to state accurately what the defaults are,
5684         and perhaps to give people an idea why using this option is risky.
5685
5686 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
5687
5688         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
5689         loops on small arguments.  This attempts to avoid the problem
5690         Bruno Haible reported for AIX 4.3.2 in
5691         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
5692
5693 2007-02-23  Bruno Haible  <bruno@clisp.org>
5694
5695         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
5696         Needed for help2man.
5697
5698 2007-02-23  Karl Berry  <karl@gnu.org>
5699
5700         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
5701         exists, foo.h should be cvs-ignored, not committed.
5702
5703 2007-02-23  Eric Blake  <ebb9@byu.net>
5704
5705         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
5706         * lib/stat-time.h (includes): Likewise.
5707         * lib/utimecmp.c (includes): Likewise.
5708         * lib/utimens.h (includes): Likewise.
5709         * lib/getdate.y (includes): Also include "timespec.h" for use
5710         internal to the module.
5711         * modules/utimens (Depends-on): Revert yesterday's patch.
5712         * modules/nanosleep (Depends-on): Add missing dependency.
5713
5714 2007-02-22  Bruno Haible  <bruno@clisp.org>
5715
5716         * lib/glob.c: Don't include getlogin_r.h.
5717
5718 2007-02-22  Jim Meyering  <jim@meyering.net>
5719
5720         * modules/utimens (Depends-on): Add timespec, required for
5721         utimens.h's inclusion of timespec.h.
5722
5723 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
5724
5725         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
5726         long unreadable paths in GNU/Linux.  Problem reported by Andreas
5727         Schwab in
5728         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
5729         I'll try to think of a better way to fix the Solaris problem.
5730
5731         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
5732         like glibc; on Solaris 10, it fails with errno == EINVAL.
5733         POSIX says the behavior is unspecified if the first argument is NULL,
5734         so play it safe and never pass NULL to the system getcwd.
5735
5736 2007-02-21  Jim Meyering  <jim@meyering.net>
5737
5738         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
5739         of gettimeofday.  It would conflict with the one now always
5740         provided via sys_time_.h.  Reported by Matthew Woehlke, as
5741         an IRIX 6.5 build failure.
5742
5743 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
5744
5745         Minor fixups to port to Solaris 10 with Sun C 5.8.
5746         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
5747         * modules/getcwd (Depends-on): Add dirfd.
5748         * lib/putenv.c (putenv): #undef it.
5749         (rpl_putenv): New decl.
5750         (malloc, free): Include <stdlib.h> rather than prototyping separately.
5751
5752 2007-02-20  Bruno Haible  <bruno@clisp.org>
5753
5754         * modules/stdio-tests: New file.
5755         * tests/test-stdio.c: New file.
5756
5757         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
5758         (Depends-on): Add stdio.
5759         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
5760         (Include): Use <stdio.h> instead of vsnprintf.h.
5761         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
5762         HAVE_DECL_VSNPRINTF.
5763         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
5764
5765         * modules/snprintf (Files): Remove lib/snprintf.h.
5766         (Depends-on): Add stdio.
5767         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
5768         (Include): Use <stdio.h> instead of snprintf.h.
5769         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
5770         HAVE_DECL_SNPRINTF.
5771         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
5772         * lib/getaddrinfo.c: Likewise.
5773
5774         * modules/stdio: New file.
5775         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
5776         * lib/snprintf.h: Remove file.
5777         * lib/vsnprintf.h: Remove file.
5778         * lib/.cppi-disable: Remove snprintf.h.
5779         * m4/stdio_h.m4: New file.
5780         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
5781
5782 2007-02-20  Jim Meyering  <jim@meyering.net>
5783
5784         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
5785         used by e.g., mingw.  From Bruno Haible.
5786
5787 2007-02-19  Bruno Haible  <bruno@clisp.org>
5788
5789         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
5790         warnings.
5791         Reported by Ben Pfaff <blp@cs.stanford.edu>.
5792
5793 2007-02-19  Bruno Haible  <bruno@clisp.org>
5794
5795         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
5796         from mingw users.
5797
5798 2007-02-19  Bruno Haible  <bruno@clisp.org>
5799
5800         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
5801         warnings.
5802         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
5803
5804 2007-02-19  Jim Meyering  <jim@meyering.net>
5805
5806         Don't use FD after a successful "fdopendir (fd)".
5807         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
5808         Reset it by calling dirfd on the just-obtained DIR*.
5809
5810         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
5811         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
5812
5813 2007-02-18  Bruno Haible  <bruno@clisp.org>
5814
5815         * lib/readlink.c: Include <unistd.h>.
5816         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
5817         HAVE_READLINK.
5818         * modules/readlink (Depends-on): Add unistd.
5819         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5820         (Include): Add <unistd.h>.
5821
5822         * lib/getlogin_r.h: Remove file.
5823         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
5824         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
5825         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
5826         HAVE_DECL_GETLOGIN_R.
5827         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
5828         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5829         (Include): Use <unistd.h> instead of getlogin_r.h.
5830
5831         * lib/getcwd.h: Remove file.
5832         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
5833         * lib/xgetcwd.c: Likewise.
5834         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
5835         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
5836         * modules/getcwd (Files): Remove lib/getcwd.h.
5837         (Depends-on): Add unistd.
5838         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5839         (Include): Use <unistd.h> instad of getcwd.h.
5840
5841         * lib/ftruncate.c: Include <unistd.h> first.
5842         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
5843         Set HAVE_FTRUNCATE.
5844         * modules/ftruncate (Depends-on): Add unistd.
5845         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5846
5847         * lib/fchdir.c: Include <unistd.h> first.
5848         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
5849         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
5850         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
5851         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5852         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
5853
5854         * lib/dup2.c: Include <unistd.h> first.
5855         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
5856         HAVE_DUP2.
5857         * modules/dup2 (Depends-on): Add unistd.
5858         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5859
5860         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
5861         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
5862         REPLACE_CHOWN. Don't define chown as a macro here.
5863         * modules/chown (Depends-on): Add unistd.
5864         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
5865
5866         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
5867         Add definition for GL_LINK_WARNING.
5868         (chown, dup2): New declarations.
5869         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
5870         link warning.
5871         (ftruncate): New declaration.
5872         (getcwd): New declaration, taken from old getcwd.h.
5873         (getlogin_r): New declaration, taken from old getlogin_r.h.
5874         (readlink): New declaration.
5875         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
5876         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
5877         (gl_PREREQ_UNISTD): Remove macro.
5878         (gl_UNISTD_MODULE_INDICATOR): New macro.
5879         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
5880         many new variables. Don't set UNISTD_H.
5881         * modules/unistd (Description): Change.
5882         (Depends-on): Add link-warning.
5883         (configure.ac): Update.
5884         (Makefile.am): Create unistd.h always. Substitute many new variables
5885         into it.
5886
5887 2007-02-18  Bruno Haible  <bruno@clisp.org>
5888
5889         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
5890         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
5891         HAVE_GETSUBOPT.
5892         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
5893         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
5894         * lib/getsubopt.h: Remove file.
5895         * modules/getsubopt (Files): Remove lib/getsubopt.h.
5896         (Depends-on): Add stdlib.
5897         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5898         (Includes): Use <stdlib.h> instead of getsubopt.h.
5899         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
5900         Set HAVE_GETSUBOPT.
5901         * lib/getsubopt.c: Don't include getsubopt.h.
5902
5903 2007-02-18  Bruno Haible  <bruno@clisp.org>
5904
5905         * modules/fchdir (Depends-on): Add dup2.
5906
5907 2007-02-18  Bruno Haible  <bruno@clisp.org>
5908
5909         * lib/stdlib_.h: Handle glibc's special invocation convention
5910         specially.
5911
5912 2007-02-18  Bruno Haible  <bruno@clisp.org>
5913
5914         * modules/stdlib-tests: New file.
5915         * tests/test-stdlib.c: New file.
5916
5917         * modules/mkstemp (Files): Remove lib/mkstemp.h.
5918         (Depends-on): Add stdlib.
5919         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5920         (Includes): Use <stdlib.h> instead of mkstemp.h.
5921         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
5922         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
5923         * lib/mkstemp.c: Don't include mkstemp.h.
5924         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
5925         * lib/stdlib--.h: Don't include mkstemp.h.
5926
5927         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
5928         (Depends-on): Add stdlib.
5929         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
5930         (Includes): Use <stdlib.h> instead of mkdtemp.h.
5931         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
5932         HAVE_MKDTEMP.
5933         * lib/mkdtemp.c: Don't include mkdtemp.h.
5934         * lib/clean-temp.c: Don't include mkdtemp.h.
5935
5936         * modules/exit (Files): Remove lib/exit.h.
5937         (Depends-on): Add stdlib.
5938         (Makefile.am): Remove lib_SOURCES.
5939         (Include): Use <stdlib.h> instead of exit.h.
5940         * lib/argmatch.c: Don't include exit.h.
5941         * lib/execute.c: Likewise.
5942         * lib/pagealign_alloc.c: Likewise.
5943         * lib/pipe.c: Likewise.
5944         * lib/wait-process.c: Likewise.
5945         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
5946         * lib/exitfail.c: Likewise.
5947         * lib/savewd.c: Likewise.
5948         * lib/xsetenv.c: Likewise.
5949
5950         * modules/stdlib: New file.
5951         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
5952         and extra comments about mkstemp().
5953         * lib/exit.h: Remove file.
5954         * lib/mkdtemp.h: Remove file.
5955         * lib/mkstemp.h: Remove file.
5956         * m4/stdlib_h.m4: New file.
5957         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
5958
5959 2007-02-18  Bruno Haible  <bruno@clisp.org>
5960
5961         * modules/math-tests: New file.
5962         * tests/test-math.c: New file.
5963
5964         * modules/math: New file.
5965         * modules/mathl (Files): Remove lib/mathl.h.
5966         (Depends-on): Add math.
5967         (Makefile.am): Don't mention mathl.h.
5968         (Include): Use <math.h> instead of mathl.h.
5969         * lib/math_.h: New file.
5970         * lib/mathl.h: Remove file.
5971         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
5972         mathl.h.
5973         * lib/asinl.c: Likewise.
5974         * lib/atanl.c: Likewise.
5975         * lib/ceill.c: Likewise.
5976         * lib/cosl.c: Likewise.
5977         * lib/expl.c: Likewise.
5978         * lib/floorl.c: Likewise.
5979         * lib/frexpl.c: Likewise.
5980         * lib/ldexpl.c: Likewise.
5981         * lib/logl.c: Likewise.
5982         * lib/sincosl.c: Likewise.
5983         * lib/sinl.c: Likewise.
5984         * lib/sqrtl.c: Likewise.
5985         * lib/tanl.c: Likewise.
5986         * lib/trigl.c: Likewise.
5987         * m4/math_h.m4: New file.
5988         * MODULES.html.sh (Mathematics): Add math.
5989
5990 2007-02-17  Bruno Haible  <bruno@clisp.org>
5991
5992         * modules/wctype-tests: New file.
5993         * tests/test-wctype.c: New file.
5994
5995         * modules/wchar-tests: New file.
5996         * tests/test-wchar.c: New file.
5997
5998         * modules/unistd-tests: New file.
5999         * tests/test-unistd.c: New file.
6000
6001         * modules/time-tests: New file.
6002         * tests/test-time.c: New file.
6003
6004         * modules/sysexits-tests: New file.
6005         * tests/test-sysexits.c: New file.
6006
6007         * modules/sys_time-tests: New file.
6008         * tests/test-sys_time.c: New file.
6009
6010         * modules/sys_stat-tests: New file.
6011         * tests/test-sys_stat.c: New file.
6012
6013         * modules/sys_socket-tests: New file.
6014         * tests/test-sys_socket.c: New file.
6015
6016         * modules/sys_select-tests: New file.
6017         * tests/test-sys_select.c: New file.
6018
6019         * modules/string-tests: New file.
6020         * tests/test-string.c: New file.
6021
6022         * modules/stdbool-tests: New file.
6023         * tests/test-stdbool.c: New file.
6024
6025         * modules/netinet_in-tests: New file.
6026         * tests/test-netinet_in.c: New file.
6027
6028         * modules/inttypes-tests: New file.
6029         * tests/test-inttypes.c: New file.
6030
6031         * modules/fcntl-tests: New file.
6032         * tests/test-fcntl.c: New file.
6033
6034         * modules/byteswap-tests: New file.
6035         * tests/test-byteswap.c: New file.
6036
6037         * modules/arpa_inet-tests: New file.
6038         * tests/test-arpa_inet.c: New file.
6039
6040 2007-02-17  Bruno Haible  <bruno@clisp.org>
6041
6042         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
6043         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
6044         if the corresponding module is not enabled. Emit link warnings if
6045         the function is used nevertheless.
6046         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
6047         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
6048         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
6049         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
6050         * modules/inttypes (Depends-on): Add link-warning.
6051         (Makefile.am): Copy the contents of build-aux/link-warning.h into
6052         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
6053         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
6054         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
6055         * modules/imaxdiv (configure.ac): Likewise.
6056         * modules/strtoimax (configure.ac): Likewise.
6057         * modules/strtoumax (configure.ac): Likewise.
6058
6059 2007-02-17  Bruno Haible  <bruno@clisp.org>
6060
6061         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
6062         gl_STRING_MODULE_INDICATOR_DEFAULTS.
6063         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
6064         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
6065
6066 2007-02-17  Bruno Haible  <bruno@clisp.org>
6067
6068         * modules/link-warning: New file.
6069         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
6070         * lib/string_.h (GL_LINK_WARNING): Remove definition.
6071         * modules/string (Depends-on): Add link-warning.
6072         (Makefile.am): Copy the contents of build-aux/link-warning.h into
6073         string.h.
6074         * MODULES.html.sh (Support for building libraries and executables): Add
6075         link-warning.
6076
6077 2007-02-17  Bruno Haible  <bruno@clisp.org>
6078
6079         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
6080         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
6081         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
6082         long lines.
6083
6084 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
6085             Bruno Haible  <bruno@clisp.org>
6086
6087         * modules/tmpfile: New file.
6088         * lib/tmpfile.c: New file.
6089         * m4/tmpfile.m4: New file.
6090         * MODULES.html.sh (func_all_modules): New section "Input/output".
6091
6092 2007-02-15  Bruno Haible  <bruno@clisp.org>
6093
6094         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
6095         (supports_delete_on_close): New function.
6096         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
6097
6098 2007-02-14  Bruno Haible  <bruno@clisp.org>
6099
6100         * modules/mbspcasecmp-tests: New file.
6101         * tests/test-mbspcasecmp.sh: New file.
6102         * tests/test-mbspcasecmp.c: New file.
6103
6104         New module mbspcasecmp.
6105         * modules/mbspcasecmp: New file.
6106         * lib/mbspcasecmp.c: New file.
6107         * lib/string_.h (strncasecmp): Change warning message.
6108         (mbspcasecmp): New declaration.
6109         * m4/mbspcasecmp.m4: New file.
6110         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6111         GNULIB_MBSPCASECMP.
6112         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
6113         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
6114
6115 2007-02-14  Bruno Haible  <bruno@clisp.org>
6116
6117         * modules/mbsncasecmp-tests: New file.
6118         * tests/test-mbsncasecmp.sh: New file.
6119         * tests/test-mbsncasecmp.c: New file.
6120
6121         New module mbsncasecmp.
6122         * modules/mbsncasecmp: New file.
6123         * lib/mbsncasecmp.c: New file.
6124         * lib/string_.h (mbsncasecmp): New declaration.
6125         * m4/mbsncasecmp.m4: New file.
6126         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6127         GNULIB_MBSNCASECMP.
6128         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
6129         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
6130
6131 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
6132
6133         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
6134         Verify that it doesn't overlap with our flags.
6135         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
6136         do not have the desired effect in multibyte locales; instead, use
6137         mbscasecmp.
6138         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
6139         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
6140         we don't require GNU fnmatch ourselves (if our users require it, they
6141         should do so explicitly).
6142
6143         Fix regex code so it doesn't rely on strcasecmp.
6144         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
6145         Otherwise, include gnulib's langinfo.h.
6146         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
6147         undesirable behavior in non-C locales.  Instead, rely on localecharset.
6148         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
6149         * modules/regex (FILES): Remove m4/codeset.m4.
6150         (Depends-on): Add localcharset.  Remove strcase.
6151
6152 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6153
6154         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
6155         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
6156
6157 2007-02-13  Bruno Haible  <bruno@clisp.org>
6158
6159         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
6160         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
6161
6162 2007-02-12  Bruno Haible  <bruno@clisp.org>
6163
6164         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
6165         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
6166         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
6167         time warning rather than a link error.
6168
6169 2007-02-12  Bruno Haible  <bruno@clisp.org>
6170
6171         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
6172         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
6173         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
6174
6175 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
6176
6177         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
6178         args, not 2.
6179
6180 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
6181
6182         New module 'time', so that apps can include <time.h> as per
6183         POSIX and GNU instead of separate include files like time_r.h
6184         and timegm.h.  This implementation tries out a simpler approach
6185         for replacing decls in standard include files (as compared to
6186         the string module), somewhat as an experiment.
6187
6188         * config/srclist.txt: Comment out mktime.c for now.
6189         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
6190         since it doesn't apply any more.  Use generic wording instead.
6191         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
6192         'time'.
6193         * lib/time_.h, m4/time_h.m4, modules/time: New files.
6194         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
6195         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
6196         Don't include <sys/types.h>; no longer needed since we assume C89.
6197         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
6198         * lib/strftime.c: Likewise.
6199         * lib/time_r.c: Likewise.
6200         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
6201         * lib/nanosleep.c: Include <time.h> first, to check interface.
6202         * lib/strptime.c: Likewise.
6203         * lib/time_r.c: Likewise.
6204         * lib/timegm.c: Likewise.
6205         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
6206         needed.
6207         * lib/timegm.c: Don't include timegm.h; no longer needed.
6208         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
6209         time.h now handles any problems in that area.
6210         (struct timespec, nanosleep): Remove; time.h now arranges for these.
6211         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
6212         that time.h defines struct timespec.
6213         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
6214         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
6215         handles that.
6216         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
6217         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
6218         needed.  Set REPLACE_LOCALTIME.
6219         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
6220         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
6221         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
6222         nanosleep; time_h.m4 now does that.  Don't require
6223         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
6224         module handles this now.
6225         * modules/getdate (Depends-on): Remove timespec.  Add time.
6226         * modules/nanosleep (Depends-on): Likewise.
6227         * modules/stat-time (Depends-on): Likewise.
6228         * modules/nanosleep (Include): Include time.h, not timespec.h.
6229         * modules/strptime (Files): Remove lib/strptime.h.
6230         (Depends-on): Add extensions, time.
6231         (Include): Include time.h, not strptime.h.
6232         * modules/time_r (Files): Remove lib/time_r.h.
6233         (Depends-on): Add time.
6234         (Include): Include time.h, not time_r.h.
6235         * modules/timegm: Likewise.
6236         * modules/timespec (Description): Now does timespec-related decls
6237         of our own, instead of struct timespec itself.
6238         (Depends-on): Add time; remove extensions.
6239         (Maintainer): Add self.
6240         * modules/utimecmp (Depends-on): Add time; remove timespec.
6241         * modules/utimens (Depends-on): Likewise.
6242         * modules/xnanosleep (Depends-on): Likewise.
6243
6244 2007-02-11  Bruno Haible  <bruno@clisp.org>
6245
6246         * lib/c-strstr.c: Include allocsa.h.
6247         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
6248         * lib/c-strcasestr.c: Include allocsa.h.
6249         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
6250         * lib/strcasestr.c: Include allocsa.h.
6251         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
6252         * lib/mbsstr.c: Include allocsa.h.
6253         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
6254         allocsa/freesa instead of malloc/free.
6255         * lib/mbscasestr.c: Include allocsa.h.
6256         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
6257         allocsa/freesa instead of malloc/free.
6258         * modules/c-strstr (Depends-on): Add allocsa.
6259         * modules/c-strcasestr (Depends-on): Likewise.
6260         * modules/strcasestr (Depends-on): Likewise.
6261         * modules/mbsstr (Depends-on): Likewise.
6262         * modules/mbscasestr (Depends-on): Likewise.
6263
6264 2007-02-11  Bruno Haible  <bruno@clisp.org>
6265
6266         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
6267
6268         * modules/mbsspn-tests: New file.
6269         * tests/test-mbsspn.sh: New file.
6270         * tests/test-mbsspn.c: New file.
6271
6272 2007-02-11  Bruno Haible  <bruno@clisp.org>
6273
6274         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
6275
6276         * modules/mbspbrk-tests: New file.
6277         * tests/test-mbspbrk.sh: New file.
6278         * tests/test-mbspbrk.c: New file.
6279
6280 2007-02-11  Bruno Haible  <bruno@clisp.org>
6281
6282         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
6283         unneeded cast.
6284
6285         * modules/mbscspn-tests: New file.
6286         * tests/test-mbscspn.sh: New file.
6287         * tests/test-mbscspn.c: New file.
6288
6289 2007-02-11  Bruno Haible  <bruno@clisp.org>
6290
6291         * modules/mbscasecmp-tests: New file.
6292         * tests/test-mbscasecmp.sh: New file.
6293         * tests/test-mbscasecmp.c: New file.
6294
6295 2007-02-11  Bruno Haible  <bruno@clisp.org>
6296
6297         Ensure O(n) worst-case complexity of mbscasestr.
6298         * lib/mbscasestr.c: Include stdbool.h.
6299         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
6300         functions.
6301         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
6302         the bookkeeping indicates that it's worth it.
6303         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
6304
6305         * modules/mbscasestr-tests: New file.
6306         * tests/test-mbscasestr1.c: New file.
6307         * tests/test-mbscasestr2.sh: New file.
6308         * tests/test-mbscasestr2.c: New file.
6309         * tests/test-mbscasestr3.sh: New file.
6310         * tests/test-mbscasestr3.c: New file.
6311         * tests/test-mbscasestr4.sh: New file.
6312         * tests/test-mbscasestr4.c: New file.
6313         * m4/locale-tr.m4: New file.
6314
6315 2007-02-11  Bruno Haible  <bruno@clisp.org>
6316
6317         Ensure O(n) worst-case complexity of mbsstr.
6318         * lib/mbsstr.c: Include stdbool.h.
6319         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
6320         functions.
6321         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
6322         bookkeeping indicates that it's worth it.
6323         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
6324
6325         * modules/mbsstr-tests: New file.
6326         * tests/test-mbsstr1.c: New file.
6327         * tests/test-mbsstr2.sh: New file.
6328         * tests/test-mbsstr2.c: New file.
6329         * tests/test-mbsstr3.sh: New file.
6330         * tests/test-mbsstr3.c: New file.
6331         * m4/locale-fr.m4: New file.
6332
6333 2007-02-11  Bruno Haible  <bruno@clisp.org>
6334
6335         * lib/mbsrchr.c (mbsrchr): Fix bug.
6336
6337         * modules/mbsrchr-tests: New file.
6338         * tests/test-mbsrchr.sh: New file.
6339         * tests/test-mbsrchr.c: New file.
6340
6341 2007-02-11  Bruno Haible  <bruno@clisp.org>
6342
6343         * lib/mbschr.c (mbschr): Fix bug.
6344
6345         * modules/mbschr-tests: New file.
6346         * tests/test-mbschr.sh: New file.
6347         * tests/test-mbschr.c: New file.
6348         * m4/locale-zh.m4: New file.
6349
6350 2007-02-11  Bruno Haible  <bruno@clisp.org>
6351
6352         Support for copying multibyte string iterators.
6353         * lib/mbiter.h: Include <string.h>.
6354         (mbiter_multi_copy): New function.
6355         (mbi_copy): New macro.
6356         * lib/mbuiter.h: Include <string.h>.
6357         (mbuiter_multi_copy): New function.
6358         (mbui_copy): New macro.
6359
6360 2007-02-11  Bruno Haible  <bruno@clisp.org>
6361
6362         New module mbslen.
6363         * modules/mbslen: New file.
6364         * lib/mbslen.c: New file.
6365         * lib/string_.h (mbslen): New declaration.
6366         * m4/mbslen.m4: New file.
6367         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6368         GNULIB_MBSLEN.
6369         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
6370         * MODULES.html.sh (Internationalization functions): Add mbslen.
6371
6372 2007-02-11  Bruno Haible  <bruno@clisp.org>
6373
6374         Ensure O(n) worst-case complexity of strcasestr substitute.
6375         * lib/strcasestr.c: Include stdbool.h.
6376         (knuth_morris_pratt): New function.
6377         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
6378         bookkeeping indicates that it's worth it.
6379         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
6380
6381         * modules/strcasestr-tests: New file.
6382         * tests/test-strcasestr.c: New file.
6383
6384 2007-02-11  Bruno Haible  <bruno@clisp.org>
6385
6386         Ensure O(n) worst-case complexity of c_strcasestr.
6387         * lib/c-strcasestr.c: Include stdbool.h, string.h.
6388         (knuth_morris_pratt): New function.
6389         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
6390         the bookkeeping indicates that it's worth it.
6391         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
6392
6393         * modules/c-strcasestr-tests: New file.
6394         * tests/test-c-strcasestr.c: New file.
6395
6396 2007-02-11  Bruno Haible  <bruno@clisp.org>
6397
6398         Ensure O(n) worst-case complexity of c_strstr.
6399         * lib/c-strstr.c: Include stdbool.h, string.h.
6400         (knuth_morris_pratt): New function.
6401         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
6402         bookkeeping indicates that it's worth it.
6403         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
6404
6405         * lib/c-strstr.c: Complete rewrite for maintainability.
6406
6407         * modules/c-strstr-tests: New file.
6408         * tests/test-c-strstr.c: New file.
6409
6410 2007-02-11  Bruno Haible  <bruno@clisp.org>
6411
6412         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
6413         5.2.1 and earlier, whereby \055 was treated just like the range
6414         delimiter '-'.
6415         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
6416
6417 2007-02-08  Bruno Haible  <bruno@clisp.org>
6418
6419         * modules/regex (Depends-on): Add stdbool.
6420         Reported by Dalibor Topic <robilad@kaffe.org>.
6421
6422 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
6423
6424         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
6425         Prefer returning from main to exiting from it.
6426         Remove unnecessary parens after sizeof.
6427
6428 2007-02-05  Bruno Haible  <bruno@clisp.org>
6429
6430         New module mbssep.
6431         * modules/mbssep: New file.
6432         * lib/mbssep.c: New file.
6433         * lib/string_.h (strsep): Add a conditional link warning.
6434         (mbssep): New declaration.
6435         * m4/mbssep.m4: New file.
6436         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6437         GNULIB_MBSSEP.
6438         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
6439         * MODULES.html.sh (Internationalization functions): Add mbssep.
6440
6441 2007-02-05  Bruno Haible  <bruno@clisp.org>
6442
6443         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
6444         Optimize search in case of 1 delimiter.
6445
6446 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
6447
6448         * lib/acl.h: Include sys/types.h before sys/acl.h.
6449
6450 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
6451
6452         Merge upstream fix for glibc bugzilla #3957:
6453
6454         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
6455
6456         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
6457         bit for RE_HAT_LISTS_NOT_NEWLINE.
6458         (build_charclass_op): Remove bogus comment.
6459
6460 2007-02-05  Simon Josefsson  <simon@josefsson.org>
6461
6462         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
6463
6464 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
6465
6466         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
6467         * lib/memmem.c [!defined _LIBC]: Include config.h.
6468
6469 2007-02-04  Bruno Haible  <bruno@clisp.org>
6470
6471         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
6472         warning message.
6473
6474 2007-02-04  Bruno Haible  <bruno@clisp.org>
6475
6476         New module mbstok_r.
6477         * modules/mbstok_r: New file.
6478         * lib/mbstok_r.c: New file.
6479         * lib/string_.h (strtok_r): Change argument names to match the
6480         comments. Add a conditional link warning.
6481         (mbstok_r): New declaration.
6482         * m4/mbstok_r.m4: New file.
6483         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6484         GNULIB_MBSTOK_R.
6485         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
6486         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
6487
6488 2007-02-04  Bruno Haible  <bruno@clisp.org>
6489
6490         New module mbsspn.
6491         * modules/mbsspn: New file.
6492         * lib/mbsspn.c: New file.
6493         * lib/string_.h (strspn): Add a conditional link warning.
6494         (mbsspn): New declaration.
6495         * m4/mbsspn.m4: New file.
6496         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6497         GNULIB_MBSSPN.
6498         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
6499         * MODULES.html.sh (Internationalization functions): Add mbsspn.
6500
6501 2007-02-04  Bruno Haible  <bruno@clisp.org>
6502
6503         New module mbspbrk.
6504         * modules/mbspbrk: New file.
6505         * lib/mbspbrk.c: New file.
6506         * lib/string_.h (strpbrk): Add a conditional link warning.
6507         (mbspbrk): New declaration.
6508         * m4/mbspbrk.m4: New file.
6509         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6510         GNULIB_MBSPBRK.
6511         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
6512         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
6513
6514 2007-02-04  Bruno Haible  <bruno@clisp.org>
6515
6516         New module mbscspn.
6517         * modules/mbscspn: New file.
6518         * lib/mbscspn.c: New file.
6519         * lib/string_.h (strcspn): Add a conditional link warning.
6520         (mbscspn): New declaration.
6521         * m4/mbscspn.m4: New file.
6522         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6523         GNULIB_MBSCSPN.
6524         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
6525         * MODULES.html.sh (Internationalization functions): Add mbscspn.
6526
6527 2007-02-04  Bruno Haible  <bruno@clisp.org>
6528
6529         New module mbscasestr, reduced goal of strcasestr.
6530         * modules/mbscasestr: New file.
6531         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
6532         (mbscasestr): Renamed from strcasestr.
6533         * lib/strcasestr.c: Don't include mbuiter.h.
6534         (strcasestr): Remove support for multibyte locales.
6535         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
6536         Change the conditional link warning.
6537         (mbscasestr): New declaration.
6538         * m4/mbscasestr.m4: New file.
6539         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
6540         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
6541         REPLACE_STRCASESTR.
6542         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
6543         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
6544         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
6545         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
6546         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
6547         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
6548         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
6549         (Depends-on): Remove mbuiter.
6550         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
6551
6552 2007-02-04  Bruno Haible  <bruno@clisp.org>
6553
6554         Simplify handling of strncasecmp.
6555         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
6556         the conditional link warning.
6557         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
6558         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
6559         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
6560         * modules/strcase (configure.ac): Don't invoke
6561         gl_STRING_MODULE_INDICATOR.
6562         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
6563
6564 2007-02-04  Bruno Haible  <bruno@clisp.org>
6565
6566         New module mbscasecmp, reduced goal of strcasecmp.
6567         * modules/mbscasecmp: New file.
6568         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
6569         (mbscasecmp): Renamed from strcasecmp.
6570         * lib/strcasecmp.c: Don't include mbuiter.h.
6571         (strcasecmp): Remove support for multibyte locales.
6572         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
6573         Change the conditional link warning.
6574         (mbscasecmp): New declaration.
6575         * m4/mbscasecmp.m4: New file.
6576         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
6577         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
6578         REPLACE_STRCASECMP.
6579         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
6580         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6581         GNULIB_MBSCASECMP.
6582         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
6583         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
6584         * modules/strcase (Files): Remove m4/mbrtowc.m4.
6585         (Depends-on): Remove mbuiter.
6586         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
6587
6588 2007-02-04  Bruno Haible  <bruno@clisp.org>
6589
6590         New module mbsstr. Remove module strstr.
6591         * modules/mbsstr: New file.
6592         * modules/strstr: Remove file.
6593         * lib/mbsstr.c: Renamed from lib/strstr.c.
6594         (mbsstr): Renamed from strstr.
6595         * lib/string_.h (strstr): Remove declaration. Change the conditional
6596         link warning.
6597         (mbsstr): New declaration.
6598         * m4/mbsstr.m4: New file.
6599         * m4/strstr.m4: Remove file.
6600         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
6601         REPLACE_STRSTR.
6602         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
6603         Don't initialize GNULIB_STRSTR.
6604         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
6605         substitute GNULIB_STRSTR and REPLACE_STRSTR.
6606         * MODULES.html.sh (Internationalization functions): Add mbsstr.
6607         (Support for systems lacking ANSI C 89): Remove strstr.
6608
6609 2007-02-04  Bruno Haible  <bruno@clisp.org>
6610
6611         New module mbsrchr.
6612         * modules/mbsrchr: New file.
6613         * lib/mbsrchr.c: New file.
6614         * lib/string_.h (strrchr): Add a conditional link warning.
6615         (mbsrchr): New declaration.
6616         * m4/mbsrchr.m4: New file.
6617         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6618         GNULIB_MBSRCHR.
6619         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
6620         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
6621
6622 2007-02-04  Bruno Haible  <bruno@clisp.org>
6623
6624         New module mbschr.
6625         * modules/mbschr: New file.
6626         * lib/mbschr.c: New file.
6627         * lib/string_.h (strchr): Add a conditional link warning.
6628         (mbschr): New declaration.
6629         * m4/mbschr.m4: New file.
6630         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
6631         GNULIB_MBSCHR.
6632         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
6633         * MODULES.html.sh (Internationalization functions): Add mbschr.
6634
6635 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
6636
6637         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
6638
6639         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
6640
6641 2007-02-04  Bruno Haible  <bruno@clisp.org>
6642
6643         New module description section 'configure.ac-early'.
6644         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
6645         (func_get_autoconf_early_snippet): New function.
6646         (func_import, func_create_testdir): Use it. Remove special cases for
6647         modules 'extensions' and 'lock'.
6648         * modules/extensions (configure.ac-early): Require
6649         gl_USE_SYSTEM_EXTENSIONS.
6650         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
6651
6652 2007-02-04  Bruno Haible  <bruno@clisp.org>
6653
6654         Make use of gcj-4.3's -fsource and -ftarget option.
6655         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
6656         and if so try the options -fsource and -ftarget.
6657         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
6658         source_version, ftarget_option, target_version arguments.
6659         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
6660         (is_envjavac_oldgcj_14_14_usable): Renamed from
6661         is_envjavac_gcj_14_14_usable.
6662         (is_envjavac_oldgcj_14_13_usable): Renamed from
6663         is_envjavac_gcj_14_13_usable.
6664         (is_gcj_present): Update.
6665         (is_gcj_43, is_gcj43_usable): New functions.
6666         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
6667         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
6668         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
6669         try the options -fsource and -ftarget.
6670
6671 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
6672
6673         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
6674         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
6675         larger value.
6676
6677 2007-02-03  Jim Meyering  <jim@meyering.net>
6678
6679         Give tools a better chance to allocate space for very large buffers.
6680         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
6681
6682         Make pwd and readlink work also when run with an unreadable parent dir
6683         on systems with openat support.
6684         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
6685         provided getcwd function, even when we have openat support.
6686         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
6687
6688 2007-02-02  Bruno Haible  <bruno@clisp.org>
6689
6690         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
6691         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
6692         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
6693         portability problems if one of these functions is only used on specific
6694         platforms.
6695         Reported by Paul Eggert.
6696
6697 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
6698
6699         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
6700         is causing more trouble than it's curing.
6701         * lib/regex_internal.h (__mempcpy): Remove.
6702         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
6703         (and make the code a tad smaller to boot).
6704         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
6705
6706 2007-02-02  Jim Meyering  <jim@meyering.net>
6707
6708         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
6709         section, not in the Makefile.am: one.
6710
6711 2007-02-02  Eric Blake  <ebb9@byu.net>
6712
6713         * lib/strchrnul.c: Always include config.h first.
6714
6715         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
6716         gnulib strstr is not necessary here.
6717
6718 2007-02-02  Simon Josefsson  <simon@josefsson.org>
6719
6720         * m4/socklen.m4: Fix typo.
6721
6722 2007-02-02  Eric Blake  <ebb9@byu.net>
6723
6724         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
6725         * modules/netinet_in (Makefile.am): Likewise.
6726
6727 2007-02-01  Bruno Haible  <bruno@clisp.org>
6728
6729         * lib/string_.h (GL_LINK_WARNING): New macro.
6730         (strcasecmp, strstr, strcasestr): If provided by the system,
6731         conditionally define as a macro that leads to a warning instead of to
6732         an error.
6733         (strncasecmp): Conditionally define as a macro that leads to a warning.
6734
6735 2007-02-01  Karl Berry  <karl@gnu.org>
6736
6737         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
6738
6739 2007-02-01  Bruno Haible  <bruno@clisp.org>
6740
6741         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
6742         renamings.
6743
6744 2007-02-01  Eric Blake  <ebb9@byu.net>
6745
6746         * modules/regex (Depends-on): Revert dependence on mempcpy.
6747         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
6748         module's definition of mempcpy.
6749         Reported by Paul Eggert.
6750
6751 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
6752
6753         * lib/string_.h: If the gnulib module XYZ is not present, undefine
6754         the symbol XYZ before redefining it.  This fixes a problem with
6755         programs that don't use XYZ, when compiled on systems that define
6756         XYZ to something else.
6757
6758 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
6759
6760         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
6761         occurs when "mkdir -m foo" creates a setgid directory that is (1)
6762         writeable to group or other and (2) is intended to have a special
6763         mode bit that is set or cleared.  In such a case, the directory
6764         should be neither group- nor other-writeable until the special
6765         mode bits are right.
6766
6767 2007-01-31  Eric Blake  <ebb9@byu.net>
6768
6769         * modules/mountlist (Depends-on): Add strstr.
6770
6771         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
6772         bug.
6773         * modules/string (Makefile.am): Remove redundant replacement.
6774         * modules/regex (Depends-on): Add mempcpy.
6775
6776 2007-01-31  Bruno Haible  <bruno@clisp.org>
6777
6778         New module description field 'Link'.
6779         * gnulib-tool (func_usage): Document --extract-link-directive.
6780         (sed_extract_prog): Recognize 'Link' directive.
6781         (func_get_link_directive): New function.
6782         (func_import): Show summary of link directives.
6783         Handle --extract-link-directive option.
6784         * modules/acl (Link): New section.
6785         * modules/clock-time (Link): New section.
6786         * modules/euidaccess (Link): New section.
6787         * modules/gettext (Link): New section.
6788         * modules/iconv (Link): New section.
6789         * modules/lock (Link): New section.
6790         * modules/nanosleep (Link): New section.
6791         * modules/readline (Link): New section.
6792
6793 2007-01-27  Bruno Haible  <bruno@clisp.org>
6794
6795         Enforce the use of gnulib modules for unportable <string.h> functions.
6796         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
6797         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
6798         (gl_HEADER_STRING_H_BODY): Require it.
6799         * lib/string_.h: If the gnulib module XYZ is not present, redefine
6800         the symbol XYZ to one that gives a link error.
6801         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
6802         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
6803         * modules/mempcpy (configure.ac): Likewise.
6804         * modules/memrchr (configure.ac): Likewise.
6805         * modules/stpcpy (configure.ac): Likewise.
6806         * modules/stpncpy (configure.ac): Likewise.
6807         * modules/strcase (configure.ac): Likewise.
6808         * modules/strcasestr (configure.ac): Likewise.
6809         * modules/strchrnul (configure.ac): Likewise.
6810         * modules/strdup (configure.ac): Likewise.
6811         * modules/strndup (configure.ac): Likewise.
6812         * modules/strnlen (configure.ac): Likewise.
6813         * modules/strpbrk (configure.ac): Likewise.
6814         * modules/strsep (configure.ac): Likewise.
6815         * modules/strstr (configure.ac): Likewise.
6816         * modules/strtok_r (configure.ac): Likewise.
6817
6818 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
6819
6820         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
6821
6822 2007-01-30  Jim Meyering  <jim@meyering.net>
6823
6824         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
6825
6826 2007-01-29  Bruno Haible  <bruno@clisp.org>
6827
6828         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
6829         * lib/execute.c: Likewise.
6830         * lib/pipe.c: Likewise.
6831         * lib/printf-args.h: Likewise.
6832         * lib/printf-args.c: Likewise.
6833         * lib/printf-parse.c: Likewise.
6834         * lib/vasnprintf.c: Likewise.
6835
6836 2007-01-29  Eric Blake  <ebb9@byu.net>
6837
6838         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
6839         declaration.
6840
6841 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
6842
6843         * lib/strptime.h (strptime): Use 'restrict' for args where
6844         POSIX requires this.
6845         * lib/strptime.c (strptime): Likewise.
6846         Change license notice from LGPL to GPL, since gnulib-tool will
6847         change this as needed.
6848         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
6849         defined.
6850         Include "strptime.h" first, to check interface.
6851         Do not #undef _LIBC and _NL_CURRENT.
6852         Do not include <stdlib.h>; no longer needed.
6853         Include "time_r.h" and declare ptime_locale_status
6854         only if _LIBC is not defined.
6855         (__P): Remove unused macro.
6856         (match_string): Bring back glibc version, but use it only if _LIBC
6857         is defined.
6858         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
6859         Remove unnecessary assertion and abort() call.
6860         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
6861         * m4/strptime.m4: Fix serial number comment.
6862         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
6863         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
6864         (Depends-on): Add time_r.
6865
6866 2007-01-29  Bruno Haible  <bruno@clisp.org>
6867
6868         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
6869         strptime.
6870         * modules/strptime (Depends-on): Add stdbool.
6871         * lib/strptime.h: Include <time.h> always. Add comments.
6872
6873 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
6874
6875         * modules/strptime: New file.
6876         * lib/strptime.h: New file.
6877         * lib/strptime.c: New file.
6878         * m4/strptime.m4: New file.
6879
6880 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
6881
6882         * MODULES.html.sh: New module mpsort.
6883         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
6884
6885         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
6886         a circularity problem with HP-UX ia64 reported by Bob Proulx in
6887         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
6888         All uses changed.
6889         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
6890         All uses changed.
6891         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
6892         to _Restrict_.
6893         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
6894         the parameter matches the prototype.
6895
6896 2007-01-28  Jim Meyering  <jim@meyering.net>
6897
6898         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
6899         sys/time.h here, reverting that part of the previous patch:
6900         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
6901
6902 2007-01-28  Bruno Haible  <bruno@clisp.org>
6903
6904         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
6905         value of $(SYS_TIME_H).
6906         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
6907         remove it conditionally, too. [added by Jim Meyering]
6908         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
6909         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
6910         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
6911         GETTIMEOFDAY_REPLACEMENT to 1.
6912
6913 2007-01-28  Bruno Haible  <bruno@clisp.org>
6914
6915         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
6916         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
6917         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
6918         Set UNISTD_H instead of UNISTD_H2.
6919         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
6920
6921 2007-01-28  Bruno Haible  <bruno@clisp.org>
6922
6923         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
6924         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
6925
6926 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6927
6928         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
6929         (func_create_testdir): Ensure C locale for `grep' and `tr'
6930         character ranges.
6931         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
6932         ACLOCAL_AMFLAGS parsing state machine.
6933
6934 2007-01-27  Bruno Haible  <bruno@clisp.org>
6935
6936         * modules/unistr/base: Update.
6937
6938 2007-01-27  Bruno Haible  <bruno@clisp.org>
6939
6940         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
6941         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
6942         * modules/unistr/u32-mbtouc-unsafe: Renamed from
6943         modules/unistr/u32-mbtouc.
6944         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
6945         * lib/unistr.h: Update.
6946         * lib/linebreak.c: Update.
6947         * modules/unistr/u32-mbtouc: Renamed from
6948         modules/unistr/u32-mbtouc-safe.
6949         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
6950         * lib/unistr.h: Update.
6951         * lib/unistr/u32-to-u8.c: Update.
6952         * lib/unistr/u32-to-u16.c: Update.
6953
6954 2007-01-27  Bruno Haible  <bruno@clisp.org>
6955
6956         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
6957         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
6958         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
6959         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
6960         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
6961         * modules/unistr/u16-mbtouc-unsafe: Renamed from
6962         modules/unistr/u16-mbtouc.
6963         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
6964         * lib/unistr.h: Update.
6965         * lib/linebreak.c: Update.
6966         * modules/linebreak: Update.
6967         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
6968         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
6969         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
6970         * modules/unistr/u16-mbtouc: Renamed from
6971         modules/unistr/u16-mbtouc-safe.
6972         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
6973         * lib/unistr.h: Update.
6974         * lib/unistr/u16-to-u8.c: Update.
6975         * modules/unistr/u16-to-u8: Update.
6976         * lib/unistr/u16-to-u32.c: Update.
6977         * modules/unistr/u16-to-u32: Update.
6978
6979 2007-01-27  Bruno Haible  <bruno@clisp.org>
6980
6981         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
6982         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
6983         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
6984         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
6985         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
6986         * modules/unistr/u8-mbtouc-unsafe: Renamed from
6987         modules/unistr/u8-mbtouc.
6988         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
6989         * lib/unistr.h: Update.
6990         * lib/striconveh.c: Update.
6991         * modules/striconveh: Update.
6992         * lib/linebreak.c: Update.
6993         * modules/linebreak: Update.
6994         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
6995         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
6996         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
6997         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
6998         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
6999         * lib/unistr.h: Update.
7000         * lib/striconveh.c: Update.
7001         * modules/striconveh: Update.
7002         * lib/unistr/u8-to-u16.c: Update.
7003         * modules/unistr/u8-to-u16: Update.
7004         * lib/unistr/u8-to-u32.c: Update.
7005         * modules/unistr/u8-to-u32: Update.
7006
7007 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7008
7009         Sync from Libtool.
7010         * lib/argz.c: Do not include strings.h nor memory.h, include
7011         string.h unconditionally.  Patch by Simon Josefsson.
7012
7013 2007-01-27  Bruno Haible  <bruno@clisp.org>
7014
7015         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
7016         from gl_HEADER_STRING_H_BODY.
7017         (gl_HEADER_STRING_H_BODY): Require it.
7018         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
7019         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
7020         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
7021         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
7022         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
7023         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
7024         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
7025         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
7026         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
7027         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
7028         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
7029         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
7030         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
7031         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
7032         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
7033
7034 2007-01-27  Bruno Haible  <bruno@clisp.org>
7035
7036         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
7037         check_PROGRAMS into noinst_PROGRAMS.
7038         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
7039         check_PROGRAMS in this case.
7040         (func_import): Set for_test to false.
7041         (func_create_testdir): Set for_test to true.
7042
7043 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
7044             Bruno Haible  <bruno@clisp.org>
7045
7046         * modules/strcasestr (Files): Remove lib/strcasestr.h.
7047         (Depends-on): Add string.
7048         (Includes): Use <string.h> instead of strcasestr.h.
7049         * modules/string (Makefile.am): Also substitute the value of
7050         REPLACE_STRCASESTR.
7051         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
7052         assume strcasestr is declared in <string.h> not <strings.h>. Also
7053         set REPLACE_STRCASESTR.
7054         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
7055         REPLACE_STRCASESTR.
7056         * lib/strcasestr.h: Remove file.
7057         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
7058         * lib/string_.h (strcasestr): New declaration.
7059
7060 2007-01-27  Bruno Haible  <bruno@clisp.org>
7061
7062         * lib/string_.h: Use 'extern'.
7063
7064 2007-01-27  Jim Meyering  <jim@meyering.net>
7065
7066         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
7067         of set-but-not-used local, "q".
7068
7069         * lib/mempcpy.c: Include <config.h> before <string.h>.
7070         This fixes a compilation error on HP-UX, due to the system's
7071         "restrict"-using mempcpy prototype.
7072
7073 2007-01-26  Bruno Haible  <bruno@clisp.org>
7074
7075         Small optimization.
7076         * lib/javacomp.c: Include c-strstr.h.
7077          (is_envjavac_gcj): Use c_strstr instead of strstr.
7078         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
7079
7080 2007-01-26  Bruno Haible  <bruno@clisp.org>
7081
7082         * MODULES.html.sh (Unicode string functions): Add the new modules.
7083
7084         * modules/uniconv/u32-strconv-to-locale: New file.
7085         * lib/uniconv/u32-strconv-to-locale.c: New file.
7086
7087         * modules/uniconv/u16-strconv-to-locale: New file.
7088         * lib/uniconv/u16-strconv-to-locale.c: New file.
7089
7090         * modules/uniconv/u8-strconv-to-locale: New file.
7091         * lib/uniconv/u8-strconv-to-locale.c: New file.
7092
7093         * modules/uniconv/u32-strconv-from-locale: New file.
7094         * lib/uniconv/u32-strconv-from-locale.c: New file.
7095
7096         * modules/uniconv/u16-strconv-from-locale: New file.
7097         * lib/uniconv/u16-strconv-from-locale.c: New file.
7098
7099         * modules/uniconv/u8-strconv-from-locale: New file.
7100         * lib/uniconv/u8-strconv-from-locale.c: New file.
7101
7102         * modules/uniconv/u32-strconv-to-enc: New file.
7103         * lib/uniconv/u32-strconv-to-enc.c: New file.
7104         * modules/uniconv/u32-strconv-to-enc-tests: New file.
7105         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
7106
7107         * modules/uniconv/u16-strconv-to-enc: New file.
7108         * lib/uniconv/u16-strconv-to-enc.c: New file.
7109         * lib/uniconv/u-strconv-to-enc.h: New file.
7110         * modules/uniconv/u16-strconv-to-enc-tests: New file.
7111         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
7112
7113         * modules/uniconv/u8-strconv-to-enc: New file.
7114         * lib/uniconv/u8-strconv-to-enc.c: New file.
7115         * modules/uniconv/u8-strconv-to-enc-tests: New file.
7116         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
7117
7118         * modules/uniconv/u32-strconv-from-enc: New file.
7119         * lib/uniconv/u32-strconv-from-enc.c: New file.
7120         * modules/uniconv/u32-strconv-from-enc-tests: New file.
7121         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
7122
7123         * modules/uniconv/u16-strconv-from-enc: New file.
7124         * lib/uniconv/u16-strconv-from-enc.c: New file.
7125         * modules/uniconv/u16-strconv-from-enc-tests: New file.
7126         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
7127
7128         * modules/uniconv/u8-strconv-from-enc: New file.
7129         * lib/uniconv/u8-strconv-from-enc.c: New file.
7130         * lib/uniconv/u-strconv-from-enc.h: New file.
7131         * modules/uniconv/u8-strconv-from-enc-tests: New file.
7132         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
7133
7134         * modules/uniconv/u32-conv-from-enc: New file.
7135         * lib/uniconv/u32-conv-from-enc.c: New file.
7136         * modules/uniconv/u32-conv-from-enc-tests: New file.
7137         * tests/uniconv/test-u32-conv-from-enc.c: New file.
7138
7139         * modules/uniconv/u16-conv-from-enc: New file.
7140         * lib/uniconv/u16-conv-from-enc.c: New file.
7141         * lib/uniconv/u-conv-from-enc.h: New file.
7142         * modules/uniconv/u16-conv-from-enc-tests: New file.
7143         * tests/uniconv/test-u16-conv-from-enc.c: New file.
7144
7145         * modules/uniconv/u8-conv-from-enc: New file.
7146         * lib/uniconv/u8-conv-from-enc.c: New file.
7147         * modules/uniconv/u8-conv-from-enc-tests: New file.
7148         * tests/uniconv/test-u8-conv-from-enc.c: New file.
7149
7150         * modules/uniconv/base: New file.
7151         * lib/uniconv.h: New file.
7152
7153 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
7154
7155         * doc/gnulib-tool.texi (Initial import): Update to match current
7156         behavior with strdup module.
7157         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
7158         * lib/memmem.h: Remove; all uses removed.  This is now done
7159         by <string.h>.
7160         * lib/mempcpy.h: Likewise.
7161         * lib/memrchr.h: Likewise.
7162         * lib/stpcpy.h: Likewise.
7163         * lib/stpncpy.h: Likewise.
7164         * lib/strcase.h: Likewise.
7165         * lib/strchrnul.h: Likewise.
7166         * lib/strdup.h: Likewise.
7167         * lib/strndup.h: Likewise.
7168         * lib/strnlen.h: Likewise.
7169         * lib/strpbrk.h: Likewise.
7170         * lib/strsep.h: Likewise.
7171         * lib/strstr.h: Likewise.
7172         * lib/strtok_r.h: Likewise.
7173         * lib/string_.h: New file.
7174         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
7175         Rely on <string.h> instead.
7176         * lib/canon-host.c: Likewise.
7177         * lib/chdir-long.c: Likewise.
7178         * lib/concatpath.c: Likewise.
7179         * lib/exclude.c: Likewise.
7180         * lib/fchdir.c: Likewise.
7181         * lib/getaddrinfo.c: Likewise.
7182         * lib/getcwd.c: Likewise.
7183         * lib/getsubopt.c: Likewise.
7184         * lib/glob.c: Likewise.
7185         * lib/hard-locale.c: Likewise.
7186         * lib/iconvme.c: Likewise.
7187         * lib/javacomp.c: Likewise.
7188         * lib/mempcpy.c: Likewise.
7189         * lib/memrchr.c: Likewise.
7190         * lib/regex_internal.h: Likewise.
7191         * lib/stpncpy.c: Likewise.
7192         * lib/strcasecmp.c: Likewise.
7193         * lib/strchrnul.c: Likewise.
7194         * lib/strdup.c: Likewise.
7195         * lib/striconv.c: Likewise.
7196         * lib/striconveh.c: Likewise.
7197         * lib/striconveha.c: Likewise.
7198         * lib/strncasecmp.c: Likewise.
7199         * lib/strndup.c: Likewise.
7200         * lib/strnlen.c: Likewise.
7201         * lib/strsep.c: Likewise.
7202         * lib/strstr.c: Likewise.
7203         * lib/strtok_r.c: Likewise.
7204         * lib/userspec.c: Likewise.
7205         * lib/w32spawn.h: Likewise.
7206         * lib/xstrndup.c: Likewise.
7207         * lib/mountlist.c (strstr): Remove decl.
7208         * m4/string_h.m4: New file.
7209         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
7210         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
7211         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
7212         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
7213         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
7214         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
7215         Set REPLACE_STRCASECMP if necessary.
7216         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
7217         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
7218         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
7219         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
7220         HAVE_DECL_STRDUP if necessary.
7221         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
7222         since gl_FUNC_STRNDUP does that now.
7223         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
7224         Check for decl here...
7225         (gl_PREREQ_STRNLEN): ... not here.
7226         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
7227         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
7228         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
7229         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
7230         necessary.
7231         * modules/string: New file.
7232         * modules/memmem (Files): Remove special-purpose include file.
7233         (Depends-on): Add string.
7234         (Include): Include <string.h>, not the removed file.
7235         * modules/mempcpy: Likewise.
7236         * modules/memrchr: Likewise.
7237         * modules/stpcpy: Likewise.
7238         * modules/stpncpy: Likewise.
7239         * modules/strcase: Likewise.
7240         * modules/strchrnul: Likewise.
7241         * modules/strdup: Likewise.
7242         * modules/strndup: Likewise.
7243         * modules/strnlen: Likewise.
7244         * modules/strpbrk: Likewise.
7245         * modules/strsep: Likewise.
7246         * modules/strstr: Likewise.
7247         * modules/strtok_r: Likewise.
7248         * tests/test-dirname.c: Don't include "strdup.h", since
7249         <string.h> now suffices.
7250         * tests/test-memmem.c: Don't include "memmem.h", since
7251         <string.h> now suffices.
7252
7253 2007-01-25  Bruno Haible  <bruno@clisp.org>
7254
7255         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
7256         *resultp is 0.
7257
7258         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
7259         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
7260         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
7261         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
7262
7263         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
7264         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
7265         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
7266         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
7267         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
7268         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
7269
7270 2007-01-24  Bruno Haible  <bruno@clisp.org>
7271
7272         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
7273         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
7274         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
7275         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
7276         gl_FUNC_FTS_CORE.
7277         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
7278         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
7279         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
7280         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
7281         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
7282         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
7283         gl_FUNC_FCHOWNAT.
7284         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
7285         gl_FUNC_STRFTIME.
7286         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
7287         Reported by Ralf Wildenhues.
7288
7289 2007-01-24  Bruno Haible  <bruno@clisp.org>
7290
7291         Drop AC_REQUIRE calls that are redundant with the module dependencies.
7292         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
7293         gl_GETADDRINFO.
7294         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
7295         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
7296         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
7297
7298 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
7299
7300         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
7301         Don't use 'exit'; just return from 'main'.
7302         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
7303
7304         * lib/fnmatch_.h: Readjust white space and comments to match
7305         glibc, to avoid spurious diffs.
7306
7307 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
7308
7309         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
7310         2004-12-01 change by Jakub Jelinek, since this code won't compile
7311         if !LIBC.  Problem reported by Bob Proulx.
7312
7313 2007-01-23  Bruno Haible  <bruno@clisp.org>
7314
7315         * lib/striconveh.c: Include c-strcaseeq.h.
7316         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
7317         * modules/striconveh (Depends-on): Add c-strcaseeq.
7318
7319 2007-01-23  Bruno Haible  <bruno@clisp.org>
7320
7321         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
7322
7323         * modules/c-strcaseeq: New file.
7324         * lib/c-strcaseeq.h: New file.
7325
7326         * modules/streq: New file.
7327         * lib/streq.h: New file.
7328
7329 2007-01-23  Bruno Haible  <bruno@clisp.org>
7330
7331         * modules/striconveha-tests: New file.
7332         * tests/test-striconveha.c: New file.
7333
7334         * lib/striconveha.h: Include <stdbool.h>.
7335         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
7336         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
7337         (mem_iconveha_notranslit): Renamed from mem_iconveha.
7338         (mem_iconveha): New function.
7339         (str_iconveha_notranslit): Renamed from str_iconveha.
7340         (str_iconveha): New function.
7341         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
7342         c-strcase.
7343
7344 2007-01-23  Bruno Haible  <bruno@clisp.org>
7345
7346         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
7347         encodings without forgiving before trying any encoding with handler.
7348         (str_iconveha): Try all encodings without forgiving before trying any
7349         encoding with handler.
7350
7351 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
7352
7353         Import the following changes from libc.
7354
7355         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
7356
7357         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
7358
7359         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
7360
7361         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
7362         normal_bracket label.
7363
7364         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
7365
7366         [BZ #361]
7367         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
7368         to normal_bracket after fetching the next character.
7369
7370 2007-01-22  Bruno Haible  <bruno@clisp.org>
7371
7372         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
7373         argument.
7374         * lib/striconveh.c (iconv_carefully_1): New function.
7375         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
7376         argument.
7377         (str_cd_iconveh): Update.
7378         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
7379         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
7380         * tests/test-striconveh.c (MAGIC): New macro.
7381         (new_offsets): New function.
7382         (main): Test call with and without offsets.
7383
7384 2007-01-22  Bruno Haible  <bruno@clisp.org>
7385
7386         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
7387         * modules/sys_select (Makefile.am): Likewise.
7388         * modules/sys_socket (Makefile.am): Likewise.
7389         * modules/sys_time (Makefile.am): Likewise.
7390
7391 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
7392
7393         * modules/gettimeofday (License): Change from GPL to LGPL, since
7394         gettimeofday is a library function.
7395
7396 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
7397
7398         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
7399
7400 2007-01-21  Bruno Haible  <bruno@clisp.org>
7401
7402         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
7403
7404 2007-01-21  Bruno Haible  <bruno@clisp.org>
7405
7406         * modules/striconveha: New file.
7407         * lib/striconveha.h: New file.
7408         * lib/striconveha.c: New file.
7409         * MODULES.html.sh (Internationalization functions): Add striconveha.
7410         * lib/striconv.c (str_iconv): Optimize the case of an empty input
7411         string.
7412         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
7413
7414 2007-01-21  Bruno Haible  <bruno@clisp.org>
7415
7416         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
7417         * lib/striconveh.c (str_iconveh): Likewise.
7418
7419 2007-01-21  Bruno Haible  <bruno@clisp.org>
7420
7421         * lib/striconveh.h (mem_iconveh): New declaration.
7422         * lib/striconveh.c (mem_iconveh): New function.
7423         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
7424
7425 2007-01-21  Bruno Haible  <bruno@clisp.org>
7426
7427         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
7428
7429         * lib/striconveh.h (mem_cd_iconveh): Change specification.
7430         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
7431         original result buffer.
7432         (str_cd_iconveh): Update.
7433         * tests/test-striconveh.c (main): Update.
7434
7435         * lib/striconv.h (mem_cd_iconv): Change specification.
7436         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
7437         result buffer.
7438         (str_cd_iconv): Update.
7439         * tests/test-striconv.c (main): Update.
7440
7441 2007-01-21  Bruno Haible  <bruno@clisp.org>
7442
7443         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
7444
7445 2007-01-20  Jim Meyering  <jim@meyering.net>
7446
7447         * lib/userspec.c (parse_with_separator): If a user or group string
7448         starts with "+", skip the corresponding name-to-ID look-up, since
7449         such a look-up must fail: user and group names may not include "+".
7450
7451 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
7452
7453         * lib/poll.c: Include sys/time.h and time.h unconditionally,
7454         since we now assume the sys_time module.
7455         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
7456         check for sys/time.h; no longer needed.
7457         * modules/poll (Depends-on): Depend on sys_time.
7458
7459 2007-01-18  Bruno Haible  <bruno@clisp.org>
7460
7461         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
7462         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
7463
7464         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
7465         gettimeofday.
7466
7467         * tests/test-gettimeofday.c: Include <time.h>.
7468         (dummy): Remove variable.
7469
7470         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
7471         gl_HEADER_SYS_TIME_H.
7472         (gl_HEADER_SYS_TIME_H): New macro.
7473
7474         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
7475         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7476         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
7477         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
7478         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7479         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
7480         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
7481         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7482         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
7483         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
7484         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7485
7486         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
7487         last change; it caused a compilation error when cross-compiling to
7488         Cygwin.
7489
7490 2007-01-18  Jim Meyering  <jim@meyering.net>
7491
7492         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
7493         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
7494         than the race-prone "test -d sys || mkdir sys".
7495         (configure.ac): Use AC_PROG_MKDIR_P.
7496         * modules/sys_select: Likewise.
7497         * modules/sys_socket: Likewise.
7498         * modules/sys_time: Likewise.
7499
7500 2007-01-18  Eric Blake  <ebb9@byu.net>
7501
7502         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
7503         replace gettimeofday.
7504         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
7505         name, to avoid infinite recursion.
7506
7507 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
7508
7509         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
7510         module sys_time.
7511         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
7512         assume timespec.h defines struct timeval.
7513         * lib/settime.c: Likewise.
7514         * lib/utimens.c: Likewise.
7515         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
7516         since we now assume the gettimeofday module.
7517         * lib/tempname.c (__gen_tempname): Likewise.
7518         * lib/gettimeofday.h: Remove.
7519         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
7520         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
7521         Include <time.h>, for 'time()'.
7522         (localtime_buffer_addr): Also use this workaround if
7523         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
7524         to simplify the uses.  All uses changed.
7525         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
7526         that #undef is inside {}, and 'const' follows type name consistently.
7527         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
7528         (gettimeofday): Do not use the maximum possible value for
7529         tv->tv_usec, since that might break usages other than ls.c.
7530         Instead, we'll leave ls.c alone.  This undoes today's patch
7531         by Bruno.  Add a compile-time warning for 1s-clock resolution;
7532         we've never observed the problem but might as well keep the
7533         canary.
7534         * lib/nanosleep.c: Include timespec.h first, for interface check.
7535         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
7536         now assume the sys_time module.
7537         * lib/tempname.c: Likewise.
7538         * lib/timespec.h: Likewise.
7539         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
7540         needed.
7541         * lib/strftime.c: Likewise.
7542         * lib/timespec.h: Likewise.
7543         * lib/posixtm.c: Include posixtm.h first, for interface check.
7544         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
7545         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
7546         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
7547         * lib/sys_time_.h: New file.
7548         * lib/timespec.h (struct timespec): Use long int, not long.
7549         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
7550         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
7551         Remove obsolescent call to AC_HEADER_TIME.
7552         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
7553         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
7554         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
7555         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
7556         Likewise.
7557         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
7558         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
7559         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
7560         into the sys_time module.  Check for gettimeofday just once.
7561         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
7562         for gettimeofday signature to just check the signature.  Merely
7563         compile it, since linking doesn't test signature.  Improve test for
7564         whether gettimeofday.o is actually needed.
7565         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
7566         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
7567         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
7568         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7569         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
7570         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
7571         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
7572         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
7573         than worrying about sys/time.h.
7574         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
7575         Don't bother worrying about TIME_WITH_SYS_TIME.
7576         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
7577         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
7578         * m4/sys_time_h.m4: New file.
7579         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
7580         Don't include sys/time.h.  Return from main rather than exiting.
7581         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
7582         all uses changed.
7583         * modules/gethrxtime (Depends-on): Add sys_time.
7584         * modules/gettime (Depends-on): Likewise.
7585         * modules/gettimeofday (Depends-on): Likewise.
7586         * modules/nanosleep (Depends-on): Likewise.
7587         * modules/settime (Depends-on): Likewise.
7588         * modules/tempname (Depends-on): Likewise.
7589         * modules/utimens (Depends-on): Likewise.
7590         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
7591         (Include:) Change back to <sys/time.h>.
7592         (Maintainer:) Add self.
7593         * modules/sys_time: New file.
7594         * modules/tempname (Depends-on): Add gettimeofday.
7595         * tests/test-gettimeofday.c: Include <sys/time.h>
7596         rather than gettimeofday.h.
7597
7598 2007-01-17  Bruno Haible  <bruno@clisp.org>
7599
7600         * gnulib-tool (func_get_license): Revert last patch. Instead, let
7601         the license default to GPL.
7602         (func_create_testdir): Don't complain if a module is LGPL and its
7603         tests module depends on GPLed modules.
7604
7605 2007-01-17  Bruno Haible  <bruno@clisp.org>
7606
7607         * lib/gettimeofday.c (gettimeofday): Add code for the case
7608         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
7609         maximum possible value for tv->tv_usec, rather than the minimum one.
7610
7611 2005-10-08  Martin Lambers  <marlam@marlam.de>
7612 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
7613 2007-01-16  Bruno Haible  <bruno@clisp.org>
7614
7615         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
7616         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
7617         gl_FUNC_GETTIMEOFDAY.
7618         (Include): Add gettimeofday.h.
7619         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
7620         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
7621         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
7622         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
7623         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
7624         * lib/gettimeofday.h: New file.
7625         * lib/gettimeofday.c: Include <sys/timeb.h>.
7626         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
7627         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
7628         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
7629         fall back on time().
7630
7631         * tests/test-gettimeofday.c: New file.
7632         * modules/gettimeofday-tests: New file.
7633
7634 2007-01-16  Eric Blake  <ebb9@byu.net>
7635
7636         * modules/fnmatch (Depends-on): Depend on wchar.
7637         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
7638         * m4/fnmatch.m4: Likewise.
7639         * modules/mbchar (Makefile.am): Assume <wchar.h>.
7640         * m4/mbchar.m4: Likewise.
7641         * modules/mbswidth (Depends-on): Depend on wchar.
7642         * lib/mbswidth.c: Assume <wchar.h>.
7643         * m4/mbswidth.m4: Likewise.
7644         * modules/quotearg (Depends-on): Depend on wchar.
7645         * lib/quotearg.c: Assume <wchar.h>.
7646         * m4/quotearg.m4: Likewise.
7647         * modules/regex (Depends-on): Depend on wchar.
7648         * lib/regex_internal.h: Assume <wchar.h>.
7649         * m4/regex.m4: Likewise.
7650         * modules/stdint (Depends-on): Depend on wchar.
7651         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
7652         * m4/stdint.m4: Likewise.
7653         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
7654         * modules/strftime (Depends-on): Depend on wchar.
7655         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
7656         * modules/strtol (Depends-on): Depend on wchar.
7657         * lib/strtol.c: Assume <wchar.h>.
7658         * modules/wcwidth (Depends-on): Depend on wchar.
7659         * lib/wcwidth.h: Assume <wchar.h>.
7660         * m4/wcwidth.m4: Likewise.
7661
7662 2007-01-16  Bruno Haible  <bruno@clisp.org>
7663
7664         * modules/csharpexec-script: New, created from...
7665         * modules/csharpexec: ... this.
7666
7667 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
7668
7669         * modules/javaexec-script: New, created from...
7670         * modules/javaexec: ... this.
7671
7672 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
7673
7674         * modules/poll (Dependencies): Add sys_select.
7675
7676 2007-01-15  Jim Meyering  <jim@meyering.net>
7677
7678         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
7679         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
7680         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
7681         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
7682
7683 2007-01-15  Bruno Haible  <bruno@clisp.org>
7684
7685         * modules/striconveh: New file.
7686         * lib/striconveh.h: New file.
7687         * lib/striconveh.c: New file.
7688         * MODULES.html.sh (Internationalization functions): Add striconveh.
7689
7690         * modules/striconveh-tests: New file.
7691         * tests/test-striconveh.c: New file.
7692
7693 2007-01-15  Bruno Haible  <bruno@clisp.org>
7694
7695         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
7696         not from GNU libiconv or GNU libc.
7697
7698 2007-01-15  Bruno Haible  <bruno@clisp.org>
7699
7700         * doc/gnulib-intro.texi (Copyright): Explain the different license
7701         terms for module descriptions, autoconf macros, tests, documentation.
7702
7703 2007-01-14  Bruno Haible  <bruno@clisp.org>
7704
7705         * modules/striconv-tests: New file.
7706         * tests/test-striconv.c: New file.
7707
7708 2007-01-14  Bruno Haible  <bruno@clisp.org>
7709
7710         * modules/iconv-tests: New file.
7711         * tests/test-iconv.c: New file.
7712
7713 2007-01-14  Bruno Haible  <bruno@clisp.org>
7714
7715         * gnulib-tool (func_get_license): For test modules, use the license of
7716         the main module.
7717
7718 2007-01-14  Bruno Haible  <bruno@clisp.org>
7719
7720         * modules/iconv (Include): Clarify that <iconv.h> can only be included
7721         if iconv is found to exist.
7722
7723 2007-01-14  Bruno Haible  <bruno@clisp.org>
7724
7725         * modules/c-ctype-tests: New file.
7726         * tests/test-c-ctype.c: New file.
7727
7728 2007-01-14  Bruno Haible  <bruno@clisp.org>
7729
7730         * modules/binary-io-tests: New file.
7731         * tests/test-binary-io.sh: New file.
7732         * tests/test-binary-io.c: New file.
7733
7734 2007-01-14  Bruno Haible  <bruno@clisp.org>
7735
7736         * modules/array-oset-tests: New file.
7737         * tests/test-array_oset.c: New file.
7738
7739 2007-01-14  Bruno Haible  <bruno@clisp.org>
7740
7741         * modules/array-list-tests: New file.
7742         * tests/test-array_list.c: New file.
7743
7744 2007-01-14  Bruno Haible  <bruno@clisp.org>
7745
7746         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
7747         and make.
7748         Reported by Simon Josefsson in
7749         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
7750
7751 2007-01-14  Bruno Haible  <bruno@clisp.org>
7752
7753         * modules/allocsa-tests: New file.
7754         * tests/test-allocsa.c: New file.
7755
7756 2007-01-14  Bruno Haible  <bruno@clisp.org>
7757
7758         * modules/fchdir (Depends-on): Add absolute-header.
7759         * modules/unistd (Depends-on): Likewise.
7760
7761 2006-12-30  Bruno Haible  <bruno@clisp.org>
7762
7763         * modules/fchdir: New file.
7764         * modules/unistd (Files): Add lib/unistd_.h.
7765         (Makefile.am): Generate unistd.h from unistd_.h.
7766         * lib/fchdir.c: New file.
7767         * lib/dirent_.h: New file.
7768         * lib/unistd_.h: New file.
7769         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
7770         * m4/fchdir.m4: New file.
7771         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
7772         (gl_HEADER_UNISTD): Invoke it.
7773         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
7774         function.
7775         * lib/backupfile.c (opendir, closedir): Undefine.
7776         * lib/chown.c (open, close): Undefine.
7777         * lib/clean-temp.c (open, close): Undefine.
7778         * lib/copy-file.c (open, close): Undefine.
7779         * lib/execute.c (open, close): Undefine.
7780         * lib/fsusage.c (open, close): Undefine.
7781         * lib/gc-gnulib.c (open, close): Undefine.
7782         * lib/getcwd.c (opendir, closedir): Undefine.
7783         * lib/glob.c (opendir, closedir): Undefine.
7784         * lib/javacomp.c (open, close): Undefine.
7785         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
7786         * lib/openat-proc.c (open, close): Undefine.
7787         * lib/pagealign_alloc.c (open, close): Undefine.
7788         * lib/pipe.c (open, close): Undefine.
7789         * lib/progreloc.c (open, close): Undefine.
7790         * lib/savedir.c (opendir, closedir): Undefine.
7791         * lib/utime.c (open, close): Undefine.
7792         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
7793
7794 2007-01-10  Bruno Haible  <bruno@clisp.org>
7795
7796         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
7797
7798 2007-01-12  Eric Blake  <ebb9@byu.net>
7799
7800         Provide a robust <wchar.h>.  Further simplifications are now
7801         possible in other modules, but not included here.
7802         * modules/wchar: New module.
7803         * m4/wchar.m4: New file.
7804         * lib/wchar_.h: Likewise.
7805         * modules/mbchar (Depends-on): Depend on wchar, as the first use
7806         of the new module.
7807         * MODULES.html.sh (Extended multibyte and wide character utilities):
7808         New section.
7809
7810 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
7811
7812         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
7813         to a reasonable default for memory allocation.
7814         (xreadlink): Don't allocate a huge buffer, to work around a buggy
7815         file system that reports garbage st_size values for symlinks.
7816         Problem reported by Liyang Hu.
7817
7818 2007-01-11  Simon Josefsson  <simon@josefsson.org>
7819
7820         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
7821         Emacs .#* auto-save files).
7822
7823 2007-01-11  Bruno Haible  <bruno@clisp.org>
7824
7825         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
7826         directory.
7827
7828 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
7829
7830         Use @...@ consistently in lib/wctype_.h.
7831         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
7832         on it being set to 1 or 0.
7833         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
7834         go back to AC_SUBSTing it.
7835         * modules/wctype (Makefile.am): Undo previous change.
7836
7837 2007-01-10  Eric Blake  <ebb9@byu.net>
7838
7839         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
7840         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
7841         * modules/wctype (Makefile.am): Likewise.
7842         Reported by Chris McGuire.
7843
7844 2007-01-10  Jim Meyering  <jim@meyering.net>
7845
7846         fts.c: a small readability/maintainability improvement
7847         * lib/fts.c (fts_read): Make this code slightly more readable and
7848         maintainable by hoisting the "sp->fts_cur = p" assignments to
7849         immediately follow the statements that set P.  Derived from
7850         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
7851
7852 2007-01-10  Eric Blake  <ebb9@byu.net>
7853
7854         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
7855         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
7856         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
7857         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
7858         Reported by Chris McGuire.
7859
7860 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7861
7862         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
7863         in sed script.
7864
7865 2007-01-09  Bruno Haible  <bruno@clisp.org>
7866
7867         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
7868         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
7869         variables.
7870         (func_module): Use them.
7871
7872 2007-01-09  Bruno Haible  <bruno@clisp.org>
7873
7874         * modules/unistr/base: New file.
7875         * lib/unistr.h: New file.
7876
7877         * modules/unistr/u8-to-u16: New file.
7878         * lib/unistr/u8-to-u16.c: New file.
7879
7880         * modules/unistr/u8-to-u32: New file.
7881         * lib/unistr/u8-to-u32.c: New file.
7882
7883         * modules/unistr/u16-to-u8: New file.
7884         * lib/unistr/u16-to-u8.c: New file.
7885
7886         * modules/unistr/u16-to-u32: New file.
7887         * lib/unistr/u16-to-u32.c: New file.
7888
7889         * modules/unistr/u32-to-u8: New file.
7890         * lib/unistr/u32-to-u8.c: New file.
7891
7892         * modules/unistr/u32-to-u16: New file.
7893         * lib/unistr/u32-to-u16.c: New file.
7894
7895         * modules/unistr/u8-check: New file.
7896         * modules/unistr/u16-check: New file.
7897         * modules/unistr/u32-check: New file.
7898         * lib/unistr/u8-check.c: New file.
7899         * lib/unistr/u16-check.c: New file.
7900         * lib/unistr/u32-check.c: New file.
7901
7902         * modules/unistr/u8-chr: New file.
7903         * modules/unistr/u16-chr: New file.
7904         * modules/unistr/u32-chr: New file.
7905         * lib/unistr/u8-chr.c: New file.
7906         * lib/unistr/u16-chr.c: New file.
7907         * lib/unistr/u32-chr.c: New file.
7908
7909         * modules/unistr/u8-cmp: New file.
7910         * modules/unistr/u16-cmp: New file.
7911         * modules/unistr/u32-cmp: New file.
7912         * lib/unistr/u8-cmp.c: New file.
7913         * lib/unistr/u16-cmp.c: New file.
7914         * lib/unistr/u32-cmp.c: New file.
7915
7916         * modules/unistr/u8-cpy: New file.
7917         * modules/unistr/u16-cpy: New file.
7918         * modules/unistr/u32-cpy: New file.
7919         * lib/unistr/u8-cpy.c: New file.
7920         * lib/unistr/u16-cpy.c: New file.
7921         * lib/unistr/u32-cpy.c: New file.
7922         * lib/unistr/u-cpy.h: New file.
7923
7924         * modules/unistr/u8-cpy-alloc: New file.
7925         * modules/unistr/u16-cpy-alloc: New file.
7926         * modules/unistr/u32-cpy-alloc: New file.
7927         * lib/unistr/u8-cpy-alloc.c: New file.
7928         * lib/unistr/u16-cpy-alloc.c: New file.
7929         * lib/unistr/u32-cpy-alloc.c: New file.
7930         * lib/unistr/u-cpy-alloc.h: New file.
7931
7932         * modules/unistr/u8-endswith: New file.
7933         * modules/unistr/u16-endswith: New file.
7934         * modules/unistr/u32-endswith: New file.
7935         * lib/unistr/u8-endswith.c: New file.
7936         * lib/unistr/u16-endswith.c: New file.
7937         * lib/unistr/u32-endswith.c: New file.
7938         * lib/unistr/u-endswith.h: New file.
7939
7940         * modules/unistr/u8-mblen: New file.
7941         * modules/unistr/u16-mblen: New file.
7942         * modules/unistr/u32-mblen: New file.
7943         * lib/unistr/u8-mblen.c: New file.
7944         * lib/unistr/u16-mblen.c: New file.
7945         * lib/unistr/u32-mblen.c: New file.
7946
7947         * modules/unistr/u8-mbtouc: New file.
7948         * modules/unistr/u16-mbtouc: New file.
7949         * modules/unistr/u32-mbtouc: New file.
7950         * lib/unistr/u8-mbtouc.c: New file.
7951         * lib/unistr/u16-mbtouc.c: New file.
7952         * lib/unistr/u32-mbtouc.c: New file.
7953
7954         * modules/unistr/u8-mbtouc-safe: New file.
7955         * modules/unistr/u16-mbtouc-safe: New file.
7956         * modules/unistr/u32-mbtouc-safe: New file.
7957         * lib/unistr/u8-mbtouc-safe.c: New file.
7958         * lib/unistr/u16-mbtouc-safe.c: New file.
7959         * lib/unistr/u32-mbtouc-safe.c: New file.
7960
7961         * modules/unistr/u8-move: New file.
7962         * modules/unistr/u16-move: New file.
7963         * modules/unistr/u32-move: New file.
7964         * lib/unistr/u8-move.c: New file.
7965         * lib/unistr/u16-move.c: New file.
7966         * lib/unistr/u32-move.c: New file.
7967         * lib/unistr/u-move.h: New file.
7968
7969         * modules/unistr/u8-next: New file.
7970         * modules/unistr/u16-next: New file.
7971         * modules/unistr/u32-next: New file.
7972         * lib/unistr/u8-next.c: New file.
7973         * lib/unistr/u16-next.c: New file.
7974         * lib/unistr/u32-next.c: New file.
7975
7976         * modules/unistr/u8-prev: New file.
7977         * modules/unistr/u16-prev: New file.
7978         * modules/unistr/u32-prev: New file.
7979         * lib/unistr/u8-prev.c: New file.
7980         * lib/unistr/u16-prev.c: New file.
7981         * lib/unistr/u32-prev.c: New file.
7982
7983         * modules/unistr/u8-set: New file.
7984         * modules/unistr/u16-set: New file.
7985         * modules/unistr/u32-set: New file.
7986         * lib/unistr/u8-set.c: New file.
7987         * lib/unistr/u16-set.c: New file.
7988         * lib/unistr/u32-set.c: New file.
7989         * lib/unistr/u-set.h: New file.
7990
7991         * modules/unistr/u8-startswith: New file.
7992         * modules/unistr/u16-startswith: New file.
7993         * modules/unistr/u32-startswith: New file.
7994         * lib/unistr/u8-startswith.c: New file.
7995         * lib/unistr/u16-startswith.c: New file.
7996         * lib/unistr/u32-startswith.c: New file.
7997         * lib/unistr/u-startswith.h: New file.
7998
7999         * modules/unistr/u8-stpcpy: New file.
8000         * modules/unistr/u16-stpcpy: New file.
8001         * modules/unistr/u32-stpcpy: New file.
8002         * lib/unistr/u8-stpcpy.c: New file.
8003         * lib/unistr/u16-stpcpy.c: New file.
8004         * lib/unistr/u32-stpcpy.c: New file.
8005         * lib/unistr/u-stpcpy.h: New file.
8006
8007         * modules/unistr/u8-stpncpy: New file.
8008         * modules/unistr/u16-stpncpy: New file.
8009         * modules/unistr/u32-stpncpy: New file.
8010         * lib/unistr/u8-stpncpy.c: New file.
8011         * lib/unistr/u16-stpncpy.c: New file.
8012         * lib/unistr/u32-stpncpy.c: New file.
8013         * lib/unistr/u-stpncpy.h: New file.
8014
8015         * modules/unistr/u8-strcat: New file.
8016         * modules/unistr/u16-strcat: New file.
8017         * modules/unistr/u32-strcat: New file.
8018         * lib/unistr/u8-strcat.c: New file.
8019         * lib/unistr/u16-strcat.c: New file.
8020         * lib/unistr/u32-strcat.c: New file.
8021         * lib/unistr/u-strcat.h: New file.
8022
8023         * modules/unistr/u8-strchr: New file.
8024         * modules/unistr/u16-strchr: New file.
8025         * modules/unistr/u32-strchr: New file.
8026         * lib/unistr/u8-strchr.c: New file.
8027         * lib/unistr/u16-strchr.c: New file.
8028         * lib/unistr/u32-strchr.c: New file.
8029
8030         * modules/unistr/u8-strcmp: New file.
8031         * modules/unistr/u16-strcmp: New file.
8032         * modules/unistr/u32-strcmp: New file.
8033         * lib/unistr/u8-strcmp.c: New file.
8034         * lib/unistr/u16-strcmp.c: New file.
8035         * lib/unistr/u32-strcmp.c: New file.
8036
8037         * modules/unistr/u8-strcpy: New file.
8038         * modules/unistr/u16-strcpy: New file.
8039         * modules/unistr/u32-strcpy: New file.
8040         * lib/unistr/u8-strcpy.c: New file.
8041         * lib/unistr/u16-strcpy.c: New file.
8042         * lib/unistr/u32-strcpy.c: New file.
8043         * lib/unistr/u-strcpy.h: New file.
8044
8045         * modules/unistr/u8-strcspn: New file.
8046         * modules/unistr/u16-strcspn: New file.
8047         * modules/unistr/u32-strcspn: New file.
8048         * lib/unistr/u8-strcspn.c: New file.
8049         * lib/unistr/u16-strcspn.c: New file.
8050         * lib/unistr/u32-strcspn.c: New file.
8051         * lib/unistr/u-strcspn.h: New file.
8052
8053         * modules/unistr/u8-strdup: New file.
8054         * modules/unistr/u16-strdup: New file.
8055         * modules/unistr/u32-strdup: New file.
8056         * lib/unistr/u8-strdup.c: New file.
8057         * lib/unistr/u16-strdup.c: New file.
8058         * lib/unistr/u32-strdup.c: New file.
8059         * lib/unistr/u-strdup.h: New file.
8060
8061         * modules/unistr/u8-strlen: New file.
8062         * modules/unistr/u16-strlen: New file.
8063         * modules/unistr/u32-strlen: New file.
8064         * lib/unistr/u8-strlen.c: New file.
8065         * lib/unistr/u16-strlen.c: New file.
8066         * lib/unistr/u32-strlen.c: New file.
8067         * lib/unistr/u-strlen.h: New file.
8068
8069         * modules/unistr/u8-strmblen: New file.
8070         * modules/unistr/u16-strmblen: New file.
8071         * modules/unistr/u32-strmblen: New file.
8072         * lib/unistr/u8-strmblen.c: New file.
8073         * lib/unistr/u16-strmblen.c: New file.
8074         * lib/unistr/u32-strmblen.c: New file.
8075
8076         * modules/unistr/u8-strmbtouc: New file.
8077         * modules/unistr/u16-strmbtouc: New file.
8078         * modules/unistr/u32-strmbtouc: New file.
8079         * lib/unistr/u8-strmbtouc.c: New file.
8080         * lib/unistr/u16-strmbtouc.c: New file.
8081         * lib/unistr/u32-strmbtouc.c: New file.
8082
8083         * modules/unistr/u8-strncat: New file.
8084         * modules/unistr/u16-strncat: New file.
8085         * modules/unistr/u32-strncat: New file.
8086         * lib/unistr/u8-strncat.c: New file.
8087         * lib/unistr/u16-strncat.c: New file.
8088         * lib/unistr/u32-strncat.c: New file.
8089         * lib/unistr/u-strncat.h: New file.
8090
8091         * modules/unistr/u8-strncmp: New file.
8092         * modules/unistr/u16-strncmp: New file.
8093         * modules/unistr/u32-strncmp: New file.
8094         * lib/unistr/u8-strncmp.c: New file.
8095         * lib/unistr/u16-strncmp.c: New file.
8096         * lib/unistr/u32-strncmp.c: New file.
8097
8098         * modules/unistr/u8-strncpy: New file.
8099         * modules/unistr/u16-strncpy: New file.
8100         * modules/unistr/u32-strncpy: New file.
8101         * lib/unistr/u8-strncpy.c: New file.
8102         * lib/unistr/u16-strncpy.c: New file.
8103         * lib/unistr/u32-strncpy.c: New file.
8104         * lib/unistr/u-strncpy.h: New file.
8105
8106         * modules/unistr/u8-strnlen: New file.
8107         * modules/unistr/u16-strnlen: New file.
8108         * modules/unistr/u32-strnlen: New file.
8109         * lib/unistr/u8-strnlen.c: New file.
8110         * lib/unistr/u16-strnlen.c: New file.
8111         * lib/unistr/u32-strnlen.c: New file.
8112         * lib/unistr/u-strnlen.h: New file.
8113
8114         * modules/unistr/u8-strpbrk: New file.
8115         * modules/unistr/u16-strpbrk: New file.
8116         * modules/unistr/u32-strpbrk: New file.
8117         * lib/unistr/u8-strpbrk.c: New file.
8118         * lib/unistr/u16-strpbrk.c: New file.
8119         * lib/unistr/u32-strpbrk.c: New file.
8120         * lib/unistr/u-strpbrk.h: New file.
8121
8122         * modules/unistr/u8-strrchr: New file.
8123         * modules/unistr/u16-strrchr: New file.
8124         * modules/unistr/u32-strrchr: New file.
8125         * lib/unistr/u8-strrchr.c: New file.
8126         * lib/unistr/u16-strrchr.c: New file.
8127         * lib/unistr/u32-strrchr.c: New file.
8128
8129         * modules/unistr/u8-strspn: New file.
8130         * modules/unistr/u16-strspn: New file.
8131         * modules/unistr/u32-strspn: New file.
8132         * lib/unistr/u8-strspn.c: New file.
8133         * lib/unistr/u16-strspn.c: New file.
8134         * lib/unistr/u32-strspn.c: New file.
8135         * lib/unistr/u-strspn.h: New file.
8136
8137         * modules/unistr/u8-strstr: New file.
8138         * modules/unistr/u16-strstr: New file.
8139         * modules/unistr/u32-strstr: New file.
8140         * lib/unistr/u8-strstr.c: New file.
8141         * lib/unistr/u16-strstr.c: New file.
8142         * lib/unistr/u32-strstr.c: New file.
8143         * lib/unistr/u-strstr.h: New file.
8144
8145         * modules/unistr/u8-strtok: New file.
8146         * modules/unistr/u16-strtok: New file.
8147         * modules/unistr/u32-strtok: New file.
8148         * lib/unistr/u8-strtok.c: New file.
8149         * lib/unistr/u16-strtok.c: New file.
8150         * lib/unistr/u32-strtok.c: New file.
8151         * lib/unistr/u-strtok.h: New file.
8152
8153         * modules/unistr/u8-uctomb: New file.
8154         * modules/unistr/u16-uctomb: New file.
8155         * modules/unistr/u32-uctomb: New file.
8156         * lib/unistr/u8-uctomb.c: New file.
8157         * lib/unistr/u16-uctomb.c: New file.
8158         * lib/unistr/u32-uctomb.c: New file.
8159
8160         * MODULES.html.sh (Unicode string functions): Add the new modules.
8161
8162 2007-01-08  Bruno Haible  <bruno@clisp.org>
8163
8164         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
8165         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
8166         subdirectories.
8167
8168 2007-01-08  Karl Berry  <karl@gnu.org>
8169
8170         * doc/error.texi: mention that main() fns must set program_name
8171         when progname is used.
8172
8173 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
8174
8175         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
8176         WCTYPE_H is empty, for the benefit of builds from non-distclean
8177         directories.  Problem reported by Eric Blake in
8178         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
8179
8180 2007-01-08  Bruno Haible  <bruno@clisp.org>
8181
8182         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
8183         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
8184         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
8185         PROVIDE_CANONICALIZE_FILENAME_MODE.
8186         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
8187
8188 2007-01-08  Bruno Haible  <bruno@clisp.org>
8189
8190         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
8191         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
8192         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
8193         * lib/fts.c: Likewise.
8194         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
8195
8196 2006-12-25  Bruno Haible  <bruno@clisp.org>
8197
8198         * modules/utf8-ucs4-safe: New file.
8199         * lib/utf8-ucs4-safe.h: New file.
8200         * lib/unistr/utf8-ucs4-safe.c: New file.
8201
8202         * modules/utf16-ucs4-safe: New file.
8203         * lib/utf16-ucs4-safe.h: New file.
8204         * lib/unistr/utf16-ucs4-safe.c: New file.
8205
8206         * MODULES.html.sh (Unicode string functions): Add the new modules.
8207
8208 2007-01-08  Bruno Haible  <bruno@clisp.org>
8209
8210         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
8211         (Depends-on): Add unitypes.
8212         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
8213         (u8_mbtouc_aux): Move out to separate file.
8214         (u8_mbtouc): Use ucs4_t, uint8_t types.
8215         * lib/unistr/utf8-ucs4.c: New file.
8216
8217         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
8218         (Depends-on): Add unitypes.
8219         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
8220         (u16_mbtouc_aux): Move out to separate file.
8221         (u16_mbtouc): Use ucs4_t, uint16_t types.
8222         * lib/unistr/utf16-ucs4.c: New file.
8223
8224         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
8225         (Depends-on): Add unitypes.
8226         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
8227         (u8_uctomb_aux): Move out to separate file.
8228         (u8_uctomb): Use ucs4_t, uint8_t types.
8229         * lib/unistr/ucs4-utf8.c: New file.
8230
8231         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
8232         (Depends-on): Add unitypes.
8233         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
8234         (u16_uctomb_aux): Move out to separate file.
8235         (u16_uctomb): Use ucs4_t, uint16_t types.
8236         * lib/unistr/ucs4-utf16.c: New file.
8237
8238 2006-12-25  Bruno Haible  <bruno@clisp.org>
8239
8240         * modules/unitypes: New file.
8241         * lib/unitypes.h: New file.
8242         * MODULES.html.sh (func_all_modules): New section "Unicode string
8243         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
8244         this section. Add unitypes.
8245
8246 2007-01-08  Bruno Haible  <bruno@clisp.org>
8247
8248         Avoid variable names that conflict with those from libtool.
8249         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
8250         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
8251         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
8252         library_names_spec to acl_library_names_spec, hardcode_* to
8253         acl_hardcode_*.
8254         Reported by Ralf Wildenhues.
8255
8256 2007-01-08  Bruno Haible  <bruno@clisp.org>
8257
8258         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
8259         definition.
8260         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
8261         definition.
8262         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
8263         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
8264         definition.
8265         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
8266         definition.
8267         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
8268         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
8269         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
8270         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
8271         definition.
8272         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
8273         definition.
8274         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
8275         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
8276         GC_USE_<algorithm>.
8277         * lib/gc-libgcrypt.c: Likewise.
8278         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
8279         * modules/gc-arctwo (configure.ac): Likewise.
8280         * modules/gc-des (configure.ac): Likewise.
8281         * modules/gc-hmac-md5 (configure.ac): Likewise.
8282         * modules/gc-hmac-sha1 (configure.ac): Likewise.
8283         * modules/gc-md2 (configure.ac): Likewise.
8284         * modules/gc-md4 (configure.ac): Likewise.
8285         * modules/gc-md5 (configure.ac): Likewise.
8286         * modules/gc-random (configure.ac): Likewise.
8287         * modules/gc-rijndael (configure.ac): Likewise.
8288         * modules/gc-sha1 (configure.ac): Likewise.
8289
8290 2007-01-08  Bruno Haible  <bruno@clisp.org>
8291
8292         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
8293         macro definition.
8294         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
8295         definition.
8296         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
8297         definition.
8298         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
8299         * modules/fcntl-safer (configure.ac): Likewise.
8300         * modules/fopen-safer (configure.ac): Likewise.
8301         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
8302         GNULIB_FWRITEERROR macro definition.
8303
8304 2007-01-08  Bruno Haible  <bruno@clisp.org>
8305
8306         * m4/gnulib-common.m4: New file.
8307         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
8308         (func_get_filelist): Add m4/gnulib-common.m4.
8309
8310 2007-01-08  Bruno Haible  <bruno@clisp.org>
8311
8312         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
8313         command.
8314
8315 2007-01-08  Jim Meyering  <jim@meyering.net>
8316
8317         Use a more robust test for a "can't happen" condition.
8318         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
8319         narrowed the st_size value.  Presuming the "can't happen" condition
8320         is true, that narrowing could conceivably convert an invalid st_size
8321         value into a valid one.  Instead, use a change based on Matthew
8322         Woehlke's original patch.
8323
8324         Slight readability improvement: use an assert-like macro
8325         in place of literal "abort ()" uses.
8326         * lib/fts.c (fts_assert): Define.
8327         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
8328         Use this macro instead of a bare 'abort'.
8329
8330 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
8331
8332         Don't worry about using IRIX 5.3's wctype.h broken definitions;
8333         simply work around them.
8334         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
8335         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
8336         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
8337         declaring.
8338         Don't bother to define as macros, since the standard doesn't require it.
8339         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
8340         longer worry about IRIX 5.3.
8341         (HAVE_WCTYPE_CTMP_BUG): Remove.
8342
8343 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
8344
8345         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
8346         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
8347         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
8348         Problems reported by Georg Schwarz for IRIX 5.3.
8349
8350         * gnulib-tool (autoconf_minversion): Take the maximum version number
8351         found, not the minimum.  Problem reported by James Youngman.
8352
8353 2007-01-03  Karl Berry  <karl@gnu.org>
8354
8355         * doc/error.texi: new file, explaining interaction with progname.
8356         * doc/gnulib.texi: include it.  Update copyright.
8357
8358 2007-01-03  Simon Josefsson  <simon@josefsson.org>
8359
8360         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
8361         AC_CANONICAL_HOST, to improve autobuild outputs.
8362
8363 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
8364             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
8365
8366         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
8367         sockets, server sockets, and other file descriptors.  Count errors
8368         to compute the return value.  Reorder the code a bit to be easier
8369         to follow.  Don't set event bits that were not requested (except
8370         POLLERR and POLLHUP).
8371
8372 2007-01-01  Bruno Haible  <bruno@clisp.org>
8373
8374         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
8375
8376 2007-01-03  Jim Meyering  <jim@meyering.net>
8377
8378         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
8379
8380 2007-01-02  Bruno Haible  <bruno@clisp.org>
8381
8382         * modules/settime (Include): Require timespec.h.
8383         * modules/nanosleep (Include): Likewise.
8384
8385 2007-01-01  Bruno Haible  <bruno@clisp.org>
8386
8387         * gnulib-tool (func_emit_copyright_notice): Bump year.
8388         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
8389
8390 2007-01-01  Bruno Haible  <bruno@clisp.org>
8391
8392         Improve support for OpenBSD.
8393         * build-aux/config.rpath (libname_spec): Export.
8394         (library_names_spec): New variable. Export.
8395         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
8396         library_names_spec from the config.rpath output. Locate shared library
8397         through the name pattern in library_names_spec.
8398
8399 2007-01-01  Eric Blake  <ebb9@byu.net>
8400
8401         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
8402
8403 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
8404
8405         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
8406         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
8407         assume the C locale, and avoid an "eval" that could cause trouble.
8408         Problem with SORT reported by Bob Proulx.
8409
8410         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
8411         Define.  Trivial patch from Henning Nielsen Lund, originally
8412         sent to bug-grep@gnu.org today.
8413
8414 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
8415
8416         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
8417         struct stat.  Problem reported by Henning Nielsen Lund.
8418         * lib/acl.c: Include acl.h first, to check interface.  Don't
8419         bother to include sys/types.h and sys/stat.h again.
8420
8421 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
8422
8423         Import the following change from libc; problem reported by
8424         Sven Verdoolaege.
8425
8426         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
8427
8428         [BZ #1373]
8429         * lib/argp.h: Remove __NTH for __argp_usage inline function.
8430
8431 2006-12-28  Jim Meyering  <jim@meyering.net>
8432
8433         * build-aux/announce-gen: Do not assume that the package
8434         builds any of tar.gz, tar.bz2, and .xdelta files.
8435         Suggestion from Simon Josefsson.
8436
8437 2006-12-28  Simon Josefsson  <simon@josefsson.org>
8438
8439         * modules/announce-gen: New file.
8440
8441 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
8442
8443         * lib/mbchar.h: Just include <wctype.h>; the wctype module
8444         handles its gotchas now.
8445         * lib/mbswidth.c: Likewise.
8446         * lib/wcwidth.h: Likewise.
8447         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
8448         and iswcntrl; the wctype module does this stuff now.
8449         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
8450         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
8451         * modules/mbchar (Depends-on): Add wctype.
8452         * modules/mbswidth (Depends-on): Likewise.
8453         * modules/wcwidth (Depends-on): Likewise.
8454
8455 2006-12-27  Eric Blake  <ebb9@byu.net>
8456
8457         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
8458         module uses more than what <wctype.h> is required to provide.
8459
8460 2006-12-26  Eric Blake  <ebb9@byu.net>
8461
8462         * gnulib-tool (sed_extract_prog): Avoid space-tab.
8463
8464 2006-12-26  Eric Blake  <ebb9@byu.net>
8465
8466         * modules/absolute-header: New module.
8467         * modules/fcntl (Depends-on): Depend on it.
8468         * modules/inttypes (Depends-on): Likewise.
8469         * modules/stdint (Depends-on): Likewise.
8470         * modules/sys_stat (Depends-on): Likewise.
8471         * modules/wctype (Depends-on): Likewise.
8472         * MODULES.html.sh (Support for building libraries and
8473         executables): Document it.
8474
8475 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
8476
8477         * gnulib-tool (SED): Remove, undoing previous change.
8478         The problem was that it broke coreutils on Solaris, because
8479         "sed --posix" leaked into a makefile.
8480         (sed): New alias, if 'alias' and GNU sed.
8481
8482 2006-12-24  Jim Meyering  <jim@meyering.net>
8483
8484         Work around an fchownat bug in glibc-2.4:
8485         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
8486         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
8487         in spite of the -P option.
8488         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
8489         New macros.
8490         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
8491         * modules/openat (Files): Add lib/fchownat.c.
8492         * lib/openat.c (fchownat): Don't define here.  Move to...
8493         * lib/fchownat.c: ...this new file.
8494
8495 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
8496
8497         Fix bug reported by Bruno Haible in
8498         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
8499         where quotearg.c didn't compile on Mac OS X 10.2 because it
8500         lacks <wchar.h> and wint_t.
8501         * lib/wctype_.h (__wctype_wint_t): New type.
8502         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
8503         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
8504         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
8505         Arg is now of type __wctype_wint_t, not wint_t.
8506         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
8507         substitute HAVE_WINT_T.
8508         * modules/wctype (Files): Add m4/wint_t.m4.
8509         (wctype.h): Substitute HAVE_WINT_T.
8510
8511 2006-12-23  Bruno Haible  <bruno@clisp.org>
8512
8513         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
8514
8515 2006-12-23  Bruno Haible  <bruno@clisp.org>
8516
8517         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
8518         S_ISLNK.
8519         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
8520         mingw.
8521
8522 2006-12-22  Bruno Haible  <bruno@clisp.org>
8523
8524         * lib/copy-file.c: Include acl.h.
8525         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
8526         Close the file descriptors only after being done with copy_acl.
8527         * modules/copy-file (Depends-on): Add acl.
8528
8529 2006-12-22  Bruno Haible  <bruno@clisp.org>
8530
8531         * gnulib-tool (SED): New variable.
8532         Use $SED instead of sed everywhere.
8533
8534 2006-12-22  Bruno Haible  <bruno@clisp.org>
8535
8536         * modules/no-c++: New file.
8537         * m4/no-c++.m4: New file.
8538         * MODULES.html.sh (Support for building libraries and executables):
8539         Add no-c++.
8540
8541 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
8542
8543         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
8544         Include <limits.h>, and use its INT_MAX to rewrite the
8545         j loop so that it does not overflow 'int'.  Problem reported by
8546         Ralf Wildenhues in
8547         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
8548         Play it safe by shifting left by 1 rather than multiplying by 2,
8549         as GCC is less likely to optimize this away when the value
8550         is signed (when it assumes overflow leads to undefined behavior).
8551         Also, don't assume time_t uses two's complement.
8552
8553 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
8554
8555         * MODULES.html.sh: New module wctype.
8556         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
8557         * lib/fnmatch.c: Don't bother to include <wchar.h> before
8558         <wctype.h>, since the new wctype module should fix this.
8559         * lib/quotearg.c: Include <wctype.h> unconditionally, since
8560         the wctype module should arrange for it.
8561         * lib/regex_internal.h: Likewise.
8562         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
8563         since the wctype module should handle this now.
8564         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
8565         * modules/fnmatch (Depends-on): Add wctype.
8566         * modules/quotearg (Depends-on): Likewise.
8567         * modules/regex (Depends-on): Likewise.
8568
8569 2006-12-19  Bruno Haible  <bruno@clisp.org>
8570
8571         * lib/strdup.h [C++]: Wrap definitions in extern "C".
8572         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
8573
8574 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8575
8576         * modules/savewd (Depends-on): Fix dependency on fcntl.
8577
8578 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
8579
8580         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
8581         conforms to C99, rather than relying on the user's environment
8582         setting of STDINT_H.
8583
8584 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
8585         and Eric Blake  <ebb9@byu.net>
8586
8587         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
8588         This is more consistent with the other defines here.
8589         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
8590         Port to z/OS.  Problem reported by Paul Gilmartin.
8591         Change local vars to use gl_ prefix rather than ac_.
8592         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
8593         with other defines.
8594         * modules/double-slash-root: New module.
8595         * modules/dirname (Files): Remove m4/double-slash-root.m4.
8596         (Depends-on): Add double-slash-root.
8597         * MODULES.html.sh (File system functions): Mention new module.
8598
8599 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
8600
8601         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
8602         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
8603         This is for the benefit of gzip, which doesn't do i18n.
8604
8605 2006-12-12  Jim Meyering  <jim@meyering.net>
8606
8607         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
8608         Reported by Andreas Schwab <schwab@suse.de>.
8609
8610 2006-12-12  Bruno Haible  <bruno@clisp.org>
8611
8612         Merge these changes.
8613         2006-09-05  Bruno Haible  <bruno@clisp.org>
8614         * lib/iconvme.c (iconv_string): No need to save and restore errno when
8615         iconv_alloc succeeded.
8616         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
8617         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
8618         test for " && dest " at the end - dest is always != NULL there. Call
8619         iconv with 4xNULL arguments initially, to reset the state. Call iconv
8620         with 2xNULL arguments, also to flush the state storage. Handle the
8621         IRIX iconv behaviour. Realloc the final result, to throw away unused
8622         memory.
8623
8624 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
8625
8626         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
8627         and fchmodat unconditionally, since glibc 2.4 has them.
8628         Problem reported by Arkadiusz Miskiewicz.
8629
8630 2006-12-10  Bruno Haible  <bruno@clisp.org>
8631
8632         * gnulib-tool (func_import): Show the include files only for those
8633         modules that are copied and specified.
8634         Reported by Karl Berry.
8635
8636 2006-12-08  Jim Meyering  <jim@meyering.net>
8637
8638         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
8639         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
8640
8641         * build-aux/announce-gen: Add two new options, both optional:
8642         --bootstrap-tools=TOOL_LIST
8643               a comma-separated list of tools, e.g.,
8644               autoconf,automake,bison,gnulib
8645         --gnulib-snapshot-date=DATE
8646               if gnulib is in the bootstrap tool list,
8647               then report this as the snapshot date.
8648               If not specified, use the current date/time.
8649               If you specify a date here, be sure it's UTC.
8650
8651 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8652
8653         * tests/test-argp-2.sh: Fix test to match actual output.
8654         (func_compare): Fix sed script to be portable.
8655
8656 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
8657
8658         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
8659         workaround for this case.  It is not autoconfigured now; offhand
8660         it's hard to see how to autoconfigure it.
8661
8662 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
8663
8664         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
8665         a directory that is about to be chowned.  Such a directory's
8666         initial file permissions should permit the owner only and this
8667         should not be changed until after the chown, since the group and
8668         other bits would be incorrect if they granted permission before
8669         the chown.
8670
8671         Fix porting problem for iswctype reported by Georg Schwarz in:
8672         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
8673         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
8674         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
8675         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
8676         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
8677
8678 2006-12-03  Jim Meyering  <jim@meyering.net>
8679
8680         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
8681         p->fts_statp may not yet be defined.
8682         (fts_read): Instead, set it in the caller, once p->fts_statp is
8683         sure to be defined, and corresponds to a top-level directory.
8684         This bug made du -x fail.  Here's the coreutils test case:
8685         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
8686         Reported by Mike Frysinger.
8687
8688 2006-12-01  Jim Meyering  <jim@meyering.net>
8689
8690         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
8691         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
8692         Reported by Simon Josefsson.
8693
8694 2006-11-30  Jim Meyering  <jim@meyering.net>
8695
8696         * m4/warning.m4: Use the all-permissive copyright notice
8697         recommended by RMS (rather than LGPL).
8698         * m4/vararrays.m4: Likewise.
8699         * m4/flexmember.m4: Likewise.
8700
8701 2006-11-29  Bruno Haible  <bruno@clisp.org>
8702
8703         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
8704         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
8705         using +=.
8706         Reported by Simon Josefsson <simon@josefsson.org>.
8707
8708 2006-11-28  James Youngman <jay@gnu.org>
8709
8710         * README: Advise users that they might find the bug-gnulib@gnu.org
8711         and autotools-announce@gnu.org mailing lists useful.
8712
8713 2006-11-28  Bruno Haible  <bruno@clisp.org>
8714
8715         * m4/ptrdiff_max.m4: Remove file.
8716
8717 2006-11-21  Bruno Haible  <bruno@clisp.org>
8718
8719         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
8720         _AC_COMPUTE_INT.
8721         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8722         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
8723         _AC_COMPUTE_INT.
8724         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8725         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
8726         _AC_COMPUTE_INT.
8727         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8728
8729 2006-11-28  Jim Meyering  <jim@meyering.net>
8730
8731         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
8732         warning from "gcc -Wshadow" about shadowing the builtin.
8733
8734 2006-11-27  Bruno Haible  <bruno@clisp.org>
8735
8736         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
8737         _AC_COMPUTE_INT.
8738         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
8739
8740 2006-11-27  Bruno Haible  <bruno@clisp.org>
8741             Paul Eggert  <eggert@cs.ucla.edu>
8742
8743         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
8744
8745 2006-11-26  Bruno Haible  <bruno@clisp.org>
8746
8747         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
8748         noinst_LTLIBRARIES.
8749
8750 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
8751             Bruno Haible  <bruno@clisp.org>
8752
8753         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
8754         if compiling with "gcc -ansi".
8755
8756 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
8757
8758         Fix some incompatibilities with gcc -ansi -pedantic.
8759         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
8760         if compiling pedantically with GCC, unless it's C99 or later.
8761         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
8762         it mishandles gcc -ansi -pedantic as well.
8763         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
8764         if gcc -pedantic.
8765         * lib/regexec.c (check_node_accept_bytes): Don't use auto
8766         initializers for struct if -pedantic, unless it's C99 or later.
8767
8768 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
8769
8770         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
8771         Don't close an fd more than once. Identical atimes indicate
8772         success, not failure.
8773
8774 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
8775
8776         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
8777
8778 2006-11-23  Jim Meyering  <jim@meyering.net>
8779
8780         * build-aux/announce-gen: New file.  From coreutils.
8781
8782 2006-11-22  Jim Meyering  <jim@meyering.net>
8783
8784         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
8785         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
8786         (fts_read): Use a temporary to narrow the overused st_size member
8787         before using it in a switch statement.  Reported by Matthew Woehlke.
8788
8789         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
8790         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
8791
8792 2006-11-20  Bruno Haible  <bruno@clisp.org>
8793
8794         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
8795         changequote instead of pairs of brackets.
8796         Reported by Andreas Schwab <schwab@suse.de>.
8797
8798 2006-11-21  Jim Meyering  <jim@meyering.net>
8799
8800         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
8801         so as to remain compatible with older compilers.
8802         Patch from Michael Deutschmann.
8803
8804 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
8805
8806         * MODULES.html.sh (File system functions): Add openat.
8807
8808         * lib/openat.h (rpl_fstatat): New macro, if
8809         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
8810         (fstatat): Define to rpl_fstatat under the same conditions,
8811         unless COMPILING_FSTATAT.
8812         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
8813         seems to have the bug.
8814         * lib/fstatat.c: New file.
8815         * modules/openat (Files): Add it.
8816
8817 2006-11-20  Bruno Haible  <bruno@clisp.org>
8818
8819         * Makefile: New file.
8820
8821 2006-11-20  Jim Meyering  <jim@meyering.net>
8822
8823         The beginnings of syntax-related checks for gnulib.
8824         * lib/Makefile: New file.
8825         * lib/t-idcache: New script.  Ensure that the two halves of
8826         idcache.c stay in sync.
8827
8828         * lib/idcache.c: Adjust comments in user- and group- portions to
8829         be more accurate, and to be consistent with one another.
8830
8831 2006-11-20  Jim Meyering  <jim@meyering.net>
8832
8833         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
8834         continue using the flexible array member (thus, this module performs
8835         half as many malloc calls), with the addition that...
8836         (getgroup, getuser): Consistently record a non-match via an empty
8837         "name" string, and map an empty string match to a NULL return value.
8838         * modules/idcache (Depends-on): Re-add flexmember.
8839
8840         * lib/idcache.c (getuser): Remove all uses of the register keyword.
8841         (getuidbyname, getgroup, getgidbyname): Likewise.
8842
8843         Use cleaner syntax: NULL rather than 0.
8844         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
8845
8846 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
8847
8848         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
8849         It mishandled the case where the group was missing.
8850         Problem reported by Greg Schafer.
8851         * modules/idcache: Likewise.
8852
8853 2006-11-18  Jim Meyering  <jim@meyering.net>
8854
8855         * check-module (%exempt_header): Add exception for some
8856         conditionally-included headers.
8857
8858         * modules/i-ring (Depends-on): Add verify.
8859         (License): Change to LGPL.
8860
8861 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
8862
8863         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
8864         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
8865         and inttostr.h.  Use snprintf rather than uinttostr, so that
8866         LGPLed code doesn't depend on GPLed.
8867
8868 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
8869
8870         * modules/inline (License): Change from GPL to LGPL.
8871
8872 2006-11-17  Jim Meyering  <jim@meyering.net>
8873
8874         * modules/d-type (License): Switch to LGPL.
8875
8876 2006-11-15  Bruno Haible  <bruno@clisp.org>
8877
8878         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
8879
8880 2006-11-15  Eric Blake  <ebb9@byu.net>
8881
8882         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
8883         the module dependency.
8884
8885 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
8886             Bruno Haible  <bruno@clisp.org>
8887
8888         * gnulib-tool (func_create_testdir): Add license consistency check.
8889
8890 2006-11-15  Eric Blake  <ebb9@byu.net>
8891
8892         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
8893         random "(cached)" in configure output.
8894
8895 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8896
8897         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
8898         test for conforming inttypes.h is both announced and cached.
8899
8900         * MODULES.html.sh (seen_modules, seen_files): New variables.
8901         (func_module): Rewrite to use a few less gnulib-tool and sed
8902         invocations.  Avoid a couple of quadratic algorithms for ...
8903         (missed_modules, missed_files): ... these, with ...
8904         (func_append, func_tmpdir): ... these new functions, from
8905         gnulib-tool.  Analogously, install traps for cleanup.
8906
8907         * tests/test-gc.c (main): Remove unused variables.
8908         * tests/test-read-file.c: Include stdlib.h, for 'free'.
8909
8910 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
8911
8912         * modules/inttostr (License): Change to LGPL.
8913
8914 2006-11-14  Eric Blake  <ebb9@byu.net>
8915
8916         * modules/tempname (License): Change to LGPL.
8917
8918 2006-11-14  Eric Blake  <ebb9@byu.net>
8919
8920         * doc/functions.texi (Function Portability): *printf functions on
8921         Cygwin now understand all POSIX size specifiers.
8922
8923 2006-11-14  Bruno Haible  <bruno@clisp.org>
8924
8925         * modules/c-ctype (License): Change to LGPL.
8926
8927 2006-11-12  Bruno Haible  <bruno@clisp.org>
8928
8929         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
8930         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
8931         for GNOME libraries, for which the include files are installed in
8932         subdirectories of $prefix/include.
8933
8934 2006-11-12  Bruno Haible  <bruno@clisp.org>
8935
8936         * m4/lib-link.m4: Require at least autoconf-2.54.
8937         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
8938         name to underscores for the --with option.
8939
8940 2006-11-13  Bruno Haible  <bruno@clisp.org>
8941
8942         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
8943         the tests directory.
8944         Reported by Ralf Wildenhues.
8945
8946 2006-11-13  Bruno Haible  <bruno@clisp.org>
8947
8948         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
8949         (func_emit_initmacro_end): Undo the override here.
8950         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
8951         Works around the famous automake error in coreutils.
8952
8953 2006-11-13  Eric Blake  <ebb9@byu.net>
8954
8955         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
8956         element, not its node.
8957
8958 2006-11-12  Bruno Haible  <bruno@clisp.org>
8959
8960         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
8961         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
8962
8963 2006-11-12  Bruno Haible  <bruno@clisp.org>
8964
8965         * gnulib-tool: New option --local-symlink.
8966         (func_usage): Document it.
8967         (lsymbolic): New variable.
8968         (func_import, func_create_testdir): If --symlink was not specified,
8969         test whether --local-symlink was specified and the file comes from
8970         the local_gnulib_dir.
8971
8972 2006-11-12  Bruno Haible  <bruno@clisp.org>
8973
8974         * gnulib-tool (func_ln): New function.
8975         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
8976
8977 2006-11-12  Bruno Haible  <bruno@clisp.org>
8978
8979         Finish support for source files in subdirectories.
8980         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
8981         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
8982         AUTOMAKE_OPTIONS.
8983         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
8984
8985 2006-11-12  Bruno Haible  <bruno@clisp.org>
8986
8987         * gnulib-tool (func_get_automake_snippet): Synthesize also an
8988         EXTRA_lib_SOURCES augmentation.
8989         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
8990
8991 2006-11-12  Jim Meyering  <jim@meyering.net>
8992
8993         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
8994         file descriptors.  This also averts a failure on systems with
8995         native openat support when a traversed directory lacks "x" access.
8996         * lib/fts_.h: Include "i-ring.h"
8997         (struct FTS) [fts_fd_ring]: New member.
8998         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
8999         (FCHDIR): Add parentheses.
9000         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
9001         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
9002         When descending, rather than simply closing the previous
9003         fts_cwd_fd value, push that file descriptor onto the ring.
9004         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
9005         (fts_open): Initialize the new fd_ring member.
9006         (fts_close): Clear the ring.
9007         (fts_safe_changedir): When possible, use our new fd_ring to skip
9008         the diropen and fstat and dev/ino comparison that would normally
9009         accompany a virtual `chdir ("..")'.
9010
9011         * modules/fts (Depends-on): Add i-ring.
9012         * modules/i-ring: New module.
9013         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
9014         * m4/i-ring.m4: New file.
9015
9016 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9017
9018         * gnulib-tool (func_create_testdir): Fix replacement of
9019         `build-aux' in configure.ac.  Run autotools in gltests
9020         subdirectory.
9021         (func_create_testdir, func_create_megatestdir, test): There is
9022         no need for '--force' in most autotool invocations in a new
9023         tree.  Actually fail the whole test if any of the tools, or the
9024         configure or make stages fail.
9025
9026         Sync from Automake.
9027         * build-aux/gnupload: Revert last change.  Add pointer to upload
9028         instructions of the GNU Maintenance Instructions.
9029         Suggestion by Karl Berry.
9030
9031 2006-11-10  Jim Meyering  <jim@meyering.net>
9032
9033         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
9034
9035 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
9036
9037         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
9038         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
9039         (bind_textdomain_codeset) [! ENABLE_NLS]:
9040         Evaluate all the arguments.  That way, callers get compatible behavior
9041         if the arguments have side effects.  Also, it avoids some GCC
9042         diagnostics in some cases; Joel E. Denny reported problems when Bison
9043         was configured with --enable-gcc-warnigs.
9044
9045 2006-11-10  Jim Meyering  <jim@meyering.net>
9046
9047         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
9048         relevant options in CFLAGS (like -O, -fno-inline) are taken into
9049         account.
9050
9051 2006-11-10  Jim Meyering  <jim@meyering.net>
9052
9053         * modules/inline: New file/module.
9054         * modules/xalloc (Files): Remove m4/inline.m4.
9055         (Depends-on): Add inline, instead.
9056         * modules/oset: Likewise.
9057         * modules/list: Likewise.
9058
9059 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
9060
9061         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
9062         Problem reported by Matthew Woehlke.
9063
9064 2006-11-09  Bruno Haible  <bruno@clisp.org>
9065
9066         * lib/tempname.c (gen_tempname): Remove variant that invokes
9067         __gen_tempname.
9068         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
9069         __gen_tempname.
9070
9071 2006-11-08  Bruno Haible  <bruno@clisp.org>
9072
9073         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
9074         to 'yes' instead of 'cross-compiling'.
9075
9076 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
9077
9078         * lib/quotearg.h (quotearg_free): New decl.
9079         * lib/quotearg.c (quotearg_free): New function.
9080         (slot0, nslots, slotvec0, slotvec):
9081         Now file-scope so that quotearg_free can get at them.
9082
9083 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9084
9085         Sync from Automake.
9086         * build-aux/gnupload: Add missing 'gnu' to example URL.
9087         Report by Karl Berry.
9088
9089 2006-11-08  Bruno Haible  <bruno@clisp.org>
9090
9091         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
9092         Suggested by Paul Eggert.
9093
9094 2006-11-08  Jim Meyering  <jim@meyering.net>
9095
9096         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
9097         It's already included if !_LIBC.
9098         (fts_safe_changedir): Add a comment.
9099
9100 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
9101
9102         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
9103         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
9104         Matthew Woehlke.
9105
9106         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
9107         definitions up, to avoid colliding with change below.
9108         (static_inline) [HAVE_INLINE]: New macro.
9109         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
9110         Provide extern decls when !HAVE_INLINE.  Do not define unless
9111         static_inline is defined, either by us or by xmalloc.c.  Use
9112         static_inline rather than static inline.
9113         (XCALLOC): Optimize sizeof(T) = 1 case.
9114         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
9115
9116 2006-11-07  Bruno Haible  <bruno@clisp.org>
9117
9118         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
9119         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
9120         AC_C_INLINE.
9121         * modules/xalloc (Files): Add m4/inline.m4.
9122
9123 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9124
9125         * README: Fix typo.
9126         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
9127         (Miscellanous Notes): ...from this.
9128
9129 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
9130
9131         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
9132         Mention that offsetof should be used instead of sizeof.
9133         From Bruno Haible.
9134
9135 2006-11-07  Bruno Haible  <bruno@clisp.org>
9136
9137         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
9138
9139 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
9140
9141         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
9142         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
9143         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
9144         (gl_tree_add_before, gl_tree_add_after):
9145         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
9146         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
9147         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
9148         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
9149         (gl_linked_add_after, gl_linked_add_at): Likewise.
9150         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
9151         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
9152         (gl_tree_add_before, gl_tree_add_after): Likewise.
9153         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
9154         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
9155         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
9156
9157 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9158
9159         * lib/gl_oset.h: Use C comment style, not C++ comment style.
9160
9161 2006-11-06  Bruno Haible  <bruno@clisp.org>
9162
9163         * m4/inline.m4: New file.
9164         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
9165         * modules/list (Files): Add m4/inline.m4.
9166         * modules/oset (Files): Likewise.
9167
9168 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
9169
9170         * lib/idcache.c: Include <stddef.h>, for offsetof.
9171         (struct userid.name): Change from char * to a flexible array member.
9172         All uses changed.
9173         * modules/idcache (Depends-on): Add flexmember.
9174
9175         * MODULES.html.sh (Core language properties): New module flexmember.
9176         * modules/flexmember, m4/flexmember.m4: New files.
9177
9178         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
9179         inline functions that are identical with the old xnmalloc_inline,
9180         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
9181         that we can avoid some unnecessary integer multiplications and
9182         divisions in the common case where the element size is known at
9183         compile time.
9184         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
9185         needed.
9186         (xnboundedmalloc): Remove.
9187         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
9188         arguments, for consistency with rest of this header.
9189         (xcharalloc): Rewrite using XNMALLOC.
9190         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
9191         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
9192         versions have been moved to lib/xalloc.h and renamed to be the
9193         non-*_inline versions.
9194         (xmalloc, xrealloc): Implement without reference to the xnmalloc
9195         and xnrealloc functions, since those functions are now inline and
9196         now call us.
9197         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
9198         renaming described above.
9199         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
9200         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
9201         captures the dependency in AC_C_INLINE.
9202
9203         New module canonicalize-lgpl, proposed by Charles Wilson in
9204         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
9205         with a few small changes afterwards.
9206         * MODULES.html.sh (File system functions): New module
9207         canonicalize-lgpl.
9208         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
9209         and canonicalize_file_name.
9210         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
9211         * modules/canonicalize-lgpl: New files.
9212
9213 2006-11-05  Bruno Haible  <bruno@clisp.org>
9214
9215         * gnulib-tool (func_import, func_create_testdir): Create directories
9216         also for files in subdirectories of lib/.
9217
9218 2006-11-05  Bruno Haible  <bruno@clisp.org>
9219
9220         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
9221         ANSI C compliant.
9222
9223 2006-11-03  Bruno Haible  <bruno@clisp.org>
9224
9225         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
9226         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
9227         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
9228         (xnboundedmalloc): New inline function.
9229         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
9230         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
9231         xmalloc.
9232         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
9233         xmalloc.
9234         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
9235         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
9236         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
9237         xmalloc.
9238         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
9239         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
9240         xmalloc.
9241         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
9242         gl_tree_add_after): Use XMALLOC instead of xmalloc.
9243         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
9244         xmalloc.
9245         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
9246         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
9247         gl_tree_add_after): Use XMALLOC instead of xmalloc.
9248         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
9249         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
9250         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
9251         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
9252
9253 2006-11-03  Bruno Haible  <bruno@clisp.org>
9254
9255         * lib/c-ctype.h [C++]: Define functions without name mangling.
9256         * lib/fwriteerror.h [C++]: Likewise.
9257         * lib/gcd.h [C++]: Likewise.
9258         * lib/linebreak.h [C++]: Likewise.
9259
9260 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
9261
9262         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
9263         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
9264         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
9265         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
9266         Check for functions and headers just once.
9267         Check for declaration of canonicalize_file_name.
9268         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
9269
9270 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
9271
9272         * gnulib-tool (func_import): Fix typo in actioncmd.
9273
9274 2006-11-02  Bruno Haible  <bruno@clisp.org>
9275
9276         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
9277         newline sequence in the Makefile.am snippet as a space, like "make"
9278         does.
9279         Reported by Roger Persson <perrog@gmail.com>.
9280
9281 2006-11-01  Bruno Haible  <bruno@clisp.org>
9282
9283         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
9284         already declared in <string.h>.
9285         * lib/strcase.h (strncasecmp): Don't declare it if yes.
9286
9287 2006-11-01  Bruno Haible  <bruno@clisp.org>
9288
9289         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
9290         * lib/strcase.h: Include <string.h>.
9291         (strcasecmp): Define to rpl_strcasecmp here.
9292
9293 2006-11-01  Bruno Haible  <bruno@clisp.org>
9294
9295         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
9296
9297 2006-11-01  Eric Blake  <ebb9@byu.net>
9298
9299         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
9300
9301         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
9302
9303 2006-10-29  Bruno Haible  <bruno@clisp.org>
9304
9305         Make it compile in C++ mode.
9306         * lib/full-write.c (full_rw): Add a cast.
9307
9308 2006-11-01  Bruno Haible  <bruno@clisp.org>
9309
9310         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
9311         be POSIX compliant.
9312         Reported by Roger Persson <perrog@gmail.com>.
9313
9314 2006-11-01  Eric Blake  <ebb9@byu.net>
9315
9316         * lib/getopt_.h: Fix comments.
9317
9318 2006-10-31  Eric Blake  <ebb9@byu.net>
9319
9320         * modules/tmpdir (Depends-on): Add sys_stat.
9321         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
9322         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
9323         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
9324         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
9325         tempname.
9326
9327 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
9328
9329         Avoid some C++ diagnostics reported by Bruno Haible.
9330         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
9331         xmalloc.
9332         (quotearg_alloc): Use xcharalloc rather than xmalloc.
9333         (struct slotvec): Move to top level.
9334         (quotearg_n_options): Rewrite to avoid xmalloc.
9335         * lib/xalloc.h (xcharalloc): New function.
9336         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
9337         [defined __cplusplus]: Add function template that provides result
9338         type propagation.  This part of the change is from Bruno Haible.
9339
9340 2006-10-29  Bruno Haible  <bruno@clisp.org>
9341
9342         Make it compile in C++ mode.
9343         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
9344         * lib/strnlen1.c (strnlen1): Cast memchr result.
9345         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
9346         * lib/clean-temp.c (string_equals, string_hash): Add casts.
9347         (create_temp_dir): Rename local variable 'template'.
9348         (compile_csharp_using_sscli): Add cast.
9349         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
9350         * lib/findprog.c (find_in_path): Likewise.
9351         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
9352         * lib/wait-process.c (register_slave_subprocess): Likewise.
9353
9354 2006-10-22  Bruno Haible  <bruno@clisp.org>
9355
9356         * modules/tsearch: New file.
9357         * lib/tsearch.h: New file.
9358         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
9359         * m4/tsearch.m4: New file.
9360         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
9361
9362 2006-10-29  Eric Blake  <ebb9@byu.net>
9363
9364         * lib/arcfour.c: Assume config.h.
9365         * lib/arctwo.c: Likewise.
9366         * lib/base64.c: Likewise.
9367         * lib/check-version.c: Likewise.
9368         * lib/crc.c: Likewise.
9369         * lib/des.c: Likewise.
9370         * lib/gc-gnulib.c: Likewise.
9371         * lib/gc-libgcrypt.c: Likewise.
9372         * lib/gc-pbkdf2-sha1.c: Likewise.
9373         * lib/getaddrinfo.c: Likewise.
9374         * lib/getdelim.c: Likewise.
9375         * lib/getline.c: Likewise.
9376         * lib/hmac-md5.c: Likewise.
9377         * lib/hmac-sha1.c: Likewise.
9378         * lib/iconvme.c: Likewise.
9379         * lib/md2.c: Likewise.
9380         * lib/md4.c: Likewise.
9381         * lib/memxor.c: Likewise.
9382         * lib/read-file.c: Likewise.
9383         * lib/readline.c: Likewise.
9384         * lib/rijndael-alg-fst.c: Likewise.
9385         * lib/rijndael-api-fst.c: Likewise.
9386         * lib/xgetdomainname.c: Likewise.
9387
9388 2006-10-28  Eric Blake  <ebb9@byu.net>
9389
9390         * lib/xstrndup.c: Assume config.h.
9391
9392 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
9393
9394         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
9395         stat-macros.h is now for our own macros, whereas stat_h is for
9396         macros in the <sys/stat.h> name space.
9397         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
9398         (STAT_MACROS_H): Remove.
9399         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
9400         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
9401         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
9402         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
9403         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
9404         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
9405         Move these macros to ...
9406         * lib/stat_.h: here.  Don't include stat-macros.h.
9407         * lib/canonicalize.c: Don't include stat-macros.h.
9408         * lib/chown.c: Likewise.
9409         * lib/euidaccess.c: Likewise.
9410         * lib/file-type.c: Likewise.
9411         * lib/filemode.c: Likewise.
9412         * lib/glob.c: Likewise.
9413         * lib/isapipe.c: Likewise.
9414         * lib/lchown.c: Likewise.
9415         * lib/lstat.c: Likewise.
9416         * lib/mkdir-p.c: Likewise.
9417         * lib/rmdir.c: Likewise.
9418         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
9419         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
9420         unless mkdir isn't declared, to speed up 'configure'.
9421         Always create sys/stat.h, since it's unlikely any real sys/stat.h
9422         would define all the S_* symbols.
9423         * modules/canonicalize (Depends-on):
9424         Depend on sys_stat, not stat-macros.
9425         * modules/chown: Likewise.
9426         * modules/euidaccess: Likewise.
9427         * modules/filemode: Likewise.
9428         * modules/file-type: Likewise.
9429         * modules/glob: Likewise.
9430         * modules/isapipe: Likewise.
9431         * modules/lchown: Likewise.
9432         * modules/lstat: Likewise.
9433         * modules/mkancesdirs: Likewise.
9434         * modules/rmdir: Likewise.
9435         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
9436         * modules/modechange: Likewise.
9437         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
9438         (configure.ac): Remove gl_STAT_MACROS.
9439         * modules/sys_stat (Depends-on): Remove stat-macros.
9440
9441 2006-10-27  Bruno Haible  <bruno@clisp.org>
9442
9443         * m4/signed.m4: Remove file.
9444         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
9445         invocation.
9446         * modules/vasnprintf (Files): Remove m4/signed.m4.
9447
9448 2006-10-27  Bruno Haible  <bruno@clisp.org>
9449
9450         Update to GNU gettext 0.16.
9451         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
9452         m4/inttypes-h.m4, m4/signed.m4.
9453         * m4/gettext.m4: Update to GNU gettext 0.16.
9454         * m4/intl.m4: New file, from GNU gettext.
9455         * m4/intldir.m4: New file, from GNU gettext.
9456         * config/srclist.txt: Update
9457
9458 2006-10-27  Eric Blake  <ebb9@byu.net>
9459
9460         * MODULES.html.sh: Document tempname.
9461         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
9462         dependencies.
9463         (Files): Move lib/tempname.c...
9464         * modules/tempname: ...to this new module.
9465         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
9466         (gl_PREREQ_TEMPNAME): Move...
9467         * m4/tempname.m4: ...to this new file.
9468         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
9469         * modules/sys_stat (Depends-on): Add stat-macros.
9470         * lib/stat_.h (includes): Pick up stat macros.
9471         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
9472         if stat macros are broken.
9473         * lib/tempname.c (includes): No need to include "stat-macros.h".
9474         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
9475         (direxists, __path_search) [!_LIBC]: Don't compile these in
9476         gnulib; the tmpdir module covers that.
9477         * lib/tempname.h: New file.
9478
9479 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
9480
9481         * COPYING: Explain how gnulib-tool converts licence headers.
9482         Almost all wording by Eric Blake.
9483
9484 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
9485
9486         * lib/mbchar.h (is_basic_table): Make read-only.
9487         * lib/mbchar.c (is_basic_table): Likewise.
9488         Reported by John Darrington.
9489
9490 2006-10-25  Bruno Haible  <bruno@clisp.org>
9491
9492         * lib/progname.h (set_program_name): Undefine before defining.
9493
9494 2006-10-25  Bruno Haible  <bruno@clisp.org>
9495
9496         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
9497         false for non-gcc C++ compilers.
9498         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
9499
9500 2006-10-24  Bruno Haible  <bruno@clisp.org>
9501
9502         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
9503         iconv implementations like Irix iconv.
9504
9505 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
9506
9507         * modules/vararrays: New file.
9508         * m4/vararrays.m4: New file, taken from diffutils.
9509         * MODULES.html.sh: New module vararrays.
9510
9511 2006-10-24  Karl Berry  <karl@gnu.org>
9512
9513         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
9514         Don't call GNU Unix.
9515
9516 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9517
9518         * users.txt: Add Libtool.
9519
9520         Sync from Libtool:
9521
9522         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
9523
9524         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
9525         to gnulib's policy of including config.h unconditionally.
9526
9527 2006-10-24  Bruno Haible  <bruno@clisp.org>
9528
9529         * modules/wcwidth (Files): Add m4/wint_t.m4.
9530         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
9531         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
9532
9533 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
9534
9535         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
9536         to pacify GCC with some -W flags enabled.  Problem reported by
9537         Bruno Haible.
9538
9539 2006-10-24  Jim Meyering  <jim@meyering.net>
9540
9541         * MODULES.html.sh: Remove uinttostr.  It's not a module.
9542         Reported by Karl Berry.
9543
9544 2006-10-23  Bruno Haible  <bruno@clisp.org>
9545
9546         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
9547
9548 2006-10-24  Bruno Haible  <bruno@clisp.org>
9549
9550         * lib/gl_list.h: Use C comment style, not C++ comment style.
9551
9552 2006-10-23  Eric Blake  <ebb9@byu.net>
9553
9554         * lib/getaddrinfo.c (includes): Add missing include.
9555
9556 2006-10-23  Bruno Haible  <bruno@clisp.org>
9557             Paul Eggert  <eggert@cs.ucla.edu>
9558
9559         Ability to rename obstack_free.
9560         * lib/obstack.h (__obstack_free): New macro. Declare instead of
9561         obstack_free.
9562         (obstack_free): Invoke the __obstack_free macro.
9563         * lib/obstack.c (obstack_free): Use __obstack_free macro.
9564
9565 2006-10-23  Bruno Haible  <bruno@clisp.org>
9566             Paul Eggert  <eggert@cs.ucla.edu>
9567
9568         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
9569         __argc, __argv from the declaration. (They are defined as macros on
9570         mingw.)
9571
9572 2006-10-22  Bruno Haible  <bruno@clisp.org>
9573
9574         * doc/gnulib-intro.texi: New file.
9575         * doc/gnulib.texi: Include it.
9576
9577 2006-10-21  Bruno Haible  <bruno@clisp.org>
9578
9579         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
9580         "Introduction", "Miscellanous Notes", "Particular Modules".
9581
9582 2006-10-21  Bruno Haible  <bruno@clisp.org>
9583
9584         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9585         Change mostlyclean-local rule to avoid sh syntax error from bash
9586         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
9587
9588 2006-10-23  Jim Meyering  <jim@meyering.net>
9589
9590         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
9591         in place of snprintf.
9592
9593         * modules/inttostr (Files): Add lib/uinttostr.c.
9594         * lib/uinttostr.c (inttostr): New file/function.
9595         * lib/inttostr.h (uinttostr): Declare.
9596         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
9597         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
9598         Add uinttostr.
9599         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
9600
9601 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
9602
9603         * lib/canonicalize.c (ELOOP): Define if not already defined.
9604         Problem reported by Bruno Haible in
9605         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
9606
9607 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
9608
9609         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
9610         Problem reported by Perry Smith and Ville Laurikari.
9611
9612         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
9613         uses.
9614
9615 2006-10-19  Bruno Haible  <bruno@clisp.org>
9616
9617         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
9618         for mingw.
9619
9620 2006-10-19  Bruno Haible  <bruno@clisp.org>
9621
9622         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
9623         Needed for mingw.
9624
9625 2006-10-19  Bruno Haible  <bruno@clisp.org>
9626
9627         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
9628
9629 2006-10-19  Bruno Haible  <bruno@clisp.org>
9630
9631         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
9632         it.
9633
9634 2006-10-19  Bruno Haible  <bruno@clisp.org>
9635
9636         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
9637         invocation.
9638
9639 2006-10-19  Bruno Haible  <bruno@clisp.org>
9640
9641         * gnulib-tool (func_create_testdir): Don't include ftruncate and
9642         mountlist by default.
9643
9644 2006-10-16  Bruno Haible  <bruno@clisp.org>
9645
9646         * lib/c-strstr.c: Include c-strstr.h.
9647
9648 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
9649
9650         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
9651         in a slash.
9652
9653 2006-10-18  Bruno Haible  <bruno@clisp.org>
9654
9655         * lib/lock.h [C++]: Wrap definitions in extern "C".
9656
9657 2006-10-18  Bruno Haible  <bruno@clisp.org>
9658
9659         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
9660         gl_LIBOBJS list.
9661
9662 2006-10-18  Bruno Haible  <bruno@clisp.org>
9663
9664         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
9665
9666 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
9667
9668         * lib/xstrtol.h: Include gettext.h.
9669         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
9670         Problem reported by Eric Blake.
9671         * modules/xstrtol (Depends-on): Add gettext-h.
9672
9673 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
9674
9675         * lib/strftime.c (advance): New macro.
9676         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
9677         incomplete type, so you can't add 0 to it.  Problem and patch
9678         reported by Eelco Dolstra for dietlibc.
9679
9680 2006-10-18  Jim Meyering  <jim@meyering.net>
9681
9682         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
9683         type for a local, and rename it: s/up/user_proc/.
9684
9685 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
9686
9687         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
9688         READ_UTMP_USER_PROCESS.
9689         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
9690
9691 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
9692
9693         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
9694         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
9695
9696 2006-10-17  Eric Blake  <ebb9@byu.net>
9697
9698         * lib/sigprocmask.c (sigprocmask): Fix typo.
9699
9700         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
9701
9702         * modules/clean-temp (Makefile.am): Don't add to make output...
9703         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
9704         config.h.
9705
9706 2006-10-17  Bruno Haible  <bruno@clisp.org>
9707
9708         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
9709         differently if DEFAULT_TEXT_DOMAIN is set.
9710
9711 2006-10-16  Bruno Haible  <bruno@clisp.org>
9712
9713         * lib/clean-temp.c: Include fwriteerror.h.
9714
9715 2006-10-16  Bruno Haible  <bruno@clisp.org>
9716
9717         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
9718
9719 2006-10-16  Bruno Haible  <bruno@clisp.org>
9720
9721         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
9722         * lib/sigprocmask.h: Include <sys/types.h>.
9723         (sigset_t): Use the system's definition if present.
9724
9725 2006-10-17  Eric Blake  <ebb9@byu.net>
9726
9727         * lib/xvasprintf.c (includes): Assume config.h.
9728         * lib/xasprintf.c (includes): Likewise.
9729
9730 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
9731
9732         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
9733         at least as wide as intmax_t.
9734
9735 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
9736
9737         (Imported from Automake.)
9738         * build-aux/gnupload: Update to version 1.1 of directive file.
9739
9740 2006-10-16  Eric Blake  <ebb9@byu.net>
9741
9742         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
9743         match Automake 1.10a.
9744
9745 2006-10-14  Bruno Haible  <bruno@clisp.org>
9746
9747         * modules/sigprocmask: New file.
9748         * lib/sigprocmask.h: New file.
9749         * lib/sigprocmask.c: New file.
9750         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
9751         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
9752         request sigprocmask.o.
9753         (gl_PREREQ_SIGPROCMASK): New macro.
9754         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
9755         (Depends-on): Add sigprocmask.
9756         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
9757         gt_SIGNALBLOCKING. Test for 'raise' only once.
9758         * lib/fatal-signal.c: Include sigprocmask.h.
9759         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
9760         unblock_fatal_signals): Define always.
9761         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
9762         sigprocmask.
9763
9764 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
9765
9766         Sync from Automake.
9767         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
9768         which incorrectly sets the mode of an existing destination
9769         directory.  In some cases the unpatched install-sh could do the
9770         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
9771         system.  We hope this is rare in practice, but it's clearly worth
9772         fixing.  Problem reported by Alex Unleashed in
9773         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
9774         Also, don't bother to check for -m bugs unless we're using -m;
9775         suggested by Stepan Kasal.
9776
9777 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9778
9779         Sync from Automake.
9780         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
9781         `-c' flag, so they appear at the same position as in %FASTDEP%
9782         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
9783         which ignores unknown options only after the first non-option.
9784         Bug report against M4 by Nelson H. F. Beebe.
9785
9786 2006-10-13  Jim Meyering  <jim@meyering.net>
9787
9788         Fix a bug in yesterday's change.
9789         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
9790         p->fts_statp->st_dev would be used uninitialized.
9791         Ensures that we always call fts_stat on the very first entry.
9792         Miklos Szeredi reported that find -xdev stopped working.
9793
9794 2006-10-12  Bruno Haible  <bruno@clisp.org>
9795
9796         * gnulib-tool (func_get_automake_snippet): Append an automatically
9797         computed EXTRA_DIST augmentation.
9798         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
9799         * modules/alloca-opt (Makefile.am): Likewise.
9800         * modules/allocsa (Makefile.am): Likewise.
9801         * modules/arcfour (Makefile.am): Likewise.
9802         * modules/arctwo (Makefile.am): Likewise.
9803         * modules/argmatch (Makefile.am): Likewise.
9804         * modules/argz (Makefile.am): Likewise.
9805         * modules/atexit (Makefile.am): Likewise.
9806         * modules/backupfile (Makefile.am): Likewise.
9807         * modules/byteswap (Makefile.am): Likewise.
9808         * modules/c-strtod (Makefile.am): Likewise.
9809         * modules/c-strtold (Makefile.am): Likewise.
9810         * modules/calloc (Makefile.am): Likewise.
9811         * modules/canon-host (Makefile.am): Likewise.
9812         * modules/canonicalize (Makefile.am): Likewise.
9813         * modules/chdir-long (Makefile.am): Likewise.
9814         * modules/chdir-safer (Makefile.am): Likewise.
9815         * modules/check-version (Makefile.am): Likewise.
9816         * modules/chown (Makefile.am): Likewise.
9817         * modules/cloexec (Makefile.am): Likewise.
9818         * modules/close-stream (Makefile.am): Likewise.
9819         * modules/closeout (Makefile.am): Likewise.
9820         * modules/crc (Makefile.am): Likewise.
9821         * modules/csharpexec (Makefile.am): Likewise.
9822         * modules/cycle-check (Makefile.am): Likewise.
9823         * modules/des (Makefile.am): Likewise.
9824         * modules/dev-ino (Makefile.am): Likewise.
9825         * modules/dirfd (Makefile.am): Likewise.
9826         * modules/dirname (Makefile.am): Likewise.
9827         * modules/dup2 (Makefile.am): Likewise.
9828         * modules/eealloc (Makefile.am): Likewise.
9829         * modules/error (Makefile.am): Likewise.
9830         * modules/euidaccess (Makefile.am): Likewise.
9831         * modules/exclude (Makefile.am): Likewise.
9832         * modules/exitfail (Makefile.am): Likewise.
9833         * modules/fcntl-safer (Makefile.am): Likewise.
9834         * modules/fcntl (Makefile.am): Likewise.
9835         * modules/file-type (Makefile.am): Likewise.
9836         * modules/fileblocks (Makefile.am): Likewise.
9837         * modules/filemode (Makefile.am): Likewise.
9838         * modules/filenamecat (Makefile.am): Likewise.
9839         * modules/fnmatch (Makefile.am): Likewise.
9840         * modules/fopen-safer (Makefile.am): Likewise.
9841         * modules/fpending (Makefile.am): Likewise.
9842         * modules/fprintftime (Makefile.am): Likewise.
9843         * modules/free (Makefile.am): Likewise.
9844         * modules/fsusage (Makefile.am): Likewise.
9845         * modules/ftruncate (Makefile.am): Likewise.
9846         * modules/fts (Makefile.am): Likewise.
9847         * modules/gc-arcfour (Makefile.am): Likewise.
9848         * modules/gc-des (Makefile.am): Likewise.
9849         * modules/gc-hmac-md5 (Makefile.am): Likewise.
9850         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
9851         * modules/gc-md4 (Makefile.am): Likewise.
9852         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
9853         * modules/gc-sha1 (Makefile.am): Likewise.
9854         * modules/gc (Makefile.am): Likewise.
9855         * modules/getaddrinfo (Makefile.am): Likewise.
9856         * modules/getcwd (Makefile.am): Likewise.
9857         * modules/getdelim (Makefile.am): Likewise.
9858         * modules/getdomainname (Makefile.am): Likewise.
9859         * modules/getgroups (Makefile.am): Likewise.
9860         * modules/gethostname (Makefile.am): Likewise.
9861         * modules/gethrxtime (Makefile.am): Likewise.
9862         * modules/getline (Makefile.am): Likewise.
9863         * modules/getloadavg (Makefile.am): Likewise.
9864         * modules/getlogin_r (Makefile.am): Likewise.
9865         * modules/getndelim2 (Makefile.am): Likewise.
9866         * modules/getopt (Makefile.am): Likewise.
9867         * modules/getpagesize (Makefile.am): Likewise.
9868         * modules/getpass-gnu (Makefile.am): Likewise.
9869         * modules/getpass (Makefile.am): Likewise.
9870         * modules/getsubopt (Makefile.am): Likewise.
9871         * modules/gettime (Makefile.am): Likewise.
9872         * modules/gettimeofday (Makefile.am): Likewise.
9873         * modules/getugroups (Makefile.am): Likewise.
9874         * modules/getusershell (Makefile.am): Likewise.
9875         * modules/glob (Makefile.am): Likewise.
9876         * modules/group-member (Makefile.am): Likewise.
9877         * modules/hard-locale (Makefile.am): Likewise.
9878         * modules/hash (Makefile.am): Likewise.
9879         * modules/hmac-md5 (Makefile.am): Likewise.
9880         * modules/hmac-sha1 (Makefile.am): Likewise.
9881         * modules/human (Makefile.am): Likewise.
9882         * modules/idcache (Makefile.am): Likewise.
9883         * modules/imaxabs (Makefile.am): Likewise.
9884         * modules/imaxdiv (Makefile.am): Likewise.
9885         * modules/inet_ntop (Makefile.am): Likewise.
9886         * modules/inet_pton (Makefile.am): Likewise.
9887         * modules/intprops (Makefile.am): Likewise.
9888         * modules/inttostr (Makefile.am): Likewise.
9889         * modules/inttypes (Makefile.am): Likewise.
9890         * modules/isapipe (Makefile.am): Likewise.
9891         * modules/javaversion (Makefile.am): Likewise.
9892         * modules/lchmod (Makefile.am): Likewise.
9893         * modules/lchown (Makefile.am): Likewise.
9894         * modules/localcharset (Makefile.am): Likewise.
9895         * modules/long-options (Makefile.am): Likewise.
9896         * modules/lstat (Makefile.am): Likewise.
9897         * modules/malloc (Makefile.am): Likewise.
9898         * modules/mathl (Makefile.am): Likewise.
9899         * modules/mbchar (Makefile.am): Likewise.
9900         * modules/md2 (Makefile.am): Likewise.
9901         * modules/md4 (Makefile.am): Likewise.
9902         * modules/md5 (Makefile.am): Likewise.
9903         * modules/memcasecmp (Makefile.am): Likewise.
9904         * modules/memchr (Makefile.am): Likewise.
9905         * modules/memcmp (Makefile.am): Likewise.
9906         * modules/memcoll (Makefile.am): Likewise.
9907         * modules/memcpy (Makefile.am): Likewise.
9908         * modules/memmem (Makefile.am): Likewise.
9909         * modules/memmove (Makefile.am): Likewise.
9910         * modules/mempcpy (Makefile.am): Likewise.
9911         * modules/memrchr (Makefile.am): Likewise.
9912         * modules/memset (Makefile.am): Likewise.
9913         * modules/memxor (Makefile.am): Likewise.
9914         * modules/mkancesdirs (Makefile.am): Likewise.
9915         * modules/mkdir-p (Makefile.am): Likewise.
9916         * modules/mkdir (Makefile.am): Likewise.
9917         * modules/mkdtemp (Makefile.am): Likewise.
9918         * modules/mkstemp (Makefile.am): Likewise.
9919         * modules/mktime (Makefile.am): Likewise.
9920         * modules/modechange (Makefile.am): Likewise.
9921         * modules/mountlist (Makefile.am): Likewise.
9922         * modules/nanosleep (Makefile.am): Likewise.
9923         * modules/obstack (Makefile.am): Likewise.
9924         * modules/openat (Makefile.am): Likewise.
9925         * modules/pagealign_alloc (Makefile.am): Likewise.
9926         * modules/pathmax (Makefile.am): Likewise.
9927         * modules/physmem (Makefile.am): Likewise.
9928         * modules/poll (Makefile.am): Likewise.
9929         * modules/posixtm (Makefile.am): Likewise.
9930         * modules/posixver (Makefile.am): Likewise.
9931         * modules/putenv (Makefile.am): Likewise.
9932         * modules/quote (Makefile.am): Likewise.
9933         * modules/quotearg (Makefile.am): Likewise.
9934         * modules/raise (Makefile.am): Likewise.
9935         * modules/read-file (Makefile.am): Likewise.
9936         * modules/readline (Makefile.am): Likewise.
9937         * modules/readlink (Makefile.am): Likewise.
9938         * modules/readtokens (Makefile.am): Likewise.
9939         * modules/readutmp (Makefile.am): Likewise.
9940         * modules/realloc (Makefile.am): Likewise.
9941         * modules/regex (Makefile.am): Likewise.
9942         * modules/rename-dest-slash (Makefile.am): Likewise.
9943         * modules/rename (Makefile.am): Likewise.
9944         * modules/rijndael (Makefile.am): Likewise.
9945         * modules/rmdir (Makefile.am): Likewise.
9946         * modules/rpmatch (Makefile.am): Likewise.
9947         * modules/safe-read (Makefile.am): Likewise.
9948         * modules/safe-write (Makefile.am): Likewise.
9949         * modules/same-inode (Makefile.am): Likewise.
9950         * modules/same (Makefile.am): Likewise.
9951         * modules/save-cwd (Makefile.am): Likewise.
9952         * modules/savedir (Makefile.am): Likewise.
9953         * modules/setenv (Makefile.am): Likewise.
9954         * modules/settime (Makefile.am): Likewise.
9955         * modules/sha1 (Makefile.am): Likewise.
9956         * modules/sig2str (Makefile.am): Likewise.
9957         * modules/snprintf (Makefile.am): Likewise.
9958         * modules/stat-macros (Makefile.am): Likewise.
9959         * modules/stat-time (Makefile.am): Likewise.
9960         * modules/stdbool (Makefile.am): Likewise.
9961         * modules/stdint (Makefile.am): Likewise.
9962         * modules/stdlib-safer (Makefile.am): Likewise.
9963         * modules/stpcpy (Makefile.am): Likewise.
9964         * modules/stpncpy (Makefile.am): Likewise.
9965         * modules/strcase (Makefile.am): Likewise.
9966         * modules/strcasestr (Makefile.am): Likewise.
9967         * modules/strchrnul (Makefile.am): Likewise.
9968         * modules/strcspn (Makefile.am): Likewise.
9969         * modules/strdup (Makefile.am): Likewise.
9970         * modules/strerror (Makefile.am): Likewise.
9971         * modules/strftime (Makefile.am): Likewise.
9972         * modules/strndup (Makefile.am): Likewise.
9973         * modules/strnlen (Makefile.am): Likewise.
9974         * modules/strpbrk (Makefile.am): Likewise.
9975         * modules/strsep (Makefile.am): Likewise.
9976         * modules/strstr (Makefile.am): Likewise.
9977         * modules/strtod (Makefile.am): Likewise.
9978         * modules/strtoimax (Makefile.am): Likewise.
9979         * modules/strtok_r (Makefile.am): Likewise.
9980         * modules/strtol (Makefile.am): Likewise.
9981         * modules/strtoll (Makefile.am): Likewise.
9982         * modules/strtoul (Makefile.am): Likewise.
9983         * modules/strtoull (Makefile.am): Likewise.
9984         * modules/strtoumax (Makefile.am): Likewise.
9985         * modules/strverscmp (Makefile.am): Likewise.
9986         * modules/sys_socket (Makefile.am): Likewise.
9987         * modules/sys_stat (Makefile.am): Likewise.
9988         * modules/sysexits (Makefile.am): Likewise.
9989         * modules/time_r (Makefile.am): Likewise.
9990         * modules/timegm (Makefile.am): Likewise.
9991         * modules/timespec (Makefile.am): Likewise.
9992         * modules/tmpfile-safer (Makefile.am): Likewise.
9993         * modules/trim (Makefile.am): Likewise.
9994         * modules/unistd-safer (Makefile.am): Likewise.
9995         * modules/unlinkdir (Makefile.am): Likewise.
9996         * modules/unlocked-io (Makefile.am): Likewise.
9997         * modules/userspec (Makefile.am): Likewise.
9998         * modules/utime (Makefile.am): Likewise.
9999         * modules/utimecmp (Makefile.am): Likewise.
10000         * modules/utimens (Makefile.am): Likewise.
10001         * modules/vasnprintf (Makefile.am): Likewise.
10002         * modules/vasprintf (Makefile.am): Likewise.
10003         * modules/vsnprintf (Makefile.am): Likewise.
10004         * modules/xalloc (Makefile.am): Likewise.
10005         * modules/xgetcwd (Makefile.am): Likewise.
10006         * modules/xnanosleep (Makefile.am): Likewise.
10007         * modules/xreadlink (Makefile.am): Likewise.
10008         * modules/xstrtod (Makefile.am): Likewise.
10009         * modules/xstrtol (Makefile.am): Likewise.
10010         * modules/xstrtold (Makefile.am): Likewise.
10011         * modules/yesno (Makefile.am): Likewise.
10012         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
10013
10014 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
10015
10016         * modules/error (Makefile.am): Distribute files through
10017         EXTRA_DIST, not lib_SOURCES.
10018
10019 2006-10-12  Eric Blake  <ebb9@byu.net>
10020
10021         * modules/error (Makefile.am): Distribute files in /lib.
10022         * modules/obstack (Makefile.am): Likewise.
10023
10024 2006-10-12  Bruno Haible  <bruno@clisp.org>
10025
10026         * modules/acl (Makefile.am): Distribute all files in lib/ through
10027         EXTRA_DIST.
10028         * modules/arcfour (Makefile.am): Likewise.
10029         * modules/arctwo (Makefile.am): Likewise.
10030         * modules/argmatch (Makefile.am): Likewise.
10031         * modules/argz (Makefile.am): Likewise.
10032         * modules/atexit (Makefile.am): Likewise.
10033         * modules/backupfile (Makefile.am): Likewise.
10034         * modules/c-strtod (Makefile.am): Likewise.
10035         * modules/c-strtold (Makefile.am): Likewise.
10036         * modules/calloc (Makefile.am): Likewise.
10037         * modules/canon-host (Makefile.am): Likewise.
10038         * modules/canonicalize (Makefile.am): Likewise.
10039         * modules/chdir-long (Makefile.am): Likewise.
10040         * modules/chdir-safer (Makefile.am): Likewise.
10041         * modules/check-version (Makefile.am): Likewise.
10042         * modules/chown (Makefile.am): Likewise.
10043         * modules/cloexec (Makefile.am): Likewise.
10044         * modules/close-stream (Makefile.am): Likewise.
10045         * modules/closeout (Makefile.am): Likewise.
10046         * modules/crc (Makefile.am): Likewise.
10047         * modules/cycle-check (Makefile.am): Likewise.
10048         * modules/des (Makefile.am): Likewise.
10049         * modules/dirfd (Makefile.am): Likewise.
10050         * modules/dirname (Makefile.am): Likewise.
10051         * modules/dup2 (Makefile.am): Likewise.
10052         * modules/euidaccess (Makefile.am): Likewise.
10053         * modules/exclude (Makefile.am): Likewise.
10054         * modules/exitfail (Makefile.am): Likewise.
10055         * modules/fcntl-safer (Makefile.am): Likewise.
10056         * modules/file-type (Makefile.am): Likewise.
10057         * modules/fileblocks (Makefile.am): Likewise.
10058         * modules/filemode (Makefile.am): Likewise.
10059         * modules/filenamecat (Makefile.am): Likewise.
10060         * modules/fnmatch (Makefile.am): Likewise.
10061         * modules/fopen-safer (Makefile.am): Likewise.
10062         * modules/fpending (Makefile.am): Likewise.
10063         * modules/fprintftime (Makefile.am): Likewise.
10064         * modules/free (Makefile.am): Likewise.
10065         * modules/fsusage (Makefile.am): Likewise.
10066         * modules/ftruncate (Makefile.am): Likewise.
10067         * modules/fts (Makefile.am): Likewise.
10068         * modules/gc (Makefile.am): Likewise.
10069         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
10070         * modules/getaddrinfo (Makefile.am): Likewise.
10071         * modules/getcwd (Makefile.am): Likewise.
10072         * modules/getdelim (Makefile.am): Likewise.
10073         * modules/getdomainname (Makefile.am): Likewise.
10074         * modules/getgroups (Makefile.am): Likewise.
10075         * modules/gethostname (Makefile.am): Likewise.
10076         * modules/gethrxtime (Makefile.am): Likewise.
10077         * modules/getline (Makefile.am): Likewise.
10078         * modules/getloadavg (Makefile.am): Likewise.
10079         * modules/getlogin_r (Makefile.am): Likewise.
10080         * modules/getopt (Makefile.am): Likewise.
10081         * modules/getpass (Makefile.am): Likewise.
10082         * modules/getpass-gnu (Makefile.am): Likewise.
10083         * modules/getsubopt (Makefile.am): Likewise.
10084         * modules/gettime (Makefile.am): Likewise.
10085         * modules/gettimeofday (Makefile.am): Likewise.
10086         * modules/getugroups (Makefile.am): Likewise.
10087         * modules/getusershell (Makefile.am): Likewise.
10088         * modules/glob (Makefile.am): Likewise.
10089         * modules/group-member (Makefile.am): Likewise.
10090         * modules/hard-locale (Makefile.am): Likewise.
10091         * modules/hash (Makefile.am): Likewise.
10092         * modules/hmac-md5 (Makefile.am): Likewise.
10093         * modules/hmac-sha1 (Makefile.am): Likewise.
10094         * modules/human (Makefile.am): Likewise.
10095         * modules/idcache (Makefile.am): Likewise.
10096         * modules/imaxabs (Makefile.am): Likewise.
10097         * modules/imaxdiv (Makefile.am): Likewise.
10098         * modules/inet_ntop (Makefile.am): Likewise.
10099         * modules/inet_pton (Makefile.am): Likewise.
10100         * modules/inttostr (Makefile.am): Likewise.
10101         * modules/isapipe (Makefile.am): Likewise.
10102         * modules/lchown (Makefile.am): Likewise.
10103         * modules/long-options (Makefile.am): Likewise.
10104         * modules/lstat (Makefile.am): Likewise.
10105         * modules/malloc (Makefile.am): Likewise.
10106         * modules/mathl (Makefile.am): Likewise.
10107         * modules/mbchar (Makefile.am): Likewise.
10108         * modules/md2 (Makefile.am): Likewise.
10109         * modules/md4 (Makefile.am): Likewise.
10110         * modules/md5 (Makefile.am): Likewise.
10111         * modules/memcasecmp (Makefile.am): Likewise.
10112         * modules/memchr (Makefile.am): Likewise.
10113         * modules/memcmp (Makefile.am): Likewise.
10114         * modules/memcoll (Makefile.am): Likewise.
10115         * modules/memcpy (Makefile.am): Likewise.
10116         * modules/memmem (Makefile.am): Likewise.
10117         * modules/memmove (Makefile.am): Likewise.
10118         * modules/mempcpy (Makefile.am): Likewise.
10119         * modules/memrchr (Makefile.am): Likewise.
10120         * modules/memset (Makefile.am): Likewise.
10121         * modules/memxor (Makefile.am): Likewise.
10122         * modules/mkancesdirs (Makefile.am): Likewise.
10123         * modules/mkdir (Makefile.am): Likewise.
10124         * modules/mkdir-p (Makefile.am): Likewise.
10125         * modules/mkdtemp (Makefile.am): Likewise.
10126         * modules/mkstemp (Makefile.am): Likewise.
10127         * modules/mktime (Makefile.am): Likewise.
10128         * modules/modechange (Makefile.am): Likewise.
10129         * modules/mountlist (Makefile.am): Likewise.
10130         * modules/nanosleep (Makefile.am): Likewise.
10131         * modules/openat (Makefile.am): Likewise.
10132         * modules/pagealign_alloc (Makefile.am): Likewise.
10133         * modules/physmem (Makefile.am): Likewise.
10134         * modules/poll (Makefile.am): Likewise.
10135         * modules/posixtm (Makefile.am): Likewise.
10136         * modules/posixver (Makefile.am): Likewise.
10137         * modules/putenv (Makefile.am): Likewise.
10138         * modules/quote (Makefile.am): Likewise.
10139         * modules/quotearg (Makefile.am): Likewise.
10140         * modules/raise (Makefile.am): Likewise.
10141         * modules/read-file (Makefile.am): Likewise.
10142         * modules/readline (Makefile.am): Likewise.
10143         * modules/readlink (Makefile.am): Likewise.
10144         * modules/readtokens (Makefile.am): Likewise.
10145         * modules/readutmp (Makefile.am): Likewise.
10146         * modules/realloc (Makefile.am): Likewise.
10147         * modules/regex (Makefile.am): Likewise.
10148         * modules/rename (Makefile.am): Likewise.
10149         * modules/rename-dest-slash (Makefile.am): Likewise.
10150         * modules/rijndael (Makefile.am): Likewise.
10151         * modules/rmdir (Makefile.am): Likewise.
10152         * modules/rpmatch (Makefile.am): Likewise.
10153         * modules/safe-read (Makefile.am): Likewise.
10154         * modules/safe-write (Makefile.am): Likewise.
10155         * modules/same (Makefile.am): Likewise.
10156         * modules/save-cwd (Makefile.am): Likewise.
10157         * modules/savedir (Makefile.am): Likewise.
10158         * modules/setenv (Makefile.am): Likewise.
10159         * modules/settime (Makefile.am): Likewise.
10160         * modules/sha1 (Makefile.am): Likewise.
10161         * modules/sig2str (Makefile.am): Likewise.
10162         * modules/snprintf (Makefile.am): Likewise.
10163         * modules/stdlib-safer (Makefile.am): Likewise.
10164         * modules/stpcpy (Makefile.am): Likewise.
10165         * modules/stpncpy (Makefile.am): Likewise.
10166         * modules/strcase (Makefile.am): Likewise.
10167         * modules/strcasestr (Makefile.am): Likewise.
10168         * modules/strchrnul (Makefile.am): Likewise.
10169         * modules/strcspn (Makefile.am): Likewise.
10170         * modules/strdup (Makefile.am): Likewise.
10171         * modules/strerror (Makefile.am): Likewise.
10172         * modules/strftime (Makefile.am): Likewise.
10173         * modules/strndup (Makefile.am): Likewise.
10174         * modules/strnlen (Makefile.am): Likewise.
10175         * modules/strpbrk (Makefile.am): Likewise.
10176         * modules/strsep (Makefile.am): Likewise.
10177         * modules/strstr (Makefile.am): Likewise.
10178         * modules/strtod (Makefile.am): Likewise.
10179         * modules/strtoimax (Makefile.am): Likewise.
10180         * modules/strtok_r (Makefile.am): Likewise.
10181         * modules/strtol (Makefile.am): Likewise.
10182         * modules/strtoll (Makefile.am): Likewise.
10183         * modules/strtoul (Makefile.am): Likewise.
10184         * modules/strtoull (Makefile.am): Likewise.
10185         * modules/strtoumax (Makefile.am): Likewise.
10186         * modules/strverscmp (Makefile.am): Likewise.
10187         * modules/time_r (Makefile.am): Likewise.
10188         * modules/timegm (Makefile.am): Likewise.
10189         * modules/tmpfile-safer (Makefile.am): Likewise.
10190         * modules/unistd-safer (Makefile.am): Likewise.
10191         * modules/unlinkdir (Makefile.am): Likewise.
10192         * modules/userspec (Makefile.am): Likewise.
10193         * modules/utime (Makefile.am): Likewise.
10194         * modules/utimecmp (Makefile.am): Likewise.
10195         * modules/utimens (Makefile.am): Likewise.
10196         * modules/vasnprintf (Makefile.am): Likewise.
10197         * modules/vasprintf (Makefile.am): Likewise.
10198         * modules/vsnprintf (Makefile.am): Likewise.
10199         * modules/xalloc (Makefile.am): Likewise.
10200         * modules/xgetcwd (Makefile.am): Likewise.
10201         * modules/xnanosleep (Makefile.am): Likewise.
10202         * modules/xreadlink (Makefile.am): Likewise.
10203         * modules/xstrtod (Makefile.am): Likewise.
10204         * modules/xstrtol (Makefile.am): Likewise.
10205         * modules/xstrtold (Makefile.am): Likewise.
10206         * modules/yesno (Makefile.am): Likewise.
10207
10208 2006-10-12  Jim Meyering  <jim@meyering.net>
10209
10210         * m4/getloadavg.m4: Revert the change below.
10211
10212         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
10213         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
10214         fail with a symlink, which is what coreutils' ./bootstrap now
10215         creates by default.
10216
10217 2006-10-12  Bruno Haible  <bruno@clisp.org>
10218
10219         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
10220         mingw.
10221         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
10222         MSVC and mingw explicitly.
10223
10224 2006-10-11  Simon Josefsson  <jas@extundo.com>
10225             Bruno Haible  <bruno@clisp.org>
10226
10227         Add support for multiple gnulib-tool invocations in the scope of a
10228         single configure.ac file.
10229         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
10230         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
10231         with the same contents as the _LIBADD variable.
10232         (func_emit_initmacro_start, func_emit_initmacro_end,
10233         func_emit_initmacro_done): New functions.
10234         (func_import, func_create_testdir): Invoke them. Allow the identifiers
10235         gl_LIBOBJS and gl_LTLIBOBJS.
10236
10237 2006-10-11  Bruno Haible  <bruno@clisp.org>
10238
10239         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
10240         (func_create_testdir): Don't create po/Makefile.am, don't invoke
10241         autoreconf. Instead, invoke autopoint explicitly but move back the
10242         *.m4 files from gnulib.
10243
10244 2006-10-11  Bruno Haible  <bruno@clisp.org>
10245
10246         * gnulib-tool (func_usage): Make module names after --create-testdir
10247         optional.
10248         (func_create_testdir): If no module was specified, use nearly all
10249         modules.
10250
10251 2006-10-12  Jim Meyering  <jim@meyering.net>
10252
10253         Big performance improvement for fts-based tools that use FTS_NOSTAT.
10254         Avoid spurious inode-mismatch problems on non-POSIX file systems.
10255         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
10256         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
10257         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
10258         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
10259         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
10260         (fts_set_stat_required): New function.
10261         (fts_open): Defer the calls to fts_stat, if possible or requested.
10262         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
10263         into fts_stat itself.
10264         (fts_read): Perform any required (deferred) fts_stat call.
10265         (fts_build): Likewise, for the directory we're about to open and read.
10266         In the readdir loop, carefully decide whether each entry will require
10267         an eventual call to fts_stat, using dirent.d_type info if available.
10268         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
10269         a command line argument into this function.  Update all callers.
10270         Map a return value of FTS_DOT to FTS_D for a command line argument.
10271         * modules/fts (Depends-on): Add d-type.  Alphabetize.
10272         Thanks to Miklos Szeredi for his tenacity and for the initial
10273         bug report about "find" failing on a FUSE-based file system.
10274
10275         * lib/fts.c (fts_open): Use consistent indentation.
10276
10277 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
10278
10279         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
10280         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
10281         reported by Jim Meyering.  All uses of cache variables renamed
10282         to match Autoconf's.
10283         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
10284         the other one.
10285
10286         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
10287         Fix misspelling in diagnostic.
10288
10289 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
10290
10291         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
10292         defined.  Problem reported by Matthew Woehlke.
10293
10294         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
10295         Add support for Tandem NonStop R series.
10296         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
10297         Use new macro.
10298
10299         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
10300         (has_trailing_slash): Omit size arg; all callers changed.
10301         Omit 'inline', since it doesn't help performance and we'd
10302         need to configure it.
10303         Don't count //, ///, etc. as having a trailing slash.
10304         As a side effect, this removes a C99ism reported by Matthew Woehlke.
10305         (rpl_rename_dest_slash): On failure, use rename's errno rather
10306         than (in some cases) an incorrect or junk errno.
10307         Simplify code by removing need to compute length; this does
10308         cause it to make two passes instead of one over the file name,
10309         but it's worth it.
10310
10311         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
10312         change, since Autoconf's version may no longer be appropriate now
10313         that we are using CVS Autoconf's version.  Add support for Tandem.
10314
10315 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
10316             Bruno Haible  <bruno@clisp.org>
10317
10318         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
10319         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
10320         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
10321         gl_AC_TYPE_LONG_LONG.
10322
10323         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
10324         instead of HAVE_LONG_LONG.
10325         * lib/printf-args.c (printf_fetchargs): Likewise.
10326         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
10327         * lib/vasnprintf.c (VASNPRINTF): Likewise.
10328         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
10329         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
10330         gl_AC_TYPE_LONG_LONG.
10331
10332 2006-10-11  Bruno Haible  <bruno@clisp.org>
10333
10334         * m4/longlong.m4: Add comments.
10335         * m4/ulonglong.m4: Likewise.
10336
10337 2006-10-10  Bruno Haible  <bruno@clisp.org>
10338
10339         Make it possible to #define stpcpy, strdup to aliases.
10340         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
10341         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
10342
10343 2006-10-10  Bruno Haible  <bruno@clisp.org>
10344
10345         Make it possible to #define gcd to an alias.
10346         * lib/gcd.c: Include config.h.
10347
10348 2006-10-10  Bruno Haible  <bruno@clisp.org>
10349
10350         Make it possible to #define c_isascii to an alias.
10351         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
10352         defined. Undefine the macros before defining them, to avoid gcc
10353         warnings.
10354         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
10355         define NO_C_CTYPE_MACROS early.
10356
10357 2006-10-10  Bruno Haible  <bruno@clisp.org>
10358
10359         Make it possible to #define set_program_name to an alias.
10360         * lib/progname.c: Don't undefine set_program_name; instead, undefine
10361         ENABLE_RELOCATABLE early.
10362
10363 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
10364
10365         Port to Tandem NSK OSS, which has 64-bit signed int but at most
10366         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
10367         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
10368         More generally, don't assume that 64-bit signed int is available
10369         if unsigned int is, and vice versa.
10370         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
10371         unsigned symbols, not on their signed counterparts.
10372         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
10373         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
10374         (UINT64_C, UINTMAX_C):
10375         Likewise.
10376         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
10377         unsigned counterparts.
10378         (Have_long_long, Unsigned): New macros.
10379         (Int): Renamed from INT.
10380         (strtoimax): Use the new macros.
10381         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
10382         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
10383         * modules/inttypes (inttypes.h): Substitute
10384         HAVE_UNSIGNED_LONG_LONG_INT.
10385         * modules/stdint (stdint.h): Likewise.
10386         (Files): Add m4/ulonglong.m4.
10387
10388 2006-10-10  Bruno Haible  <bruno@clisp.org>
10389
10390         Fix a gcc -Wshadow warning.
10391         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
10392         to 'bucket'.
10393         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
10394         gl_linked_indexof_from_to): Likewise.
10395         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
10396         Likewise.
10397         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
10398         Likewise.
10399         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
10400         Reported by Eric Blake.
10401
10402 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
10403
10404         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
10405         for NetBSD.  Problem reported by Bruno Haible.
10406
10407 2006-10-09  Jim Meyering  <jim@meyering.net>
10408
10409         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
10410         Patch from Bruno Haible.
10411
10412 2006-10-09  Jim Meyering  <jim@meyering.net>
10413
10414         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
10415         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
10416         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
10417
10418 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
10419
10420         Don't include <config.h> twice; this doesn't work in some cases,
10421         e.g., when config.h has "#define intmax_t long long int" and
10422         we include <config.h>, <inttypes.h>, <config.h> in that order.
10423         Problem reported by Matthew Woehlke in:
10424         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
10425         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
10426         * lib/fts-cycle.c: Don't include config.h.
10427         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
10428         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
10429         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
10430         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
10431         inttypes.h.
10432         * lib/xstrtoumax.c: Likewise.
10433         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
10434         __strtol and the like, so that this module is more like its siblings.
10435         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
10436         Remove; no longer needed now that we assume gnulib inttypes.h.
10437
10438 2006-10-08  Bruno Haible  <bruno@clisp.org>
10439
10440         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
10441         option.
10442
10443 2006-10-07  Jim Meyering  <jim@meyering.net>
10444
10445         * modules/inttypes (inttypes.h): Revert what seems to have been
10446         an inadvertent part of today's change: use "|", not "/" in the
10447         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
10448
10449 2006-10-07  Bruno Haible  <bruno@clisp.org>
10450
10451         * modules/sublist: New file.
10452
10453 2006-10-07  Bruno Haible  <bruno@clisp.org>
10454
10455         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
10456         * modules/argz (argz.h): Likewise.
10457         * modules/arpa_inet (arpa/inet.h): Likewise.
10458         * modules/byteswap (byteswap.h): Likewise.
10459         * modules/configmake (configmake.h): Likewise.
10460         * modules/fcntl (fcntl.h): Likewise.
10461         * modules/fnmatch (fnmatch.h): Likewise.
10462         * modules/getopt (getopt.h): Likewise.
10463         * modules/glob (glob.h): Likewise.
10464         * modules/inttypes (inttypes.h): Likewise.
10465         * modules/netinet_in (netinet/in.h): Likewise.
10466         * modules/poll (poll.h): Likewise.
10467         * modules/stdbool (stdbool.h): Likewise.
10468         * modules/stdint (stdint.h): Likewise.
10469         * modules/sys_select (sys/select.h): Likewise.
10470         * modules/sys_socket (sys/socket.h): Likewise.
10471         * modules/sys_stat (sys/stat.h): Likewise.
10472         * modules/sysexits (sysexits.h): Likewise.
10473         * modules/unistd (unistd.h): Likewise.
10474         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
10475         Add a "DO NOT EDIT" comment to the generated file.
10476         (func_import): Likewise for gnulib-comp.m4.
10477
10478 2006-10-07  Bruno Haible  <bruno@clisp.org>
10479
10480         * lib/gl_sublist.h: New file.
10481         * lib/gl_sublist.c: New file.
10482
10483 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
10484
10485         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
10486         name (relative to the original working directory) and the file
10487         name component (relative to the temporary working directory).  All
10488         callers changed.
10489         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
10490         * lib/mkdir-p.c (make_dir_parents): Likewise.
10491         * lib/mkdir-p.h (make_dir_parents): Likewise.
10492
10493 2006-10-06  Eric Blake  <ebb9@byu.net>
10494
10495         Define several macros for use by the clean-temp module.
10496         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
10497         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
10498         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
10499
10500         * lib/clean-temp.h (close_stream_temp): New declaration.
10501         * lib/clean-temp.c (includes): Pull in headers according to what
10502         other modules are in use.
10503         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
10504
10505 2006-10-06  Bruno Haible  <bruno@clisp.org>
10506
10507         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
10508         instead of fopen, fwriteerror.
10509
10510 2006-10-06  Bruno Haible  <bruno@clisp.org>
10511
10512         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
10513         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
10514         int.
10515         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
10516         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
10517         Return an error indicator.
10518         Suggested by Eric Blake.
10519
10520 2006-10-06  Bruno Haible  <bruno@clisp.org>
10521
10522         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
10523         Reported by Eric Blake.
10524
10525 2006-10-06  Bruno Haible  <bruno@clisp.org>
10526
10527         * modules/closeout (Description): Mention stderr too.
10528
10529 2006-10-06  Bruno Haible  <bruno@clisp.org>
10530         and Paul Eggert  <eggert@cs.ucla.edu>
10531
10532         * lib/closeout.c (close_stdout): Also close stderr.
10533         * lib/closeout.h: Update comment.
10534
10535 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
10536
10537         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
10538         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
10539         * lib/dirchownmod.c: Include lchown.h.
10540         * lib/lchown.c: Don't include files that lchown.h now includes.
10541         Don't declare chown, since lchown.h now does that.
10542         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
10543         (lchown): Define to rpl_chown if lchown is declared but
10544         does not exist.  Declare using a prototype if lchown is not
10545         declared.  Add a copyright notice.
10546         * lib/mkstemp.h: Include <unistd.h>.
10547         * lib/openat.c: Include lchown.h.
10548
10549         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
10550         we now test for that separately.
10551         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
10552         rather than O_NOFOLLOW, when testing whether it's possible to
10553         avoid a race condition reliably.
10554         * lib/savewd.c (savewd_chdir): Likewise.
10555
10556         Remove macros that are no longer needed now that stdint.h is
10557         reliable.
10558         * lib/fsusage.c (UINTMAX_MAX): Remove.
10559         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
10560         * lib/utimecmp.c (SIZE_MAX): Remove.
10561
10562         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
10563
10564         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
10565         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
10566         O_NOATIME works.
10567
10568 2006-10-05  Bruno Haible  <bruno@clisp.org>
10569
10570         * lib/gl_list.h (gl_sortedlist_search_from_to,
10571         gl_sortedlist_indexof_from_to): New declarations.
10572         (gl_list_implementation): New fields sortedlist_search_from_to,
10573         sortedlist_indexof_from_to.
10574         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
10575         inline functions.
10576         * lib/gl_list.c (gl_sortedlist_search_from_to,
10577         gl_sortedlist_indexof_from_to): New functions.
10578         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
10579         function.
10580         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
10581         (gl_array_sortedlist_search_from_to): New function.
10582         (gl_array_list_implementation): Update.
10583         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
10584         function.
10585         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
10586         (gl_carray_sortedlist_search_from_to): New function.
10587         (gl_carray_list_implementation): Update.
10588         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
10589         gl_linked_sortedlist_indexof_from_to): New functions.
10590         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
10591         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
10592         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
10593         gl_tree_sortedlist_indexof_from_to): New functions.
10594         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
10595         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
10596         Update.
10597         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
10598         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
10599         Update.
10600
10601 2006-10-05  Bruno Haible  <bruno@clisp.org>
10602
10603         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
10604         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
10605         (struct gl_list_implementation): Add fields search_from_to,
10606         indexof_from_to. Remove fields search, indexof.
10607         (gl_list_search): Use the search_from_to method.
10608         (gl_list_search_from, gl_list_search_from_to): New functions.
10609         (gl_list_indexof): Use the indexof_from_to method.
10610         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
10611         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
10612         (gl_list_search_from, gl_list_search_from_to): New functions.
10613         (gl_list_indexof): Use the indexof_from_to method.
10614         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
10615         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
10616         gl_array_indexof. Add start_index, end_index arguments.
10617         (gl_array_search_from_to): Renamed from gl_array_search. Add
10618         start_index, end_index arguments.
10619         (gl_array_remove, gl_array_list_implementation): Update.
10620         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
10621         gl_carray_indexof. Add start_index, end_index arguments.
10622         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
10623         start_index, end_index arguments.
10624         (gl_carray_remove, gl_carray_list_implementation): Update.
10625         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
10626         gl_linked_search. Add start_index, end_index arguments.
10627         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
10628         start_index, end_index arguments.
10629         (gl_linked_remove): Update.
10630         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
10631         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
10632         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
10633         field to 'size_t'.
10634         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
10635         gl_tree_search. Add start_index, end_index arguments.
10636         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
10637         start_index, end_index arguments.
10638         (gl_tree_remove): Update.
10639         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
10640         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
10641         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
10642         function.
10643         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
10644         gl_tree_search. Add start_index, end_index arguments.
10645         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
10646         start_index, end_index arguments.
10647         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
10648         Update.
10649         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
10650
10651 2006-10-05  Bruno Haible  <bruno@clisp.org>
10652
10653         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
10654
10655         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
10656         fwriteerror_temp): New declarations.
10657         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
10658         (descriptors): New variable.
10659         (cleanup): First, close the descriptors.
10660         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
10661         fclose_temp, fwriteerror_temp): New functions.
10662
10663 2006-10-04  Jim Meyering  <jim@meyering.net>
10664
10665         * lib/fts.c (fts_open): Tiny comment change.
10666
10667 2006-10-04  Bruno Haible  <bruno@clisp.org>
10668
10669         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
10670         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
10671         gl_LOCK_BODY.
10672         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
10673         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
10674         gl_LOCK_EARLY_BODY.
10675         (gl_LOCK): Require gl_LOCK_BODY.
10676
10677 2006-10-04  Bruno Haible  <bruno@clisp.org>
10678
10679         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
10680         (gl_oset_search_atleast): New declaration.
10681         (struct gl_oset_implementation): Add field 'search_atleast'.
10682         (gl_oset_search_atleast): New inline function.
10683         * lib/gl_oset.c (gl_oset_search_atleast): New function.
10684         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
10685         (gl_array_oset_implementation): Update.
10686         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
10687         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
10688         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
10689
10690 2006-10-04  Bruno Haible  <bruno@clisp.org>
10691
10692         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
10693
10694 2006-10-03  Bruno Haible  <bruno@clisp.org>
10695
10696         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
10697         from gl_avltreehash_list_implementation.
10698
10699 2006-10-03  Bruno Haible  <bruno@clisp.org>
10700
10701         * lib/gl_oset.c (gl_oset_add): Fix return type.
10702
10703 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
10704
10705         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
10706
10707 2006-10-02  Eric Blake  <ebb9@byu.net>
10708
10709         * modules/strnlen (Depends-on): Add extensions.
10710
10711 2006-10-02  Eric Blake  <ebb9@byu.net>
10712
10713         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
10714         definition in 2.60+.
10715
10716 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
10717
10718         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
10719         checks.
10720
10721 2006-10-02  Bruno Haible  <bruno@clisp.org>
10722
10723         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
10724         to the AUTOMAKE_OPTIONS.
10725         Reported by Jim Meyering.
10726
10727 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
10728
10729         Work around bug in Solaris 10 /proc file system:
10730         /proc/self/fd/NNN/.. isn't the parent directory of
10731         the directory whose file descriptor is NNN.  This needs to
10732         be worked around at run time, not compile time, since a
10733         program might be built on Solaris 8, where things work, and
10734         run on Solaris 10.
10735         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
10736         to use the following interface instead:
10737         (OPENAT_BUFFER_SIZE): New macro.
10738         (openat_proc_name): New function.
10739         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
10740         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
10741         Likewise.
10742         * lib/openat-proc.c: New file.
10743         * modules/openat (Files): Add lib/openat-proc.c.
10744         (Depends-on): Add same-inode, stdbool.
10745         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
10746
10747 2006-09-29  Bruno Haible  <bruno@clisp.org>
10748
10749         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
10750         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
10751         argument. Set stdout_closed before testing for ferror, not after.
10752         (fwriteerror, fwriteerror_no_ebadf): New functions.
10753
10754 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10755
10756         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
10757
10758 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
10759
10760         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
10761         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
10762
10763 2006-09-28  Jim Meyering  <jim@meyering.net>
10764
10765         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
10766         Include <unistd.h>.
10767
10768 2006-09-28  Bruno Haible  <bruno@clisp.org>
10769
10770         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
10771         * modules/linkedhash-list (Depends-on): Likewise.
10772         * modules/rbtreehash-list (Depends-on): Likewise.
10773
10774 2006-09-28  Bruno Haible  <bruno@clisp.org>
10775
10776         * lib/strndup.h: Simplify the redefinition of strndup.
10777         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
10778         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
10779
10780 2006-09-28  Bruno Haible  <bruno@clisp.org>
10781
10782         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
10783         * lib/gl_linkedhash_list.c: Likewise.
10784         * lib/gl_rbtreehash_list.c: Likewise.
10785
10786 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
10787
10788         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
10789         getaddrinfo.
10790
10791         * lib/__fpending.h: Don't include <stdio_ext.h> unless
10792         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
10793         it causes <stdio_ext.h> to cause a compile-time error.
10794         Problem reported by Nelson H. F. Beebe.
10795         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
10796         of HAVE_DECL___PENDING.
10797
10798         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
10799         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
10800         declaration.
10801
10802 2006-09-27  Jim Meyering  <jim@meyering.net>
10803
10804         This file could end up with a definition for a function
10805         named __strndup, rather than rpl_strndup on a system with
10806         incomplete weak_alias support.
10807         * lib/strndup.c (strndup): Rename from __strndup.
10808         Remove #defines that used to map __strndup to strndup.
10809         Don't use K&R prototypes.
10810         Remove LIBC-related code, since this file is not sync'd with glibc.
10811         * lib/strndup.h: Revamp, accordingly.
10812         * m4/strndup.m4: Modernize.
10813
10814 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
10815
10816         * modules/savewd (Depends-on): Add 'raise'.
10817         * lib/savewd.c: Include <signal.h>, for 'raise'.
10818
10819 2006-09-26  Jim Meyering  <jim@meyering.net>
10820
10821         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
10822         when we detect Darwin 8.7.0's acl_get_file bug.
10823         Rearrange to perform the new (below) run-test while $LIBS
10824         contains any acl-related library.  Set USE_ACL at the end.
10825         (gl_ACL_GET_FILE): New function.
10826
10827 2006-09-26  Eric Blake  <ebb9@byu.net>
10828
10829         * lib/verror.c: Include <config.h> unconditionally.
10830
10831 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
10832
10833         * modules/clock-time (Maintainer): Add self.
10834         * modules/getlogin_r (Depends-on): Add extensions.
10835
10836 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10837
10838         * modules/clock-time: New module.
10839         * modules/nanosleep (Depends-on): Add clock-time.
10840         * modules/gethrxtime (Depends-on): Likewise.
10841         * modules/gettime (Depends-on): Likewise.
10842         * modules/settime (Depends-on): Likewise.
10843
10844         * modules/fts-lgpl: Depend on openat.
10845         * modules/mkancesdirs: Depend on savewd.
10846         * modules/mkdir-p: Likewise.
10847
10848 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10849
10850         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
10851
10852         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
10853         `gl_have_arbitrary_file_name_length_limit' to
10854         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
10855         actually works between configure runs.
10856
10857 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10858             Bruno Haible  <bruno@clisp.org>
10859
10860         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
10861
10862 2006-09-25  Jim Meyering  <jim@meyering.net>
10863
10864         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
10865         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
10866
10867 2006-09-25  Eric Blake  <ebb9@byu.net>
10868
10869         * gnulib-tool (func_import, func_create_testdir): Fix typos in
10870         exec's in 2006-09-18 patch when shuffling fds.
10871
10872 2006-09-25  Bruno Haible  <bruno@clisp.org>
10873
10874         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
10875         Reported by Jim Meyering.
10876
10877 2006-09-24  Jim Meyering  <jim@meyering.net>
10878
10879         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
10880         compare a pointer against a literal "0".  That caused failures with
10881         at least HP-UX's hpcc.
10882
10883 2006-09-22  Simon Josefsson  <jas@extundo.com>
10884
10885         * modules/gc-sha1:
10886         * modules/gc-md4:
10887         * modules/gc-hmac-sha1:
10888         * modules/gc-hmac-md5:
10889         * modules/gc-des:
10890         * modules/gc-arcfour: Distribute more files.
10891
10892 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10893
10894         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
10895         (gl_linked_iterator_from_to): Initialize struct completely.
10896         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
10897         (gl_tree_iterator_from_to): Likewise
10898         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
10899         * lib/gl_array_list.c [lint] (gl_array_iterator)
10900         (gl_array_iterator_from_to): Likewise.
10901         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
10902         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
10903         (gl_carray_iterator_from_to): Likewise.
10904
10905         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
10906         * lib/md4.c (md4_process_block): Remove unused variable.
10907         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
10908         parentheses for clarity.
10909
10910 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10911
10912         * modules/bison-i18n (Depends-on): Add gettext.
10913
10914 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10915
10916         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
10917         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
10918         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
10919         also add missing comma that caused broken test.
10920         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
10921         stdlib.h, for `abort'.
10922         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
10923         variables.
10924         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
10925         include unistd.h if present, for `rmdir'.
10926         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
10927         variables.
10928         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
10929         in the process include standard headers for prototypes.
10930         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
10931         gets declared on GNU/Linux.
10932         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
10933         unistd.h, for `rmdir'.
10934         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
10935
10936         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
10937         always true.
10938         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
10939
10940         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
10941
10942 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10943
10944         * gnulib-tool (func_version): Create output all at once.  This
10945         may help avoid triggering unnecessary SIGPIPEs, and at any
10946         rate it doesn't hurt.
10947
10948 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10949             Bruno Haible  <bruno@clisp.org>
10950
10951         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
10952         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
10953         * m4/signed.m4 (bh_C_SIGNED): Likewise.
10954
10955         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
10956         (gl_FUNC_VASPRINTF): Invoke it.
10957
10958 2006-09-22  Bruno Haible  <bruno@clisp.org>
10959
10960         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
10961         getloadavg.c as first argument.
10962
10963 2006-09-22  Bruno Haible  <bruno@clisp.org>
10964
10965         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
10966         at the beginning of the gl_INIT macro.
10967         * modules/getloadavg (configure.ac): Pass $gl_source_base to
10968         gl_GETLOADAVG.
10969
10970 2006-09-22  Bruno Haible  <bruno@clisp.org>
10971
10972         * gnulib-tool (func_create_megatestdir): Don't include the config-h
10973         module.
10974         Suggested by Ralf Wildenhues.
10975
10976 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
10977
10978         Import this patch from libc:
10979
10980         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
10981
10982         * lib/regex_internal.c (re_string_reconstruct): Handle
10983         offset < pstr->valid_raw_len && pstr->offsets_needed case.
10984         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
10985         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
10986         re_string_context_at.
10987
10988         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
10989         now requires it.
10990         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
10991         gl_REGEX now does it for us.
10992         (gl_REGEX): Add test taken from
10993         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
10994
10995         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
10996         Check that large offsets work.  Modernize Autoconf usages.
10997         Prefer "yes" to mean a good thing rather than a bad.
10998         Don't put "#define mkstemp" in config.h, as this might interfere
10999         with standard system headers that "#define mkstemp mkstemp64".
11000
11001         * modules/mkstemp (Depends-on): Add extensions, so that
11002         mkstemp is visible on some platforms.
11003         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
11004         (Include): Change to "mkstemp.h" from <stdlib.h>.
11005         (Files): Add mkstemp.h.
11006
11007         * lib/mkstemp.h: New file, since some standard headers
11008         #define mkstemp.
11009         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
11010         Include "mkstemp.h".
11011         Make the _LIBC code resemble glibc original more,
11012         e.g., use K&R style.
11013         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
11014         (mkstemp): Remove, since mkstemp.h does this for us.
11015         * lib/stdlib--.h: Include mkstemp.h.
11016
11017         Import this patch from libc:
11018
11019         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
11020
11021         * lib/tempname.c (__gen_tempname): Change attempts_min
11022         into a macro.  Use preprocessor to decide how to initialize
11023         attempts [Coverity CID 67].
11024
11025 2006-09-20  Bruno Haible  <bruno@clisp.org>
11026
11027         * lib/mkdtemp.c: Import from libc.
11028         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
11029                 * sysdeps/posix/tempname.c (__gen_tempname): Change
11030                 attempts_min into a macro.  Use preprocessor to decide how to
11031                 initialize attempts [Coverity CID 67].
11032         2001-11-27  Paul Eggert  <eggert@twinsun.com>
11033                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
11034                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
11035
11036 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11037
11038         * gnulib-tool (func_exit): New function, to allow to pass the
11039         exit status portably through the trap.  Use everywhere.
11040         (--help, --version): Signal a write error.
11041         (trap): catch SIGPIPE, for write errors.
11042         Exit at the end of the trap, with the correct exit status.
11043
11044 2006-09-19  Karl Berry  <karl@gnu.org>
11045
11046         * doc/gnulib.texi: note about the license texinfo files.
11047
11048 2006-09-19  Eric Blake  <ebb9@byu.net>
11049
11050         * gnulib-tool: Avoid space-tab.
11051
11052 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
11053
11054         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
11055         that prevented coreutils 6.1 from building.  Problem reported
11056         by Petter Reinholdtsen.
11057
11058 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
11059
11060         * gnulib-tool (avoidlist): Fix typo that broke options like
11061         --avoid=lock that are used by coreutils bootstrap.
11062
11063 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
11064
11065         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
11066         more systematically.
11067
11068 2006-09-18  Jim Meyering  <jim@meyering.net>
11069
11070         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
11071
11072 2006-09-18  Bruno Haible  <bruno@clisp.org>
11073
11074         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
11075
11076 2006-09-18  Bruno Haible  <bruno@clisp.org>
11077
11078         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
11079         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
11080         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
11081         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
11082         * m4/gettext.m4: Require autoconf >= 2.52.
11083         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
11084         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
11085         of gl_cv_header_inttypes_h.
11086
11087 2006-09-18  Bruno Haible  <bruno@clisp.org>
11088
11089         * lib/javaversion.c: Include configmake.h.
11090
11091 2006-09-18  Bruno Haible  <bruno@clisp.org>
11092
11093         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
11094         avoid that the while loops be executed in a subshell.
11095
11096 2006-09-18  Bruno Haible  <bruno@clisp.org>
11097
11098         * MODULES.html.sh (func_module): Break long lines.
11099         Suggested by Bruce Korb <bkorb@gnu.org>.
11100
11101 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11102
11103         Speed up by a factor of 1.12.
11104         * gnulib-tool (nl): New variable.
11105         (func_import): Rewrite include directive extraction to only read each
11106         directive once.
11107
11108 2006-09-17  Bruno Haible  <bruno@clisp.org>
11109
11110         * modules/javaversion (Makefile.am): Remove DEFS setting.
11111         (Depends-on): Add configmake, for PKGDATADIR definition.
11112
11113 2006-09-17  Bruno Haible  <bruno@clisp.org>
11114
11115         * gnulib-tool (func_create_testdir): Rewrite all files at once.
11116
11117 2006-09-17  Bruno Haible  <bruno@clisp.org>
11118
11119         * gnulib-tool (func_append): New function, stolen from libtool.m4.
11120         (func_modules_transitive_closure, func_modules_add_dummy,
11121         func_modules_to_filelist, func_import, func_create_testdir,
11122         func_create_megatestdir, ...): Use it wherever possible.
11123         Suggested by Ralf Wildenhues.
11124
11125 2006-09-16  Karl Berry  <karl@gnu.org>
11126
11127         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
11128         to avoid sectioning errors.
11129         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
11130         [ifinfo]: blank line after @center-ed titles.
11131         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
11132         Spell FSF address consistently with others.
11133         (These changes approved by rms.)
11134
11135 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11136
11137         Speed up by a factor of 1.61.
11138         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
11139         already checked module names again.
11140
11141 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11142
11143         Speed up by a factor of 1.13.
11144         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
11145         for new_files, and the input to func_add_or_update.
11146
11147 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11148
11149         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
11150         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
11151
11152 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
11153
11154         * modules/mkancesdirs (Depends-on): Add fcntl.
11155         * modules/savewd: New file.
11156         * MODULES.html.sh (File system functions): Add savewd.
11157
11158         * modules/configmake (Makefile.am): Add support for the
11159         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
11160
11161 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
11162
11163         * m4/savewd.m4: New file.
11164
11165 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
11166
11167         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
11168         (dirchownmod): New arg FD.  All callers changed.
11169         Use FD rather than opening the directory ourself, as opening is
11170         now the caller's responsibility.
11171         * lib/dirchownmod.h: Likewise.
11172         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
11173         hosts that require <sys/types.h> before <sys/stat.h>.  Include
11174         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
11175         (test_dir): Remove.
11176         (mkancesdirs): Return length of prefix of FILE that has already
11177         been made, or -2 if there is a child doing the work.  Redo
11178         algorithm so that it is O(N) rather than O(N**2).  Optimize away
11179         ".", and treat ".." specially since it might stray back into
11180         already-created areas.  Use a subprocess if necessary.  New arg
11181         WD; all users changed.  MAKE_DIR function should now return 1
11182         if it creates a directory that is not readable.  Return -2 if
11183         a child process is spun off.
11184         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
11185         Adjust signature to match code.
11186         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
11187         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
11188         all users changed.
11189         * lib/savewd.c, lib/savewd.h: New files.
11190
11191 2006-09-15  Jim Meyering  <jim@meyering.net>
11192
11193         * modules/rename-dest-slash: New module.
11194         * MODULES.html.sh (posix_compat): Add it here.
11195
11196         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
11197
11198 2006-09-15  Jim Meyering  <jim@meyering.net>
11199
11200         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
11201         file.
11202
11203         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
11204
11205 2006-09-15  Jim Meyering  <jim@meyering.net>
11206
11207         * lib/rename-dest-slash.c (has_trailing_slash): Use
11208         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
11209         (rpl_rename_dest_slash): Perform the cheaper trailing slash
11210         test before testing whether SRC is a directory.
11211         Suggestions from Bruno Haible.
11212
11213         Avoid a warning about an unused variable.
11214         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
11215         into the #ifdef block where it's used.
11216
11217         * lib/rename-dest-slash.c: New file.
11218
11219 2006-09-14  Bruno Haible  <bruno@clisp.org>
11220
11221         * lib/allocsa.c: Include <config.h> unconditionally.
11222         * lib/asnprintf.c: Likewise.
11223         * lib/asprintf.c: Likewise.
11224         * lib/c-strcasecmp.c: Likewise.
11225         * lib/c-strcasestr.c: Likewise.
11226         * lib/c-strncasecmp.c: Likewise.
11227         * lib/c-strstr.c: Likewise.
11228         * lib/classpath.c: Likewise.
11229         * lib/clean-temp.c: Likewise.
11230         * lib/concatpath.c: Likewise.
11231         * lib/copy-file.c: Likewise.
11232         * lib/csharpcomp.c: Likewise.
11233         * lib/csharpexec.c: Likewise.
11234         * lib/execute.c: Likewise.
11235         * lib/fatal-signal.c: Likewise.
11236         * lib/findprog.c: Likewise.
11237         * lib/fwriteerror.c: Likewise.
11238         * lib/gl_array_list.c: Likewise.
11239         * lib/gl_array_oset.c: Likewise.
11240         * lib/gl_avltree_list.c: Likewise.
11241         * lib/gl_avltree_oset.c: Likewise.
11242         * lib/gl_avltreehash_list.c: Likewise.
11243         * lib/gl_carray_list.c: Likewise.
11244         * lib/gl_linked_list.c: Likewise.
11245         * lib/gl_linkedhash_list.c: Likewise.
11246         * lib/gl_list.c: Likewise.
11247         * lib/gl_oset.c: Likewise.
11248         * lib/gl_rbtree_list.c: Likewise.
11249         * lib/gl_rbtree_oset.c: Likewise.
11250         * lib/gl_rbtreehash_list.c: Likewise.
11251         * lib/imaxabs.c: Likewise.
11252         * lib/imaxdiv.c: Likewise.
11253         * lib/javacomp.c: Likewise.
11254         * lib/javaexec.c: Likewise.
11255         * lib/javaversion.c: Likewise.
11256         * lib/linebreak.c: Likewise.
11257         * lib/localcharset.c: Likewise.
11258         * lib/lock.c: Likewise.
11259         * lib/mbchar.c: Likewise.
11260         * lib/mbswidth.c: Likewise.
11261         * lib/mkdtemp.c: Likewise.
11262         * lib/pipe.c: Likewise.
11263         * lib/printf-args.c: Likewise.
11264         * lib/printf-parse.c: Likewise.
11265         * lib/progname.c: Likewise.
11266         * lib/progreloc.c: Likewise.
11267         * lib/readlink.c: Likewise.
11268         * lib/sh-quote.c: Likewise.
11269         * lib/stpcpy.c: Likewise.
11270         * lib/stpncpy.c: Likewise.
11271         * lib/strcasecmp.c: Likewise.
11272         * lib/strcasestr.c: Likewise.
11273         * lib/strcspn.c: Likewise.
11274         * lib/striconv.c: Likewise.
11275         * lib/strncasecmp.c: Likewise.
11276         * lib/strnlen1.c: Likewise.
11277         * lib/strstr.c: Likewise.
11278         * lib/strtok_r.c: Likewise.
11279         * lib/tls.c: Likewise.
11280         * lib/tmpdir.c: Likewise.
11281         * lib/unicodeio.c: Likewise.
11282         * lib/unsetenv.c: Likewise.
11283         * lib/vasnprintf.c: Likewise.
11284         * lib/vasprintf.c: Likewise.
11285         * lib/wait-process.c: Likewise.
11286         * lib/xallocsa.c: Likewise.
11287         * lib/xsetenv.c: Likewise.
11288         * lib/xstriconv.c: Likewise.
11289
11290 2006-09-13  Simon Josefsson  <jas@extundo.com>
11291
11292         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
11293         that internally, suggested by Ralf Wildenhues
11294         <Ralf.Wildenhues@gmx.de>.
11295
11296 2006-09-13  Simon Josefsson  <jas@extundo.com>
11297
11298         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
11299         @LIBOBJS@.
11300         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
11301
11302 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
11303
11304         * lib/_fpending.c: Include <config.h> unconditionally, since we no
11305         longer worry about uses that don't define HAVE_CONFIG_H.
11306         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
11307         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
11308         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
11309         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
11310         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
11311         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
11312         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
11313         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
11314         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
11315         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
11316         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
11317         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
11318         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
11319         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
11320         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
11321         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
11322         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
11323         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
11324         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
11325         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
11326         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
11327         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
11328         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
11329         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
11330         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
11331         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
11332         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
11333         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
11334         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
11335         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
11336         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
11337         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
11338         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
11339         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
11340         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
11341         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
11342         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
11343         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
11344         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
11345         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
11346         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
11347         Likewise.
11348
11349 2006-09-13  Eric Blake  <ebb9@byu.net>
11350
11351         * lib/getopt.c: Fix typo in last commit.
11352
11353 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
11354
11355         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
11356         dgettext.
11357
11358 2006-09-12  Jim Meyering  <jim@meyering.net>
11359
11360         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
11361         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
11362         Reported by Nelson H. F. Beebe.
11363
11364 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
11365
11366         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
11367         program_invocation_name and program_invocation_short_name are
11368         initialized.
11369         * lib/argp-namefrob.h: Move declarations of program_invocation_name
11370         and program_invocation_short_name to argp.h, so they are visible
11371         to user programs.
11372         * lib/argp.h: Likewise
11373
11374 2006-09-10  Bruno Haible  <bruno@clisp.org>
11375
11376         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
11377         m4/inttypes_h.m4, m4/uintmax_t.m4.
11378
11379 2006-09-10  Bruno Haible  <bruno@clisp.org>
11380
11381         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
11382         gl_AC_TYPE_UINTMAX_T.
11383
11384 2006-09-10  Bruno Haible  <bruno@clisp.org>
11385
11386         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
11387
11388 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
11389
11390         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
11391         convention.  Text proposed by Bruno Haible.
11392         (struct argp_option): Document the use of N_() wrappers.
11393
11394         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
11395         '\v', and translate the two parts separately, instead of feeding
11396         the whole string to gettext.  This allows to exclude
11397         '\v' from the strings visible to the translator by writing doc
11398         strings as N_("..") "\v" N_("..").
11399
11400 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
11401
11402         * config/srclist.txt: Undo latest change; the bug was fixed.
11403
11404 2006-09-09  Bruno Haible  <bruno@clisp.org>
11405
11406         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
11407         assignments if building a library without libtool.
11408         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
11409         in func_emit_lib_Makefile_am.
11410         (func_import): When building a static library libfoo.a, arrange to
11411         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
11412         (func_create_testdir): Likewise.
11413         * modules/gc (configure.ac, Makefile.am): If building statically,
11414         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
11415         * modules/iconvme (configure.ac, Makefile.am): Likewise.
11416         * modules/striconv (configure.ac, Makefile.am): Likewise.
11417         Based on a suggestion by Ralf Wildenhues.
11418
11419 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11420
11421         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
11422         Check for unistd.h too, since Autoconf doesn't assume POSIX.
11423         Also:
11424
11425         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11426         Add year_2050_test to catch glibc bug 2821
11427         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
11428
11429         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
11430         Prefer #ifdef to #if.
11431
11432         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
11433         Return from 'main' instead of calling 'exit'.
11434
11435 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11436
11437         * lib/mktime.c (guess_time_tm): Fix bug where mktime
11438         returned the maximum time_t value rather than (time_t) -1.
11439         Problem originally reported by William Bardwell
11440         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
11441
11442         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
11443         Moved to here ...
11444         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
11445         ... from here.
11446
11447 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
11448
11449         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
11450         2821 is fixed.
11451
11452 2006-09-08  Jim Meyering  <jim@meyering.net>
11453
11454         Don't make generated files read-only.  That would bother too many
11455         people.  However, do retain the ability to work when targets are
11456         read-only: remove the destination and temporary files before writing
11457         them (when generated via sed or echo), or by using the -f option for
11458         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
11459         * modules/alloca-opt, modules/argz, modules/arpa_inet:
11460         * modules/byteswap, modules/configmake, modules/fcntl:
11461         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
11462         * modules/localcharset, modules/netinet_in, modules/poll:
11463         * modules/stdbool, modules/stdint, modules/sys_select:
11464         * modules/sys_socket, modules/sys_stat, modules/sysexits:
11465
11466 2006-09-08  Jim Meyering  <jim@meyering.net>
11467
11468         Avoid new build failure on FreeBSD 6.0.
11469         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
11470         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
11471         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
11472
11473 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11474
11475         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
11476
11477 2006-09-07  Jim Meyering  <jim@meyering.net>
11478
11479         Fix global typo in last change: use chmod u-w, not chmod u-x.
11480         Spotted by Paul Eggert and Bruce Korb.
11481         * modules/alloca-opt, modules/argz, modules/arpa_inet:
11482         * modules/byteswap, modules/configmake, modules/fcntl:
11483         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
11484         * modules/localcharset, modules/netinet_in, modules/poll:
11485         * modules/stdbool, modules/stdint, modules/sys_select:
11486         * modules/sys_socket, modules/sys_stat, modules/sysexits:
11487
11488 2006-09-06  Jim Meyering  <jim@meyering.net>
11489
11490         Make generated files be read-only.
11491         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
11492         Ensure that each generated file is now read-only.
11493         * modules/argz: Likewise.
11494         * modules/arpa_inet: Likewise.
11495         * modules/byteswap: Likewise.
11496         * modules/configmake: Likewise.
11497         * modules/fcntl: Likewise.
11498         * modules/fnmatch: Likewise.
11499         * modules/getopt: Likewise.
11500         * modules/glob: Likewise.
11501         * modules/inttypes: Likewise.
11502         * modules/netinet_in: Likewise.
11503         * modules/poll: Likewise.
11504         * modules/stdbool: Likewise.
11505         * modules/stdint: Likewise.
11506         * modules/sys_select: Likewise.
11507         * modules/sys_socket: Likewise.
11508         * modules/sys_stat: Likewise.
11509         * modules/sysexits: Likewise.
11510         * modules/localcharset: Same as above, but continue using temporary
11511         file named "t-$@" (why different?) rather than the "$@-t" used
11512         everywhere else.
11513
11514         * modules/sysexits (Makefile.am): Replace literal occurrences
11515         of "sysexit.h" more readable, and more consistent, "$@".
11516
11517 2006-09-06  Bruno Haible  <bruno@clisp.org>
11518
11519         * modules/striconv: New file.
11520         * modules/xstriconv: New file.
11521         * MODULES.html.sh (Internationalization functions): Add striconv,
11522         xstriconv.
11523
11524 2006-09-06  Bruno Haible  <bruno@clisp.org>
11525
11526         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
11527         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
11528         not using libtool correctly.
11529
11530 2006-09-06  Bruno Haible  <bruno@clisp.org>
11531
11532         * lib/striconv.h: New file.
11533         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
11534         iconvstring.c.
11535         * lib/xstriconv.h: New file.
11536         * lib/xstriconv.c: New file.
11537
11538 2006-09-06  Bruno Haible  <bruno@clisp.org>
11539
11540         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
11541         lib_..._LDFLAGS.
11542
11543 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11544
11545         * lib/argz_.h: Sync from Libtool.
11546
11547         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
11548                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
11549
11550         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
11551
11552 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
11553
11554         * modules/trim: New file.
11555
11556 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
11557
11558         * lib/trim.h: New file.
11559         * lib/trim.c: New file.
11560
11561 2006-09-05  Bruno Haible  <bruno@clisp.org>
11562
11563         * MODULES.html.sh (String handling): Add trim.
11564
11565 2006-09-04  Karl Berry  <karl@gnu.org>
11566
11567         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
11568         until next release.
11569
11570 2006-09-03  Bruno Haible  <bruno@clisp.org>
11571
11572         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
11573         correctly.
11574
11575 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11576
11577         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
11578         not gl_GETLOADAVG.  Omit unneeded semicolons.
11579         Problems reported by Ralf Wildenhues in
11580         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
11581         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
11582         at the end, which is the usual gnulib style.
11583
11584         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
11585         of doing all the work ourselves.
11586         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
11587         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
11588
11589 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11590
11591         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
11592         Problem reported by Ralf Wildenhues in
11593         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
11594
11595         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
11596         HAVE_STRUCT_STATFS_F_FSTYPENAME.
11597
11598 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
11599
11600         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
11601         yesterday's patch by changing test -n to test -z.
11602
11603 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11604
11605         * modules/getloadavg (Files): Add m4/getloadavg.m4.
11606         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
11607         the former is now obsolescent.
11608
11609         * modules/chdir-long (Depends-on): Add fcntl.
11610
11611 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11612
11613         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
11614         obsolescent, and programs should use gnulib instead.
11615         * m4/getloadavg.m4: New file, with contents taken from Autoconf
11616         but with prefixes changed.
11617
11618 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
11619
11620         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
11621         or stdbool.h, because they might not exist while configuring.
11622
11623         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
11624         Don't include unistd.h or limits.h; not needed, since chdir-long.h
11625         does that for us.
11626         (O_DIRECTORY): Remove.
11627
11628 2006-08-31  Eric Blake  <ebb9@byu.net>
11629
11630         * gnulib-tool: Don't let emacs change spaces to TAB.
11631
11632 2006-08-31  Bruno Haible  <bruno@clisp.org>
11633
11634         * gnulib-tool: When calling func_import more than once, do it in a
11635         subshell.
11636         Reported by Eric Blake <ebb9@byu.net>.
11637
11638 2006-08-31  Bruno Haible  <bruno@clisp.org>
11639
11640         * gnulib-tool (nl): Remove variable.
11641         (sed_transform_lib_file): Use more robust test for config-h module.
11642         (func_import): Fix typo in 2006-08-25 patch.
11643
11644 2006-08-31  Bruno Haible  <bruno@clisp.org>
11645
11646         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
11647         specified, augment Makefile.am variables instead of assigning them.
11648
11649 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11650
11651         Work around a bug in both the Linux and SunOS 64-bit kernels:
11652         nanosleep mishandles sleeps for longer than 2**31 seconds.
11653         Problem reported by Frank v Waveren in
11654         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
11655         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
11656         Check for nanosleep bug.
11657         (LIB_NANOSLEEP): Append clock_gettime library if needed.
11658
11659 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11660
11661         Work around a bug in both the Linux and SunOS 64-bit kernels:
11662         nanosleep mishandles sleeps for longer than 2**31 seconds.
11663         Problem reported by Frank v Waveren in
11664         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
11665         * lib/nanosleep.c (BILLION): New constant.
11666         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
11667         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
11668         implementation.
11669
11670 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11671
11672         * modules/nanosleep (Depends-on): Add gettime.
11673
11674 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
11675         and Simon Josefsson  <jas@extundo.com>
11676         and Oskar Liljeblad  <oskar@osk.mine.nu>
11677
11678         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
11679         * gnulib-tool (func_import): New license type 'unmodifiable license
11680         text'.
11681         * modules/fdl: Use it.  Longer description.
11682         * module/gpl, module/lgpl: New files.
11683
11684 2006-08-30  Jim Meyering  <jim@meyering.net>
11685
11686         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
11687         shadowing the parameter.
11688
11689 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11690
11691         Sync from Libtool:
11692
11693         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11694
11695         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
11696         sharing with gnulib.  Report by Eric Blake.
11697
11698 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11699
11700         * modules/isapipe: New file.
11701         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
11702
11703 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11704
11705         * modules/configmake (Makefile.am): Add a comment, and omit
11706         the CONFIGMAKE_ prefix from generated macro names.  Suggested
11707         by Bruno Haible.
11708
11709 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11710
11711         * m4/isapipe.m4: New file.
11712
11713 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
11714
11715         * lib/isapipe.c, lib/isapipe.h: New files.
11716
11717 2006-08-29  Jim Meyering  <jim@meyering.net>
11718
11719         * modules/configmake (Makefile.am): Make configmake.h depend on
11720         Makefile.  Otherwise, a stale configmake.h could hang around.
11721
11722 2006-08-29  Eric Blake  <ebb9@byu.net>
11723
11724         * lib/error.c (error_at_line, print_errno_message): Match libc, after
11725         resolution of upstream bug 3044.
11726
11727 2006-08-29  Bruno Haible  <bruno@clisp.org>
11728
11729         * modules/localcharset (Depends-on): Add configmake.
11730         (Makefile.am): Remove setting of LIBDIR through DEFS.
11731
11732 2006-08-29  Bruno Haible  <bruno@clisp.org>
11733
11734         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
11735         defined.
11736
11737 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11738
11739         * modules/fcntl: New file.
11740         * modules/chdir-safer (Depends-on): Add fcntl.
11741         * modules/fts: Likewise.
11742         * modules/mkdir-p: Likewise.
11743
11744         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
11745         This undoes the most recent change, since we're now addressing the
11746         problem in a different way.
11747
11748         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
11749         into output, since the output might be called Makefile.am even
11750         if $makefile_name is something different.
11751         (func_import): Use $makefile_am rather than
11752         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
11753         empty.
11754
11755         * modules/inttypes (Files): Add m4/inttypes-h.m4.
11756
11757 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11758
11759         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
11760         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
11761         recent change to stdint.m4, since we're now addressing the problem in a
11762         different way.
11763
11764 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11765
11766         * m4/fcntl_h.m4: New file.
11767
11768 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
11769
11770         * lib/fcntl_.h: New file.
11771         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
11772         the fcntl module.
11773         * lib/dirchownmod.c: Likewise.
11774         * lib/fts.c: Likewise.
11775
11776         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
11777         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
11778         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
11779         just before including <inttypes.h>, to avoid circular inclusion.
11780
11781 2006-08-28  Jim Meyering  <jim@meyering.net>
11782
11783         * doc/visibility.texi: Actually read and correct the grammar of the
11784         sentence affected by yesterday's change.
11785
11786 2006-08-28  Eric Blake  <ebb9@byu.net>
11787
11788         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
11789         needs wrapper.
11790
11791 2006-08-28  Eric Blake  <ebb9@byu.net>
11792
11793         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
11794
11795 2006-08-28  Eric Blake  <ebb9@byu.net>
11796
11797         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
11798
11799 2006-08-28  Bruno Haible  <bruno@clisp.org>
11800
11801         * modules/c-strstr: New file, from GNU gettext.
11802         * MODULES.html.sh (String handling): Add c-strstr.
11803
11804 2006-08-28  Bruno Haible  <bruno@clisp.org>
11805
11806         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
11807         macros.
11808         Reported by Eric Blake.
11809
11810 2006-08-28  Bruno Haible  <bruno@clisp.org>
11811
11812         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
11813         (VASNPRINTF): Return a string of length > INT_MAX without failing.
11814         * lib/vasprintf.c: Include errno.h, limits.h.
11815         (EOVERFLOW): New fallback definition.
11816         (vasprintf): Test here whether the string length is > INT_MAX.
11817         * lib/vsnprintf.c: Include errno.h, limits.h.
11818         (EOVERFLOW): New fallback definition.
11819         (vsnprintf): Fix bug when generated string was too long for the buffer.
11820         Test here whether the string length is > INT_MAX.
11821
11822 2006-08-28  Bruno Haible  <bruno@clisp.org>
11823
11824         * lib/inttypes_.h (SCNX*): Remove definitions.
11825         Reported by Eric Blake.
11826
11827 2006-08-28  Bruno Haible  <bruno@clisp.org>
11828
11829         * lib/c-strstr.h: New file, from GNU gettext.
11830         * lib/c-strstr.c: New file, from GNU gettext.
11831
11832 2006-08-28  Bruno Haible  <bruno@clisp.org>
11833
11834         * gnulib-tool: Reorder some statements.
11835
11836 2006-08-28  Bruno Haible  <bruno@clisp.org>
11837
11838         * gnulib-tool: New option --makefile-name.
11839         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
11840         $makefile_name.
11841         (func_import): Write $makefile_name to the cache file, and read it from
11842         there unless explicitly specified. Use $makefile_name as file name
11843         instead of Makefile.am. Adjust the recommendations accordingly.
11844
11845 2006-08-28  Bruno Haible  <bruno@clisp.org>
11846
11847         * gnulib-tool (func_verify_module): Check against misapplying patch.
11848
11849 2006-08-28  Bruno Haible  <bruno@clisp.org>
11850
11851         * gnulib-tool (func_relativize, func_relconcat): New functions.
11852         Give an error if --local-dir is given with --update.
11853         Remove trailing slashes from $local_gnulib_dir.
11854         (func_import): Store the relativized $local_gnulib_dir in
11855         gnulib-cache.m4, and read it from there if not specified explicitly.
11856
11857 2006-08-28  Bruno Haible  <bruno@clisp.org>
11858
11859         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
11860         is the current directory. Respect also $local_gnulib_dir.
11861
11862 2006-08-28  Bruno Haible  <bruno@clisp.org>
11863             Simon Josefsson  <jas@extundo.com>
11864
11865         BeOS portability.
11866         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
11867
11868 2006-08-27  Jim Meyering  <jim@meyering.net>
11869
11870         * doc/visibility.texi: Remove duplicate word: "pointer".
11871
11872 2006-08-26  Bruno Haible  <bruno@clisp.org>
11873
11874         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
11875         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
11876         (Makefile.am): Create inttypes.h from inttypes_.h.
11877         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
11878
11879         * modules/imaxabs: New file.
11880
11881         * modules/imaxdiv: New file.
11882
11883 2006-08-26  Bruno Haible  <bruno@clisp.org>
11884
11885         * m4/inttypes.m4: New file.
11886         * m4/_inttypes_h.m4: Remove file.
11887         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
11888         PRI_MACROS_BROKEN.
11889         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
11890
11891         * m4/imaxabs.m4: New file.
11892
11893         * m4/imaxdiv.m4: New file.
11894
11895 2006-08-26  Bruno Haible  <bruno@clisp.org>
11896
11897         * lib/inttypes_.h: New file.
11898         * lib/inttypes.h: Remove file.
11899         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
11900
11901         * lib/imaxabs.c: New file.
11902
11903         * lib/imaxdiv.c: New file.
11904
11905 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11906
11907         New config-h module, so that "make" output needn't be cluttered
11908         by -DHAVE_CONFIG_H.
11909         * MODULES.html.sh (Support for building libraries and executables):
11910         Add config-h.
11911         * modules/config-h: New file.
11912         * gnulib-tool (nl, sed_transform_lib_file): New vars.
11913         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
11914         the config-h module is used.
11915
11916         New configmake module, so that "make" output needn't be cluttered
11917         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
11918         * MODULES.html.sh (Support for building libraries and executables):
11919         Add configmake.
11920         * modules/configmake: New file.
11921
11922 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
11923
11924         * m4/config-h.m4: New file.
11925
11926 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11927
11928         * config/srclist.txt: Add elisp-comp.
11929
11930 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
11931
11932         * MODULES.html.sh (Support for building libraries and executables):
11933         Add elisp-comp.
11934         * build-aux/elisp-comp: New file.
11935         * modules/elisp-comp: New file.
11936
11937 2006-08-24  Bruno Haible  <bruno@clisp.org>
11938
11939         * gnulib-tool (func_create_testdir): Use non-default values of
11940         sourcebase and m4base.
11941
11942 2006-08-24  Bruno Haible  <bruno@clisp.org>
11943
11944         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
11945         HTML structure.
11946
11947 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
11948
11949         * modules/openat (Depends-on): Add lchown.
11950
11951 2006-08-23  Bruno Haible  <bruno@clisp.org>
11952
11953         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
11954         of gl_LOCK_EARLY instead of gl_LOCK.
11955
11956 2006-08-23  Bruno Haible  <bruno@clisp.org>
11957
11958         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
11959         on OSF/1 to no.
11960         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
11961
11962 2006-08-23  Bruno Haible  <bruno@clisp.org>
11963
11964         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
11965         as unusable.
11966
11967         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
11968         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
11969         (gl_LOCK): New macro.
11970
11971 2006-08-22  Simon Josefsson  <jas@extundo.com>
11972
11973         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
11974         to md5 module.
11975
11976 2006-08-22  Simon Josefsson  <jas@extundo.com>
11977
11978         * MODULES.html.sh: Add "Support for maintaining and release
11979         projects".
11980
11981         * build-aux/gnupload: New file, from coreutils.
11982
11983 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
11984
11985         Avoid the need for AC_LIBSOURCES in m4 macros.
11986         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
11987         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
11988         * modules/check-version (EXTRA_DIST): Add check-version.h.
11989         * modules/crc (EXTRA_DIST): Add crc.h.
11990         * modules/des (EXTRA_DIST): Add des.h.
11991         * modules/gc (EXTRA_DIST): Add gc.h.
11992         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
11993         * modules/getline (EXTRA_DIST): Add getline.h.
11994         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
11995         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
11996         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
11997         * modules/md2 (EXTRA_DIST): Add md2.h.
11998         * modules/md4 (EXTRA_DIST): Add md4.h.
11999         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
12000         * modules/read-file (EXTRA_DIST): Add read-file.h.
12001         * modules/readline (EXTRA_DIST): Add readline.h.
12002         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
12003         rijndael-api-fst.h.
12004
12005 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
12006
12007         * m4/rijndael.m4 (gl_ARCFOUR):
12008         * m4/arctwo.m4 (gl_ARCTWO):
12009         * m4/check-version.m4 (gl_CHECK_VERSION):
12010         * m4/crc.m4 (gl_CRC):
12011         * m4/des.m4 (gl_DES):
12012         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
12013         * m4/gc.m4 (gl_GC):
12014         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
12015         * m4/getline.m4 (gl_FUNC_GETLINE):
12016         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
12017         * m4/hmac-md5.m4 (gl_HMAC_MD5):
12018         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
12019         * m4/md2.m4 (gl_MD2):
12020         * m4/md4.m4 (gl_MD4):
12021         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
12022         * m4/read-file.m4 (gl_FUNC_READ_FILE):
12023         * m4/readline.m4 (gl_FUNC_READLINE):
12024         * m4/rijndael.m4 (gl_RIJNDAEL):
12025         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
12026         to get the necessary .h files and whatnot.
12027
12028 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
12029
12030         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
12031         gnulib rather than the other way around.
12032         * config/srclistvars.sh (COREUTILS): Remove.
12033
12034 2006-08-22  Jim Meyering  <jim@meyering.net>
12035
12036         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
12037
12038         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
12039
12040 2006-08-22  Eric Blake  <ebb9@byu.net>
12041
12042         * modules/regexprops-generic: New file.
12043         * MODULES.html.sh (Support for building documentation): List it.
12044
12045 2006-08-22  Eric Blake  <ebb9@byu.net>
12046
12047         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
12048         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
12049         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
12050         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
12051
12052 2006-08-22  Bruno Haible  <bruno@clisp.org>
12053
12054         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
12055         and lib_LTLIBRARIES like the other lib_* variables.
12056
12057 2006-08-22  Bruno Haible  <bruno@clisp.org>
12058
12059         * build-aux/x-to-1.in: New file, from GNU gettext.
12060
12061 2006-08-22  Bruno Haible  <bruno@clisp.org>
12062
12063         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
12064         <utmpx.h> exists.
12065
12066 2006-08-22  Bruno Haible  <bruno@clisp.org>
12067
12068         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
12069         <utmpx.h> exists.
12070
12071 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
12072
12073         BeOS portability.
12074         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
12075         exist.
12076         Problem reported by Bruno Haible.
12077
12078 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
12079
12080         Avoid the need for AC_LIBSOURCES in m4 macros.
12081         * modules/acl (EXTRA_DIST): Add acl.h.
12082         * modules/argmatch (Files): Add m4/argmatch.m4.
12083         (configure.ac): Add gl_ARGMATCH.
12084         (EXTRA_DIST): Renamed from lib_SOURCES, for
12085         consistency with the other modules.  Remove argmatch.c.
12086         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
12087         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
12088         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
12089         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
12090         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
12091         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
12092         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
12093         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
12094         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
12095         * modules/closeout (EXTRA_DIST): Add closeout.h.
12096         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
12097         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
12098         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
12099         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
12100         dirname.h; remove basename.c and stripslash.c.
12101         * modules/exclude (EXTRA_DIST): Add exclude.h.
12102         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
12103         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
12104         * modules/file-type (EXTRA_DIST): Add file-type.h.
12105         * modules/filemode (EXTRA_DIST): Add filemode.h.
12106         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
12107         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
12108         * modules/fpending (EXTRA_DIST): Add __fpending.h.
12109         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
12110         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
12111         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
12112         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
12113         * modules/getdate (EXTRA_DIST): Add getdate.c.
12114         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
12115         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
12116         * modules/getpass (EXTRA_DIST): Add getpass.h.
12117         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
12118         * modules/group-member (EXTRA_DIST): Add group-member.h.
12119         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
12120         * modules/hash (EXTRA_DIST): Add hash.h.
12121         * modules/human (EXTRA_DIST): Add human.h.
12122         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
12123         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
12124         * modules/lchown (EXTRA_DIST): Add lchown.h.
12125         * modules/long-options (EXTRA_DIST): Add long-options.h.
12126         * modules/lstat (EXTRA_DIST): Add lstat.h.
12127         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
12128         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
12129         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
12130         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
12131         * modules/memxor (EXTRA_DIST): Add memxor.h.
12132         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
12133         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
12134         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
12135         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
12136         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
12137         * modules/physmem (EXTRA_DIST): Add physmem.h.
12138         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
12139         * modules/posixver (EXTRA_DIST): Add posixver.h.
12140         * modules/quote (EXTRA_DIST): Add quote.h.
12141         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
12142         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
12143         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
12144         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
12145         regex_internal.h regexec.c.
12146         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
12147         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
12148         * modules/same (EXTRA_DIST): Add same.h.
12149         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
12150         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
12151         * modules/savedir (EXTRA_DIST): Add savedir.h.
12152         * modules/sha1 (EXTRA_DIST): Add sha1.h.
12153         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
12154         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
12155         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
12156         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
12157         * modules/strdup (EXTRA_DIST): Add strdup.h.
12158         * modules/strftime (EXTRA_DIST): Add strftime.h.
12159         * modules/strndup (EXTRA_DIST): Add strndup.h.
12160         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
12161         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
12162         * modules/time_r (EXTRA_DIST): Add time_r.h.
12163         * modules/timespec (EXTRA_DIST): Add timespec.h.
12164         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
12165         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
12166         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
12167         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
12168         * modules/userspec (EXTRA_DIST): Add userspec.h.
12169         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
12170         * modules/utimens (EXTRA_DIST): Add utimens.h.
12171         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
12172         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
12173         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
12174         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
12175         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
12176         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
12177         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
12178         * modules/yesno (EXTRA_DIST): Add yesno.h.
12179
12180 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
12181
12182         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
12183
12184         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
12185         * m4/dev-ino.m4, same-inode.m4: Remove.
12186
12187         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
12188         * m4/acl.m4 (AC_FUNC_ACL):
12189         * m4/backupfile.m4 (gl_BACKUPFILE):
12190         * m4/c-strtod.m4 (gl_C99_STRTOLD):
12191         * m4/canon-host.m4 (gl_CANON_HOST):
12192         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
12193         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
12194         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
12195         * m4/cloexec.m4 (gl_CLOEXEC):
12196         * m4/close-stream.m4 (gl_CLOSE_STREAM):
12197         * m4/closeout.m4 (gl_CLOSEOUT):
12198         * m4/dirfd.m4 (gl_FUNC_DIRFD):
12199         * m4/dirname.m4 (gl_DIRNAME):
12200         * m4/exclude.m4 (gl_EXCLUDE):
12201         * m4/exitfail.m4 (gl_EXITFAIL):
12202         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
12203         * m4/file-type.m4 (gl_FILE_TYPE):
12204         * m4/filemode.m4 (gl_FILEMODE):
12205         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
12206         * m4/fpending.m4 (gl_FUNC_FPENDING):
12207         * m4/fprintftime.m4 (gl_FPRINTFTIME):
12208         * m4/fts.m4 (gl_FUNC_FTS):
12209         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
12210         * m4/getdate.m4 (gl_GETDATE):
12211         * m4/gethrxtime.m4 (gl_GETHRXTIME):
12212         * m4/getpagesize.m4 (gl_GETPAGESIZE):
12213         * m4/getpass.m4 (gl_FUNC_GETPASS):
12214         * m4/gettime.m4 (gl_GETTIME):
12215         * m4/getugroups.m4 (gl_GETUGROUPS):
12216         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
12217         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
12218         * m4/hard-locale.m4 (gl_HARD_LOCALE):
12219         * m4/hash.m4 (gl_HASH):
12220         * m4/idcache.m4 (gl_IDCACHE):
12221         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
12222         * m4/lchown.m4 (gl_FUNC_LCHOWN):
12223         * m4/long-options.m4 (gl_LONG_OPTIONS):
12224         * m4/lstat.m4 (gl_FUNC_LSTAT):
12225         * m4/md5.m4 (gl_MD5):
12226         * m4/memcasecmp.m4 (gl_MEMCASECMP):
12227         * m4/memcoll.m4 (gl_MEMCOLL):
12228         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
12229         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
12230         * m4/memxor.m4 (gl_MEMXOR):
12231         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
12232         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
12233         * m4/modechange.m4 (gl_MODECHANGE):
12234         * m4/mountlist.m4 (gl_MOUNTLIST):
12235         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
12236         * m4/openat.m4 (gl_FUNC_OPENAT):
12237         * m4/pathmax.m4 (gl_PATHMAX):
12238         * m4/physmem.m4 (gl_PHYSMEM):
12239         * m4/posixtm.m4 (gl_POSIXTM):
12240         * m4/posixver.m4 (gl_POSIXVER):
12241         * m4/quote.m4 (gl_QUOTE):
12242         * m4/quotearg.m4 (gl_QUOTEARG):
12243         * m4/readtokens.m4 (gl_READTOKENS):
12244         * m4/readutmp.m4 (gl_READUTMP):
12245         * m4/regex.m4 (gl_REGEX):
12246         * m4/safe-read.m4 (gl_SAFE_READ):
12247         * m4/safe-write.m4 (gl_SAFE_WRITE):
12248         * m4/same.m4 (gl_SAME):
12249         * m4/save-cwd.m4 (gl_SAVE_CWD):
12250         * m4/savedir.m4 (gl_SAVEDIR):
12251         * m4/settime.m4 (gl_SETTIME):
12252         * m4/sha1.m4 (gl_SHA1):
12253         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
12254         * m4/stat-macros.m4 (gl_STAT_MACROS):
12255         * m4/stat-time.m4 (gl_STAT_TIME):
12256         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
12257         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
12258         * m4/strdup.m4 (gl_FUNC_STRDUP):
12259         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
12260         * m4/strndup.m4 (gl_FUNC_STRNDUP):
12261         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
12262         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
12263         * m4/time_r.m4 (gl_TIME_R):
12264         * m4/timespec.m4 (gl_TIMESPEC):
12265         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
12266         * m4/unlinkdir.m4 (gl_UNLINKDIR):
12267         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
12268         * m4/userspec.m4 (gl_USERSPEC):
12269         * m4/utimecmp.m4 (gl_UTIMECMP):
12270         * m4/utimens.m4 (gl_UTIMENS):
12271         * m4/xalloc.m4 (gl_XALLOC):
12272         * m4/xgetcwd.m4 (gl_XGETCWD):
12273         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
12274         * m4/xreadlink.m4 (gl_XREADLINK):
12275         * m4/xstrtod.m4 (gl_XSTRTOD):
12276         * m4/yesno.m4 (gl_YESNO):
12277         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
12278         to get the necessary .h files and whatnot.
12279
12280 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
12281             Bruno Haible  <bruno@clisp.org>
12282
12283         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
12284         /bin/sh understanding of '!' conditional negation.
12285
12286 2006-08-21  Jim Meyering  <jim@meyering.net>
12287
12288         * modules/openat (Depends-on): Really alphabetize.
12289
12290         * modules/acl (Depends-on): Add error and quote.
12291
12292         * check-module (find_included_lib_files): Add at-func.c to the
12293         ok-to-include-more-than-once white list.
12294
12295         * modules/openat (Depends-on): Add lstat.  Alphabetize.
12296
12297 2006-08-21  Bruno Haible  <bruno@clisp.org>
12298
12299         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12300         Emit a pkgdata_DATA variable only if some snippets add contents to it.
12301         Reported by Martin Lambers <marlam@marlam.de>.
12302
12303 2006-08-21  Bruno Haible  <bruno@clisp.org>
12304
12305         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
12306         specify an installation location, don't emit a noinst_LIBRARIES or
12307         noinst_LTLIBRARIES assignment.
12308
12309 2006-08-21  Bruno Haible  <bruno@clisp.org>
12310
12311         BeOS portability.
12312         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
12313         BeOS has mbrtowc() but no <wctype.h>.
12314
12315 2006-08-21  Bruno Haible  <bruno@clisp.org>
12316
12317         BeOS portability.
12318         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
12319         exist.
12320
12321 2006-08-21  Bruno Haible  <bruno@clisp.org>
12322
12323         BeOS portability.
12324         * lib/mbchar.h: Include <wctype.h> only if it exists.
12325
12326 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12327
12328         Remove files that are no longer needed by their respective modules.
12329         * m4/obstack.m4: Remove.
12330         * m4/strerror_r.m4: Remove.
12331         * m4/uint32_t.m4: Remove.
12332         * m4/uintptr_t.m4: Remove.
12333         * m4/ullong_max.m4: Remove.
12334         * m4/xstrtoimax.m4: Remove.
12335         * m4/xstrtoumax.m4: Remove.
12336
12337         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
12338         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
12339         dependencies now capture this.
12340
12341         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
12342         Do not use AC_LIBSOURCES, since gnulib modules now do this.
12343         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
12344         * m4/human.m4 (gl_HUMAN): Likewise.
12345         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
12346         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
12347
12348         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
12349
12350         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
12351         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
12352         stdint.
12353         * m4/human.m4 (gl_HUMAN): Likewise.
12354         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
12355         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
12356         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
12357         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
12358         * m4/xstrtol (gl_XSTRTOL): Likewise.
12359
12360         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
12361         AC_TYPE_LONG_LONG_INT.
12362         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
12363         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
12364         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
12365         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
12366
12367         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
12368         on stdbool.
12369
12370         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
12371         (gl_PREREQ_XSTRTOUL): Remove.
12372
12373         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
12374
12375         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
12376         mode.
12377
12378 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12379
12380         Add and change modules to make it easier for coreutils to use
12381         gnulib-tool.
12382         * modules/backupfile (Files): Remove m4/d-ino.m4.
12383         (Depends-on): Add d-ino.
12384         * modules/cycle-check (Depends-on): Add stdint.
12385         (lib_SOURCES): Add cycle-check.h.
12386         * modules/d-ino: New module.
12387         * modules/d-type: New module.
12388         * modules/error (Files): Remove m4/strerror_r.m4.
12389         * modules/filemode (Files): Add m4/st_dm_mode.m4.
12390         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
12391         m4/inttypes_h.m4, m4/uintmax_t.m4.
12392         (Depends-on): Add stdint.
12393         (lib_SOURCES): Add fsusage.h.
12394         * modules/getcwd (Files): Remove d-ino.m4.
12395         (Depends-on): Add d-ino.
12396         * modules/getndelim2 (Depends-on): Add stdint.
12397         * modules/glob (Files): Remove m4/d-type.m4.
12398         (Depends-on): Add d-type.
12399         * modules/host-os: New module.
12400         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
12401         m4/inttypes_h.m4, m4/uintmax_t.m4.
12402         * Depends-on: Add stdint.
12403         (lib_SOURCES): Add human.h.
12404         * modules/inttostr (Files): Remove m4/intmax_t.m4,
12405         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
12406         m4/uintmax_t.m4, m4/ulonglong.m4.
12407         (Depends-on): Add stdint.
12408         (EXTRA_DIST): Add inttostr.h.
12409         * modules/lchmod: New module.
12410         * modules/link-follow: New module.
12411         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
12412         (Depends-on): Add lchmod.
12413         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
12414         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
12415         (Depends-on): Add stdint.
12416         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
12417         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
12418         (Depends-on): Add stdint.
12419         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
12420         * modules/perl: New module.
12421         * modules/regex (Depends-on): Add stdint.
12422         * modules/rmdir-errno: New module.
12423         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
12424         m4/intmax_t.m4.
12425         (Depends-on): Add stdint.
12426         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
12427         m4/uintmax_t.m4.
12428         (Depends-on): Add stdint.
12429         * modules/unlink-busy: New module.
12430         * modules/utimecmp (Depends-on): Add stdint.
12431         * modules/uptime: New module.
12432         * modules/winsz-ioctl: New module.
12433         * modules/winsz-termios: New module.
12434         * modules/xnanosleep (Depends-on): Add nanosleep.
12435         * modules/ullong_max: Remove.
12436         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
12437         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
12438         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
12439         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
12440         (Depends-on): Add inttypes.
12441         (lib_SOURCES): Add xstrtol.h.
12442         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
12443         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
12444         * MODULES.html.sh: Move 'assert' into the assert section.
12445         Move 'dummy' into the linking section.
12446         Remove ullong_max.
12447         Add section for compatibility checks for POSIX:2001 functions,
12448         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
12449         winsz-ioctl, and winsz-termios into it.
12450         Add lchmod.
12451         Add top-level Misc section and put host-os, perl, and uptime
12452         into it.
12453
12454 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
12455
12456         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
12457         now assume the stdint module.  Do not include inttypes.h.
12458         * lib/fsusage.h: Likewise.
12459         * lib/getndelim2.c: Likewise.
12460         * lib/human.h: Likewise.
12461         * lib/inttostr.h: Likewise.
12462         * lib/obstack.c: Likewise.
12463         * lib/regex_internal.h: Likewise.
12464         * lib/tempname.c: Likewise.
12465         * lib/utimecmp.c: Likewise.
12466         * lib/xstrtol.h: Likewise.
12467
12468         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
12469
12470         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
12471         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
12472         * lib/xtime.h: Likewise.
12473
12474 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12475
12476         * modules/openat (Files): Add lib/fchmodat.c.
12477         Fixes problem reported by Jay Youngman.
12478
12479 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
12480
12481         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
12482         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
12483
12484 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
12485             Bruno Haible  <bruno@clisp.org>
12486
12487         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
12488         and is a script that invokes bison. Tighten the code. Add comments.
12489
12490 2006-08-18  Jim Meyering  <jim@meyering.net>
12491
12492         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
12493         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
12494         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
12495         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
12496
12497 2006-08-18  Bruno Haible  <bruno@clisp.org>
12498
12499         * modules/bison-i18n: New file.
12500         * MODULES.html.sh (Internationalization functions): Add it.
12501
12502 2006-08-18  Bruno Haible  <bruno@clisp.org>
12503
12504         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
12505         sys/statvfs.h. When getmntinfo was found, check its declaration and
12506         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
12507
12508 2006-08-18  Bruno Haible  <bruno@clisp.org>
12509
12510         * m4/bison-i18n.m4: New file, from bison.
12511
12512 2006-08-18  Bruno Haible  <bruno@clisp.org>
12513
12514         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
12515         (ME_DUMMY): Treat "kernfs" as a dummy.
12516         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
12517
12518 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
12519
12520         Update from coreutils.
12521
12522         2006-08-15  Jim Meyering  <jim@meyering.net>
12523
12524         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
12525
12526         2006-01-17  Jim Meyering  <jim@meyering.net>
12527
12528         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
12529
12530         2006-01-11  Jim Meyering  <jim@meyering.net>
12531
12532         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
12533         Check for the lchmod function.
12534
12535 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
12536
12537         Update from coreutils.
12538
12539         * lib/__fpending.h: Add copyright notice.
12540         * lib/fprintftime.h: Likewise.
12541         * lib/savedir.c: Use (C) in copyright notice.
12542         * lib/savedir.h: Likewise.
12543
12544         2006-08-15  Jim Meyering  <jim@meyering.net>
12545
12546         * lib/at-func.c: New file, with the logic of all emulated at-functions.
12547         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
12548         in support of the EXPECTED_ERRNO macro.
12549         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
12550         definitions.  Instead, define the appropriate symbols and include
12551         "at-func.c".
12552         * lib/mkdirat.c (mkdirat): Likewise.
12553         * lib/fchmodat.c (fchmodat): Likewise.
12554         (ENOSYS): Remove definition.
12555         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
12556         it.  Don't include "unistd--.h" -- it wasn't ever used.
12557
12558         2006-01-17  Jim Meyering  <jim@meyering.net>
12559
12560         Rewrite fts.c not to change the current working directory,
12561         by using openat, fstatat, fdopendir, etc..
12562
12563         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
12564         (HAVE_OPENAT_SUPPORT): Define.
12565         [_LIBC] (fchdir): Don't undef or define; no longer used.
12566         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
12567         Now, this `function' always succeeds, and consumes its file descriptor
12568         parameter -- so callers must not close such FDs.  Update callers.
12569         (diropen_fd, opendirat, cwd_advance_fd): New functions.
12570         (diropen): Add parameter, SP.  Adjust all callers.
12571         Implement using diropen_fd, rather than open.
12572         (fts_open): Initialize new member, fts_cwd_fd.
12573         Remove fts_rft-setting code.
12574         (fts_close): Close fts_cwd_fd, if necessary.
12575         (__opendir2): Define in terms of opendir or opendirat,
12576         depending on whether the FST_NOCHDIR flag is set.
12577         (fts_build): Since fts_safe_changedir consumes its FD, and since
12578         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
12579         and close the dup'd file descriptor upon failure.
12580         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
12581         (fts_safe_changedir): Tweak semantics to reflect that this function
12582         now calls cwd_advance_fd and hence consumes its FD argument.
12583         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
12584         [struct FTS] (fts_rft): Remove now-unused member.
12585         [struct FTS] (fts_cycle.state): Improve comment.
12586
12587         * lib/openat.c (openat_needs_fchdir): New function.
12588         * lib/openat.h (openat_needs_fchdir): Declare it.
12589
12590 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
12591
12592         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
12593         Problem and fix reported by Pádraig Brady in
12594         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
12595
12596 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12597
12598         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
12599
12600 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12601
12602         * lib/memcoll.c (memcoll): Optimize for the common case where the
12603         arguments are bytewise equal.
12604
12605 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
12606
12607         * doc/regexprops-generic.texi: Add a copyright notice.
12608
12609 2006-08-15  Bruno Haible  <bruno@clisp.org>
12610
12611         * modules/tmpdir (License): Change to LGPL.
12612
12613 2006-08-15  Bruno Haible  <bruno@clisp.org>
12614
12615         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
12616         module.
12617
12618 2006-08-14  Simon Josefsson  <jas@extundo.com>
12619
12620         * config/srclist.txt: Add gnupload.
12621
12622 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12623
12624         Change copyright notice from LGPL 2 to GPL 2, since that's the
12625         standard form used in the gnulib repository.
12626         * tests/test-lock.c: Likewise.
12627         * tests/test-stdint.c: Likewise.
12628         * tests/test-tls.c: Likewise.
12629
12630         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
12631         prelude-manager.  User shorter URLs for GNU projects, without '?'.
12632         Add copyright notice.
12633
12634         * check-module: Add copyright notice.  Output a copyright
12635         notice if "--version" is specified.
12636         * modules/COPYING: New file.
12637         * tests/test-getaddrinfo.c: Add copyright notice.
12638         * tests/test-verify.c: Likewise.
12639
12640 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12641
12642         Change copyright notice from LGPL 2 to GPL 2, since that's the
12643         standard form used in the gnulib repository.
12644         * lib/lock.c: LGPL -> GPL.
12645         * lib/lock.h: Likewise.
12646         * lib/strnlen1.c: Likewise.
12647         * lib/strnlen1.h: Likewise.
12648         * lib/tls.c: Likewise.
12649         * lib/tls.h: Likewise.
12650         * lib/tmpdir.c: Likewise.
12651
12652         * lib/TODO: Remove; this belongs only in coreutils.
12653
12654 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12655
12656         Add copyright notices to long-enough files that lack them, since
12657         otherwise the files aren't clearly free.  Use the same notice that
12658         getdate.texi already uses.
12659         * doc/alloca-opt.texi: Add copyright notice.
12660         * doc/alloca.texi: Likewise.
12661         * doc/ctime.texi: Likewise.
12662         * doc/functions.texi: Likewise.
12663         * doc/gcd.texi: Likewise.
12664         * doc/gnulib-tool.texi: Likewise.
12665         * doc/inet_ntoa.texi: Likewise.
12666         * doc/visibility.texi: Likewise.
12667
12668         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
12669         * doc/quote.texi: Add copyright notice.
12670
12671         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
12672         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
12673         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
12674         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
12675         is now obsolete, and give a pointer to the Sun list.
12676         Add copyright notice.
12677
12678 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
12679
12680         * config/srclistvars.sh: Add copyright notice.
12681
12682 2006-08-14  Eric Blake  <ebb9@byu.net>
12683
12684         Import the following change from libc:
12685
12686         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
12687
12688         Upstream bug 2997.
12689         * lib/misc/error.c: Add space between program name and message if file
12690         name is missing.
12691
12692 2006-08-12  Karl Berry  <karl@gnu.org>
12693
12694         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
12695         remove, these originate in gnulib now.
12696
12697 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12698
12699         * doc/Makefile (standards.info standards.html standards.dvi):
12700         Also depend on make-stds.texi.
12701
12702 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
12703
12704         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
12705         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
12706
12707         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
12708         in wchar_t.  Problem reported by Eric Blake.
12709
12710         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
12711         LEN is smaller than SIZE.  Suggested by Bruno Haible.
12712         Also, help the compiler to keep LEN in a register.
12713
12714 2006-08-11  Eric Blake  <ebb9@byu.net>
12715
12716         * users.txt: Sort.  Add tar.
12717
12718 2006-08-11  Bruno Haible  <bruno@clisp.org>
12719
12720         * users.txt: New file.
12721
12722 2006-08-11  Bruno Haible  <bruno@clisp.org>
12723
12724         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
12725         before <wchar.h>. Needed for OSF/1 and BSD/OS.
12726
12727 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
12728
12729         * modules/snprintf (Depends-on): Remove minmax.
12730         (Maintainer): Add self and Bruno.
12731
12732 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
12733
12734         * lib/.cppi-disable: Add snprintf.h, socket_.h.
12735         * lib/snprintf.c: Include <errno.h> and <limits.h>.
12736         (EOVERFLOW): Define if the system does not.
12737         Do not include "minmax.h"; it wasn't used.
12738         (snprintf): Don't assume size_t promotes to an unsigned type.
12739         Fix bug when generated string was too long for the buffer: the
12740         buffer's contents are supposed to be the initial prefix of the
12741         output.  Don't assume vasnprintf returns EOVERFLOW if the size
12742         exceeds INT_MAX; do the check ourselves.
12743
12744         Import the following changes from libc:
12745
12746         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
12747
12748         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
12749         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
12750         set wc to the byte which couldn't be converted.
12751         (re_string_reconstruct): Don't clear valid_raw_len before calling
12752         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
12753         tip_context using re_string_context_at.
12754
12755         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
12756
12757         * lib/posix/regex.h: g++ still cannot handled [restrict].
12758
12759         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
12760
12761         * lib/posix/regex.h: Remove special handling for VMS.
12762
12763 2006-08-10  Jim Meyering  <jim@meyering.net>
12764
12765         * modules/same-inode: New module.
12766         * modules/dev-ino: New module.
12767         * modules/cycle-check: Depend on these modules, rather than simply
12768         including their .h files.
12769         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
12770         required via m4/cycle-check.m4.
12771         * modules/same: Depend on new same-inode module, rather than
12772         including same-inode.h.
12773         * modules/chdir-safer: New file.
12774
12775         * modules/chown (Depends-on): Add stat-macros.
12776
12777 2006-08-10  Jim Meyering  <jim@meyering.net>
12778
12779         * m4/cycle-check.m4: New file.
12780         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
12781         * m4/dev-ino.m4, m4/same-inode.m4: New files.
12782
12783 2006-08-10  Eric Blake  <ebb9@byu.net>
12784
12785         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
12786         in from original proposal.
12787
12788 2006-08-10  Eric Blake  <ebb9@byu.net>
12789         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
12790
12791         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
12792         namespace.
12793
12794 2006-08-10  Bruno Haible  <bruno@clisp.org>
12795
12796         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
12797         as well.
12798
12799 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12800
12801         Sync from coreutils.
12802
12803         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
12804
12805         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
12806         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
12807
12808 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12809
12810         * modules/restrict: Remove; no longer needed now that we assume
12811         Autoconf 2.59 or later.
12812         * MODULES.html.sh: Remove 'restrict'.
12813         * modules/argp (Depends-on): Remove 'restrict'.
12814         * modules/base64 (Depends-on): Likewise.
12815         * modules/gc (Depends-on): Likewise.
12816         * modules/getaddrinfo (Depends-on): Likewise.
12817         * modules/glob (Depends-on): Likewise.
12818         * modules/inet_ntop (Depends-on): Likewise.
12819         * modules/inet_pton (Depends-on): Likewise.
12820         * modules/memxor (Depends-on): Likewise.
12821         * modules/regex (Depends-on): Likewise.
12822         * modules/strtok_r (Depends-on): Likewise.
12823         * modules/time_r (Depends-on): Likewise.
12824
12825 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
12826
12827         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
12828         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
12829         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
12830         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
12831         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
12832         * m4/memxor.m4 (gl_MEMXOR): Likewise.
12833         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
12834         gl_C_RESTRICT replaced by AC_C_RESTRICT.
12835
12836         Merge from coreutils.
12837         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
12838         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
12839         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
12840         * m4/time_r.m4 (gl_TIME_R): Likewise.
12841
12842 2006-08-09  Karl Berry  <karl@gnu.org>
12843
12844         * config/srclist.txt: no more gettext-tools, per Bruno.
12845
12846 2006-08-08  Eric Blake  <ebb9@byu.net>
12847
12848         * modules/verror: New module.
12849         * MODULES.html.sh: Document it.
12850
12851 2006-08-08  Eric Blake  <ebb9@byu.net>
12852
12853         * lib/verror.h, lib/verror.c: New files.
12854
12855 2006-08-08  Eric Blake  <ebb9@byu.net>
12856
12857         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
12858         verror_at_line output complies with GNU Coding Standards even when
12859         file is NULL.
12860
12861 2006-08-07  Bruno Haible  <bruno@clisp.org>
12862
12863         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
12864         versions of AIX.
12865         Reported by Ralf Wildenhues.
12866
12867 2006-08-07  Bruno Haible  <bruno@clisp.org>
12868
12869         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
12870         in an AC_DEFUN. Needed so that the autoconf snippets can use
12871         AC_REQUIRE.
12872
12873 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12874
12875         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12876         Initialize pkgdata_DATA.
12877         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
12878         overriding it.
12879
12880 2006-08-06  Eric Blake  <ebb9@byu.net>
12881
12882         * lib/error.h: Fold in some upstream changes from glibc.
12883         * lib/error.c: Likewise.
12884
12885 2006-08-04  Bruno Haible  <bruno@clisp.org>
12886
12887         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12888         Make the mostlyclean-local rule depend on mostlyclean-generic.
12889         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
12890
12891 2006-07-31  Bruno Haible  <bruno@clisp.org>
12892
12893         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
12894         <stdlib.h>, <string.h>.
12895
12896 2006-07-30  Bruno Haible  <bruno@clisp.org>
12897
12898         * modules/readlink (License): Change to LGPL.
12899
12900 2006-07-30  Bruno Haible  <bruno@clisp.org>
12901
12902         * modules/javaversion (Makefile.am): Distribute javaversion.java and
12903         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
12904         set PKGDATADIR to point to it.
12905
12906 2006-07-30  Bruno Haible  <bruno@clisp.org>
12907
12908         * modules/csharpexec (configure.ac): Comment out macro invocation.
12909         * modules/javaexec (configure.ac): Likewise.
12910         * modules/javacomp-script (configure.ac): Likewise.
12911
12912         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
12913
12914 2006-07-30  Bruno Haible  <bruno@clisp.org>
12915
12916         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
12917         linked-list.
12918
12919 2006-07-30  Bruno Haible  <bruno@clisp.org>
12920
12921         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
12922
12923 2006-07-30  Bruno Haible  <bruno@clisp.org>
12924
12925         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12926         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
12927         get removed.
12928
12929 2006-07-29  Bruno Haible  <bruno@clisp.org>
12930
12931         Make it possible for gnulib-tool to work with locally modified or
12932         augmented gnulib repositories.
12933         * gnulib-tool (func_usage): Document --local-dir option.
12934         (local_gnulib_dir): New variable.
12935         Handle --local-dir option.
12936         (func_lookup_file): New function.
12937         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
12938         (func_get_description, func_get_filelist, func_get_description,
12939         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
12940         func_get_automake_snippet, func_get_include_directive,
12941         func_get_license, func_get_maintainer): Use func_lookup_file.
12942         (func_import, func_create_testdir): Use func_lookup_file.
12943
12944 2006-07-29  Bruno Haible  <bruno@clisp.org>
12945
12946         * modules/setenv (Depends-on): Add unistd.
12947
12948 2006-07-29  Bruno Haible  <bruno@clisp.org>
12949
12950         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
12951
12952 2006-07-29  Bruno Haible  <bruno@clisp.org>
12953
12954         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
12955
12956 2006-07-29  Bruno Haible  <bruno@clisp.org>
12957
12958         * gnulib-tool (import, update): If there is no Makefile.am, look at
12959         aclocal.m4, instead of bailing out.
12960
12961 2006-07-29  Bruno Haible  <bruno@clisp.org>
12962
12963         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
12964         Categorize the options by when they are useful.
12965
12966 2006-07-29  Bruno Haible  <bruno@clisp.org>
12967
12968         * gnulib-tool (func_usage): Document option --no-libtool.
12969         Handle option --no-libtool.
12970         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
12971         for changed semantics of $libtool variable.
12972         (func_import): Likewise. If libtool is not used, show this through
12973         an option --no-libtool.
12974         (func_create_testdir): Update.
12975
12976 2006-07-29  Bruno Haible  <bruno@clisp.org>
12977
12978         * gnulib-tool (func_import): Extend error message about missing
12979         --doc-base.
12980
12981 2006-07-29  Bruno Haible  <bruno@clisp.org>
12982
12983         * gnulib-tool (func_import): Don't create the $docbase directory if
12984         there is no file to store there.
12985
12986 2006-07-29  Bruno Haible  <bruno@clisp.org>
12987
12988         * gnulib-tool (autoconf_minversion): If a --dir option is given and
12989         relevant, look for configure.ac there, not in the current directory.
12990         Also use a simple search for AC_PREREQ, not "autoconf --trace".
12991
12992 2006-07-29  Bruno Haible  <bruno@clisp.org>
12993
12994         * gnulib-tool (SORT): New variable.
12995         (func_usage): Undocument --assume-autoconf option.
12996         Remove --assume-autoconf option handling.
12997         (autoconf_minversion): Determine from the contents of configure.ac.
12998         (func_import): Remove autoconf_minversion handling.
12999         Suggested by Eric Blake.
13000
13001 2006-07-29  Bruno Haible  <bruno@clisp.org>
13002
13003         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
13004
13005 2006-07-29  Bruno Haible  <bruno@clisp.org>
13006
13007         * config/srclist.txt (*setenv.[ch]): Remove rules.
13008
13009 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13010
13011         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
13012
13013 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13014
13015         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
13016         arpa/inet.h.
13017
13018 2006-07-28  Simon Josefsson  <jas@extundo.com>
13019
13020         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
13021         * modules/inet_pton (Depends-on): Likewise.
13022
13023 2006-07-28  Simon Josefsson  <jas@extundo.com>
13024
13025         * m4/netinet_in_h.m4: New file.
13026
13027 2006-07-28  Simon Josefsson  <jas@extundo.com>
13028
13029         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
13030         #include's.
13031
13032 2006-07-28  Simon Josefsson  <jas@extundo.com>
13033
13034         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
13035         #include's.
13036
13037 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
13038
13039         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
13040         setgid on directories only if they set these bits.
13041         * lib/modechange.h: Remove obsolete comment about masks.
13042
13043 2006-07-28  Eric Blake  <ebb9@byu.net>
13044
13045         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
13046         macro expansion.
13047
13048 2006-07-28  Bruno Haible  <bruno@clisp.org>
13049
13050         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
13051
13052 2006-07-28  Bruno Haible  <bruno@clisp.org>
13053
13054         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
13055
13056 2006-07-28  Bruno Haible  <bruno@clisp.org>
13057
13058         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
13059         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
13060         Define fallbacks.
13061         Avoids link error on FreeBSD 4.x.
13062         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
13063
13064         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
13065         encoding.
13066         * lib/mbswidth.c (iswcntrl): Likewise.
13067
13068 2006-07-27  Bruno Haible  <bruno@clisp.org>
13069
13070         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
13071         test.
13072
13073 2006-07-27  Bruno Haible  <bruno@clisp.org>
13074
13075         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
13076         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
13077         defined.
13078
13079 2006-07-26  Eric Blake  <ebb9@byu.net>
13080
13081         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
13082
13083 2006-07-26  Eric Blake  <ebb9@byu.net>
13084
13085         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
13086         like mingw that lack mkstemp.
13087         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
13088         avoid compilation warning on mingw.
13089
13090 2006-07-26  Bruno Haible  <bruno@clisp.org>
13091
13092         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
13093         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
13094         INT_FAST*_MIN, INTPTR_MIN.
13095
13096 2006-07-25  Bruno Haible  <bruno@clisp.org>
13097
13098         * modules/version-etc (Depends-on): Add stdarg.
13099
13100 2006-07-25  Bruno Haible  <bruno@clisp.org>
13101
13102         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
13103         complex commands.
13104
13105 2006-07-25  Bruno Haible  <bruno@clisp.org>
13106
13107         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
13108         defined in <stdarg.h> or config.h.
13109
13110 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
13111
13112         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
13113         (gl_STDIO_SAFER): Remove.
13114
13115 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
13116
13117         * MODULES.html.sh (File stream based Input/Output):
13118         Add fopen-safer, tmpfile-safer; remove stdio-safer.
13119         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
13120         * modules/fopen-safer, modules/tmpfile-safer: New files.
13121         * modules/stdio-safer: Remove.
13122
13123 2006-07-24  Bruno Haible  <bruno@clisp.org>
13124
13125         * modules/tmpdir: New file.
13126         * MODULES.html.sh (File system functions): Add it.
13127
13128 2006-07-24  Bruno Haible  <bruno@clisp.org>
13129
13130         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
13131         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
13132
13133 2006-07-24  Bruno Haible  <bruno@clisp.org>
13134
13135         * modules/clean-temp: New file.
13136
13137 2006-07-24  Bruno Haible  <bruno@clisp.org>
13138
13139         * m4/tmpdir.m4: New file, from GNU gettext.
13140
13141 2006-07-24  Bruno Haible  <bruno@clisp.org>
13142
13143         * lib/tmpdir.h: New file, from GNU gettext.
13144         * lib/tmpdir.c: New file, from GNU gettext.
13145
13146 2006-07-24  Bruno Haible  <bruno@clisp.org>
13147
13148         * lib/clean-temp.h: New file, from GNU gettext.
13149         * lib/clean-temp.c: New file, from GNU gettext.
13150
13151 2006-07-23  Eric Blake  <ebb9@byu.net>
13152
13153         * modules/stdio-safer (Files): Add tmpfile-safer.c.
13154         (Depends-on): Add binary-io.
13155
13156 2006-07-23  Eric Blake  <ebb9@byu.net>
13157
13158         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
13159
13160 2006-07-23  Eric Blake  <ebb9@byu.net>
13161
13162         * lib/tmpfile-safer.c: New file.
13163         * lib/stdio-safer.h (fopen_safer): Add prototype.
13164         * lib/stdio--.h (tmpfile): Make safer.
13165
13166 2006-07-23  Bruno Haible  <bruno@clisp.org>
13167
13168         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
13169         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
13170         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
13171         gl_linked_remove_at): Use it.
13172
13173 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
13174         and Simon Josefsson <jas@extundo.com>
13175
13176         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
13177
13178         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
13179
13180 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
13181
13182         * modules/close-stream: New file.
13183         * modules/closeout (Description): Make it clear that it exits
13184         with a diagnostic on error.
13185         (Depends-on): Add close-stream.  Remove fpending, stdbool.
13186         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
13187
13188 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
13189
13190         * m4/close-stream.m4: New file.
13191
13192 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
13193
13194         * lib/close-stream.c, lib/close-stream.h: New files.
13195
13196 2006-07-22  Bruno Haible  <bruno@clisp.org>
13197
13198         Merge from GNU gettext 0.15.
13199
13200         2006-05-01  Bruno Haible  <bruno@clisp.org>
13201
13202                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
13203
13204         2006-07-22  Bruno Haible  <bruno@clisp.org>
13205
13206                 * modules/javaversion: New file.
13207                 * MODULES.html.sh (Java): Add javaversion.
13208
13209         2006-03-12  Bruno Haible  <bruno@clisp.org>
13210
13211                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
13212
13213         2005-12-04  Bruno Haible  <bruno@clisp.org>
13214
13215                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
13216                 (untested).
13217
13218         2006-06-21  Bruno Haible  <bruno@clisp.org>
13219
13220                 Avoid warnings from recent versions of mcs.
13221                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
13222                 -o, -L, -r any more. Use options documented since mcs-1.0
13223                 instead. Similarly for -g.
13224
13225         2005-12-04  Bruno Haible  <bruno@clisp.org>
13226
13227                 * build-aux/csharpcomp.sh.in: Suffix for resources is
13228                 .resources, not .resource.
13229
13230         2005-07-09  Bruno Haible  <bruno@clisp.org>
13231
13232                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
13233                 add a .dll suffix.
13234                 Reported by Mark Junker <mjscod@gmx.de>.
13235
13236         2006-07-22  Bruno Haible  <bruno@clisp.org>
13237
13238                 * modules/gettext: Upgrade to gettext-0.15.
13239                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
13240                 m4/visibility.m4.
13241                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
13242
13243 2006-07-22  Bruno Haible  <bruno@clisp.org>
13244
13245         Merge from GNU gettext 0.15.
13246
13247         2006-03-25  Bruno Haible  <bruno@clisp.org>
13248
13249                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
13250
13251         2006-07-21  Bruno Haible  <bruno@clisp.org>
13252
13253                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
13254                 "1.1".
13255
13256         2006-05-09  Bruno Haible  <bruno@clisp.org>
13257
13258                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
13259                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
13260                 for the conftestver execution.
13261
13262         2006-05-01  Bruno Haible  <bruno@clisp.org>
13263
13264                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
13265                 optional target-version argument. Verify that the compiler
13266                 groks source of the specified source-version, or add -source
13267                 option as necessary. Verify that the compiler produces
13268                 bytecode in the specified target-version, or add -target and
13269                 -source options as necessary. Make the result of the test
13270                 available as variable CONF_JAVAC. Also log error output in
13271                 config.log.
13272
13273         2006-03-11  Bruno Haible  <bruno@clisp.org>
13274
13275                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
13276
13277         2006-05-09  Bruno Haible  <bruno@clisp.org>
13278
13279                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
13280                 CLASSPATH_SEPARATOR to a semicolon.
13281
13282         2006-03-12  Bruno Haible  <bruno@clisp.org>
13283
13284                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
13285                 available as variable CONF_JAVA, for subsequent autoconf
13286                 tests. Also log error output in config.log.
13287
13288         2006-07-19  Bruno Haible  <bruno@clisp.org>
13289
13290                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
13291                 that getline works on glibc2 systems. Needed to avoid trouble
13292                 in relocatable.c.
13293                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
13294
13295         2005-12-04  Bruno Haible  <bruno@clisp.org>
13296
13297                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
13298                 launcher (untested).
13299
13300         2005-12-04  Bruno Haible  <bruno@clisp.org>
13301
13302                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
13303
13304         2006-07-22  Bruno Haible  <bruno@clisp.org>
13305
13306                 * gettext.m4: Update from GNU gettext-0.15.
13307                 * nls.m4: Likewise.
13308                 * po.m4: Likewise.
13309                 * inttypes-pri.m4: Likewise.
13310                 * inttypes-h.m4: Renamed from inttypes.m4.
13311                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
13312
13313 2006-07-22  Bruno Haible  <bruno@clisp.org>
13314
13315         Merge from GNU gettext 0.15.
13316
13317         2005-07-05  Bruno Haible  <bruno@clisp.org>
13318
13319                 * printf-args.c (printf_fetchargs): Work around broken
13320                 definition of wint_t on mingw.
13321
13322         2005-02-12  Bruno Haible  <bruno@clisp.org>
13323
13324                 * xallocsa.h: Add extern "C" for C++.
13325
13326         2006-05-17  Bruno Haible  <bruno@clisp.org>
13327
13328                 Cygwin portability.
13329                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
13330
13331         2006-04-30  Bruno Haible  <bruno@clisp.org>
13332
13333                 * progreloc.c: Include <mach-o/dyld.h> if available.
13334                 (find_executable): Use _NSGetExecutablePath when possible.
13335
13336         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
13337
13338                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
13339                 function.
13340
13341         2005-12-29  Bruno Haible  <bruno@clisp.org>
13342
13343                 * progreloc.c (set_program_name_and_installdir): Fix
13344                 compilation error.
13345
13346         2005-12-04  Bruno Haible  <bruno@clisp.org>
13347
13348                 Cygwin portability.
13349                 * progreloc.c: Include <windows.h> also on Cygwin.
13350                 (find_executable): Add support for Cygwin.
13351                 (set_program_name_and_installdir): Handle also platforms with
13352                 nonempty EXEEXT.
13353
13354         2006-07-11  Bruno Haible  <bruno@clisp.org>
13355
13356                 * javacomp.c: Fix a comment.
13357                 Reported by Jim Meyering.
13358
13359         2006-04-30  Bruno Haible  <bruno@clisp.org>
13360
13361                 * javacomp.h (compile_java_class): Add source_version,
13362                 target_version arguments.
13363                 * javacomp.c: Rewritten to choose only a compiler that
13364                 respects the specified source_version and target_version.
13365
13366         2006-06-27  Bruno Haible  <bruno@clisp.org>
13367
13368                 Assume correct S_ISDIR macro.
13369                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
13370
13371         2006-07-22  Bruno Haible  <bruno@clisp.org>
13372
13373                 * javaversion.h: New file, from GNU gettext.
13374                 * javaversion.c: New file, from GNU gettext.
13375                 * javaversion.java: New file, from GNU gettext.
13376                 * javaversion.class: New file, from GNU gettext.
13377
13378         2006-05-17  Bruno Haible  <bruno@clisp.org>
13379
13380                 Cygwin portability.
13381                 * javaexec.c (execute_java_class): Test for jview program
13382                 also on Cygwin.
13383
13384         2006-04-09  Bruno Haible  <bruno@clisp.org>
13385
13386                 * fatal-signal.c: Don't include string.h.
13387                 (at_fatal_signal): Use a copying loop instead of memcpy.
13388
13389         2005-12-04  Bruno Haible  <bruno@clisp.org>
13390
13391                 * csharpexec.c: Add support for 'clix' launcher (untested).
13392                 (execute_csharp_using_sscli): New function.
13393                 (execute_csharp_program): Call it.
13394
13395         2006-06-21  Bruno Haible  <bruno@clisp.org>
13396
13397                 Avoid warnings from recent versions of mcs.
13398                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
13399                 -o, -L, -r any more. Use options documented since mcs-1.0
13400                 instead. Similarly for -g.
13401
13402         2005-07-09  Bruno Haible  <bruno@clisp.org>
13403
13404                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
13405                 add a .dll suffix.
13406                 Reported by Mark Junker <mjscod@gmx.de>.
13407
13408         2006-06-17  Bruno Haible  <bruno@clisp.org>
13409
13410                 * config.charset: Update for NetBSD 3.0.
13411
13412         2006-05-17  Bruno Haible  <bruno@clisp.org>
13413
13414                 Cygwin portability.
13415                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
13416
13417         2006-05-16  Bruno Haible  <bruno@clisp.org>
13418
13419                 * localcharset.c [CYGWIN]: Include <windows.h>.
13420                 (get_charset_aliases): For Cygwin, return the same CPxxx
13421                 aliases list as under WIN32.
13422                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
13423                 the environment variables. Fall back to GetACP().
13424
13425         2006-04-05  Bruno Haible  <bruno@clisp.org>
13426
13427                 * config.charset: Update Juan Manuel Guerrero's address.
13428
13429         2005-02-12  Bruno Haible  <bruno@clisp.org>
13430
13431                 * allocsa.h: Add extern "C" for C++.
13432
13433         2005-02-10  Bruno Haible  <bruno@clisp.org>
13434
13435                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
13436                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
13437
13438         2006-07-22  Bruno Haible  <bruno@clisp.org>
13439
13440                 * gettext.h: Update to GNU gettext-0.15.
13441
13442 2006-07-22  Bruno Haible  <bruno@clisp.org>
13443
13444         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
13445         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
13446         lib-prefix.m4, longdouble.m4, ssize_t.m4.
13447
13448 2006-07-21  Eric Blake  <ebb9@byu.net>
13449
13450         * modules/stdlib-safer: New file.
13451         * MODULES.html.sh (File stream based Input/Output): Add
13452         stdlib-safer.
13453
13454 2006-07-21  Eric Blake  <ebb9@byu.net>
13455
13456         * lib/stdlib-safer.h: New file from coreutils, required by
13457         stdlib--.h.
13458
13459 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
13460
13461         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
13462
13463 2006-07-20  Bruno Haible  <bruno@clisp.org>
13464
13465         * gnulib-tool: Recognize new option --assume-autoconf.
13466         (autoconf_minversion): New variable.
13467         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
13468
13469 2006-07-20  Bruno Haible  <bruno@clisp.org>
13470
13471         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
13472
13473 2006-07-19  Derek R. Price  <derek@ximbiot.com>
13474
13475         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
13476         Reindent and repaginate.
13477
13478 2006-07-19  Derek Price  <derek@ximbiot.com>
13479
13480         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
13481         Correct grammar.
13482
13483 2006-07-17  Bruno Haible  <bruno@clisp.org>
13484
13485         * modules/list: New file.
13486         * modules/array-list: New file.
13487         * modules/carray-list, modules/carray-list-tests: New files.
13488         * modules/linked-list, modules/linked-list-tests: New files.
13489         * modules/avltree-list, modules/avltree-list-tests: New files.
13490         * modules/rbtree-list, modules/rbtree-list-tests: New files.
13491         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
13492         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
13493         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
13494         * modules/oset: New file.
13495         * modules/array-oset: New file.
13496         * modules/avltree-oset, modules/avltree-oset-tests: New files.
13497         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
13498         * tests/test-carray_list.c: New file.
13499         * tests/test-linked_list.c: New file.
13500         * tests/test-avltree_list.c: New file.
13501         * tests/test-rbtree_list.c: New file.
13502         * tests/test-linkedhash_list.c: New file.
13503         * tests/test-avltreehash_list.c: New file.
13504         * tests/test-rbtreehash_list.c: New file.
13505         * tests/test-avltree_oset.c: New file.
13506         * tests/test-rbtree_oset.c: New file.
13507         * MODULES.html.sh (Container data structures): New section.
13508
13509 2006-07-17  Bruno Haible  <bruno@clisp.org>
13510
13511         * m4/gl_list.m4: New file.
13512
13513 2006-07-17  Bruno Haible  <bruno@clisp.org>
13514
13515         * lib/gl_list.h: New file.
13516         * lib/gl_list.c: New file.
13517         * lib/gl_array_list.h: New file.
13518         * lib/gl_array_list.c: New file.
13519         * lib/gl_carray_list.h: New file.
13520         * lib/gl_carray_list.c: New file.
13521         * lib/gl_linked_list.h: New file.
13522         * lib/gl_linked_list.c: New file.
13523         * lib/gl_anylinked_list1.h: New file.
13524         * lib/gl_anylinked_list2.h: New file.
13525         * lib/gl_avltree_list.h: New file.
13526         * lib/gl_avltree_list.c: New file.
13527         * lib/gl_anyavltree_list1.h: New file.
13528         * lib/gl_anyavltree_list2.h: New file.
13529         * lib/gl_rbtree_list.h: New file.
13530         * lib/gl_rbtree_list.c: New file.
13531         * lib/gl_anyrbtree_list1.h: New file.
13532         * lib/gl_anyrbtree_list2.h: New file.
13533         * lib/gl_anytree_list1.h: New file.
13534         * lib/gl_anytree_list2.h: New file.
13535         * lib/gl_linkedhash_list.h: New file.
13536         * lib/gl_linkedhash_list.c: New file.
13537         * lib/gl_anyhash_list1.h: New file.
13538         * lib/gl_anyhash_list2.h: New file.
13539         * lib/gl_avltreehash_list.h: New file.
13540         * lib/gl_avltreehash_list.c: New file.
13541         * lib/gl_rbtreehash_list.h: New file.
13542         * lib/gl_rbtreehash_list.c: New file.
13543         * lib/gl_anytreehash_list1.h: New file.
13544         * lib/gl_anytreehash_list2.h: New file.
13545
13546         * lib/gl_oset.h: New file.
13547         * lib/gl_oset.c: New file.
13548         * lib/gl_array_oset.h: New file.
13549         * lib/gl_array_oset.c: New file.
13550         * lib/gl_avltree_oset.h: New file.
13551         * lib/gl_avltree_oset.c: New file.
13552         * lib/gl_rbtree_oset.h: New file.
13553         * lib/gl_rbtree_oset.c: New file.
13554         * lib/gl_anytree_oset.h: New file.
13555
13556 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
13557
13558         * m4/mkancesdirs.m4: New file.
13559         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
13560         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
13561         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
13562         it.
13563
13564 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
13565
13566         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
13567         * lib/mkancesdirs.h: New files.
13568         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
13569         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
13570         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
13571         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
13572         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
13573         callers changed.  Revamp internals significantly, by not
13574         attempting to create directories that are temporarily more
13575         permissive than the final results.  Do not attempt to use
13576         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
13577         This removes some race conditions, fixes some bugs, and simplifies
13578         things.  Use new dirchownmod function to do owner and mode changes.
13579         * lib/mkdir-p.h: Likewise.
13580         * lib/modechange.c (octal_to_mode): New function.
13581         (struct mode_change): New member mentioned.
13582         (make_node_op_equals): New arg mentioned.  All callers changed.
13583         (mode_compile): Keep track of which mode bits the user has explicitly
13584         mentioned.
13585         (mode_adjust): New arg DIR, so that we implement the X op correctly.
13586         New arg PMODE_BITS, to keep track of which mode bits the user
13587         mentioned; it treats S_ISUID and S_ISGID speciall.
13588         All callers changed.
13589         * lib/modechange.h: Likewise.
13590
13591 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
13592
13593         * MODULES.html.sh: Add mkancestors.
13594         * modules/mkancesdirs: New module.
13595         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
13596         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
13597         The chdir-safer and afs files are now orphans; I'll remove them
13598         unless someone speaks up.
13599         Add lib/dirchownmod.c, lib/dirchownmod.h.
13600         (Depends-on): Remove alloca, chown, save-cwd, dirname.
13601         Add lchown, mkancesdirs.
13602         (Maintainer): Add self.
13603
13604 2006-07-15  Karl Berry  <karl@gnu.org>
13605
13606         * gnulib-tool: help message wording/arrangement.
13607
13608 2006-07-14  Simon Josefsson  <jas@extundo.com>
13609
13610         * doc/gnulib.texi (Libtool and Windows): New section.
13611
13612 2006-07-12  Simon Josefsson  <jas@extundo.com>
13613
13614         * modules/gendocs (License): Fix license, approved by Karl.
13615
13616 2006-07-12  Eric Blake  <ebb9@byu.net>
13617
13618         * MODULES.html.sh: Add gendocs.
13619
13620 2006-07-11  Eric Blake  <ebb9@byu.net>
13621
13622         * modules/fdl: New module, to install doc/fdl.texi.
13623         * MODULES.html.sh: Add new section for documentation modules.
13624         * gnulib-tool: Avoid space-tab.
13625         (--doc-base): New option, to manage files from doc.
13626
13627 2006-07-11  Eric Blake  <ebb9@byu.net>
13628
13629         * m4/absolute-header.m4: Fix comments to match recent change.
13630
13631 2006-07-11  Eric Blake  <ebb9@byu.net>
13632
13633         * gnulib-tool: List --doc-base before --tests-base.
13634
13635 2006-07-11  Derek R. Price  <derek@ximbiot.com>
13636
13637         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
13638
13639 2006-07-11  Bruno Haible  <bruno@clisp.org>
13640
13641         * README: Mention where to put documentation.
13642
13643 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13644
13645         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
13646
13647 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
13648
13649         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
13650         to stdint.m4.
13651
13652 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
13653
13654         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
13655         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
13656         "no/such/file/stdint.h" when there is no such file, so that
13657         the resulting C code can be parsed by dodgy compilers.
13658         Problems reported by Bob Proulx.
13659
13660 2006-07-10  Derek R. Price  <derek@ximbiot.com>
13661
13662         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
13663         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
13664         macros into the GNU _D_EXACT_NAMLEN.
13665         * lib/savedir.c:  Likewise.
13666         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
13667
13668 2006-07-10  Derek R. Price  <derek@ximbiot.com>
13669         and Paul Eggert  <eggert@cs.ucla.edu>
13670
13671         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
13672         * m4/savedir.m4:
13673         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
13674         macros into the GNU _D_EXACT_NAMLEN.
13675
13676 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
13677
13678         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
13679         around the absolute name, to work around a problem with the HP-UX
13680         11.23 native C compiler, reported by Bob Proulx.
13681
13682 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
13683
13684         * doc/maintain.texi, make-stds.texi: Sync from
13685         <http://savannah.gnu.org/projects/gnustandards>.
13686
13687 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
13688
13689         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
13690
13691 2006-07-09  Jim Meyering  <jim@meyering.net>
13692
13693         * m4/glob.m4: Remove a doubled word in a comment.
13694
13695 2006-07-09  Jim Meyering  <jim@meyering.net>
13696
13697         * lib/argp-pv.c: Remove a doubled word in a comment.
13698         * lib/check-version.c (check_version): Likewise.
13699         * lib/javacomp.c (compile_java_class): Likewise.
13700
13701 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
13702
13703         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
13704         for the benefit of people using Autoconf 2.60.  If you want to
13705         support older Autoconf versions you can copy m4/onceonly_2_57.m4
13706         (or m4/onceonly.m4, if pre-2.57) manually.
13707
13708 2006-07-08  Jim Meyering  <jim@meyering.net>
13709
13710         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
13711         comment.
13712         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
13713         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
13714         comment.
13715
13716 2006-07-08  Jim Meyering  <jim@meyering.net>
13717
13718         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
13719
13720 2006-07-07  Simon Josefsson  <jas@extundo.com>
13721
13722         * tests/test-crc.c: Change expected crc value, the test vector
13723         were probably computed using the old broken crc.c?
13724
13725 2006-07-06  Simon Josefsson  <jas@extundo.com>
13726
13727         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
13728         now the canonical place for the M4 file).
13729
13730         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
13731         from the sys_socket dependency now.
13732
13733         * modules/inet_pton (Files): Ditto.
13734
13735         * modules/inet_ntop (Files): Ditto.
13736
13737 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
13738
13739         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
13740         not gl_PREREQ_GETUSERSHELL.
13741
13742 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13743
13744         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
13745         with only one argument, for Autoconf 2.60.
13746         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
13747         expand to nothing, so add a shell command to avoid syntax error.
13748         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
13749
13750 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13751
13752         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
13753
13754 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
13755
13756         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
13757         no longer needed.  Check for isblank decl.
13758         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
13759         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
13760         of existence.
13761
13762 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
13763
13764         * lib/getloadavg.c: Use __VMS, not VMS.
13765         * lib/getopt.c: Likewise.
13766         * lib/getpagesize.h: Likewise.
13767         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
13768         and probably does not work.
13769
13770 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
13771
13772         * lib/.cppi-disable: Add wcwidth.
13773         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
13774         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
13775         (ISGRAPH): Remove.  All uses changed to isgraph.
13776         (FOLD) [!defined _LIBC]: Remove special case.
13777         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
13778         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
13779         HAVE_ISBLANK.
13780         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
13781         case.
13782
13783 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
13784
13785         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
13786         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
13787         brackets.  Other minor changes to suppress some compiler
13788         warnings.
13789
13790 2006-07-06  Derek R. Price  <derek@ximbiot.com>
13791         and Paul Eggert  <eggert@cs.ucla.edu>
13792
13793         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
13794         of invoking obsolescent AC_HEADER_DIRENT macro.
13795         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
13796         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
13797         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
13798         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
13799         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
13800         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
13801         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
13802         * m4/readdir.m4: Remove; no longer needed.
13803
13804 2006-07-06  Derek R. Price  <derek@ximbiot.com>
13805         and Paul Eggert  <eggert@cs.ucla.edu>
13806
13807         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
13808         Don't worry about this obsolete case any more.
13809         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
13810         directories.
13811         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
13812         worry about this obsolete case any more.
13813         * lib/fts.c: Likewise.
13814         * lib/getcwd.c: Likewise.
13815         * lib/glob.h: Likewise.
13816         * lib/savedir.c: Likewise.
13817
13818 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
13819
13820         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
13821         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
13822         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
13823         needed.
13824         All uses removed.
13825         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13826         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
13827         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
13828         needed.
13829         * m4/getdate.m4 (gl_GETDATE): Likewise.
13830         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
13831         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
13832         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
13833         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13834         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
13835         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
13836         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
13837         needed.
13838
13839 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
13840
13841         * lib/memcasecmp.c: Include <limits.h>.
13842         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
13843         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
13844         Don't assume isdigit succeeds only on '0' through '9'.
13845
13846 2006-07-05  Eric Blake  <ebb9@byu.net>
13847
13848         * modules/getaddrinfo (Depends-on): Add snprintf.
13849
13850 2006-07-05  Eric Blake  <ebb9@byu.net>
13851
13852         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
13853         to avoid 'header present but could not be compiled' on cygwin.
13854
13855 2006-07-05  Eric Blake  <ebb9@byu.net>
13856
13857         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
13858         missing from netdb.h.
13859         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
13860
13861 2006-07-05  Derek R. Price  <derek@ximbiot.com>
13862
13863         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
13864         no longer needed.
13865         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
13866         * m4/getdate.m4 (gl_GETDATE): Likewise.
13867         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
13868         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
13869         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
13870         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
13871         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
13872
13873 2006-07-05  Derek R. Price  <derek@ximbiot.com>
13874
13875         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
13876         All uses of is_space replaced by isspace.
13877         * lib/exit.h: Don't talk about STDC_HEADERS.
13878         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
13879         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
13880         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
13881         replaced by isprint etc.
13882         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
13883         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
13884         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
13885         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
13886         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
13887         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
13888
13889 2006-07-05  Bruno Haible  <bruno@clisp.org>
13890
13891         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
13892         the function exists, before testing against AIX.
13893         Reported by Martin Lambers <marlam@marlam.de>.
13894
13895 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
13896
13897         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
13898         From Mark D. Baushke.
13899
13900 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
13901
13902         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
13903         to the absolute name, not just one, to bypass Sun C 5.8's
13904         "warning: #include of /usr/include/... may be non-portable".
13905
13906 2006-07-04  Eric Blake  <ebb9@byu.net>
13907
13908         * modules/dirname-tests: New test module.
13909         * tests/test-dirname.c: New file, replacing dirname.c
13910         TEST_DIRNAME section that was recently deleted.
13911
13912 2006-07-04  Bruno Haible  <bruno@clisp.org>
13913
13914         Assume ANSI C header files and <ctype.h> functions.
13915         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
13916         (mbsnwidth): Use isprint, iscntrl instead.
13917
13918 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13919
13920         Merge from coreutils.
13921         * MODULES.html.sh: Add xstrtold.
13922         * modules/xstrtold: New file.
13923         * modules/cycle-check (Files): Add lib/same-inode.h.
13924         * modules/dirname (Files): Add m4/double-slash-root.m4.
13925         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
13926         * modules/mkdir-p (Files): Add lib/same-inode.h.
13927         * modules/same (Files): Add lib/same-inode.h.
13928
13929 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
13930
13931         * m4/absolute-header.m4: Renamed from full-header-path.m4.
13932         This is to keep the terminology clean; POSIX talks about
13933         "absolute pathnames", not "full pathnames", but the GNU
13934         Coding Standards say to use "path" for something else;
13935         so use "absolute" to keep both sides happy.
13936         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
13937         Set gl_absolute_header, not gl_full_header_path.
13938         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
13939         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
13940         All uses changed.
13941
13942         Merge from coreutils.
13943
13944         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
13945
13946         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
13947         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
13948         want to require the building of c-strtod.o.
13949         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
13950         needs -lm directly.
13951         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
13952
13953         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
13954
13955         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
13956         --as-needed option if available.  Problem reported by Albert Chin in
13957         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
13958         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
13959         cc merely issues a bunch of annoying warnings for --as-needed
13960         (this problem was reported by Bob Proulx).  Also, try linking with
13961         -lm to detect a bug in binutils 2.16 (this problem was reported
13962         by Ralf Wildenhues).
13963
13964         2006-06-18  Jim Meyering  <jim@meyering.net>
13965
13966         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
13967         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
13968         macro.
13969         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
13970         also check for glibc-2.4's abort-inducing bug.
13971
13972         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
13973         Low-probability clean-up should be to use rmdir to get rid of
13974         the just-created directory, not unlink.
13975
13976         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
13977         configure fail, and request a bug report to inform us about it.
13978         Add a comment that, barring reports to the contrary, in 2007 we'll
13979         assume ftruncate is universally available.
13980
13981         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
13982
13983         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
13984
13985         2006-03-12  Jim Meyering  <jim@meyering.net>
13986
13987         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
13988         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
13989         * m4/same.m4 (gl_SAME): Likewise.
13990         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
13991
13992         2006-03-11  Eric Blake  <ebb9@byu.net>
13993
13994         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
13995         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
13996         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
13997         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
13998
13999 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
14000
14001         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
14002         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
14003         reported by Mark D. Baushke, one in
14004         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
14005
14006         Merge from coreutils.
14007
14008         * lib/.cppi-disable: Add stdint_.h.
14009         * lib/.cvsignore: Add stdint.h.
14010
14011         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
14012
14013         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
14014         both double and long double versions.
14015         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
14016         * lib/xstrtold.c: New file.
14017         * lib/xstrtod.h (xstrtold): New decl.
14018
14019         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
14020
14021         * lib/filemode.c (setst): Remove.
14022         (strmode): Rewrite to avoid setst.  This makes the code shorter,
14023         (arguably) clearer, and the generated code is a bit smaller on my
14024         Debian GNU/Linux stable x86 host.
14025
14026         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
14027
14028         * lib/filemode.c: Include "filemode.h" first, to test the interface.
14029         Assume that filemode.h includes sys/types.h and sys/stat.h.
14030         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
14031         (ftypelet): Reorder to put common cases first, for efficiency.
14032         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
14033         to do 'M'.
14034         (strmode): Renamed from mode_string, and now stores 12 bytes instead
14035         of 10, for compatibility with FreeBSD.  All callers changed.
14036         (filemodestring): Now stores 12 bytes instead of 10, and sets file
14037         types that can't be deduced solely from st_mode.  First arg is now a
14038         const pointer.
14039         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
14040         (strmode): Renamed from mode_string.
14041         (filemodestring): New decl.
14042         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
14043         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
14044         needed.
14045         (S_ISPORT, S_ISWHT): New macros, if not already defined.
14046
14047         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
14048
14049         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
14050         fsusage.h now does that.  Include fsusage.h first, to test interface.
14051         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
14052         at most one method (the old code could have generated decls that
14053         didn't conform to C89, not that this was ever exercised).
14054         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
14055
14056         2006-03-19  Jim Meyering  <jim@meyering.net>
14057
14058         Work even in a chroot where d_ino values for entries in "/"
14059         don't match the stat.st_ino values for the same names.
14060         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
14061         number, iterate through all entries again, using lstat instead.
14062         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
14063         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
14064
14065         * lib/getcwd.c (__getcwd): Clarify a comment.
14066         Use memcpy in place of a call to strcpy.
14067
14068         2006-03-12  Jim Meyering  <jim@meyering.net>
14069
14070         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
14071         matches that of the current directory (which we're about to chdir ".."
14072         out of), then save the dev-ino of the parent, instead.
14073
14074         * lib/same-inode.h (SAME_INODE): New file/macro.
14075         * lib/chdir-safer.c (SAME_INODE): Remove definition.
14076         Include "same-inode.h", instead.
14077         * lib/same.c: Likewise.
14078         * lib/cycle-check.h: Include "same-inode.h".
14079         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
14080         * lib/cycle-check.c (SAME_INODE): Remove definition.
14081         * lib/root-dev-ino.h: Include "same-inode.h".
14082
14083         2006-03-11  Eric Blake  <ebb9@byu.net>
14084
14085         * lib/same.c (same_name): s/base_name/last_component/
14086         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
14087         * lib/filenamecat.c (file_name_concat): Likewise.
14088
14089         2006-03-11  Eric Blake  <ebb9@byu.net>,
14090                     Paul Eggert  <eggert@cs.ucla.edu>
14091
14092         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
14093         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
14094         drive prefix.
14095         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
14096         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
14097         (last_component): New method.
14098         * lib/dirname.c (dir_len): Determine when drive letters need a
14099         subsequent slash.  Preserve // when it is special.
14100         (dir_name): Don't append dot when drive letter is absolute.
14101         [TEST_DIRNAME]: Move into a full-blown gnulib test.
14102         * lib/basename.c (base_name): New semantics - malloc the result.
14103         Preserve // when it is special.  Preserve relative files that look
14104         like drive letters.
14105         (base_len): Preserve // when it is special.
14106         (last_component): New method, similar to old base_name semantics.
14107         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
14108         base_name.  Strip redundant slashes from ///.
14109
14110 2006-07-03  Jim Meyering  <jim@meyering.net>
14111
14112         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
14113         macro is used before the first cycle_check call.
14114
14115 2006-07-03  Eric Blake  <ebb9@byu.net>
14116
14117         * modules/dirname (Depends-on): Add xstrndup.
14118
14119 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
14120
14121         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
14122         test cases, so that config.log is a bit easier to follow.
14123
14124 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
14125
14126         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
14127         both are 64 bits, since this seems to be the tradition, and this
14128         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
14129         we ever run into a host that prefers long long to long in this
14130         case, we'll need another configure-time test.  Problem reported by
14131         Jim Meyering.
14132
14133 2006-07-02  Eric Blake  <ebb9@byu.net>
14134
14135         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
14136
14137 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
14138
14139         * modules/inttypes (Depends-on): No longer depends on stdint.
14140         * modules/stdint (Description): Say more about assumptions.
14141         Say that the fast types might differ.  Say macros are used.
14142         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
14143         (Makefile.am): Revise list of substituted symbols to match
14144         new stdint.m4.
14145         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
14146         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
14147         * tests/test-stdint.c (verify_same_types)
14148         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
14149         the code conforms to C99/C89.
14150         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
14151         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
14152
14153 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
14154
14155         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
14156         but fix a bug, by requiring at least 64 bits.
14157         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
14158         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
14159         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
14160         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
14161
14162         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
14163         changes.  Make 2.59 a prerequisite.  Check and substitute for
14164         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
14165         inttypes.h.  Do not use special include files; just use the
14166         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
14167         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
14168         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
14169         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
14170         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
14171         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
14172         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
14173         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
14174         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
14175         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
14176         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
14177         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
14178         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
14179         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
14180         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
14181         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
14182         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
14183         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
14184         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
14185         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
14186         WINT_MAX.  Check for C99 conformance more strictly, by detecting
14187         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
14188         not check for things that C99 does not require, e.g., int8_t.  If
14189         a test isn't needed unless <stdint.h> isn't working, and is
14190         unlikely to be needed for any other reason, then don't do it
14191         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
14192         size_t, since we assume C89 freestanding at least.  Do not check
14193         for sig_atomic_t, wchar_t, or wint_t, since the code now does
14194         the right thing even if the types are not defined.  Instead use:
14195         (gl_STDINT_TYPE_PROPERTIES): New macro.
14196         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
14197         testing whether <sys/types.h> clashes, as Autoconf does this for
14198         us now.  All uses removed.
14199         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
14200         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
14201         (gl_CHECK_TYPE_SAME):
14202         Remove; no longer needed.
14203         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
14204         exists, since we'll return 0 anyway in that case.
14205         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
14206
14207 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
14208
14209         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
14210         possible collision with system files.
14211         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
14212         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
14213         WCHAR_MIN and WCHAR_MAX in this case.
14214         (<stddef.h>): Do not include; no longer needed.
14215         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
14216         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
14217         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
14218         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
14219         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
14220         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
14221         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
14222         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
14223         !defined(__c99))]: Include in this case too, since it's harmless
14224         now.
14225         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
14226         dangerous to do so.
14227         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
14228         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
14229         (_STDINT_MIN, _STDINT_MAX): New macros.
14230         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
14231         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
14232         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
14233         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
14234         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
14235         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
14236         macros, not typedefs; this simplifies things quite a bit.
14237         Use long int for all types narrower than int64_t.
14238         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
14239         Define in terms of long long int or int64_t or long int,
14240         not int64_t or int32_t.  This saves some compile-time testing.
14241         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
14242         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
14243         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
14244         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
14245         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
14246         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
14247         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
14248         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
14249         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
14250         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
14251         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
14252         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
14253         undef any previous version and define our own version, for
14254         simplicity and consistency with the new macros for types.
14255         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
14256         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
14257         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
14258         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
14259         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
14260         @WINT_T_SUFFIX@ to keep things simple here.
14261         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
14262         Simplify by assuming typical 8/16/32/64 host, since we're
14263         already doing that elsewhere anyway.
14264         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
14265         and assume long long int is 64 bits if available.  This
14266         speeds up 'configure'.
14267
14268 2006-07-01  Eric Blake  <ebb9@byu.net>
14269
14270         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
14271         Reported by Andreas Buening.
14272
14273 2006-07-01  Eric Blake  <ebb9@byu.net>
14274
14275         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
14276
14277 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
14278
14279         * lib/getaddrinfo.c: fixed typo
14280
14281 2006-06-29  Jim Meyering  <jim@meyering.net>
14282
14283         * modules/strftime (Maintainer): Add my name, since with the
14284         FPRINTFTIME changes strftime.c has forked from glibc.
14285
14286 2006-06-29  Eric Blake  <ebb9@byu.net>
14287
14288         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
14289
14290 2006-06-29  Eric Blake  <ebb9@byu.net>
14291
14292         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
14293
14294 2006-06-29  Eric Blake  <ebb9@byu.net>
14295
14296         * lib/stat_.h: New file.
14297
14298 2006-06-29  Eric Blake  <ebb9@byu.net>
14299
14300         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
14301         unused static function.
14302
14303 2006-06-29  Eric Blake  <ebb9@byu.net>
14304
14305         * doc/functions.texi (Function Portability): Document missing lstat
14306         on mingw.
14307
14308 2006-06-29  Eric Blake  <ebb9@byu.net>
14309
14310         * MODULES.html.sh: Add sys_stat.
14311         * modules/sys_stat: New module.
14312         * modules/mkstemp (Depends-on): Add sys_stat.
14313
14314 2006-06-29  Derek R. Price  <derek@ximbiot.com>
14315
14316         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
14317
14318 2006-06-29  Derek R. Price  <derek@ximbiot.com>
14319
14320         * m4/c-bs-a.m4: Removed.
14321
14322 2006-06-29  Derek R. Price  <derek@ximbiot.com>
14323
14324         * lib/strftime.c: Assume strftime() exists.
14325
14326 2006-06-29  Derek Price  <derek@ximbiot.com>
14327
14328         * modules/c-bs-a: Removed - \a is C89.
14329         * MODULES.html.sh: Remove c-bs-a.
14330
14331 2006-06-29  Bruno Haible  <bruno@clisp.org>
14332
14333         * modules/wcwidth (License): Change to LGPL.
14334
14335 2006-06-28  Simon Josefsson  <jas@extundo.com>
14336
14337         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
14338         on _WIN32.
14339
14340         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
14341         getnameinfo.
14342
14343 2006-06-28  Simon Josefsson  <jas@extundo.com>
14344
14345         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
14346
14347 2006-06-28  Simon Josefsson  <jas@extundo.com>
14348
14349         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
14350         functions there.  It will succeed on Windows XP, but on Windows
14351         2000 and (presumably) earlier, it will fail, and use the internal
14352         re-implementation.
14353         (use_win32_p): New function.
14354         (getaddrinfo): Use strtoul on servname, to support numeric ports.
14355         Support AI_NUMERICSERV to disable getservbyname.
14356         (getnameinfo): New function, only supports
14357         NI_NUMERICHOST|NI_NUMERICSERV for now.
14358
14359         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
14360         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
14361         getnameinfo.
14362
14363 2006-06-28  Eric Blake  <ebb9@byu.net>
14364
14365         * modules/wcwidth: New file.
14366         * modules/mbchar (Depends-on): Add wcwidth.
14367         * modules/mbswidth (Depends-on): Add wcwidth.
14368         * MODULES.html.sh: Add wcwidth.
14369
14370 2006-06-28  Eric Blake  <ebb9@byu.net>
14371
14372         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
14373         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
14374
14375 2006-06-28  Eric Blake  <ebb9@byu.net>
14376
14377         * lib/xvasprintf.h: Fix comments.
14378
14379 2006-06-28  Eric Blake  <ebb9@byu.net>
14380
14381         * lib/mbchar.h (wcwidth): Include wcwidth.h.
14382         * lib/mbswidth.c (wcwidth): Move from here...
14383         * lib/wcwidth.h: ...to this new file.
14384
14385 2006-06-28  Derek R. Price  <derek@ximbiot.com>
14386
14387         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
14388
14389         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
14390         it's obsolete.
14391         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
14392
14393 2006-06-28  Derek R. Price  <derek@ximbiot.com>
14394
14395         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
14396         Autoconf 2.60 says this stuff was obsolete.
14397
14398 2006-06-28  Bruno Haible  <bruno@clisp.org>
14399
14400         * modules/wcwidth (Files): Add m4/wchar_t.m4.
14401
14402 2006-06-28  Bruno Haible  <bruno@clisp.org>
14403
14404         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
14405         gt_TYPE_WCHAR_T.
14406
14407 2006-06-28  Bruno Haible  <bruno@clisp.org>
14408
14409         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
14410         declaration for wcwidth.
14411         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
14412
14413 2006-06-28  Bruno Haible  <bruno@clisp.org>
14414
14415         * lib/mkdtemp.c [MINGW]: Include <io.h>.
14416         (mkdir): Define using _mkdir.
14417
14418 2006-06-28  Bruno Haible  <bruno@clisp.org>
14419
14420         * lib/getaddrinfo.h: Fix POSIX URL.
14421         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
14422         _WIN32.
14423         (use_win32_p): Make static.
14424         (getaddrinfo): Reject service name if it is empty or does not consist
14425         solely of decimal digits, or if its value is > 65535.
14426         (getnameinfo): Remove useless casts.
14427
14428 2006-06-27  Simon Josefsson  <jas@extundo.com>
14429
14430         * modules/sys_select: New file, suggested by Bruno Haible, Paul
14431         Eggert and Martin Lambers.
14432
14433 2006-06-27  Simon Josefsson  <jas@extundo.com>
14434
14435         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
14436         Eggert and Martin Lambers.
14437
14438 2006-06-27  Bruno Haible  <bruno@clisp.org>
14439
14440         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
14441         result to 0, not to empty.
14442         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
14443
14444 2006-06-27  Bruno Haible  <bruno@clisp.org>
14445
14446         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
14447
14448 2006-06-26  Simon Josefsson  <jas@extundo.com>
14449
14450         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
14451         present.
14452
14453 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
14454
14455         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
14456         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
14457         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
14458
14459 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
14460
14461         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
14462
14463 2006-06-26  Bruno Haible  <bruno@clisp.org>
14464
14465         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
14466
14467 2006-06-26  Bruno Haible  <bruno@clisp.org>
14468
14469         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
14470
14471 2006-06-26  Bruno Haible  <bruno@clisp.org>
14472
14473         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
14474         SGI C compiler in pre-C99 mode.
14475         Suggested by Mark D. Baushke and Larry Jones.
14476
14477 2006-06-26  Bruno Haible  <bruno@clisp.org>
14478
14479         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
14480         WCHAR_MAX.
14481         Reported by Mark D. Baushke and Larry Jones.
14482
14483 2006-06-26  Bruno Haible  <bruno@clisp.org>
14484
14485         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
14486         in pre-C99 mode.
14487         Suggested by Mark D. Baushke and Larry Jones.
14488
14489 2006-06-23  Simon Josefsson  <jas@extundo.com>
14490             Bruno Haible  <bruno@clisp.org>
14491
14492         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
14493         Emit mostlyclean-local rule.
14494         (func_emit_tests_Makefile_am): Likewise.
14495         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
14496
14497 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
14498
14499         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
14500
14501 2006-06-23  Bruno Haible  <bruno@clisp.org>
14502
14503         * tests/test-stdint.c: Update to match ISO C 99 Technical
14504         Corrigendum 1.
14505
14506 2006-06-23  Bruno Haible  <bruno@clisp.org>
14507
14508         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
14509
14510 2006-06-23  Bruno Haible  <bruno@clisp.org>
14511
14512         * lib/stdint_.h: Treat IRIX like OpenBSD.
14513
14514 2006-06-23  Bruno Haible  <bruno@clisp.org>
14515
14516         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
14517         ISO C 99 Technical Corrigendum 1.
14518
14519 2006-06-22  Simon Josefsson  <jas@extundo.com>
14520
14521         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
14522         MinGW.
14523
14524 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
14525
14526         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
14527         needed.  Some compiler complained about some of them.  Problem reported
14528         by Larry Jones in
14529         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
14530
14531 2006-06-21  Simon Josefsson  <jas@extundo.com>
14532
14533         * tests/test-getaddrinfo.c: New file.
14534
14535         * modules/getaddrinfo-tests: New file.
14536
14537         * MODULES.html.sh: Add inet_pton.
14538
14539         * modules/inet_pton: New file.
14540
14541 2006-06-21  Simon Josefsson  <jas@extundo.com>
14542
14543         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
14544         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
14545         of using the (limited) gnulib implementation on Windows XP.
14546
14547         * m4/inet_pton.m4: New file.
14548
14549 2006-06-21  Simon Josefsson  <jas@extundo.com>
14550
14551         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
14552         variable.
14553
14554         * lib/socket_.h: Don't define WINVER.
14555
14556         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
14557         slightly modified to work in gnulib.
14558
14559 2006-06-21  Simon Josefsson  <jas@extundo.com>
14560
14561         * doc/gnulib.texi (Windows sockets): Add.
14562
14563 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
14564
14565         * lib/read-file.c (fread_file): Start with buffer allocation of
14566         0 bytes rather than 1 byte; this simplifies the code.
14567         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
14568         code to free buffer and save/restore errno.
14569         (internal_read_file): Remove unused local.
14570
14571 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
14572
14573         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
14574         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
14575         Problem reported by Denis Excoffier in
14576         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
14577
14578 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
14579
14580         * modules/sys_socket, modules/socklen: Include sys/types since
14581         FreeBSD 4.x's sys/socket.h needs it.
14582
14583 2006-06-19  Simon Josefsson  <jas@extundo.com>
14584
14585         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
14586
14587 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
14588
14589         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
14590
14591 2006-06-19  Bruno Haible  <bruno@clisp.org>
14592
14593         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
14594         and FULL_PATH_INTTYPES_H in angle brackets.
14595         Reported by Mark D. Baushke <mdb@gnu.org>.
14596
14597 2006-06-17  Eric Blake  <ebb9@byu.net>
14598
14599         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
14600         errno.
14601
14602 2006-06-17  Bruno Haible  <bruno@clisp.org>
14603
14604         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
14605         <sys/inttypes.h>.
14606
14607 2006-06-17  Bruno Haible  <bruno@clisp.org>
14608
14609         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
14610         whether errno is declared. Assume <errno.h> declares errno.
14611
14612 2006-06-17  Bruno Haible  <bruno@clisp.org>
14613
14614         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
14615
14616 2006-06-17  Bruno Haible  <bruno@clisp.org>
14617
14618         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
14619         problem on Solaris 2.5.1.
14620
14621 2006-06-16  Eric Blake  <ebb9@byu.net>
14622
14623         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
14624         * lib/unicodeio.c [!defined errno]: Likewise.
14625         * lib/strtol.c [!defined errno]: Likewise.
14626         * lib/strtod.c [!defined errno]: Likewise.
14627
14628 2006-06-15  Eric Blake  <ebb9@byu.net>
14629
14630         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
14631
14632 2006-06-15  Eric Blake  <ebb9@byu.net>
14633
14634         * config/srclist.txt (ssize_t.m4): Lose sync.
14635
14636 2006-06-15  Bruno Haible  <bruno@clisp.org>
14637
14638         * modules/stdint (Files): Include m4/full-header-path.m4,
14639         m4/size_max.m4, m4/wchar_t.m4.
14640         (Makefile.am): Many more substitutions.
14641         * modules/stdint-tests: New file.
14642         * tests/test-stdint.c: New file.
14643
14644 2006-06-15  Bruno Haible  <bruno@clisp.org>
14645
14646         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
14647         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
14648         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
14649         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
14650         gl_CHECK_TYPE_SAME): New macros.
14651
14652 2006-06-15  Bruno Haible  <bruno@clisp.org>
14653
14654         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
14655
14656 2006-06-15  Bruno Haible  <bruno@clisp.org>
14657
14658         * lib/stdint_.h: Rewritten to be fully auto-configured.
14659         Fixes bug on HP-UX/IA64.
14660
14661 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
14662
14663         * lib/getdate.y (__attribute__): Don't define if already defined.
14664         Problem reported by Larry Jones.
14665         * lib/utimens.c (__attribute__): Likewise.
14666
14667 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
14668
14669         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
14670         reported by Andreas Schwab.
14671
14672 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14673             Bruno Haible  <bruno@clisp.org>
14674
14675         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
14676         check for the declaration of strnlen and a run test that exposes the
14677         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
14678         rpl_strndup.
14679
14680 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14681             Bruno Haible  <bruno@clisp.org>
14682
14683         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
14684
14685 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14686
14687         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
14688         compile test, for Tru64 4.0D.
14689
14690 2006-05-28  Karl Berry  <karl@gnu.org>
14691
14692         * config/srclist.txt (printf-args.c): lose sync.
14693
14694 2006-05-26  Martin Lambers  <marlam@marlam.de>
14695
14696         * lib/getpass.c: Updates the test for the native W32 API, and adds
14697         missing includes, thus fixing compilation warnings.
14698
14699 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
14700
14701         * lib/exclude.c (exclude_fnmatch): New function.
14702         (excluded_file_name): Call exclude_fnmatch.
14703         * lib/exclude.h (excluded_file_name): New prototype
14704
14705 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
14706
14707         * lib/tempname.c (small_open, large_open): New macros.
14708         (__open, __open64) [!_LIBC]: Remove.
14709         (__gen_tempname): Use small_open and large_open instead of __open
14710         and __open64.  This fixes a portability bug on HP-UX 11.11i
14711         reported by Simon Wing-Tang in
14712         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
14713
14714 2006-05-24  Bruno Haible  <bruno@clisp.org>
14715
14716         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
14717         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
14718         Reported by Thorsten Maerz <torte@netztorte.de> via
14719         Aaron Stone <aaron@serendipity.cx>.
14720
14721 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
14722
14723         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
14724         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
14725         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
14726         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
14727         not really conditional on the cache.
14728         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
14729
14730 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
14731
14732         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
14733         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
14734         (my_usleep): Don't mishandle maximum value.
14735
14736 2006-05-19  Jim Meyering  <jim@meyering.net>
14737
14738         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
14739
14740 2006-05-17  Bruno Haible  <bruno@clisp.org>
14741
14742         Cygwin portability.
14743         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
14744
14745 2006-05-17  Bruno Haible  <bruno@clisp.org>
14746
14747         * lib/stdint_.h: Fix recognition of Cygwin.
14748
14749 2006-05-15  Bruno Haible  <bruno@clisp.org>
14750
14751         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
14752         on libtool patch by Ralf Wildenhues.
14753
14754 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
14755
14756         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
14757         test for C99 conformance; (bool) 0.5 is an integer constant
14758         expression, but (bool) -0.5 is not.  Problem reported by Fedor
14759         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
14760
14761 2006-05-11  Simon Josefsson  <jas@extundo.com>
14762
14763         * m4/xvasprintf.m4: Fix obvious typo.
14764
14765 2006-05-11  Jim Meyering  <jim@meyering.net>
14766
14767         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
14768         James Lemley.
14769
14770 2006-05-10  Simon Josefsson  <jas@extundo.com>
14771
14772         * lib/md4.c: Typo fix, update copyright years.
14773         (K1, K2): Don't use L because it turn computations into 64-bit on
14774         64-bit platforms.
14775
14776 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
14777
14778         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
14779         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
14780         unwanted sign propagation, e.g., on hosts with 64-bit int.
14781         There still are some problems with reeelly weird theoretical hosts
14782         (e.g., 33-bit int) but it's not worth worrying about now.
14783         * lib/sha1.c (rol): Likewise.
14784         (K1, K2, K3, K4): Remove unnecessary L suffix.
14785
14786 2006-05-10  Bruno Haible  <bruno@clisp.org>
14787
14788         * lib/des.c: Cast to avoid warnings.
14789
14790 2006-05-09  Bruno Haible  <bruno@clisp.org>
14791
14792         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
14793         (Depends-on): Depend also on xsize, stdarg.
14794         (configure.ac): Add gl_XVASPRINTF.
14795
14796 2006-05-09  Bruno Haible  <bruno@clisp.org>
14797
14798         * m4/xvasprintf.m4: New file.
14799
14800 2006-05-09  Bruno Haible  <bruno@clisp.org>
14801
14802         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
14803         (EOVERFLOW): Define fallback value.
14804         (xstrcat): New function.
14805         (xvasprintf): Recognize the special case of a string concatenation.
14806
14807 2006-05-08  Eric Blake  <ebb9@byu.net>
14808
14809         * gnulib-tool (func_version): Base copyright year on CVS date.
14810         (func_emit_copyright_notice): New function.
14811         (func_emit_lib_Makefile_am): Use it.
14812         (func_emit_tests_Makefile_am): Likewise.
14813         (func_import): Likewise.
14814
14815 2006-05-08  Bruno Haible  <bruno@clisp.org>
14816
14817         * modules/stdarg: New file.
14818         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
14819
14820 2006-05-08  Bruno Haible  <bruno@clisp.org>
14821
14822         * m4/stdarg.m4: New file, from GNU gettext.
14823
14824 2006-05-08  Bruno Haible  <bruno@clisp.org>
14825
14826         * config/srclist.txt (build-aux/config.rpath): different from latest
14827         release.
14828
14829 2006-05-08  Bruno Haible  <bruno@clisp.org>
14830
14831         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
14832
14833 2006-05-05  Jim Meyering  <jim@meyering.net>
14834
14835         * m4/warning.m4: New file, derived from bison's file by the same name.
14836
14837 2006-05-03  Bruno Haible  <bruno@clisp.org>
14838
14839         * lib/stdint_.h: Shorter URL.
14840         * lib/inttypes.h: Likewise.
14841
14842 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14843
14844         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
14845
14846 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14847
14848         * lib/verify.h: Document the internals better.  Most of this change
14849         was written by Bruno Haible.
14850
14851 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
14852
14853         * doc/verify.texi: New file, partly based on a proposal by
14854         Bruno Haible.
14855
14856 2006-05-02  Bruno Haible  <bruno@clisp.org>
14857
14858         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
14859         test from here...
14860         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
14861
14862 2006-04-29  Bruno Haible  <bruno@clisp.org>
14863
14864         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
14865         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
14866
14867 2006-04-29  Bruno Haible  <bruno@clisp.org>
14868
14869         * gnulib-tool: Make --update option actually work.
14870
14871 2006-04-29  Bruno Haible  <bruno@clisp.org>
14872
14873         * doc/gcd.texi: New file.
14874         * doc/gnulib.texi: Include it.
14875
14876 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
14877
14878         * lib/getdate.y (get_date): When adding relative date, start with the
14879         initial time, not with the result of the first mktime call.
14880
14881 2006-04-25  Bruno Haible  <bruno@clisp.org>
14882
14883         * gnulib-tool (func_import): Output the include directives in three
14884         blocks, sorted separately.
14885         Reported by Ben Pfaff <blp@cs.stanford.edu>.
14886
14887 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
14888
14889         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
14890         to define main with arguments, for C++.  Reported by Eric Blake.
14891         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
14892         Prefer 'int main ()' to 'int main (void)', for C++.
14893         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
14894         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
14895         for 'main', for C99 and C++.
14896
14897 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
14898
14899         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
14900         Don't assume that exit status -1 is valid.
14901         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
14902         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
14903         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
14904         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
14905         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
14906         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
14907         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
14908         functions can be used without declaring them, or that you can
14909         exit with status -1.
14910         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
14911
14912 2006-04-24  Karl Berry  <karl@gnu.org>
14913
14914         * config/srclist.txt (longdouble.m4): sync lost.
14915
14916 2006-04-24  Eric Blake  <ebb9@byu.net>
14917
14918         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
14919
14920 2006-04-24  Bruno Haible  <bruno@clisp.org>
14921
14922         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
14923         poll() implementation in AIX.
14924         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14925
14926 2006-04-24  Bruno Haible  <bruno@clisp.org>
14927
14928         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
14929         assigned exactly once.
14930
14931 2006-04-23  Claudio Fontana  <claudio@gnu.org>
14932             Bruno Haible  <bruno@clisp.org>
14933
14934         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
14935         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
14936         for AM_CPPFLAGS.
14937
14938 2006-04-23  Bruno Haible  <bruno@clisp.org>
14939
14940         * modules/copy-file: Depend on unistd.
14941         * modules/execute: Likewise.
14942         * modules/fatal-signal: Likewise.
14943         * modules/findprog: Likewise.
14944         * modules/mkdtemp : Likewise.
14945         * modules/pipe: Likewise.
14946         * modules/wait-process: Likewise.
14947
14948 2006-04-23  Bruno Haible  <bruno@clisp.org>
14949
14950         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
14951         condition was already detected.
14952         Reported by Ben Pfaff <blp@cs.stanford.edu>.
14953
14954 2006-04-23  Bruno Haible  <bruno@clisp.org>
14955
14956         * lib/copy-file.c: Include <unistd.h> unconditionally.
14957         * lib/execute.c: Likewise.
14958         * lib/fatal-signal.c: Likewise.
14959         * lib/findprog.c: Likewise.
14960         * lib/mkdtemp.c: Likewise.
14961         * lib/pipe.h: Likewise.
14962         * lib/pipe.c: Likewise.
14963         * lib/wait-process.h: Likewise.
14964
14965 2006-04-23  Bruno Haible  <bruno@clisp.org>
14966
14967         * gnulib-tool (func_usage): Fix --import description. Document
14968         --update.
14969         (func_import): Create temporary file in a temporary directory, if
14970         --dry-run is specified. Silence errors from 'grep' when there are no
14971         m4 files in $m4dir.
14972         (func_create_testdir): Silence errors from 'grep' when there are no
14973         m4 files in $m4dir.
14974         Reported by Karl Berry <karl@freefriends.org>.
14975
14976 2006-04-20  Bruno Haible  <bruno@clisp.org>
14977
14978         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
14979         one argument, so that the code will be portable to Autoconf 2.60.
14980         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
14981         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
14982         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
14983
14984 2006-04-19  Derek Price  <derek@ximbiot.com>
14985             Eric Blake  <ebb9@byu.net>
14986
14987         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
14988         rather than "/full/path.h".  Update comment to match.  Shorten &
14989         generalize m4_translit call via AS_TR_CPP.
14990
14991 2006-04-19  Derek Price  <derek@ximbiot.com>
14992             Eric Blake  <ebb9@byu.net>
14993
14994         * lib/inttypes.h: Correct grammar in comment.
14995
14996 2006-04-18  Derek Price  <derek@ximbiot.com>
14997             Paul Eggert  <eggert@cs.ucla.edu>
14998
14999         * modules/inttypes: New file.
15000         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
15001
15002 2006-04-18  Derek Price  <derek@ximbiot.com>
15003             Paul Eggert  <eggert@cs.ucla.edu>
15004
15005         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
15006         New files.
15007
15008 2006-04-18  Derek Price  <derek@ximbiot.com>
15009             Paul Eggert  <eggert@cs.ucla.edu>
15010
15011         * lib/inttypes.h: New file.
15012         * lib/strtoimax.c: Assume <inttypes.h>.
15013
15014 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
15015
15016         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
15017         isn't mounted.  Problem reported by Kir Kolyshkin.
15018
15019 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
15020
15021         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
15022         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
15023         Derek R. Price.
15024         * lib/regex.h (RE_DUP_MAX): Update comment to match current
15025         implementation.
15026
15027 2006-04-12  Eric Blake  <ebb9@byu.net>
15028
15029         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
15030         is now done automatically by the corresponding Autoconf macro.
15031
15032 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
15033
15034         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
15035         time_r.h.
15036
15037 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
15038
15039         Merge regex changes from libc, removing some of our
15040         POSIX-conformance changes that were rejected and redoing them in a
15041         less-intrusive way.
15042
15043         * lib/regcomp.c (re_compile_internal, init_dfa):
15044         Length arg is now size_t, not Idx.  All uses changed.
15045         (peek_token): Forward decl now says internal_function.
15046         (__re_error_msgid, __re_error_msgid_idx):
15047         Now static rather than extern with attribute_hidden.
15048         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
15049         For some reason libc prefers K&R style defns for external functions.
15050         (regerror) [!defined _LIBC]: Likewise.
15051         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
15052         (seek_collating_symbol_entry, lookup_collation_sequence_value):
15053         (build_range_exp, build_collating_symbol):
15054         Use K&R-style defn.
15055         (re_compile_fastmap): Use '\0' to memset, not 0.
15056         (utf8_sb_map): Make the calculations more obvious.
15057         (init_dfa, parse_bracket_exp, build_charclass_op):
15058         Call calloc and cast result, as glibc does.
15059         (init_word_char, fetch_token, peek_token, peek_token_bracket):
15060         (build_range_exp, build_collating_symbol):
15061         Now internal functions.
15062
15063         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
15064
15065         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
15066         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
15067         Don't depend on VMS; depend on __VMS instead, for POSIX
15068         namespace cleanness.
15069         (regoff_t): Define to ssize_t, not long int.
15070
15071         Remove the REG_ macros named below.  Instead, make the old names
15072         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
15073         __USE_GNU_REGEX.
15074         (REG_BACKSLASH_ESCAPE_IN_LISTS):
15075         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
15076         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
15077         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
15078         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
15079         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
15080         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
15081         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
15082         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
15083         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
15084         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
15085         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
15086         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
15087         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
15088         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
15089         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
15090         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
15091         (REG_NREGS):
15092         Remove.  All uses replaced by the old RE_* names.
15093         (RE_BACKSLASH_ESCAPE_IN_LISTS):
15094         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
15095         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
15096         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
15097         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
15098         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
15099         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
15100         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
15101         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
15102         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
15103         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
15104         Don't bother having these macros be independent of each others'
15105         values, since they no longer exist in the POSIX name space.
15106
15107         Rename the following member names back to their old names,
15108         unless !__USE_GNU_REGEX.  All uses changed back.
15109         (buffer): Renamed from re_buffer.
15110         (allocated): Renamed from re_allocated.
15111         (used): Renamed from re_used.
15112         (syntax): Renamed from re_syntax.
15113         (fastmap): Renamed from re_fastmap.
15114         (translate): Renamed from re_translate.
15115         (can_be_null): Renamed from re_can_be_null.
15116         (regs_allocated): Renamed from re_regs_allocated.
15117         (fastmap_accurate): Renamed from re_fastmap_accurate.
15118         (no_sub): Renamed from re_no_sub.
15119         (not_bol): Renamed from re_not_bol.
15120         (not_eol): Renamed from re_not_eol.
15121         (newline_anchor): Renamed from re_newline_anchor.
15122         (num_regs): Renamed from rm_num_regs.
15123         (start): Renamed from rm_start.
15124         (end): Renamed from rm_end.
15125
15126         (free_state): Move up a bit.
15127
15128         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
15129         #define to be empty.
15130         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
15131         when that is what is intended.
15132         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
15133         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
15134         (MAX): New macro.
15135         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
15136         All uses changed back to re_malloc, etc.  It's now the caller's
15137         responsibility to check for overflow; all callers changed.
15138         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
15139         (re_x2nrealloc): Remove.
15140         (free_state): Remove decl.
15141
15142         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
15143         (re_set_registers, re_exec):
15144         Use K&R-style defn.
15145
15146         2006-01-31  Roland McGrath  <roland@redhat.com>
15147
15148         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
15149         Reported by Mike Frysinger <vapier@gentoo.org>.
15150
15151         2006-01-15  Andreas Jaeger  <aj@suse.de>
15152
15153         [BZ #1950]
15154         * lib/regex_internal.c (re_string_reconstruct): Adjust for
15155         build_wcs_upper_buffer change.
15156         (build_wcs_upper_buffer): Change return type.
15157
15158         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
15159
15160         * lib/regex_internal.h: Include <stdint.h> if available.
15161
15162         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
15163
15164         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
15165
15166         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
15167
15168         * lib/regcomp.c: Adjust for changed secondary hash function.
15169
15170         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
15171
15172         * lib/regex.h: Pretty printing.
15173         Clean up namespace a bit.
15174
15175         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
15176
15177         * lib/regexec.c (update_cur_sifted_state, check_arrival,
15178         check_arrival_add_next_nodes): Avoid using uninitialized variable.
15179
15180         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
15181                     Ulrich Drepper  <drepper@redhat.com>
15182
15183         [BZ #1302]
15184         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
15185         changed.
15186         (bitset_word_t): Renamed from bitset_word.  All uses changed.
15187
15188         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
15189
15190         [BZ #281]
15191         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
15192         * lib/regcomp.c: Remove unnecessary uses of
15193         unsigned RE_TRANSLATE_TYPE.
15194         * lib/regex_internal.h: Likewise.
15195         * lib/regex_internal.c: Likewise.
15196         * lib/regexec.c: Likewise.
15197         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
15198
15199         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
15200
15201         * lib/regexec.c (find_recover_state): Remove unnecessary
15202         initialization.
15203         (transit_state_bkref): Make DFA a const pointer.
15204         (get_subexp): Likewise.
15205         (check_arrival): Likewise.
15206         (update_cur_sifted_state): Likewise.
15207         (re_search_internal): Likewise.
15208         (prune_impossible_nodes): Likewise.
15209         (acquire_init_state_context): Likewise.
15210         (proceed_next_node): Likewise.
15211         (set_regs): Likewise.
15212         (free_fail_stack_return): Likewise.
15213         (check_arrival_expand_ecl): Mark DFA parameter as const.
15214         (check_arrival_expand_ecl_sub): Likewise.
15215         (check_subexp_limits): Likewise.
15216         (sub_epsilon_src_nodes):  Likewise.
15217         (add_epsilon_src_nodes):  Likewise.
15218         (merge_state_array): Likewise.
15219         (update_regs): Likewise.
15220         (build_trtable): Likewise.
15221         (sift_states_backward): Mark MCTX parameter as const.
15222         (build_sifted_states): Likewise.
15223         (update_cur_sifted_state): Likewise.
15224         (sift_states_mkref): Likewise.
15225         (check_arrival_expand_ecl): Mark eclosure as const.
15226         (check_dst_limits_calc_pos_1): Likewise.
15227         * lib/regex_internal.h (re_match_context_t): Make dfa a const
15228         pointer.
15229
15230         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
15231
15232         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
15233         (transit_state_sb): Likewise.
15234         (transit_state_mb): Likewise.
15235         (sift_states_iter_mb): Likewise.
15236         (check_arrival_add_next_nodes): Likewise.
15237         (check_node_accept_bytes): Change first parameter to pointer-to-const.
15238         [_LIBC] (re_search_2_stub): Use mempcpy.
15239
15240         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
15241         mbrtowc for very simple UTF-8 case.
15242
15243         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
15244         a pointer-to-const.
15245         (re_acquire_state_context): Likewise.
15246         * lib/regex_internal.h: Adjust prototypes.
15247
15248         * lib/regex.c: Prevent using C++ compilers.
15249
15250         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
15251         (re_acquire_state_context): Likewise.
15252
15253 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
15254
15255         * modules/regex (Depends-on): Add ssize_t.
15256
15257 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
15258
15259         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
15260         translation table.
15261
15262 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
15263
15264         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
15265
15266 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
15267             Bruno Haible  <bruno@clisp.org>
15268
15269         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
15270         <sys/types.h> and <inttypes.h>.
15271
15272 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15273
15274         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
15275         `__error_t_defined', so argp.h will not typedef the former.
15276
15277 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
15278
15279         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
15280         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
15281         glibc names.  Even if glibc is changed to conform to POSIX, the
15282         traditional names will be available anyway, since regex depends on
15283         the extensions module.  Also, fix a longstanding typo in the
15284         implementation of Spencer ERE test #75 from grep 2.3.  Problems
15285         reported by Emanuele Giaquinta.  Also, change sense of cached
15286         variable, so that the message makes sense.
15287
15288 2006-03-24  Simon Josefsson  <jas@extundo.com>
15289
15290         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
15291         including some doc fixes.
15292         (base64_encode_alloc): Fix +1 bug on allocation failures.
15293
15294 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15295
15296         * lib/base64.c (base64_encode): Do not read past end of array with
15297         unsanitized input on systems with CHAR_BIT > 8.
15298
15299 2006-03-24  Eric Blake  <ebb9@byu.net>
15300
15301         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
15302
15303 2006-03-22  Karl Berry  <karl@gnu.org>
15304
15305         * config/srclist.txt (*setenv.[ch]): get from coreutils.
15306         * config/srclistvars.sh (COREUTILS): new var.
15307
15308 2006-03-17  Jim Meyering  <jim@meyering.net>
15309
15310         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
15311         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
15312
15313 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
15314
15315         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
15316         no longer needs it.  Instead, check that regoff_t is as least
15317         as wide as ptrdiff_t.
15318
15319         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
15320         so that our regex.h stays compatible with the installed regex.
15321         This is helpful for installers who configure --without-included-regex.
15322         Problem reported by Emanuele Giaquinta.
15323
15324 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
15325
15326         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
15327         Typedef to long int, not to off_, as POSIX will likely change
15328         in that direction.
15329
15330 2006-03-15  Eric Blake  <ebb9@byu.net>
15331
15332         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
15333
15334 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
15335
15336         * lib/argp-help.c (validate_uparams): Fix typo
15337         * lib/argp-parse.c (argp_default_options): Consistently begin help
15338         messages with a lowercase letter.
15339
15340 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
15341
15342         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
15343         overrun buffers and shouldn't be used (much as gets shouldn't be
15344         used).
15345         * lib/time_r.c (asctime_r, ctime_r): Likewise.
15346
15347 2006-03-08  Simon Josefsson  <jas@extundo.com>
15348
15349         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
15350         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15351
15352 2006-03-08  Simon Josefsson  <jas@extundo.com>
15353
15354         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
15355         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15356
15357 2006-03-08  Simon Josefsson  <jas@extundo.com>
15358
15359         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
15360         signal that configure disabled the device.
15361
15362 2006-03-08  Simon Josefsson  <jas@extundo.com>
15363
15364         * build-aux/maint.mk: Fix refresh-po, to handle no translated
15365         languages.
15366
15367 2006-03-07  Simon Josefsson  <jas@extundo.com>
15368
15369         * modules/getopt (Depends-on): Add unistd.
15370
15371         * modules/unistd: New file.
15372
15373 2006-03-07  Simon Josefsson  <jas@extundo.com>
15374
15375         * modules/gc-random: New file.
15376
15377 2006-03-07  Simon Josefsson  <jas@extundo.com>
15378
15379         * m4/unistd_h.m4: New file.
15380
15381 2006-03-07  Simon Josefsson  <jas@extundo.com>
15382
15383         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
15384         test to be side-effect free by storing the result in the cache
15385         variable gl_cv_lib_readline, and moving the assignment of
15386         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
15387         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15388
15389 2006-03-07  Simon Josefsson  <jas@extundo.com>
15390
15391         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
15392         error on missing devices (the functions will return an error).
15393
15394         * m4/gc.m4: Move random stuff to gc-random.m4
15395
15396 2006-03-07  Simon Josefsson  <jas@extundo.com>
15397
15398         * lib/unistd_.h: New file.
15399
15400 2006-03-07  Simon Josefsson  <jas@extundo.com>
15401
15402         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
15403
15404 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
15405
15406         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
15407         Problem reported by Juan Manuel Guerrero.
15408
15409 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
15410
15411         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
15412         the unistd module.
15413         * lib/getlogin_r.c: Likewise.
15414         * lib/getlogin_r.h: Likewise.
15415         * lib/glob.c: Likewise.
15416         * lib/pagealign_alloc.c: Likewise.
15417         * lib/unistd_.h: Remove; no longer needed.
15418
15419 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
15420
15421         * MODULES.html.sh (Support for systems lacking POSIX:2001):
15422         Add unistd.
15423         * modules/c-stack (Depends-on): Add unistd.
15424         * modules/getlogin_r: Likewise.
15425         * modules/glob: Likewise.
15426         * modules/pagealign_alloc: Likewise.
15427         * modules/unistd (Files): Remove lib/unistd_.h.
15428         (EXTRA_DIST): Remove.
15429         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
15430         need unistd_.h.
15431         (MOSTLYCLEANFILES): Remove unistd.h-t.
15432
15433 2006-03-03  Simon Josefsson  <jas@extundo.com>
15434
15435         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
15436
15437 2006-03-03  Simon Josefsson  <jas@extundo.com>
15438
15439         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
15440         libidn and bison.
15441
15442 2006-03-03  Simon Josefsson  <jas@extundo.com>
15443
15444         * build-aux/maint.mk: Add indent target.
15445
15446 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
15447
15448         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
15449         our replacement poll.h in any case, to avoid a differing
15450         declaration from a system header.  Seen on AIX.
15451
15452 2006-03-01  Simon Josefsson  <jas@extundo.com>
15453
15454         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
15455         <kasal@ucw.cz>.
15456
15457 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
15458
15459         * modules/gettime (Depends-on): Add extensions module.
15460         * modules/nanosleep (Depends-on): Likewise.
15461         * modules/settime (Depends-on): Likewise.
15462
15463 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
15464
15465         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
15466         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
15467         pedantically.
15468         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
15469         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
15470
15471         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
15472         not "==".  Reported by Ralf Wildenhues.
15473
15474 2006-03-01  Karl Berry  <karl@gnu.org>
15475
15476         * doc/Copyright/request-*: new files, synced from gnuorg.
15477
15478 2006-03-01  Karl Berry  <karl@gnu.org>
15479
15480         * config/srclist.txt (Copyright/*): new entries.
15481
15482 2006-02-28  Simon Josefsson  <jas@extundo.com>
15483
15484         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
15485
15486 2006-02-27  Simon Josefsson  <jas@extundo.com>
15487
15488         * lib/base64.h: Indent #define's.  From Jim Meyering
15489         <jim@meyering.net>.
15490
15491 2006-02-27  Jim Meyering  <jim@meyering.net>
15492
15493         Revert the change of 2006-02-24, so these files can continue
15494         to be sync'd from gettext.
15495         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
15496         of `config.h'.
15497
15498 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
15499
15500         * modules/intprops: New file.
15501         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
15502         Add intprops.
15503         * modules/getloadavg (Files): Remove lib/intprops.h.
15504         (Depends-on): Add intprops.
15505         * modules/human: Likewise.
15506         * modules/inttostr: Likewise.
15507         * modules/openat: Likewise.
15508         * modules/sig2str: Likewise.
15509         * modules/userspec: Likewise.
15510         * modules/utimecmp: Likewise.
15511         * modules/xnanosleep: Likewise.
15512         * modules/xstrtol: Likewise.
15513
15514 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
15515
15516         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
15517         * modules/lock-tests (TESTS): Use $(EXEEXT).
15518         * modules/tls-tests: Likewise.
15519         * modules/argp-tests: Likewise.
15520         (check_PROGRAMS): New var, replacing...
15521         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
15522
15523 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15524
15525         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
15526         `config.h'.
15527
15528 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
15529
15530         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
15531
15532 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15533
15534         Sync from coreutils.
15535         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
15536         gl_CHDIR_SAFER.
15537
15538 2006-02-22  Jim Meyering  <jim@meyering.net>
15539
15540         Sync from coreutils.
15541         * m4/chdir-safer.m4: New file.
15542
15543 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
15544
15545         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
15546         AT_FDCWD exceeds INT_MAX.
15547         * lib/openat.h (AT_FDCWD): Likewise.
15548
15549 2006-02-17  Eric Blake  <address@hidden>
15550
15551         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
15552
15553 2006-02-16  Simon Josefsson  <jas@extundo.com>
15554
15555         * modules/getaddrinfo (Depends-on): Add sys_socket.
15556
15557 2006-02-15  Simon Josefsson  <jas@extundo.com>
15558
15559         * build-aux/maint.mk: Add dsyntax-check rule.
15560
15561 2006-02-15  Eric Blake  <ebb9@byu.net>
15562
15563         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
15564         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
15565         'present but cannot compile' warnings on cygwin.
15566         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
15567         use ws2tcpip.h if sys/socket.h works.
15568         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
15569         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
15570
15571 2006-02-14  Simon Josefsson  <jas@extundo.com>
15572
15573         * modules/maintainer-makefile (Files): Rename.
15574
15575         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
15576         and (the local) Makefile.cfg to maint-cfg.mk.
15577
15578         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
15579         to the latter.
15580
15581         * modules/maintainer-makefile: New module.
15582
15583         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
15584         severaly stripped to make it possible to build it up from scratch
15585         with reliable tests.
15586
15587         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
15588         fixes to permit overriding the default actions when configure and
15589         makefile are not available.
15590
15591 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
15592
15593         Sync from coreutils.
15594         * modules/lstat (Depends-on): Don't depend on xalloc.
15595         (License): Change from GPL to LGPL, since this is now simply a
15596         replacement for a libc function.
15597
15598 2006-02-14  Jim Meyering  <jim@meyering.net>
15599
15600         Sync from coreutils.
15601
15602         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
15603         failure on deficient systems, and simplify gnulib lgpl dependencies.
15604         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
15605         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
15606
15607         * lib/xalloc-die.c: Remove unused definition of N_.
15608
15609 2006-02-14  Jim Meyering  <jim@meyering.net>
15610
15611         Sync from coreutils.
15612         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
15613         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
15614         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
15615         double-quote uses of that variable, to accommodate the rare case in
15616         which getmntent is available in none of the libraries checked.  This
15617         happens at least on FreeBSD 5.0.
15618
15619 2006-02-13  Simon Josefsson  <jas@extundo.com>
15620
15621         * gnulib-tool (Usage): Fix --import, from
15622         karl@freefriends.org (Karl Berry).
15623
15624 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
15625
15626         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
15627
15628 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
15629
15630         * lib/argp-namefrob.h: Restore changes accidentally lost during the
15631         "autoupdate" on 2005-12-12.
15632
15633 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
15634
15635         * modules/closeout (Depends-on): Remove atexit.
15636
15637 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
15638
15639         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
15640         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
15641
15642 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
15643
15644         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
15645         __EXTENSIONS__ if this causes compilation to fail.  Problem
15646         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
15647         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
15648
15649 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
15650
15651         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
15652         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
15653         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
15654         All uses changed.
15655
15656 2006-01-26  Simon Josefsson  <jas@extundo.com>
15657
15658         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
15659         prototype is visible on mingw32.
15660
15661         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
15662         for mingw32.
15663
15664         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
15665         mingw32).
15666
15667 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
15668
15669         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
15670         attempt to open for write; this always fails, at least on POSIX
15671         hosts.  This reinstates the 2006-01-09 change, which was
15672         inadvertently removed.
15673
15674 2006-01-26  Bruno Haible  <bruno@clisp.org>
15675
15676         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
15677         Reported by Paul Eggert.
15678
15679 2006-01-26  Bruno Haible  <bruno@clisp.org>
15680             Paul Eggert  <eggert@cs.ucla.edu>
15681
15682         * lib/stdbool_.h (_Bool)
15683         [(! (defined __cplusplus || defined __BEOS__)
15684           && !defined __GNUC__
15685           && !(defined __HP_cc || defined __xlc__
15686                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
15687                || defined __sgi))]:
15688         #define to signed char in these cases too; this simplifies
15689         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
15690         etc., separately) and makes it more conservative.
15691
15692 2006-01-25  Simon Josefsson  <jas@extundo.com>
15693
15694         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
15695         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
15696         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
15697
15698 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
15699
15700         * lib/argp-namefrob.h: Bugfix. Remove stray #
15701
15702 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
15703
15704         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
15705         so that we test the test.
15706         Check for yet another HP-UX cc bug involving *bool |= bool.
15707
15708 2006-01-25  Karl Berry  <karl@gnu.org>
15709
15710         * config/srclist.txt (vasnprintf.c): sync lost.
15711
15712 2006-01-25  Jim Meyering  <jim@meyering.net>
15713
15714         Sync from the stable (b5) branch of coreutils:
15715
15716         * lib/fts.c (fts_children): Don't let close() clobber errno from
15717         failed fchdir().
15718
15719         * lib/fts.c (fts_stat): When following a symlink-to-directory,
15720         don't necessarily interpret stat-fails+lstat-succeeds as indicating
15721         a dangling symlink.  That can also happen at least for ELOOP.
15722         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
15723         FYI, this bug predates the inclusion of fts.c in coreutils.
15724
15725         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
15726         in their own block, so pre-c99 compilers don't object.
15727
15728         Avoid the double-free (first in fts_read, second in fts_close) that
15729         would occur when an `active' directory is made inaccessible (e.g.,
15730         via chmod a-x) during a traversal.
15731         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
15732         before returning.  Reproduce this failure by
15733         mkdir -p a/b; cd a; chmod a-x . b
15734         Reported by Stavros Passas.
15735
15736 2006-01-25  Jim Meyering  <jim@meyering.net>
15737
15738         * lib/fileblocks.c: Remove more useless parentheses.
15739         * lib/readutmp.h: Likewise.
15740
15741 2006-01-25  Bruno Haible  <bruno@clisp.org>
15742
15743         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
15744         warnings.
15745         Reported by Paul Eggert.
15746
15747 2006-01-25  Bruno Haible  <bruno@clisp.org>
15748
15749         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
15750         rid of a trap command. For Solaris sh.
15751         Reported by Mark D. Baushke <mdb@gnu.org>.
15752
15753 2006-01-24  Simon Josefsson  <jas@extundo.com>
15754
15755         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
15756         Bruno.
15757
15758 2006-01-24  Karl Berry  <karl@gnu.org>
15759
15760         * config/srclist.txt (argp-namefrob.h): sync lost.
15761
15762 2006-01-24  Jim Meyering  <jim@meyering.net>
15763
15764         * modules/openat (Files): Add lib/intprops.h.
15765         From Mark D. Baushke.
15766
15767 2006-01-24  Jim Meyering  <jim@meyering.net>
15768
15769         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
15770         Reported by Mark D. Baushke.
15771
15772 2006-01-24  Jim Meyering  <jim@meyering.net>
15773
15774         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
15775
15776 2006-01-24  Bruno Haible  <bruno@clisp.org>
15777
15778         * modules/strnlen (Maintainer): Change from glibc to all.
15779
15780 2006-01-24  Bruno Haible  <bruno@clisp.org>
15781
15782         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
15783         Patch by Paul Eggert.
15784
15785 2006-01-24  Bruno Haible  <bruno@clisp.org>
15786
15787         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
15788         already has it.
15789         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
15790         2005-11-26.
15791
15792         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
15793         'signed char' to avoid problems with the built-in _Bool type.
15794         Reported by Paul Eggert on 2005-11-26.
15795
15796 2006-01-24  Bruno Haible  <bruno@clisp.org>
15797
15798         * gnulib-tool (func_import): Avoid constructing complicated sed
15799         expressions inside backquote.
15800         Report and solution by Mark D. Baushke <mdb@gnu.org>.
15801
15802 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
15803
15804         These changes imported from libc.
15805         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
15806         test and two separate function calls.
15807         * lib/strndup.c (__strndup): Add libc_hidden_def.
15808
15809 2006-01-23  Simon Josefsson  <jas@extundo.com>
15810
15811         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
15812         Remove the test_*_SOURCES variable: automake infers it by default.
15813         * modules/tls-tests: Likewise.
15814
15815 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15816
15817         Work around porting bugs reported by Dieter in
15818         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
15819         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
15820         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
15821         Include "getopt.h" first, to check interface.
15822         (getenv): Declare only if defined HAVE_DECL_GETENV &&
15823         !HAVE_DECL_GETENV.
15824         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
15825         (__strndup): Revert to K&R-style function dfns, the glibc style.
15826         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
15827         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
15828         Include strnlen.h first, to get prototype properly.
15829         (strnlen): Renamed from __strnlen.
15830         Remove weak alias.
15831
15832 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15833
15834         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
15835
15836 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
15837
15838         * config/srclist.txt: Adjust to reflect glibc reorganization.
15839         This affects only comments.
15840
15841 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
15842
15843          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
15844          Reported by Bruce Korb <bkorb@gnu.org>.
15845
15846 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
15847
15848         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
15849         to pacify gcc -Wswitch-default.
15850
15851 2006-01-22  Bruno Haible  <bruno@clisp.org>
15852
15853         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
15854         temporary buffer for sprintf, take into account the precision also
15855         for 'd', 'i', 'u', 'o', 'x', 'X'.
15856
15857 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
15858
15859         * modules/argp-tests: New module
15860         * tests/test-argp.c: New file
15861         * tests/test-argp-2.sh: New file
15862
15863 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
15864
15865         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
15866         (__argp_base_name): Removed
15867         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
15868         typo.
15869         (__argp_base_name): Provide macro definition or extern declaration
15870         depending on the configuration
15871
15872 2006-01-20  Simon Josefsson  <jas@extundo.com>
15873
15874         * modules/inet_ntop (Depends-on): Depend on sys_socket.
15875
15876 2006-01-20  Simon Josefsson  <jas@extundo.com>
15877
15878         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
15879
15880 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
15881
15882         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
15883         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
15884         Suggested by Bruno Haible.
15885
15886 2006-01-20  Karl Berry  <karl@gnu.org>
15887
15888         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
15889         until changes propagate, I guess.
15890
15891 2006-01-19  Simon Josefsson  <jas@extundo.com>
15892
15893         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
15894
15895 2006-01-19  Simon Josefsson  <jas@extundo.com>
15896
15897         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
15898
15899 2006-01-19  Simon Josefsson  <jas@extundo.com>
15900
15901         * gnulib-tool: Set check_PROGRAMS.
15902
15903         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
15904         modules/des-tests, modules/gc-arcfour-tests,
15905         modules/gc-arctwo-tests, modules/gc-des-tests,
15906         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
15907         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
15908         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
15909         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
15910         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
15911         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
15912         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
15913         test_*_SOURCES.
15914
15915 2006-01-18  Simon Josefsson  <jas@extundo.com>
15916
15917         * modules/socklen (Depends-on): Depend on sys_socket.
15918
15919 2006-01-18  Simon Josefsson  <jas@extundo.com>
15920
15921         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
15922         modules/des-tests, modules/gc-arcfour-tests,
15923         modules/gc-arctwo-tests, modules/gc-des-tests,
15924         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
15925         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
15926         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
15927         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
15928         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
15929         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
15930         $(EXEEXT) to automake TESTS variable, for mingw32.
15931
15932 2006-01-17  Simon Josefsson  <jas@extundo.com>
15933
15934         * modules/socklen (Include): Need sys/socket.h.
15935
15936 2006-01-17  Bruno Haible  <bruno@clisp.org>
15937
15938         * modules/ssize_t (Include): Add <sys/types.h>.
15939
15940 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
15941
15942         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
15943         it's not portable and it doesn't work with cross-compiles.
15944         Problem reported by Bruno Haible.  Fix missing-$ typo in
15945         'test "gl_cv_ignore_unused_libraries" ...' that prevented
15946         -zignore from being used with Sun's C compiler.
15947
15948 2006-01-12  Simon Josefsson  <jas@extundo.com>
15949
15950         * lib/base64.c: Fix warning, reported by Bruno Haible
15951         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
15952
15953 2006-01-12  Bruno Haible  <bruno@clisp.org>
15954
15955         * modules/ldd: New file.
15956         * build-aux/ldd.sh.in: New file.
15957         * MODULES.html.sh (Support for building libraries and executables): Add
15958         ldd.
15959
15960 2006-01-12  Bruno Haible  <bruno@clisp.org>
15961
15962         * m4/ldd.m4: New file.
15963
15964 2006-01-12  Bruno Haible  <bruno@clisp.org>
15965
15966         * gnulib-tool (func_import, func_create_testdir): Don't go into an
15967         endless loop while replacing $auxdir with build-aux.
15968
15969 2006-01-11  Simon Josefsson  <jas@extundo.com>
15970
15971         * lib/stdint_.h (SIZE_MAX): Add missing (.
15972
15973 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
15974
15975         Sync from coreutils.
15976         * lib/md5.c: Fix commentary typos.
15977         (alignof, UNALIGNED_P): No need for a GCC-specific version.
15978         * lib/md5.h (__attribute__): Remove; unused.
15979         * lib/sha1.c: Fix commentary to match md5 better.
15980         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
15981         so that we don't need to worry about alignment.  All uses changed.
15982         This merges the 2005-10-28 md5 change into sha1.
15983
15984 2006-01-11  Jim Meyering  <jim@meyering.net>
15985
15986         Sync from coreutils.
15987         * lib/md5.c (OP): Fix spacing.
15988
15989 2006-01-11  Bruno Haible  <bruno@clisp.org>
15990
15991         Ensure automatic ordering between gl_LOCK and gl_ARGP.
15992         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
15993         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
15994
15995 2006-01-11  Bruno Haible  <bruno@clisp.org>
15996
15997         Ensure automatic ordering between gl_LOCK and gl_ARGP.
15998         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
15999         the "early" section as well.
16000
16001 2006-01-11  Bruno Haible  <bruno@clisp.org>
16002
16003         Avoid "ar: no archive members specified" error on MacOS X.
16004         * gnulib-tool (func_modules_add_dummy): New function.
16005         (func_import, func_create_testdir): Invoke it.
16006
16007 2006-01-11  Bruno Haible  <bruno@clisp.org>
16008
16009         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
16010         with $auxdir in AC_CONFIG_FILES statements.
16011
16012 2006-01-11  Bruno Haible  <bruno@clisp.org>
16013
16014         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
16015         Initialize also noinst_HEADERS to empty.
16016
16017 2006-01-11  Bruno Haible  <bruno@clisp.org>
16018
16019         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
16020         variables.
16021         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
16022         autoreconf.
16023
16024 2006-01-11  Bruno Haible  <bruno@clisp.org>
16025
16026         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
16027         overridable by the user.
16028         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
16029
16030 2006-01-10  Simon Josefsson  <jas@extundo.com>
16031
16032         * modules/sys_socket: New file.
16033
16034 2006-01-10  Simon Josefsson  <jas@extundo.com>
16035
16036         * m4/sys_socket_h.m4: New file.
16037
16038 2006-01-10  Simon Josefsson  <jas@extundo.com>
16039
16040         * lib/socket_.h: New file.
16041
16042 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
16043
16044         * modules/readutmp (Maintainer): Add myself.
16045
16046 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
16047
16048         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
16049         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
16050         People who are still concerned with buggy memcmp implementations
16051         can invoke gl_FUNC_MEMCMP themselves.
16052
16053 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
16054
16055         * lib/regex_internal.h (BITSET_WORD_BITS):
16056         Work around a bug in 64-bit PGC (before version 6.1-2), where the
16057         preprocessor mishandles large unsigned values as if they were signed.
16058         Problem reported by Claudio Fontana in
16059         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
16060
16061 2006-01-10  Jim Meyering  <jim@meyering.net>
16062
16063         Avoid the double-free (first in fts_read, second in fts_close) that
16064         would occur when an `active' directory is made inaccessible (e.g.,
16065         via chmod a-x) during a traversal.
16066         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
16067         before returning.  Reproduce this failure by
16068         mkdir -p a/b; cd a; chmod a-x . b
16069         Reported by Stavros Passas.
16070
16071         Sync from coreutils.
16072         * lib/sha1.c: Tweak grammar in a comment.
16073
16074 2006-01-10  Jim Meyering  <jim@meyering.net>
16075
16076         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
16077         Patch by Joerg Sonnenberger.
16078
16079 2006-01-10  Bruno Haible  <bruno@clisp.org>
16080
16081         * modules/readutmp: Depend on module free.
16082         * modules/strtok_r: Depend on module restrict.
16083
16084 2006-01-10  Bruno Haible  <bruno@clisp.org>
16085
16086         * modules/gettext (configure.ac): Add an invocation of
16087         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
16088
16089 2006-01-10  Bruno Haible  <bruno@clisp.org>
16090
16091         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
16092         Reported by Werner Lemberg <wl@gnu.org>.
16093
16094 2006-01-10  Bruno Haible  <bruno@clisp.org>
16095
16096         * lib/localcharset.c: Update from GNU gettext.
16097
16098 2006-01-10  Bruno Haible  <bruno@clisp.org>
16099
16100         * lib/argp.h (__const): Remove macro. Use const instead.
16101         * lib/argp-fmtstream.h (__const): Likewise.
16102         * lib/glob_.h (__const): Remove macro.
16103         * lib/glob-libc.h: Use const instead of __const.
16104
16105 2006-01-10  Bruno Haible  <bruno@clisp.org>
16106
16107         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
16108         variable.
16109         Needed to avoid an automake error regarding the 'gettext' module.
16110
16111 2006-01-09  Simon Josefsson  <jas@extundo.com>
16112
16113         * modules/inet_ntop (Depends-on): Add restrict.
16114
16115 2006-01-09  Simon Josefsson  <jas@extundo.com>
16116
16117         * modules/gc-rijndael-tests (License): Put under LGPL.
16118
16119         * modules/gc-des-tests (License): Likewise.
16120
16121         * modules/gc-arcfour-tests (License): Likewise.
16122
16123         * modules/gc-arctwo-tests (License): Likewise.
16124
16125         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
16126
16127         * modules/gc-hmac-sha1-tests (Files): Likewise.
16128
16129         * modules/gc-hmac-md5-tests (License): Likewise.
16130
16131         * modules/gc-sha1-tests (License): Likewise.
16132
16133         * modules/gc-md5-tests (License): Likewise.
16134
16135         * modules/gc-md4-tests (License): Likewise.
16136
16137         * modules/gc-md2-tests (License): Likewise.
16138
16139         * modules/gc-tests (License): Likewise.
16140
16141         * modules/des-tests (License): Likewise.
16142
16143         * modules/md4-tests (License): Likewise.
16144
16145         * modules/md2-tests (License): Likewise.
16146
16147 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
16148
16149         Sync from coreutils:
16150
16151         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
16152         * modules/lib-ignore: New file.
16153         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
16154         chdir-safer.m4, lchmod.m4.
16155         * modules/openat: Add mkdirat.c, openat-priv.h.
16156
16157 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
16158
16159         Sync from coreutils.
16160         * m4/lib-ignore.m4: New file.
16161         * m4/lchmod.m4: New file.
16162
16163 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
16164
16165         Sync from coreutils.
16166         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
16167         for write access: POSIX says that must fail.
16168         * lib/fts.c (diropen): Likewise.
16169         * lib/save-cwd.c (save_cwd): Likewise.
16170         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
16171         well, for minor improvements on hosts that lack O_DIRECTORY.
16172         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
16173         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
16174         Fall back on chown if open failed with EACCES.
16175
16176         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
16177         Report an error at compile-time if only a 1-second nominal clock
16178         resolution is found.
16179
16180         * lib/lchmod.h: New file.
16181         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
16182         (make_dir_parents): Use lchown rather than chown, and
16183         lchmod rather than chmod.
16184
16185         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
16186         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
16187         "proc" reported by n0dalus.
16188
16189         * lib/mountlist.c: Include <limits.h>.
16190         (dev_from_mount_options)
16191         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
16192         New function.  It no longer assumes "dev=" has the System V meaning
16193         on Linux (since it doesn't).  It also parses "dev=" more carefully.
16194         (read_file_system_list)
16195         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
16196         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
16197         dev= in that case.
16198
16199         * lib/posixtm.h (PDS_PRE_2000): New macro.
16200         * lib/posixtm.c (year): Arg is now syntax_bits rather than
16201         allow_century.  All usages changed.  Reject dates outside the range
16202         1969-1999 if PDS_PRE_2000 is used.
16203
16204 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
16205
16206         Sync from coreutils.
16207         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
16208         (Time of day items): Mention the possibility of leap seconds.
16209         Problem reported by Dr. David Alan Gilbert.
16210
16211 2006-01-09  Jim Meyering  <jim@meyering.net>
16212
16213         Sync from coreutils.
16214
16215         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
16216
16217         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
16218
16219         * lib/modechange.c (mode_compile): Reject an invalid mode string
16220         that starts with an octal digit.  From Andreas Gruenbacher.
16221
16222         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
16223         and dup to open_safer and dup_safer, respectively.
16224         (openat_permissive): Fix typo in comment.
16225
16226         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
16227         "gettext.h"; either no longer needed or are guaranteed by openat.h.
16228         (_): Remove; no longer needed.
16229         (openat): Renamed from rpl_openat; no need for rpl_openat
16230         since openat.h renames openat for us.
16231         Replace most of the body with a call to openat_permissive,
16232         to avoid duplicate code.
16233         Port to (probably hypothetical) environments were mode_t is
16234         wider than int.
16235         (openat_permissive): Require mode arg, so that we can check
16236         types better.  Put it just after flags.  Change cwd failure
16237         indicator from pointer-to-bool to pointer-to-errno-value.
16238         All callers changed.
16239         Invoke openat_save_fail and/or openat_restore_fail if
16240         cwd_errno is null, so that openat can call us.
16241         (openat_permissive, fdopendir, fstatat, unlinkat):
16242         Simplify errno handling to avoid some duplicate code,
16243         as it's OK to set errno on success.
16244         * lib/openat.h: Revamp code so that function macros depend on
16245         __OPENAT_PREFIX only, not also on AT_FDCWD.
16246         (openat_ro): Remove.  Caller changed to use openat_permissive.
16247         (openat_permissive): Now a macro, if not a function.
16248         (openat_restore_fail, openat_save_fail): Now always functions,
16249         since mkdirat needs them even if __OPENAT_PREFIX is defined.
16250
16251         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
16252         and openat.c.
16253         * lib/mkdirat.c: Include openat-priv.h.
16254         Remove definitions of macros defined therein.
16255         * lib/openat.c: Likewise.
16256
16257         * lib/mkdirat.c (mkdirat): New file and function.
16258         * lib/openat.h (mkdirat): Declare.
16259
16260         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
16261
16262         * lib/openat.h (openat_permissive): Declare.
16263         (openat_ro): Define.
16264
16265         * lib/openat.c (EXPECTED_ERRNO): New macro.
16266         (openat_permissive): New function -- used in remove.c rewrite.
16267         (all functions): Set errno just before returning, only if there
16268         was an actual failure.
16269         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
16270
16271         Emulate openat-family functions using Linux's procfs, if possible.
16272         Idea and some code based on Ulrich Drepper's glibc changes.
16273
16274         * lib/openat.c: (BUILD_PROC_NAME): New macro.
16275         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
16276         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
16277         before falling back on save_cwd and restore_cwd.
16278         (fdopendir, fstatat, unlinkat): Likewise.
16279
16280         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
16281         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
16282
16283         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
16284         as second argument to va_arg.  Otherwise, some versions of gcc
16285         warn that `if this code is reached, the program will abort'.
16286
16287 2006-01-09  Jim Meyering  <jim@meyering.net>
16288
16289         Sync from coreutils.
16290         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
16291         Require openat-priv.h.
16292
16293 2006-01-09  Bruno Haible  <bruno@clisp.org>
16294
16295         * modules/strnlen (Include): Use strnlen.h.
16296
16297 2006-01-09  Bruno Haible  <bruno@clisp.org>
16298
16299         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
16300
16301 2006-01-09  Bruno Haible  <bruno@clisp.org>
16302
16303         * lib/sysexit_.h (EX_OK): New macro.
16304         Suggested by Martin Lambers <marlam@marlam.de>.
16305
16306 2006-01-09  Bruno Haible  <bruno@clisp.org>
16307
16308         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
16309         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
16310
16311 2006-01-09  Bruno Haible  <bruno@clisp.org>
16312
16313         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
16314         numbers.
16315
16316 2006-01-09  Bruno Haible  <bruno@clisp.org>
16317
16318         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
16319         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
16320         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
16321         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
16322
16323 2006-01-09  Bruno Haible  <bruno@clisp.org>
16324
16325         * build-aux/javacomp.sh.in: New file, moved from lib/.
16326         * modules/javacomp-script (Files): Update.
16327         (configure.ac): Add AC_CONFIG_FILES invocation.
16328         (EXTRA_DIST): Remove variable.
16329
16330         * build-aux/javaexec.sh.in: New file, moved from lib/.
16331         * modules/javaexec (Files): Update.
16332         (configure.ac): Add AC_CONFIG_FILES invocation.
16333         (EXTRA_DIST): Remove javaexec.sh.in.
16334
16335         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
16336         * modules/csharpcomp-script (Files): Update.
16337         (configure.ac): Add AC_CONFIG_FILES invocation.
16338         (EXTRA_DIST): Remove variable.
16339
16340         * build-aux/csharpexec.sh.in: New file, moved from lib/.
16341         * modules/csharpexec (Files): Update.
16342         (configure.ac): Add AC_CONFIG_FILES invocation.
16343         (EXTRA_DIST): Remove csharpexec.sh.in.
16344
16345 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
16346
16347         Sync from coreutils.
16348
16349         Add POSIX ACL support
16350         * lib/acl.h (copy_acl, set_acl): Add declarations.
16351         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
16352         systems other than Linux.
16353         (chmod_or_fchmod): New function: use fchmod when possible,
16354         and chmod otherwise.
16355         (file_has_acl): Add a POSIX ACL implementation, with a
16356         Linux-specific subcase.
16357         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
16358         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
16359         acls are unsupported.
16360         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
16361         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
16362         are unsupported.
16363
16364 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
16365
16366         Sync from coreutils.
16367         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
16368
16369 2006-01-07  Bruno Haible  <bruno@clisp.org>
16370
16371         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
16372         gl_EARLY.
16373
16374 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
16375
16376         * lib/strftime.c (tzname): Don't declare if it is already #defined.
16377         Problem reported for Mingw by Mark Junker.
16378
16379 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
16380
16381         * README: Gnulib normally doesn't generate a tarball.
16382
16383 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
16384
16385         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
16386         long int, not int, for nanosecond counts, so that people who are
16387         used to POSIX struct timespec won't be surprised.  Reported by Jim
16388         Meyering.
16389
16390 2005-12-28  Bruno Haible  <bruno@clisp.org>
16391
16392         * build-aux/config.rpath: Update from GNU gettext.
16393
16394 2005-12-16  Jim Meyering  <jim@meyering.net>
16395
16396         * modules/fprintftime: New module.
16397         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
16398
16399 2005-12-16  Jim Meyering  <jim@meyering.net>
16400
16401         * m4/fprintftime.m4: New file.
16402
16403 2005-12-16  Jim Meyering  <jim@meyering.net>
16404
16405         * lib/fprintftime.c, lib/fprintftime.h: New files.
16406
16407 2005-12-15  Simon Josefsson  <jas@extundo.com>
16408
16409         * modules/socklen (configure.ac): Fix M4 macro name, to align with
16410         new m4/socklen.m4.
16411
16412 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
16413
16414         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
16415         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
16416
16417 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
16418
16419         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
16420         * lib/argp-help.c (fill_in_uparams): Check if the constructed
16421         struct uparams is valid. Fall back to the default values if it is
16422         not.
16423
16424 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16425
16426         * modules/argp (Files): Add argp-pin.c
16427         (Depends-on): dirname
16428         (lib_SOURCES): Add argp-pin.c
16429
16430 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16431
16432         * m4/argp.m4:  Check if program_invocation_name and
16433         program_invocation_short_name are declared and define appropriate
16434         macros if they are not.
16435
16436 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16437
16438         * lib/argp-help.c (__argp_base_name): New function
16439         (__argp_short_program_name): Rewrite using __argp_base_name
16440         * lib/argp-namefrob.h: Define program_invocation_name and
16441         program_invocation_short_name if requested
16442         (__argp_base_name): Add prototype
16443         * lib/argp-parse.c (argp_def): Use gettext wrappers
16444         (argp_default_parser): Use __argp_base_name
16445         * lib/argp-pin.c: New file. Defines program_invocation_name and
16446         program_invocation_short_name on systems that lack them.
16447
16448 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
16449
16450         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
16451         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
16452         porting problem reported by Georg Schwarz in
16453         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
16454
16455 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
16456
16457         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
16458         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
16459         porting problem reported by Georg Schwarz in
16460         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
16461
16462 2005-12-05  Bruno Haible  <bruno@clisp.org>
16463
16464         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
16465         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
16466         Reported by Mark Junker <mjscod@gmx.de>.
16467
16468 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
16469
16470         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
16471         Use implementation from Albert Chin, with some
16472         comments/corrections by Stepan Kasal and myself.
16473
16474 2005-12-02  Bruno Haible  <bruno@clisp.org>
16475
16476         * gnulib-tool (func_import): Accept GPLed build tool modules when
16477         --lgpl is given.
16478         * modules/csharpcomp-script: New file.
16479         * modules/csharpcomp: Depend on it.
16480         * modules/javacomp-script: New file.
16481         * modules/javacomp: Depend on it.
16482         Suggested by Simon Josefsson.
16483
16484 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
16485
16486         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
16487         statement, to work around an HP-UX 10.20 compiler bug reported by
16488         Peter O'Gorman.
16489
16490 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
16491
16492         * modules/savedir (Depends-on): Add openat.
16493
16494 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
16495
16496         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
16497         (uintmax_t) [defined uintmax_t]: Do not declare.
16498         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
16499         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
16500         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
16501         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
16502         sake of portability to weird hosts that C allows (though we don't
16503         know of any practical examples).
16504
16505         * lib/savedir.h (fdsavedir): New decl.
16506         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
16507         contains most of the former guts of savedir.
16508         (savedir): Use savedirstream.
16509         Include "openat.h".
16510
16511 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
16512
16513         * modules/obstack (Files): Add m4/ulonglong.m4.
16514         Problem reported by Davide Angelocola.
16515
16516 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
16517
16518         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
16519         coreutils no longer futzes with rounding modes.
16520
16521 2005-11-14  Jim Meyering  <jim@meyering.net>
16522
16523         * lib/mkstemp-safer.c: Include <config.h>, required for possible
16524         replacement of mkstemp.
16525
16526 2005-11-10  Simon Josefsson  <jas@extundo.com>
16527
16528         * lib/readline.c: Remove EOL.
16529
16530 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
16531
16532         * modules/gethrxtime (Depends-on): Add gettime.
16533
16534 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
16535
16536         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
16537         or gettimeofday; no longer needed.
16538
16539 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
16540
16541         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
16542         time business.
16543         (gethrxtime) [! (HAVE_NANOUPTIME
16544         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
16545         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
16546         our own approximation.
16547
16548 2005-11-08  Eric Blake  <ebb9@byu.net>
16549
16550         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
16551
16552 2005-11-08  Eric Blake  <ebb9@byu.net>
16553
16554         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
16555
16556 2005-11-04  Bruno Haible  <bruno@clisp.org>
16557
16558         * gnulib-tool: Implement --update mode.
16559
16560 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16561
16562         Fix porting problem reported by Theodoros V. Kalamatianos.
16563         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
16564         Don't assume that futimes failing means we must fail.
16565
16566 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
16567
16568         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
16569         variables to suggest the intended function of the PATH_MAX check.
16570
16571 2005-10-30  Kean Johnston  <jkj@sco.com>
16572
16573         Trivial changes to support SCO systems.
16574         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
16575         as PATH_MAX.
16576         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
16577         where __ptr is null when no I/O is pending.
16578
16579 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
16580
16581         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
16582         leave errno alone.  Problem reported by Dmitry V. Levin.
16583
16584 2005-10-28  Simon Josefsson  <jas@extundo.com>
16585
16586         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
16587         Test more.
16588
16589         * tests/test-gc-md2.c, tests/test-md2.c: New files.
16590
16591         * modules/md2, modules/md2-tests: New files.
16592
16593 2005-10-28  Simon Josefsson  <jas@extundo.com>
16594
16595         * m4/inet_ntop.m4: More tests.
16596
16597         * m4/gc-md2.m4, md2.m4: New file.
16598
16599 2005-10-28  Simon Josefsson  <jas@extundo.com>
16600
16601         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
16602         "restrict" keywords, as per POSIX.  Protect the function
16603         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
16604         Don't use K&R prototypes.  Check the sprintf return values.
16605         Re-define EAFNOSUPPORT if not present.  Indent.
16606
16607         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
16608         suggested by Bruno Haible <bruno@clisp.org>.
16609
16610         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
16611
16612         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
16613
16614         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
16615         libgcrypt).
16616
16617         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
16618
16619         * lib/md2.h, lib/md2.c: New files.
16620
16621 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
16622
16623         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
16624         errno alone.  Problem reported by Frederic Jolliton.
16625
16626 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
16627
16628         * modules/verify (License): Change from GPL to LGPL.  This is a
16629         tiny module and there are apparently near-equivalents that are
16630         under the BSD license.
16631
16632 2005-10-24  Simon Josefsson  <jas@extundo.com>
16633
16634         * modules/sha1: Relicense to LGPL.
16635
16636 2005-10-24  Simon Josefsson  <jas@extundo.com>
16637
16638         * lib/md4.h: Shrink buffer size, now that we changed the type.
16639
16640 2005-10-23  Simon Josefsson  <jas@extundo.com>
16641
16642         * gnulib-tool (func_import): Fix --tests-base.
16643
16644 2005-10-22  Simon Josefsson  <jas@extundo.com>
16645
16646         * modules/arcfour (Depends-on): Need stdint.
16647
16648 2005-10-22  Simon Josefsson  <jas@extundo.com>
16649
16650         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
16651         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
16652
16653 2005-10-22  Simon Josefsson  <jas@extundo.com>
16654
16655         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
16656         suggested by Bruno Haible <bruno@clisp.org>.
16657
16658 2005-10-22  Simon Josefsson  <jas@extundo.com>
16659
16660         * lib/crc.h: Include stddef.h, for size_t.
16661
16662 2005-10-22  Simon Josefsson  <jas@extundo.com>
16663
16664         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
16665         arcfour_context struct (simplify test vector testing in GNU
16666         Shishi).
16667
16668 2005-10-21  Simon Josefsson  <jas@extundo.com>
16669
16670         * modules/des, modules/des-tests: New files.
16671
16672         * modules/gc-des, modules/gc-des-tests: New files.
16673
16674         * tests/test-des.c, tests/test-gc-des.c: New file.
16675
16676 2005-10-21  Simon Josefsson  <jas@extundo.com>
16677
16678         * modules/arctwo, modules/arctwo-tests: New files.
16679
16680         * tests/test-arctwo.c: New file.
16681
16682         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
16683
16684         * tests/test-gc-arctwo.c: New file.
16685
16686 2005-10-21  Simon Josefsson  <jas@extundo.com>
16687
16688         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
16689         Bruno Haible <bruno@clisp.org>.
16690
16691         * m4/gc-des.m4: New file.
16692
16693 2005-10-21  Simon Josefsson  <jas@extundo.com>
16694
16695         * m4/arctwo.m4: New file.
16696
16697         * m4/gc-arctwo.m4: New file.
16698
16699 2005-10-21  Simon Josefsson  <jas@extundo.com>
16700
16701         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
16702         block.
16703
16704 2005-10-21  Simon Josefsson  <jas@extundo.com>
16705
16706         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
16707         <bruno@clisp.org>.
16708
16709         * lib/hmac-sha1.c (hmac_sha1): Likewise.
16710
16711         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
16712         Bruno Haible <bruno@clisp.org>.
16713
16714         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
16715         <bruno@clisp.org>.
16716
16717 2005-10-21  Simon Josefsson  <jas@extundo.com>
16718
16719         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
16720
16721 2005-10-21  Simon Josefsson  <jas@extundo.com>
16722
16723         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
16724
16725 2005-10-21  Simon Josefsson  <jas@extundo.com>
16726
16727         * lib/des.h, lib/des.c: New files.
16728
16729         * lib/gc-gnulib.c: Support DES.c
16730
16731 2005-10-21  Simon Josefsson  <jas@extundo.com>
16732
16733         * lib/arctwo.h, lib/arctwo.c: New files.
16734
16735         * lib/gc-gnulib.c: Support ARCTWO.
16736
16737 2005-10-21  Simon Josefsson  <jas@extundo.com>
16738
16739         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
16740         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
16741
16742 2005-10-21  Simon Josefsson  <jas@extundo.com>
16743
16744         * gnulib-tool (func_import, func_create_testdir): Define automake
16745         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
16746         Makefile.am snippet),
16747         suggested by Bruno Haible <bruno@clisp.org>.
16748
16749         * modules/gc (Makefile.am): Use it.
16750
16751 2005-10-21  Bruno Haible  <bruno@clisp.org>
16752
16753         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
16754         patch.
16755
16756 2005-10-19  Simon Josefsson  <jas@extundo.com>
16757
16758         * tests/test-gc-rijndael.c: New file.
16759
16760         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
16761
16762 2005-10-19  Simon Josefsson  <jas@extundo.com>
16763
16764         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
16765         interface too.
16766
16767 2005-10-19  Simon Josefsson  <jas@extundo.com>
16768
16769         * tests/test-gc-arcfour.c: New file.
16770
16771         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
16772
16773 2005-10-19  Simon Josefsson  <jas@extundo.com>
16774
16775         * modules/gc-md4, modules/gc-md4-tests: New file.
16776
16777         * tests/test-gc-md4.c: New file.
16778
16779 2005-10-19  Simon Josefsson  <jas@extundo.com>
16780
16781         * m4/gc-md4.m4: New file.
16782
16783 2005-10-19  Simon Josefsson  <jas@extundo.com>
16784
16785         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
16786         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
16787         <kasal@ucw.cz>.
16788
16789 2005-10-19  Simon Josefsson  <jas@extundo.com>
16790
16791         * m4/gc-arcfour.m4: New file.
16792
16793         * m4/gc-rijndael.m4: New file.
16794
16795 2005-10-19  Simon Josefsson  <jas@extundo.com>
16796
16797         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
16798
16799 2005-10-19  Simon Josefsson  <jas@extundo.com>
16800
16801         * lib/gc-gnulib.c: Support ARCFOUR.
16802
16803 2005-10-19  Simon Josefsson  <jas@extundo.com>
16804
16805         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
16806         support.
16807
16808         * lib/gc.h: Add ECB enum type.
16809
16810         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
16811
16812 2005-10-18  Simon Josefsson  <jas@extundo.com>
16813
16814         * tests/test-md5.c: New file.
16815
16816         * modules/md5-tests: New file.
16817
16818 2005-10-18  Simon Josefsson  <jas@extundo.com>
16819
16820         * tests/test-md4.c: New file.
16821
16822         * modules/md4, modules/md4-tests: New files.
16823
16824 2005-10-18  Simon Josefsson  <jas@extundo.com>
16825
16826         * m4/md4.m4: New file.
16827
16828 2005-10-18  Simon Josefsson  <jas@extundo.com>
16829
16830         * lib/md4.h, lib/md4.c: New files, based on md5.?.
16831
16832 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
16833
16834         * gnulib-tool (func_create_testdir): Omit the second check whether
16835         BUILT_SOURCES in nonempty.
16836
16837 2005-10-17  Simon Josefsson  <jas@extundo.com>
16838
16839         * tests/test-rijndael.c: New file.
16840
16841 2005-10-17  Simon Josefsson  <jas@extundo.com>
16842
16843         * modules/sha1: Depend on stdint instead of md5.
16844
16845         * modules/md5: Depend on stdint, remove uint32_t.
16846
16847 2005-10-17  Simon Josefsson  <jas@extundo.com>
16848
16849         * modules/gc-sha1-tests: New file.
16850
16851         * tests/test-gc-sha1.c: New file.
16852
16853 2005-10-17  Simon Josefsson  <jas@extundo.com>
16854
16855         * m4/md5.m4: Remove call to uint32_t.m4.
16856
16857 2005-10-17  Simon Josefsson  <jas@extundo.com>
16858
16859         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
16860
16861         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
16862         md5.h.
16863
16864         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
16865
16866         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
16867
16868 2005-10-17  Simon Josefsson  <jas@extundo.com>
16869
16870         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
16871
16872 2005-10-17  Simon Josefsson  <jas@extundo.com>
16873
16874         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
16875
16876 2005-10-17  Simon Josefsson  <jas@extundo.com>
16877
16878         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
16879
16880         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
16881
16882 2005-10-17  Bruno Haible  <bruno@clisp.org>
16883
16884         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
16885         that it can also be used in a test.
16886
16887 2005-10-16  Bruno Haible  <bruno@clisp.org>
16888
16889         * gnulib-tool (func_emit_tests_Makefile_am): Also define
16890         TESTS_ENVIRONMENT, so that individual tests can augment it.
16891
16892         * gnulib-tool (func_create_testdir): Use an intermediate target for
16893         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
16894         macros, like $(ALLOCA_H), which cannot be passed through the command
16895         line.
16896
16897 2005-10-15  Simon Josefsson  <jas@extundo.com>
16898
16899         * modules/rijndael-tests: New file.
16900
16901         * modules/rijndael: New file.
16902
16903 2005-10-15  Simon Josefsson  <jas@extundo.com>
16904
16905         * m4/rijndael.m4: New file.
16906
16907 2005-10-15  Simon Josefsson  <jas@extundo.com>
16908
16909         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
16910
16911         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
16912
16913 2005-10-14  Simon Josefsson  <jas@extundo.com>
16914
16915         * tests/test-arcfour.c: New file.
16916
16917         * modules/arcfour, modules/arcfour-tests: New files.
16918
16919 2005-10-14  Simon Josefsson  <jas@extundo.com>
16920
16921         * m4/arcfour.m4: New file.
16922
16923 2005-10-14  Simon Josefsson  <jas@extundo.com>
16924
16925         * lib/arcfour.h, lib/arcfour.c: New files.
16926
16927 2005-10-14  Roland McGrath  <roland@redhat.com>
16928
16929         Import from libc.  [BZ #1331]
16930         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
16931         macro argument.
16932         Reported by Matej Vela <vela@debian.org>.
16933
16934 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
16935
16936         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
16937         include <wchar.h>; no longer needed.
16938
16939 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
16940
16941         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
16942
16943 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
16944         and  Ulrich Drepper  <drepper@redhat.com>
16945
16946         Import from libc.
16947         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
16948         instead of inline stream orientation test and two separate
16949         function calls.  Pay no attention to USE_IN_LIBIO.
16950
16951 2005-10-13  Simon Josefsson  <jas@extundo.com>
16952
16953         * modules/gc-hmac-md5-tests: New file.
16954
16955         * tests/test-gc-hmac-sha1.c: New file.
16956
16957         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
16958
16959         * modules/gc-hmac-md5-tests: New file.
16960
16961         * tests/test-gc-md5.c: New file.
16962
16963         * modules/gc-md5-tests: New file.
16964
16965 2005-10-13  Simon Josefsson  <jas@extundo.com>
16966
16967         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
16968         Move memory allocation outside of loop.
16969
16970 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
16971
16972         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
16973         intermediate directory is in a read-only file system.  Problem
16974         reported by Eric Blake.
16975
16976 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
16977
16978         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
16979
16980 2005-10-12  Simon Josefsson  <jas@extundo.com>
16981
16982         * tests/test-hmac-sha1.c: New file.
16983
16984         * modules/hmac-sha1-tests: New file.
16985
16986         * modules/hmac-sha1: New file.
16987
16988 2005-10-12  Simon Josefsson  <jas@extundo.com>
16989
16990         * modules/gc-sha1: New file.
16991
16992 2005-10-12  Simon Josefsson  <jas@extundo.com>
16993
16994         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
16995
16996         * tests/test-gc-pbkdf2-sha1.c: New file.
16997
16998 2005-10-12  Simon Josefsson  <jas@extundo.com>
16999
17000         * modules/gc-md5, modules/gc-hmac-md5: New files.
17001
17002         * modules/gc (Files): Remove md5, memxor and hmac files.
17003
17004 2005-10-12  Simon Josefsson  <jas@extundo.com>
17005
17006         * m4/gc-pbkdf2-sha1.m4: New file.
17007
17008         * m4/gc-hmac-sha1.m4: New file.
17009
17010         * m4/gc-sha1: New file.
17011
17012         * m4/hmac-sha1.m4: New file.
17013
17014 2005-10-12  Simon Josefsson  <jas@extundo.com>
17015
17016         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
17017
17018         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
17019
17020 2005-10-12  Simon Josefsson  <jas@extundo.com>
17021
17022         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
17023         suggested by Bruno Haible <bruno@clisp.org>.
17024
17025 2005-10-12  Simon Josefsson  <jas@extundo.com>
17026
17027         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
17028
17029 2005-10-12  Simon Josefsson  <jas@extundo.com>
17030
17031         * lib/gc-pbkdf2-sha1.c: New file.
17032
17033         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
17034
17035 2005-10-12  Simon Josefsson  <jas@extundo.com>
17036
17037         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
17038
17039         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
17040
17041 2005-10-12  Simon Josefsson  <jas@extundo.com>
17042
17043         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
17044         GC_USE_HMAC_MD5, respectively.
17045
17046         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
17047         (gc_md5): Fix typo.
17048
17049         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
17050
17051         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
17052
17053         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
17054
17055 2005-10-12  Bruno Haible  <bruno@clisp.org>
17056
17057         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
17058         Reported by Stepan Kasal <kasal@ucw.cz>.
17059
17060 2005-10-11  Simon Josefsson  <jas@extundo.com>
17061
17062         * tests/test-crc.c: New file.
17063
17064         * modules/crc, modules/crc-tests: New files.
17065
17066 2005-10-11  Simon Josefsson  <jas@extundo.com>
17067
17068         * m4/crc.m4: New file.
17069
17070 2005-10-11  Simon Josefsson  <jas@extundo.com>
17071
17072         * lib/gc.h: Add gc_hash and gc_hash_buffer.
17073
17074         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
17075
17076         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
17077
17078 2005-10-11  Simon Josefsson  <jas@extundo.com>
17079
17080         * lib/crc.h, lib/crc.c: New files.
17081
17082         * lib/gc.h (gc_hash_buffer): Add doc.
17083
17084 2005-10-11  Bruno Haible  <bruno@clisp.org>
17085
17086         * modules/c-strcasestr: New file.
17087         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
17088
17089 2005-10-11  Bruno Haible  <bruno@clisp.org>
17090
17091         * modules/c-strcase: New file.
17092         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
17093
17094 2005-10-11  Bruno Haible  <bruno@clisp.org>
17095
17096         * lib/strcasecmp.c: Include limits.h.
17097         (strcasecmp): Avoid integer overflow on exotic platforms.
17098         * lib/strncasecmp.c: Include limits.h.
17099         (strncasecmp): Avoid integer overflow on exotic platforms.
17100         Reported by Paul Eggert.
17101
17102 2005-10-11  Bruno Haible  <bruno@clisp.org>
17103
17104         * lib/c-strcasestr.h: New file, from GNU gettext.
17105         * lib/c-strcasestr.c: New file, from GNU gettext.
17106
17107 2005-10-11  Bruno Haible  <bruno@clisp.org>
17108
17109         * lib/c-strcase.h: New file, from GNU gettext.
17110         * lib/c-strcasecmp.c: New file, from GNU gettext.
17111         * lib/c-strncasecmp.c: New file, from GNU gettext.
17112
17113 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
17114
17115         * modules/mempcpy (License): GPL -> LGPL.
17116         * modules/strchrnul (License): Likewise.
17117         * modules/sysexits (License): Likewise.
17118
17119 2005-10-08  Simon Josefsson  <jas@extundo.com>
17120
17121         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
17122
17123 2005-10-07  Simon Josefsson  <jas@extundo.com>
17124
17125         * m4/memxor.m4: Remove gl_C_RESTRICT call.
17126
17127 2005-10-06  Simon Josefsson  <jas@extundo.com>
17128
17129         * tests/test-hmac-md5.c: New file.
17130
17131         * modules/hmac-md5-tests: New file.
17132
17133         * modules/hmac-md5: New file.
17134
17135 2005-10-06  Simon Josefsson  <jas@extundo.com>
17136
17137         * m4/hmac-md5.m4: New file.
17138
17139         * m4/memxor.m4: Require gl_C_RESTRICT.
17140
17141 2005-10-06  Simon Josefsson  <jas@extundo.com>
17142
17143         * lib/memxor.c (memxor): Avoid casts and warnings.
17144
17145 2005-10-06  Simon Josefsson  <jas@extundo.com>
17146
17147         * lib/hmac-md5.c: New file.
17148
17149         * lib/hmac.h: New file.
17150
17151 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
17152
17153         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
17154         promotes to int, not unsigned int, to catch the AIX 5.3
17155         compiler bug.
17156
17157 2005-10-05  Simon Josefsson  <jas@extundo.com>
17158
17159         * modules/memxor: New file.
17160
17161         * modules/iconv (Files): Move config.rpath to havelib, it is used
17162         there.
17163
17164         * modules/havelib (Files): Add config.rpath.
17165
17166 2005-10-05  Simon Josefsson  <jas@extundo.com>
17167
17168         * m4/memxor.m4: New file.
17169
17170 2005-10-05  Simon Josefsson  <jas@extundo.com>
17171
17172         * lib/memxor.c (memxor): Fix compiler error.
17173
17174         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
17175         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
17176
17177         * lib/memxor.h, lib/memxor.c: New files.
17178
17179         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
17180         we assume all systems have it, suggested by Jim Meyering
17181         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
17182         any systems lack sys/socket.h; mingw32 is known to lack it, but we
17183         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
17184         same reasons.
17185
17186 2005-10-05  Simon Josefsson  <jas@extundo.com>
17187
17188         * config/srclist.txt: Add glibc bug 1423 for md5.h.
17189
17190 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
17191
17192         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
17193         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
17194         needed, since the source code now assumes these .h files.
17195
17196 2005-10-05  Derek Price  <derek@ximbiot.com>
17197
17198         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
17199
17200 2005-10-05  Bruno Haible  <bruno@clisp.org>
17201
17202         * modules/stdint (License): Change to LGPL.
17203
17204 2005-10-04  Simon Josefsson  <jas@extundo.com>
17205
17206         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
17207         D. Baushke" <mdb@gnu.org>.
17208
17209 2005-10-04  Bruno Haible  <bruno@clisp.org>
17210
17211         * lib/verify.h (verify_true): Provide alternative definition for C++.
17212
17213 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
17214
17215         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
17216         (SSIZE_MAX): New macro, if not already defined.
17217         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
17218         than 2 GiB.
17219
17220 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
17221
17222         Sync from coreutils.
17223         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
17224         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
17225         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
17226         ULLONG_MAX doesn't work with 2.7.2.1.
17227
17228 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
17229
17230         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
17231         From Ben Pfaff.
17232
17233         * modules/exclude (Depends-on): Depend on verify.
17234         * modules/strtoimax (Depends-on): Likewise.
17235         * modules/utimecmp (Depends-on): Likewise.
17236
17237 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
17238
17239         * lib/exclude.c: Include verify.h.
17240         (verify): Remove.  All callers changed to use verify.h's version.
17241         * lib/strtoimax.c: Likewise.
17242         * lib/utimecmp.c: Likewis.e
17243
17244         Sync from coreutils.
17245         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
17246         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
17247         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
17248         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
17249         bother returning ENOSYS if settimeofday or stime fails; just let
17250         them return whatever errno they want to return.
17251         * lib/utimens.c: Include unistd.h, for dup2.
17252         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
17253         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
17254
17255 2005-10-02  Jim Meyering  <jim@meyering.net>
17256
17257         Sync from coreutils.
17258         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
17259         from glibc-2.2.5 that fails for read-only files.
17260
17261 2005-10-02  Jim Meyering  <jim@meyering.net>
17262
17263         Sync from coreutils.
17264         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
17265         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
17266         `#if HAVE_CONFIG_H'.
17267         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
17268         Remove AT_FDCWD test.
17269         Do not consume the fd unless successful.
17270         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
17271         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
17272         block, so that we don't even try to compile it if settimeofday is
17273         available.  This works around a compilation failure on OSF1 V5.1,
17274         due to stime requiring a `long int*' while tv_sec is `int'.
17275
17276 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
17277
17278         Sync from coreutils.
17279         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
17280         against `yes', rather than just testing for nonempty.
17281
17282 2005-10-01  Simon Josefsson  <jas@extundo.com>
17283
17284         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
17285         and Darwin.
17286
17287         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
17288         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
17289         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
17290         freeaddrinfo and gai_strerror are declared by the POSIX headers.
17291         Check if struct addrinfo is declared.
17292
17293 2005-10-01  Simon Josefsson  <jas@extundo.com>
17294
17295         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
17296         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
17297         AI_* and EAI_* definitions.  Protect function declarations.
17298
17299 2005-10-01  Jim Meyering  <jim@meyering.net>
17300
17301         Sync from coreutils.
17302
17303         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
17304         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
17305         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
17306         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
17307         in the inet and nsl libraries.  Required on Solaris 5.7.
17308
17309 2005-10-01  Jim Meyering  <jim@meyering.net>
17310
17311         Sync from coreutils.
17312         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
17313         in the inet and nsl libraries.  Required on Solaris 5.7.
17314
17315 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
17316
17317         * lib/getdelim.c (getdelim): Remove unused variables.
17318
17319 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
17320
17321         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
17322         so that the code works even with ancient cpp.  Portability problem
17323         with GCC 2.7.2.1 reported by Thomas M.Ott.
17324
17325 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
17326
17327         * modules/regex (Depends-on): Add strcase.
17328
17329         * modules/gethostname (Licence): Change from GPL to LGPL, since
17330         gethostname.c is a trivial implementation of a standard library
17331         function.
17332         * modules/poll (License): Change from GPL to LGPL, since it's
17333         derived from LGPL code.
17334
17335 2005-09-27  Jim Meyering  <jim@meyering.net>
17336
17337         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
17338         HAVE_CONFIG_H.
17339
17340         * lib/intprops.h (signed_type_or_expr__): Define.
17341         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
17342         for unsigned types.
17343
17344 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
17345
17346         * lib/verify.h (verify_expr): Remove, replacing with:
17347         (verify_true): New macro that returns true instead of void.
17348         (verify_type__): Remove.
17349         (verify): Use verify_true rather than verify_type__.
17350
17351 2005-09-26  Bruno Haible  <bruno@clisp.org>
17352
17353         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
17354         is necessary.
17355         (lib_SOURCES): Remove mbchar.c.
17356         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
17357         (Files): Add m4/mbrtowc.m4.
17358         * modules/mbiter: Likewise.
17359         * modules/mbuiter: Likewise.
17360
17361 2005-09-26  Bruno Haible  <bruno@clisp.org>
17362
17363         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
17364         compile mbchar.c if they are not both present.
17365         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
17366         * m4/mbiter.m4 (gl_MBITER): Likewise.
17367         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
17368         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
17369         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
17370
17371 2005-09-25  Jim Meyering  <jim@meyering.net>
17372
17373         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
17374         also uses socklen_t.
17375
17376 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
17377
17378         * lib/utimens.c (ENOSYS): Define if not already defined.
17379         (futimens): Support having a null PATH if the file descriptor
17380         is nonnegative.
17381
17382         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
17383         Remove.
17384         (__attribute): Define to empty unless GCC 3.1 or later.
17385         This works around a core dump on OpenBSD 3.4, which has GCC
17386         2.95.3, which dumps core when given __attribute__(()).  It also
17387         simplifies other tests, since we really don't want to bother with
17388         worrying about which ancient version of GCC supported what.
17389         Original problem reported by Yoann Vandoorselaere, with part of
17390         the fix suggested by Derek Price.
17391
17392 2005-09-24  Jim Meyering  <jim@meyering.net>
17393
17394         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
17395         so we can once again use a positive bitfield width of 1 -- now we
17396         don't have to explain why we were using a bitfield width of 2.
17397
17398 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
17399
17400         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
17401         and similarly for the other external symbols.  Problem reported
17402         by James Gallager.
17403
17404         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
17405         bug reported by Jim Meyering.
17406
17407         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
17408         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
17409         not needed, since socklen is a prerequisite module.
17410
17411 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
17412
17413         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
17414         Problem reported by Eric Blake.
17415         (getaddrinfo): Initialize se so that it's not garbage.
17416         Redo internal storage allocation so that it doesn't make unportable
17417         assumptions about alignment.
17418         Fix a memory leak.
17419
17420         * lib/utimens.c (futimens): Use futimesat if available.
17421         Prefer it to futimes since it doesn't have the futimes bug.
17422
17423         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
17424         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
17425         Instead, declare a function that returns a pointer to an array,
17426         and use verify_type__ to declare the size of the array.
17427         Problem and germ of a solution reported by Bruno Haible.
17428         (verify_type__): Use 2, not 1, for bitfield size, to avoid
17429         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
17430
17431 2005-09-23  Jim Meyering  <jim@meyering.net>
17432
17433         Sync from coreutils.
17434         Correct build failure (socklen_t not defined) on at least
17435         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
17436         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
17437
17438 2005-09-23  Jim Meyering  <jim@meyering.net>
17439
17440         * modules/getaddrinfo (Depends-on): Add socklen.
17441
17442 2005-09-23  Bruno Haible  <bruno@clisp.org>
17443
17444         * tests/test-verify.c: New file.
17445
17446 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17447
17448         Sync from coreutils.
17449
17450         * modules/argmatch (Depends-on): Add verify.
17451         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
17452         unistd-safer.
17453         * modules/save-cwd (Depends-on): Likewise.
17454
17455         * modules/openat (Files): Add lib/openat-die.c.
17456         (Depends-on): Remove error, exitfail.
17457         Add dirname.
17458
17459         * modules/verify: New file.
17460         * MODULES.html.sh (Diagnostics <assert.h>): New section,
17461         with "verify" module.
17462
17463 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17464
17465         Sync from coreutils.
17466
17467         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
17468         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
17469         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
17470         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
17471         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
17472         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
17473         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
17474         Don't bother checking for string.h, stdlib.h, unistd.h.
17475         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
17476         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
17477         module's job.
17478         * m4/jm-macros.m4 (gl_MACROS): Likewise.
17479         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
17480
17481         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
17482         (gl_GETDATE): Use it.
17483
17484         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
17485
17486 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17487
17488         Sync from coreutils.
17489
17490         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
17491         stat-time.h.
17492         * lib/argmatch.h: Include verify.h
17493         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
17494         (ARGMATCH_ASSERT): Remove; unused.
17495         * lib/canonicalize.c: Assume STDC_HEADERS.
17496         * lib/exclude.c: Include "strcase.h".
17497         * lib/regex_internal.h [!defined _LIBC]: Likewise.
17498         * lib/getusershell.c: Include stdio--.h rather than stdio.h
17499         and stdio-safer.h.
17500         (getusershell): Call fopen, not fopen_safer.
17501         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
17502         Do not include unistd-safer.h.
17503         (save_cwd): Don't call fd_safer; no longer needed
17504         now that we include fcntl--.h.
17505
17506         * lib/getdate.y (relative_time): New type.
17507         (RELATIVE_TIME_0): New constant.
17508         (parser_control): Use relative_time instead of doing it ourselves.
17509         (%union): Add new relative_time rel member.
17510         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
17511         Now typeless.
17512         (relunit, relunit_snumber): Now of type rel.
17513         (zone, rel, relunit, get_date): Adjust to above changes.
17514
17515         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
17516         Do not include unistd-safer.h.
17517         (getloadavg): Don't call fd_safer; no longer needed
17518         now that we include fcntl--.h.
17519
17520         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
17521         (make_dir_parents): Treat ENOSYS like EEXIST.
17522
17523         Improve quality of diagnostics on restore_cwd failure.
17524         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
17525         (make_dir_parents): Last arg is now int * (for errno), not bool *.
17526         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
17527         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
17528         each time through the loop.  Do not diagnose restore_cwd failure;
17529         that is the caller's job (and perhaps the caller does not care).
17530
17531         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
17532         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
17533         If the file already exists but is not a directory, don't bother
17534         to try to make its parents.
17535         Close potential file descriptor leak if we can't chdir("/") (!).
17536         Don't always return true if chdir($PWD) fails; return true only
17537         if the requested action was done successfully (except for the
17538         chdir($PWD)).
17539         Don't log final directory unless we actually made it.
17540         Refactor to avoid duplicate code to fix up permissions.
17541         Don't attempt to fix up parent permissions if chdir($PWD) fails.
17542
17543         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
17544         to make it a bit faster and (I hope) clearer.
17545         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
17546         Fix bug in formats like %2N.
17547
17548         * lib/verify.h: New file.
17549
17550 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
17551
17552         Sync from coreutils.
17553         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
17554
17555 2005-09-22  Jim Meyering  <jim@meyering.net>
17556
17557         Sync from coreutils.
17558
17559         * m4/lstat.m4 (gl_FUNC_LSTAT):
17560         Use AC_LIBSOURCES to require lstat.c and lstat.h.
17561         Remove obsolete comment.
17562         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
17563         * m4/xstrtod.m4: Likewise.
17564
17565         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
17566
17567 2005-09-22  Jim Meyering  <jim@meyering.net>
17568
17569         Sync from coreutils.
17570
17571         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
17572
17573         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
17574         the .tm_year member, since otherwise gcc-4.0 would now warn about
17575         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
17576
17577         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
17578         order to avoid an unsuppressible warning from gcc on 64-bit systems.
17579
17580         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
17581         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
17582         when run in a time zone for which daylight savings time is in effect
17583         for the starting date.
17584
17585         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
17586         stop us from restricting permissions of just-created absolute-named
17587         directories.
17588         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
17589         to restore initial working directory.
17590         * lib/mkdir-p.c (make_dir_parents): New parameter:
17591         different_working_dir, to tell caller if/when we change the working
17592         directory and are unable to return to the initial one.
17593         * lib/mkdir-p.h (make_dir_parents): Update prototype.
17594         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
17595         `return false'.  This fixes a bug introduced on 2004-07-30.
17596
17597         * lib/openat.c (fdopendir): Be sure to close the supplied
17598         file descriptor before returning.  This makes our replacement
17599         implementation a little closer to Solaris's, where fdopendir
17600         ties the file descriptor to the returned DIR* pointer.
17601         * lib/openat.c (unlinkat): New function.
17602         * lib/openat.h (unlinkat): Add prototype.
17603         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
17604         (openat_restore_fail): Rename from openat_restore_die.
17605         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
17606
17607         Provide an alternative to exiting immediately upon save_cwd or
17608         restore_cwd failure.  Now, an application can arrange e.g.,
17609         to perform a longjump in that case.
17610         * lib/openat.c: Include dirname.h.
17611         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
17612         (rpl_openat, fdopendir, fstatat): Call openat_save_die
17613         and openat_restore_die rather than calling error directly.
17614         Don't include "error.h" or "exitfail.h"; they're no longer needed.
17615
17616         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
17617         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
17618         define.
17619
17620         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
17621         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
17622                             int utc, int nanoseconds);
17623         Background:
17624         date should not have to allocate a megabyte of virtual memory to
17625         handle a format argument like +%1048575T.  When implemented with
17626         strftime, it must allocate such a buffer, use strftime to fill it
17627         in, print it, then free it.
17628         With fprintftime, it simply prints everything and exits.
17629         With no need for memory allocation, that's one fewer way to fail.
17630         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
17631         optional field width, not before, so we accept %9:z, not %:9z.
17632         (my_strftime): Be sure to use L_('x') for literals.
17633
17634         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
17635         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
17636         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
17637         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
17638         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
17639         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
17640         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
17641         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
17642         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
17643         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
17644         * lib/xgethostname.c, lib/xreadlink.c:
17645         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
17646
17647         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
17648         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
17649         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
17650         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
17651         and don't include <sys/file.h>).
17652
17653 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
17654
17655         Sync from coreutils.
17656
17657         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
17658         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
17659         [!LDAV_DONE]: Avoid unused variable warning.
17660
17661 2005-09-21  Bruno Haible  <bruno@clisp.org>
17662
17663         * lib/unicodeio.h (unicode_to_mb): New declaration.
17664
17665 2005-09-20  Derek Price  <derek@ximbiot.com>
17666
17667         * lib/getaddrinfo.c: Don't include <netdb.h> included from
17668         getaddrinfo.h.
17669
17670 2005-09-20  Bruno Haible  <bruno@clisp.org>
17671
17672         * gnulib-tool: Remove trailing slashes from the values specified for
17673         --source-base, --m4-base, --tests-base, --aux-dir.
17674         Suggested by Simon Josefsson <jas@extundo.com>.
17675
17676 2005-09-20  Bruno Haible  <bruno@clisp.org>
17677
17678         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
17679         func_modules_to_filelist, func_import, func_create_testdir): Make all
17680         sorting results locale-independent, so that gnulib-cache.m4 doesn't
17681         change when gnulib-tool is invoked in a different locale.
17682
17683 2005-09-19  Simon Josefsson  <jas@extundo.com>
17684
17685         * m4/socklen.m4: Fix typo.
17686
17687 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
17688
17689         Use a consistent style for including <config.h>.
17690         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
17691         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
17692         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
17693         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
17694         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
17695         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
17696         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
17697         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
17698         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
17699         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
17700         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
17701         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
17702         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
17703         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
17704         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
17705         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
17706         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
17707         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
17708         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
17709         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
17710         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
17711         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
17712         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
17713         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
17714         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
17715         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
17716         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
17717         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
17718         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
17719         lib/xstrtoumax.c, lib/yesno.c:
17720         Standardize inclusion of config.h.
17721         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
17722         lib/inttostr.h:  Removed inclusion of config.h from header files.
17723         * lib/inttostr.c:  Adjusted in-tree users.
17724         * lib/timespec.h: Remove superfluous warning to include config.h.
17725         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
17726         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
17727         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
17728         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
17729         config.h with HAVE_CONFIG_H.
17730
17731 2005-09-19  Jim Meyering  <jim@meyering.net>
17732
17733         * modules/pathmax (License): Change to LGPL.
17734
17735 2005-09-19  Derek Price  <derek@ximbiot.com>
17736
17737         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
17738
17739 2005-09-19  Bruno Haible  <bruno@clisp.org>
17740
17741         * gnulib-tool (import): Provide default for --tests-base.
17742
17743 2005-09-19  Bruno Haible  <bruno@clisp.org>
17744
17745         * doc/quote.texi: New file, extracted from gnulib.texi.
17746         * doc/ctime.texi: New file, extracted from gnulib.texi.
17747         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
17748         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
17749         * doc/gnulib.texi: Include them.
17750
17751 2005-09-18  Bruno Haible  <bruno@clisp.org>
17752
17753         Portability fix.
17754         * gnulib-tool (func_readlink): New function.
17755         (func_ln_if_changed): Use it.
17756
17757 2005-09-18  Bruno Haible  <bruno@clisp.org>
17758
17759         * gnulib-tool: Support --with-tests also with --import.
17760         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
17761         (func_import): Use variables $testsbase and $inctests. Emit a
17762         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
17763         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
17764         SUBDIRS += $testsdir.
17765         (func_create_testdir): Update.
17766
17767 2005-09-18  Bruno Haible  <bruno@clisp.org>
17768
17769         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
17770         instead of $dry_run.
17771         (func_cp_if_changed, func_mv_if_changed): Remove functions.
17772         (func_ln_if_changed): Don't handle dry-run here.
17773         (func_import): In dry-run mode, detect more precisely which actions
17774         would be performed, and don't use "...ing" verbs.
17775
17776 2005-09-18  Bruno Haible  <bruno@clisp.org>
17777
17778         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
17779         (func_import): Use join on two temporary files instead of three nested
17780         loops, in order to determine which files are new or old.
17781
17782 2005-09-18  Bruno Haible  <bruno@clisp.org>
17783
17784         * gnulib-tool (func_import): Comment out code that spits out the
17785         new files with --dry-run.
17786
17787 2005-09-18  Bruno Haible  <bruno@clisp.org>
17788
17789         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
17790
17791 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
17792
17793         * lib/stat-time.h: New file.
17794         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
17795         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
17796         in a different way.
17797         (timespec_cmp): New function.
17798         * lib/utimecmp.c: Include stat-time.h.
17799         (SYSCALL_RESOLUTION): Depend on whether various struct stat
17800         members exist, not on the obsolescent ST_MTIM_NSEC.
17801         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
17802
17803 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
17804
17805         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
17806
17807 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
17808
17809         * MODULES.html.sh (File system functions): Add stat-time.
17810         * modules/stat-time: New file.
17811         * modules/timespec (Files): Remove m4/st_mtim.m4; this
17812         is now done in a different way, by the stat-time module.
17813         * modules/utimecmp (Depends-on): Add stat-time.
17814
17815 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
17816
17817         * m4/st_mtim.m4: Remove.  Superseded by...
17818         * m4/stat-time.m4: New file.
17819         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
17820         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
17821
17822 2005-09-15  Derek Price  <derek@ximbiot.com>
17823
17824         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
17825
17826 2005-09-15  Derek Price  <derek@ximbiot.com>
17827
17828         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
17829         * lib/regex_internal.c: Ditto, using this...
17830         (__GNUC_PREREQ): ...new macro.
17831         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
17832         using...
17833         (__GNUC_PREREQ): ...this new macro.
17834
17835         * lib/strstr.h: Include string.h. Define strstr as a macro here.
17836
17837 2005-09-15  Derek Price  <derek@ximbiot.com>
17838             Paul Eggert  <eggert@cs.ucla.edu>
17839
17840         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
17841         changes, consolidating in...
17842         * lib/regex_internal.h: ...this file.
17843
17844 2005-09-13  Jim Meyering  <jim@meyering.net>
17845
17846         * lib/canon-host.c: Filter through gnu indent and reword comments
17847         slightly.
17848         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
17849
17850 2005-09-13  Derek Price  <derek@ximbiot.com>
17851
17852         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
17853         failure.
17854         Reported by Jim Meyering  <jim@meyering.net>.
17855
17856 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
17857
17858         * lib/base64.c: Typo.
17859         (base64_encode): Put b64str in initialized data section.
17860
17861 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
17862
17863         Merge glibc and coreutils changes into gnulib, plus a few
17864         extra fixes.
17865         * lib/md5.c: Use #error rather than a string.
17866         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
17867         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
17868         (__attribute__): Define to empty for non recent-GCC.
17869         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
17870         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
17871         Renamed from their non-__ counterparts, with new macros replacing
17872         them if not _LIBC.  Add __THROW attribute.
17873         (rol): Remove.
17874         (struct md5_ctx): Align buffer if using GCC.
17875         * lib/sha1.h (struct sha1_ctx): Likewise.
17876         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
17877         The old name was backwards.
17878         (NOTSWAP): Remove; not used.
17879         (rol): New macro, moved here from md5.h.
17880         (sha1_process_block): Remove a FIXME that doesn't make sense.
17881
17882 2005-09-12  Derek Price  <derek@ximbiot.com>
17883
17884         Return usable errors from canon-host.
17885         * lib/canon-host.h: New file.
17886         * lib/canon-host.c (canon_host): Wrap...
17887         (canon_host_r): ...this new function, which now relies exclusively on
17888         getaddrinfo.
17889         (ch_strerror): New function.
17890         (last_cherror): New global.
17891         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
17892         interface.
17893         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
17894         void *.
17895         (freeaddrinfo): Free ai->ai_canonname when set.
17896
17897 2005-09-12  Derek Price  <derek@ximbiot.com>
17898
17899         Make canon-host require getaddrinfo.
17900         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
17901         AC_LIBSOURCE canon-host.h.  Call...
17902         (gl_PREREQ_CANON_HOST): ...this new function, which requires
17903         gl_GETADDRINFO.
17904         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
17905
17906 2005-09-12  Derek Price  <derek@ximbiot.com>
17907
17908         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
17909         LGPL.
17910         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
17911
17912 2005-09-12  Derek Price  <derek@ximbiot.com>
17913
17914         * lib/gai_strerror.c: Include config.h when available.  Include
17915         getaddrinfo.h before other headers to test interface.
17916         Reported by Larry Jones <lawrence.jones@ugs.com>.
17917
17918 2005-09-12  Derek Price  <derek@ximbiot.com>
17919             Paul Eggert  <eggert@cs.ucla.edu>
17920
17921         * modules/glob (Files): Add glob-libc.h.
17922
17923 2005-09-12  Derek Price  <derek@ximbiot.com>
17924             Paul Eggert  <eggert@cs.ucla.edu>
17925
17926         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
17927         glob_.h, glob-libc.h.
17928         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
17929
17930 2005-09-12  Derek Price  <derek@ximbiot.com>
17931             Paul Eggert  <eggert@cs.ucla.edu>
17932
17933         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
17934         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
17935         protecting things that should be done only in gnulib contexts.
17936         * lib/glob_.h: New file, containing only the glob things needed for
17937         gnulib.
17938         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
17939         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
17940         (glob, globfree, glob_pattern_p): Now defined simply in terms of
17941         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
17942         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
17943         and to respect the namespace rules better.
17944
17945 2005-09-08  Simon Josefsson  <jas@extundo.com>
17946
17947         * modules/socklen: New file.
17948
17949 2005-09-08  Simon Josefsson  <jas@extundo.com>
17950
17951         * m4/socklen.m4: New file.
17952
17953 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17954
17955         * modules/utimens (Files): Add m4/utimbuf.m4, since
17956         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
17957         Reported by Sergey Poznyakoff.
17958
17959 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17960
17961         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
17962         definitions, since that's the preferred style in glibc.
17963         Fix a minor spacing issue, and update copyright notice to match
17964         glibc's.
17965
17966 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
17967
17968         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
17969
17970 2005-09-06  Simon Josefsson  <jas@extundo.com>
17971
17972         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
17973         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
17974
17975 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
17976
17977         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
17978         warning.
17979
17980 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
17981
17982         * config/srclist.txt: Add glibc bug 1302.
17983
17984 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
17985
17986         Change bitset word type from unsigned int to unsigned long int,
17987         as this has better performance on typical 64-bit hosts.
17988         Port bitset code to hosts with unusual word sizes.
17989         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
17990         (build_collating_symbol):
17991         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
17992         argument is a bitset.  This is merely a style issue, but it makes
17993         it clearer that an entire array is expected.
17994         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
17995         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
17996         Port to the case where bitset_word is not the same as unsigned int.
17997         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
17998         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
17999         Likewise.
18000         * lib/regexec.c (check_dst_limits_calc_pos_1,
18001         check_subexp_matching_top):
18002         (build_trtable, group_nodes_into_DFAstates):
18003         Likewise.
18004         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
18005         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
18006         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
18007         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
18008         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
18009         * lib/regcomp.c (optimize_subexps, lower_subexp):
18010         Work even if bitset_word has holes in its bitwise representation.
18011         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
18012         * lib/regexec.c (check_dst_limits_calc_pos_1,
18013         check_subexp_matching_top):
18014         Likewise.
18015         * lib/regex_internal.c (re_string_reconstruct):
18016         Don't assume UCHAR_MAX == 255.
18017         * lib/regex_internal.h (bitset_set_all): Likewise.
18018         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
18019         All uses changed.
18020         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
18021         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
18022         All uses changed.
18023         (BITSET_WORD_MAX): New macro.
18024         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
18025         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
18026         (bitset_empty, bitset_copy):
18027         Prefer sizeof (bitset) to multiplying it out ourselves.
18028         (bitset_not_merge): Remove; unused.
18029         (bitset_contain): Return bool, not unsigned int with one bit on.
18030         All callers changed.
18031         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
18032         alignment than re_node_set; do this by defining a new internal
18033         type struct dests_alloc and using it to allocate memory.
18034
18035 2005-09-05  Bruno Haible  <bruno@clisp.org>
18036
18037         * gnulib-tool (func_import): Fix comparison in handling of symbolic
18038         links.
18039
18040 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
18041
18042         * modules/size_max (Makefile.am): Add size_max.h
18043
18044 2005-09-04  Derek Price  <derek@ximbiot.com>
18045
18046         * gnulib-tool (func_import): Fix reversed $symbolic logic.
18047
18048 2005-09-03  Simon Josefsson  <jas@extundo.com>
18049
18050         * gnulib-tool: Fix typo.
18051
18052 2005-09-03  Simon Josefsson  <jas@extundo.com>
18053
18054         * config/srclist.txt: Add glibc bug 1293.
18055
18056 2005-09-03  Derek Price  <derek@ximbiot.com>
18057
18058         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
18059         From Larry Jones <lawrence.jones@ugs.com>.
18060
18061 2005-09-02  Simon Josefsson  <jas@extundo.com>
18062
18063         * modules/socklen: New file.
18064
18065 2005-09-02  Simon Josefsson  <jas@extundo.com>
18066
18067         * modules/havelib: New module.
18068
18069         * modules/gettext, modules/iconv, modules/lock, modules/readline:
18070         Use havelib.
18071
18072 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
18073
18074         Check for arithmetic overflow when calculating sizes, to prevent
18075         some buffer-overflow issues.  These patches are conservative, in the
18076         sense that when I couldn't determine whether an overflow was possible,
18077         I inserted a run-time check.
18078         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
18079         macros.
18080         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
18081         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
18082         (re_xnrealloc, re_x2nrealloc): New inline functions.
18083         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
18084         parse_bracket_exp):
18085         (build_equiv_class, build_charclass): Check for arithmetic overflow
18086         in size expression calculations.
18087         * lib/regex_internal.c (re_string_realloc_buffers):
18088         (build_wcs_upper_buffer, re_node_set_add_intersect):
18089         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
18090         (re_dfa_add_node, register_state): Likewise.
18091         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
18092         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
18093         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
18094         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
18095
18096 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
18097
18098         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
18099         m4/ulonglong.m4.  Problem reported by Martin Lambers.
18100
18101 2005-09-02  Bruno Haible  <bruno@clisp.org>
18102
18103         Support for lib vs. lib64 distinction on biarch platforms.
18104         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
18105         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
18106         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
18107
18108 2005-09-02  Bruno Haible  <bruno@clisp.org>
18109
18110         * gnulib-tool (import): In the other first-use case, provide defaults
18111         as well.
18112
18113 2005-09-02  Bruno Haible  <bruno@clisp.org>
18114
18115         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
18116         patches not yet found in the latest gettext release.
18117
18118 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
18119
18120         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
18121         to avoid a collision with bits/local_lim.h in glibc.
18122         All uses changed.  Problem reported by Dmitry V. Levin in
18123         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
18124
18125         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
18126         bugs in int versus size_t comparisons.
18127         (re_string_context_at): Fix bug where the code assumed that
18128         Idx is signed.
18129
18130         Use bool where appropriate.
18131         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
18132         All callers changed.
18133         (calc_eclosure_iter): Likewise, for ROOT arg.
18134         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
18135         (build_charclass_op): Likewise, for NON_MATCH arg.
18136         * lib/regex_internal.c (re_string_allocate, re_string_construct):
18137         (re_string_construct_common): Likewise, for ICASE arg.
18138         * lib/regexec.c (re_search_2_stub, re_search_stub):
18139         Likewise, for RET_LEN arg.
18140         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
18141         (set_regs): Likewise, for FL_BACKTRACK arg.
18142         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
18143         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
18144         (calc_eclosure_iter, parse_bracket_exp):
18145         Use bool for internal variables that are booleans.
18146         * lib/regexec.c (re_search_internal, check_matching,
18147         proceed_next_node):
18148         (set_regs, build_sifted_states, sift_states_bkref):
18149         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
18150         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
18151         (find_collation_sequence_value):
18152         Likewise.
18153         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
18154         (re_node_set_compare):
18155         Return bool, not int. All callers changed.
18156         * lib/regexec.c (check_halt_node_context, check_dst_limits):
18157         (build_trtable, check_node_accept): Likewise.
18158         * lib/regex_internal.h: Include stdbool.h.
18159
18160         Fix bugs uncovered when converting to bool.
18161         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
18162         failure instead of charging ahead blindly.
18163         * lib/regex_internal.c (register_state): Likewise.
18164         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
18165         for freeing internal storage.
18166         (group_nodes_into_DFA_states): Use unsigned int, not int, for
18167         bitset pieces used as boolean, to avoid undefined behavior
18168         on hosts that do int overflow checking.
18169
18170 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
18171
18172         * config/srclist.txt: Add glibc bugs 1285-1287.
18173
18174 2005-09-01  Jim Meyering  <jim@meyering.net>
18175
18176         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
18177         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
18178         Require gl_STAT_MACROS, too.
18179
18180 2005-09-01  Bruno Haible  <bruno@clisp.org>
18181
18182         * gnulib-tool (import): In the first-use case, provide defaults.
18183
18184 2005-09-01  Bruno Haible  <bruno@clisp.org>
18185
18186         * gnulib-tool (func_import): Remove the .tmp files.
18187
18188 2005-09-01  Bruno Haible  <bruno@clisp.org>
18189
18190         * gnulib-tool (func_import): Fix handling of symbolic links.
18191
18192 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
18193
18194         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
18195         old glibc regex code mishandles strings longer than 2**31 bytes.
18196         This patch fixes this when the regex code is used in gnulib
18197         (i.e., outside glibc).
18198
18199         This patch should not affect the use of the regex code inside
18200         glibc.  No doubt this problem also needs to be handled for glibc
18201         as well, but the result will be an incompatible change to the
18202         glibc ABI, and the old ABI will have to be supported too.  That
18203         can be the the subject for another patch.
18204
18205         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
18206         governing whether the rest of this patch is active.  By default,
18207         the macro is disabled and the patch has no effect.
18208         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
18209         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
18210         (struct re_pattern_buffer, re_search, re_search_2, re_match):
18211         (re_match_2, re_set_registers): Use the new types.
18212         * lib/regex_internal.h (Idx, re_hashval_t): New types.
18213         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
18214         New macros.
18215         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
18216         (re_string_context_at, bin_tree_t, re_dfastate_t):
18217         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
18218         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
18219         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
18220         (re_string_char_size_at, re_string_wchar_at):
18221         (re_string_elem_size_at):
18222         Use the new types and macros to port to 64-bit hosts.
18223         Use unsigned types for internal values, so that the code
18224         mostly works even for arrays larger than SSIZE_MAX.
18225         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
18226         (search_duplicated_node, calc_eclosure_iter, fetch_number):
18227         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
18228         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
18229         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
18230         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
18231         (calc_inveclosure, parse_dup_op, build_range_exp):
18232         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
18233         (fetch_number, create_token_tree, mark_opt_subexp):
18234         Likewise.
18235         * lib/regex_internal.c (re_string_construct_common,
18236         create_ci_newstate):
18237         (create_cd_newstate, re_string_allocate, re_string_construct):
18238         (re_string_realloc_buffers, build_wcs_upper_buffer):
18239         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
18240         (re_string_reconstruct, re_string_peek_byte_case):
18241         (re_string_fetch_byte_case, re_string_context_at):
18242         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
18243         (re_node_set_init_copy, re_node_set_add_intersect):
18244         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
18245         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
18246         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
18247         (re_acquire_state, re_acquire_state_context, register_state):
18248         Likewise.
18249         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
18250         search_cur_bkref_entry):
18251         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
18252         (re_search_internal, re_search_2_stub, re_search_stub)
18253         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
18254         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
18255         (update_cur_sifted_state, check_dst_limits):
18256         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
18257         (check_subexp_limits, sift_states_bkref, merge_state_array):
18258         (check_subexp_matching_top, get_subexp, get_subexp_sub):
18259         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
18260         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
18261         (expand_bkref_cache, check_node_accept_bytes):
18262         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
18263         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
18264         (acquire_init_state_context, check_halt_node_context):
18265         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
18266         (sift_states_backward, clean_state_log_if_needed):
18267         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
18268         (find_recover_state, transit_state_sb, transit_state_mb):
18269         (transit_state_bkref, build_trtable, match_ctx_clean):
18270         Likewise.
18271         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
18272         to work around an assumption that REG_MISSING is negative.
18273
18274         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
18275         (seek_collating_symbol_entry) [defined _LIBC]:
18276         (lookup_collation_sequence_value) [defined _LIBC]:
18277         (build_range_exp, build_collating_symbol) [defined _LIBC]:
18278         Use prototypes rather than old-style function definitions.
18279         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
18280         (transit_state_sb) [0]:
18281         (find_collation_sequence_value) [defined _LIBC]: Likewise.
18282
18283         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
18284         rm_eo.
18285
18286         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
18287         (optimize_subexps, lower_subexp):
18288         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
18289         since the signed shift might overflow.  Use 1u<<31 instead.
18290         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
18291         Likewise.
18292         * lib/regexec.c (check_dst_limits_calc_pos_1,
18293         check_subexp_matching_top): Likewise.
18294
18295         * lib/regcomp.c (optimize_subexps, lower_subexp):
18296         Use CHAR_BIT rather than 8, for clarity.
18297         * lib/regexec.c (check_dst_limits_calc_pos_1):
18298         (check_subexp_matching_top): Likewise.
18299         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
18300         have to worry about portability issues when shifting it left.
18301         Remove no-longer-needed test for table_size > 0.
18302         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
18303         in a word, as the resulting behavior is undefined.
18304         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
18305         in one case, a <= should have been an <, and in another case the
18306         whole test was missing.
18307         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
18308         the standard name CHAR_BIT.
18309         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
18310         this is not true on one's complement and signed-magnitude hosts.
18311
18312         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
18313         next_last_offset.
18314         (struct re_dfa_t): Remove unused member states_alloc.
18315         * lib/regcomp.c (init_dfa): Don't initialize unused members.
18316
18317 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
18318
18319         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
18320         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
18321         and large-file glibc and in 32-bit large-file Solaris.
18322
18323 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
18324
18325         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
18326         lengths fit in regoff_t; this isn't true if regoff_t is the same
18327         width as size_t.
18328         * lib/regex.c (re_search_internal): 5th arg is LAST_START
18329         (= START + RANGE) instead of RANGE.  This avoids overflow
18330         problems when regoff_t is the same width as size_t.
18331         All callers changed.
18332         (re_search_2_stub): Check for overflow when adding the
18333         sizes of the two strings.
18334         (re_search_stub): Check for overflow when adding START
18335         to RANGE; if it occurs, substitute the extreme value.
18336
18337 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
18338
18339         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
18340
18341 2005-08-31  Jim Meyering  <jim@meyering.net>
18342
18343         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
18344         a pointer-to-const.
18345         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
18346         (register_state): Likewise.
18347         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
18348         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
18349         (group_nodes_into_DFAstates): Likewise.
18350
18351 2005-08-31  Jim Meyering  <jim@meyering.net>
18352
18353         * check-module: Add a FIXME comment.
18354
18355 2005-08-31  Eric Blake  <ebb9@byu.net>
18356
18357         * modules/unistd-safer (Files): Add unistd--.h.
18358         * modules/stdio-safer (Files): Add stdio--.h.
18359
18360 2005-08-31  Derek Price  <derek@ximbiot.com>
18361
18362         * lib/getdelim.c (getdelim): Return EOF on EOF.
18363         Reported by Larry Jones <lawrence.jones@ugs.com>.
18364
18365 2005-08-31  Bruno Haible  <bruno@clisp.org>
18366
18367         Avoid unnecessary diffs in the generated lib/Makefile.am.
18368         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
18369         the generated files.
18370         (func_import): Don't set cmd.
18371
18372 2005-08-31  Bruno Haible  <bruno@clisp.org>
18373
18374         * lib/strstr.c: Include <stddef.h>, for NULL.
18375         * lib/strcasestr.c: Likewise.
18376         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
18377
18378 2005-08-31  Bruno Haible  <bruno@clisp.org>
18379
18380         * gnulib-tool: New option --macro-prefix.
18381         (func_import): Use macro_prefix.
18382         (import): Handle option --macro-prefix.
18383
18384 2005-08-31  Bruno Haible  <bruno@clisp.org>
18385
18386         * gnulib-tool (import): Rename most ac_* variables to cached_*.
18387         Also use new variables cached_lgpl, cached_libtool.
18388
18389 2005-08-31  Bruno Haible  <bruno@clisp.org>
18390
18391         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
18392         always instantiating them.
18393
18394 2005-08-31  Bruno Haible  <bruno@clisp.org>
18395
18396         * gnulib-tool (func_import): Read the previous cached settings
18397         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
18398         earlier added by gnulib but are now dropped. Warn when a gnulib file
18399         overwrites a non-gnulib file.
18400
18401 2005-08-31  Bruno Haible  <bruno@clisp.org>
18402
18403         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
18404         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
18405         projects that don't keep autogenerated files in CVS. Put into
18406         actioncmd only the specified modules, not the transitive closure.
18407
18408 2005-08-31  Bruno Haible  <bruno@clisp.org>
18409
18410         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
18411         Create directories that shall be filled.
18412         (import): Don't look for gl_* macros in configure.ac. Recurse across
18413         all directories containing a gnulib-cache.m4 files, if meaningful.
18414
18415 2005-08-31  Bruno Haible  <bruno@clisp.org>
18416
18417         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
18418         (import): Set seen_libtool when we see gl_LIBTOOL.
18419
18420 2005-08-31  Bruno Haible  <bruno@clisp.org>
18421
18422         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
18423         declaration macro definitions from generated gnulib.m4.
18424
18425 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
18426
18427         * lib/iconvme.h: Add prototype for iconv_alloc.
18428
18429 2005-08-29  Simon Josefsson  <jas@extundo.com>
18430
18431         * lib/iconvme.c: Fix errno.
18432
18433 2005-08-29  Bruno Haible  <bruno@clisp.org>
18434
18435         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
18436         that it works when the directory contains spaces.
18437
18438 2005-08-29  Bruno Haible  <bruno@clisp.org>
18439
18440         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
18441
18442 2005-08-29  Bruno Haible  <bruno@clisp.org>
18443
18444         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
18445         Emit more advice.
18446
18447 2005-08-29  Bruno Haible  <bruno@clisp.org>
18448         and Stepan Kasal  <kasal@ucw.cz>
18449
18450         * check-module: If more parameters are given, check each of them
18451         separately; add more exceptions, as noted by Jim Meyering.
18452         (check_module): New procedure.
18453         (%exempt_header): Now contains all exceptions.
18454
18455 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
18456
18457         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
18458
18459 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
18460
18461         * lib/iconvme.c: Split iconv_string into iconv_alloc.
18462
18463 2005-08-28  Bruno Haible  <bruno@clisp.org>
18464
18465         * m4/gnulib-tool.m4: New file.
18466
18467 2005-08-27  Jim Meyering  <jim@meyering.net>
18468
18469         * modules/unistd-safer (Files): Add pipe-safer.c.
18470         * modules/fcntl-safer (Files): Add creat-safer.c.
18471
18472 2005-08-27  Jim Meyering  <jim@meyering.net>
18473
18474         * m4/stdlib-safer.m4: New file.  From coreutils.
18475         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
18476         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
18477         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
18478         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
18479         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
18480
18481 2005-08-27  Jim Meyering  <jim@meyering.net>
18482
18483         * lib/fopen-safer.c: Merge minor changes from coreutils.
18484         * lib/dup-safer.c: Likewise.
18485         * lib/fd-safer.c: Likewise.
18486
18487         Merge from coreutils.
18488         * lib/stdio--.h: New file.
18489         * lib/stdlib--.h: New file.
18490         * lib/mkstemp-safer.c: New file.
18491
18492         GNU tar needs these.
18493         * lib/pipe-safer.c: New file.
18494         * lib/creat-safer.c: New file.
18495         * lib/fcntl--.h (creat): Define to creat_safer.
18496         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
18497         * lib/unistd--.h (pipe): Define to pipe_safer.
18498         * lib/unistd-safer.h: Declare pipe_safer.
18499
18500 2005-08-26  Simon Josefsson  <jas@extundo.com>
18501
18502         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
18503         Haible <bruno@clisp.org>.
18504
18505 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
18506
18507         * lib/regex_internal.h: Remove all references to
18508         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
18509         or better.
18510         (bitset_not, bitset_merge, bitset_not_merge):
18511         (bitset_mask, re_string_allocate, re_string_construct):
18512         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
18513         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
18514         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
18515         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
18516         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
18517         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
18518         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
18519         (re_acquire_state_context):
18520         Remove unnecessary forward decls.
18521         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
18522         Put __attribute at function definition,
18523         now that the function decl has been removed.
18524         * lib/regex_internal.c (re_string_peek_byte_case):
18525         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
18526         Likewise.
18527
18528 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
18529
18530         * m4/regex.m4: Add AC_PREREQ(2.50).
18531         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
18532
18533 2005-08-25  Simon Josefsson  <jas@extundo.com>
18534
18535         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
18536         __fsetlocking.
18537
18538 2005-08-25  Simon Josefsson  <jas@extundo.com>
18539
18540         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
18541         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
18542         GLIBC specific code.
18543
18544 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18545
18546         Make regex safe for g++.  This fixes one real bug (an "err"
18547         that should have been "*err").  g++ problem reported by
18548         Sam Steingold.
18549         * lib/regex_internal.h (re_calloc): New macro, consistent with
18550         re_malloc etc.  All callers of calloc changed to use re_calloc.
18551         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
18552         not int.  All callers changed.
18553         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
18554         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
18555         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
18556         (find_recover_state): Change "err" to "*err"; this fixes what
18557         appears to be a real bug.
18558         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
18559         versus int.
18560
18561 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18562
18563         * modules/regex (Depends-on): Add malloc, since the code
18564         assumes that !malloc(0) means failure.
18565
18566 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18567
18568         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
18569
18570         alloca modernization/simplification for regex.
18571         * lib/regex.c: Remove portability cruft for alloca.  This no longer
18572         needs to be at the start of the file, and can be moved into
18573         regex_internal.h and simplified.
18574         * lib/regex_internal.h: Include <alloca.h>.
18575         (__libc_use_alloca) [!defined _LIBC]: New macro.
18576         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
18577         now works outside glibc.
18578
18579 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
18580
18581         * config/srclist.txt: Add glibc bugs 1241, 1245.
18582
18583 2005-08-25  Jim Meyering  <jim@meyering.net>
18584
18585         * lib/open-safer.c: Include <config.h>.
18586         Otherwise, we'd lose LARGEFILE support in any file using
18587         e.g. "fcntl--.h"
18588
18589 2005-08-25  Bruno Haible  <bruno@clisp.org>
18590
18591         * m4/minmax.m4: Require autoconf 2.52.
18592         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
18593         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
18594         alternatives of translit over the alphabet.
18595         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
18596
18597 2005-08-24  Simon Josefsson  <jas@extundo.com>
18598
18599         * tests/test-getpass.c: New file.
18600
18601 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
18602
18603         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
18604         for GNU regex features.
18605
18606 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
18607
18608         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
18609         * lib/regex.h (regerror): Likewise.
18610
18611         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
18612         requires this.  (The code never needed it.)
18613
18614         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
18615         All uses of recently-renamed identifiers changed to use the new,
18616         POSIX-compliant names.  The code will build and run just fine
18617         without these changes, but it's better to eat our own dog food
18618         and use the standard-conforming names.
18619
18620         * lib/regex.h: Fix a multitude of POSIX name space violations.
18621         These changes have an effect only for programs that define
18622         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
18623         do not change anything for programs compiled in the normal way.
18624         Also, there is no effect on the ABI.
18625
18626         (_REGEX_SOURCE): New macro.
18627         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
18628         defined and _GNU_SOURCE is not; this fixes a name space violation.
18629
18630         Rename the following macros to obey POSIX requirements.
18631         The old names are still visible as macros if _REGEX_SOURCE is defined.
18632         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
18633         RE_BACKSLASH_ESCAPE_IN_LISTS.
18634         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
18635         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
18636         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
18637         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
18638         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
18639         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
18640         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
18641         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
18642         (REG_INTERVALS): renamed from RE_INTERVALS.
18643         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
18644         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
18645         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
18646         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
18647         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
18648         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
18649         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
18650         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
18651         RE_UNMATCHED_RIGHT_PAREN_ORD.
18652         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
18653         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
18654         (REG_DEBUG): renamed from RE_DEBUG.
18655         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
18656         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
18657         unusual, since we can't clash with the POSIX REG_ICASE.
18658         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
18659         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
18660         (REG_NO_SUB): renamed from RE_NO_SUB.
18661         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
18662         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
18663         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
18664         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
18665         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
18666         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
18667         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
18668         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
18669         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
18670         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
18671         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
18672         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
18673         RE_SYNTAX_POSIX_MINIMAL_BASIC.
18674         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
18675         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
18676         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
18677         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
18678         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
18679         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
18680         (REG_FIXED): Renamed from REGS_FIXED.
18681         (REG_NREGS): Renamed from RE_NREGS.
18682
18683         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
18684         of other REG_* macros, since POSIX says the user is allowed to
18685         #undef these macros selectively.
18686
18687         (reg_errcode_t): Update comment stating what other tables need
18688         to be consistent.
18689
18690         Rename the following enum values to obey POSIX requirements.
18691         The old names are still visible as macros.
18692         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
18693         is not defined, since GNU is supposed to be a superset of POSIX as
18694         much as possible, and since we want reg_errcode_t to be a signed
18695         type for implementation consistency.
18696         (_REG_NOERROR): Renamed from REG_NOERROR.
18697         (_REG_NOMATCH): Renamed from REG_NOMATCH.
18698         (_REG_BADPAT): Renamed from REG_BADPAT.
18699         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
18700         (_REG_ECTYPE): Renamed from REG_ECTYPE.
18701         (_REG_EESCAPE): Renamed from REG_EESCAPE.
18702         (_REG_ESUBREG): Renamed from REG_ESUBREG.
18703         (_REG_EBRACK): Renamed from REG_EBRACK.
18704         (_REG_EPAREN): Renamed from REG_EPAREN.
18705         (_REG_EBRACE): Renamed from REG_EBRACE.
18706         (_REG_BADBR): Renamed from REG_BADBR.
18707         (_REG_ERANGE): Renamed from REG_ERANGE.
18708         (_REG_ESPACE): Renamed from REG_ESPACE.
18709         (_REG_BADRPT): Renamed from REG_BADRPT.
18710         (_REG_EEND): Renamed from REG_EEND.
18711         (_REG_ESIZE): Renamed from REG_ESIZE.
18712         (_REG_ERPAREN): Renamed from REG_ERPAREN.
18713         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
18714         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
18715         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
18716         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
18717
18718         (_REG_RE_NAME, _REG_RM_NAME): New macros.
18719         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
18720         changed.  But support the old name if the new one is not defined
18721         and if _REGEX_SOURCE.
18722
18723         Change the following member names in struct re_pattern_buffer.
18724         The old names are still supported if !_REGEX_SOURCE.
18725         The new names are always supported, regardless of _REGEX_SOURCE.
18726         (re_buffer): Renamed from buffer.
18727         (re_allocated): Renamed from allocated.
18728         (re_used): Renamed from used.
18729         (re_syntax): Renamed from syntax.
18730         (re_fastmap): Renamed from fastmap.
18731         (re_translate): Renamed from translate.
18732         (re_can_be_null): Renamed from can_be_null.
18733         (re_regs_allocated): Renamed from regs_allocated.
18734         (re_fastmap_accurate): Renamed from fastmap_accurate.
18735         (re_no_sub): Renamed from no_sub.
18736         (re_not_bol): Renamed from not_bol.
18737         (re_not_eol): Renamed from not_eol.
18738         (re_newline_anchor): Renamed from newline_anchor.
18739
18740         Change the following member names in struct re_registers.
18741         The old names are still supported if !_REGEX_SOURCE.
18742         The new names are always supported, regardless of _REGEX_SOURCE.
18743         (rm_num_regs): Renamed from num_regs.
18744         (rm_start): Renamed from start.
18745         (rm_end): Renamed from end.
18746
18747         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
18748         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
18749         Prepend __ to parameter names.
18750
18751         Undo yesterday's changes.
18752
18753 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
18754
18755         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
18756         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
18757         lib/regex.c.
18758
18759 2005-08-24  Jim Meyering  <jim@meyering.net>
18760
18761         Sync from coreutils.
18762         * m4/fcntl-safer.m4: New file.
18763
18764         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
18765         and object files for this module.
18766
18767 2005-08-24  Jim Meyering  <jim@meyering.net>
18768
18769         Sync from coreutils.
18770         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
18771
18772 2005-08-24  Jim Meyering  <jim@meyering.net>
18773
18774         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
18775         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
18776
18777 2005-08-24  Jim Meyering  <jim@meyering.net>
18778
18779         * modules/fcntl-safer: New module.
18780         * modules/fts (Depends-on): Add fcntl-safer.
18781         * MODULES.html.sh (File descriptor based Input/Output):
18782         Add fcntl-safer.
18783
18784 2005-08-24  Bruno Haible  <bruno@clisp.org>
18785
18786         Support for unit test modules.
18787         * modules/README: Mention tests modules.
18788         * modules/TEMPLATE-TESTS: New file.
18789         * gnulib-tool: New options --extract-tests-module, --with-tests and
18790         --tests-base (unused for the moment).
18791         (testsbase, inctests): New variables.
18792         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
18793         (func_verify_module): Exclude TEMPLATE-TESTS.
18794         (func_verify_nontests_module, func_verify_tests_module): New functions.
18795         (func_get_dependencies): Add implicit dependency for tests modules.
18796         (func_get_tests_module): New function.
18797         (func_modules_transitive_closure): When --with-tests was specified,
18798         include the unit tests as well, unless explicitly avoided.
18799         (func_emit_lib_Makefile_am): Ignore the tests modules here.
18800         (func_emit_tests_Makefile_am): New function.
18801         (func_create_testdir): When --with-tests was specified, emit a
18802         tests/ directory.
18803         * MODULES.html.sh (Future developments): Update.
18804
18805 2005-08-24  Bruno Haible  <bruno@clisp.org>
18806
18807         * modules/tls-tests: New file.
18808         * tests/test-tls.c: New file, from GNU gettext.
18809
18810 2005-08-24  Bruno Haible  <bruno@clisp.org>
18811
18812         * modules/lock-tests: New file.
18813         * tests/test-lock.c: New file, from GNU gettext.
18814
18815 2005-08-24  Bruno Haible  <bruno@clisp.org>
18816
18817         * lib/lock.h: Add multiple inclusion guard.
18818         * lib/tls.h: Add multiple inclusion guard.
18819
18820 2005-08-24  Bruno Haible  <bruno@clisp.org>
18821
18822         * gnulib-tool: Add support for the --aux-dir option to
18823         --create-testdir, --create-megatestdir, --test, --megatest.
18824         (func_create_testdir, func_create_megatestdir): Optionally emit a
18825         AC_CONFIG_AUX_DIR directive.
18826         (create-testdir, create-megatestdir, test, megatest): Provide a
18827         default value for $auxdir.
18828
18829 2005-08-24  Bruno Haible  <bruno@clisp.org>
18830
18831         * gnulib-tool (import): Use compound statement instead of subshell
18832         where possible.
18833
18834 2005-08-24  Bruno Haible  <bruno@clisp.org>
18835
18836         * gnulib-tool (import): Change --aux-dir default to "build-aux".
18837
18838 2005-08-24  Bruno Haible  <bruno@clisp.org>
18839
18840         * gnulib-tool (func_version): Update.
18841
18842 2005-08-24  Bruno Haible  <bruno@clisp.org>
18843
18844         * gnulib-tool (func_import, func_create_testdir,
18845         func_create_megatestdir): Quote all autoconf macro arguments.
18846
18847 2005-08-24  Bruno Haible  <bruno@clisp.org>
18848
18849         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
18850         option --force, because --force causes the aclocal.m4 of each
18851         subdirectory to be newer than the corresponding config.h.in.
18852
18853 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18854
18855         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
18856         All contents moved to gl_REGEX.
18857         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
18858         assume that it does.
18859
18860 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18861
18862         * lib/regex.h (REG_NOSYS)
18863         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
18864         Define, since POSIX requires it as of 2001.
18865         (_REG_ENOSYS)
18866         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
18867         New private symbol, used to keep the enum signed in all cases.
18868         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
18869         Youngman in
18870         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
18871
18872         * lib/regex_internal.c (re_string_skip_chars, register_state):
18873         (calc_state_hash):
18874         Remove forward decls; no longer needed now that we use prototypes.
18875         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
18876         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
18877         (clean_state_log_if_needed): Likewise.
18878
18879 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
18880
18881         * config/srclist.txt: Add glibc bugs 1231-1233.
18882
18883 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18884
18885         Fix problems reported by Sam Steingold in
18886         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
18887         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
18888         assumed that reg_errcode_t is a signed type, which is not
18889         necessarily true if _XOPEN_SOURCE is not defined.
18890         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
18891         since some compilers warn about it otherwise.
18892
18893 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18894
18895         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
18896         (init_word_char, create_initial_state, duplicate_node_closure):
18897         (fetch_token, peek_token_bracket, build_range_exp):
18898         (build_collating_symbol): Remove forward decls; no longer needed
18899         now that we use prototypes.
18900
18901         * lib/regcomp.c:
18902         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
18903         (re_compile_fastmap_iter, regcomp, regerror, regfree):
18904         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
18905         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
18906         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
18907         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
18908         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
18909         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
18910         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
18911         (build_range_exp, build_collating_symbol, parse_bracket_exp):
18912         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
18913         (build_charclass, build_charclass_op, fetch_number, create_tree):
18914         (create_token_tree, mark_opt_subexp, duplicate_tree):
18915         Use prototypes rather than old-style definitions.
18916
18917         * lib/regex_internal.c:
18918         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
18919         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
18920         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
18921         (re_string_reconstruct, re_string_peek_byte_case):
18922         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
18923         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
18924         (re_node_set_init_copy, re_node_set_add_intersect):
18925         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
18926         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
18927         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
18928         (re_acquire_state, re_acquire_state_context, register_state):
18929         (create_ci_newstate, create_cd_newstate, free_state):
18930         Likewise.
18931         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
18932         re_search_2):
18933         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
18934         (re_search_internal, prune_impossible_nodes):
18935         (acquire_init_state_context, check_matching, static):
18936         (check_halt_node_context, check_halt_state_context, proceed_next_node):
18937         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
18938         (update_regs, sift_states_backward, build_sifted_states):
18939         (clean_state_log_if_needed, merge_state_array):
18940         (update_cur_sifted_state, add_epsilon_src_nodes):
18941         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
18942         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
18943         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
18944         (find_recover_state, check_subexp_matching_top, transit_state_mb):
18945         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
18946         (check_arrival, check_arrival_add_next_nodes):
18947         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
18948         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
18949         (check_node_accept_bytes, check_node_accept, extend_buffers):
18950         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
18951         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
18952         (sift_ctx_init):
18953         Likewise.
18954
18955         * lib/regex_internal.h:
18956         (re_string_allocate, re_string_construct, re_string_reconstruct):
18957         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
18958         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
18959         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
18960         (re_string_context_at, re_string_peek_byte_case):
18961         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
18962         is defined, since we now use prototypes always.
18963
18964         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
18965         C89 or better.  All uses removed.
18966
18967 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
18968
18969         * config/srclist.txt: Add glibc bugs 1220-1227.
18970
18971 2005-08-20  Jim Meyering  <jim@meyering.net>
18972
18973         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
18974         of unused local, dfa.
18975
18976 2005-08-20  Bruno Haible  <bruno@clisp.org>
18977
18978         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
18979
18980 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18981
18982         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
18983         (re_node_set_insert_last, re_dfa_add_node):
18984         Rename local variables to avoid GCC shadowing warnings.
18985
18986 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18987
18988         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
18989         [defined lint]: Suppress bogus uninitialized-variable warnings.
18990
18991         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
18992         and let the caller return REG_ESPACE if out of space.  This
18993         removes an uninitialied-variable warning with GCC 4.0.1, and also
18994         avoids taking the address of a local variable.  All callers
18995         changed.
18996
18997 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
18998
18999         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
19000         $LIBCSRC/posix/regexec.c.
19001         Add glibc bug 1217 for regcomp.c.
19002
19003 2005-08-19  Jim Meyering  <jim@meyering.net>
19004
19005         * lib/regexec.c (proceed_next_node): Redo local variables to
19006         avoid GCC shadowing warnings.
19007
19008 2005-08-18  Bruno Haible  <bruno@clisp.org>
19009
19010         * lib/strstr.c (strstr): Fix return value in multibyte case.
19011         * lib/strcasestr.c (strcasestr): Likewise.
19012
19013 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
19014
19015         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
19016
19017 2005-08-17  Jim Meyering  <jim@meyering.net>
19018
19019         Make the %s format (seconds since the epoch) work for a negative
19020         number and when used with a zero-padded field width, e.g. %015s.
19021
19022         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
19023         label so that it precedes the code to set `digits'.  Otherwise,
19024         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
19025         print `00-22'.  Now, it prints `-0022', as it should.
19026
19027 2005-08-17  Bruno Haible  <bruno@clisp.org>
19028
19029         * modules/strstr (Files): Add m4/mbrtowc.m4.
19030         (Depends-on): Add mbuiter.
19031
19032 2005-08-17  Bruno Haible  <bruno@clisp.org>
19033
19034         * modules/strcasestr: New file.
19035         * MODULES.html.sh (String handling, based on ANSI C 89): Add
19036         strcasestr.
19037
19038 2005-08-17  Bruno Haible  <bruno@clisp.org>
19039
19040         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
19041
19042 2005-08-17  Bruno Haible  <bruno@clisp.org>
19043
19044         * modules/mbuiter: New file.
19045         * MODULES.html.sh (Extended multibyte and wide character utilities):
19046         Add mbuiter.
19047
19048 2005-08-17  Bruno Haible  <bruno@clisp.org>
19049
19050         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
19051         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
19052
19053 2005-08-17  Bruno Haible  <bruno@clisp.org>
19054
19055         * m4/strcasestr.m4: New file.
19056
19057 2005-08-17  Bruno Haible  <bruno@clisp.org>
19058
19059         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
19060         * lib/strstr.c: Completely rewritten, with multibyte locale support.
19061
19062 2005-08-17  Bruno Haible  <bruno@clisp.org>
19063
19064         * lib/strcasestr.h: New file.
19065         * lib/strcasestr.c: New file.
19066
19067 2005-08-17  Bruno Haible  <bruno@clisp.org>
19068
19069         * lib/strcasecmp.c: Use mbuiter.h.
19070
19071 2005-08-17  Bruno Haible  <bruno@clisp.org>
19072
19073         * lib/mbuiter.h: New file.
19074
19075 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
19076
19077         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
19078         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
19079         and gl_GETOPT are both invoked via different paths (as happens
19080         with GNU tar CVS because it uses both argp and getopt), the former
19081         wins.
19082
19083 2005-08-16  Bruno Haible  <bruno@clisp.org>
19084
19085         * modules/tls: New file.
19086         * MODULES.html.sh (Multithreading): Add tls.
19087
19088 2005-08-16  Bruno Haible  <bruno@clisp.org>
19089
19090         * modules/strnlen1: New file.
19091         * MODULES.html.sh (String handling): Add strnlen1.
19092
19093 2005-08-16  Bruno Haible  <bruno@clisp.org>
19094
19095         * modules/strcase (Files): Add m4/mbrtowc.m4.
19096         (Depends-on): Add strnlen1, mbchar.
19097
19098 2005-08-16  Bruno Haible  <bruno@clisp.org>
19099
19100         * modules/mbiter: New file.
19101         * MODULES.html.sh (Extended multibyte and wide character utilities):
19102         Add mbiter.
19103
19104 2005-08-16  Bruno Haible  <bruno@clisp.org>
19105
19106         * modules/mbfile: New file.
19107         * MODULES.html.sh (Extended multibyte and wide character utilities):
19108         Add mbfile.
19109
19110 2005-08-16  Bruno Haible  <bruno@clisp.org>
19111
19112         * modules/mbchar: New file.
19113         * MODULES.html.sh (Extended multibyte and wide character utilities):
19114         New section.
19115
19116 2005-08-16  Bruno Haible  <bruno@clisp.org>
19117
19118         * m4/tls.m4: New file, from GNU gettext.
19119
19120 2005-08-16  Bruno Haible  <bruno@clisp.org>
19121
19122         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
19123         always.
19124         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
19125
19126 2005-08-16  Bruno Haible  <bruno@clisp.org>
19127
19128         * m4/mbiter.m4: New file.
19129
19130 2005-08-16  Bruno Haible  <bruno@clisp.org>
19131
19132         * m4/mbfile.m4: New file.
19133
19134 2005-08-16  Bruno Haible  <bruno@clisp.org>
19135
19136         * m4/mbchar.m4: New file.
19137
19138 2005-08-16  Bruno Haible  <bruno@clisp.org>
19139
19140         * lib/tls.h: New file, from GNU gettext.
19141         * lib/tls.c: New file, from GNU gettext.
19142
19143 2005-08-16  Bruno Haible  <bruno@clisp.org>
19144
19145         * lib/strnlen1.h: New file.
19146         * lib/strnlen1.c: New file.
19147
19148 2005-08-16  Bruno Haible  <bruno@clisp.org>
19149
19150         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
19151         (mbi_init): Update.
19152         (mbi_avail, mbi_advance): Let the iteration end before the terminating
19153         NUL byte, not after it.
19154
19155 2005-08-16  Bruno Haible  <bruno@clisp.org>
19156
19157         * lib/strcase.h (strcasecmp): Add note in comments.
19158         * lib/strncasecmp.c: Use code from strcasecmp.c.
19159         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
19160         (strcasecmp): Work correctly in multibyte locales.
19161
19162 2005-08-16  Bruno Haible  <bruno@clisp.org>
19163
19164         * lib/mbiter.h: New file.
19165
19166 2005-08-16  Bruno Haible  <bruno@clisp.org>
19167
19168         * lib/mbfile.h: New file.
19169
19170 2005-08-16  Bruno Haible  <bruno@clisp.org>
19171
19172         * lib/mbchar.h: New file.
19173         * lib/mbchar.c: New file.
19174
19175 2005-08-16  Bruno Haible  <bruno@clisp.org>
19176
19177         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
19178         the valid ones. Makes the comparison operations transitive:
19179         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
19180         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
19181
19182 2005-08-15  Simon Josefsson  <jas@extundo.com>
19183
19184         * modules/ssize_t (License): Change to 'unlimited'.
19185
19186         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
19187
19188 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
19189
19190         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
19191         Add comments for each pending glibc patch.
19192
19193 2005-08-15  Bruno Haible  <bruno@clisp.org>
19194
19195         * lib/regex.h (__restrict_arr): Don't define to __restrict if
19196         __cplusplus is defined.
19197
19198 2005-08-14  Jim Meyering  <jim@meyering.net>
19199
19200         Sync from coreutils.
19201
19202         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
19203         Use the hash-table-based cycle-detection code not just when
19204         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
19205         Reported by James Youngman in
19206         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
19207         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
19208         FTS_TIGHT_CYCLE_CHECK.
19209         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
19210         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
19211         once again.
19212         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
19213         * lib/fts.c (fd_safer): Remove decl.
19214         Include fcntl--.h rather than unistd-safer.h
19215         (fts_safe_changedir): Don't call fd_safer; no longer needed
19216         now that we include fcntl--.h.
19217
19218 2005-08-12  Simon Josefsson  <jas@extundo.com>
19219
19220         * modules/getndelim2: Use ssize_t module.
19221         * modules/getnline: Likewise.
19222         * modules/safe-read: Likewise.
19223         * modules/xreadlink: Likewise.
19224
19225         * modules/ssize_t: New file.
19226
19227 2005-08-12  Simon Josefsson  <jas@extundo.com>
19228
19229         * m4/readline.m4: Look for termcap, curses or ncurses if required.
19230
19231 2005-08-12  Simon Josefsson  <jas@extundo.com>
19232
19233         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
19234         ssize_t.
19235
19236 2005-08-12  Simon Josefsson  <jas@extundo.com>
19237
19238         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
19239         readline, getdelim and check_version.
19240         (Support for systems lacking ISO C 99: Sizes of integer types):
19241         Add size_max.
19242
19243 2005-08-12  Bruno Haible  <bruno@clisp.org>
19244
19245         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
19246
19247 2005-08-11  Simon Josefsson  <jas@extundo.com>
19248
19249         * modules/readline: New file.
19250
19251         * modules/strnlen (Files): Add strnlen.h.
19252
19253 2005-08-11  Simon Josefsson  <jas@extundo.com>
19254
19255         * m4/readline.m4: New file.
19256
19257 2005-08-11  Simon Josefsson  <jas@extundo.com>
19258
19259         * lib/readline.h, readline.c: New file.
19260
19261 2005-08-11  Simon Josefsson  <jas@extundo.com>
19262
19263         * doc/gnulib.texi (Initial import, Finishing touches): Mention
19264         gl_AVOID.
19265
19266 2005-08-11  Bruno Haible  <bruno@clisp.org>
19267
19268         * lib/strnlen.h (strnlen): Change parameter name to match comment.
19269
19270 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
19271
19272         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
19273
19274 2005-08-10  Simon Josefsson  <jas@extundo.com>
19275
19276         * tests/test-iconvme.c: New file.
19277
19278 2005-08-10  Simon Josefsson  <jas@extundo.com>
19279
19280         * m4/strnlen.m4: New file.
19281
19282         * m4/strndup.m4: Don't check for strnlen declaration, done in
19283         strnlen.m4.
19284
19285 2005-08-10  Simon Josefsson  <jas@extundo.com>
19286
19287         * lib/strndup.c: Use strnlen.h.
19288
19289         * lib/strnlen.h: New file.
19290
19291 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
19292
19293         * README: Typos.
19294
19295 2005-08-02  Simon Josefsson  <jas@extundo.com>
19296
19297         * modules/readline: New file.
19298
19299 2005-08-02  Simon Josefsson  <jas@extundo.com>
19300
19301         * modules/getdelim: New file.
19302
19303         * modules/getline: Rewrite, don't use getndelim2.
19304
19305 2005-08-02  Simon Josefsson  <jas@extundo.com>
19306
19307         * m4/getline.m4: Separate out getdelim stuff into separate module.
19308
19309         * m4/getdelim.m4: New file.
19310
19311 2005-08-02  Simon Josefsson  <jas@extundo.com>
19312
19313         * lib/getline.h, getline.c: Rewrite.
19314
19315         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
19316
19317 2005-07-31  Bruno Haible  <bruno@clisp.org>
19318
19319         * lib/lock.h (gl_lock_initializer): New macro.
19320         (gl_lock_define_initialized): Use it.
19321         (gl_rwlock_initializer): New macro.
19322         (gl_rwlock_define_initialized): Use it.
19323         (gl_recursive_lock_initializer): New macro.
19324         (gl_recursive_lock_define_initialized): Use it.
19325
19326 2005-07-30  Karl Berry  <karl@gnu.org>
19327
19328         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
19329         Report from Ben Pfaff, regarding getopt.
19330
19331 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
19332
19333         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
19334         normal way.
19335         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
19336         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
19337         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
19338         (gl_GETOPT): Use the new macros.  Most of the implementation
19339         is moved to the new macros.  This is for programs like Emacs
19340         that don't want all the functionality of gl_GETOPT.
19341
19342 2005-07-26  Bruno Haible  <bruno@clisp.org>
19343
19344         * m4/lock.m4: Update from GNU gettext.
19345
19346 2005-07-26  Bruno Haible  <bruno@clisp.org>
19347
19348         * lib/lock.h: Update from GNU gettext.
19349         * lib/lock.c: Update from GNU gettext.
19350
19351 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
19352
19353         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
19354         obsolescent AC_TRY_RUN.  Include the default includes files, for
19355         'exit'.
19356
19357 2005-07-24  Bruno Haible  <bruno@clisp.org>
19358
19359         * modules/visibility: New file.
19360         * MODULES.html.sh (Misc): Add visibility.
19361
19362 2005-07-24  Bruno Haible  <bruno@clisp.org>
19363
19364         * m4/visibility.m4: New file.
19365
19366 2005-07-24  Bruno Haible  <bruno@clisp.org>
19367
19368         * doc/visibility.texi: New file.
19369
19370 2005-07-22  Bruno Haible  <bruno@clisp.org>
19371
19372         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
19373         $(ALLOCA_H), redundant through BUILT_SOURCES.
19374         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
19375         redundant through BUILT_SOURCES.
19376         * modules/byteswap (Makefile.am): Remove explicit dependency on
19377         $(BYTESWAP_H), redundant through BUILT_SOURCES.
19378         * modules/fnmatch (Makefile.am): Remove explicit dependency on
19379         $(FNMATCH_H), redundant through BUILT_SOURCES.
19380         * modules/getopt (Makefile.am): Remove explicit dependency on
19381         $(GETOPT_H), redundant through BUILT_SOURCES.
19382         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
19383         redundant through BUILT_SOURCES.
19384         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
19385         redundant through BUILT_SOURCES.
19386         * modules/stdbool (Makefile.am): Remove explicit dependency on
19387         $(STDBOOL_H), redundant through BUILT_SOURCES.
19388         * modules/stdint (Makefile.am): Remove explicit dependency on
19389         $(STDINT_H), redundant through BUILT_SOURCES.
19390         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
19391         Remove explicit dependency on $(SYSEXITS_H).
19392         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
19393
19394 2005-07-18  Simon Josefsson  <jas@extundo.com>
19395
19396         * lib/check-version.c (check_version): Accept identical versions too.
19397
19398 2005-07-18  Bruno Haible  <bruno@clisp.org>
19399
19400         * modules/lock: New file.
19401         * MODULES.html.sh (Multithreading): New section.
19402
19403 2005-07-18  Bruno Haible  <bruno@clisp.org>
19404
19405         * m4/lock.m4: New file, from GNU gettext.
19406
19407 2005-07-18  Bruno Haible  <bruno@clisp.org>
19408
19409         * lib/lock.h: New file, from GNU gettext.
19410         * lib/lock.c: New file, from GNU gettext.
19411
19412 2005-07-18  Bruno Haible  <bruno@clisp.org>
19413
19414         * lib/lock.h (gl_once_t): New type.
19415         (gl_once_define, gl_once): New macros.
19416         * lib/lock.c (fresh_once): New variable.
19417         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
19418         functions.
19419
19420 2005-07-16  Simon Josefsson  <jas@extundo.com>
19421
19422         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
19423         workaround, suggested by Bruno.
19424
19425 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
19426
19427         * modules/xalloc (Depends-on): Add xalloc-die.
19428         * modules/xvasprintf (Depends-on): Add xalloc-die.
19429
19430 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
19431
19432         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
19433         with a minor change.
19434
19435 2005-07-15  Bruno Haible  <bruno@clisp.org>
19436
19437         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
19438         When using lib/poll.c, define poll as rpl_poll.
19439
19440 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
19441
19442         * modules/argp (Depends-on): Remove unlocked-io.
19443
19444 2005-07-14  Derek Price  <derek@ximbiot.com>
19445
19446         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
19447         for glob symlink bug.
19448
19449 2005-07-14  Bruno Haible  <bruno@clisp.org>
19450
19451         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
19452         Instead, test for *_unlocked function declarations directly.
19453
19454 2005-07-11  Simon Josefsson  <jas@extundo.com>
19455
19456         * modules/size_max: New file.
19457
19458         * modules/xsize: Depend on size_max module for size_max.m4.
19459
19460 2005-07-11  Simon Josefsson  <jas@extundo.com>
19461
19462         * lib/size_max.h: New file.
19463
19464 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
19465
19466         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
19467         copyright symbol and the year.
19468         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
19469         (version_etc_va): Use parameterized copyright notice.
19470         Reword to conform to the current GNU coding standards.
19471
19472 2005-07-11  Karl Berry  <karl@gnu.org>
19473
19474         * doc/gnulib.texi (Quoting): new node.
19475         (Initial import): more info, from Patrice.
19476
19477 2005-07-11  Bruno Haible  <bruno@clisp.org>
19478
19479         * gnulib-tool (func_usage): Document option --avoid.
19480         (Command line options): Handle --avoid.
19481         (func_acceptable): New function.
19482         (func_modules_transitive_closure): Use it.
19483
19484 2005-07-11  Bruno Haible  <bruno@clisp.org>
19485
19486         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
19487         Reported by Jim Meyering.
19488
19489 2005-07-10  Bruno Haible  <bruno@clisp.org>
19490
19491         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
19492         Needed when size_t is smaller than 'unsigned int'.
19493         Reported by Paul Eggert.
19494
19495 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
19496
19497         * modules/argp (Depends-on): Add unlocked-io
19498
19499 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
19500
19501         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
19502         block of defines.
19503
19504 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
19505
19506         * config/srclist.txt: Comment out regcomp.c, since we have a porting
19507         fix now.
19508
19509 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
19510         and Paul Eggert  <eggert@cs.ucla.edu>
19511
19512         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
19513         in wint_t, not wchar_t.  Remove now-unnecessary cast.
19514
19515 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19516
19517         * modules/regex (Files): Add lib/regex_internal.c,
19518         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
19519         (Depends-on): Add extensions.
19520         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
19521
19522 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19523
19524         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
19525         pathconf.
19526         * m4/same.m4 (gl_SAME): Likewise.
19527         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
19528
19529         * m4/regex.m4: Adjust to new libc regex implementation.
19530         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
19531         all the .c and .h parts of (the new) regex.
19532         Quote the m4 stuff better.
19533         Check for RE_ICASE bug of old gnulib.
19534         Check for REG_STARTEND of recent libc.
19535         Rename local variables from jm_* to gl_*.
19536         Quote operand of "test -f".
19537         Say "recent enough" version of libc, not "version 2".
19538         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
19539         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
19540         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
19541         Remove check for btowc, isascii.
19542         Require AM_LANGINFO_CODESET.
19543
19544 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19545
19546         * lib/regex.c, regex.h: Sync from libc.
19547         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
19548         * lib/regexec.c:
19549         New files, synced from libc, except that regex_internal.h
19550         currently has a small porting fix.
19551
19552 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
19553
19554         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
19555         regex_internal.c, regexec.c.
19556         Add regex_internal.h too, but as a comment, since the libc version
19557         is currently broken in gnulib mode.
19558
19559 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
19560
19561         Support programs like Emacs that use gnulib but not gettext.
19562         * MODULES.html.sh (Internationalization functions): Add gettext-h.
19563         * modules/gettext-h: New file.
19564         * modules/gettext (Files): Remove lib/gettext.h.
19565         (Depends-on): Add gettext-h.
19566         (Makefile.am): Remove lib_SOURCES.
19567         * modules/argmatch, modules/c-stack, modules/closeout:
19568         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
19569         * modules/execute, modules/file-type, modules/getaddrinfo:
19570         * modules/getopt, modules/human, modules/javacomp:
19571         * modules/javaexec, modules/mkdir-p, modules/obstack:
19572         * modules/openat, modules/pagealign_alloc, modules/pipe:
19573         * modules/quotearg, modules/regex, modules/rpmatch:
19574         * modules/unicodeio, modules/userspec, modules/version-etc:
19575         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
19576         * modules/xsetenv:
19577         Depend on gettext-h, not gettext.
19578
19579 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
19580
19581         * gnulib-tool (func_import): Add support for 'public domain' license.
19582         * modules/alloca, modules/atexit, modules/memmove:
19583         Now public domain, not GPL.
19584         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
19585         * modules/realloc, modules/strerror, modules/strtod:
19586         Now LGPL, not GPL.
19587
19588 2005-07-05  Bruno Haible  <bruno@clisp.org>
19589
19590         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
19591         autoconf CVS. Needed for mingw.
19592
19593 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
19594
19595         Remove the dependency of the strftime module on the tzset module.
19596         * modules/strftime (Depends-on): Remove dependency on tzset.
19597
19598 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
19599
19600         Remove the dependency of the strftime module on the tzset module.
19601         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
19602         gl_FUNC_TZSET_CLOBBER.
19603
19604 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
19605
19606         Remove the dependency of the strftime module on the tzset module.
19607         * lib/strftime.c (my_strftime)
19608         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
19609         Copy the input structure, to work around some of the bug with
19610         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
19611         Solaris releases, you should also use the tzset module, but we won't
19612         require it as a dependency any more since we don't want LGPLed code
19613         to depend on GPLed code.
19614
19615 2005-07-02  Jim Meyering  <jim@meyering.net>
19616
19617         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
19618         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
19619         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
19620         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
19621
19622 2005-07-02  Jim Meyering  <jim@meyering.net>
19623
19624         * lib/backupfile.c (backup_args): Change a `0' to NULL.
19625
19626 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
19627
19628         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
19629         declares only 'struct timespec;' (!).
19630
19631 2005-07-01  Jim Meyering  <jim@meyering.net>
19632
19633         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
19634         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
19635         * lib/save-cwd.c, tempname.c:
19636         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
19637         and don't include <sys/file.h>).
19638
19639 2005-06-29  Jim Meyering  <jim@meyering.net>
19640
19641         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
19642         type name.  Use the variable name instead.
19643         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
19644         Likewise.
19645
19646 2005-06-28  Simon Josefsson  <jas@extundo.com>
19647
19648         * modules/check-version (Files): Add check-version.m4.
19649
19650 2005-06-28  Simon Josefsson  <jas@extundo.com>
19651
19652         * m4/check-version.m4: New file, suggested by Jim Meyering
19653         <jim@meyering.net>.
19654
19655 2005-06-28  Simon Josefsson  <jas@extundo.com>
19656
19657         * lib/check-version.h, lib/check-version.c: New files.
19658
19659 2005-06-28  Simon Josefsson  <jas@extundo.com>
19660
19661         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
19662         collision with global variable.  Better indentation.  Don't
19663         increment buffer pointer beyond buffer end.  Based on comments
19664         from Paul Eggert <eggert@cs.ucla.edu>.
19665
19666         * lib/base64.h: Indent.
19667
19668 2005-06-28  Simon Josefsson  <jas@extundo.com>
19669
19670         * doc/gnulib.texi (Library version handling): New section.
19671
19672 2005-06-28  Jim Meyering  <jim@meyering.net>
19673
19674         * check-module (find_included_lib_files): Hard-code another
19675         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
19676         but modules/fts-lgpl (correctly) does not list those files.
19677
19678         * modules/canonicalize (Files): Add lib/pathmax.h.
19679
19680 2005-06-25  Simon Josefsson  <jas@extundo.com>
19681
19682         * modules/check-version: New file.
19683
19684 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
19685
19686         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
19687         initializer of struct addrinfo, as an indication that we don't
19688         care how many members the structure has.
19689
19690 2005-06-24  Derek Price  <derek@ximbiot.com>
19691         and Bruno Haible  <bruno@clisp.org>
19692
19693         Remove stat module & update lstat.
19694         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
19695         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
19696         * m4/stat.m4: Remove this file.
19697
19698 2005-06-24  Derek Price  <derek@ximbiot.com>
19699         and Bruno Haible  <bruno@clisp.org>
19700
19701         Remove stat module & update lstat.
19702         * lib/stat.c: Remove this file...
19703         (slash_aware_lstat): ...moving this content and its support...
19704         * lib/lstat.c (rpl_lstat): ...into here.
19705         * lib/lstat.h: New file.
19706
19707 2005-06-24  Derek Price  <derek@ximbiot.com>
19708         and Bruno Haible  <bruno@clisp.org>
19709
19710         Remove stat module & update lstat.
19711         * config/srclist.txt (libc sources): Remove stat.
19712
19713 2005-06-24  Derek Price  <derek@ximbiot.com>
19714         and Bruno Haible  <bruno@clisp.org>
19715
19716         Remove stat module & update lstat.
19717         * MODULES.html.sh (stat): Remove.
19718         * MODULES.html: Regenerated.
19719         * modules/lstat (Description): Correct function name.
19720         (Files): Add "lstat.h".
19721         (Depends-on): Remove stat, add xalloc, stat-macros.
19722         * modules/stat: Remove this file.
19723         (Include): Add "lstat.h", remove <sys/stat.h>.
19724
19725 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
19726
19727         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
19728         (ranged_convert): Don't save conversion in a temporary struct.
19729         This causes a warning with GCC 4.0.0, and anyway in the typical
19730         case it's not worth the extra 100 bytes or so of code.
19731         (ranged_convert, __mktime_internal): When calling a function via a
19732         pointer P, use P () rather than (*P) (), as we now assume C89 or
19733         better.
19734
19735 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19736
19737         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
19738         "who -r" failed to give output.  Problem reported by Tim Waugh.
19739
19740         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
19741         (xcalloc): Use it to avoid needless tests.
19742         Problem reported by Jim Meyering.
19743
19744 2005-06-20  Derek Price  <derek@ximbiot.com>
19745
19746         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
19747         unnecessary for Autoconfs > 2.59c.
19748
19749 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19750
19751         * lib/argp.h (__option_is_short): Check upper limit of
19752         __key. Isprint() requires its argument to have the value
19753         of an unsigned char or EOF.
19754
19755 2005-06-16  Jim Meyering  <jim@meyering.net>
19756
19757         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
19758         when either N or S is zero.
19759
19760 2005-06-16  Derek Price  <derek@ximbiot.com>
19761
19762         * m4/bison.m4: Declare YACC & YFLAGS precious.
19763
19764 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
19765
19766         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
19767         multibyte string or pattern, fall back on unibyte matching.
19768         Problem reported by James Youngman.
19769
19770 2005-06-08  Bruno Haible  <bruno@clisp.org>
19771
19772         * modules/csharpcomp: New file.
19773         * MODULES.html.sh (C#): Add csharpcomp.
19774
19775 2005-06-08  Bruno Haible  <bruno@clisp.org>
19776
19777         * m4/csharpcomp.m4: New file, from GNU gettext.
19778
19779 2005-06-08  Bruno Haible  <bruno@clisp.org>
19780
19781         * lib/csharpcomp.h: New file, from GNU gettext.
19782         * lib/csharpcomp.c: New file, from GNU gettext.
19783         * lib/csharpcomp.sh.in: New file, from GNU gettext.
19784
19785 2005-06-08  Bruno Haible  <bruno@clisp.org>
19786
19787         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
19788         warning on mingw.
19789
19790 2005-06-07  Derek Price  <derek@ximbiot.com>
19791
19792         Sync from CVS.
19793         * lib/glob_.h: Indent nested #ifdef.
19794
19795 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19796
19797         Sync from coreutils.
19798         Use "file name" when talking about file names, instead of "filename"
19799         or "path", as per the GNU coding standards.
19800         * lib/mkdir-p.c: Renamed from makepath.c.
19801         (make_dir_parents): Renamed from make_path.  All callers changed.
19802         * lib/mkdir-p.h: Likewise.  All includers changed.
19803         * lib/filenamecat.c: Renamed from path-concat.c.
19804         (file_name_concat): Renamed from path_concat.  All callers changed.
19805         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
19806         * lib/filenamecat.h: Likewise.  All includers changed.
19807         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
19808         in comments or local variable names.
19809         * lib/basename.c: Likewise.
19810         * lib/canonicalize.c, canonicalize.h: Likewise.
19811         * lib/dirname.c, dirname.h: Likewise.
19812         * lib/euidaccess.c: Likewise.
19813         * lib/exclude.c: Likewise
19814         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
19815         * lib/fsusage.c, fsuage.h: Likewise.
19816         * lib/fts.c, fts_.h: Likewise.
19817         * lib/getcwd.c: Likewise.
19818         * lib/getloadavg.c: Likewise.
19819         * lib/mkstemp.c: Likewise.
19820         * lib/mountlist.c, mountlist.h: Likewise.
19821         * lib/openat.c, openat.h: Likewise.
19822         * lib/readlink-stub.c: Likewise.
19823         * lib/readutmp.c, readutmp.h: Likewise.
19824         * lib/rename.c: Likewise.
19825         * lib/rmdir.c: Likewise.
19826         * lib/same.c: Likewise.
19827         * lib/savedir.c: Likewise.
19828         * lib/stripslash.c: Likewise.
19829         * lib/tempname.c: Likewise.
19830         * lib/xreadlink.c: Likewise.
19831         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
19832         All uses changed.
19833         * lib/exclude.h: Likewise.
19834
19835         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
19836         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19837         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
19838         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19839         * lib/pathmax.h: Include <limits.h> unconditionally, since other
19840         files have been getting away with it for years (MORE/BSD 4.3
19841         is extinct now).
19842         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
19843         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
19844
19845         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
19846         Define to 256, not 255, as per modern POSIX.
19847
19848 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19849
19850         Sync from coreutils.
19851         Use "file name" when talking about file names, instead of "filename"
19852         or "path", as per the GNU coding standards.
19853         * MODULES.html.sh: mkdir-p renamed from makepath.
19854         filenamecat renamed from path-concat.
19855         * modules/filenamecat: Renamed from modules/path-concat.
19856         (Files): filenamecat.h and filenamecat.c renamed from
19857         path-concat.h and path-concat.c.
19858         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
19859         (Include): filenamecat.h, not path-concat.h.
19860         * modules/mkdir-p: Renamed from modules/makepath.
19861         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
19862         makepath.c.
19863         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
19864         (Include): mkdir-p.h, not makepath.h.
19865
19866 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
19867
19868         Sync from coreutils.
19869         * m4/mkdir-p.m4: Renamed from makepath.m4.
19870         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
19871         Rename files from makepath.c to mkdir-p.c, and from
19872         makepath.h to mkdir-p.h.
19873         * m4/filenamecat.m4: Renamed from path-concat.m4.
19874         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
19875         Rename files from path-concat.c to filenamecat.c,
19876         and from path-concat.h to filenamecat.h.
19877         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
19878         "file name" in local variables or comments.
19879         * m4/rename.m4: Likewise.
19880
19881 2005-06-01  Bruno Haible  <bruno@clisp.org>
19882
19883         * modules/csharpexec: New file.
19884         * MODULES.html.sh (C#): New section.
19885
19886 2005-06-01  Bruno Haible  <bruno@clisp.org>
19887
19888         * m4/csharp.m4: New file, from GNU gettext.
19889         * m4/csharpexec.m4: New file, from GNU gettext.
19890
19891 2005-06-01  Bruno Haible  <bruno@clisp.org>
19892
19893         * lib/csharpexec.h: New file, from GNU gettext.
19894         * lib/csharpexec.c: New file, from GNU gettext.
19895         * lib/csharpexec.sh.in: New file, from GNU gettext.
19896
19897 2005-05-31  Derek Price  <derek@ximbiot.com>
19898             Paul Eggert  <eggert@cs.ucla.edu>
19899
19900         Sync from cvs.
19901         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
19902
19903 2005-05-31  Derek Price  <derek@ximbiot.com>
19904             Paul Eggert  <eggert@cs.ucla.edu>
19905
19906         Sync from cvs.
19907         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
19908
19909 2005-05-29  Derek Price  <derek@ximbiot.com>
19910
19911         * config/srclist.txt (glob_.h, glob.c): Add these files.
19912
19913 2005-05-29  Derek Price  <derek@ximbiot.com>
19914
19915         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
19916         * modules/glob: New file.
19917         * modules/getlogin_r: Add link to POSIX spec in description.
19918
19919 2005-05-29  Derek Price  <derek@ximbiot.com>
19920             Paul Eggert  <eggert@cs.ucla.edu>
19921
19922         * m4/glob.m4: New file.
19923
19924 2005-05-29  Derek Price  <derek@ximbiot.com>
19925             Paul Eggert  <eggert@cs.ucla.edu>
19926
19927         * lib/glob_.h, lib/glob.c: New files.
19928
19929 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19930
19931         * modules/fts (Files): Remove m4/inttypes-pri.m4.
19932         * modules/fts-lgpl (Depends-on): Remove gettext.
19933
19934 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19935
19936         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
19937         and don't require gt_INTTYPES_PRI.
19938
19939 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
19940
19941         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
19942
19943         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
19944         the configuration hassle isn't worth it.
19945         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
19946         (LONGEST_MODIFIER, PRIuMAX): Remove.
19947
19948 2005-05-27  Bruno Haible  <bruno@clisp.org>
19949
19950         * lib/getlogin_r.h: Remove second include of <stddef.h>.
19951
19952 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
19953
19954         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
19955         _POSIX_PTHREAD_SEMANTICS for Solaris.
19956
19957 2005-05-25  Derek Price  <derek@ximbiot.com>
19958
19959         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
19960
19961 2005-05-25  Derek Price  <derek@ximbiot.com>
19962             Paul Eggert  <eggert@cs.ucla.edu>
19963
19964         * modules/getlogin_r, m4/getlogin_r.m4: New files.
19965         * lib/getlogin_r.c, getlogin_r.h: New files.
19966
19967 2005-05-25  Bruno Haible  <bruno@clisp.org>
19968             Derek Price  <derek@ximbiot.com>
19969
19970         * lib/getlogin_r.h: Simplify API documentation.
19971
19972 2005-05-23  Derek Price  <derek@ximbiot.com>
19973
19974         * modules/minmax (Files): Add m4/minmax.m4.
19975         (configure.ac): Add gl_MINMAX.
19976
19977 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
19978
19979         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
19980         so that unistd-safer.h (GPL'ed code) need not be included.
19981
19982 2005-05-22  Bruno Haible  <bruno@clisp.org>
19983
19984         * m4/minmax.m4: New file.
19985         Based on a patch by Derek Price <derek@ximbiot.com>.
19986
19987 2005-05-22  Bruno Haible  <bruno@clisp.org>
19988
19989         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
19990         (INT64_MIN): Fix definition.
19991         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
19992
19993         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
19994         NEED_SIGNED_INT_TYPES.
19995
19996         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
19997         HAVE_SYSTEM_INTTYPES.
19998
19999 2005-05-22  Bruno Haible  <bruno@clisp.org>
20000
20001         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
20002         Also include <sys/param.h> if it defines MIN, MAX.
20003         Based on a patch by Derek Price <derek@ximbiot.com>.
20004
20005 2005-05-21  Jim Meyering  <jim@meyering.net>
20006
20007         * modules/fts (Files): Add m4/inttypes-pri.m4.
20008         (Depends-on): Add lstat and remove gettext.  Alphabetize.
20009
20010 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
20011
20012         New fts module.
20013         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
20014         (setup_dir, free_dir): New functions.
20015         (enter_dir, leave_dir): Define trivial
20016         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
20017         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
20018         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
20019         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
20020         Move to fts-cycle.c.
20021         (fts_open): Use setup_dir.
20022         (fts_close): Use free_dir.
20023         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
20024         This adds a label and some gotos, but the alternatives were messier.
20025         Check for memory allocation failure when entering a dir.
20026         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
20027         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
20028         (FTS): New member fts_cycle, that is a union that contains the
20029         old active_dir_ht and cycle_state.  All uses changed to mention
20030         fts_cycle.ht and fts_cycle.state.
20031         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
20032         fts.c, with the following changes:
20033         (setup_dir, free_dir): New functions.
20034         (enter_dir): Now returns bool.  Return true if successful, false
20035         if memory exhausted.  All callers changed.
20036         Do not bother partly cleaning up on
20037         memory allocation failure; that is free_dir's job.
20038         However, free ad if hash_insert fails, to avoid memory leak.
20039         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
20040         fts->fts_options to see which union member to use.
20041
20042 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
20043
20044         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
20045         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
20046
20047 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
20048
20049         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
20050
20051 2005-05-20  Jim Meyering  <jim@meyering.net>
20052
20053         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
20054         Now a macro, to pacify GCC.
20055
20056 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
20057
20058         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
20059         of -1.
20060
20061 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
20062
20063         * lib/chown.c (rpl_chown): Return -1 on failure.
20064
20065 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
20066
20067         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
20068         Don't check for stddef.h.
20069         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
20070         don't use its results.
20071         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
20072         since we include them unconditionally.  Don't require
20073         AM_STDBOOL_H, since stdbool is a prerequisite.
20074         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
20075         since we assume C89 or better.
20076         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
20077         as we don't use their results.
20078         Don't check for fchdir, memmove, memset, strrchr, as we use
20079         them unconditionally.
20080         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
20081         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
20082
20083 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
20084
20085         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
20086         Include <stddef.h> unconditionally, since we assume C89 now.
20087         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
20088         * lib/fts.c: Include fts_.h first, to check interface.
20089         Do not include intprops.h; no longer needed.
20090         Include cycle-check.h and hash.h, since fts_.h no longer does.
20091         Remove unnecessary casts of closedir to void.
20092         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
20093         decide whether to decrement nlinks.
20094         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
20095         (FTS): Use struct hash_table * instead of Hash_table, so that
20096         we no longer need to include hash.h here.
20097
20098 2005-05-18  Jim Meyering  <jim@meyering.net>
20099
20100         * modules/dirfd (License): Change to LGPL.  Most of the code
20101         is already in the public domain.
20102
20103 2005-05-18  Jim Meyering  <jim@meyering.net>
20104
20105         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
20106         Reported by Yoann Vandoorselaere.
20107
20108 2005-05-17  Jim Meyering  <jim@meyering.net>
20109
20110         * m4/fts.m4: New file, from coreutils.
20111
20112 2005-05-17  Jim Meyering  <jim@meyering.net>
20113
20114         * lib/fts.c, lib/fts_.h: New files, from coreutils.
20115
20116 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
20117
20118         Sync from coreutils.
20119         * m4/unlinkdir.m4: New file.
20120
20121 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
20122
20123         Sync from coreutils.
20124         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
20125         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
20126         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
20127         White space changes only.
20128         * lib/makepath.c (make_path): Port to hosts where leading "//" is
20129         special.
20130         * lib/yesno.c: Include getline.h, not ctype.h.
20131         (yesno): Don't remove leading white space; POSIX doesn't allow it.
20132         Use getline to remove arbitrary restriction on response length.
20133
20134 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
20135
20136         * config/srclist-update: Spell out "Street" in FSF postal
20137         mail address; this is the style the FSF seems to prefer.
20138
20139         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
20140         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
20141         this updates FSF postal mail address.
20142
20143         Sync from coreutils.
20144         * modules/unlinkdir: New file.
20145         * modules/yesno (Depends-on): Add getline.
20146         * MODULES.html.sh (File system functions): Add unlinkdir.
20147
20148 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
20149
20150         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
20151         lib/strsep.h:
20152         Change the initial comment to refer to GPL, not LGPL.
20153         gnulib-tool will change it to LGPL as needed.
20154
20155         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
20156         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
20157         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
20158         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
20159         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
20160         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
20161         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
20162         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
20163         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
20164         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
20165         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
20166         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
20167         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
20168         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
20169         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
20170         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
20171         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
20172         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
20173         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
20174         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
20175         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
20176         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
20177         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
20178         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
20179         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
20180         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
20181         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
20182         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
20183         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
20184         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
20185         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
20186         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
20187         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
20188         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
20189         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
20190         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
20191         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
20192         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
20193         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
20194         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
20195         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
20196         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
20197         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
20198         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
20199         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
20200         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
20201         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
20202         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
20203         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
20204         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
20205         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
20206         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
20207         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
20208         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
20209         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
20210         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
20211         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
20212         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
20213         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
20214         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
20215         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
20216         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
20217         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
20218         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
20219         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
20220         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
20221         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
20222         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
20223         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
20224         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
20225         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
20226         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
20227         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
20228         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
20229         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
20230         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
20231         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
20232         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
20233         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
20234         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
20235         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
20236         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
20237         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
20238         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
20239         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
20240         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
20241         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
20242         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
20243         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
20244         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
20245         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
20246         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
20247         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
20248         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
20249         lib/yesno.c, lib/yesno.h:
20250         Update FSF postal mail address.
20251
20252 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
20253
20254         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
20255         tests/test-memmem.c, tests/test-stpncpy.c:
20256         Update FSF postal mail address.
20257
20258 2005-05-13  Bruno Haible  <bruno@clisp.org>
20259
20260         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
20261         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
20262         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
20263         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
20264         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
20265         Add support for 64-bit integers in the MSVC compiler.
20266
20267 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20268
20269         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
20270
20271 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
20272
20273         * gnulib-tool (func_import): Sort and uniquify recommended includes.
20274
20275 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
20276
20277         * doc/getdate.texi (General date syntax): Don't say that date
20278         date --iso-8601=ns generates acceptable dates; it doesn't yet.
20279         Problem reported by Nic Ferrier.
20280
20281 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
20282
20283         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
20284         specified in ai_socktype. Fix invalid ai_protocol
20285         check. ai_protocol is usually set to 0 or depending on
20286         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
20287         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
20288         ai_socktype / ai_protocol in the returned addrinfo structure.
20289
20290 2005-05-10  Simon Josefsson  <jas@extundo.com>
20291
20292         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
20293         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
20294
20295 2005-05-10  Karl Berry  <karl@gnu.org>
20296
20297         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
20298         (from http://www.gnu.org/licenses).
20299         * doc/COPYING.LIB: also rename to COPYING.LESSER.
20300         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
20301         fdl.texi suffices.
20302
20303 2005-05-10  Karl Berry  <karl@gnu.org>
20304
20305         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
20306         (COPYING.DOC): remove.
20307
20308         * config/srclist-update: new FSF address.
20309
20310 2005-05-10  Derek Price  <derek@ximbiot.com>
20311
20312         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
20313         possible.
20314
20315 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
20316             Bruno Haible  <bruno@clisp.org>
20317
20318         * modules/inet_ntop: New file.
20319         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
20320         inet_ntop.
20321
20322 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
20323             Bruno Haible  <bruno@clisp.org>
20324
20325         * m4/inet_ntop.m4: New file.
20326
20327 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
20328             Bruno Haible  <bruno@clisp.org>
20329
20330         * lib/inet_ntop.h: New file.
20331         * lib/inet_ntop.c: New file, from glibc with modifications.
20332
20333 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
20334
20335         * modules/time_r (License): Change to LGPL.
20336         * modules/extensions (License): Change to LGPL.  Actually,
20337         the license is more permissive than that, but currently gnulib-tool
20338         doesn't know how to handle more-permissive licenses.
20339
20340         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
20341         Problem reported by Dave Love.
20342
20343 2005-05-08  Jim Meyering  <jim@meyering.net>
20344
20345         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
20346         blank.
20347
20348 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
20349
20350         * modules/argmatch (Depends-on): Add stdbool.
20351         * modules/backupfile (Depends-on): Likewise.
20352         * modules/chdir-long (Depends-on): Likewise.
20353         * modules/closeout (Depends-on): Likewise.
20354         * modules/cycle-check (Depends-on): Likewise.
20355         * modules/dirname (Depends-on): Likewise.
20356         * modules/fnmatch (Depends-on): Likewise.
20357         * modules/fsusage (Depends-on): Likewise.
20358         * modules/fwriteerror (Depends-on): Likewise.
20359         * modules/getcwd (Depends-on): Likewise.
20360         * modules/getloadavg (Depends-on): Likewise.
20361         * modules/hard-locale (Depends-on): Likewise.
20362         * modules/makepath (Depends-on): Likewise.
20363         * modules/mountlist (Depends-on): Likewise.
20364         * modules/nanosleep (Depends-on): Likewise.
20365         * modules/posixtm (Depends-on): Likewise.
20366         * modules/quotearg (Depends-on): Likewise.
20367         * modules/readtokens (Depends-on): Likewise.
20368         * modules/readtokens0 (Depends-on): Likewise.
20369         * modules/readutmp (Depends-on): Likewise.
20370         * modules/save-cwd (Depends-on): Likewise.
20371         * modules/strftime (Depends-on): Likewise.
20372         * modules/userspec (Depends-on): Likewise.
20373         * modules/utimecmp (Depends-on): Likewise.
20374         * modules/xgetcwd (Depends-on): Likewise.
20375         * modules/xnanosleep (Depends-on): Likewise.
20376         * modules/xstrtod (Depends-on): Likewise.
20377         * modules/yesno (Depends-on): Likewise.
20378
20379 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
20380
20381         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
20382         needless checks.
20383
20384 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20385
20386         Merge from coreutils.  Among other things,
20387         add bulletproofing for cases where stdin, stdout, or stderr are closed.
20388         * lib/fd-safer.c: New file.
20389         * lib/fcntl-safer.h, open-safer.c: Remove.
20390         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
20391         * lib/dup-safer.c: Include unistd-safer.h first.
20392         Don't include errno.h.
20393         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
20394         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
20395         * lib/file-type.c: Rely on file-type.h change.
20396         * lib/getloadavg.c: Include unistd-safer.h.
20397         (getloadavg): Use safer open.
20398         * lib/getusershell.c: Include "stdio-safer.h".
20399         (getusershell): Use safer fopen.
20400         * lib/long-options.c (long_options): Use NULL rather than 0.
20401         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
20402         'free'.
20403         * lib/modechange.c: Likewise.
20404         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
20405         (MODE_DONE): New constant.
20406         (struct mode_change): Remove 'next' member.
20407         (make_node_op_equals): New function; like the old one of the
20408         same name, except it allocates an array.
20409         (mode_compile, mode_create_from_ref): Use it.
20410         (mode_compile): Allocate result as an array, not a linked list.
20411         Parse octal string ourself, so that we catch mistakes like "+0".
20412         (mode_adjust): Arg is an array, not a linked list.
20413         * lib/modechange.c: Include stat-macros.h, xalloc.h.
20414         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
20415         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
20416         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
20417         Remove.  This is now stat-macros.h's job.
20418         (talloc): Remove.  All callers replaced by xalloc, so that
20419         our invokers don't have to worry about reporting memory failures.
20420         (make_node_op_equals): Remove.
20421         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
20422         New constants.
20423         (struct mode_change): Moved here from modechange.h.
20424         (mode_append_entry): Remove.
20425         (mode_compile): Remove MASKED_OPS arg, since it encouraged
20426         apps to have incorrect behavior.  Use simpler algorithm for head
20427         and tail.  Don't futz with umask; that's now the job of mode_adjust.
20428         Detect more invalid usages rather than having somewhat-random behavior.
20429         Don't insert an "a=" action, as that leads to incorrect behavior.
20430         (mode_compile, mode_create_from_ref): Return NULL on error instead
20431         of an enum, since now there's only one way to have an error.  All
20432         callers changed.
20433         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
20434         at the correct time.  Simplify calculation of "+u" and its ilk.
20435         Don't mishandle "+X".
20436         (mode_free): Remove "register" and localize decls.
20437         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
20438         (struct mode_change): Move to modechange.c; callers don't
20439         need to see this stuff.
20440         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
20441         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
20442         (mode_change, mode_adjust): Reflect the new signatures noted above.
20443         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
20444         that might redefine system include files.
20445         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
20446         (my_usleep): Use NULL rather than (void *) 0.
20447         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
20448         Use siginterrupt to specify that system calls should be interrupted.
20449         (rpl_nanosleep): Move initialization of suspended closer to call of
20450         my_usleep.
20451         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
20452         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
20453         (desirable_utmp_entry): New function.
20454         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
20455         using x2nrealloc, to simplify logic.
20456         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
20457         size calculation.  Do not assume utmp file is a regular file.
20458         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
20459         (READ_UTMP_CHECK_PIDS): New constant.
20460         * lib/save-cwd.c: Include unistd-safer.h.
20461         (save_cwd): Use fd_safer.
20462         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
20463         [!_LIBC] Include "stat-macros.h" instead.
20464         * lib/unistd-safer.h (fd_safer): New decl.
20465
20466 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20467
20468         * modules/getloadavg (Depends-on): Add unistd-safer.
20469         * modules/getusershell (Depends-on): Add stdio-safer.
20470         * modules/lstat (Depends-on): Remove xalloc.
20471         * modules/mkstemp (Depends-on): Add stat-macros.
20472         * modules/modechange (Depends-on): Remove xstrtol.
20473         Add stat-macros, xalloc.
20474         * modules/save-cwd (Depends-on): Add unistd-safer.
20475         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
20476         * modules/unistd-safer (Files): Add lib/fd-safer.c
20477         (Makefile.am): Remove lib_SOURCES.
20478
20479         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
20480         Remove fcntl-safer; unistd-safer supersedes it.
20481
20482 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20483
20484         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
20485         AC_HEADER_STAT.
20486         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
20487         (gl_PREREQ_CHOWN): Remove.
20488         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
20489         it.  Don't require AC_HEADER_STAT.
20490         (gl_PREREQ_LSTAT): Remove.
20491         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
20492         Don't require AC_HEADER_STAT.
20493         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
20494         (gl_PREREQ_RMDIR): Remove.
20495         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
20496         mention stat-macros.h or AC_HEADER_STAT, since we'll make
20497         the stat-macros module a prerequisite.
20498         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
20499         * m4/filemode.m4 (gl_FILEMODE): Likewise.
20500         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
20501         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
20502         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
20503         variable names.
20504         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
20505         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
20506         variable prefixes.
20507         * m4/fcntl-safer.m4: Remove.
20508         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
20509         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
20510         Invoke gl_PREREQ_FD_SAFER.
20511         (gl_PREREQ_FD_SAFER): New macro.
20512         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
20513         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
20514         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
20515         Remove duplicate call to AC_LIBOBJ(readutmp).
20516         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
20517
20518         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
20519         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
20520
20521 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
20522
20523         * MODULES.html.sh (Misc): Add byteswap.
20524
20525 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20526
20527         * modules/getcwd (Depends-on): Add extensions.
20528         * modules/openat (Depends-on): Likewise.
20529
20530 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20531
20532         * modules/byteswap: New file.
20533
20534 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20535
20536         * m4/byteswap.m4: New file.
20537
20538 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
20539
20540         * lib/byteswap_.h: New file.
20541
20542 2005-04-25  Karl Berry  <karl@gnu.org>
20543
20544         * m4/gettext.m4: Update from GNU gettext 0.14.4.
20545
20546 2005-04-25  Albert Chin  <china@thewrittenword.com>
20547
20548         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
20549         Toolkit C bug.
20550
20551 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
20552
20553         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
20554         (func_ln_if_changed) Remove forcibly for no error message
20555         in case file does not exist.
20556
20557 2005-04-19  Simon Josefsson  <jas@extundo.com>
20558
20559         * gnulib-tool (Options): Make --symlink mean --symbolic.
20560
20561 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
20562
20563         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
20564
20565 2005-04-16  Simon Josefsson  <jas@extundo.com>
20566
20567         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
20568
20569 2005-04-15  Simon Josefsson  <jas@extundo.com>
20570
20571         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
20572
20573 2005-04-15  Simon Josefsson  <jas@extundo.com>
20574
20575         * gnulib-tool: Rename --symlink to --symbolic.
20576
20577 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
20578
20579         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
20580         symbolic links to files instead of copying/moving.  Add --aux-dir,
20581         specifying directory relative --dir where auxiliary build tools
20582         are placed.
20583
20584 2005-04-14  Bruno Haible  <bruno@clisp.org>
20585
20586         * modules/allocsa (License): Change to LGPL.
20587         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
20588
20589 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
20590
20591         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
20592         that "UTC +1 second" continues to work.  Problem reported
20593         by Dmitry V. Levin.
20594         (relunit_snumber): New rule.
20595         (relunit): Use it.
20596
20597 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
20598
20599         * lib/getdate.y (universal_time_zone_table): New constant.
20600         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
20601         universal_time_zone_table.
20602         (lookup_zone): Prefer universal_time_zone_table to
20603         local_time_zone_table, so that "GMT" time stamps are allowed in
20604         London during the summer.  Problem reported by Ian Abbott.
20605
20606 2005-04-12  Jim Meyering  <jim@meyering.net>
20607
20608         * lib/human.c (humblock): Set *options even when returning due to
20609         xstrtoumax conversion failure.  Thanks to a used-uninitialized
20610         warning from gcc-4.
20611
20612 2005-04-09  Jim Meyering  <jim@meyering.net>
20613
20614         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
20615         -Wuninitialized: initialize tm0.tm_year.
20616
20617 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
20618
20619         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
20620         count, since there's no maximum.  All uses changed.
20621         Add member dsts_seen.
20622         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
20623         not being INT_MAX.
20624         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
20625         Use pc_rels_seen to decide whther a date is absolute.
20626
20627         * lib/getdate.y (number): Don't overwrite year.
20628         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
20629         check.
20630
20631 2005-04-02  Simon Josefsson  <jas@extundo.com>
20632
20633         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
20634         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
20635
20636 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
20637
20638         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
20639         where no absolute path name can be longer than PATH_MAX.
20640
20641 2005-03-27  Jim Meyering  <jim@meyering.net>
20642
20643         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
20644
20645 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
20646
20647         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
20648         "one's complement" -> "ones' complement" in comment, as per Knuth.
20649         "value of type" -> "type or expression" in comment.
20650         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
20651
20652 2005-03-26  Jim Meyering  <jim@meyering.net>
20653
20654         Comment nits.
20655         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
20656         Correct typos: s/or/of/.
20657
20658 2005-03-26  Jim Meyering  <jim@meyering.net>
20659
20660         * modules/check-include-files: Move to ../ and rename to...
20661         * check-module: ...this.
20662
20663 2005-03-25  Jim Meyering  <jim@meyering.net>
20664
20665         * modules/xvasprintf (Files): Add xalloc.h.
20666
20667 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
20668
20669         * modules/gettext (Files): config/config.rpath ->
20670         build-aux/config.rpath
20671         * modules/iconv (Files): Likewise.
20672         Problem reported by Oskar Liljeblad.
20673
20674 2005-03-23  Jim Meyering  <jim@meyering.net>
20675
20676         * modules/check-include-files: New script to check for
20677         missing dependencies, multiple includes, etc.
20678
20679         * modules/c-strtold (Depends-on): Add xalloc.
20680         * modules/c-strtod (Depends-on): Add xalloc.
20681         * modules/hash (Depends-on): Add xalloc.
20682         (Files): Remove lib/xalloc.h.
20683
20684         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
20685         * modules/userspec (Files): Add lib/inttostr.h.
20686
20687 2005-03-23  Jim Meyering  <jim@meyering.net>
20688
20689         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
20690
20691 2005-03-22  Jim Meyering  <jim@meyering.net>
20692
20693         * modules/stat-macros: New module.
20694         * modules/canonicalize, modules/euidaccess, modules/file-type,
20695         * modules/filemode, modules/lchown, modules/makepath,
20696         * modules/rmdir, modules/stat: Depend on new stat-macros module
20697         rather than listing lib/stat-macros.h manually.
20698         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
20699
20700 2005-03-22  Jim Meyering  <jim@meyering.net>
20701
20702         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
20703
20704 2005-03-22  Bruno Haible  <bruno@clisp.org>
20705
20706         * config/srclist.txt: Replace target directory 'config' with
20707         'build-aux'.
20708         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
20709         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
20710         ../build-aux/.
20711
20712 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
20713
20714         * modules/chdir-long (Depends-on): Add mempcpy.
20715
20716         * modules/acl, modules/backupfile, modules/c-strtod,
20717         modules/c-strtold, modules/canon-host, modules/canonicalize,
20718         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
20719         modules/exclude, modules/exitfail, modules/file-type,
20720         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
20721         modules/getdate, modules/getline, modules/getpagesize,
20722         modules/getpass, modules/getugroups, modules/group-member,
20723         modules/hard-locale, modules/hash, modules/human, modules/idcache,
20724         modules/inttostr, modules/long-options, modules/makepath,
20725         modules/md5, modules/memcasecmp, modules/memcoll,
20726         modules/modechange, modules/mountlist, modules/path-concat,
20727         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
20728         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
20729         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
20730         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
20731         modules/strftime, modules/strndup, modules/strverscmp,
20732         modules/timespec, modules/unlocked-io, modules/userspec,
20733         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
20734         modules/yesno:
20735         Remove lib_SOURCES line from Makefile.am section, as this is now
20736         done automatically by the corresponding Autoconf macro.
20737
20738 2005-03-21  Jim Meyering  <jim@meyering.net>
20739
20740         Changes imported from coreutils.
20741
20742         * lib/cycle-check.c: Don't include xalloc.h.
20743
20744         * lib/path-concat.c: Don't include assert.h.
20745         (path_concat): Remove assertion that would have triggered
20746         for ABASE starting with more than one slash.
20747         Reported by Andreas Schwab.
20748
20749         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
20750         properly when ABASE is an absolute file name.
20751         Correct the description of this function.
20752         Include <assert.h>.
20753         Add an assertion and a test driver.
20754         This fixes a bug introduced on 2004-07-02.
20755         Andreas Schwab reported the resulting failure of cp --parents:
20756         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
20757
20758 2005-03-21  Jim Meyering  <jim@meyering.net>
20759
20760         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
20761         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
20762
20763 2005-03-21  Jim Meyering  <jim@meyering.net>
20764         and  Paul Eggert  <eggert@cs.ucla.edu>
20765
20766         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
20767         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
20768         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
20769         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
20770         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
20771         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
20772         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
20773         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
20774         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
20775         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
20776         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
20777         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
20778         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
20779         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
20780         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
20781         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
20782         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
20783         for these modules.
20784
20785 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
20786
20787         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
20788         (which shouldn't happen), generate nothing instead of returning 0
20789         immediately, so that nstrftime (NULL, ...) doesn't return 0.
20790
20791 2005-03-16  Bruno Haible  <bruno@clisp.org>
20792
20793         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
20794         HAVE_LONGLONG_64BIT.
20795
20796 2005-03-16  Bruno Haible  <bruno@clisp.org>
20797
20798         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
20799         HAVE_LONGLONG_64BIT.
20800
20801 2005-03-16  Bruno Haible  <bruno@clisp.org>
20802
20803         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
20804         HAVE_LONGLONG_64BIT.
20805
20806 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
20807
20808         * lib/strftime.c (my_strftime): Prepend space to format so that we can
20809         reliably distinguish strftime failure from empty output on POSIX
20810         hosts.
20811
20812 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
20813
20814         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
20815         (iconv_string): Don't guess a size-zero buffer, as that might cause
20816         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
20817         result would be 'too large', where 'too large' is (heuristically)
20818         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
20819         overflow concerns.  This will prevent some unwanted malloc failures
20820         when the inputs are very large.
20821
20822 2005-03-15  Karl Berry  <karl@gnu.org>
20823
20824         * config/srclist.txt (config.rpath): from gettext.
20825         * config/config.rpath: update.
20826
20827 2005-03-15  Bruno Haible  <bruno@clisp.org>
20828
20829         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
20830         to 'negate'.
20831
20832         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
20833         variable.
20834
20835         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
20836         results.
20837
20838 2005-03-14  Simon Josefsson  <jas@extundo.com>
20839
20840         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
20841         <fx@gnu.org>.
20842
20843 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
20844
20845         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
20846         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
20847         intprops.h.
20848         * lib/strtol.c: Likewise.
20849
20850 2005-03-14  Jim Meyering  <jim@meyering.net>
20851
20852         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
20853         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
20854         to be nonzero so that we (and caller) can detect the difference
20855         between a valid zero-length expansion and an error return, even
20856         when the underlying strftime fails before writing anything into
20857         that location.
20858
20859 2005-03-14  Bruno Haible  <bruno@clisp.org>
20860
20861         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
20862         Update from GNU gettext 0.14.3.
20863
20864 2005-03-10  Jim Meyering  <jim@meyering.net>
20865
20866         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
20867
20868 2005-03-10  Jim Meyering  <jim@meyering.net>
20869
20870         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
20871         so that this module works on systems without fchdir.
20872
20873 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
20874
20875         Factor int-properties macros into a single file, except for
20876         glibc-related files.
20877         * lib/intprops.h: New file.
20878         * lib/getloadavg.c: Include it instead of limits.h.
20879         (INT_STRLEN_BOUND): Remove.
20880         * lib/human.c: Include intprops.h.
20881         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
20882         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
20883         302/1000.
20884         * lib/inttostr.h: Include intprops.h instead of limits.h.
20885         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
20886         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
20887         for consistency with intprops.h.
20888         (time_t_is_integer, twos_complement_arithmetic): Use them.
20889         * lib/sig2str.h: Include <signal.h>, intprops.h.
20890         (INT_STRLEN_BOUND): Remove.
20891         * lib/strftime.c (TYPE_SIGNED): Remove.
20892         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
20893         * lib/strtol.c: Adjust comments to match intprops.h.
20894         * lib/userspec.c: Include intprops.h.
20895         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
20896         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
20897         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
20898         instead of rolling our own expressions.
20899         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
20900
20901         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
20902         instead of int.
20903         (my_strftime): Do not mishandle years close to INT_MAX, by doing
20904         the right thing even if adding 1900 would overflow.  Similarly
20905         for tm_mon + 1 and tm_yday + 1.
20906         Make %Y always equivalent to %C%y, and similarly for %G and %g.
20907         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
20908         (DO_SIGNED_NUMBER): New macro.
20909         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
20910
20911 2005-03-07  Bruno Haible  <bruno@clisp.org>
20912
20913         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
20914
20915 2005-03-07  Bruno Haible  <bruno@clisp.org>
20916
20917         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
20918
20919 2005-03-04  Derek R. Price  <derek@ximbiot.com>
20920
20921         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
20922         (func_import): Only replace files via --import when they have actually
20923         changed.
20924
20925 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20926
20927         * m4/mmap-anon.m4: New file.
20928         * m4/pagealign_alloc.m4: New file.
20929
20930 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20931             Bruno Haible  <bruno@clisp.org>
20932
20933         * modules/pagealign_alloc: New file.
20934         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
20935
20936 2005-03-03  Derek R. Price  <derek@ximbiot.com>
20937             Bruno Haible  <bruno@clisp.org>
20938
20939         * lib/pagealign_alloc.h: New file.
20940         * lib/pagealign_alloc.c: New file.
20941
20942 2005-03-03  Bruno Haible  <bruno@clisp.org>
20943
20944         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
20945         Use an all-permissive copyright notice, recommended by RMS.
20946
20947 2005-03-02  Bruno Haible  <bruno@clisp.org>
20948
20949         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
20950         of AIX, the replacement has to be done only after <string.h> is
20951         included, therefore not in config.h. stpncpy.h does the replacement,
20952         and stpncpy.c uses it.
20953
20954 2005-03-02  Bruno Haible  <bruno@clisp.org>
20955
20956         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
20957         stpncpy.c uses it.
20958
20959 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20960
20961         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
20962         The workaround isn't strictly needed for POSIX conformance, and
20963         it's too much of a pain to configure and maintain.  We'll ask
20964         people to fix their kernels instead.
20965         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
20966         (NANOSLEEP_BUG_WORKAROUND): Remove.
20967         (xnanosleep): Remove the workaround.
20968
20969 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20970
20971         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
20972         Reported by Derek Price.
20973         (Include): Add "timespec.h".
20974
20975         * modules/xnanosleep (Depends-on): Remove gethrxtime.
20976
20977 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
20978
20979         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
20980         to detect nanosleep bug.
20981
20982 2005-03-01  Bruno Haible  <bruno@clisp.org>
20983
20984         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
20985
20986 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
20987
20988         * modules/gethrxtime: New file.
20989         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
20990         (Depends-on): Add gethrxtime.
20991         (configure.ac): Add gl_XNANOSLEEP.
20992         (Makefile.am): Remove lib_SOURCES line.
20993
20994 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
20995
20996         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
20997         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
20998
20999 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
21000
21001         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
21002         * lib/timespec.h (gettime): Return void, since it always
21003         succeeds now.  All uses changed.
21004         * lib/gettime.c (gettime) Likewise.
21005         [HAVE_NANOTIME]: Prefer nanotime.
21006         Assume gettimeofday succeeds, as POSIX requires.
21007         Assime time () succeeds, since other code already does.
21008         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
21009         (timespec_subtract): Remove.
21010         (NANOSLEEP_BUG_WORKAROUND): New constant.
21011         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
21012         things considerably.  Use it only on GNU/Linux hosts, since the
21013         workaround shouldn't be needed elsewhere.
21014
21015 2005-02-24  Bruno Haible  <bruno@clisp.org>
21016
21017         * modules/gettext (Files): Add m4/glibc2.m4.
21018
21019 2005-02-24  Bruno Haible  <bruno@clisp.org>
21020
21021         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
21022         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
21023         * m4/progtest.m4:
21024         Update from GNU gettext 0.14.2.
21025         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
21026
21027 2005-02-24  Bruno Haible  <bruno@clisp.org>
21028
21029         * lib/localcharset.c: Update from GNU gettext 0.14.2.
21030         * lib/config.charset: Update from GNU gettext 0.14.2.
21031
21032 2005-02-24  Bruno Haible  <bruno@clisp.org>
21033
21034         * lib/gettext.h: Update from GNU gettext 0.14.2.
21035
21036 2005-02-23  Simon Josefsson  <jas@extundo.com>
21037
21038         * m4/iconvme.m4: New file.
21039
21040 2005-02-23  Jim Meyering  <jim@meyering.net>
21041
21042         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
21043         change.
21044         Thanks to Bruno Haible for catching it.
21045
21046 2005-02-22  Simon Josefsson  <jas@extundo.com>
21047
21048         * modules/iconvme: New file.
21049
21050         * MODULES.html.sh: Add iconvme.
21051
21052 2005-02-22  Simon Josefsson  <jas@extundo.com>
21053
21054         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
21055
21056 2005-02-22  Simon Josefsson  <jas@extundo.com>
21057
21058         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
21059
21060 2005-02-22  Jim Meyering  <jim@meyering.net>
21061
21062         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
21063         s/ifndef/ifdef/.
21064
21065 2005-02-20  Neil Conway  <neilc@samurai.com>
21066
21067         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
21068         returned by OSX/Darwin if the specified buffer is not large
21069         enough for the hostname.
21070
21071 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21072
21073         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
21074         pass it to _help, otherwise the latter coredumps trying to
21075         dereference state.root_argp.
21076
21077 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
21078
21079         * modules/chdir-long (Depends-on): Add memrchr.
21080         * modules/memrchr (Files): Add lib/memrchr.h.
21081         (Include): "memrchr.h".
21082
21083 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
21084
21085         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
21086
21087 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
21088
21089         * lib/memrchr.h: New file.
21090         * lib/chdir-long.c: Include it.
21091         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
21092         Don't bother including stddef.h.
21093
21094 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
21095
21096         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
21097         inclusion.
21098         Include <sys/types.h>, for dev_t.
21099         (ME_DUMMY, ME_REMOTE): Move from here....
21100         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
21101         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
21102         Dmitry V. Levin.
21103         Include mountlist.h first, to test the interface.
21104
21105 2005-01-29  Bruno Haible  <bruno@clisp.org>
21106
21107         * lib/progname.c (program_name): Initialize.
21108         Needed when linking statically on MacOS X.
21109
21110 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
21111
21112         Sync from coreutils.
21113         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
21114         (Depends-on): Add c-strtod.
21115         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
21116
21117 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
21118
21119         Sync from coreutils.
21120         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
21121
21122         Remove files that are specific to coreutils.
21123         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
21124
21125 2005-01-28  Bruno Haible  <bruno@clisp.org>
21126
21127         * modules/javacomp: New file.
21128         * MODULES.html.sh (Java): Add javacomp.
21129
21130 2005-01-28  Bruno Haible  <bruno@clisp.org>
21131
21132         * m4/javacomp.m4: New file, from GNU gettext.
21133
21134 2005-01-28  Bruno Haible  <bruno@clisp.org>
21135
21136         * lib/javacomp.sh.in: New file, from GNU gettext.
21137         * lib/javacomp.h: New file, from GNU gettext.
21138         * lib/javacomp.c: New file, from GNU gettext.
21139
21140 2005-01-26  Simon Josefsson  <jas@extundo.com>
21141
21142         * lib/gai_strerror.c: Use GPL in header.
21143
21144 2005-01-26  Bruno Haible  <bruno@clisp.org>
21145
21146         * modules/javaexec: New file.
21147         * MODULES.html.sh (Java): Add javaexec.
21148
21149 2005-01-26  Bruno Haible  <bruno@clisp.org>
21150
21151         * m4/javaexec.m4: New file, from GNU gettext.
21152
21153 2005-01-26  Bruno Haible  <bruno@clisp.org>
21154
21155         * lib/javaexec.sh.in: New file, from GNU gettext.
21156         * lib/javaexec.h: New file, from GNU gettext.
21157         * lib/javaexec.c: New file, from GNU gettext.
21158
21159 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21160
21161         * modules/lchown (Depends-on): Remove lchown.h
21162
21163 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21164
21165         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
21166         must be defined if the header file was not found, in order
21167         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
21168
21169 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21170
21171         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
21172         initializers for struct pentry_state.
21173         (__argp_error): Check return value of __asprintf
21174         (__argp_failure): Translate error message
21175
21176         * lib/argp-parse.c: Removed braces around the expansion of N_()
21177
21178 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
21179
21180         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
21181         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
21182         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
21183         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
21184         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
21185         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
21186         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
21187         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
21188         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
21189         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
21190         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
21191         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
21192         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
21193         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
21194         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
21195         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
21196         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
21197         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
21198         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
21199         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
21200         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
21201         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
21202         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
21203         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
21204         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
21205         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
21206         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
21207         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
21208         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
21209         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
21210         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
21211         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
21212         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
21213         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
21214         xstrtol.m4, xstrtoumax.m4, yesno.m4:
21215         Use an all-permissive copyright notice, recommended by RMS.
21216
21217 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
21218
21219         * modules/chdir-long (Depends-on): Remove mempcpy.
21220
21221 2005-01-21  Jim Meyering  <jim@meyering.net>
21222
21223         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
21224         same value as for Solaris 9.
21225
21226         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
21227         component length.  This included changing the parameter to be
21228         of type `char *' rather than `char const *'.
21229         * lib/chdir-long.h (chdir_long): Update prototype.
21230
21231         * lib/openat.c (fdopendir, fstatat): New functions.
21232         * lib/openat.h: Include headers required for use of DIR and struct
21233         stat.
21234         [AT_SYMLINK_NOFOLLOW]: Define.
21235         (fdopendir, fstatat): Add prototypes.
21236
21237 2005-01-21  Bruno Haible  <bruno@clisp.org>
21238
21239         * modules/classpath: New file.
21240         * MODULES.html.sh (Java): Add classpath.
21241
21242 2005-01-21  Bruno Haible  <bruno@clisp.org>
21243
21244         * lib/classpath.h: New file, from GNU gettext.
21245         * lib/classpath.c: New file, from GNU gettext.
21246
21247 2005-01-20  Simon Josefsson  <jas@extundo.com>
21248
21249         * modules/version-etc-fsf: New file.
21250
21251 2005-01-20  Simon Josefsson  <jas@extundo.com>
21252
21253         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
21254         * lib/version-etc.c: Remove version_etc_copyright.
21255         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
21256         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
21257
21258 2005-01-20  Simon Josefsson  <jas@extundo.com>
21259
21260         * lib/base64.h (isbase64): Add.
21261
21262         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
21263         using a unsigned prototype, don't inline.
21264         (base64_decode): Use it.
21265
21266 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
21267
21268         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
21269         it.
21270
21271 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
21272
21273         * lib/save-cwd.c (save_cwd): Remove code to support the case
21274         where fchdir is missing or flaky.
21275
21276 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
21277
21278         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
21279
21280 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
21281
21282         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
21283         AC_LIBSOURCES now does this.
21284         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
21285         with new ullong_max module.
21286
21287 2005-01-19  Bruno Haible  <bruno@clisp.org>
21288
21289         * modules/sh-quote: New file.
21290         * MODULES.html.sh (Executing programs): Add sh-quote.
21291
21292 2005-01-19  Bruno Haible  <bruno@clisp.org>
21293
21294         * lib/sh-quote.h: New file, from GNU gettext.
21295         * lib/sh-quote.c: New file, from GNU gettext.
21296
21297 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
21298
21299         Merge from coreutils.
21300         * m4/ullong_max.m4: New file.
21301         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
21302         (gl_MACROS): Assume localeconv exists.
21303
21304 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
21305
21306         Merge changes from coreutils, as described below in several
21307         changelogs dated today.
21308
21309         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
21310         (O_DIRECTORY): Remove; not needed here, since "." must be
21311         a directory.  All uses removed.
21312         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
21313         universal on Suns, and we also need to test for IRIX.
21314         Revamp code to use 'if' rather than '#if'.
21315         Avoid unnecessary comparison of cwd->desc to 0.
21316
21317         * lib/utimens.c (futimens): Robustify the previous patch, by checking
21318         for known valid error numbers rather than observed invalid ones.
21319
21320 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
21321
21322         * modules/ullong_max: New file.
21323
21324         * modules/chdir-long, modules/openat: New files.
21325         * modules/save-cwd (Depends-on): Depend on chdir-long.
21326         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
21327
21328 2005-01-18  Jim Meyering  <jim@meyering.net>
21329
21330         Merge from coreutils.
21331         * m4/chdir-long.m4, m4/openat.m4: New files.
21332         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
21333         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
21334         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
21335         is sane and DOES follow symlinks.  Besides, testing 20 different
21336         systems found no broken chown implementations.
21337         Prompted by a change in rsync's copy of this macro.
21338         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
21339
21340         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
21341
21342         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
21343         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
21344         NULL-means-set-to-current-time semantics.
21345         Remove temporary file immediately, rather than waiting
21346         for configure's at-exit trap code to do it.
21347
21348 2005-01-18  Jim Meyering  <jim@meyering.net>
21349
21350         * lib/version-etc.c (version_etc_copyright): Update copyright date.
21351
21352         * lib/utimens.c (futimens): Account for the fact that futimes
21353         can also fail with errno == ENOSYS or errno == ENOENT.
21354         Patch from Dmitry V. Levin.
21355
21356         Change the name of the robust chdir function from chdir to chdir_long.
21357         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
21358         (restore_cwd): Use chdir_long, not chdir.
21359         * lib/chdir-long.c: Renamed from chdir.c.
21360         * lib/chdir-long.h: Renamed from chdir.h.
21361         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
21362         Hurd.
21363
21364 2005-01-18  Bruno Haible  <bruno@clisp.org>
21365
21366         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
21367         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
21368         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
21369         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
21370         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
21371         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
21372         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
21373         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
21374         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
21375         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
21376         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
21377         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
21378         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
21379         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
21380         Use an all-permissive copyright notice, recommended by RMS.
21381
21382 2005-01-18  Bob Proulx  <bob@proulx.com>
21383
21384         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
21385         simplify offsetof() macro construct to avoid compile failure with
21386         native HP-UX 11.0 ANSI C compiler.
21387
21388 2005-01-17  Bruno Haible  <bruno@clisp.org>
21389
21390         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
21391         redundant because stpncpy.m4 takes care of it.
21392
21393 2005-01-17  Bruno Haible  <bruno@clisp.org>
21394
21395         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
21396
21397 2005-01-17  Bruno Haible  <bruno@clisp.org>
21398
21399         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
21400         used.
21401
21402 2005-01-17  Bruno Haible  <bruno@clisp.org>
21403
21404         * lib/fwriteerror.h (fwriteerror): Change specification to include
21405         fclose.
21406         * lib/fwriteerror.c: Include <stdbool.h>.
21407         (fwriteerror): At the end, close the file stream. Record whether
21408         stdout was already closed.
21409
21410 2005-01-17  Bruno Haible  <bruno@clisp.org>
21411
21412         * lib/execute.c (environ): Declare if needed.
21413         * lib/pipe.c (environ): Likewise.
21414         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
21415
21416 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21417
21418         * modules/argp: Depend on vsnprintf
21419
21420 2005-01-10  Jim Meyering  <jim@meyering.net>
21421
21422         * modules/closeout (Depends-on): Add atexit.
21423
21424 2005-01-06  Bruno Haible  <bruno@clisp.org>
21425
21426         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
21427
21428 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
21429
21430         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
21431         definitions to be after all include files, to avoid collisions.
21432         Problem reported by Bob Proulx.
21433
21434 2005-01-04  Jim Meyering  <jim@meyering.net>
21435
21436         Changes imported from coreutils.
21437         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
21438         as the mkstemp template, use a temporary directory and an
21439         8.3-friendly template to avoid trouble on systems like DJGPP.
21440         Reported by Juan M. Guerrero via Stepan Kasal.
21441         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
21442         close. Remove the temporary directory right away, rather than waiting
21443         for configure's at-exit trap code to do it.
21444         Suggestion from Stepan Kasal.
21445
21446 2005-01-01  Simon Josefsson  <jas@extundo.com>
21447
21448         * gnulib-tool: Print #include directives when --import'ing.
21449
21450 2004-12-28  Simon Josefsson  <jas@extundo.com>
21451
21452         * tests/test-base64.c: Include required header files.  Remove
21453         unused variables.
21454
21455 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
21456
21457         * modules/error (Depends-on): Remove gettext.
21458
21459 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
21460
21461         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
21462         not needed.  This removes a dependency on the gettext module.
21463         [defined _LIBC]: Do not include <libintl.h>; not needed.
21464
21465 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
21466
21467         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
21468         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
21469
21470 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
21471
21472         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
21473         HAVE_DECL_STRTOLD.
21474
21475 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
21476
21477         * modules/getdate (Depends-on): Remove alloca-opt.
21478
21479 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
21480
21481         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
21482
21483 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
21484
21485         * lib/argp-parse.c: Include <stddef.h>.
21486         (alignof, alignto): New macros.
21487         (parser_init): Don't assume that void * is aligned sufficiently
21488         for struct option.
21489
21490         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
21491         need to extend the stack.
21492         (YYINITDEPTH): New macro, so that the initial stack isn't overly
21493         large.
21494
21495 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21496
21497         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
21498
21499 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
21500
21501         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
21502         (2004-10-24) change.  Apparently this was a false alarm.
21503
21504         * modules/getdate: Depend on alloca-opt, not alloca.
21505
21506 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
21507
21508         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
21509         Remove now-obsolete comment about AIX.
21510         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
21511         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
21512         (YYMAXDEPTH): New macro.
21513
21514 2004-12-18  Simon Josefsson  <jas@extundo.com>
21515
21516         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
21517
21518 2004-12-18  Bruno Haible  <bruno@clisp.org>
21519
21520         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
21521
21522 2004-12-18  Bruno Haible  <bruno@clisp.org>
21523
21524         * lib/fatal-signal.c (fatal_signals): Make non-const.
21525         (init_fatal_signals): New function.
21526         (uninstall_handlers, install_handlers): Ignore signals that were set to
21527         SIG_IGN.
21528         (at_fatal_signal): Call init_fatal_signals.
21529         (init_fatal_signal_set): Likewise. Ignore signals that were set to
21530         SIG_IGN.
21531         Reported by Paul Eggert.
21532
21533 2004-12-18  Bruno Haible  <bruno@clisp.org>
21534
21535         * doc/alloca.texi: New file.
21536         * doc/alloca-opt.texi: New file.
21537
21538 2004-12-17  Jim Meyering  <jim@meyering.net>
21539
21540         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
21541         Otherwise, install-sh could exit with improper exit status when
21542         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
21543
21544 2004-12-16  Simon Josefsson  <jas@extundo.com>
21545
21546         * tests/test-base64.c: Add license.
21547
21548 2004-12-15  Stepan Kasal  <address@hidden>
21549
21550         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
21551
21552 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
21553
21554         * modules/getcwd (Files): Add m4/d-ino.m4.
21555         Suggested by Mark D. Baushke.
21556
21557 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
21558
21559         * lib/getdate.y (textint): New member "negative".
21560         (time_zone_hhmm): New function.
21561         Expect 14 shift-reduce conflicts, not 13.
21562         (o_colon_minutes): New rule.
21563         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
21564         (yylex): Set the "negative" member of signed numbers.
21565
21566 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
21567
21568         * doc/getdate.texi (Time of day items, Time zone items):
21569         Describe new formats +00:00, UTC+00:00.
21570
21571 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
21572
21573         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
21574         spurious "-l"s.  Problem reported by Stepan Kasal.
21575
21576 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
21577
21578         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
21579         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
21580
21581 2004-12-04  Simon Josefsson  <jas@extundo.com>
21582
21583         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
21584         Vandoorselaere <yoann@prelude-ids.org>.
21585
21586 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
21587
21588         Changes imported from coreutils.
21589         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
21590         exist.
21591         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
21592
21593 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
21594
21595         Changes imported from coreutils.
21596         * lib/hard-locale.c: Assume <locale.h> exists.
21597         Include "strdup.h".
21598         (GLIBC_VERSION): New macro.
21599         (hard_locale): Assume setlocale exists.
21600         Rewrite to avoid #ifdef.
21601         Use strdup rather than malloc + strcpy.
21602         * lib/human.c: Assume <locale.h> exists.
21603         (human_readable): Assume localeconv exists.
21604
21605 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
21606
21607         * modules/hard-locale (Depends-on): Add strdup.
21608
21609 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
21610
21611         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
21612         convert T2, not T.  (Imported from libc.)
21613
21614 2004-11-30  Simon Josefsson  <jas@extundo.com>
21615
21616         * modules/restrict (License): Change to LGPL.
21617
21618 2004-11-30  Simon Josefsson  <jas@extundo.com>
21619
21620         * m4/restrict.m4: Add copyright and copying conditions.
21621
21622 2004-11-30  Simon Josefsson  <jas@extundo.com>
21623
21624         * m4/base64.m4: New file.
21625
21626 2004-11-30  Simon Josefsson  <jas@extundo.com>
21627
21628         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
21629         base64.
21630
21631         * tests/test-base64.c: New file.
21632
21633         * modules/base64: New file.
21634
21635 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
21636
21637         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
21638         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
21639
21640         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
21641
21642 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
21643
21644         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
21645         (__getcwd.c): Don't restore errno; glibc doesn't.
21646         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
21647         first, falling back to our code only if its results look suspicious.
21648         Ensure that the resulting buffer is only as large as necessary.
21649
21650         * lib/readutmp.c: Include readutmp.h first.
21651         Include <errno.h>, since readutmp.h no longer does that.
21652         * lib/readutmp.h: Don't include <errno.h>,
21653         <sys/param.h>, <time.h>; not needed to establish interface.
21654         (errno): Remove decl.
21655         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
21656         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
21657         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
21658
21659 2004-11-28  Simon Josefsson  <jas@extundo.com>
21660
21661         * lib/base64.h, base64.c: New file.
21662
21663 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
21664
21665         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
21666
21667 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
21668
21669         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
21670         (Depends-on): Remove pathmax, same.  Add mempcpy.
21671         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
21672         (Makefile.am): Append getcwd.h to lib_SOURCES.
21673         (Include): Add getcwd.h.
21674         (Maintainer): Change from Jim Meyering to "all, glibc",
21675         since getdate now uses intended-for-glibc code.
21676         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
21677         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
21678
21679 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
21680
21681         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
21682         HP's ANSI C compiler.
21683         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
21684         Declaring int functions causes warnings on some modern systems and
21685         shouldn't be needed to compile on ancient ones.
21686         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
21687         defined.
21688
21689         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
21690         with the following changes.
21691         (__set_errno): Parenthesize properly.
21692         Include <stdbool.h>.
21693         (MIN, MAX, MATCHING_INO): New macros.
21694         (__getcwd): Define with prototype, not K&R form.
21695         Use heuristics to allocate default buffer on stack if possible.
21696         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
21697         behavior, and to avoid the PATH_MAX limit when computing
21698         ../../../../...
21699         Use MATCHING_INO to compare inode number to file.
21700         Check for arithmetic overflow in size calculations.
21701         Fix bug in reallocation of dot array that caused getcwd to fail
21702         on directories nested deeper than 75.
21703         Be more careful about saving errno on error.
21704         Do not use realloc; use only free+malloc, as this is a bit
21705         more flexible and avoids a needless copy operation.
21706         Do not inspect st_dev and st_ino for symbolic links; POSIX
21707         doesn't specify the latter.
21708         Check for closedir errors.
21709         Avoid needless casts.
21710         Use "#ifdef weak_alias" around weak_alias, to be like other
21711         glibc code.
21712         The following changes to getcwd.c have effect only when used in
21713         gnulib; they have no effect inside glibc proper.
21714         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
21715         as alloca isn't used.
21716         (alloca, __alloca): Likewise.
21717         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
21718         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
21719         unconditionally, as gnulib assumes C89 or better.
21720         Do not include <sys/param.h>.
21721         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
21722         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
21723         better.
21724         (NULL) [!defined NULL]: Remove; we assume C89 or better.
21725         Include <dirent.h> in a way that is compatible with modern Autoconf.
21726         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
21727         New macros, if not already defined.
21728         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
21729         Use "_LIBC", not "defined _LIBC", for consistency.
21730         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
21731         a mempcpy module.
21732         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
21733         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
21734         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
21735         credit only to Jim Meyering and adjust the copyright dates.
21736         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
21737         <stdlib.h>, <unistd.h>, "pathmax.h".
21738         Instead, include "xgetcwd.h" (first) and "getcwd.h".
21739         (INITIAL_BUFFER_SIZE): Remove.
21740         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
21741
21742 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
21743
21744         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
21745         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
21746         Use the _ONCE methods, for efficiency.
21747         Check for fcntl.h.  In test program, include <errno.h>
21748         and <fcntl.h> if available.  Remove old K&R cruft from
21749         test program.  Check for common errors in GNU/Linux,
21750         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
21751         don't do AC_LIBOBJ, as that's getcwd.m4's job.
21752         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
21753         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
21754         name accordingly.
21755         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
21756         accommodate new getcwd.c.
21757         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
21758         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
21759         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
21760         that's all we need now.
21761
21762 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21763
21764         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
21765         argp-parse.c depends on getopt internals, that means we should
21766         always use our getopt, to be on the safe side.
21767         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
21768         order not to spoil the result of an eventual previous invocation
21769         of gl_GETOPT_SUBSTITUTE.
21770
21771 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
21772
21773         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
21774         redefinition warnings. To avoid them, include the defines
21775         in `#if !defined __need_getopt ... #endif'. The only place
21776         where __getopt_argv_const is used is in definitions
21777         of getopt_long and getopt_long_only below, which are as well
21778         protected by `#ifndef __need_getopt'.
21779         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
21780         __need_getopt after including <stdio.h> and <unistd.h> These
21781         headers might have defined it.
21782
21783 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
21784
21785         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
21786
21787 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
21788
21789         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
21790         (futimens): New function, which uses futimes if available.
21791         (futimens, utimens): Support timespec==NULL, with same semantics
21792         as utime and utimens.
21793         * lib/utimens.h (futimens): New decl.
21794
21795 2004-11-23  Jim Meyering  <jim@meyering.net>
21796
21797         * lib/getopt_.h: Remove trailing blanks.
21798
21799 2004-11-23  Jim Meyering  <jim@meyering.net>
21800
21801         * lib/__fpending.c: Add comment.
21802
21803 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
21804
21805         * modules/canonicalize (Depends-on): Add xreadlink.
21806         Problem reported by James Youngman.
21807
21808 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
21809
21810         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
21811         New macros.
21812         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
21813         optopt): Use them instead of invoking ## directly; otherwise, the
21814         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
21815
21816 2004-11-19  Bruno Haible  <bruno@clisp.org>
21817
21818         * lib/strtok_r.c: Move comments from here...
21819         * lib/strtok_r.h: ... to here.
21820
21821 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
21822
21823         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
21824         implementations that mishandle size_t overflow.
21825
21826 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
21827
21828         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
21829         might fail.  Problem reported by Yoann Vandoorselaere.
21830         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
21831         implementations that mishandle size_t overflow.
21832
21833 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21834
21835         * modules/canon-host (Depends-on): Add strdup.
21836
21837 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21838
21839         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
21840
21841 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21842
21843         * lib/canon-host.c: Include "strdup.h".
21844         (canon_host): Use getaddrinfo if available, so that IPv6 works.
21845         Use strdup instead of malloc/strcpy to duplicate strings.
21846
21847         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
21848         (human_space_before_unit): New constant.
21849         * lib/human.c (human_readable): Support it.
21850
21851         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
21852         (xgetcwd): Set errno correctly when failing.
21853         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
21854         the failure is actually due to a PATH_MAX problem.
21855
21856         Further getopt changes to make it more likely that glibc will
21857         buy the changes back.
21858         * lib/getopt.c (POSIXLY_CORRECT): New constant.
21859         (getopt): Use it, so to preserve glibc semantic
21860         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
21861         when compiling for libc.
21862         * lib/getopt_.h (__getopt_argv_const): Bring it back.
21863         (getopt_long, getopt_long_only): Use it.
21864
21865         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
21866         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
21867         (getopt): Argv is now char * const *, as per standard.
21868         (_getopt_internal_r, _getopt_internal): Argv is now char **,
21869         not char *__getopt_argv_const *.
21870         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
21871         _getopt_long_only_r): Likewise.
21872         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
21873         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
21874         _getopt_long_r, _getopt_long_only_r): Likewise.
21875         * lib/getopt_.h (__getopt_argv_const): Remove.
21876         (getopt): Argv is now char * const *, as per standard.
21877
21878         * lib/getdate.y (tORDINAL): New token.
21879         (day, relunit): Allow it for relative times.
21880         (relative_time_table): Use tORDINAL for ordinals.
21881
21882 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
21883
21884         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
21885         Document that "second" isn't allowed as an ordinal number.
21886
21887 2004-11-16  Jim Meyering  <jim@meyering.net>
21888
21889         * modules/closeout (Depends-on): Add fpending.
21890
21891 2004-11-15  Jim Meyering  <jim@meyering.net>
21892
21893         * lib/closeout.c: Include "__fpending.h" once again.
21894         Include <stdbool.h>.
21895         (close_stdout): Don't fail just because stdout was closed initially,
21896         since some programs don't write to stdout in the normal course of
21897         operation (other than --version and --help), and we don't want this
21898         function to make e.g. `touch file >&-' fail.
21899         But do fail if it was closed and someone has tried to write to it.
21900         E.g., `printf foo >&-' must fail.
21901
21902 2004-11-13  Jim Meyering  <jim@meyering.net>
21903
21904         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
21905
21906 2004-11-12  Simon Josefsson  <jas@extundo.com>
21907
21908         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
21909         small doc fix is still pending.
21910
21911 2004-11-11  Simon Josefsson  <jas@extundo.com>
21912
21913         * modules/strtok_r: New file.
21914
21915         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21916         strtok_r.
21917
21918 2004-11-11  Simon Josefsson  <jas@extundo.com>
21919
21920         * m4/strtok_r.m4: New file.
21921
21922         * m4/getopt.m4: Replace opterr.
21923
21924 2004-11-11  Simon Josefsson  <jas@extundo.com>
21925
21926         * lib/strtok_r.h, strtok_r.c: New file.
21927
21928 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
21929
21930         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
21931         of replacing opterr, getopt, etc.  This should handle the
21932         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
21933
21934 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
21935
21936         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
21937         we can stop lying to compilers about the constness of argv when we
21938         are compiled outside glibc.
21939         (getopt, getopt_long, getopt_long_only): Use it.
21940         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
21941         _getopt_internal, getopt): Likewise.
21942         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
21943         _getopt_long_only_r): Likewise.
21944         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
21945         _getopt_long_r, _getopt_long_only_r): Likewise.
21946
21947         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
21948         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
21949         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
21950         the other external symbols.
21951         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
21952         declaration, since the above renaming now works around collisions.
21953
21954 2004-11-11  Jim Meyering  <jim@meyering.net>
21955
21956         * lib/linebreak.c: Remove trailing blanks.
21957         * lib/alloca_.h: Likewise.
21958         * lib/acosl.c: Likewise.
21959         * lib/euidaccess.c: Likewise.
21960         * lib/allocsa.h: Likewise.
21961
21962 2004-11-10  Simon Josefsson  <jas@extundo.com>
21963
21964         * m4/getaddrinfo.m4: New file.
21965
21966 2004-11-10  Simon Josefsson  <jas@extundo.com>
21967
21968         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
21969
21970 2004-11-10  Simon Josefsson  <jas@extundo.com>
21971
21972         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21973         getaddrinfo.
21974
21975         * modules/getaddrinfo: New file.
21976
21977 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
21978
21979         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
21980
21981 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
21982
21983         * lib/mktime.c (SHR): New macro, which is a portable
21984         substitute for >> that should work even on Crays.
21985         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
21986         Problem reported by Mark D. Baushke in
21987         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
21988         * lib/getdate.y (SHR): Likewise.
21989         (tm_diff): Use it.
21990         * lib/strftime.c (SHR): Likewise.
21991         (tm_diff): Use it.
21992         * lib/quotearg.c (struct quoting_options): Use unsigned int for
21993         quote_these_too, so that right shifts are well defined.  All uses
21994         changed.
21995
21996 2004-11-10  Jim Meyering  <jim@meyering.net>
21997
21998         Ensure that no close failure goes unreported.
21999         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
22000         return early when it seems there's nothing to flush.
22001         Don't include __fpending.h.
22002
22003 2004-11-10  Jim Meyering  <jim@meyering.net>
22004
22005         * modules/closeout (Depends-on): Remove fpending.
22006
22007 2004-11-10  Jim Meyering  <jim@meyering.net>
22008
22009         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
22010
22011 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
22012
22013         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
22014         gl_FUNC_STRFTIME.
22015         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
22016         and AC_REQUIRE when possible, to avoid duplicate checks.
22017         Check for <wchar.h>.
22018
22019 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
22020
22021         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
22022
22023 2004-11-09  Bruno Haible  <bruno@clisp.org>
22024
22025         * m4/sockpfaf.m4: New file.
22026
22027 2004-11-05  Bruno Haible  <bruno@clisp.org>
22028
22029         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
22030         Reported by Mark D. Baushke <mdb@cvshome.org>.
22031
22032 2004-11-04  Bruno Haible  <bruno@clisp.org>
22033
22034         2004-09-11  Bruno Haible  <bruno@clisp.org>
22035                 * allocsa.valgrind: New file.
22036         2004-02-06  Bruno Haible  <bruno@clisp.org>
22037                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
22038                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
22039                 Reported by Christopher Seip <chris.seip@hp.com>.
22040
22041 2004-11-04  Bruno Haible  <bruno@clisp.org>
22042
22043         * modules/allocsa (Files): Add lib/allocsa.valgrind.
22044         (Makefile.am): Distribute it.
22045
22046 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
22047
22048         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
22049         with errno == ERANGE if the buffer is too small.
22050         Problem reported by Mark D. Baushke.
22051
22052 2004-11-03  Albert Chin  <china@thewrittenword.com>
22053             Paul Eggert  <eggert@cs.ucla.edu>
22054
22055         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
22056         equivalent, substitute $ac_type for equivalent type rather than
22057         blindly using uint32_t *always* which won't work if uint32_t is not
22058         available.  Define _UINT32_T to work around typedef of uint32_t if
22059         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
22060         2.5.1.
22061
22062 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
22063
22064         * m4/jm-macros.m4: Sync from coreutils.
22065         (gl_MACROS): Check for mbrlen, for pathchk.
22066         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
22067
22068 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
22069
22070         * lib/xreadlink.c (MAXSIZE): New macro.
22071         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
22072         size does not exceed MAXSIZE.  Avoid cast.
22073         As suggested by Mark D. Baushke in
22074         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
22075         if readlink fails with buffer size just under MAXSIZE, try again
22076         with MAXSIZE.
22077
22078 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
22079
22080         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
22081
22082 2004-11-02  Derek R. Price  <derek@ximbiot.com>
22083         and  Paul Eggert  <eggert@cs.ucla.edu>
22084
22085         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
22086         (get_date): Overparenthesize to avoid GCC warning.
22087
22088 2004-11-02  Bruno Haible  <bruno@clisp.org>
22089
22090         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
22091         returns void.
22092
22093 2004-11-02  Bruno Haible  <bruno@clisp.org>
22094
22095         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
22096         function returns void.
22097
22098 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
22099
22100         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
22101         fflush_unlocked, flockfile, funlockfile, funlockfile,
22102         fputs_unlocked, putc_unlocked.
22103
22104 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
22105
22106         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
22107         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
22108         already declared.
22109
22110 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
22111
22112         * modules/getdate (Files): Add doc/getdate.texi.
22113         (Depends-on): Add setenv, xalloc.
22114
22115 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
22116
22117         * lib/getdate.y: Add support for TZ="foo" within a date string.
22118         Fix some bugs near time_t boundaries.  Reject dates with
22119         out-of-range components, e.g., "Sept 31".
22120         Include <stdlib.h>, "setenv.h", "xalloc.h".
22121         (ISDIGIT_LOCALE): Remove; unused.
22122         Note that the TZ and time functions used here are not reentrant.
22123         (mktime_ok, get_tz): New functions.
22124         (TZBUFSIZE): New constant.
22125         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
22126         This requires that we sometimes generate our own TZ="XXX..." setting.
22127
22128 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
22129
22130         * doc/getdate.texi: New file, from coreutils with modifications for
22131         the new TZ parsing.
22132
22133 2004-10-27  Derek R. Price  <derek@ximbiot.com>
22134
22135         * lib/mktime.c (not_equal_tm): Remove redundant check.
22136
22137 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
22138
22139         * modules/regex (lib_SOURCES): Add regex.c.
22140         Reported by James Youngman in
22141         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
22142
22143 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
22144
22145         * lib/getdate.y: Use Bison 1.875 features, and some minor
22146         code cleanups.  This change does not affect semantics.
22147         Don't include <stdlib.h>; no longer needed.
22148         Don't include unlocked-io.h; only the "#if TEST" code uses
22149         stdio, and performance isn't crucial there.
22150         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
22151         Bison 1.875 features as described below.
22152         All uses of "PC." replaced by "pc->".
22153         (YYSTYPE): Add a forward declaration.
22154         (yylex, yyerror): Use full prototypes in forward decls.
22155         Use "%pure-parser" rather than obsolescent "%pure_parser".
22156         Use %parse-param and %lex-param instead of obsolescent
22157         YYPARSE_PARAM and YYLEX_PARAM.
22158         (meridian_table, month_and_day_table, time_units_table,
22159         relative_time_table, time_zone_table, military_table,
22160         lookup_zone, lookup_word, get_date):
22161         Use NULL instead of 0 where appropriate.
22162         (to_hour): Avoid abort (), to avoid a dependency on
22163         stdlib.h.
22164         (yyerror, yylex): Now accepts parser_control * arg.
22165         (main) [TEST]: Use '\0' rather than 0 for char.
22166
22167 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
22168
22169         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
22170
22171 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
22172
22173         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
22174         It's now the caller's responsibility to handle the case where
22175         !HAVE_GETPAGESIZE && !defined getpagesize.
22176
22177         * lib/mktime.c (leapyear): Arg is long int, not int.
22178
22179 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
22180
22181         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
22182
22183 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
22184
22185         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
22186         missing.  Problem reported by James Youngman.
22187
22188 2004-10-16  Simon Josefsson  <jas@extundo.com>
22189
22190         * gnulib-tool: Fix comments.  Fix parse problem.
22191         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
22192
22193 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
22194
22195         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
22196         implementation of getopt_long.  Problem reported by Alexander Taler in:
22197         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
22198
22199 2004-10-15  Bruno Haible  <bruno@clisp.org>
22200
22201         * gnulib-tool: Untabify. Initialize supplied_libname.
22202         (func_usage): More homogenous output.
22203         (func_modules_transitive_closure, func_modules_to_filelist,
22204         func_emit_lib_Makefile_am): New functions.
22205         (func_import): New function, extracted from big case statement. Use
22206         func_get_license, func_modules_transitive_closure,
22207         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
22208         opt_lgpl. Don't use test -a, as it's not portable.
22209         (func_create_testdir): Use func_modules_transitive_closure,
22210         func_modules_to_filelist, func_emit_lib_Makefile_am.
22211
22212 2004-10-15  Bruno Haible  <bruno@clisp.org>
22213
22214         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
22215
22216 2004-10-15  Bruno Haible  <bruno@clisp.org>
22217
22218         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
22219         the portions belonging to each module.
22220         Suggested by Derek Robert Price <derek@ximbiot.com>.
22221
22222 2004-10-12  Simon Josefsson  <jas@extundo.com>
22223
22224         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
22225         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
22226         to real functions.
22227
22228 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22229
22230         * modules/vsnprintf: New file.
22231
22232 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22233
22234         * m4/vsnprintf.m4: New file.
22235
22236 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22237
22238         * lib/vsnprintf.h: New file.
22239         * lib/vsnprintf.c: New file.
22240
22241 2004-10-11  Bruno Haible  <bruno@clisp.org>
22242
22243         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
22244         vsnprintf.
22245
22246 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
22247
22248         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
22249
22250 2004-10-07  Bruno Haible  <bruno@clisp.org>
22251
22252         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
22253         fits into the provided buffer.
22254
22255 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
22256
22257         * lib/diacrit.c, diacrit.h: Add GPL notice.
22258
22259         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
22260         notice.
22261         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
22262         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
22263         This avoids a potential constant-folding bug.
22264
22265 2004-10-05  Bruno Haible  <bruno@clisp.org>
22266
22267         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
22268         for the declaration of strsep.
22269
22270 2004-10-05  Bruno Haible  <bruno@clisp.org>
22271
22272         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
22273
22274 2004-10-04  Simon Josefsson  <jas@extundo.com>
22275
22276         * modules/memmem: New file.
22277         * tests/test-memmem.c: New file.
22278         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
22279
22280 2004-10-04  Simon Josefsson  <jas@extundo.com>
22281
22282         * m4/memmem.m4: New file.
22283
22284 2004-10-04  Simon Josefsson  <jas@extundo.com>
22285
22286         * lib/memmem.h: New file.
22287         * lib/memmem.c: New file, taken from glibc.
22288
22289 2004-10-04  Simon Josefsson  <jas@extundo.com>
22290
22291         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
22292         '#ifdef USE_UNLOCKED_IO'.
22293
22294 2004-10-04  Simon Josefsson  <jas@extundo.com>
22295
22296         * config/srclist.txt: Add memmem from glibc.
22297
22298 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
22299
22300         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
22301
22302         * modules/argmatch, modules/argp, modules/closeout, modules/error,
22303         modules/exclude, modules/getdate, modules/getline,
22304         modules/getndelim2, modules/getpass, modules/getpass-gnu,
22305         modules/getusershell, modules/linebuffer, modules/md5,
22306         modules/mountlist, modules/posixtm, modules/readtokens,
22307         modules/readutmp, modules/regex, modules/sha1,
22308         modules/version-etc, modules/yesno:
22309         Remove dependency on unlocked-io.
22310
22311 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
22312
22313         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
22314
22315         * m4/unlocked-io.m4: Add copyright notice.
22316         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
22317
22318 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
22319
22320         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
22321         * lib/xmalloc.c (xmemdup): Likewise.
22322         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
22323         XFREE): Remove these long-obsolescent macros.
22324         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
22325         * lib/xstrdup.c: Remove.
22326
22327         * lib/regex.c (re_comp): Cast gettext return value to char *,
22328         Problem reported by Martin Neitzel via Mark D. Baushke.
22329
22330 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
22331
22332         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
22333         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
22334         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
22335         regex.c, sha1.c, version-etc.c, yesno.c:
22336         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
22337         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
22338         the includer's responsibility.
22339
22340         Sync from coreutils.
22341
22342         * lib/modechange.c (mode_compile): Don't decrement a pointer that
22343         points to the start of a string, as the C Standard says the
22344         resulting behavior is undefined.
22345
22346         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
22347         simple -> simple_backups, numbered_existing ->
22348         numbered_existing_backups, numbered -> numbered_backups
22349         to avoid shadowing problems.  All uses changed.
22350         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
22351         * lib/backupfile.c (check_extension, numbered_backup):
22352         Rename locals to avoid shadowing 'basename'.
22353         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
22354         once.
22355
22356         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
22357         * lib/.cvsignore: Add getopt.h.
22358
22359 2004-10-04  Bruno Haible  <bruno@clisp.org>
22360
22361         * modules/README: New file.
22362         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
22363         not a module.
22364
22365 2004-10-02  Jim Meyering  <jim@meyering.net>
22366
22367         * lib/dirfd.h, getpagesize.h: Add copyright notice.
22368
22369 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22370
22371         * modules/strsep: New file.
22372
22373 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22374
22375         * m4/strsep.m4: New file.
22376
22377 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
22378
22379         * lib/strsep.h: New file.
22380         * lib/strsep.c: New file.
22381
22382 2004-10-01  Simon Josefsson  <jas@extundo.com>
22383
22384         * lib/snprintf.c (snprintf): Handle size==0.
22385
22386 2004-10-01  Simon Josefsson  <jas@extundo.com>
22387             Bruno Haible  <bruno@clisp.org>
22388
22389         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
22390         (snprintf): Declare 'args'.
22391
22392 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
22393
22394         * lib/snprintf.c: Remove comments as to why each header is needed.
22395
22396 2004-10-01  Bruno Haible  <bruno@clisp.org>
22397
22398         * MODULES.html.sh: Add strsep.
22399
22400 2004-09-30  Simon Josefsson  <jas@extundo.com>
22401
22402         * modules/snprintf: New file.
22403
22404 2004-09-30  Simon Josefsson  <jas@extundo.com>
22405
22406         * m4/snprintf.m4: New file.
22407
22408 2004-09-30  Simon Josefsson  <jas@extundo.com>
22409
22410         * lib/snprintf.h, lib/snprintf.c: New files.
22411
22412 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
22413
22414         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
22415         (hol_entry_help): Never translate an empty string.
22416         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
22417         * lib/argp.h (OPTION_NO_TRANS): New option.
22418
22419 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
22420
22421         * modules/argp (Maintainer): Replace Simon Josefsson
22422         by Sergey Poznyakoff.
22423
22424 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
22425
22426         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
22427         changes merged back into glibc.
22428
22429 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
22430
22431         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
22432
22433 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
22434
22435         * lib/xvasprintf.c: Include xalloc.h.
22436         (xvasprintf): Use xalloc_die, not xmalloc_die.
22437
22438 2004-09-29  Bruno Haible  <bruno@clisp.org>
22439
22440         * modules/alloca-opt: New file, derived from modules/alloca.
22441         * modules/allocsa: Depend on alloca-opt instead of alloca.
22442         * modules/setenv: Likewise.
22443         * modules/vasnprintf: Likewise.
22444         * MODULES.html.sh: Add alloca-opt.
22445
22446 2004-09-28  Simon Josefsson  <jas@extundo.com>
22447
22448         * gnulib-tool: New parameter --lgpl, to asseert that modules are
22449         LGPL, and to replace license template from GPL to LGPL.
22450
22451 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
22452
22453         * modules/dummy: Change license to LGPL.
22454
22455 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
22456
22457         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
22458
22459 2004-09-24  Simon Josefsson  <jas@extundo.com>
22460
22461         * modules/minmax (License): Change from GPL to LGPL.
22462
22463 2004-09-23  Simon Josefsson  <jas@extundo.com>
22464
22465         * gnulib-tool (--import): Typo.
22466
22467 2004-09-23  Simon Josefsson  <jas@extundo.com>
22468
22469         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
22470
22471 2004-09-22  Bruno Haible  <bruno@clisp.org>
22472
22473         * modules/*: Add 'License' field.
22474         * gnulib-tool: Accept --extract-license option.
22475         (func_get_license): New function.
22476
22477 2004-09-21  Bruno Haible  <bruno@clisp.org>
22478
22479         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
22480         Reported by Simon Josefsson.
22481
22482 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
22483
22484         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
22485         gl_AC_TYPE_LONG_LONG.
22486
22487 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
22488
22489         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
22490
22491 2004-09-18  Simon Josefsson  <jas@extundo.com>
22492         and  Paul Eggert  <eggert@cs.ucla.edu>
22493
22494         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
22495         calls with autoreconf.  Define GL_LIB.
22496
22497 2004-09-14  Karl Berry  <karl@gnu.org>
22498
22499         * config/srclist.txt: unsync setenv.c, sigh.
22500
22501 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
22502
22503         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
22504         Problem reported by Bruno Haible in:
22505         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
22506
22507 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
22508
22509         * config/srclist.txt: Comment out argp-pvh.c.
22510
22511 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
22512
22513         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
22514         in case some system header has #define'd it.  Problem reported by
22515         Soeren D. Schulze in
22516         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
22517
22518 2004-09-09  Karl Berry  <karl@gnu.org>
22519
22520         * regex.[ch]: delete from the root.  These were supposed to be
22521                 synced with emacs cvs, but this has not happened for about
22522                 a year, and anyway nothing else uses emacs regex.[ch].
22523                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
22524                 lib/regex[.ch] is untouched.
22525
22526 2004-09-09  Bruno Haible  <bruno@clisp.org>
22527
22528         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
22529
22530 2004-09-09  Bruno Haible  <bruno@clisp.org>
22531
22532         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
22533         modifications.
22534         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
22535
22536 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
22537
22538         * modules/xvasprintf: New file.
22539         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
22540
22541 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
22542
22543         * lib/xvasprintf.h: New file.
22544         * lib/xvasprintf.c: New file.
22545         * lib/xasprintf.c: New file.
22546
22547 2004-09-08  Bruno Haible  <bruno@clisp.org>
22548
22549         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
22550
22551 2004-09-08  Bruno Haible  <bruno@clisp.org>
22552
22553         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
22554         length is > INT_MAX.
22555         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
22556         more.
22557
22558 2004-09-08  Bruno Haible  <bruno@clisp.org>
22559
22560         * lib/stdint_.h: New file, taken from GNU clisp.
22561
22562 2004-09-08  Bruno Haible  <bruno@clisp.org>
22563             Oskar Liljeblad  <oskar@osk.mine.nu>
22564
22565         * modules/stdint: New file.
22566         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
22567
22568 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
22569
22570         Import from coreutils.
22571         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
22572         strings on unbounded length.  alloca's performance benefits aren't
22573         that important here.
22574         (V_STRDUP): Remove.
22575         (parse_with_separator): New function, with most of the internals
22576         of the old parse_user_spec.  Allow user to omit both user and group,
22577         for compatibility with FreeBSD.
22578         Clone only the user name, not the entire spec.
22579         Do not set *uid, *gid unless entirely successful.
22580         Avoid memory leak in some failing cases.
22581         Fix regression for USER.GROUP reported by Dmitry V. Levin in
22582         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
22583         (parse_user_spec): Rewrite to use parse_with_separator.
22584
22585 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
22586
22587         * modules/userspec: Don't depend on alloca.
22588
22589 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
22590
22591         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
22592
22593 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
22594
22595         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
22596         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
22597         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
22598
22599 2004-08-16  Simon Josefsson  <jas@extundo.com>
22600
22601         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
22602         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
22603         Add --dry-run for --import.
22604         Let user provided command line parameters override configure.ac
22605         settings.
22606
22607 2004-08-12  Simon Josefsson  <jas@extundo.com>
22608
22609         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
22610         as discussed with Paul Eggert in threads rooted at
22611         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
22612         and
22613         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
22614         Before, the test was empty, and relied on ELIDE_CODE in source
22615         code.)
22616         (gl_PREREQ_GETOPT): New macro.
22617         (gl_GETOPT): Use them.
22618
22619 2004-08-12  Simon Josefsson  <jas@extundo.com>
22620
22621         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
22622         * lib/getopt_.h: Renamed from getopt.h.
22623
22624 2004-08-12  Simon Josefsson  <jas@extundo.com>
22625
22626         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
22627         Change default library name from libfoo to libgnu.
22628         Now, if you have a configure.ac that says:
22629                 gl_SOURCE_BASE(gl)
22630                 gl_M4_BASE(gl/m4)
22631                 gl_MODULES(error getopt etcetera)
22632                 gl_INIT
22633         you can import all you need by running:
22634                 ../gnulib/gnulib-tool --import
22635
22636         * modules/getopt (Files): Rename getopt.h to getopt_.h.
22637         (Makefile.am): Rewrite, use logic from argz.
22638         (Include): Use <getopt.h> instead of "getopt.h".
22639
22640 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22641
22642         * modules/argp (Files): Add m4/unlocked-io.m4.
22643         (Depends-on): Add extensions.
22644
22645 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22646
22647         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
22648         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
22649         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
22650         Check for program_invocation_name, program_invocation_short_name,
22651         flockfile, funlockfile, features.h, _getopt_long_only_r.
22652
22653 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22654
22655         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
22656         its complicated substitute.
22657         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
22658         and program_invocation_name.
22659         (__argp_basename) [!_LIBC]: Remove; the only use was
22660         replaced by its body.
22661         (__argp_short_program_name): Change condition from
22662         !defined __argp_short_program_name to
22663         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
22664         to match argp-namefrob.h.
22665         (__argp_failure): Don't assume strerror_r returns char *.
22666         * lib/argp-parse.c (N_): Define unconditionally.
22667         (argp_default_options): Fill out initializers with 0 to avoid
22668         gcc warnings.
22669
22670 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
22671
22672         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
22673         getopt1.c.
22674
22675 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
22676
22677         Merge from coreutils.
22678
22679         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
22680
22681         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
22682         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
22683
22684 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
22685
22686         Merge from coreutils.
22687
22688         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
22689         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
22690         for Reliant Unix 5.43.
22691
22692         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
22693         (union fooround): Use uintmax_t, not long int.
22694         The rest is a merge from libc:
22695         [defined _LIBC]: Include <shlib-compat.h>.
22696         (_obstack) [defined _LIBC]: Remove after 2.3.4.
22697
22698         * lib/settime.c (settime): Recode to avoid warning with
22699         Sun Forte C 6U2.
22700
22701         * lib/strverscmp.c: Convert to UTF-8.
22702
22703 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
22704
22705         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
22706         m4/uintmax_t.m4.
22707
22708 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
22709
22710         * modules/xalloc-die: New file.
22711         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
22712
22713         * modules/md5 (Files): Add m4/uint32_t.m4.
22714         * modules/sha1: Renamed from modules/sha.
22715         (Files):
22716         Rename lib/sha.h to lib/sha1.h.
22717         Rename lib/sha.c to lib/sha1.c.
22718         Rename m4/sha.m4 to m4/sha1.m4.
22719         (lib_SOURCES): Likewise.
22720         (configure.ac): Rename gl_SHA to gl_SHA1.
22721         (Include): sha.h -> sha1.h.
22722
22723 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
22724
22725         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
22726         * m4/sha1.m4: Renamed from sha.m4.
22727         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
22728
22729 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
22730
22731         * lib/obstack.h (obstack_empty_p):
22732         Don't assume that chunk->contents is suitably aligned.
22733         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
22734         Likewise. Problem reported by Benno in
22735         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
22736
22737         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
22738         readable.  This could be improved further but it'd take some work.
22739
22740 2004-08-08  Simon Josefsson  <jas@extundo.com>
22741
22742         * modules/xgethostname (Depends-on): Remove exit and error (not
22743         used).
22744
22745         * modules/getpass-gnu: Add getpass.h.
22746         (Depends-on): Add stdbool.
22747         * modules/getpass: Add getpass.h.
22748
22749 2004-08-08  Simon Josefsson  <jas@extundo.com>
22750
22751         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
22752         Check getpass declaration.
22753
22754 2004-08-08  Simon Josefsson  <jas@extundo.com>
22755
22756         * lib/xgethostname.c: Don't include error.h (not used).
22757
22758         * lib/getpass.h: Add.
22759         * lib/getpass.c: Include getpass.h first.
22760
22761 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
22762
22763         * lib/xalloc-die.c: New file.
22764         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
22765         All uses removed.
22766         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
22767         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
22768         xalloc-die.c.
22769         (_, N_, xalloc_die): Move to xalloc-die.c.
22770         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
22771         so that we needn't mess with xalloc_msg_memory_exhausted.
22772
22773         * lib/sha1.h: Renamed from sha.h.
22774         (SHA1_H): Renamed from _SHA_H.
22775         (sha1_ctx): Renamed from sha_ctx.
22776         (sha1_init_ctx): Renamed from sha_init_ctx.
22777         (sha1_process_block): Renamed from sha_process_block.
22778         (sha1_process_bytes): Renamed from sha_process_bytes.
22779         (sha1_finish_ctx): Renamed from sha_finish_ctx.
22780         (sha1_read_ctx): Renamed from sha_read_ctx.
22781         (sha1_stream): Renamed from sha_stream.
22782         (sha1_buffer): Renamed from sha_buffer.
22783         * lib/sha1.c: Likewise; renamed from sha.c.
22784         Do not include <sys/types.h>.
22785         Include <stddef.h> rather than <stdlib.h>.
22786
22787 2004-08-08  Bruno Haible  <bruno@clisp.org>
22788
22789         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
22790         FILESYSTEM_PREFIX_LEN.
22791         * lib/progreloc.c: Likewise.
22792         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
22793
22794 2004-08-06  Simon Josefsson  <jas@extundo.com>
22795
22796         * modules/progname (Depends-on): Don't depend on stdbool.
22797
22798 2004-08-06  Simon Josefsson  <jas@extundo.com>
22799
22800         * modules/getsubopt: New file.
22801         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
22802         getsubopt.
22803
22804 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22805
22806         More merge from coreutils.
22807
22808         * m4/utimens.m4, m4/utimecmp.m4: New files.
22809         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
22810         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
22811         prereq.m4, sha.m4: Import changes from coreutils.
22812
22813 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22814
22815         More merge from coreutils.
22816         * modules/raise, modules/readtokens0, modules/utimens:
22817         * modules/utimecmp, module/xnanosleep: New files.
22818         * modules/strftime: Add lib/strftime.h.
22819         Change include from <time.h> to "strftime.h".
22820         * modules/yesno: Add lib/yesno.h.
22821         * modules/backupfile: Remove lib/addext.c.
22822         * modules/euidaccess: Add stat-macros.h.
22823         * modules/canonicalize, modules/euidaccess,
22824         modules/filemode, modules/lchown, modules/makepath,
22825         modules/rmdir, modules/stat: Likewise.
22826
22827 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
22828
22829         Merge from tar.
22830         * lib/argp-help.c (make_hol, hol_append): Don't assume that
22831         SIZE_MAX is a valid preprocessor constant.
22832         (__argp_basename): Change from "#ifndef _LIBC"
22833         to "#ifndef __argp_short_program_name", so that
22834         we don't compile these functions for tar.
22835
22836         More merges from coreutils.
22837         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
22838         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
22839         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
22840         * lib/addext.c: Remove; no longer needed.
22841         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
22842         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
22843         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
22844         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
22845         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
22846         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
22847         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
22848         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
22849         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
22850         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
22851         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
22852         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
22853         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
22854         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
22855         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
22856         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
22857         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
22858         Import changes from coreutils.
22859
22860 2004-08-05  Simon Josefsson  <jas@extundo.com>
22861
22862         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
22863
22864 2004-08-05  Simon Josefsson  <jas@extundo.com>
22865
22866         * m4/getsubopt.m4: New file.
22867
22868 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22869
22870         Merge from coreutils.
22871
22872         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
22873         * m4/getcwd-path-max.m4: New files.
22874
22875         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
22876         FILESYSTEM_PREFIX_LEN ->
22877         FILE_SYSTEM_PREFIX_LEN.
22878         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
22879         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
22880         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
22881         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
22882
22883         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
22884         prerequisite modules now handle the DOS stuff.
22885         Don't check for unistd.h.
22886
22887 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22888
22889         Merge from coreutils.
22890
22891         * lib/.gdb-history: Remove; this doesn't belong here.
22892
22893         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
22894         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
22895         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
22896         * lib/getcwd.c: New files.
22897
22898         * lib/dirname.h: Include <stdbool.h>.
22899         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
22900         for consistency with POSIX terminology.  All uses changed.
22901         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
22902         (strip_trailing_slashes): Use bool for booleans.
22903         * lib/stripslash.c (strip_trailing_slashes): Likewise.
22904
22905         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
22906         sometimes returns a positive errno value even when it succeeds.
22907         (print_errno_message) [!LIBC]: Fall back on strerror if
22908         __strerror_r fails.
22909
22910         * lib/path-concat.c (mempcpy): Don't define if a system header defines
22911         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
22912         (longest_relative_suffix): New function.
22913         (path_concat): Use it.  Assume first argument is not NULL.
22914         Port to DOS.  Omit redundant separators.
22915         Report an error instead of returning NULL.
22916         Use mempcpy instead of memcpy.
22917         (xpath_concat): Remove: not declared or used.
22918
22919         * lib/same.h: Include <stdbool.h>
22920         (same_name): Return bool, not int.
22921         * lib/same.c (same_name): Likewise.
22922         (errno): Don't declare; we assume C89 or better now.
22923
22924         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
22925         if not already defined.
22926
22927         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
22928         * lib/dup-safer.c (errno): Likewise.
22929
22930 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
22931
22932         Merge from coreutils.
22933         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
22934         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
22935         * modules/path-concat: Don't depend on strdup.
22936
22937 2004-08-03  Simon Josefsson  <jas@extundo.com>
22938
22939         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
22940         * lib/progname.h: Don't include stdbool.h.
22941
22942 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22943
22944         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
22945         * MODULES.html.sh (func_all_modules): Remove fatal.
22946
22947 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22948
22949         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
22950
22951 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
22952
22953         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
22954         working.
22955
22956 2004-08-02  Simon Josefsson  <jas@extundo.com>
22957
22958         * lib/getsubopt.h: New file, with comments from Bruno Haible.
22959         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
22960         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
22961
22962 2004-08-01  Simon Josefsson  <jas@extundo.com>
22963
22964         * lib/xgetdomainname.c: Include stdlib.h, for free().
22965
22966 2004-07-19  Bruno Haible  <bruno@clisp.org>
22967
22968         * MODULES.html.sh (func_all_modules): Add dummy.
22969
22970 2004-07-16  Simon Josefsson  <jas@extundo.com>
22971
22972         * modules/dummy: New file.
22973
22974 2004-07-16  Simon Josefsson  <jas@extundo.com>
22975
22976         * lib/dummy.c: New file.
22977
22978 2004-07-16  Bruno Haible  <bruno@clisp.org>
22979
22980         * lib/backupfile.h: Add extern "C" for C++.
22981         * lib/closeout.h: Likewise.
22982         * lib/copy-file.h: Likewise.
22983         * lib/findprog.h: Likewise.
22984         * lib/full-write.h: Likewise.
22985         * lib/pathname.h: Likewise.
22986         * lib/progname.h: Likewise.
22987         * lib/stpcpy.h: Likewise.
22988         * lib/stpncpy.h: Likewise.
22989         * lib/strcase.h: Likewise.
22990         * lib/strstr.h: Likewise.
22991         * lib/xalloc.h: Likewise.
22992
22993         * lib/mbswidth.h: Add extern "C" for C++.
22994         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
22995
22996 2004-07-13  Robert Millan  <robertmh@gnu.org>
22997
22998         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
22999
23000 2004-07-09  Simon Josefsson  <jas@extundo.com>
23001
23002         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
23003         failed without this.)
23004
23005 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
23006
23007         * modules/chown (Files): Add lib/fchown-stub.c, since
23008         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
23009
23010 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
23011
23012         * lib/fchown-stub.c: New file.
23013
23014 2004-06-24  Jim Meyering  <jim@meyering.net>
23015
23016         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
23017
23018 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
23019
23020         * modules/argz: Omit "#include".
23021
23022         * MODULES.html.sh (func_all_modules): Add calloc, to match
23023         2004-06-01 addition of calloc module.
23024
23025 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
23026
23027         * m4/argz.m4: New file, which is autoupdated from libtool.
23028
23029 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
23030
23031         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
23032         libtool.
23033
23034 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
23035
23036         * config/srclist-update: Don't insist on "USA." before the
23037         close-comment, as libtool omits the period and puts the */ on a
23038         separate line.
23039         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
23040         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
23041
23042 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
23043
23044         * modules/argz: New file.
23045         * MODULES.html.sh (func_all_modules): Add argz.
23046
23047 2004-06-12  Jim Meyering  <jim@meyering.net>
23048         and  Paul Eggert  <eggert@cs.ucla.edu>
23049
23050         * modules/hash (Files): Add lib/xalloc.h.
23051         * modules/pipe (Depends-on): Add wait-process.
23052         * modules/stat (Depends-on): Add xalloc.
23053         * modules/userspec (Files): Add lib/userspec.h.
23054         * modules/xstrto
23055
23056         Upgrade from gettext-0.13.
23057         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
23058         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
23059         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
23060
23061 2004-06-10  Jim Meyering  <jim@meyering.net>
23062
23063         * lib/calloc.c: New file.
23064
23065 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
23066
23067         * lib/getdate.y (yylex): Allow space between sign and number.
23068         Problem reported by Dan Jacobson.
23069
23070 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
23071
23072         Merge from coreutils CVS.
23073
23074         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
23075         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
23076         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
23077         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
23078         xstrtol.m4: Fix copyright date and/or serial number.
23079
23080         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
23081         See if we need an fchown replacement.
23082         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
23083         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
23084         and use the replacement function if we detect either defect.
23085
23086         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
23087         gl_UTIMECMP.
23088
23089 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
23090         and  Jim Meyering  <jim@meyering.net>
23091
23092         Merge from coreutils CVS.
23093
23094         * lib/stat-macros.h: New file, with contents from file-type.h
23095         and coreutils' system.h.
23096         * lib/file-type.c: Include "stat-macros.h".
23097         * lib/file-type.h (file_type): Move all macro definitions to new file,
23098         stat-macros.h.
23099
23100         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
23101         Wrap old code with this conditional.
23102         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
23103         function that does not dereference symlinks.
23104         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
23105
23106         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
23107         dependency problems.
23108         (xreadlink): Accept new arg SIZE, for efficiency.
23109         All decls and uses changed.
23110         * lib/xreadlink.h: Include <stddef.h>, for size_t.
23111
23112         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
23113         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
23114
23115         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
23116         sysexits.h.
23117
23118 2004-06-01  Jim Meyering  <jim@meyering.net>
23119
23120         * m4/calloc.m4: New file.
23121
23122 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
23123
23124         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
23125         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
23126         Also, fix a typo in a diagnostic.
23127
23128 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
23129
23130         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
23131         or AC_FUNC_REALLOC.
23132
23133 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
23134
23135         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
23136         macros to be defined.
23137         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
23138         the allocator returns NULL because the requested size is zero.
23139
23140 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
23141
23142         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
23143         var.  Add comment explaining why libc still defines it.  This
23144         merges the following patch from glibc:
23145         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
23146
23147 2004-05-20  Andreas Schwab  <schwab@suse.de>
23148
23149         * m4/free.m4: Replace free if it not known to work, not the other
23150         way round.
23151
23152 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
23153
23154         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
23155         present in glibc since revision 1.1 of this file.
23156         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
23157         obstack_alignment_mask, obstack_alloc, obstack_base,
23158         obstack_blank, obstack_blank_fast, obstack_chunk_size,
23159         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
23160         obstack_grow0, obstack_init, obstack_int_grow,
23161         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
23162         obstack_next_free, obstack_object_size, obstack_ptr_grow,
23163         obstack_ptr_grow_fast, obstack_room): Remove declarations of
23164         nonexistent functions.
23165
23166 2004-05-18  Karl Berry  <karl@gnu.org>
23167
23168         * config/srclist.txt: break link for vasnprintf.c.
23169
23170 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
23171
23172         Port obstack to the AS/400, where pointers are 16 bytes wide and
23173         you cannot cast an integer to a valid pointer.  This patch is
23174         currently waiting to be integrated into glibc; see
23175         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
23176
23177         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
23178         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
23179         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
23180         (struct obstack): temp member is now a union of a pointer and
23181         an integer, instead of an integer.  All integer uses changed.
23182         This does not affect the physical layout of struct obstack,
23183         except on hosts (like the AS/400) where the size or alignment of
23184         void * is greater than that of ptrdiff_t.
23185         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
23186         __STDC__)]: Store temporary in pointer member of union, not
23187         integer member.
23188         * lib/obstack.c: Include <stddef.h>, for offsetof.
23189         (struct fooalign): Remove; it doesn't need a name.
23190         (union fooround): Change double to long double, and add void *.
23191         (DEFAULT_ALIGNMENT): Use offsetof to compute.
23192         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
23193         not a macro.  Hence the values are always int; so remove all
23194         casts-to-int in uses.
23195
23196 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
23197
23198         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
23199         we can get this patch merged into glibc.
23200
23201 2004-05-17  Derek R. Price  <derek@ximbiot.com>
23202             Paul Eggert  <eggert@cs.ucla.edu>
23203
23204         * m4/argp: Depend on alloca.
23205
23206 2004-05-17  Derek R. Price  <derek@ximbiot.com>
23207             Paul Eggert  <eggert@cs.ucla.edu>
23208
23209         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
23210         freecoding.
23211
23212 2004-05-17  Bruno Haible  <bruno@clisp.org>
23213
23214         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
23215         precision that consists of a '.' followed by an empty digit string.
23216         Patch by Tor Lillqvist <tml@iki.fi>.
23217
23218 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
23219
23220         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
23221         for backward compatibility with older code.  We need our own
23222         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
23223         it under some other name, and our alloca.h will define it.
23224
23225 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
23226             Derek Price  <derek@ximbiot.com>
23227
23228         * lib/alloca.c: Include <alloca.h>, to get our interface.
23229         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
23230         include <alloca.h> first.  Use C89 prototype for alloca; this
23231         requires including <stddef.h> for size_t.  Use extern "C" if C++.
23232         Use #elif for simplicity, since we can assume C89 now.
23233         Don't try to source the system alloca.h since it will not be found
23234         and to prevent recursively including its replacement.
23235         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
23236         * lib/regex.c: Likewise.
23237
23238 2004-05-16  Derek Price  <derek@ximbiot.com>
23239             Paul Eggert  <eggert@cs.ucla.edu>
23240
23241         getline cleanup.  This changes the getndelim2 API: both order of
23242         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
23243         no delimiter).
23244
23245         * lib/getline.c: Don't include stddef.h or stdio.h, since our
23246         interface does that.
23247         (getline): Always use getdelim, so that we don't have two
23248         copies of this code.
23249         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
23250         if available.
23251         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
23252         (GETNDELIM2_MAXIMUM): New macro.
23253         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
23254         instead of the old practice of delim2==0.  All callers changed.
23255         Return -1 on overflow, instead of returning junk.
23256         Do not set *linesize unless allocation succeeds.
23257         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
23258         that we include sys/types.h.
23259         * lib/getnline.h: Likewise.
23260         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
23261         (getndelim2): Reorder arguments.
23262         * lib/getnline.c (getnline, getndelim):
23263         Don't discard the NMAX argument.
23264         (getnline): Invoke getndelim, to avoid code duplication.
23265         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
23266         of (size_t) -1 by callers of the getnline family.
23267
23268 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
23269
23270         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
23271         Check for gettimeofday.
23272         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
23273         Check for settimeofday, stime.
23274
23275 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
23276
23277         * lib/nanosleep.c (suspended): Change its type from int to
23278         sig_atomic_t volatile.
23279         (first_call): Make it private to rpl_nanosleep, and have it
23280         be zero initially as that's a bit faster.
23281         (my_usleep): Round up fractional times instead of truncating them,
23282         as this is the usual meaning for 'sleep'.
23283
23284         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
23285         doesn't work.
23286         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
23287         (ENOSYS): Define if not defined.
23288         (settime): Fall back on stime if it exists and settimeofday fails.
23289         But don't bother with fallbacks if a method fails with errno == EPERM.
23290
23291 2004-05-11  Jim Meyering  <jim@meyering.net>
23292
23293         Prior to this change, the save_cwd caller required read access to the
23294         current directory on most systems (ones with the fchdir function).
23295
23296         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
23297         fails, try write-only, and finally, resort to using xgetcwd.
23298
23299 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
23300
23301         * lib/obstack.c, obstack.h: Import changes from libc.
23302
23303 2004-04-28  Bruno Haible  <bruno@clisp.org>
23304
23305         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
23306         also implicitly appends .exe to executables.
23307         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
23308         accepts Windows pathnames.
23309         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
23310         Treat Cygwin like Windows, since it now accepts Windows pathnames.
23311         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
23312         Treat Cygwin like Windows, since it now accepts Windows pathnames.
23313         Reported by Derek Robert Price <derek@ximbiot.com>.
23314
23315 2004-04-21  Karl Berry  <karl@gnu.org>
23316
23317         * config/srclist.txt (localcharset.c): break sync.
23318
23319 2004-04-20  Paul Eggert  <eggert@twinsun.com>
23320
23321         * m4/host-os.m4: Add a copyright notice.
23322
23323 2004-04-20  Jim Meyering  <jim@meyering.net>
23324
23325         Change UTILS_ to gl_ in AC_DEFINE'd names.
23326         Change utils_- and jm_-prefixed variables, too.
23327         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
23328         UTILS_FUNC_MKDIR_TRAILING_SLASH.
23329         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
23330
23331         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
23332         Don't emit trailing blanks.
23333         Also rename jm_-prefixed variables to have gl_ prefix.
23334
23335         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
23336         Also rename jm_-prefixed variables to have gl_ prefix.
23337
23338         * m4/jm-macros.m4: Reflect the renamings.
23339         * m4/prereq.m4: Likewise.
23340
23341 2004-04-20  Jim Meyering  <jim@meyering.net>
23342
23343         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
23344         memory.
23345
23346 2004-04-20  Jim Meyering  <jim@meyering.net>
23347             Bruno Haible  <bruno@clisp.org>
23348
23349         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
23350         memory when realloc fails.
23351
23352 2004-04-19  Jim Meyering  <jim@meyering.net>
23353
23354         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
23355         now that readutmp.c may call `free (0)'.
23356
23357 2004-04-19  Bruno Haible  <bruno@clisp.org>
23358
23359         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
23360         * m4/inttypes_h.m4: Likewise.
23361         * m4/stdint_h.m4: Likewise.
23362         * m4/intmax_t.m4: Likewise.
23363         * m4/uintmax_t.m4: Likewise.
23364
23365 2004-04-18  Jim Meyering  <jim@meyering.net>
23366
23367         * m4/prereq.m4: Don't forbid jm_ prefix.
23368
23369         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
23370         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
23371         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
23372         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
23373         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
23374         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
23375         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
23376         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
23377         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
23378         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
23379         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
23380         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
23381         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
23382         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
23383         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
23384         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
23385         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
23386         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
23387         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
23388
23389 2004-04-18  Jim Meyering  <jim@meyering.net>
23390
23391         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
23392         failure, don't leak memory and do call END_UTMP_ENT.
23393
23394 2004-04-16  Jim Meyering  <jim@meyering.net>
23395
23396         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
23397         coreutils' stat program.
23398         (gl_PREREQ): Don't require jm_PREREQ_STAT.
23399
23400 2004-04-11  Paul Eggert  <eggert@twinsun.com>
23401
23402         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
23403         C89.
23404         (CHAR_BIT): Remove, since we assume C89.
23405         Include <stdint.h> if available, as per current Autoconf CVS advice.
23406
23407 2004-03-31  Jim Meyering  <jim@meyering.net>
23408
23409         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
23410         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
23411         * m4/xalloc.m4: Likewise.
23412
23413 2004-03-30  Paul Eggert  <eggert@twinsun.com>
23414
23415         Merge from coreutils.
23416
23417         * m4/inttostr.m4: New file.
23418         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
23419         Require AM_STDBOOL_H and gl_TIMESPEC instead.
23420         Require gl_CLOCK_TIME.
23421         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
23422
23423 2004-03-30  Paul Eggert  <eggert@twinsun.com>
23424
23425         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
23426         not bool, to be more consistent with Unix conventions.
23427         Suggested by Bruno Haible.
23428
23429         Merge from coreutils.
23430
23431         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
23432         * lib/umaxtostr.c: New files.
23433
23434         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
23435         the usual <time.h> dance.
23436         (get_date): Change signature to support fractional time stamps.
23437         All callers changed.
23438         * lib/getdate.y: Include "getdate.h" first, as we can now
23439         assume C89 and don't need to worry about 'const'.
23440         Similarly, include "unlocked-io.h" near start, not in middle.
23441         Include <limits.h>.
23442         (textint.value): Use long int rather than int.
23443         (textint.digits): Use size_t rather than int.
23444         (BILLION, LOG10_BILLION): New constants.
23445         (parser_control): New member rel_ns.  Members day_ordinal,
23446         time_zone, month, day, hour, minutes, rel_year, rel_month,
23447         rel_day, rel_hour, rel_minutes, rel_seconds
23448         are now long int, not int.  Member seconds is now struct timespec,
23449         not int.  New member timespec_seen.  Members dates_seen, days_seen,
23450         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
23451         not int.
23452         (%union.intval): Now long int, not int.
23453         New member timespec.
23454         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
23455         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
23456         (spec): Now is a timespec or an item list.
23457         (timespec, items): New nonterminals.
23458         (time, rel, relunit, number, get_date):
23459         Add support for fractional seconds.
23460         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
23461         (gmtime, localtime, mktime): Remove decls; not needed with C89.
23462         (to_hour): First arg is now long int, not int.
23463         (to_year): Returns long int, not int.
23464         Don't treat year -70 like 70.
23465         (tm_diff): Returns long int, not int.
23466         (lookup_word): Use bool instead of int when appropriate.
23467         (yylex): Use size_t for count, not int.
23468         Detect overflow when parsing large integer constants.
23469         Add support for fractions.
23470         (get_date): Make pointers 'const' if possible.
23471         Use more-portable code to detect integer overflow.
23472         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
23473         Don't use ctime; it's not reliable if the year has >4 digits.
23474
23475         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
23476         This is for compatibility with BSD.
23477
23478         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
23479         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
23480         From coreutils' system.h.
23481
23482         * lib/userspec.c: Don't include "posixver.h".
23483         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
23484         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
23485         compatible extension.  Simplify code by removing a boolean int
23486         that was always nonzero if a string was nonnull.
23487
23488 2004-03-30  Jim Meyering  <jim@meyering.net>
23489
23490         Merge from coreutils.
23491
23492         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
23493         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
23494         on some systems one must include <grp.h> before it.
23495         Reported by Christian Krackowizer.
23496
23497 2004-03-30  Jim Meyering  <jim@meyering.net>
23498
23499         Merge from coreutils.
23500
23501         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
23502
23503         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
23504         an empty input stream.
23505
23506         * lib/readtokens.c: Include <stdbool.h>.
23507         (readtoken): Use `size_t' rather than int/long.
23508         All callers adjusted.
23509         Use `bool' rather than `int' where appropriate.
23510         Use memset rather than an explicit loop.
23511         Use x2nrealloc rather than xrealloc.
23512         Allow the use of `\0' as a delimiter.
23513         (readtokens): Likewise.
23514         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
23515
23516 2004-03-30  Jim Meyering  <jim@meyering.net>
23517
23518         * m4/realloc.m4: Remove file, since now it does no more than
23519         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
23520         the `configure.ac' section of module/realloc.
23521         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
23522
23523 2004-03-30  Bruno Haible  <bruno@clisp.org>
23524
23525         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
23526         nonnull.
23527
23528 2004-03-29  Paul Eggert  <eggert@twinsun.com>
23529
23530         Merge changes to getloadavg.c from coreutils and Emacs.
23531
23532         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
23533         Define to an expression, not to the empty string.
23534         Include cloexec.h and xalloc.h.
23535         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
23536         Use set_cloexec_flag rather than rolling our own.
23537         * lib/cloexec.c, lib/cloexec.h: New files.
23538
23539 2004-03-29  Paul Eggert  <eggert@twinsun.com>
23540
23541         * m4/cloexec.m4: New file.
23542
23543 2004-03-18  Paul Eggert  <eggert@twinsun.com>
23544
23545         * lib/getopt.h: Sync with libc CVS.
23546
23547 2004-03-18  Paul Eggert  <eggert@twinsun.com>
23548             Bruno Haible  <bruno@clisp.org>
23549
23550         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
23551         mbswidth.
23552
23553 2004-03-18  Paul Eggert  <eggert@twinsun.com>
23554             Bruno Haible  <bruno@clisp.org>
23555
23556         * lib/mbswidth.h: Include <wchar.h> only if
23557         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
23558         <wchar.h>.
23559         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
23560
23561 2004-03-09  Paul Eggert  <eggert@twinsun.com>
23562
23563         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
23564         Sync with libc CVS.
23565         * lib/getopt_int.h: New file, also synced from libc.
23566
23567 2004-03-09  Paul Eggert  <eggert@twinsun.com>
23568
23569         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
23570         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
23571         Bring back getopt.c, getopt.h, getopt1.c.
23572
23573 2004-03-07  Paul Eggert  <eggert@twinsun.com>
23574
23575         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
23576         All uses changed.  Check for sa_sigaction member; this fixes
23577         a bug first reported by Jason Andrade in
23578         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
23579
23580 2004-03-07  Paul Eggert  <eggert@twinsun.com>
23581
23582         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
23583         '#if' expressions.  Unlike the code it replaces, it does not
23584         depend on (defined _SC_PAGESIZE).  However, it does depend on
23585         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
23586         first reported by Jason Andrade in
23587         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
23588
23589 2004-02-25  Simon Josefsson  <jas@extundo.com>
23590
23591         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
23592
23593 2004-02-25  Simon Josefsson  <jas@extundo.com>
23594
23595         * lib/strdup.h: New file.
23596         * lib/strdup.c: Include it.
23597         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
23598         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
23599
23600 2004-02-23  Karl Berry  <karl@gnu.org>
23601
23602         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
23603         (from fencepost.gnu.org:/gd/gnuorg).
23604
23605 2004-02-23  Karl Berry  <karl@gnu.org>
23606
23607         * config/srclistvars.sh (GNUORG) [karl]: redefine.
23608         * config/srclist.txt: add maintain/standards documents.
23609
23610 2004-02-18  Bruno Haible  <bruno@clisp.org>
23611
23612         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
23613         Reported by Derek Robert Price <derek@ximbiot.com>.
23614
23615 2004-02-16  Karl Berry  <karl@gnu.org>
23616
23617         * config/mkinstalldirs, install-sh: update from automake.
23618
23619 2004-02-06  Karl Berry  <karl@gnu.org>
23620
23621         * m4/po.m4: update from gettext 0.14.1.
23622
23623 2004-02-06  Karl Berry  <karl@gnu.org>
23624
23625         * lib/config.charset: update from gettext 0.14.1.
23626
23627 2004-02-05  Paul Eggert  <eggert@twinsun.com>
23628
23629         Add comments and code, prompted by suggestions from Bruno Haible
23630         for sh-quote.
23631         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
23632         describing the enum quoting_style values.
23633         * lib/quotearg.c (quotearg_alloc): New function.
23634         (quotearg_buffer_restyled): Treat lone { and } as special.
23635         Treat = as special.  Work around bug with older shells
23636         that "see" a '\' that is really the 2nd byte of a multibyte char.
23637         Quote empty string with shell_quoting_style.
23638
23639 2004-02-03  Bruno Haible  <bruno@clisp.org>
23640
23641         * m4/pipe.m4: New file, from GNU gettext.
23642
23643 2004-02-03  Bruno Haible  <bruno@clisp.org>
23644
23645         * lib/pipe.h: New file, from GNU gettext.
23646         * lib/pipe.c: New file, from GNU gettext.
23647
23648 2004-01-27  Bruno Haible  <bruno@clisp.org>
23649
23650         * m4/execute.m4: New file, from GNU gettext.
23651
23652 2004-01-27  Bruno Haible  <bruno@clisp.org>
23653
23654         * lib/execute.h: New file, from GNU gettext.
23655         * lib/execute.c: New file, from GNU gettext.
23656         * lib/w32spawn.h: New file, from GNU gettext.
23657
23658 2004-01-24  Paul Eggert  <eggert@twinsun.com>
23659
23660         Merge from diffutils.
23661
23662         * lib/file-type.c (file_type): Add typed memory objects.
23663         * lib/file-type.h (S_TYPEISTMO): New macro.
23664
23665         * lib/c-stack.h (c_stack_action): Remove argv argument.
23666         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
23667         (die): Don't calculate message unless segv_action returns.
23668         (get_stack_location, min_address_from_argv, max_address_from_argv,
23669         volatile stack_base, volatile_stack_size): Remove.
23670         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
23671         that every segmentation violation is a stack overflow.  (Ouch!)
23672         See Debian bug 136249 (still outstanding) for more info about why
23673         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
23674
23675 2004-01-24  Paul Eggert  <eggert@twinsun.com>
23676
23677         Exit-status fix from coreutils.
23678
23679         Use exit_failure consistently in place of EXIT_FAILURE,
23680         so that program exit statuses are consistent on failure.
23681
23682         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
23683         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
23684         * lib/argmatch.h: Comment fix to match the above.
23685         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
23686         Now a macro referring to exit_failure, instead of a separate
23687         variable.  Include "exitfail.h" to get it.
23688         * lib/xstrtol.h: Include "exitfail.h".
23689         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
23690
23691         * lib/long-options.c (parse_long_options): Use prototype
23692         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
23693         for clarity.
23694
23695 2004-01-21  Jim Meyering  <jim@meyering.net>
23696
23697         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
23698         so as not to conflict with a different-sized __mktime_internal
23699         function in GNU libc.
23700         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
23701         Problem building statically-linked `ls' reported by Michael Brunnbauer.
23702
23703 2004-01-20  Karl Berry  <karl@gnu.org>
23704
23705         * config/config.guess: update from config.
23706
23707         * config/srclistvars.sh: GNUWWWLICENSES for karl.
23708
23709 2004-01-20  Bruno Haible  <bruno@clisp.org>
23710
23711         Safer stack allocation.
23712         * lib/setenv.c: Include allocsa.h.
23713         (alloca): Remove fallback definition.
23714         (freea): Remove macro.
23715         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
23716         instead of freea.
23717
23718 2004-01-20  Bruno Haible  <bruno@clisp.org>
23719
23720         * m4/eealloc.m4: New file, from GNU gettext.
23721
23722 2004-01-20  Bruno Haible  <bruno@clisp.org>
23723
23724         * m4/allocsa.m4: New file, from GNU gettext.
23725
23726 2004-01-20  Bruno Haible  <bruno@clisp.org>
23727
23728         * lib/xallocsa.h: New file, from GNU gettext.
23729         * lib/xallocsa.c: New file, from GNU gettext.
23730
23731 2004-01-20  Bruno Haible  <bruno@clisp.org>
23732
23733         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
23734
23735 2004-01-20  Bruno Haible  <bruno@clisp.org>
23736
23737         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
23738         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
23739         specially.
23740
23741 2004-01-20  Bruno Haible  <bruno@clisp.org>
23742
23743         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
23744         patch.
23745
23746 2004-01-20  Bruno Haible  <bruno@clisp.org>
23747
23748         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
23749
23750 2004-01-20  Bruno Haible  <bruno@clisp.org>
23751
23752         * lib/eealloc.h: New file.
23753
23754 2004-01-20  Bruno Haible  <bruno@clisp.org>
23755
23756         * lib/binary-io.h: Avoid warnings on Cygwin.
23757
23758 2004-01-20  Bruno Haible  <bruno@clisp.org>
23759
23760         * lib/allocsa.h: New file, from GNU gettext.
23761         * lib/allocsa.c: New file, from GNU gettext.
23762
23763 2004-01-18  Karl Berry  <karl@gnu.org>
23764
23765         * doc/gpl.texi, doc/lgpl.texi: new files.
23766
23767 2004-01-18  Karl Berry  <karl@gnu.org>
23768
23769         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
23770         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
23771
23772 2004-01-15  Paul Eggert  <eggert@twinsun.com>
23773
23774         Merge from coreutils.
23775
23776         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
23777         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
23778         (gl_DEFAULT_POSIX2_VERSION): Move
23779         the documentation from 'configure' into 'config.hin',
23780         so that 'configure --help' isn't burdened by it and
23781         we don't have to worry about its formatting there.
23782         Reword the documentation so that it's more succinct
23783         and can be run together into a single paragraph.
23784         * m4/same.m4 (gl_SAME): Check for pathconf.
23785
23786 2004-01-15  Paul Eggert  <eggert@twinsun.com>
23787
23788         Merge from coreutils.
23789
23790         * lib/posixver.c: Include posixver.h.
23791
23792         * lib/same.c: Include <stdbool.h>, <limits.h>.
23793         (_POSIX_NAME_MAX): Define if not defined.
23794         (MIN): New macro.
23795         (same_name): If file names are silently truncated, report
23796         that the file names are the same if they are the same after
23797         the silent truncation.
23798
23799         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
23800         conversion function.
23801         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
23802         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
23803         longer needed.
23804
23805 2004-01-15  Jim Meyering  <jim@meyering.net>
23806
23807         Merge from coreutils.
23808
23809         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
23810         if no library is required.
23811         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
23812         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
23813         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
23814         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
23815         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
23816         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
23817         value, $ac_cv_search_crypt, if it's "none required".
23818         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
23819         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
23820         not gl_FUNC_GETLOADAVG.
23821         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
23822         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
23823
23824 2004-01-15  Jim Meyering  <jim@meyering.net>
23825
23826         Merge from coreutils.
23827
23828         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
23829         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
23830         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
23831
23832         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
23833         optional configure-time default.
23834
23835         * lib/version-etc.c (version_etc_copyright): Update copyright date.
23836
23837         * lib/xreadlink.c (xreadlink): Correct outdated comment.
23838
23839 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
23840
23841         Merge from coreutils.
23842
23843         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
23844         value, $ac_cv_search_nanosleep, if it's "none required".
23845
23846 2004-01-14  Paul Eggert  <eggert@twinsun.com>
23847
23848         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
23849         with like-named macro in fnmatch.c.
23850         (EXT): Use an internal constant instead.
23851
23852         Merge fnmatch patches from glibc.
23853         * lib/fnmatch.c (mbsinit): Remove define.
23854         Add libc_hidden_ver (__fnmatch, fnmatch).
23855         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
23856         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
23857
23858 2004-01-14  Karl Berry  <karl@gnu.org>
23859
23860         * config/install-sh: update from automake.
23861
23862 2004-01-13  Karl Berry  <karl@gnu.org>
23863
23864         * config/install-sh: update from automake.
23865
23866 2004-01-09  Karl Berry  <karl@gnu.org>
23867
23868         * config/install-sh: update from automake.
23869
23870 2004-01-05  Karl Berry  <karl@gnu.org>
23871
23872         * config/config.{sub,guess}: update from config.
23873
23874 2003-12-31  Karl Berry  <karl@gnu.org>
23875
23876         * config/depcomp: update from automake.
23877
23878 2003-12-14  Karl Berry  <karl@gnu.org>
23879
23880         * lib/config.charset: update from gettext-runtime.
23881
23882 2003-12-03  Paul Eggert  <eggert@twinsun.com>
23883
23884         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
23885         Bug reported by Alfred M. Szmidt.
23886
23887 2003-12-03  Bruno Haible  <bruno@clisp.org>
23888
23889         * m4/gettext.m4: Upgrade from gettext-0.13.
23890         * m4/po.m4: Upgrade from gettext-0.13.
23891         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
23892         * m4/intmax.m4: New file, from gettext-0.13.
23893         * m4/printf-posix.m4: New file, from gettext-0.13.
23894
23895 2003-11-29  Karl Berry  <karl@gnu.org>
23896
23897         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
23898
23899 2003-11-25  Paul Eggert  <eggert@twinsun.com>
23900             Bruno Haible  <bruno@clisp.org>
23901
23902         * lib/printf-parse.h: Don't include sys/types.h.
23903         (ARG_NONE): New macro.
23904         (char_directive): Change type of *arg_index fields to size_t.
23905         * lib/printf-parse.c: Don't include sys/types.h.
23906         (SSIZE_MAX): Remove macro.
23907         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
23908         Remove unnecessary overflow check.
23909         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
23910         fields.
23911
23912 2003-11-25  Bruno Haible  <bruno@clisp.org>
23913
23914         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
23915
23916 2003-11-25  Bruno Haible  <bruno@clisp.org>
23917
23918         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
23919         gt_TYPE_SSIZE_T.
23920
23921 2003-11-24  Paul Eggert  <eggert@twinsun.com>
23922
23923         * modules/alloca: Remove dependency on xalloc.
23924
23925 2003-11-24  Paul Eggert  <eggert@twinsun.com>
23926
23927         * lib/alloca.c: Remove dependency on xalloc module.
23928         (xalloc_die): Remove.
23929         (memory_full) [!defined emacs]: New macro.
23930         [!defined emacs]: Don't include xalloc.h.
23931         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
23932         address arithmetic overflows.  Change datatypes a bit to avoid
23933         unnecessary casts.
23934
23935 2003-11-22  Jim Meyering  <jim@meyering.net>
23936
23937         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
23938         s/size/size_t/.
23939
23940 2003-11-21  Karl Berry  <karl@gnu.org>
23941
23942         * config/config.{sub,guess}: update from config.
23943
23944 2003-11-18  Karl Berry  <karl@gnu.org>
23945
23946         * config/config.{sub,guess}: update from config.
23947
23948         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
23949
23950 2003-11-17  Paul Eggert  <eggert@twinsun.com>
23951
23952         * README: Mention that S+T cannot overflow if S is the size of
23953         an existing object and T is sufficiently small.
23954
23955 2003-11-17  Jim Meyering  <jim@meyering.net>
23956
23957         On systems without utime and without a utimes function capable of
23958         dealing with a NULL struct utimbuf* argument, this utime replacement
23959         could -- in unusual circumstances -- leak a file descriptor.
23960         * lib/utime.c: Include <unistd.h> and <errno.h>.
23961         (utime_null): Be sure to close `fd' and to preserve errno.
23962         Reported by Geoff Collyer via Arnold Robbins.
23963
23964 2003-11-17  Bruno Haible  <bruno@clisp.org>
23965
23966         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
23967         (Depends-on): Add xsize.
23968
23969 2003-11-17  Bruno Haible  <bruno@clisp.org>
23970
23971         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
23972
23973 2003-11-17  Bruno Haible  <bruno@clisp.org>
23974
23975         * lib/vasnprintf.c (alloca): Remove fallback definition.
23976         (freea): Remove definition.
23977         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
23978         Reported by Paul Eggert.
23979
23980 2003-11-16  Paul Eggert  <eggert@twinsun.com>
23981             Bruno Haible  <bruno@clisp.org>
23982
23983         Protect against address arithmetic overflow.
23984         * lib/printf-args.h: Include stddef.h.
23985         (arguments): Change type of field 'count' to size_t.
23986         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
23987         'unsigned int' where appropriate.
23988         * lib/printf-parse.h: Include sys/types.h.
23989         (char_directive): Change type of *arg_index fields to ssize_t.
23990         (char_directives): Change type of fields 'count', max_*_length to
23991         size_t.
23992         * lib/printf-parse.c: Include sys/types.h and xsize.h.
23993         (SSIZE_MAX): Define fallback value.
23994         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
23995         instead of 'int' where appropriate. Check a_allocated, d_allocated
23996         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
23997         * lib/vasnprintf.c: Include xsize.h.
23998         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
23999         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
24000         overflow. Avoid wraparound when converting a width or precision from
24001         decimal to binary.
24002
24003 2003-11-16  Bruno Haible  <bruno@clisp.org>
24004
24005         Update from GNU gettext.
24006         * lib/printf-parse.c: Generalize to it can be compiled for wide
24007         strings.
24008         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
24009         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
24010         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
24011         SNPRINTF): New macros.
24012         Don't include <alloca.h> if the file is used inside libintl.
24013         (local_wcslen): New function, for Solaris 2.5.1.
24014         (VASNPRINTF): Use it instead of wcslen.
24015
24016 2003-11-16  Bruno Haible  <bruno@clisp.org>
24017
24018         * lib/xsize.h (xmax): New function.
24019         (xsum, xsum3, xsum4): Declare as "pure" functions.
24020
24021 2003-11-12  Paul Eggert  <eggert@twinsun.com>
24022
24023         * modules/xalloc (Files): Undo latest change, since xalloc.h
24024         no longer needs SIZE_MAX or PTRDIFF_MAX.
24025
24026 2003-11-12  Paul Eggert  <eggert@twinsun.com>
24027
24028         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
24029         gl_PTRDIFF_MAX.
24030
24031 2003-11-12  Paul Eggert  <eggert@twinsun.com>
24032
24033         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
24034         "return", to pacify some unknown compiler.  Problem reported
24035         by Joerg Schilling.
24036
24037 2003-11-12  Paul Eggert  <eggert@twinsun.com>
24038
24039         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
24040         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
24041         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
24042         heuristic is just as accurate as far as we know, and it removes a
24043         dependency on size_max.m4 and ptrdiff_max.m4.
24044
24045 2003-11-11  Bruno Haible  <bruno@clisp.org>
24046
24047         * modules/xsize (Files): Add m4/size_max.m4.
24048         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
24049
24050 2003-11-11  Bruno Haible  <bruno@clisp.org>
24051
24052         * m4/size_max.m4: New file.
24053         * m4/ptrdiff_max.m4: New file.
24054         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
24055         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
24056         (gl_XALLOC): Invoke it.
24057
24058 2003-11-11  Bruno Haible  <bruno@clisp.org>
24059
24060         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
24061         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
24062         defined.
24063
24064 2003-11-10  Paul Eggert  <eggert@twinsun.com>
24065
24066         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
24067         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
24068         rejected some allocations of exactly SIZE_MAX - 2 bytes.
24069         From Bruno Haible.
24070         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
24071         not (size_t) -1, since it's defined here.
24072
24073 2003-11-09  Karl Berry  <karl@gnu.org>
24074
24075         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
24076
24077 2003-11-06  Paul Eggert  <eggert@twinsun.com>
24078
24079         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
24080         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
24081         Reject sizes of exactly SIZE_MAX bytes.
24082         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
24083         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
24084
24085 2003-11-05  Bruno Haible  <bruno@clisp.org>
24086
24087         * lib/xsize.h: Include limits.h, to avoid a possible collision with
24088         SIZE_MAX defined in <limits.h> on Solaris.
24089
24090 2003-11-04  Jim Meyering  <jim@meyering.net>
24091
24092         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
24093         variable names, rather than @VAR@.
24094         * modules/poll: Likewise.
24095
24096 2003-11-04  Bruno Haible  <bruno@clisp.org>
24097
24098         * modules/xsize: New file.
24099         * modules/linebreak: Depend on xsize.
24100         * MODULES.html.sh (func_all_modules): Add xsize.
24101
24102 2003-11-04  Bruno Haible  <bruno@clisp.org>
24103
24104         * m4/xsize.m4: New file.
24105
24106 2003-11-04  Bruno Haible  <bruno@clisp.org>
24107
24108         * lib/xsize.h: New file.
24109         * lib/linebreak.c: Include xsize.h.
24110         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
24111         argument for overflow.
24112         Suggested by Paul Eggert.
24113
24114 2003-11-03  Karl Berry  <karl@gnu.org>
24115
24116         * config/config.{guess,sub}: update from config.
24117
24118 2003-11-03  Jim Meyering  <jim@meyering.net>
24119
24120         * modules/userspec (lib_SOURCES): Add userspec.h.
24121         (Include): Add "userspec.h".
24122         Improve description.
24123
24124 2003-11-03  Jim Meyering  <jim@meyering.net>
24125
24126         * lib/userspec.c: Include "userspec.h".
24127         * lib/userspec.h: New file.
24128
24129 2003-11-03  Bruno Haible  <bruno@clisp.org>
24130
24131         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
24132
24133 2003-11-03  Bruno Haible  <bruno@clisp.org>
24134
24135         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
24136         available, to avoid (extremely rare) race condition.
24137         Suggested by Paul Eggert.
24138
24139 2003-11-02  Karl Berry  <karl@gnu.org>
24140
24141         * config/srclist.txt (vasprintf.c): sync broken, sigh.
24142
24143 2003-10-31  Paul Eggert  <eggert@twinsun.com>
24144
24145         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
24146         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
24147         (read_filesystem_list): Set and use me_type_malloced.
24148         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
24149         whatever the type happens to be), for brevity and consistency.
24150         Check for size calculation overflow on Alphas running OSF/1.
24151
24152 2003-10-31  Jim Meyering  <jim@meyering.net>
24153
24154         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
24155
24156         * lib/linebuffer.c: Include <string.h> for declaration of memset.
24157
24158 2003-10-30  Paul Eggert  <eggert@twinsun.com>
24159             Bruno Haible  <bruno@clisp.org>
24160
24161         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
24162         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
24163
24164 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
24165
24166         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
24167         netbsd*-gnu*.  Suggested by Robert Millan.
24168
24169 2003-10-29  Paul Eggert  <eggert@twinsun.com>
24170
24171         * modules/group-member: Depend on stdbool.
24172
24173 2003-10-29  Paul Eggert  <eggert@twinsun.com>
24174
24175         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
24176
24177 2003-10-29  Paul Eggert  <eggert@twinsun.com>
24178
24179         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
24180         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
24181         after the 'gnu' in these cases.  This fixes some bugs in the
24182         previous change, and is based on suggestions by Robert Millan.
24183
24184 2003-10-29  Paul Eggert  <eggert@twinsun.com>
24185
24186         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
24187         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
24188         no longer needed.
24189         * lib/quotearg.c (quotearg_n_options): Use it.
24190         * lib/group-member.c: Include <stdbool.h>.
24191         (free_group_info): Arg is now const *; don't free arg.
24192         (get_group_info): Now returns bool and accepts struct group_info *,
24193         rather than returning a malloc'ed struct group_info *.
24194         All uses changed.  Check for overflow in internal size calculation.
24195
24196         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
24197         rather than xmalloc/xrealloc.
24198         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
24199         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
24200         conformance bug: the old code used a pointer after freeing the
24201         storage that it addressed.
24202         * lib/hash.c (hash_initialize): Simplify the code by using
24203         xalloc_oversized rather than doing it by hand.
24204         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
24205         the buffer preserved.  Use free and xmalloc instead.
24206         * lib/quotearg.c (quotearg_n_options): Likewise.
24207         Use a simpler test for size overflow.  Don't use xalloc_oversized
24208         because unsigned int might be wider than size_t (!); this suggests
24209         that we should switch from unsigned int to size_t for slot numbers.
24210
24211 2003-10-28  Paul Eggert  <eggert@twinsun.com>
24212
24213         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
24214         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
24215         NetBSD kernels.  Requested by Richard Stallman.
24216
24217 2003-10-27  Paul Eggert  <eggert@twinsun.com>
24218
24219         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
24220         to allocate the returned structure.  Do not allocate a subarray,
24221         as x2nrealloc will do that.
24222         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
24223         instead of xnrealloc.
24224         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
24225
24226 2003-10-27  Bruno Haible  <bruno@clisp.org>
24227
24228         * lib/stdbool_.h: Better support for BeOS.
24229
24230 2003-10-26  Paul Eggert  <eggert@twinsun.com>
24231
24232         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
24233         now uses inline.
24234
24235 2003-10-26  Paul Eggert  <eggert@twinsun.com>
24236
24237         * lib/xalloc.h (xalloc_oversized): New static inline function, for
24238         callers that want to do their own size-overflow checking.  Include
24239         <stdbool.h>, since xalloc_oversized returns bool.
24240         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
24241         to use xalloc_oversized.
24242
24243         Add two functions x2realloc, x2nrealloc, for programs that grow
24244         arrays dynamically by doubling their sizes.
24245         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
24246         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
24247         New functions.
24248
24249         Port to C99 semantics for 'inline' of external functions.
24250         Bug reported by Bruno Haible.
24251         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
24252         with the old contents of xnmalloc.
24253         (xnmalloc, xmalloc): Use it.
24254         (xnrealloc_inline): New static inline function,
24255         with the old contents of xnrealloc.
24256         (xnrealloc, xrealloc): Use it.
24257
24258         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
24259         that.
24260
24261 2003-10-26  Karl Berry  <karl@gnu.org>
24262
24263         * config/srclist.txt (COPYING.DOC): no longer available from
24264         /gd/gnuorg; don't know where the ultimate source is.
24265
24266 2003-10-25  Paul Eggert  <eggert@twinsun.com>
24267
24268         Fix several address-calculation bugs in the hash modules,
24269         plus some minor code cleanup.
24270
24271         * lib/hash.h: Include <stdbool.h>, for bool.
24272         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
24273         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
24274         hash_get_n_entries, hash_get_max_bucket_length,
24275         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
24276         hash_rehash): Use size_t rather than unsigned.
24277         * lib/hash.c (struct hash_table, hash_get_n_buckets,
24278         hash_get_n_buckets_used, hash_get_n_entries,
24279         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
24280         hash_get_entries, hash_do_for_each, hash_string, is_prime,
24281         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
24282         Likewise.
24283         (SIZE_MAX): Define if not defined.
24284         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
24285         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
24286         hash_print):
24287         Use const * when possible.
24288         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
24289         (check_tuning): Fix bug: if tuning parameters were very close to
24290         0 or 1, rounding errors could have caused subscript violations.
24291         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
24292         (hash_initialize): Add 'fail:' label
24293         to free table and return NULL, and use it to simplify code.
24294         Use calloc rather than clearing the storage ourself.
24295         (hash_initialize, hash_rehash): Check for arithmetic overflow in
24296         buffer size calculations.
24297         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
24298         Include <stddef.h>, for size_t.
24299         * lib/hash-pjw.c (hash_pjw): Likewise.
24300         Switch to method described by Bruno Haible.
24301         Include <limits.h>, for CHAR_BIT.
24302         (SIZE_BITS): New macro.
24303
24304 2003-10-23  Paul Eggert  <eggert@twinsun.com>
24305
24306         * m4/getline.m4 (AM_FUNC_GETLINE):
24307         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
24308         hosts.  Problem reported by Derek Robert Price in
24309         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
24310         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
24311         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
24312
24313 2003-10-21  Paul Eggert  <eggert@twinsun.com>
24314
24315         * lib/getndelim2.c (getndelim2): When size calculation overflows,
24316         ceiling the allocation at NMAX bytes rather than silently
24317         discarding input bytes before NMAX is reached.  This makes
24318         a difference only if NMAX exceeds SIZE_MAX / 2.
24319
24320         * lib/obstack.c: Merge from glibc.
24321         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
24322         Add libc_hidden_def (_obstack_newchunk).
24323         (_obstack_free) [! defined _LIBC]: Remove.
24324         [defined _LIBC]: Make a strong alias from obstack_free, rather than
24325         a clone of the function body.
24326         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
24327         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
24328
24329         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
24330         glibc.
24331         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
24332         arg to memcpy.
24333
24334         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
24335         (obstack_ptr_grow_fast, obstack_int_grow_fast):
24336         Don't use lvalue casts, as GCC plans to remove support for them
24337         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
24338         was also present in the non-GCC version, indicating that this
24339         code had always been buggy and had never been widely used.
24340         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
24341         Use the fast variant of each macro, rather than copying the
24342         definiens of the fast variant; that way, we'll be more likely to
24343         catch future bugs in the fast variants.
24344
24345 2003-10-20  Bruno Haible  <bruno@clisp.org>
24346
24347         * modules/wait-process: New file.
24348         * MODULES.html.sh (func_all_modules): Add wait-process.
24349
24350 2003-10-20  Bruno Haible  <bruno@clisp.org>
24351
24352         * m4/wait-process.m4: New file.
24353
24354 2003-10-20  Bruno Haible  <bruno@clisp.org>
24355
24356         * lib/wait-process.h: New file, from GNU gettext.
24357         * lib/wait-process.c: New file, from GNU gettext.
24358
24359 2003-10-19  Jim Meyering  <jim@meyering.net>
24360
24361         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
24362         HPUX 10.20.
24363
24364 2003-10-18  Karl Berry  <karl@gnu.org>
24365
24366         * config/config.guess: update from config.
24367
24368 2003-10-16  Paul Eggert  <eggert@twinsun.com>
24369
24370         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
24371         (getgroups): First arg is int, not size_t.
24372         Don't let 'free' mangle errno.
24373
24374 2003-10-16  Paul Eggert  <eggert@twinsun.com>
24375
24376         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
24377
24378 2003-10-16  Karl Berry  <karl@gnu.org>
24379
24380         * config/config.{guess,sub}: update from config.
24381
24382 2003-10-16  Jim Meyering  <jim@meyering.net>
24383
24384         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
24385         memcpy.
24386
24387 2003-10-15  Paul Eggert  <eggert@twinsun.com>
24388
24389         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
24390         (SIZE_MAX): Remove.
24391         (new_exclude, add_exclude_file): Initial size no longer needs to
24392         be a power of 2.
24393         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
24394         our own address arithmetic overflow checking.
24395
24396         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
24397         (fnmatch): Do not alloca more than 2000 wide characters;
24398         instead, use malloc for large buffers.
24399         Check for address arithmetic overflow, and return -1
24400         with errno set to ENOMEM in that case.
24401         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
24402         (NEW_PATTERN): Do not alloca more than 8000 bytes;
24403         instead, return -1.  Check for address arithmetic overflow.
24404
24405 2003-10-14  Paul Eggert  <eggert@twinsun.com>
24406
24407         Handle invalid suffixes and overflow independently, so that
24408         callers can treat them independently as needed.  Fix some bugs in
24409         suffix handling, e.g., "100k@" was not diagnosed as an invalid
24410         suffix for a human-readable blocksize.  The major caller-visible
24411         change is the addition of a new
24412         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
24413         that both overflow and suffix chars were found.
24414
24415         * lib/human.c (humblock): Don't check separately for invalid suffix
24416         char; that is xstrtoumax's job (now that its bug is fixed).
24417         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
24418         INTMAX_MAX]: New macros.
24419         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
24420         TYPE_MAXIMUM): New macros.
24421         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
24422         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
24423         if overflow occurs, as it's what __strtol does and it's more useful
24424         in practice.
24425         (__xstrtol): If __strtol reports some error other than ERANGE,
24426         reflect it to the caller as LONGINT_INVALID.  If it reports
24427         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
24428         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
24429         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
24430         value.
24431         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
24432         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
24433         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
24434         [defined UINTMAX_MAX]: New macros.
24435
24436 2003-10-14  Bruno Haible  <bruno@clisp.org>
24437
24438         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
24439
24440 2003-10-14  Bruno Haible  <bruno@clisp.org>
24441
24442         * m4/sig_atomic_t: New file, from GNU gettext.
24443         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
24444
24445 2003-10-14  Bruno Haible  <bruno@clisp.org>
24446
24447         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
24448         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
24449         Also use volatile where needed.
24450
24451 2003-10-12  Paul Eggert  <eggert@twinsun.com>
24452
24453         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
24454         Change maintainer from Bruno Haible to 'all'.
24455
24456 2003-10-12  Paul Eggert  <eggert@twinsun.com>
24457
24458         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
24459
24460 2003-10-12  Paul Eggert  <eggert@twinsun.com>
24461
24462         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
24463         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
24464         and define in terms of the other primitives.
24465         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
24466         (SIZE_MAX): Define if not already defined.
24467         (array_size_overflow): New function.
24468         (xalloc_die): Abort instead of exiting if 'error' returns.
24469         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
24470         (xmalloc, xrealloc): Use them.
24471         (xcalloc): Check for address arithmetic overflow.
24472         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
24473         a bit faster than strcpy.
24474
24475 2003-10-10  Simon Josefsson  <jas@extundo.com>
24476
24477         * modules/argp (Depends-on): Add restrict and strcase.
24478
24479 2003-10-10  Simon Josefsson  <jas@extundo.com>
24480
24481         * m4/argp.m4: Add AC_C_INLINE.
24482
24483 2003-10-08  Paul Eggert  <eggert@twinsun.com>
24484
24485         Merge getpass from libc, plus a few fixes.
24486
24487         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
24488         Include <stdbool.h>.
24489         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
24490         __fsetlocking to empty.
24491         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
24492         do include <bits/libc-lock.h>.
24493         Do not include <fcntl.h>; not needed.
24494         [_LIBC]: Include <wchar.h>.
24495         (NOTCANCEL_MODE): New macro.
24496         (flockfile, funlockfile) [_LIBC]: New macros.
24497         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
24498         [!_LIBC]: New macros.
24499         (call_fclose): New function.
24500         (getpass): Use it.  Save tty stream separately; this simplifies the
24501         code and makes it more reliable if stdin happens to equal stdout.
24502         Invoke __fsetlocking on tty.
24503         Handle thread cancellation if needed.
24504         Namespace cleanup (use __tcgetattr, __getline).
24505         Use bool for Booleans.
24506         [USE_IN_LIBIO]: Handle wide streams.
24507         [!_LIBC]: Unconditionally do the fseek, since we don't know what
24508         stream might go where.
24509
24510         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
24511         doesn't have to include <stdio.h> before us.
24512         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
24513         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
24514         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
24515         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
24516         if not declared, so that we can use getpass.c code from libc without
24517         rewriting it.
24518         (flockfile, ftrylockfile, funlockfile): New macros.
24519
24520 2003-10-08  Paul Eggert  <eggert@twinsun.com>
24521
24522         * modules/getpass: Depend on stdbool.
24523
24524 2003-10-08  Paul Eggert  <eggert@twinsun.com>
24525
24526         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
24527
24528 2003-10-07  Karl Berry  <karl@gnu.org>
24529
24530         * config/config.{guess,sub}: update from config.
24531
24532 2003-10-06  Jim Meyering  <jim@meyering.net>
24533             Bruno Haible  <bruno@clisp.org>
24534
24535         This lets translators provide better translations for the
24536         "Written by ..." part of --version output.
24537         * lib/version-etc.h: Include stdarg.h.
24538         (version_etc_copyright): Declare as readonly.
24539         (version_etc): Make this function variadic with a NULL-terminated list
24540         of author name strings.
24541         (version_etc_va): New declaration.
24542         * lib/version-etc.c: Include stdarg.h, stdlib.h.
24543         (version_etc_copyright): Declare as readonly.
24544         (version_etc_va): New function. Provide a different translatable string
24545         for each possible number of authors < 10. Abbreviate when there are 10
24546         authors or more.
24547         (version_etc): Make this function variadic. Call version_etc_va.
24548         Suggestion from Gary V. Vaughan.
24549
24550         * lib/long-options.h (parse_long_options): Change prototype: the
24551         authors string is moved to the end and becomes variadic.
24552         * lib/long-options.c: Include stdarg.h.
24553         (parse_long_options): Make this function variadic, too.
24554         Call version_etc_va, not version_etc.
24555
24556 2003-10-06  Bruno Haible  <bruno@clisp.org>
24557
24558         * modules/version-etc-2: Remove file.
24559         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
24560
24561 2003-10-06  Bruno Haible  <bruno@clisp.org>
24562
24563         * modules/fatal-signal: New file.
24564         * MODULES.html.sh (func_all_modules): Add fatal-signal.
24565
24566 2003-10-06  Bruno Haible  <bruno@clisp.org>
24567
24568         * m4/fatal-signal.m4: New file.
24569         * m4/signalblocking.m4: New file, from GNU gettext.
24570
24571 2003-10-06  Bruno Haible  <bruno@clisp.org>
24572
24573         * lib/version-etc-2.h: Remove file.
24574         * lib/version-etc-2.c: Remove file.
24575
24576 2003-10-06  Bruno Haible  <bruno@clisp.org>
24577
24578         * lib/fatal-signal.h: New file, from GNU gettext.
24579         * lib/fatal-signal.c: New file, from GNU gettext.
24580
24581 2003-10-05  Paul Eggert  <eggert@twinsun.com>
24582
24583         * README: Rework advice for preventing empty .o files.
24584         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
24585         not <sys/types.h>.
24586
24587 2003-10-04  Karl Berry  <karl@gnu.org>
24588
24589         * lib/argp*: update from libc.
24590
24591 2003-10-04  Karl Berry  <karl@gnu.org>
24592
24593         * config/config.{guess,sub}: update from config.
24594
24595 2003-10-02  Bruno Haible  <bruno@clisp.org>
24596
24597         * modules/lchown (Include): Add lchown.h.
24598         * modules/time_r (Include): Use "..." syntax.
24599         * modules/xgetdomainname (Include): Add xgetdomainname.h.
24600
24601 2003-10-01  Simon Josefsson  <jas@extundo.com>
24602
24603         * MODULES.html.sh (func_all_modules): Move gethostname from section
24604         'based on' to section 'lacking' POSIX:2001.
24605
24606 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
24607
24608         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
24609         to output mode on the same stream.
24610
24611 2003-09-29  Paul Eggert  <eggert@twinsun.com>
24612
24613         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
24614         Fix arg typo in previous patch.
24615
24616 2003-09-28  Jim Meyering  <jim@meyering.net>
24617
24618         * lib/error.c: Correct cpp indentation.
24619
24620 2003-09-27  Paul Eggert  <eggert@twinsun.com>
24621
24622         * modules/free: New file.
24623
24624 2003-09-27  Paul Eggert  <eggert@twinsun.com>
24625
24626         * m4/free.m4: New file.
24627
24628 2003-09-27  Paul Eggert  <eggert@twinsun.com>
24629
24630         * lib/minmax.h (MIN, MAX)
24631         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
24632         Omit the special code that used __typeof__, since we worry that
24633         it could be more trouble than it's worth.  See:
24634         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
24635         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
24636
24637         * lib/free.c: New file.
24638
24639 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
24640
24641         Trivial fixes to Makefile.am parts of module listings.
24642         * modules/strstr: Append strstr.h to lib_SOURCES.
24643         * modules/strcase: Likewise, for strcase.h.
24644
24645 2003-09-27  Karl Berry  <karl@gnu.org>
24646
24647         * config/mkinstalldirs: update from automake.
24648
24649 2003-09-26  Paul Eggert  <eggert@twinsun.com>
24650
24651         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
24652         (error_tail): Do not loop, reallocating temporary buffer, since
24653         the output cannot contain more wide characters than the input
24654         contains bytes, the size must be big enough already.  This avoids
24655         one potential size overflow calculation.  Check for size overflow
24656         when calculating temporary buffer size.  Free temporary buffer
24657         when done, if it was allocated with malloc; this plugs a memory
24658         leak.  Remove casts from void * to pointers, that are no longer
24659         needed now that we're assuming C89 or better.
24660
24661         Merge error changes from glibc.
24662
24663         * lib/error.c, error.h: Update copyright notice header to match glibc.
24664         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
24665         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
24666         Disable cancellation while printing error.
24667         * lib/error.h: Prepend __ to parameter names.
24668
24669 2003-09-26  Jim Meyering  <jim@meyering.net>
24670
24671         * lib/error.c (error_tail): Move some declarations
24672         into inner scope where the local variables are used.
24673
24674 2003-09-26  Bruno Haible  <bruno@clisp.org>
24675
24676         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
24677         stpncpy().
24678         Don't define stpncpy through config.h; it's now done through stpncpy.h.
24679
24680 2003-09-26  Bruno Haible  <bruno@clisp.org>
24681
24682         * lib/stpncpy.h (gnu_stpncpy): New declaration.
24683         (stpncpy): Define as alias for gnu_stpncpy.
24684         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
24685
24686 2003-09-25  Simon Josefsson  <jas@extundo.com>
24687
24688         * lib/xgetdomainname.h: New file.
24689         * lib/xgetdomainname.c: New file.
24690
24691 2003-09-25  Simon Josefsson  <jas@extundo.com>
24692             Bruno Haible  <bruno@clisp.org>
24693
24694         * modules/getdomainname: New file.
24695         * modules/xgetdomainname: New file.
24696         * MODULES.html.sh (func_all_modules): Add getdomainname,
24697         xgetdomainname.
24698
24699 2003-09-25  Simon Josefsson  <jas@extundo.com>
24700             Bruno Haible  <bruno@clisp.org>
24701
24702         * m4/getdomainname.m4: New file.
24703
24704 2003-09-25  Simon Josefsson  <jas@extundo.com>
24705             Bruno Haible  <bruno@clisp.org>
24706
24707         * lib/getdomainname.h: New file.
24708         * lib/getdomainname.c: New file.
24709
24710 2003-09-25  Karl Berry  <karl@gnu.org>
24711
24712         * lib/argp-fmtstream.c, argp-help.c: update from libc.
24713
24714 2003-09-25  Karl Berry  <karl@gnu.org>
24715
24716         * config/install-sh: update from automake.
24717
24718 2003-09-25  Bruno Haible  <bruno@clisp.org>
24719
24720         * modules/version-etc-2: New file, from modules/version-etc with
24721         modifications.
24722         * MODULES.html.sh (func_all_modules): Add version-etc-2.
24723
24724 2003-09-25  Bruno Haible  <bruno@clisp.org>
24725
24726         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
24727         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
24728
24729 2003-09-24  Simon Josefsson  <jas@extundo.com>
24730
24731         * modules/xgethostname: Add xgethostname.h.
24732
24733 2003-09-24  Paul Eggert  <eggert@twinsun.com>
24734
24735         * lib/linebuffer.c (freebuffer): Don't free the argument, just
24736         the buffer associated with the argument.  Bug reported by
24737         Simon Josefsson.
24738
24739 2003-09-24  Paul Eggert  <eggert@twinsun.com>
24740
24741         * README: Document assumptions that 'int' is at least 32 bits
24742         wide, that integer arithmetic is 2's complement without overflow,
24743         that there are no holes in integer values, that adding sizes of
24744         two nonoverlapping objects can't overflow, and that all-bits-zero
24745         yields scalar zero.  Fix spelling and capitalization typos.
24746
24747 2003-09-19  Karl Berry  <karl@gnu.org>
24748
24749         * lib/argp.h: update from libc.
24750
24751 2003-09-17  Paul Eggert  <eggert@twinsun.com>
24752
24753         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
24754         to avoid spurious warnings like "AC_RUN_IFELSE was called before
24755         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
24756
24757 2003-09-17  Paul Eggert  <eggert@twinsun.com>
24758
24759         * gnulib-tool: Use "test -h", not "test -L", for portability
24760         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
24761         (tags_regexp): Remove, since \| doesn't conform to POSIX.
24762         (sed_extract_prog): Issue s commands one-by-one, rather than
24763         using \| in one s command.
24764
24765 2003-09-16  Paul Eggert  <eggert@twinsun.com>
24766
24767         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
24768         input error, instead of returning NULL the next time we are called
24769         (and therefore losing track of errno).
24770
24771 2003-09-16  Bruno Haible  <bruno@clisp.org>
24772
24773         * gnulib-tool (func_create_testdir): Warn about duplicated
24774         dependencies.
24775
24776 2003-09-15  Paul Eggert  <eggert@twinsun.com>
24777
24778         * modules/argmatch, modules/fatal, modules/obstack,
24779         modules/xalloc, modules/xgethostname: Sort dependencies by
24780         importance, not alphabetically.
24781
24782 2003-09-15  Paul Eggert  <eggert@twinsun.com>
24783
24784         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
24785         fails, so that the caller gets the proper errno.
24786
24787         * lib/readutmp.c (read_utmp): Likewise.
24788         Check for fstat error.  Close stream and free storage
24789         when failing.
24790
24791 2003-09-14  Karl Berry  <karl@gnu.org>
24792
24793         * config/srclist.txt (strdup.c): disable for c89 changes.
24794
24795 2003-09-14  Jim Meyering  <jim@meyering.net>
24796
24797         * lib/getloadavg.c: Correct cpp indentation.
24798         * lib/strdup.c: Likewise.
24799         * lib/vasnprintf.c: Likewise.
24800
24801 2003-09-14  Bruno Haible  <bruno@clisp.org>
24802
24803         * modules/fwriteerror: New file.
24804         * MODULES.html.sh (func_all_modules): Add fwriteerror.
24805
24806 2003-09-14  Bruno Haible  <bruno@clisp.org>
24807
24808         * lib/fwriteerror.h: New file.
24809         * lib/fwriteerror.c: New file.
24810
24811 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24812
24813         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
24814         modules/xgethostname, modules/xalloc: Depend on exit.
24815
24816 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24817
24818         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
24819
24820         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
24821         and AC_MINIX, too, so that their extensions are available.
24822
24823         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
24824         This macro has been superseded by gl_BACKUPFILE.
24825
24826         More patches to assume C89 or better.
24827
24828         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
24829
24830         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
24831         unconditionally.
24832         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
24833         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
24834         Include <string.h>, <stdlib.h> unconditionally.
24835         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
24836         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
24837         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
24838         headers or for string.h.
24839         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
24840         or strtoul.
24841
24842         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
24843         headers.
24844         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
24845         * m4/userspec.m4 (gl_USERSPEC): Likewise.
24846         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
24847         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
24848         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
24849         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
24850         memcpy, memset.
24851         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
24852         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
24853         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
24854         strtol.
24855         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
24856         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
24857         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
24858         strtoul.
24859
24860 2003-09-12  Paul Eggert  <eggert@twinsun.com>
24861
24862         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
24863         * lib/obstack.c [!defined _LIBC]: Likewise.
24864         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
24865         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
24866         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
24867
24868         More changes to assume C89 or better.
24869
24870         * lib/error.c (error_tail): Assume vprintf.
24871
24872         * lib/argmatch.c (getenv): Remove decl.
24873         * lib/progreloc.c (get_full_program_name): Define via prototype.
24874         * lib/setenv.c (clearenv): Likewise.
24875         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
24876         needed.
24877         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
24878         (malloc, memcpy): Remove decls.
24879         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
24880         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
24881         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
24882         (memcpy): Remove macro.
24883         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
24884         (__P): Remove.  All uses removed.
24885         (PTR): Remove.  All uses changed to void *.
24886         (CHAR_BIT, NULL): Remove.
24887         (spaces, zeros, memset_space, memset_zero)
24888         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
24889         Remove.
24890         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
24891         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
24892         Define with prototype.
24893         Remove now-unnecessary prototype decl.
24894         (extra_args_spec): Assume ANSI C.  All uses changed.
24895         (extra_args_spec_iso): Remove.
24896         (my_strftime, emacs_strftimeu): Define via prototype.
24897         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
24898         unconditionally.
24899         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
24900         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
24901         (strtoul, strtol): Remove decls.
24902         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
24903         LONG_MAX): Remove.
24904         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
24905         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
24906         (LOCALE_PARAM_PROTO): New macro.
24907         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
24908         (INTERNAL (strtol), strtol): Define with a prototype.
24909         (PARAMS): Remove.  All uses removed.
24910         * lib/tempname.c: Include <string.h> unconditionally.
24911         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
24912         * lib/xgethostname.c (main): Define with a prototype.
24913         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
24914         Include <stdlib.h> unconditionally.
24915         (calloc, malloc, realloc, free): Remove decls.
24916         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
24917         Include <stdlib.h> unconditionally.  Sort include file names.
24918         (strtod): Remove.
24919         (xstrtod): Define with a prototype.
24920         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
24921         (strtol, strtoul): Remove decls.
24922
24923 2003-09-11  Paul Eggert  <eggert@twinsun.com>
24924
24925         More patches to assume C89 or better.
24926         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
24927         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
24928         string.h, memchr, STDC_HEADERS.
24929
24930 2003-09-11  Paul Eggert  <eggert@twinsun.com>
24931
24932         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
24933         Include <stdlib.h>, <string.h> unconditionally.
24934         Remove now-unnecessary cast to char *.
24935         * lib/strnlen.c: Include <string.h> unconditionally.
24936         * lib/yesno.c (yesno): Define with a prototype.
24937
24938 2003-09-11  Bruno Haible  <bruno@clisp.org>
24939
24940         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
24941
24942 2003-09-10  Jim Meyering  <jim@meyering.net>
24943
24944         * lib/error.c: Correct indentation of cpp directives.
24945
24946 2003-09-10  Bruno Haible  <bruno@clisp.org>
24947
24948         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
24949         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
24950         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
24951         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
24952         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
24953         <stdlib.h> and <string.h> checks.
24954         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
24955         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
24956
24957 2003-09-10  Bruno Haible  <bruno@clisp.org>
24958
24959         * lib/strcspn.c: Include <string.h> unconditionally.
24960         * lib/strpbrk.c: Include <string.h> unconditionally.
24961         * lib/strstr.c: Include <string.h> unconditionally.
24962         * lib/unicodeio.c: Include <string.h> unconditionally.
24963         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
24964         * lib/unsetenv.c: Likewise.
24965         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
24966         * lib/yesno.c: Include <stdlib.h> unconditionally.
24967         (rpmatch): Add prototype.
24968
24969 2003-09-09  Paul Eggert  <eggert@twinsun.com>
24970
24971         More patches to assume C89 or better.
24972         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
24973         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
24974         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
24975         or for string.h.
24976         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
24977         stdlib.h.
24978         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
24979         C headers.
24980         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
24981         string.h.
24982         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
24983         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
24984         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
24985         or for string.h.
24986         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
24987         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
24988         C headers.
24989         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
24990         memcpy.
24991         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
24992         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
24993         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
24994         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
24995         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
24996         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
24997         string.h, free.
24998         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
24999         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
25000         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
25001         C headers, or for string.h.
25002         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
25003         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
25004         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
25005         headers, memory.h, stdlib.h, string.h, strings.h.
25006         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
25007         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
25008         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
25009         strchr.
25010         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
25011         headers, memory.h, string.h.
25012         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
25013         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
25014         free.
25015         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
25016         headers.
25017         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
25018         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
25019         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
25020         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
25021         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
25022
25023 2003-09-09  Paul Eggert  <eggert@twinsun.com>
25024
25025         More K&R removal.
25026
25027         * lib/acosl.c (main): Use a prototype.
25028         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
25029         tanl.c: Likewise.
25030
25031         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
25032
25033         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
25034         (getopt, etopt_long, getopt_long_only, _getopt_internal)
25035         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
25036         with a prototype.
25037         * lib/getopt.c (const): Remove macro.
25038         Include <string.h> unconditionally.
25039         (my_index): Remove; all uses changed to strchr.
25040         (strlen): Remove decl.
25041         (exchange): Remove forward decl; no longer needed.
25042         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
25043         Define with prototype.
25044         * lib/getopt1.c (const): Remove macro.
25045         (getopt_long, getopt_long_only, main): Define with prototype.
25046
25047         * lib/getugroups.c: Include <string.h> unconditionally.
25048
25049         * lib/getusershell.c: Include <stdlib.h> unconditionally.
25050         (getusershell, setusershell, endusershell, readname, main):
25051         Define with prototypes.
25052
25053         * lib/group-member.c: Include group-member.h first.
25054         Include <stdlib.h> unconditionally.
25055
25056         * lib/hard-locale.c: Include hard-locale.h first.
25057         Include <stdlib.h>, <string.h> unconditionally.
25058
25059         * lib/hash.c (free, malloc): Remove decls.
25060         Include <stdlib.h> unconditionally.
25061
25062         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
25063         (getenv): Do not declare.
25064
25065         * lib/idcache.c: Include <string.h> unconditionally.
25066
25067         * lib/long-options.c: Include long-options.h first, to test interface.
25068         Include <stdlib.h> unconditionally.
25069
25070         * lib/makepath.c: Include makepath.h first, to test interface.
25071         Include <stdlib.h> and <string.h> unconditionally.
25072
25073         * lib/linebuffer.c: Include <stdlib.h>.
25074         (free): Remove decl.
25075
25076         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
25077         stddef.h. rpl_malloc returns void *, not char *.
25078         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
25079         prototype.
25080
25081         * lib/md5.h: Include <limits.h> unconditionally.
25082         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
25083         (__P): Remove; all uses removed.
25084         * lib/md5.c: Include "md5.h" first.
25085         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
25086         md5_buffer, md5_process_bytes, md5_process_block):
25087         Define with prototypes.
25088         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
25089         * lib/sha.c: Include "sha.h" first.
25090         Include <stdlib.h>, <string.h> unconditionally.
25091
25092         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
25093         * lib/memcmp.c (__ptr_t): Likewise.
25094         * lib/memrchr.c (__ptr_t): Likewise.
25095         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
25096         Include <string.h> unconditionally.
25097         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
25098         * lib/memchr.c: Include <stdlib.h> unconditionally.
25099         * lib/memchr.c (LONG_MAX): Remove.
25100         * lib/memrchr.c (LONG_MAX): Likewise.
25101         * lib/memchr.c (__memchr): Define via a prototype.
25102         * lib/memrchr.c (__memrchr): Likewise.
25103         * lib/memcmp.c (__P): Remove, and remove all uses.
25104         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
25105         Remove forward decls; no longer needed.
25106         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
25107         Use types required by C89 in prototype.
25108
25109         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
25110         * lib/savedir.c: Likewise.
25111         * lib/mkdir.c (free): Remove decl.
25112         * lib/rmdir.c (rmdir): Define with a prototype.
25113         * lib/savedir.c: Include savedir.h first, to test interface.
25114
25115         * lib/mktime.c (STDC_HEADERS): Remove.
25116         Include <stdlib.h>, <string.h> unconditionally.
25117
25118         * lib/modechange.c: Include <stdlib.h> unconditionally.
25119         (malloc): Remove decl.
25120
25121         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
25122         (free): Remove decl.
25123
25124         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
25125         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
25126         (This type really should be intptr_t, but that's a C99ism.)
25127         (_obstack_memcpy): Remove: all uses changed to memcpy.
25128         Include <string.h> unconditionally.
25129         (struct obstack): Assume __STDC__ for types of members
25130         chunkfun, freefun, extra_arg.
25131         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
25132         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
25133         obstack_begin, obstack_specify_allocation,
25134         obstack_specify_allocation_with_arg, obstack_chunkfun,
25135         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
25136         Remove unprototyped decls and the macros that use them.
25137         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
25138         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
25139         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
25140         (defined __STDC__ && __STDC__)]:
25141         Remove nonprototyped code.
25142         Include <stdlib.h> unconditionally.
25143         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
25144         _obstack_allocated_p, _obstack_free, obstack_free,
25145         _obstack_memory_used, print_and_abort):
25146         Define using prototypes.
25147         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
25148         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
25149         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
25150         obstack_next_free, obstack_object_size, obstack_room) [0]:
25151         Remove unused, unprototyped code.
25152
25153         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
25154
25155         * lib/physmem.c (physmem_total, physmem_available, main): Define
25156         with prototypes.
25157
25158         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
25159         (main): Define with a prototype.
25160
25161         * lib/posixver.c (getenv): Remove decl.
25162
25163         * lib/putenv.c (malloc): Returns void *, not char *.
25164         Include <string.h> unconditionally.
25165         (strchr, memcpy, NULL): Do not define.
25166
25167         * lib/readtokens.c: Include readtokens.h first, to test interface.
25168         Include <stdlib.h>, <string.h> unconditionally.
25169         (init_tokenbuffer): Define with a prototype.
25170
25171         * lib/regex.c (PARAMS): Remove.  All uses removed.
25172         All uses of _RE_ARGS removed, too.
25173         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
25174         unconditionally.
25175         (bzero): Assume memset exists.
25176         (memcmp, memcpy, NULL): Remove.
25177         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
25178         char, or assignments to local vars of type signed char.
25179         (init_syntax_once, PREFIX(extract_number_and_incr),
25180         PREFIX(print_partial_compiled_pattern),
25181         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
25182         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
25183         PREFIX(regex_grow_registers), PREFIX(regex_compile),
25184         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
25185         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
25186         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
25187         wcs_compile_range, byte_compile_range, truncate_wchar,
25188         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
25189         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
25190         count_mbs_length, wcs_re_match_2_internal,
25191         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
25192         PREFIX(alt_match_null_string_p),
25193         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
25194         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
25195         regfree, PREFIX(extract_number)): Define with prototype.  Remove
25196         now-unnecessary declaration, if any.
25197         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
25198         regcomp, regexec):
25199         Remove now-unnecessary casts among pointer types.
25200         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
25201
25202         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
25203         (free): Remove decl.
25204
25205         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
25206
25207         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
25208         (free): Remove decl.
25209
25210         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
25211         * lib/xgetcwd.c: Likewise.
25212
25213         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
25214         (free): Remove decl.
25215
25216         * lib/strchrnul.c (strchrnul): Define with a prototype.
25217         Fix bug: c_in was not converted to char before searching.
25218
25219         The following changes are not K&R related:
25220
25221         * lib/group-member.h: Include <sys/types.h>, so that this file is
25222         self-contained.
25223         * lib/makepath.h: Likewise.
25224
25225         * lib/getusershell.c (readname, default_index, line_size, readname):
25226         Use size_t, not int, for sizes.
25227         (readname): If the size overflows, report an error instead of
25228         looping forever.
25229
25230 2003-09-09  Paul Eggert  <eggert@twinsun.com>
25231
25232         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
25233         libc.
25234
25235 2003-09-09  Paul Eggert  <eggert@twinsun.com>
25236
25237         * README: New section: portability guidelines.
25238
25239 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
25240
25241         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
25242         C89 spec.
25243
25244 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
25245
25246         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
25247
25248 2003-09-08  Paul Eggert  <eggert@twinsun.com>
25249
25250         Assume C89 or better; remove K&R cruft.
25251         A few of these changes were first proposed by Derek Robert Price
25252         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
25253
25254         * lib/addext.c: Include <string.h> unconditionally.
25255         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
25256         Don't declare getenv or malloc.
25257
25258         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
25259         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
25260         (NULL): Remove.
25261         (find_stack_direction, alloca): Use prototypes.
25262
25263         * lib/atexit.c (atexit): Define using a prototype.
25264
25265         * lib/basename.c, dirname.c, stripslash.c:
25266         Include <string.h> unconditionally.
25267
25268         * lib/bcopy.c: Include <stddef.h>.
25269         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
25270
25271         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
25272
25273         * lib/error.h (error, error_at_line, error_print_progname)
25274         [! (defined (__STDC__) && __STDC__)]: Remove decls.
25275         * lib/error.c: Include error.h first, to check interface.
25276         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
25277         (VA_START): Remove; all uses changeed to va_start.
25278         (exit, strerror): Remove decls.
25279         (error_print_progname): Prototype uncondionally.
25280         Don't include <errno.h>; no longer needed.
25281         (private_strerror): Remove.
25282         (error_tail): Always define.
25283         (error, error_at_line): Assume C89 or better; always use prototypes.
25284         * lib/fatal.c: Include "fatal.h" first, to test interface.
25285         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
25286         (VA_START): Remove; all uses changed to va_start.
25287         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
25288         this case.
25289         (exit): Remove decl.
25290         (fatal): Prototype unconditionally.  Assume va_start works.
25291         Abort at end, to pacify gcc.
25292
25293         * lib/euidaccess.c (main): Define with a prototype.
25294
25295         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
25296
25297         * lib/exitfail.c: Include <stdlib.h> unconditionally.
25298
25299         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
25300         prototypes.
25301         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
25302         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
25303         (getenv): Remove decl.
25304         (fnmatch): Define using a prototype.
25305         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
25306         (FCT): Define using a prototype.
25307
25308         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
25309
25310         * lib/gethostname.c: Include <stddef.h>.
25311         (gethostname): Define with prototype.  Length is size_t, not int.
25312
25313 2003-09-08  Paul Eggert  <eggert@twinsun.com>
25314
25315         Assume C89 or better; remove K&R cruft.
25316         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
25317         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
25318         string.h, getenv, malloc.
25319         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
25320         headers.
25321         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
25322         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
25323         do not check for strerror.
25324         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
25325         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
25326         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
25327         do not check for doprnt or vprintf.
25328         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
25329         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
25330
25331 2003-09-08  Paul Eggert  <eggert@twinsun.com>
25332
25333         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
25334         getversion.c should have been removed then, but was accidentally
25335         preserved.
25336
25337         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
25338         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
25339
25340 2003-09-08  Karl Berry  <karl@gnu.org>
25341
25342         * config/config.sub, config.guess, srclistvars.sh: update from savannah
25343                 config, forget about prep.
25344
25345         * config/depcomp, missing: update from automake.
25346
25347 2003-09-07  Paul Eggert  <eggert@twinsun.com>
25348
25349         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
25350         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
25351
25352 2003-09-07  Paul Eggert  <eggert@twinsun.com>
25353
25354         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
25355         copy_tm_result.  Bug reported by Simon Josefsson in
25356         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
25357
25358 2003-09-06  Paul Eggert  <eggert@twinsun.com>
25359
25360         * m4/time_r.m4: New file.
25361         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
25362         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
25363         is. Check for timegm declaration.
25364         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
25365         Do not check for gmtime_r.
25366         Replace mktime if __mktime_internal does not exist and if mktime
25367         hasn't been replaced already.
25368
25369 2003-09-06  Paul Eggert  <eggert@twinsun.com>
25370
25371         * lib/time_r.c, lib/time_r.h: New files.
25372
25373         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
25374         __localtime_r.
25375         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
25376         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
25377
25378         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
25379         __gmtime_r.
25380         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
25381         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
25382         Include <time_r.h>.
25383
25384         * lib/timegm.c: Switch to glibc implementation, with the following
25385         changes:
25386         [defined HAVE_CONFIG_H]: Include <config.h>.
25387         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
25388         (__mktime_internal) [!defined _LIBC]: New decl.
25389         (__gmtime_r) [!defined _LIBC]: New macro and function.
25390         (timegm): Use a prototype, since gnulib assumes C89.
25391         Do not bother declaring tmp to be const, as it's not really usefu.
25392         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
25393         (timegm): Declare only if HAVE_DECL_TIMEGM.
25394
25395 2003-09-06  Paul Eggert  <eggert@twinsun.com>
25396
25397         * MODULES.html.sh (func_all_modules): Add time_r.
25398         * modules/time_r: New file.
25399         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
25400         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
25401
25402 2003-09-03  Paul Eggert  <eggert@twinsun.com>
25403
25404         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
25405         Bug reported by Lute Kamstra in
25406         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
25407
25408         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
25409         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
25410         course with correspondingly smaller numbers for tomorrow and
25411         yesterday.  From Tadayoshi Funaba.  Originally installed into
25412         sh-utils on 1999-08-07, but the patch got lost (I guess during the
25413         coreutils merge?).
25414
25415 2003-08-31  Simon Josefsson  <jas@extundo.com>
25416
25417         * modules/timegm: New file.
25418         * MODULES.html.sh (func_all_modules): Add timegm.
25419
25420 2003-08-31  Simon Josefsson  <jas@extundo.com>
25421
25422         * m4/timegm.m4: New file.
25423
25424 2003-08-31  Simon Josefsson  <jas@extundo.com>
25425
25426         * lib/timegm.h: New file.
25427         * lib/timegm.c: New file.  Based on
25428         wget-1.8.2/src/http.c:mktime_from_utc.
25429
25430 2003-08-31  Karl Berry  <karl@gnu.org>
25431
25432         * lib/argp.h: update from libc.
25433
25434 2003-08-28  Bruno Haible  <bruno@clisp.org>
25435
25436         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
25437         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
25438         followed by '#define fnmatch fnmatch_posix' gives an error.
25439
25440 2003-08-28  Bruno Haible  <bruno@clisp.org>
25441
25442         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
25443         warning on QNX, which defines O_BINARY to 000000.
25444
25445 2003-08-27  Jim Meyering  <jim@meyering.net>
25446
25447         * m4/mkstemp.m4: Require that the system mkstemp be able to create
25448         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
25449         would fail after 32.  Reported by Danny Levinson.  Details here:
25450         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
25451
25452 2003-08-24  Bruno Haible  <bruno@clisp.org>
25453
25454         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
25455         MSVC7 <stdio.h> is included later.
25456
25457 2003-08-22  Simon Josefsson  <jas@extundo.com>
25458
25459         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
25460
25461 2003-08-20  Karl Berry  <karl@gnu.org>
25462
25463         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
25464
25465 2003-08-20  Bruno Haible  <bruno@clisp.org>
25466
25467         * modules/progname: New file.
25468         * MODULES.html.sh (func_all_modules): Add progname.
25469
25470 2003-08-20  Bruno Haible  <bruno@clisp.org>
25471
25472         * lib/progname.h: New file, from GNU gettext.
25473         * lib/progname.c: New file, from GNU gettext.
25474         * lib/progreloc.c: New file, from GNU gettext.
25475
25476 2003-08-19  Jim Meyering  <jim@meyering.net>
25477
25478         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
25479         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
25480
25481 2003-08-19  Bruno Haible  <bruno@clisp.org>
25482
25483         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
25484         more.
25485
25486 2003-08-19  Bruno Haible  <bruno@clisp.org>
25487
25488         * lib/xstrdup.c: Assume <string.h> exists.
25489
25490 2003-08-18  Paul Eggert  <eggert@twinsun.com>
25491
25492         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
25493         in makefile rules.
25494
25495 2003-08-18  Jim Meyering  <jim@meyering.net>
25496
25497         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
25498         * m4/lib-ld.m4: Likewise.
25499
25500 2003-08-18  Jim Meyering  <jim@meyering.net>
25501
25502         * lib/setenv.h: Indent nested cpp directive.
25503         * lib/vasnprintf.c: Remove trailing blanks.
25504
25505 2003-08-17  Simon Josefsson  <jas@extundo.com>
25506
25507         * modules/xstrndup: New file.
25508         * MODULES.html.sh (func_all_modules): Add xstrndup.
25509
25510 2003-08-17  Simon Josefsson  <jas@extundo.com>
25511
25512         * modules/argp: Fix autoconf macro name. Add more dependencies.
25513
25514 2003-08-17  Simon Josefsson  <jas@extundo.com>
25515
25516         * m4/xstrndup.m4: New file.
25517
25518 2003-08-17  Simon Josefsson  <jas@extundo.com>
25519
25520         * m4/argp.m4: New file.
25521
25522 2003-08-17  Simon Josefsson  <jas@extundo.com>
25523             Bruno Haible  <bruno@clisp.org>
25524
25525         * lib/xstrndup.h: New file.
25526         * lib/xstrndup.c: New file.
25527
25528 2003-08-17  Bruno Haible  <bruno@clisp.org>
25529
25530         * modules/strndup (Files, Include): Add lib/strndup.h.
25531
25532 2003-08-17  Bruno Haible  <bruno@clisp.org>
25533
25534         * modules/euidaccess (Files): Add lib/euidaccess.h.
25535
25536 2003-08-17  Bruno Haible  <bruno@clisp.org>
25537
25538         * lib/strndup.h: New file.
25539
25540 2003-08-17  Bruno Haible  <bruno@clisp.org>
25541
25542         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
25543         like AC_GNU_SOURCE.
25544         * modules/extensions (configure.ac): Comment out the invocation of
25545         gl_USE_SYSTEM_EXTENSIONS.
25546
25547 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25548
25549         Merges from coreutils, etc.
25550         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
25551         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
25552         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
25553         fixing a typo.
25554         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
25555         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
25556
25557 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25558
25559         Document merge from coreutils.
25560         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
25561         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
25562         * modules/utime: Add m4/utimes-null.m4.
25563
25564 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25565
25566         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
25567         space, undoing this 2003-08-12 change:
25568         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
25569
25570 2003-08-16  Paul Eggert  <eggert@twinsun.com>
25571
25572         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
25573         strtoul.c from libc, undoing this 2003-08-12 change:
25574         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
25575
25576 2003-08-16  Jim Meyering  <jim@meyering.net>
25577
25578         Merges from coreutils.
25579         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
25580         prefix.  Adjust cache variables similarly.  Create 500 rather than
25581         just 300 files, to exercise bug on Darwin6.5, too.
25582         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
25583         $missing_dir.
25584         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
25585         AM_SYS_POSIX_TERMIOS.
25586         Reported by mkc@mathdogs.com.
25587         Also change use of $am_cv_sys_posix_termios
25588         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
25589         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
25590         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
25591         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
25592         in /proc/mounts until it finds one with matching device number.  This
25593         is unnecessary when the FILE argument *is* a mount point.  No stat call
25594         is necessary in that case.  So, disable the statvfs-testing code on
25595         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
25596         as RedHat bug# 84846.
25597         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
25598         to 1MB, so as not to render systems with no stack size limit (e.g.,
25599         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
25600         Include <unistd.h>.  On some systems,
25601         it is required for the definition of _SC_PAGESIZE.
25602
25603 2003-08-16  Jim Meyering  <jim@meyering.net>
25604
25605         Merge from coreutils.
25606         * lib/xstrtoimax.c: #else #if -> #elif.
25607         * lib/xstrtoumax.c: Likewise.
25608
25609 2003-08-16  Jim Meyering  <jim@meyering.net>
25610
25611         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
25612         * m4/utimes.m4: Removed.
25613         * m4/utimes-null.m4: Renamed from utimes.m4.
25614
25615         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
25616         to 1MB, so as not to render systems with no stack size limit (e.g.,
25617         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
25618         Include <unistd.h>.  On some systems,
25619         it is required for the definition of _SC_PAGESIZE.
25620
25621 2003-08-16  Jim Meyering  <jim@meyering.net>
25622         and Paul Eggert  <eggert@cs.ucla.edu>
25623
25624         Merges from coreutils, etc.
25625
25626         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
25627         using the latest version from cvs.  This avoids problems with #line
25628         directives using a vendor (Sun) compiler.
25629         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
25630         Don't set GETGROUPS_LIB here; now it's
25631         done via getgroups.m4's wrapper function.
25632         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
25633         rather than just in sh-util/configure.in, so that the
25634         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
25635         same.
25636         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
25637         AC_FUNC_GETLOADAVG where to find getloadavg.c.
25638         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
25639         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
25640         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
25641         Remove code that is now done by the newly-required macros.
25642         Append $(EXEEXT) to DF_PROG.
25643         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
25644         Do not invoke or require the following here,
25645         since prereq.m4 or some gnulib .m4 now does this for us:
25646         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
25647         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
25648         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
25649         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
25650         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
25651         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
25652         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
25653         AC_FUNC_OBSTACK.
25654         Do not replace the following functions, as this is now the job
25655         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
25656         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
25657         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
25658         atexit getpass, strdup, getpagesize.
25659         Replace 'raise'.
25660         Do not check for the following functions, as this is now the job
25661         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
25662         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
25663         setregid.
25664         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
25665         Check for sys/sysctl.h.
25666         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
25667         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
25668         of checking for ssize_t ourselves.
25669
25670         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
25671         Require every macro that gnulib/modules/* suggests for us.
25672         (jm_PREREQ_ADDEXT): New macro.
25673         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
25674         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
25675
25676         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
25677         (gl_PHYSMEM): Use it.
25678         Also check for `table' function.
25679         Check for new headers and functions.
25680         Add check for sys/sysmp.h.
25681         With suggestions from Kaveh Ghazi.
25682         Ignore headers that are present but cannot be compiled.  This
25683         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
25684         C 5.4.
25685
25686 2003-08-15  Paul Eggert  <eggert@twinsun.com>
25687
25688         Document merge from coreutils.
25689         * modules/userspec: Depend on posixver.
25690         * modules/strftime: Depend on tzset.
25691
25692 2003-08-15  Paul Eggert  <eggert@twinsun.com>
25693
25694         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
25695         rather than tab, after '#' in shell-script copyright notices.
25696         Suggested by Bruno Haible.
25697
25698 2003-08-15  Paul Eggert  <eggert@twinsun.com>
25699
25700         * config/srclist-update: Use three spaces, rather than tab, after '#'
25701         in shell-script copyright notices.  Suggested by Bruno Haible.
25702         Remove unnecessary parenthesization in regular expression.
25703
25704 2003-08-15  Jim Meyering  <jim@meyering.net>
25705
25706         Merge from coreutils.
25707         * lib/xgethostname.c: Include <stdlib.h>.
25708         (xghostname): Don't exit for anything other than memory-related
25709         failure; just return NULL.
25710         * lib/userspec.c: Include "posixver.h".
25711         (parse_user_spec): Accept `.' as a separator only
25712         in pre-POSIX-200112 mode.
25713         * lib/strtoimax.c: Use #elif rather than #else #if.
25714         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
25715         Remove function, now that we can rely on a working tzset function.
25716         [!_LIBC]: Ensure that the required autoconf test has been run.
25717         [!defined _NL_CURRENT && HAVE_STRFTIME]:
25718         Use underlying_strftime for %r.
25719         * lib/sha.c: Merge in some clean-up and optimization changes from
25720         glibc.
25721         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
25722         Ensure that it is a multiple of 64.
25723         Rearrange loop exit tests so as to avoid performing an
25724         additional fread after encountering an error or EOF.
25725         * lib/realloc.c: Update copyright date.
25726
25727 2003-08-15  Jim Meyering  <jim@meyering.net>
25728         and Paul Eggert  <eggert@twinsun.com>
25729
25730         Merge from coreutils.
25731         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
25732         member but strut utmpx does not.  Needed for AIX 4.3.3.
25733         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
25734
25735 2003-08-15  Jim Meyering  <jim@meyering.net>
25736         and Paul Eggert  <eggert@cs.ucla.edu>
25737
25738         Merges from coreutils, etc.
25739         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
25740         Require gl_FUNC_TZSET_CLOBBER.
25741         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
25742         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
25743         members.
25744
25745 2003-08-14  Paul Eggert  <eggert@twinsun.com>
25746
25747         Help the merge from coreutils.
25748         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
25749         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
25750         * m4/tzset.m4: Use it too.
25751
25752 2003-08-14  Paul Eggert  <eggert@twinsun.com>
25753
25754         * modules/tzset: New file.
25755
25756 2003-08-14  Jim Meyering  <jim@meyering.net>
25757
25758         Merges from coreutils.
25759         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
25760         variable names, rather than @FNMATCH_H@.
25761         * modules/alloca: Likewise for $(ALLOCA_H).
25762
25763         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
25764         the three copies of the literal target, `fnmatch.h'.
25765         * modules/alloca (alloca.h): Likewise.
25766
25767 2003-08-14  Jim Meyering  <jim@meyering.net>
25768
25769         Merge from coreutils.
25770         * m4/tzset.m4: New file.
25771         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
25772         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
25773         otherwise, AIX 5.1 systems would end up using the latter.
25774         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
25775         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
25776         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
25777         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
25778
25779 2003-08-14  Jim Meyering  <jim@meyering.net>
25780
25781         Merge from coreutils.
25782         * lib/obstack.h: Whitespace changes.
25783         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
25784         and xcalloc return values.
25785         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
25786         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
25787         hang on OSF/1 5.1 for DIR on both local and remote file systems.
25788         Reported by (and fix confirmed by) Nelson H. F. Beebe.
25789         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
25790         error from mntctl.
25791         Use mntctl's return value to drive the entry-processing loop, since
25792         we can't rely on the value of the vmt_length member in the last
25793         entry.  On some systems doing so could result in exhausting
25794         virtual memory.  Based in part on a patch from Mike Jetzer.
25795
25796 2003-08-14  Jim Meyering  <jim@meyering.net>
25797         and Paul Eggert  <eggert@twinsun.com>
25798
25799         Merges from coreutils, plus other fixes.
25800         * lib/physmem.c: Merge in portability changes from gcc/libiberty
25801         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
25802         for credits and details.  Thanks to Kaveh Ghazi for helping
25803         to keep these files in sync.
25804         (ARRAY_SIZE): Define it.
25805         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
25806         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
25807         (memcasecmp): Don't assume size_t fits in unsigned int.
25808         Remove casts and duplicate code.
25809         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
25810         (memcpy): Remove definition.
25811         Merge in some clean-up and optimization changes from glibc.
25812         [BLOCKSIZE]: Move definition to top of file.
25813         Ensure that it is a multiple of 64.
25814         Rearrange loop exit tests so as to avoid performing an
25815         additional fread after encountering an error or EOF.
25816         * lib/md5.h (md5_uintptr): Define.
25817         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
25818         return to the initial working directory.  Preserve errno
25819         for caller.
25820         * lib/idcache.c: Include "xalloc.h".
25821         (xmalloc, xrealloc): Remove decls.
25822         (getuser): Remove casts no longer required in C89.
25823         * lib/human.c: Include stdio.h, for sprintf.
25824         * lib/group-member.c: Include "xalloc.h".
25825         (xmalloc, xrealloc): Remove decls.
25826         (get_group_info): Remove casts no longer required in C89.
25827         * lib/getusershell.c (readname): Remove casts no longer required in
25828         C89.
25829         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
25830         * lib/getline.c: Whitespace fix, from coreutils.
25831
25832 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25833
25834         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
25835         Check for isascii.
25836
25837         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
25838         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
25839         Undo previous (whitespace-only) change.
25840
25841 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25842
25843         * lib/exclude.c: Include <ctype.h>
25844         (IN_CTYPE_DOMAIN): New macro.
25845         (is_space): New fn.
25846         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
25847         and empty lines.
25848
25849         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
25850         Undo previous (whitespace-only) change.
25851
25852 2003-08-13  Paul Eggert  <eggert@twinsun.com>
25853
25854         * config/srclist-update: Change update back to the old behavior,
25855         leaving whitespace alone.  Use one 'sed' command rather than a
25856         pipeline.
25857         (fixlicense): Now a variable, not a function.
25858         (remove_trailing_blanks): Remove.
25859         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
25860         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
25861         Undo previous (whitespace-only) change.
25862
25863 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25864
25865         Merge from coreutils.
25866         * modules/euidaccess: Add lib_SOURCES, include for new
25867         file euidaccess.h
25868
25869 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25870
25871         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
25872         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
25873         Normalize leading white space and remove trailing white space.
25874
25875         Merge from coreutils
25876         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
25877
25878         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
25879         0.12.1.  These files are now being upgraded automatically by
25880         ../config/srclist-update.
25881
25882 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25883
25884         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
25885         Normalize leading white space and remove trailing white space.
25886         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
25887         notice, as per ../config/srclist-update.
25888
25889         Merge from coreutils.
25890         * lib/euidaccess.h: New file.
25891         * lib/euidaccess.c: Include it.
25892         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
25893         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
25894         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
25895
25896 2003-08-12  Paul Eggert  <eggert@twinsun.com>
25897
25898         * config/srclist-update: Add copyright notice.
25899         (remove_id_lines, remove_trailing_blanks): New constants.
25900         (fixfile): Use them to normalize spacing a bit in copied files.
25901         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
25902         Normalize leading white space and remove trailing white space.
25903
25904         * config/texinfo.tex: Sync with texinfo.
25905
25906         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
25907         strtoul.c from libc, to merge coreutils whitespace changes.
25908
25909         * config/srclist.txt: Get the following m4 files from gettext:
25910         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
25911         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
25912         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
25913         wint_t.m4.
25914
25915 2003-08-12  Karl Berry  <karl@gnu.org>
25916
25917         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
25918         been made.
25919
25920 2003-08-11  Paul Eggert  <eggert@twinsun.com>
25921
25922         * modules/gnu-source, m4/gnu-source.m4:
25923         Remove; we're assuming Autoconf 2.54 or later now.
25924         Suggested by Bruno Haible.
25925         * MODULES.html.sh (func_all_modules): Remove gnu-source.
25926
25927 2003-08-11  Bruno Haible  <bruno@clisp.org>
25928
25929         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
25930
25931 2003-08-11  Bruno Haible  <bruno@clisp.org>
25932
25933         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
25934         (vasnprintf): Use it instead of wcslen.
25935
25936 2003-08-11  Bruno Haible  <bruno@clisp.org>
25937
25938         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
25939         value to ensure that _Bool promotes to int. Use #define for _Bool when
25940         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
25941
25942 2003-08-10  Karl Berry  <karl@gnu.org>
25943
25944         * lib/regex.h: update from libc (whitespace fix).
25945
25946 2003-08-09  Paul Eggert  <eggert@twinsun.com>
25947
25948         Merge some files from coreutils.  These changes were
25949         originally made by Jim Meyering.
25950         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
25951         many older Unixes require this.
25952         * lib/alloca.c (alloca): Remove cast to argument of free;
25953         no longer needed in C89.
25954         * lib/alloca_.h, regex.h: Fix white space to match
25955         what GNU indent does.
25956
25957 2003-08-09  Paul Eggert  <eggert@twinsun.com>
25958
25959         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
25960         apparently Emacs's Unicode mode got confused before my 2003-08-05
25961         checkin.
25962
25963 2003-08-08  Paul Eggert  <eggert@twinsun.com>
25964
25965         * m4/extensions.m4: New file.
25966         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
25967         Require gl_USE_SYSTEM_EXTENSIONS.
25968         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
25969         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
25970
25971 2003-08-08  Paul Eggert  <eggert@twinsun.com>
25972
25973         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
25974         * modules/extensions, modules/gnu-source: New files.
25975         * modules/timespec, modules/unlocked-io: Depend on extensions.
25976
25977 2003-08-07  Paul Eggert  <eggert@twinsun.com>
25978
25979         * modules/restrict: New file.
25980         * MODULES.html.sh (func_all_modules): Add restrict.
25981         * modules/regex: Depend on restrict.
25982
25983 2003-08-07  Paul Eggert  <eggert@twinsun.com>
25984
25985         * m4/restrict.m4: New file.
25986         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
25987
25988 2003-08-07  Bruno Haible  <bruno@clisp.org>
25989
25990         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
25991         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
25992
25993 2003-08-07  Bruno Haible  <bruno@clisp.org>
25994
25995         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
25996         makes the module 'getndelim2' compatible with the module 'getline'.
25997
25998 2003-08-05  Paul Eggert  <eggert@twinsun.com>
25999
26000         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
26001         byte with "\201" to avoid glitches when editing that source file
26002         with multi-gnome-terminal.
26003
26004 2003-08-05  Paul Eggert  <eggert@twinsun.com>
26005
26006         * lib/bumpalloc.h: Remove.
26007
26008 2003-08-05  Paul Eggert  <eggert@twinsun.com>
26009
26010         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
26011         * modules/bumpalloc: Remove.
26012
26013 2003-08-04  Paul Eggert  <eggert@twinsun.com>
26014
26015         * lib/getloadavg.c: Change copyright notice and spacing to conform to
26016         GNU coding style.
26017
26018         Merge from coreutils.
26019         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
26020         1. From glibc.
26021         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
26022         from Karl Berry, implemented by Jim Meyering.
26023         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
26024         from Dmitry V. Levin.
26025         Remove anachronistic cast of xrealloc.
26026         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
26027         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
26028         type. Otherwise, it wouldn't compile with at least /bin/cc on
26029         ymp-cray-unicos9.0.2.X.
26030         Combine two mostly-identical uses of alloca into one.
26031         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
26032
26033 2003-08-04  Dave Love  <d.love@dl.ac.uk>
26034
26035         [From Emacs.]
26036
26037         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
26038         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
26039         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
26040         obsolete NLIST_NAME_UNION.
26041         [__GNU__]: Undef BSD and FSCALE.
26042         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
26043
26044 2003-08-03  Paul Eggert  <eggert@twinsun.com>
26045
26046         * lib/stdbool_.h (_Bool): Make it signed char, instead of
26047         an enum type, so that it's guaranteed to promote to int.  See:
26048         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
26049
26050 2003-08-03  Karl Berry  <karl@gnu.org>
26051
26052         * config/depcomp: update from automake.
26053
26054 2003-07-31  Paul Eggert  <eggert@twinsun.com>
26055
26056         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
26057         (strerror): Don't assume that a printable int fits in 14 bytes.
26058
26059 2003-07-31  Bruno Haible  <bruno@clisp.org>
26060
26061         * modules/getpass-gnu: New file.
26062         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
26063
26064 2003-07-31  Bruno Haible  <bruno@clisp.org>
26065
26066         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
26067
26068 2003-07-24  Karl Berry  <karl@gnu.org>
26069
26070         * config/missing: update from automake.
26071
26072 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
26073             Bruno Haible  <bruno@clisp.org>
26074
26075         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
26076         * lib/getline.c (getline, getdelim): Likewise.
26077         Remove _GNU_SOURCE define; now it's defined in config.h through
26078         m4/getline.m4.
26079
26080 2003-07-23  Karl Berry  <karl@gnu.org>
26081
26082         * config/config.sub: update from prep.
26083
26084 2003-07-22  Paul Eggert  <eggert@twinsun.com>
26085
26086         * modules/xalloc (Depends-on): Add exitfail.
26087         * modules/xmemcoll: Likewise.
26088
26089 2003-07-22  Paul Eggert  <eggert@twinsun.com>
26090
26091         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
26092         over-parenthesization in macros.
26093
26094         Sync with coreutils.
26095
26096         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
26097         required by C99.
26098
26099         Use `exit_failure' for xalloc and xmemcoll instead of their own
26100         private exit-failure variables.
26101         * lib/xalloc.h (xalloc_exit_failure): Remove.
26102         * lib/xmalloc.c: Likewise.  Include exitfail.h.
26103         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
26104         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
26105         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
26106         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
26107
26108 2003-07-20  Jim Meyering  <jim@meyering.net>
26109
26110         * modules/closeout (Depends-on): Add exitfail.
26111         Suggestion from Bruno Haible.
26112
26113 2003-07-19  Karl Berry  <karl@gnu.org>
26114
26115         * config/config.sub: update from prep.
26116
26117 2003-07-18  Paul Eggert  <eggert@twinsun.com>
26118
26119         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
26120         Remove.
26121         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
26122         to test that it can stand by itself.  Include "exitfail.h".
26123         Clients should set exit_failure instead.
26124         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
26125
26126 2003-07-18  Bruno Haible  <bruno@clisp.org>
26127
26128         * modules/getndelim2: New file.
26129         * modules/getline: Share files with module getndelim2.
26130         * modules/getnline: Depend on getndelim2 instead of sharing files with
26131         it. Add getnline.c to lib_SOURCES.
26132         * MODULES.html.sh (func_all_modules): Add getndelim2.
26133
26134 2003-07-18  Bruno Haible  <bruno@clisp.org>
26135
26136         * m4/getndelim2.m4: New file.
26137         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
26138         invoke gl_PREREQ_GETNDELIM2.
26139         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
26140         gl_PREREQ_GETNDELIM2.
26141         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
26142         gl_GETNDELIM2.
26143
26144 2003-07-18  Bruno Haible  <bruno@clisp.org>
26145
26146         * lib/getndelim2.h: New file.
26147         * lib/getndelim2.c: Make into a module of its own. Include config.h,
26148         getndelim2.h.
26149         (getndelim2): Make non-static. Change return type to ssize_t.
26150         * lib/getline.h: Change argument names.
26151         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
26152         * lib/getnline.c: Include getndelim2.h.
26153
26154 2003-07-18  Andreas Schwab  <schwab@suse.de>
26155
26156         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
26157
26158 2003-07-17  Karl Berry  <karl@gnu.org>
26159
26160         * config/config.sub: update from prep.
26161
26162 2003-07-17  Bruno Haible  <bruno@clisp.org>
26163
26164         * modules/getnline: New file.
26165         * modules/getline: Add lib/getndelim2.c to source file list.
26166         * MODULES.html.sh (func_all_modules): Add getnline.
26167
26168 2003-07-17  Bruno Haible  <bruno@clisp.org>
26169
26170         * m4/getnline.m4: New file.
26171
26172 2003-07-17  Bruno Haible  <bruno@clisp.org>
26173
26174         * m4/Makefile.am.in: Remove file.
26175         * m4/Makefile.am: Remove file.
26176         * m4/Makefile.in: Remove file.
26177
26178 2003-07-17  Bruno Haible  <bruno@clisp.org>
26179
26180         * lib/getnline.h: New file.
26181         * lib/getnline.c: New file.
26182         * lib/getndelim2.c: New file, extracted from getline.c.
26183         (getndelim2): Renamed from getdelim2, with added nmax argument.
26184         * lib/getline.c: Include getndelim2.c.
26185         (getdelim2): Moved out to getndelim2.c.
26186         (getline, getdelim): Update.
26187
26188 2003-07-17  Bruno Haible  <bruno@clisp.org>
26189
26190         * lib/Makefile.am: Remove file.
26191         * lib/Makefile.in: Remove file.
26192
26193 2003-07-17  Bruno Haible  <bruno@clisp.org>
26194
26195         * configure.in: Remove file.
26196         * Makefile.in: Remove file.
26197
26198 2003-07-17  Bruno Haible  <bruno@clisp.org>
26199
26200         * MODULES.html.sh: Put the </BODY> right before </HTML>.
26201
26202 2003-07-16  Karl Berry  <karl@gnu.org>
26203
26204         * config/srclist-update: was running fixlicense twice, which caused
26205                 texinfo.tex to be nullified for some reason.  Simplify,
26206                 $gplsrc is no longer needed as far as I can see?
26207
26208 2003-07-16  Jim Meyering  <jim@meyering.net>
26209
26210         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
26211
26212 2003-07-15  Paul Eggert  <eggert@twinsun.com>
26213
26214         * config/srclist.txt: Get the following files from gettext-runtime/intl
26215         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
26216         ref-del.sin.  From Bruno Haible.
26217         * config/srclist-update (fixfile): Change grep pattern again, since the
26218         previous fix didn't work (there was another trailing $).  Use
26219         '[$]' to escape the $s.
26220
26221 2003-07-15  Karl Berry  <karl@gnu.org>
26222
26223         * lib/vasnprintf.c: update from gettext.
26224
26225 2003-07-15  Karl Berry  <karl@gnu.org>
26226
26227         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
26228         gets expanded when surrounded by '$'.
26229
26230 2003-07-15  Jim Meyering  <jim@meyering.net>
26231
26232         * modules/save-cwd: Don't depend on error.  From Derek Price.
26233
26234 2003-07-15  Jim Meyering  <jim@meyering.net>
26235
26236         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
26237
26238 2003-07-14  Simon Josefsson  <jas@extundo.com>
26239
26240         * modules/mempcpy: New file.
26241         * MODULES.html.sh (func_all_modules): Add mempcpy.
26242
26243 2003-07-14  Simon Josefsson  <jas@extundo.com>
26244
26245         * m4/mempcpy.m4: New file.
26246
26247 2003-07-14  Simon Josefsson  <jas@extundo.com>
26248
26249         * lib/mempcpy.h: New file.
26250         * lib/mempcpy.c: New file.
26251
26252 2003-07-14  Paul Eggert  <eggert@twinsun.com>
26253
26254         * modules/getdate, modules/posixtm: Depend on mktime.
26255
26256 2003-07-14  Paul Eggert  <eggert@twinsun.com>
26257
26258         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
26259         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
26260         unicodeio.c, unicodeio.h, unlocked-io.h:
26261         Switch from LGPL to GPL.
26262
26263 2003-07-14  Paul Eggert  <eggert@twinsun.com>
26264
26265         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
26266         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
26267         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
26268         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
26269         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
26270         updated automatically by ../config/srclist-update.  This changes
26271         their license from LPGL to GPL.
26272
26273 2003-07-14  Paul Eggert  <eggert@twinsun.com>
26274
26275         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
26276         assumed to refer to the root of the most recent stable gettext version.
26277         * config/srclistvars.sh: Add defaults for eggert.
26278         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
26279         Match "This program" as well as "The program".  This is needed
26280         for gettext.
26281
26282 2003-07-14  Jim Meyering  <jim@meyering.net>
26283
26284         Don't emit diagnostics.  Let callers do that.
26285         * lib/save-cwd.c: Don't include "error.h".
26286         (save_cwd): Don't call error.  Ensure that errno is valid
26287         when returning nonzero.
26288
26289         * lib/save-cwd.h (restore_cwd): Update prototype.
26290         * lib/save-cwd.c (restore_cwd): Remove two parameters.
26291         Simplify.  Don't call error upon failure.  Let callers do that.
26292         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
26293         when auditing is enabled.  But don't bother updating the #if.
26294
26295 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
26296
26297         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
26298         it breaks C++ compilation.
26299         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
26300
26301 2003-07-10  Simon Josefsson  <jas@extundo.com>
26302
26303         * modules/strchrnul (Makefile.am): Add strchrnul.h.
26304
26305 2003-07-10  Jim Meyering  <jim@meyering.net>
26306
26307         * m4/clock_time.m4: Remove trailing blank.
26308         * m4/intmax_t.m4: Likewise.
26309
26310 2003-07-10  Jim Meyering  <jim@meyering.net>
26311
26312         * lib/vasnprintf.c: Remove trailing blanks.
26313         Make cpp indentation consistent.
26314
26315 2003-07-09  Paul Eggert  <eggert@twinsun.com>
26316
26317         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
26318         posixver.c, strftime.c, strnlen.c, strverscmp.c:
26319         Switch from LGPL to GPL.
26320
26321 2003-07-09  Paul Eggert  <eggert@twinsun.com>
26322
26323         * config/srclist.txt: Sort sublists.  Add
26324         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
26325         that differ from gnulib for one reason or another; we'd like this list
26326         to be smaller but for now let's document what we have.
26327
26328 2003-07-08  Paul Eggert  <eggert@twinsun.com>
26329
26330         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
26331         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
26332         and sweeter "eval x=$x".
26333         * config/srclist.txt: Get lib/argp* from glibc.
26334
26335 2003-07-07  Paul Eggert  <eggert@twinsun.com>
26336
26337         * lib/mktime.c: Fix some boundary cases and remove need for floating
26338         point.
26339
26340         Issue a compile-time diagnostic if time_t is floating point, or if
26341         two's complement arithmetic is not in effect, or if arithmetic
26342         right shift does not propagate the sign.  These assumptions were
26343         all in the original code but they weren't checked.
26344
26345         (TIME_T_MIDPOINT, verify): New macros.
26346         (__isleap): Remove; it has integer overflow problems.
26347         (leapyear): New function, without those problems.
26348         (ydhms_tm_diff): Remove; splitting into two parts.
26349         (ydhms_diff): New function, containing the arithmetic part of
26350         the old ydhms_tm_diff function.  Issue a compile-time
26351         diagnostic if we are not using C99 integer division.
26352         Avoid casts when possible.
26353         (guess_time_tm): New function, containing the checking part of
26354         the old ydhms_tm_diff function.  Return the new value, rather than
26355         the difference between it and the old.  Accept a new argument T
26356         so that *T specifies the old value.  Check for overflow in the result.
26357
26358         (__mktime_internal): Use a time_t offset, not a long int offset.
26359         This undoes the 2003-06-04 change, which is no longer needed now
26360         that we have better overflow checking.
26361         (localtime_offset): Likewise.
26362
26363         (__mktime_internal): Avoid harmful overflow on hosts where time_t
26364         and long are 64-bit but int is only 32-bit.
26365         (ydhms_diff): Use long int to store year1 and yday1.
26366         Issue a compile-time diagnostic if long int is not wide enough.
26367
26368         (__mktime_internal): Use long int to store adjusted year and yday.
26369         Use plain C rather than preprocessor commands, if that doesn't
26370         affect efficiency.
26371         Check for overflow (and try to repair) after each probe
26372         rather than checking only at the very end.  This avoids some bugs
26373         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
26374         does not equal GMT offset at maximum time).
26375         Use integer to check for overflow rather than floating point; this
26376         is more portable to non-IEEE hosts, and is a tad faster.
26377         When we detect that we are oscillating between two values,
26378         don't check whether tm_isdst has the requested value, since
26379         we already know the answer.  When tm_isdst has the wrong value,
26380         use a different heuristic to find the right one, based on the
26381         extreme values actually observed in practice in tz2003a,
26382         rather than the (overly optimistic) "previous 3 calendar quarters".
26383
26384         (not_equal_tm, print_tm, check_result): Use "const T" rather than
26385         "T const" to accommodate glibc style.
26386         (check_result): Use less-confusing report format.  "long" -> "long int.
26387         (main): Likewise.
26388         Don't loop if the iteration overflows time_t.
26389         Allow a negative step in the iteration.
26390
26391 2003-07-06  Karl Berry  <karl@gnu.org>
26392
26393         * config/depcomp: update from automake.
26394         * config/config.sub: update from prep.
26395
26396 2003-07-03  Karl Berry  <karl@gnu.org>
26397
26398         * config/config.guess: update from prep.
26399
26400 2003-07-01  Paul Eggert  <eggert@twinsun.com>
26401
26402         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
26403         xreadlink.c now includes it unconditionally.
26404
26405 2003-07-01  Paul Eggert  <eggert@twinsun.com>
26406
26407         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
26408         having it depend on HAVE_SYS_TYPES_H.
26409
26410 2003-07-01  Bruno Haible  <bruno@clisp.org>
26411
26412         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
26413         <sys/types.h> should be sufficient.
26414         Reported by Paul Eggert.
26415
26416 2003-06-26  Karl Berry  <karl@gnu.org>
26417
26418         * config/depcomp: update from automake.
26419
26420 2003-06-26  Bruno Haible  <bruno@clisp.org>
26421
26422         * modules/human: Depend on module stdbool.
26423
26424 2003-06-25  Bruno Haible  <bruno@clisp.org>
26425
26426         * modules/readlink: New file.
26427         * modules/xreadlink: Depend on it.
26428         * MODULES.html.sh (func_all_modules): Add readlink.
26429
26430 2003-06-25  Bruno Haible  <bruno@clisp.org>
26431
26432         * m4/readlink.m4: New file.
26433
26434 2003-06-25  Bruno Haible  <bruno@clisp.org>
26435
26436         * lib/readlink.c: New file.
26437
26438 2003-06-22  Karl Berry  <karl@gnu.org>
26439
26440         * config/srclist.txt: update mkinstalldirs from automake.
26441         * config/mkinstalldirs: update.
26442
26443 2003-06-22  Bruno Haible  <bruno@clisp.org>
26444
26445         Portability to mingw32.
26446         * m4/ssize_t.m4: New file, from GNU gettext.
26447         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
26448         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
26449
26450 2003-06-22  Bruno Haible  <bruno@clisp.org>
26451
26452         * modules/safe-read: Add m4/ssize_t.m4.
26453         * modules/xreadlink: Add m4/ssize_t.m4.
26454
26455 2003-06-20  Bruno Haible  <bruno@clisp.org>
26456
26457         Assume C89, so PARAMS isn't needed.
26458         * lib/unicodeio.h (PARAMS): Remove.
26459         * lib/unicodeio.c: Don't use PARAMS.
26460
26461 2003-06-18  Karl Berry  <karl@gnu.org>
26462
26463         * config/config.{guess,sub}: update from prep.
26464
26465 2003-06-18  Jim Meyering  <jim@meyering.net>
26466
26467         Merge changes from coreutils.
26468         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
26469         Remove explicit declarations of xmalloc and realloc.
26470         Include xalloc.h.
26471         (read_utmp): Remove anachronistic cast of xmalloc.
26472
26473 2003-06-17  Paul Eggert  <eggert@twinsun.com>
26474
26475         Assume C89, so PARAMS isn't needed.
26476         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
26477         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
26478         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
26479         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
26480         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
26481         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
26482         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
26483         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
26484         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
26485         lib/xstrtod.h, lib/xstrtol.h: Likewise.
26486         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
26487         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
26488         no longer needed. Anyway, config.h should always be included before any
26489         other file.
26490
26491 2003-06-11  Simon Josefsson  <jas@extundo.com>
26492
26493         * modules/sysexits: New file.
26494         * MODULES.html.sh (func_all_modules): Add sysexits.
26495
26496 2003-06-11  Simon Josefsson  <jas@extundo.com>
26497
26498         * lib/sysexit_.h: New file.
26499
26500 2003-06-11  Derek Price  <derek@ximbiot.com>
26501
26502         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
26503         necessary.
26504
26505 2003-06-11  Bruno Haible  <bruno@clisp.org>
26506
26507         * m4/sysexits.m4: New file.
26508
26509 2003-06-10  Simon Josefsson  <jas@extundo.com>
26510
26511         * lib/argp.h: New file, from glibc.
26512         * lib/argp-ba.c: New file, from glibc.
26513         * lib/argp-eexst.c: New file, from glibc.
26514         * lib/argp-fmtstream.c: New file, from glibc.
26515         * lib/argp-fmtstream.h: New file, from glibc.
26516         * lib/argp-fs-xinl.c: New file, from glibc.
26517         * lib/argp-help.c: New file, from glibc.
26518         * lib/argp-namefrob.h: New file, from glibc.
26519         * lib/argp-parse.c: New file, from glibc.
26520         * lib/argp-pv.c: New file, from glibc.
26521         * lib/argp-pvh.c: New file, from glibc.
26522         * lib/argp-xinl.c: New file, from glibc.
26523
26524 2003-06-10  Simon Josefsson  <jas@extundo.com>
26525
26526         * modules/strchrnul: New file.
26527
26528 2003-06-10  Simon Josefsson  <jas@extundo.com>
26529
26530         * modules/argp: New file.
26531
26532 2003-06-10  Simon Josefsson  <jas@extundo.com>
26533
26534         * m4/strchrnul.m4: New file.
26535
26536 2003-06-10  Simon Josefsson  <jas@extundo.com>
26537
26538         * lib/strchrnul.h: New file.
26539         * lib/strchrnul.c: New file.
26540
26541 2003-06-10  Bruno Haible  <bruno@clisp.org>
26542
26543         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
26544
26545 2003-06-07  Karl Berry  <karl@gnu.org>
26546
26547         * config/config.{guess,sub}: update from prep.
26548
26549 2003-06-07  Jim Meyering  <jim@meyering.net>
26550
26551         * modules/strtod: Use $(...) notation, not @...@ for
26552         AC_REPLACE'd variables.
26553         * modules/localcharset: Likewise.
26554
26555 2003-06-07  Jim Meyering  <jim@meyering.net>
26556
26557         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
26558         in place of my name in the copyright comment.
26559         Remove definition and uses of __P.
26560
26561         From coreutils.
26562         * lib/stat.c: Don't declare xmalloc explicitly.
26563         Instead, include "xalloc.h".
26564         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
26565         xrealloc, and xcalloc return values.
26566         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
26567         Improve comment.
26568         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
26569
26570 2003-06-07  Bruno Haible  <bruno@clisp.org>
26571
26572         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
26573         avoid AC_CONFIG_LINKS.
26574         * modules/fnmatch (Makefile.am): Use explicit creation rule for
26575         fnmatch.h, to avoid AC_CONFIG_LINKS.
26576         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
26577
26578 2003-06-07  Bruno Haible  <bruno@clisp.org>
26579
26580         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
26581         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
26582         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
26583         directory.
26584         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
26585         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
26586         directory.
26587
26588 2003-06-06  Jim Meyering  <jim@meyering.net>
26589
26590         Merge from coreutils.
26591         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
26592         Consolidate declarations and initializations of *_base* locals.
26593
26594         Merge from coreutils.
26595         This avoids a core dump on systems without GNU putenv,
26596         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
26597         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
26598         (unsetenv): New static function, from GNU libc.
26599         (rpl_putenv): Use it.
26600
26601         * lib/modechange.c: Remove trailing blanks.
26602
26603         Merge from coreutils.
26604         * lib/fsusage.c: Remove declaration of statfs.
26605         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
26606
26607         * lib/posixtm.c: Include <stdbool.h> unconditionally.
26608
26609 2003-06-06  Jim Meyering  <jim@meyering.net>
26610
26611         * lib/stdbool_.h: Renamed from stdbool.h.in.
26612
26613 2003-06-06  Jim Meyering  <jim@meyering.net>
26614             Bruno Haible  <bruno@clisp.org>
26615
26616         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
26617         Adjust Makefile.am snippet not to redirect directly to target.
26618         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
26619
26620 2003-06-05  Paul Eggert  <eggert@twinsun.com>
26621
26622         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
26623         mismatch, look in future quarters as well as past.  This fixes a
26624         bug when processing fall-backwards gaps immediately after a long
26625         period of daylight-saving time.
26626
26627         * lib/mktime.c: Assume freestanding C89 or better.
26628         (HAVE_LIMITS_H): Remove.  Assume it's 1.
26629         (__P): Remove; not used.
26630         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
26631         (mktime, not_equal_tm, print_tm, check_result,
26632         main): Use prototypes.  Use const * where appropriate.
26633         (main): Fix typo in testing code that uncovered by above changes.
26634         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
26635
26636 2003-06-04  Paul Eggert  <eggert@twinsun.com>
26637
26638         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
26639         locale.h, localeconv.  This merges changes from coreutils.
26640
26641         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
26642         It can be removed after the next Autoconf is released.
26643         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
26644         needed.
26645
26646 2003-06-04  Paul Eggert  <eggert@twinsun.com>
26647
26648         * lib/mktime.c: Fix Debian bug 177940
26649         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
26650         (localtime_offset): Now long int, not time_t, because we want it
26651         to be guaranteed to be signed.  All uses changed.
26652         (__mktime_internal): If overflow would occur when adding offset,
26653         don't add it.
26654
26655         Merge 'human' changes from coreutils.  Rewrite to support
26656         locale-specific notations like thousands separators.
26657         * lib/human.c: Simplify authorship notice.
26658         Include human.h immediately after config.h.
26659         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
26660         <limits.h>: Do not include, since human.h does.
26661         (SIZE_MAX, UINTMAX_MAX): New macros.
26662         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
26663         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
26664         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
26665         (power_letter): Renamed from suffixes.
26666         (generate_suffix_backwards): Remove.
26667         (adjust_value): Now takes int style (because of human.h changes)
26668         and long double value (for greater precision on some platforms).
26669         (group_number): New function.
26670         (human_readable): Use it.  Use integer options, not enum.
26671         Put the options before the sizes in the arg list.
26672         Support all the new options.
26673         The old human_readable function has been removed;
26674         use inttostr.h instead.
26675         (human_readable, default_block_size, humblock):
26676         Use uintmax_t, not int, for block sizes.
26677         (human_readable_inexact, block_size_types): Remove.
26678         (block_size_opts): New constant.
26679         (human_options): Renamed from human_block_size, with new signature
26680         that allows block sizes up to UINTMAX_MAX.  All callers changed.
26681         * lib/human.h: Add copyright and authorship notice.
26682         Include <limits.h> and <stdbool.h> unconditionally.
26683         (PARAMS): Remove.  All uses removed.
26684         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
26685         (enum human_inexact_style): Remove tag; now a nameless enum.
26686         (human_floor, human_ceiling, human_round_to_even): Now have
26687         values 2, 0, 1 rather than -1, 1, 0.
26688         (human_group_digits, human_suppress_point_zero, human_autoscale,
26689         human_base_1024, human_SI, human_B): New constants.
26690         (human_readable_inexact, human_block_size): Remove.
26691         (human_readable): Size args are now uintmax_t, not int.
26692         (human_options): New decl.
26693
26694         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
26695         unnecessary now that we assume C89 or better.  This change
26696         imported from coreutils.
26697
26698         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
26699         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
26700         in the 2003-05-30 sync from glibc.
26701
26702         .h files should stand alone, but we shouldn't include <sys/types.h>
26703         if we can get away with just <stddef.h>.
26704
26705         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
26706         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
26707         rather than <sys/types.h>, as we merely need size_t.
26708         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
26709         to get size_t.
26710         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
26711         Include <stdio.h>, to get FILE.
26712         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
26713         memcasecmp.h has included <stddef.h> and all we need is size_t.
26714         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
26715         our interface, instead of including <sys/types.h>
26716
26717 2003-06-04  Paul Eggert  <eggert@twinsun.com>
26718
26719         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
26720         now, as glibc mktime is buggy on non-glibc systems.
26721
26722 2003-06-03  Karl Berry  <karl@gnu.org>
26723
26724         * config/config.sub: update from prep.
26725
26726 2003-06-02  Paul Eggert  <eggert@twinsun.com>
26727
26728         [from coreutils]
26729         Fix some minor time-related bugs with POSIX time arguments.
26730         Some valid time stamps were being rejected (notably -1, and
26731         time stamps before 1900 on 64-bit hosts).  And some invalid
26732         time stamps were being accepted, e.g. September 31.
26733
26734         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
26735         that we can return (time_t) -1 successfully.
26736         * lib/posixtm.c: Likewise.
26737         [HAVE_STDBOOL_H]: Include <stdbool.h>.
26738         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
26739         (t): Remove static var.
26740         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
26741         of static var.  All uses changed.
26742         (year): Do not reject years before 1900; they can occur with
26743         64-bit time_t.
26744         (posix_time_parse): Do not check for out-of-range components;
26745         that is now the caller's responsibility, since our checks were
26746         only approximations.
26747         (posixtime): Use mktime to check for out-of-range components,
26748         since it knows them exactly.
26749         If mktime returns (time_t) -1, check whether an error actually occurred
26750         by invoking localtime on -1.
26751         (main) [TEST_POSIXTIME]: Check for input data errors, and report
26752         posixtime failures better.
26753         Improve the test data (in comments only).
26754
26755 2003-06-02  Karl Berry  <karl@gnu.org>
26756
26757         * config/mkinstalldirs (version): new variable.
26758         (--version): new option.
26759         (usage): improve message.
26760
26761 2003-05-30  Karl Berry  <karl@gnu.org>
26762
26763         * lib/mktime.c: update from libc.
26764
26765 2003-05-30  Bruno Haible  <bruno@clisp.org>
26766
26767         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
26768         * config/config.rpath: Upgrade to gettext-0.12.1.
26769
26770 2003-05-30  Bruno Haible  <bruno@clisp.org>
26771
26772         * m4/gettext.m4: Upgrade to gettext-0.12.1.
26773         * m4/nls.m4: New file, from gettext-0.12.1.
26774         * m4/po.m4: New file, from gettext-0.12.1.
26775         * m4/progtest.m4: Upgrade to gettext-0.12.1.
26776
26777 2003-05-30  Bruno Haible  <bruno@clisp.org>
26778
26779         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
26780         * lib/localcharset.h: Likewise.
26781         * lib/localcharset.c: Likewise.
26782
26783 2003-05-29  Karl Berry  <karl@gnu.org>
26784
26785         * config/config.rpath: update from gettext.
26786
26787 2003-05-28  Paul Eggert  <eggert@twinsun.com>
26788
26789         Assume the headers required for C89 freestanding compilers.
26790         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
26791         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
26792         * m4/human.m4 (gl_HUMAN): Likewise.
26793         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
26794         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
26795         * m4/userspec.m4 (gl_USERSPEC): Likewise.
26796         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
26797         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
26798         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
26799
26800 2003-05-28  Paul Eggert  <eggert@twinsun.com>
26801
26802         Assume the headers required for C89 freestanding compilers.
26803         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
26804         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
26805         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
26806         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
26807         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
26808         define, since <limits.h> is guaranteed to do that.
26809         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
26810         * lib/exclude.c: Include <stdbool.h> unconditionally.
26811         * lib/tempname.c: Include <stddef.h> unconditionally.
26812         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
26813         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
26814         <stddef.h> does that.
26815         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
26816         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
26817         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
26818         needed.
26819         * lib/xstrtol.c: Likewise.
26820         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
26821         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
26822
26823         * lib/addext.c (addext): Use assignment rather than cast, to avoid
26824         warnings on some platforms.
26825
26826         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
26827         arbitrarily.
26828
26829 2003-05-26  Jim Meyering  <jim@meyering.net>
26830
26831         Merge in a change from coreutils:
26832         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
26833         that is guaranteed to be `no'.  Use `no_such_member' to indicate
26834         that condition, rather than `-1' which is slightly misleading.
26835         Change the name of the cache variable to have the gl_ prefix.
26836         Prompted by a patch from Richard Dawe for DJGPP.
26837
26838 2003-05-24  Karl Berry  <karl@gnu.org>
26839
26840         * config/config.guess: update from prep.
26841
26842 2003-05-22  Karl Berry  <karl@gnu.org>
26843
26844         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
26845
26846 2003-05-20  Karl Berry  <karl@gnu.org>
26847
26848         * config/config.guess: update from prep.
26849
26850 2003-05-18  Karl Berry  <karl@gnu.org>
26851
26852         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
26853         might actually be set by the user.
26854
26855         * config/depcomp, install-sh, mdate-sh: update from automake.
26856
26857 2003-05-17  Bruno Haible  <bruno@clisp.org>
26858
26859         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
26860         invalid expansion for AC_EGREP_CPP.
26861         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
26862         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
26863         Suggested by Akim Demaille <akim@epita.fr> in
26864         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
26865
26866 2003-05-12  Jim Meyering  <jim@meyering.net>
26867
26868         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
26869         the space-padded-by-default conversion specifiers, %e, %k, %l.
26870
26871 2003-05-12  Bruno Haible  <bruno@clisp.org>
26872
26873         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
26874         the string is longer than 4 KB.
26875
26876 2003-05-11  Karl Berry  <karl@gnu.org>
26877
26878         * config/config.{guess,sub}: update from prep.
26879
26880 2003-05-09  Bruno Haible  <bruno@clisp.org>
26881
26882         * modules/error: Add m4/strerror_r.m4 to file list.
26883
26884 2003-05-03  Bruno Haible  <bruno@clisp.org>
26885
26886         Upgrade to Unicode-4.0.
26887         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
26888         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
26889         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
26890         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
26891         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
26892         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
26893         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
26894         Change width of U+E0100..U+E01EF from 1 to 0.
26895
26896 2003-04-25  Jim Meyering  <jim@meyering.net>
26897
26898         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
26899         of type size_t, not int.
26900
26901 2003-04-25  Bruno Haible  <bruno@clisp.org>
26902
26903         * lib/copy-file.c: Include <stddef.h>, for size_t.
26904
26905 2003-04-21  Paul Eggert  <eggert@twinsun.com>
26906
26907         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
26908         code which expansion is under static control.  Patch imported from
26909         Akim Demaille's patch to Bison; see
26910         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
26911
26912 2003-04-14  Bruno Haible  <bruno@clisp.org>
26913
26914         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
26915
26916 2003-04-11  Jim Meyering  <jim@meyering.net>
26917
26918         Merge changes from Coreutils.
26919
26920         2003-03-22  Jim Meyering  <jim@meyering.net>
26921
26922         * lib/strftime.c (widen): Cast alloca return value to proper type.
26923
26924         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
26925
26926         From GNU libc.
26927         * lib/strftime.c (my_strftime): Handle very large width
26928         specifications for numeric values correctly.  Improve checks for
26929         overflow.
26930
26931         2003-01-19  Jim Meyering  <jim@meyering.net>
26932
26933         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
26934         definitions.
26935         (nl_get_alt_digit) [! defined my_strftime]: Define.
26936         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
26937         _nl_get_alt_digit and _nl_get_walt_digit.
26938
26939         * lib/strftime.c (my_strftime): Merge in locale-related changes from
26940         libc. These changes have no effect outside of _LIBC.
26941
26942 2003-04-10  Bruno Haible  <bruno@clisp.org>
26943
26944         * modules/findprog: New file.
26945         * MODULES.html.sh (func_all_modules): Add it.
26946
26947 2003-04-10  Bruno Haible  <bruno@clisp.org>
26948
26949         * m4/findprog.m4: New file.
26950         * m4/eaccess.m4: New file.
26951
26952 2003-04-10  Bruno Haible  <bruno@clisp.org>
26953
26954         * lib/findprog.h: New file, from GNU gettext.
26955         * lib/findprog.c: New file, from GNU gettext.
26956
26957 2003-04-05  Jim Meyering  <jim@meyering.net>
26958
26959         Merge changes from Coreutils.
26960
26961         * lib/exclude.h (PARAMS): Remove definition and uses.
26962         * lib/exclude.c: Remove uses of `PARAMS'.
26963
26964         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
26965         Add test-cases for DOS filenames. Declare program_name.
26966         (main): Set up program_name.  Patch by Rich Dawe.
26967
26968         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
26969         error from mntctl.
26970         Use mntctl's return value to drive the entry-processing loop, since
26971         we can't rely on the value of the vmt_length member in the last
26972         entry.  On some systems doing so could result in exhausting
26973         virtual memory.  Based in part on a patch from Mike Jetzer.
26974
26975 2003-04-04  Bruno Haible  <bruno@clisp.org>
26976
26977         * modules/linebreak: New file.
26978         * MODULES.html.sh (func_all_modules): Add it.
26979
26980 2003-04-04  Bruno Haible  <bruno@clisp.org>
26981
26982         * m4/linebreak.m4: New file.
26983
26984 2003-04-04  Bruno Haible  <bruno@clisp.org>
26985
26986         * lib/linebreak.h: New file, from GNU gettext.
26987         * lib/linebreak.c: New file, from GNU gettext with slight
26988         modifications.
26989         * lib/lbrkprop.h: New file, from GNU gettext.
26990
26991 2003-04-03  Bruno Haible  <bruno@clisp.org>
26992
26993         * modules/utf8-ucs4: New file.
26994         * modules/utf16-ucs4: New file.
26995         * modules/ucs4-utf8: New file.
26996         * modules/ucs4-utf16: New file.
26997         * MODULES.html.sh (func_all_modules): Add them.
26998
26999 2003-04-03  Bruno Haible  <bruno@clisp.org>
27000
27001         * m4/utf-ucs4.m4: New file.
27002         * m4/ucs4-utf.m4: New file.
27003
27004 2003-04-03  Bruno Haible  <bruno@clisp.org>
27005
27006         * lib/utf8-ucs4.h: New file, from GNU gettext.
27007         * lib/utf16-ucs4.h: New file, from GNU gettext.
27008         * lib/ucs4-utf8.h: New file, from GNU gettext.
27009         * lib/ucs4-utf16.h: New file, from GNU gettext.
27010
27011 2003-04-02  Bruno Haible  <bruno@clisp.org>
27012
27013         * modules/binary-io: New file.
27014         * MODULES.html.sh (func_all_modules): Add it.
27015
27016 2003-04-02  Bruno Haible  <bruno@clisp.org>
27017
27018         * lib/binary-io.h: New file, from GNU gettext.
27019
27020 2003-04-01  Bruno Haible  <bruno@clisp.org>
27021
27022         * modules/pathname: New file.
27023         * MODULES.html.sh (func_all_modules): Add it.
27024
27025 2003-04-01  Bruno Haible  <bruno@clisp.org>
27026
27027         * lib/pathname.h: New file, from GNU gettext.
27028         * lib/concatpath.c: New file, from GNU gettext.
27029
27030 2003-03-30  Bruno Haible  <bruno@clisp.org>
27031
27032         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
27033
27034 2003-03-30  Bruno Haible  <bruno@clisp.org>
27035
27036         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
27037         function chown() doesn't exist.
27038
27039 2003-03-28  Bruno Haible  <bruno@clisp.org>
27040
27041         * modules/copy-file: New file.
27042         * MODULES.html.sh (func_all_modules): Add it.
27043
27044 2003-03-28  Bruno Haible  <bruno@clisp.org>
27045
27046         * m4/copy-file.m4: New file.
27047
27048 2003-03-28  Bruno Haible  <bruno@clisp.org>
27049
27050         * lib/copy-file.h: New file, from GNU gettext.
27051         * lib/copy-file.c: New file, from GNU gettext.
27052
27053 2003-03-18  Jim Meyering  <jim@meyering.net>
27054
27055         * lib/quote.c (quote_n): Fix typo in comment.
27056
27057 2003-03-18  Bruno Haible  <bruno@clisp.org>
27058
27059         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
27060         checking.
27061         * m4/onceonly_2_57.m4: Likewise.
27062
27063 2003-03-17  Bruno Haible  <bruno@clisp.org>
27064
27065         * m4/onceonly.m4: Require autoconf 2.54 or newer.
27066         (m4_quote): Remove macro.
27067         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
27068
27069 2003-03-14  Jim Meyering  <jim@meyering.net>
27070
27071         Merge changes from Coreutils.
27072         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
27073         to be const, in order to avoid warnings.
27074         (obstack_room): Likewise.
27075         (obstack_empty_p): Likewise.
27076
27077 2003-03-14  Bruno Haible  <bruno@clisp.org>
27078
27079         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
27080         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
27081
27082 2003-03-13  Paul Eggert  <eggert@twinsun.com>
27083
27084         Merge changes from Bison.
27085         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
27086         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
27087         when compiling Bison 1.875's `bitset bset = obstack_alloc
27088         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
27089         * lib/hash.c: Include <stdbool.h> unconditionally.
27090
27091 2003-03-13  Paul Eggert  <eggert@twinsun.com>
27092
27093         * m4/onceonly.m4 (m4_quote): New macro.
27094         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
27095         Quote AC_FOREACH variable-expansions properly.
27096
27097 2003-03-13  Paul Eggert  <eggert@twinsun.com>
27098
27099         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
27100
27101 2003-03-09  Paul Eggert  <eggert@twinsun.com>
27102
27103         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
27104         Reported by Bruce Becker; see:
27105         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
27106
27107 2003-03-03  Paul Eggert  <eggert@twinsun.com>
27108             Bruno Haible  <bruno@clisp.org>
27109
27110         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
27111         Reported by John Hughes, see
27112         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
27113
27114 2003-02-20  Bruno Haible  <bruno@clisp.org>
27115
27116         * MODULES.html.sh (func_all_modules): Add poll.
27117
27118 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
27119
27120         * modules/poll: New file.
27121
27122 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
27123
27124         * lib/poll_.h: New file.
27125         * lib/poll.c: New file.
27126
27127 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
27128
27129         * m4/poll.m4: New file.
27130
27131 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
27132
27133         * modules/mathl: New file.
27134
27135 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
27136
27137         * lib/mathl.h: New file.
27138         * lib/acosl.c: New file.
27139         * lib/asinl.c: New file.
27140         * lib/atanl.c: New file.
27141         * lib/ceill.c: New file.
27142         * lib/cosl.c: New file.
27143         * lib/expl.c: New file.
27144         * lib/floorl.c: New file.
27145         * lib/frexpl.c: New file.
27146         * lib/ldexpl.c: New file.
27147         * lib/logl.c: New file.
27148         * lib/sincosl.c: New file.
27149         * lib/sinl.c: New file.
27150         * lib/sqrtl.c: New file.
27151         * lib/tanl.c: New file.
27152         * lib/trigl.c: New file.
27153         * lib/trigl.h: New file.
27154
27155 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
27156
27157         * m4/mathl.m4: New file.
27158
27159 2003-02-18  Bruno Haible  <bruno@clisp.org>
27160
27161         * MODULES.html.sh (func_all_modules): Add mathl.
27162
27163 2003-02-17  Bruno Haible  <bruno@clisp.org>
27164
27165         * modules/mkdtemp: New module.
27166         * MODULES.html.sh (func_all_modules): Add it.
27167
27168 2003-02-17  Bruno Haible  <bruno@clisp.org>
27169
27170         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
27171
27172 2003-02-17  Bruno Haible  <bruno@clisp.org>
27173
27174         * lib/mkdtemp.h: New file, from GNU gettext.
27175         * lib/mkdtemp.c: New file, from GNU gettext.
27176
27177 2003-02-02  Jim Meyering  <jim@meyering.net>
27178
27179         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
27180         e.g. glibc-2.2.93.
27181
27182 2003-01-31  Bruno Haible  <bruno@clisp.org>
27183
27184         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
27185         'rpl_rename'.
27186         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
27187         'rpl_strnlen'.
27188         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
27189         'rpl_strtod'.
27190         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
27191         'rpl_utime'.
27192
27193 2003-01-31  Bruno Haible  <bruno@clisp.org>
27194
27195         * lib/rename.c: #undef rename before defining rpl_rename.
27196         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
27197
27198 2003-01-30  Bruno Haible  <bruno@clisp.org>
27199
27200         * modules/vasnprintf, modules/vasprintf: New modules.
27201         * MODULES.html.sh (func_all_modules): Add them.
27202
27203 2003-01-30  Bruno Haible  <bruno@clisp.org>
27204
27205         * m4/signed.m4: New file, from GNU gettext.
27206         * m4/longdouble.m4: New file, from GNU gettext.
27207         * m4/wchar_t.m4: New file, from GNU gettext.
27208         * m4/wint_t.m4: New file, from GNU gettext.
27209         * m4/vasnprintf.m4: New file.
27210         * m4/vasprintf.m4: New file.
27211
27212 2003-01-30  Bruno Haible  <bruno@clisp.org>
27213
27214         * lib/printf-args.h: New file, from GNU gettext.
27215         * lib/printf-args.c: New file, from GNU gettext.
27216         * lib/printf-parse.h: New file, from GNU gettext.
27217         * lib/printf-parse.c: New file, from GNU gettext.
27218         * lib/vasnprintf.h: New file, from GNU gettext.
27219         * lib/vasnprintf.c: New file, from GNU gettext.
27220         * lib/asnprintf.c: New file, from GNU gettext.
27221         * lib/vasprintf.h: New file, from GNU gettext with modifications.
27222         * lib/vasprintf.c: New file, from GNU gettext.
27223         * lib/asprintf.c: New file, from GNU gettext.
27224
27225 2003-01-29  Bruno Haible  <bruno@clisp.org>
27226
27227         * modules/stpncpy: New module.
27228         * MODULES.html.sh (func_all_modules): Add it.
27229
27230 2003-01-29  Bruno Haible  <bruno@clisp.org>
27231
27232         * m4/stpncpy.m4: New file.
27233
27234 2003-01-29  Bruno Haible  <bruno@clisp.org>
27235
27236         * lib/stpncpy.h: New file, from GNU gettext with modifications.
27237         * lib/stpncpy.c: New file, from GNU gettext with modifications.
27238
27239 2003-01-28  Bruno Haible  <bruno@clisp.org>
27240
27241         * modules/c-ctype: New module.
27242         * MODULES.html.sh (func_all_modules): Add it.
27243
27244 2003-01-28  Bruno Haible  <bruno@clisp.org>
27245
27246         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
27247         Paul Eggert.
27248         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
27249         Paul Eggert.
27250
27251 2003-01-27  Bruno Haible  <bruno@clisp.org>
27252
27253         * modules/xsetenv: New module.
27254         * MODULES.html.sh (func_all_modules): Add it.
27255
27256 2003-01-27  Bruno Haible  <bruno@clisp.org>
27257
27258         * lib/xsetenv.h: New file, from GNU gettext.
27259         * lib/xsetenv.c: New file, from GNU gettext.
27260
27261 2003-01-23  Jim Meyering  <jim@meyering.net>
27262
27263         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
27264         from working on systems without dirfd (at least Irix and OSF1/Tru64).
27265
27266 2003-01-23  Bruno Haible  <bruno@clisp.org>
27267
27268         * modules/minmax: New module.
27269         * MODULES.html.sh (func_all_modules): Add it.
27270
27271 2003-01-23  Bruno Haible  <bruno@clisp.org>
27272
27273         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
27274         Eggert.
27275
27276 2003-01-22  Bruno Haible  <bruno@clisp.org>
27277
27278         * modules/exit: New module.
27279         * MODULES.html.sh (func_all_modules): Add it.
27280
27281 2003-01-22  Bruno Haible  <bruno@clisp.org>
27282
27283         * lib/exit.h: New file, from GNU gettext.
27284
27285 2003-01-19  Bruno Haible  <bruno@clisp.org>
27286
27287         * gnulib-tool: Recognize option --extract-maintainer.
27288         (func_get_maintainer): New function.
27289         * modules/*: Add Maintainer entry.
27290
27291 2003-01-16  Jim Meyering  <jim@meyering.net>
27292
27293         * m4/regex.m4: The `regex' struct is both input and output.
27294         Initialize it before each use.  Patch by Tim Waugh.
27295
27296 2003-01-16  Bruno Haible  <bruno@clisp.org>
27297
27298         * MODULES.html.sh: Add a table of contents. Add the module name as
27299         leftmost column. Add hyperlinks.
27300
27301 2003-01-15  Bruno Haible  <bruno@clisp.org>
27302
27303         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
27304
27305 2003-01-15  Bruno Haible  <bruno@clisp.org>
27306
27307         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
27308         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
27309         suffix.
27310
27311 2003-01-15  Bruno Haible  <bruno@clisp.org>
27312
27313         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
27314
27315 2003-01-15  Bruno Haible  <bruno@clisp.org>
27316
27317         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
27318         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
27319
27320 2003-01-14  Jim Meyering  <jim@meyering.net>
27321
27322         * lib/same.c (same_name): Tweak a comment.
27323
27324 2003-01-14  Bruno Haible  <bruno@clisp.org>
27325
27326         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
27327         when a string comparison is sufficient.
27328
27329 2003-01-14  Bruno Haible  <bruno@clisp.org>
27330
27331         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
27332         'unsigned int'.
27333
27334 2003-01-14  Bruno Haible  <bruno@clisp.org>
27335
27336         * lib/hash-pjw.c: Add comment about low quality of this function.
27337
27338 2003-01-13  Bruno Haible  <bruno@clisp.org>
27339
27340         * modules/stpcpy: Distribute lib/stpcpy.h.
27341         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
27342
27343 2003-01-13  Bruno Haible  <bruno@clisp.org>
27344
27345         * modules/*: Add a description.
27346         * modules/strpbrk: Fix Makefile.am snippet.
27347         * modules/strtoimax: Fix dependencies.
27348         * modules/strtoumax: Likewise.
27349
27350 2003-01-13  Bruno Haible  <bruno@clisp.org>
27351
27352         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
27353         * modules/alloca (Makefile.am): All object files depend on alloca.h.
27354         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
27355
27356 2003-01-13  Bruno Haible  <bruno@clisp.org>
27357
27358         * gnulib-tool (func_create_testdir): Store config/* files in the main
27359         directory.
27360         * config.rpath: Move to ...
27361         * config/config.rpath: ... here.
27362         * modules/gettext: Contains config/config.rpath, not config.rpath.
27363         * modules/iconv: Likewise.
27364
27365 2003-01-12  Paul Eggert  <eggert@twinsun.com>
27366
27367         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
27368         to avoid collisions with libcurses and libreadline.
27369
27370         * m4/getstr.m4: Remove.
27371         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
27372
27373 2003-01-12  Paul Eggert  <eggert@twinsun.com>
27374
27375         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
27376         to avoid collisions with libcurses and libreadline.
27377
27378         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
27379         * lib/getstr.h, getstr.c: Remove.
27380         * lib/getline.c: Include "getline.h", to check interface.
27381         Move body of old getstr.c here: this defines MIN_CHUNK and
27382         declares getdelim2, which is renamed from getstr.
27383         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
27384
27385         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
27386         All uses changed.
27387         * lib/linebuffer.h: Likewise.
27388         (readline): Remove backward-compatibility macro.
27389
27390 2003-01-12  Paul Eggert  <eggert@twinsun.com>
27391
27392         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
27393         to avoid collisions with libcurses and libreadline.
27394         * getstr: Remove.
27395         * MODULES.html.sh: Remove getstr.
27396         * modules/getline: Depend on unlocked-io, not getstr.
27397
27398 2003-01-12  Jim Meyering  <jim@meyering.net>
27399
27400         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
27401
27402 2003-01-10  Bruno Haible  <bruno@clisp.org>
27403
27404         * modules/alloca: Change Makefile.am requirements. Simplify Include
27405         requirements. Add lib/alloca_.h to file list.
27406
27407 2003-01-10  Bruno Haible  <bruno@clisp.org>
27408
27409         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
27410
27411 2003-01-10  Bruno Haible  <bruno@clisp.org>
27412
27413         * lib/alloca_.h: New file.
27414         * lib/getdate.y: Unconditionally include alloca.h.
27415         * lib/makepath.c: Likewise.
27416         * lib/setenv.c: Likewise.
27417         * lib/userspec.c: Likewise.
27418
27419 2003-01-09  Karl Berry  <karl@gnu.org>
27420
27421         * MODULES.html.sh: include `dirname $0` in PATH, to find
27422         gnulib-tool.
27423
27424 2003-01-09  Bruno Haible  <bruno@clisp.org>
27425
27426         * modules/stdbool: Change configure.ac, Makefile.am requirements.
27427         Simplify Include requirements. Add lib/stdbool.h.in to file list.
27428
27429 2003-01-09  Bruno Haible  <bruno@clisp.org>
27430
27431         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
27432
27433 2003-01-09  Bruno Haible  <bruno@clisp.org>
27434
27435         * lib/stdbool.h.in: New file.
27436
27437 2003-01-09  Bruno Haible  <bruno@clisp.org>
27438
27439         * gnulib-tool (func_all_modules): Ignore files ending in ~.
27440         * MODULES.html.sh: Likewise.
27441
27442 2003-01-08  Jim Meyering  <jim@meyering.net>
27443
27444         * lib/full-write.c: Undefine and define-away `const' after inclusion
27445         of errno.h, not before.  Suggestion from Bruno Haible.
27446
27447 2003-01-08  Bruno Haible  <bruno@clisp.org>
27448
27449         * modules/full-read: Depend on full-write.
27450
27451 2003-01-08  Bruno Haible  <bruno@clisp.org>
27452
27453         * lib/safe-read.c: Include specification header first, to ensure its
27454         selfcontainedness.
27455         * lib/full-write.c: Likewise.
27456
27457 2003-01-07  Jim Meyering  <jim@meyering.net>
27458
27459         * lib/full-write.c: Rework so that it may serve to define full_read,
27460         too.
27461         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
27462
27463 2003-01-07  Bruno Haible  <bruno@clisp.org>
27464
27465         * lib/strtoimax.c: Include <stdint.h> as an alternative to
27466         <inttypes.h>.
27467         * lib/xstrtol.h: Likewise.
27468         * lib/xstrtoimax.c: Likewise.
27469         * lib/xstrtoumax.c: Likewise.
27470         * lib/human.h: Likewise.
27471
27472         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
27473         on systems that have <inttypes.h> but not <stdint.h>.
27474
27475 2003-01-07  Bruno Haible  <bruno@clisp.org>
27476
27477         * MODULES.html.sh: Add copyright notice.
27478         (missed_files): Omit CVS directory entries.
27479         (func_module): Make it work with sed-3.02.
27480         * MODULES.txt: Remove file.
27481
27482 2003-01-06  Jim Meyering  <jim@meyering.net>
27483
27484         * lib/version-etc.c: Update year in translatable copyright string.
27485
27486 2003-01-03  Karl Berry  <karl@gnu.org>
27487
27488         * config/config.{guess,sub}: update from prep.
27489
27490 2003-01-02  Karl Berry  <karl@gnu.org>
27491
27492         * doc/COPYING.DOC: belatedly updated to 1.2.
27493
27494 2003-01-01  Karl Berry  <karl@gnu.org>
27495
27496         * gnulib-tool (func_verify_module): report module name $module in
27497         error message, not $1.
27498         * gnulib-tool (create-testdir): don't complain if destdir couldn't
27499         be created, only if it doesn't exist.
27500         * gnulib-tool (last_checkin_date): don't expand the $Date here.
27501
27502 2002-12-31  Paul Eggert  <eggert@twinsun.com>
27503
27504         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
27505
27506 2002-12-31  Paul Eggert  <eggert@twinsun.com>
27507
27508         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
27509         memcmp if strcoll doesn't work.
27510
27511 2002-12-31  Bruno Haible  <bruno@clisp.org>
27512
27513         * lib/utime.c (utime_null): No need to call ftruncate if the file was
27514         nonempty.
27515
27516 2002-12-31  Bruno Haible  <bruno@clisp.org>
27517
27518         * lib/memcoll.c (STRCOLL): New macro.
27519         (memcoll): Use it.
27520
27521 2002-12-31  Bruno Haible  <bruno@clisp.org>
27522
27523         * lib/localcharset.h: New file.
27524         * lib/localcharset.c: Include it.
27525         * lib/unicodeio.c: Likewise.
27526
27527 2002-12-31  Bruno Haible  <bruno@clisp.org>
27528
27529         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
27530         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
27531
27532 2002-12-31  Bruno Haible  <bruno@clisp.org>
27533
27534         * lib/getline.h: Include <stddef.h>, for size_t.
27535
27536         * lib/unicodeio.h: Include <stddef.h>, for size_t.
27537         * lib/unicodeio.c: Don't include <stddef.h>.
27538
27539 2002-12-31  Bruno Haible  <bruno@clisp.org>
27540
27541         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
27542         HAVE_TM_ZONE.
27543
27544 2002-12-24  Karl Berry  <karl@gnu.org>
27545
27546         * config/config.guess: update from prep.
27547
27548 2002-12-24  Bruno Haible  <bruno@clisp.org>
27549
27550         General infrasructure.
27551         * m4/README: Rewritten.
27552         * m4/onceonly.m4: New file.
27553         * m4/onceonly_2_57.m4: New file.
27554
27555         Module atexit.
27556         * m4/atexit.m4: New file.
27557
27558         Module strtod.
27559         * m4/strtod.m4: New file.
27560
27561         Module strtol.
27562         * m4/strtol.m4: New file.
27563
27564         Module strtoul.
27565         * m4/strtoul.m4: New file.
27566
27567         Module memchr.
27568         * m4/memchr.m4: New file.
27569
27570         Module memcmp.
27571         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
27572         (jm_FUNC_MEMCMP): Invoke it.
27573
27574         Module memcpy.
27575         * m4/memcpy.m4: New file.
27576
27577         Module memmove.
27578         * m4/memmove.m4: New file.
27579
27580         Module memset.
27581         * m4/memset.m4: New file.
27582
27583         Module strcspn.
27584         * m4/strcspn.m4: New file.
27585
27586         Module strpbrk.
27587         * m4/strpbrk.m4: New file.
27588
27589         Module strstr.
27590         * m4/strstr.m4: New file.
27591
27592         Module strerror.
27593         * m4/strerror.m4: New file.
27594
27595         Module mktime.
27596         * m4/mktime.m4: Renamed from jm-mktime.m4.
27597         (gl_PREREQ_MKTIME): New macro.
27598         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
27599
27600         Module malloc.
27601         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
27602         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
27603         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
27604
27605         Module realloc.
27606         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
27607         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
27608         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
27609
27610         Module strftime.
27611         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
27612         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
27613         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
27614         gl_TM_GMTOFF.
27615         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
27616
27617         Module xalloc.
27618         * m4/xalloc.m4: New file.
27619
27620         Module alloca.
27621         * m4/alloca.m4: New file.
27622
27623         Module putenv.
27624         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
27625         (jm_FUNC_PUTENV): Invoke it.
27626
27627         Module setenv.
27628         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
27629         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
27630         when invoked twice.
27631         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
27632         gt_FUNC_SETENV.
27633
27634         Module memrchr.
27635         * m4/memrchr.m4: New file.
27636
27637         Module stpcpy.
27638         * m4/stpcpy.m4: New file.
27639
27640         Module strcase.
27641         * m4/strcase.m4: New file.
27642
27643         Module strdup.
27644         * m4/strdup.m4: New file.
27645
27646         Module strnlen.
27647         * m4/strnlen.m4: New file.
27648
27649         Module strndup.
27650         * m4/strndup.m4: New file.
27651
27652         Module xstrtod.
27653         * m4/xstrtod.m4: New file.
27654
27655         Module xstrtol.
27656         * m4/xstrtol.m4: New file.
27657
27658         Module getdate.
27659         * m4/getdate.m4: New file.
27660
27661         Module unlocked-io.
27662         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
27663         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
27664         * m4/jm-glibc-io.m4n: Remove file.
27665
27666         Module long-options.
27667         * m4/long-options.m4: New file.
27668
27669         Module md5.
27670         * m4/md5.m4: New file.
27671
27672         Module sha.
27673         * m4/sha.m4: New file.
27674
27675         Module getstr.
27676         * m4/getstr.m4: New file.
27677
27678         Module getline.
27679         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
27680         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
27681         <sys/types.h>, for size_t. Use the function name gnu_getline, not
27682         simply getline. Infoke gl_PREREQ_GETLINE.
27683
27684         Module obstack.
27685         * m4/obstack.m4: New file.
27686
27687         Module hash.
27688         * m4/hash.m4: New file.
27689
27690         Module readtokens.
27691         * m4/readtokens.m4: New file.
27692
27693         Module strverscmp.
27694         * m4/strverscmp.m4: New file.
27695
27696         Module stdbool.
27697         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
27698         OSF/1.
27699
27700         Module strtoll.
27701         * m4/strtoll.m4: New file.
27702
27703         Module strtoull.
27704         * m4/strtoull.m4: New file.
27705
27706         Module strtoimax.
27707         * m4/strtoimax.m4: New file.
27708
27709         Module strtoumax.
27710         * m4/strtoumax.m4: New file.
27711
27712         Module xstrtoimax.
27713         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
27714         jm_AC_PREREQ_XSTRTOIMAX.
27715         Moved the strtol prerequisites to strtol.m4.
27716         Moved the strtoll prerequisites to strtoll.m4.
27717         Moved the strtoimax prerequisites to strtoimax.m4.
27718
27719         Module xstrtoumax.
27720         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
27721         jm_AC_PREREQ_XSTRTOUMAX.
27722         Moved the strtoul prerequisites to strtoul.m4.
27723         Moved the strtoull prerequisites to strtoull.m4.
27724         Moved the strtoumax prerequisites to strtoumax.m4.
27725
27726         Module chown.
27727         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
27728         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
27729
27730         Module dup2.
27731         * m4/dup2.m4: New file.
27732
27733         Module ftruncate.
27734         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
27735         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
27736
27737         Module getgroups.
27738         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
27739         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
27740
27741         Module gettimeofday.
27742         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
27743         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
27744         gl_PREREQ_GETTIMEOFDAY.
27745
27746         Module mkdir.
27747         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
27748         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
27749
27750         Module mkstemp.
27751         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
27752         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
27753         jm_AC_TYPE_UINTMAX_T.
27754         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
27755
27756         Module stat.
27757         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
27758         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
27759
27760         Module lstat.
27761         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
27762         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
27763
27764         Module timespec.
27765         * m4/timespec.m4 (gl_TIMESPEC): New macro.
27766         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
27767         * m4/st_mtim.m4: Indentation.
27768
27769         Module nanosleep.
27770         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
27771         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
27772         gl_PREREQ_NANOSLEEP.
27773
27774         Module regex.
27775         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
27776         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
27777         (gl_REGEX): New macro.
27778
27779         Module rename.
27780         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
27781         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
27782
27783         Module rmdir.
27784         * m4/rmdir.m4: New file.
27785
27786         Module utime.
27787         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
27788         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
27789         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
27790
27791         Module dirname.
27792         * m4/dirname.m4: New file.
27793
27794         Module getopt.
27795         * m4/getopt.m4: New file.
27796
27797         Module unistd-safer.
27798         * m4/unistd-safer.m4: New file.
27799
27800         Module fnmatch.
27801         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
27802         declaration.
27803         (gl_PREREQ_FNMATCH_EXTRA): New macro.
27804         (gl_FUNC_FNMATCH_POSIX): New macro.
27805         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
27806         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
27807         simply fnmatch.
27808
27809         Module exclude.
27810         * m4/exclude.m4: New file.
27811
27812         Module human.
27813         * m4/human.m4: New file.
27814
27815         Module acl.
27816         * m4/acl.m4: Nop.
27817
27818         Module backupfile.
27819         * m4/backupfile.m4: New file.
27820         * m4/d-ino.m4: Indentation.
27821
27822         Module fsusage.
27823         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
27824         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
27825         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
27826
27827         Module dirfd.
27828         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
27829         requirements.
27830
27831         Module euidaccess.
27832         * m4/euidaccess.m4: New file.
27833
27834         Module file-type.
27835         * m4/file-type.m4: New file.
27836
27837         Module fileblocks.
27838         * m4/fileblocks.m4: New file.
27839
27840         Module filemode.
27841         * m4/filemode.m4: New file.
27842
27843         Module isdir.
27844         * m4/isdir.m4: New file.
27845
27846         Module lchown.
27847         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
27848         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
27849
27850         Module makepath.
27851         * m4/makepath.m4: New file.
27852
27853         Module modechange.
27854         * m4/modechange.m4: New file.
27855
27856         Module mountlist.
27857         * m4/mountlist.m4: New file.
27858         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
27859         Indentation.
27860
27861         Module path-concat.
27862         * m4/path-concat.m4: New file.
27863
27864         Module pathmax.
27865         * m4/pathmax.m4: New file.
27866
27867         Module same.
27868         * m4/same.m4: New file.
27869
27870         Module save-cwd.
27871         * m4/save-cwd.m4: New file.
27872
27873         Module savedir.
27874         * m4/savedir.m4: New file.
27875
27876         Module xgetcwd.
27877         * m4/xgetcwd.m4: New file.
27878         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
27879
27880         Module xreadlink.
27881         * m4/xreadlink.m4: New file.
27882
27883         Module safe-read.
27884         * m4/safe-read.m4: New file.
27885
27886         Module safe-write.
27887         * m4/safe-write.m4: New file.
27888
27889         Module closeout.
27890         * m4/closeout.m4: New file.
27891
27892         Module stdio-safer.
27893         * m4/stdio-safer.m4: New file.
27894
27895         Module getpass.
27896         * m4/getpass.m4: New file.
27897
27898         Module getugroups.
27899         * m4/getugroups.m4: New file.
27900
27901         Module group-member.
27902         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
27903         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
27904
27905         Module idcache.
27906         * m4/idcache.m4: New file.
27907
27908         Module userspec.
27909         * m4/userspec.m4: New file.
27910
27911         Module gettime.
27912         * m4/clock_time.m4: New file.
27913         * m4/gettime.m4: New file.
27914
27915         Module settime.
27916         * m4/settime.m4: New file.
27917
27918         Module posixtm.
27919         * m4/posixtm.m4: New file.
27920
27921         Module gethostname.
27922         * m4/gethostname.m4: New file.
27923
27924         Module canon-host.
27925         * m4/canon-host.m4: New file.
27926
27927         Module gettext.
27928         * m4/codeset.m4: New file, from gettext-0.11.5.
27929         * m4/gettext.m4: New file, from gettext-0.11.5.
27930         * m4/glibc21.m4: New file, from gettext-0.11.5.
27931         * m4/iconv.m4: New file, from gettext-0.11.5.
27932         * m4/intdiv0.m4: New file, from gettext-0.11.5.
27933         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
27934         * m4/inttypes.m4: New file, from gettext-0.11.5.
27935         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
27936         * m4/isc-posix.m4: New file, from gettext-0.11.5.
27937         * m4/lcmessage.m4: New file, from gettext-0.11.5.
27938         * m4/lib-ld.m4: New file, from gettext-0.11.5.
27939         * m4/lib-link.m4: New file, from gettext-0.11.5.
27940         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
27941         * m4/progtest.m4: New file, from gettext-0.11.5.
27942         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
27943         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
27944         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
27945
27946         Module localcharset.
27947         * m4/localcharset.m4: New file.
27948
27949         Module hard-locale.
27950         * m4/hard-locale.m4: New file.
27951
27952         Module mbswidth.
27953         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
27954         onceonly macros.
27955         * m4/mbrtowc.m4: Add comment.
27956
27957         Module memcasecmp.
27958         * m4/memcasecmp.m4: New file.
27959
27960         Module memcoll.
27961         * m4/memcoll.m4: New file.
27962
27963         Module unicodeio.
27964         * m4/unicodeio.m4: New file.
27965
27966         Module rpmatch.
27967         * m4/rpmatch.m4: New file.
27968
27969         Module yesno.
27970         * m4/yesno.m4: New file.
27971
27972         Module exitfail.
27973         * m4/exitfail.m4: New file.
27974
27975         Module c-stack.
27976         * m4/c-stack.m4 (gl_C_STACK): New macro.
27977         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
27978
27979         Module error.
27980         * m4/error.m4 (gl_ERROR): New macro.
27981         (jm_PREREQ_ERROR): Use onceonly macros.
27982
27983         Module fatal.
27984         * m4/fatal.m4: New file.
27985
27986         Module getloadavg.
27987         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
27988         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
27989
27990         Module getpagesize.
27991         * m4/getpagesize.m4: New file.
27992
27993         Module getusershell.
27994         * m4/getusershell.m4: New file.
27995
27996         Module physmem.
27997         * m4/physmem.m4: New file.
27998
27999         Module posixver.
28000         * m4/posixver.m4: New file.
28001
28002         Module quotearg.
28003         * m4/quotearg.m4: New file.
28004
28005         Module quote.
28006         * m4/quote.m4: New file.
28007
28008         Module readutmp.
28009         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
28010
28011         Module sig2str.
28012         * m4/sig2str.m4: New file.
28013
28014         Other.
28015         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
28016         ulonglong.m4.
28017         * m4/intmax_t.m4: New file.
28018         * m4/d-type.m4: Indentation.
28019         * m4/jm-macros.m4: Update.
28020         * m4/prereq.m4 (jm_PREREQ): Update.
28021         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
28022         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
28023         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
28024         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
28025         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
28026         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
28027         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
28028         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
28029         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
28030         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
28031         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
28032         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
28033         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
28034         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
28035         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
28036         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
28037         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
28038         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
28039         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
28040
28041 2002-12-24  Bruno Haible  <bruno@clisp.org>
28042
28043         * MODULES.txt: Update according to m4/ changes.
28044
28045         Module gettext.
28046         * config.rpath: New file, from gettext-0.11.5.
28047
28048         * modules/*: New module descriptions.
28049         * gnulib-tool: New file.
28050         * MODULES.html.sh: New file.
28051
28052 2002-12-21  Karl Berry  <karl@gnu.org>
28053
28054         * doc/fdl.texi: update to version 1.2.
28055
28056 2002-12-19  Karl Berry  <karl@gnu.org>
28057
28058         * config/config.guess: update from prep.
28059
28060 2002-12-18  Bruno Haible  <bruno@clisp.org>
28061
28062         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
28063         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
28064
28065 2002-12-17  Bruno Haible  <bruno@clisp.org>
28066
28067         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
28068         stdlib.h, string.h.
28069
28070 2002-12-17  Bruno Haible  <bruno@clisp.org>
28071
28072         * lib/canon-host.c (strdup): Remove unused declaration.
28073
28074         * lib/fsusage.c: Include full_read.h.
28075         (get_fs_usage): Use full_read instead of safe_read.
28076
28077         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
28078
28079 2002-12-12  Karl Berry  <karl@gnu.org>
28080
28081         * config/config.guess: update from prep.
28082
28083 2002-12-11  Bruno Haible  <bruno@clisp.org>
28084
28085         * m4/setenv.m4: New file, from gettext-0.11.5.
28086
28087 2002-12-11  Bruno Haible  <bruno@clisp.org>
28088
28089         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
28090         not unsetenv().
28091         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
28092         modifications:
28093
28094         2002-12-11  Bruno Haible  <bruno@clisp.org>
28095
28096                 * setenv.c (alloca): Fall back to malloc.
28097                 (freea): New macro.
28098                 (setenv): Use freea() to free memory allocated with alloca().
28099
28100         2002-11-13  Bruno Haible  <bruno@clisp.org>
28101
28102                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
28103                 function declarations.
28104                 * unsetenv.c (unsetenv): Likewise.
28105
28106         2002-03-04  Bruno Haible  <bruno@clisp.org>
28107
28108                 Portability to AIX 4.3.3.
28109                 * unsetenv.c: New file, extracted from setenv.c.
28110                 * setenv.c: Move the unsetenv() function to unsetenv.c.
28111
28112         2001-12-20  Bruno Haible  <bruno@clisp.org>
28113
28114                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
28115                 use malloc instead. For SunOS 4.
28116
28117         2001-12-11  Bruno Haible  <bruno@clisp.org>
28118
28119                 * setenv.c: Declare alloca.
28120                 (compar_fn_t): New typedef.
28121                 (KNOWN_VALUE, STORE_VALUE): Use it.
28122
28123         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
28124         setenv.h.
28125
28126 2002-12-10  Paul Eggert  <eggert@twinsun.com>
28127
28128         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
28129         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
28130         Choose values that are less likely to collide with system fnmatch
28131         options.
28132         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
28133         defined (e.g., a pure POSIX system).
28134         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
28135         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
28136
28137 2002-12-06  Paul Eggert  <eggert@twinsun.com>
28138
28139         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
28140         a pain in practice to deal with generated m4 files.  This change
28141         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
28142
28143         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
28144         and jm-glibc-io.m4, as they are no longer a special case.
28145         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
28146         kludge and the auto-generation stuff.  Check only whether the
28147         functions are declared, not whether they exist, since older hosts
28148         that don't declare the functions can't use the optimization anyway.
28149
28150 2002-12-06  Jim Meyering  <jim@meyering.net>
28151
28152         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
28153
28154         Merge in changes from libc's misc/error.c, in preparation
28155         for the merge of gnulib's changes back into libc.
28156
28157         * lib/error.c (_): Define only if not already defined.
28158         Move definition to follow all #include directives.
28159         Include unlocked-io.h only if !_LIBC.
28160         [_LIBC]: Include <libio/libioP.h>.
28161         [USE_IN_LIBIO]: Include <libio/iolibio.h>
28162         (fflush): Tweak definition to use INTUSE.
28163         (putc): Define.
28164
28165 2002-12-05  Paul Eggert  <eggert@twinsun.com>
28166
28167         * lib/alloca.c [defined emacs]: Include "lisp.h".
28168         (xalloc_die) [defined emacs]: New macro.
28169         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
28170         [! defined emacs]: Include <xalloc.h>.
28171         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
28172         (pointer): Typedef to POINTER_TYPE *.
28173         (malloc): Remove decl; we now always use xmalloc.
28174         (alloca): Use old-style definition, since Emacs needs this.
28175         Check for arithmetic overflow when computing combined size.
28176
28177 2002-12-04  Paul Eggert  <eggert@twinsun.com>
28178
28179         Do not generate unlocked-io.h automatically, since it's easier to
28180         maintain it by hand.
28181
28182         * lib/unlocked-io.h: New file, from GNU diffutils,
28183         but with proper copyright notice and attribution.
28184         * lib/gen-uio: Remove.
28185         * lib/Makefile.am: Add copyright notice.
28186         (libfetish_a_SOURCES): Add unlocked-io.h.
28187         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
28188         (DISTCLEANFILES, io_functions): Remove macros.
28189         (EXTRA_DIST): Remove gen_uio.
28190         (unlocked-io.h): Remove rule.
28191
28192 2002-12-04  Jim Meyering  <jim@meyering.net>
28193
28194         Reflect the fact that stat.c and lstat.c are no longer generated.
28195         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
28196         (DISTCLEANFILES): Likewise.
28197         (EXTRA_DIST): Likewise.
28198         (all_local): Don't depend on stat.c or lstat.c.
28199         (stat.c, lstat.c): Remove rules.
28200         (EXTRA_DIST): Remove xstat.in.
28201
28202         * lib/xstat.in: Remove file.  Contents moved into stat.c.
28203         * lib/stat.c: New file.  Contents mostly from xstat.in.
28204         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
28205         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
28206
28207         * lib/safe-read.c: Rework so that it may serve to define safe_write,
28208         too.
28209         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
28210
28211 2002-12-03  Jim Meyering  <jim@meyering.net>
28212
28213         * lib/safe-read.c, safe-write.c: Change variable names and comments,
28214         but not semantics, to minimize the differences between these two files.
28215         (safe_read): Change comment to mention SAFE_READ_ERROR.
28216
28217         * lib/safe-read.c (IS_EINTR): Define.
28218         (safe_read): Use IS_EINTR in place of in-function cpp directives.
28219
28220 2002-12-02  Jim Meyering  <jim@meyering.net>
28221
28222         * lib/safe-read.c (EINTR): Define.
28223         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
28224         (INT_MAX): Provide fallback.
28225         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
28226
28227         * lib/safe-read.h (SAFE_READ_ERROR): Define.
28228
28229 2002-12-02  Bruno Haible  <bruno@clisp.org>
28230
28231         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
28232         Define, taken from safe-read.c.
28233         (INT_MAX): Provide fallback.
28234         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
28235         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
28236
28237         * lib/safe-read.c (EINTR): Remove definition.
28238         (safe_read): Don't use EINTR if it is absent.
28239
28240 2002-12-01  Jim Meyering  <jim@meyering.net>
28241
28242         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
28243         zero.
28244         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
28245
28246 2002-11-27  Paul Eggert  <eggert@twinsun.com>
28247
28248         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
28249         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
28250         with `if (! (value < limit)) abort ();', for readability.
28251
28252 2002-11-26  Karl Berry  <karl@gnu.org>
28253
28254         * lib/strdup.c: copy from libc again, with jim's ok.
28255         * lib/.cppi-disable: re-add strdup.c
28256
28257 2002-11-25  Karl Berry  <karl@gnu.org>
28258
28259         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
28260         instead of "strtol.c".
28261
28262 2002-11-25  Karl Berry  <karl@gnu.org>
28263
28264         * config/install-sh: update from automake for variable quoting, $0 in
28265         error msgs, etc.
28266
28267         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
28268         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
28269         entry.
28270
28271 2002-11-25  Jim Meyering  <jim@meyering.net>
28272
28273         * lib/mktime.c: Sync from libc, now that it has the latest fix.
28274
28275 2002-11-24  Karl Berry  <karl@gnu.org>
28276
28277         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
28278         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
28279
28280 2002-11-24  Jim Meyering  <jim@meyering.net>
28281
28282         Update from coreutils:
28283
28284         * lib/mktime.c: Merge in changes from libc.
28285
28286         Avoid a link-time failure on some Linux systems.
28287         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
28288         (otherwise).
28289         (__mon_yday): Declare with the STATIC attribute.
28290         (__mktime_internal): Likewise.
28291         Based on a report from Greg Schafer.
28292
28293 2002-11-23  Jim Meyering  <jim@meyering.net>
28294
28295         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
28296         Use `unsigned', not `int', as type of index.
28297
28298         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
28299
28300         * lib/fsusage.c: Remove unneeded parentheses around operands of
28301         `defined'.
28302
28303 2002-11-22  Paul Eggert  <eggert@twinsun.com>
28304
28305         * lib/quotearg.h: Allow multiple inclusion by surrounding with
28306         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
28307         so that we can be included first.
28308         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
28309         * lib/quotearg.c: Include quotearg.h immediately after config.h.
28310         No need to include stddef.h or sys/types.h any more.
28311         Surround local include files with "", not "<>".
28312         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
28313         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
28314         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
28315         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
28316         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
28317         (ISPRINT): Remove; no longer needed now that we assume C89.
28318
28319         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
28320         Preserve errno.
28321
28322         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
28323         quotearg_char): Use SIZE_MAX rather than
28324         (size_t) -1 when we are talking about "infinity".
28325
28326         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
28327
28328 2002-11-22  Paul Eggert  <eggert@twinsun.com>
28329
28330         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
28331         hint that one should use `if (! x) abort ();' rather than `assert
28332         (x);', and anyway it's one less thing to worry about configuring.
28333         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
28334         hash_rehash, hash_insert): Use abort rather than assert.
28335
28336 2002-11-22  Bruno Haible  <bruno@clisp.org>
28337
28338         * lib/safe-read.h: Assume C89. Add comments.
28339         (safe_read): Change return type to size_t.
28340         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
28341         byte counts > SSIZE_MAX correctly.
28342         * lib/safe-write.h: New file.
28343         * lib/safe-write.c: New file.
28344         * lib/full-read.h: New file.
28345         * lib/full-read.c: New file.
28346         * lib/full-write.h: Assume C89. Add comments.
28347         * lib/full-write.c: Include safe-write.h.
28348         (full_write): Rewritten to use safe_write.
28349         Suggested by Jim Meyering and Paul Eggert.
28350
28351 2002-11-21  Jim Meyering  <jim@meyering.net>
28352
28353         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
28354
28355         Merge in changes from the coreutils.
28356
28357         2002-09-25  Paul Eggert  <eggert@twinsun.com>
28358         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
28359         <stdint.h>.
28360         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
28361         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
28362         int.  Work more efficiently if X is the same width as uintmax_t.
28363         Do not compare X to -1, to avoid bogus compiler warning.
28364         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
28365         Don't assume that f_frsize and f_bsize are the same type.
28366
28367         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
28368         warning on FreeBSD.
28369
28370         * lib/makepath.c (make_path): Restore umask *before* creating the final
28371         component.
28372         (make_path): Minor reformatting.
28373
28374         * lib/xmalloc.c: Adjust to work with new autoconf macros,
28375         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
28376         HAVE_MALLOC/HAVE_REALLOC.
28377
28378         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
28379         dummy ones.  At least on GNU/Linux systems, `auto' means something
28380         else.
28381         From Michael Stone.
28382
28383 2002-11-21  Bruno Haible  <bruno@clisp.org>
28384
28385         Remove case insensitive option matching.
28386         * lib/argmatch.h (argcasematch): Remove declaration.
28387         (ARGCASEMATCH): Remove macro.
28388         (__xargmatch_internal): Remove case_sensitive argument.
28389         (XARGMATCH): Update.
28390         (XARGCASEMATCH): Remove macro.
28391         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
28392         case_sensitive argument.
28393         (argcasematch): Remove function.
28394         (__xargmatch_internal): Remove case_sensitive argument.
28395         (main): Use XARGMATCH instead of XARGCASEMATCH.
28396
28397         * lib/xmalloc.c: Change compile-time error message. Add comment about
28398         required autoconf version.
28399
28400 2002-11-20  Paul Eggert  <eggert@twinsun.com>
28401
28402         Merge argmatch cleanups from Bison.  Assume C89.
28403
28404         * lib/argmatch.c: Include config.h here, not in argmatch.h.
28405         Include stdlib.h, for EXIT_FAILURE.
28406         Always include <string.h>, since we assume C89.
28407         (EXIT_FAILURE): Remove pre-C89 bug workaround.
28408         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
28409         Include <stddef.h> instead, since it's all we need for size_t.
28410         (PARAMS): Remove.  All uses removed.
28411         (ARRAY_CARDINALITY): Do not bother to #undef.
28412         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
28413         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
28414         Remove unnecessary parentheses.
28415         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
28416         Insert necessary parentheses.
28417         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
28418         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
28419
28420 2002-11-19  Bruno Haible  <bruno@clisp.org>
28421
28422         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
28423         * lib/mbswidth.h: Include <stddef.h>, for size_t.
28424
28425         * lib/mbswidth.h (PARAMS): Remove macro.
28426         (mbswidth, mbsnwidth): Use ANSI C function declarations.
28427         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
28428
28429         * lib/gcd.h (PARAMS): Remove macro.
28430         (gcd): Use ANSI C function declarations.
28431         * lib/gcd.c (gcd): Likewise.
28432
28433 2002-11-15  Bruno Haible  <bruno@clisp.org>
28434
28435         * lib/strcspn.c: Include <stddef.h>.
28436         (strcspn): Use ANSI C function declaration. Change return type to
28437         size_t. Use NULL.
28438         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
28439         (strpbrk): Use NULL.
28440         * lib/strpbrk.h (PARAMS): Remove macro.
28441         (strpbrk): Use ANSI C function declaration.
28442         * lib/strstr.c: Don't include <sys/types.h>.
28443         * lib/strstr.h (PARAMS): Remove macro.
28444         (strstr): Use ANSI C function declarations.
28445
28446 2002-11-14  Karl Berry  <karl@gnu.org>
28447
28448         * config/mkinstalldirs: `do' on separate line, instead of
28449         `for var; do'.
28450
28451 2002-11-06  Bruno Haible  <bruno@clisp.org>
28452
28453         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
28454         * lib/gcd.c (gcd): Likewise.
28455
28456 2002-11-05  Bruno Haible  <bruno@clisp.org>
28457
28458         * lib/gcd.h: New file, from gettext-0.11.5.
28459         * lib/gcd.c: New file, from gettext-0.11.5.
28460
28461 2002-11-05  Bruno Haible  <bruno@clisp.org>
28462
28463         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28464         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28465         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28466         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
28467
28468         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
28469         <libintl.h>.
28470         * lib/makepath.c: Include gettext.h instead of <locale.h> and
28471         <libintl.h>.
28472
28473         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
28474         * lib/human.c: Include gettext.h instead of <libintl.h>.
28475         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
28476         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
28477         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
28478         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
28479         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
28480         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
28481         (textdomain): Remove definition.
28482         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
28483
28484         * lib/long-options.c: Remove include of <libintl.h> and definition of
28485         _.
28486         * lib/same.c: Remove include of <libintl.h> and definition of _.
28487
28488 2002-11-04  Owen Taylor  <otaylor@redhat.com>
28489
28490         * lib/config.charset: A few additions for Solaris.
28491
28492 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
28493
28494         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
28495         * lib/localcharset.c (locale_charset): Declare as extern "C".
28496
28497 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
28498
28499         * lib/config.charset: msdos in uk_UA uses CP1125.
28500
28501 2002-11-04  Bruno Haible  <bruno@clisp.org>
28502
28503         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
28504         * lib/strcase.h: New file, from GNU gettext-0.11.5.
28505         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
28506         * lib/strstr.h: New file, from GNU gettext-0.11.5.
28507         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
28508
28509 2002-11-04  Bruno Haible  <bruno@clisp.org>
28510
28511         * lib/localcharset.c (locale_charset): Don't return an empty string.
28512
28513 2002-11-04  Bruno Haible  <bruno@clisp.org>
28514
28515         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
28516         aliases.
28517
28518 2002-11-04  Bruno Haible  <bruno@clisp.org>
28519
28520         * lib/config.charset: Update for newest glibc. Add canonical names
28521         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
28522
28523 2002-11-04  Bruno Haible  <bruno@clisp.org>
28524
28525         * lib/config.charset: Add support for NetBSD.
28526
28527 2002-11-04  Bruno Haible  <bruno@clisp.org>
28528
28529         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
28530
28531 2002-11-01  Bruno Haible  <bruno@clisp.org>
28532
28533         * configure.in: Add AC_CONFIG_AUX_DIR call.
28534         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
28535         test/Makefile.
28536         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
28537
28538 2002-09-28  Karl Berry  <karl@gnu.org>
28539
28540         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
28541         installed automake until the next release, since changes have been
28542         made.
28543
28544 2002-09-25  Karl Berry  <karl@gnu.org>
28545
28546         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
28547         * lib/getopt*: copy from libc/posix.
28548         * lib/gettext.h: copy from gettext.
28549         * lib/.cppi-disable: add strdup.c, gettext.h.
28550
28551 2002-09-25  Karl Berry  <karl@gnu.org>
28552
28553         * config/srclist.txt: enable gettext.h check.
28554         * config/config.{guess,sub}: update from prep.
28555         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
28556                 from automake 1.6.3.
28557         See srclist*.
28558
28559 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
28560
28561         * regex.c (PATFETCH): Remove the translating fetch.
28562         (PATFETCH_RAW): Rename to PATFETCH.
28563         (set_image_of_range): New fun.
28564         (SET_RANGE_TABLE_WORK_AREA): Use it.
28565         (regex_compile): Don't translate the pattern chars so eagerly.
28566         Only do it when inserting an `exactn' bytecode or when handling
28567         a char-range.
28568         (mutually_exclusive_p): Avoid empty statement.
28569
28570 2002-07-06  Jim Meyering  <meyering@lucent.com>
28571
28572         * m4/README: Don't mention Makefile.am.in.
28573         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
28574
28575 2002-07-01  Jim Meyering  <meyering@lucent.com>
28576
28577         * lib/c-stack.c: Include sys/time.h.
28578         From Volker Borchert.
28579
28580 2002-06-26  Paul Eggert  <eggert@twinsun.com>
28581
28582         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
28583
28584 2002-06-26  Paul Eggert  <eggert@twinsun.com>
28585
28586         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
28587         New macro.  Use it uniformly instead of
28588         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
28589         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
28590         reported by Vin Shelton.
28591
28592 2002-06-22  Paul Eggert  <eggert@twinsun.com>
28593
28594         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
28595         Do not assume SA_SIGINFO behavior.
28596         Bug reported by Jim Meyering on NetBSD 1.5.2.
28597
28598 2002-06-22  Jim Meyering  <meyering@lucent.com>
28599
28600         * m4/c-stack.m4: New file, from diffutils-2.8.2.
28601         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
28602
28603         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
28604         now that configure.ac uses AC_GNU_SOURCE.
28605         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
28606         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
28607
28608         Update to latest tools.  Suggestions from Paul Eggert.
28609         * m4/stdbool.m4: New file, from diffutils-2.8.2.
28610         * m4/gnu-source.m4: Update from diffutils-2.8.2.
28611         * m4/fnmatch.m4: Likewise.
28612         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
28613         to AC_HEADER_STDBOOL
28614
28615 2002-06-22  Jim Meyering  <meyering@lucent.com>
28616
28617         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
28618         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
28619
28620 2002-06-22  Jim Meyering  <meyering@lucent.com>
28621
28622         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
28623
28624         * lib/exitfail.c, exitfail.h: Likewise.
28625         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
28626
28627         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
28628         of fnmatch.h.
28629         (EXTRA_DIST): Add fnmatch_loop.c.
28630         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
28631
28632         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
28633         * lib/fnmatch.c: Update from diffutils-2.8.2.
28634         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
28635         * lib/fnmatch.h: Remove file.
28636
28637 2002-06-21  Jim Meyering  <meyering@lucent.com>
28638
28639         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
28640         * m4/mbrtowc.m4: Likewise.
28641
28642         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
28643         * m4/mbswidth.m4: Reflect name change:
28644         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
28645         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
28646
28647         * m4/lib-link.m4: Update from gettext-0.11.2.
28648         * m4/gettext.m4: Likewise.
28649
28650         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
28651         From Alfred M. Szmidt.
28652
28653 2002-06-18  Paul Eggert  <eggert@twinsun.com>
28654
28655         * lib/file-type.h: Report an error if neither S_ISREG nor
28656         S_IFREG is defined, instead of using a test specific to glibc
28657         2.2.  This should be safe, since POSIX requires S_ISREG and
28658         Unix Version 7 had S_IFREG.  We don't need to check for
28659         <sys/types.h> since we don't use any symbols that it defines.
28660
28661 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
28662
28663         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
28664         $@-t, so that each temporary file name is unique and valid in the first
28665         8 characters, for operation under DOS.
28666
28667 2002-06-15  Paul Eggert  <eggert@twinsun.com>
28668
28669         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
28670
28671 2002-06-15  Jim Meyering  <meyering@lucent.com>
28672
28673         Work even with DJGPP 2.03, which lacks support for symlinks.
28674         From Richard Dawe.
28675         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
28676         is defined.
28677         * lib/lchown.c (S_ISLNK): Likewise.
28678
28679 2002-06-15  Jim Meyering  <meyering@lucent.com>
28680
28681         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
28682         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
28683         have been included before this file.
28684
28685 2002-06-14  Jim Meyering  <meyering@lucent.com>
28686
28687         * lib/file-type.h: Use the version from diffutils-2.8.2.
28688         * lib/file-type.c: Likewise.
28689
28690 2002-06-07  Jim Meyering  <meyering@lucent.com>
28691
28692         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
28693         They're needed at least for NetBSD 1.5.2.
28694         ($statxfs_includes): Include those same headers.
28695         ($statxfs_includes): Include sys/vfs.h if available.
28696         ($statxfs_includes): Likewise for sys/statvfs.h.
28697         Check for the following members in both structs statfs and statvfs:
28698         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
28699
28700 2002-06-01  Jim Meyering  <meyering@lucent.com>
28701
28702         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
28703         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
28704
28705 2002-05-28  Jim Meyering  <meyering@lucent.com>
28706
28707         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
28708         Reported by Volker Borchert.
28709
28710 2002-05-27  Jim Meyering  <meyering@lucent.com>
28711
28712         Fix a problem seen only on nonconforming systems whereby ls.c's
28713         use of localtime, and then of gettimeofday would cause trouble:
28714         the localtime call used to initialize rpl_gettimeofday's save
28715         mechanism would clobber ls's current local time information so
28716         that in any long listing the first file would always be listed
28717         with date 1970-01-01.  Analysis by Volker Borchert.
28718
28719         * lib/gettimeofday.c (localtime): Undefine.
28720         (rpl_localtime): New function.
28721
28722 2002-05-27  Jim Meyering  <meyering@lucent.com>
28723
28724         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
28725         localtime.
28726
28727         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
28728         use the replacement function; it wouldn't resolve at link time.
28729         Reported by Volker Borchert.
28730
28731 2002-05-22  Jim Meyering  <meyering@lucent.com>
28732
28733         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
28734         file-type.h.
28735         * lib/file-type.h: New file.
28736         * lib/file-type.c (file_type): New file/function.  Extracted from
28737         diffutils.
28738
28739 2002-04-30  Jim Meyering  <meyering@lucent.com>
28740
28741         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
28742
28743 2002-04-29  Paul Eggert  <eggert@twinsun.com>
28744
28745         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
28746
28747 2002-04-29  Paul Eggert  <eggert@twinsun.com>
28748
28749         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
28750         Do not check for alloca.h (no longer used) or stdbool.h (was never
28751         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
28752
28753 2002-04-29  Paul Eggert  <eggert@twinsun.com>
28754
28755         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
28756
28757 2002-04-29  Jim Meyering  <meyering@lucent.com>
28758
28759         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
28760         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
28761         Use AC_FUNC_STRNLEN here instead.
28762
28763         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
28764         With autoconf-2.53a, it's part of AC_PROG_CC.
28765
28766 2002-04-28  Paul Eggert  <eggert@twinsun.com>
28767
28768         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
28769         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
28770
28771 2002-04-28  Paul Eggert  <eggert@twinsun.com>
28772
28773         * lib/sig2str.h, lib/sig2str.c: New files.
28774         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
28775
28776 2002-04-28  Paul Eggert  <eggert@twinsun.com>
28777
28778         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
28779         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
28780         of 127, since 64 is the largest conceivable number for ancient
28781         nonstandard hosts.
28782         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
28783
28784 2002-04-28  Jim Meyering  <meyering@lucent.com>
28785
28786         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
28787
28788 2002-04-24  Jim Meyering  <meyering@lucent.com>
28789
28790         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
28791         (jm_PREREQ): Use it.
28792
28793         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
28794         mach/mach.h fcntl.h.
28795         Check for this function: setlocale.
28796
28797 2002-04-24  Jim Meyering  <meyering@lucent.com>
28798
28799         * lib/gettext.h: New file, from Gettext.
28800         * lib/Makefile.am (INCLUDES): Remove -I../intl.
28801         (libfetish_a_SOURCES): Add gettext.h.
28802
28803 2002-04-16  Jim Meyering  <meyering@lucent.com>
28804
28805         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
28806         ut_pid, ut_id, ut_exit.
28807
28808 2002-04-16  Jim Meyering  <meyering@lucent.com>
28809
28810         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
28811         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
28812         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
28813
28814 2002-04-12  Jim Meyering  <meyering@lucent.com>
28815
28816         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
28817         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
28818         existence of the getmntinfo function.  Needed for Darwin 5.3.
28819
28820         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
28821         This is necessary at least on Darwin 5.3.
28822
28823         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
28824         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
28825         strnlen.o in the library, and that makes some versions of ranlib
28826         object.
28827
28828 2002-04-12  Jim Meyering  <meyering@lucent.com>
28829
28830         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
28831
28832 2002-04-09  Jim Meyering  <meyering@lucent.com>
28833
28834         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
28835         to be more precise.  Rather than saying we're checking whether the
28836         function `works', say what we're testing.
28837         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
28838         Reported by Bruno Haible.
28839
28840 2002-03-10  Jim Meyering  <meyering@lucent.com>
28841
28842         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
28843         Suggestion from Santiago Vila.
28844
28845 2002-03-08  Jim Meyering  <meyering@lucent.com>
28846
28847         * lib/rename.c: Mention that this wrapper is needed also on
28848         mips-dec-ultrix4.4 systems.
28849
28850 2002-03-02  Jim Meyering  <meyering@lucent.com>
28851
28852         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
28853         not HAVE_CLOCK_SETTIME.
28854
28855 2002-02-27  Paul Eggert  <eggert@twinsun.com>
28856
28857         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
28858         Check for clock_settime.
28859
28860 2002-02-27  Paul Eggert  <eggert@twinsun.com>
28861
28862         * lib/nanosleep.h: Rename to....
28863         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
28864
28865         * lib/gettime.c: New file.
28866         * lib/settime.c: New file.
28867         * lib/stime.c: Remove.
28868
28869         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
28870         timespec.h.  Remove nanosleep.h.
28871
28872 2002-02-25  Paul Eggert  <eggert@twinsun.com>
28873
28874         * m4/acl.m4: New file.
28875         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
28876         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
28877
28878 2002-02-25  Paul Eggert  <eggert@twinsun.com>
28879
28880         * lib/acl.c, lib/acl.h: New files.
28881         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
28882
28883 2002-02-24  Jim Meyering  <meyering@lucent.com>
28884
28885         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
28886         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
28887         cause trouble.  Reported by Nelson Beebe.
28888
28889 2002-02-23  Paul Eggert  <eggert@twinsun.com>
28890
28891         * lib/path-concat.c (xpath_concat): Reorder code to pacify
28892         compilers that don't know that xalloc_die never returns.
28893
28894 2002-02-20  Jim Meyering  <meyering@lucent.com>
28895
28896         * lib/getdate.c: Regenerate using bison-1.33.
28897
28898 2002-02-17  Jim Meyering  <meyering@lucent.com>
28899
28900         * config/config.guess (main): Don't use `head -1'; it's no longer
28901         portable. Use `sed 1q' instead.
28902
28903 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
28904
28905         * m4/codeset.m4: Upgrade to gettext-0.11.
28906         * m4/gettext.m4: Upgrade to gettext-0.11.
28907         * m4/glibc21.m4: Upgrade to gettext-0.11.
28908         * m4/iconv.m4: Upgrade to gettext-0.11.
28909         * m4/isc-posix.m4: Upgrade to gettext-0.11.
28910         * m4/lcmessage.m4: Upgrade to gettext-0.11.
28911         * m4/lib-ld.m4: New file, from gettext-0.11.
28912         * m4/lib-link.m4: New file, from gettext-0.11.
28913         * m4/lib-prefix.m4: New file, from gettext-0.11.
28914         * m4/progtest.m4: Upgrade to gettext-0.11.
28915
28916 2002-02-15  Paul Eggert  <eggert@twinsun.com>
28917
28918         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
28919         (jm_PREREQ): Use it.
28920
28921 2002-02-15  Paul Eggert  <eggert@twinsun.com>
28922
28923         * lib/posixver.c, lib/posixver.h: New files.
28924         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
28925
28926 2002-02-02  Paul Eggert  <eggert@twinsun.com>
28927             Bruno Haible  <bruno@clisp.org>
28928
28929         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
28930         (fwrite_success_callback): New declaration.
28931         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
28932         print_unicode_char. Call failure callback instead of error.
28933         (fwrite_success_callback): New function.
28934         (exit_failure_callback): New function.
28935         (fallback_failure_callback): New function.
28936         (print_unicode_char): Call unicode_to_mb.
28937
28938 2002-01-26  Jim Meyering  <meyering@lucent.com>
28939
28940         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
28941         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
28942
28943 2002-01-26  Jim Meyering  <meyering@lucent.com>
28944
28945         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
28946
28947 2002-01-22  Paul Eggert  <eggert@twinsun.com>
28948
28949         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
28950
28951 2002-01-22  Jim Meyering  <meyering@lucent.com>
28952
28953         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
28954         Otherwise, some versions of automake would omit the rule that makes
28955         Makefile from Makefile.in.
28956
28957 2002-01-21  Paul Eggert  <eggert@twinsun.com>
28958
28959         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
28960         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
28961         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
28962         (memcoll): Set errno to zero if there is no error.
28963
28964         * lib/quotearg.c (quotearg_buffer_restyled):
28965         Fix bug with quoting buffers containing NUL when backslashing escapes.
28966         This bug was exposed by the other changes in this patch.
28967         (quotearg_n_options): New arg ARGSIZE.
28968         All callers changed.
28969         (quoting_options_from_style): New function.
28970         (quotearg_n_style): Use it.
28971         (quotearg_n_style_mem): New function.
28972
28973         * lib/quotearg.h (quotearg_n_style_mem): New function.
28974
28975 2002-01-19  Jim Meyering  <meyering@lucent.com>
28976
28977         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
28978         Remove useless quotes: DF_PROG="df".
28979         * m4/strnlen.m4: New file.
28980
28981 2002-01-16  Paul Eggert  <eggert@twinsun.com>
28982
28983         * lib/backupfile.c (ISDIGIT): Comment fix.
28984         * lib/getdate.y (ISDIGIT): Likewise.
28985         * lib/posixtm.c (ISDIGIT, year): Likewise.
28986         * lib/strverscmp.c (ISDIGIT): Likewise.
28987         * lib/userspec.c (ISDIGIT): Likewise.
28988
28989 2002-01-16  Jim Meyering  <meyering@lucent.com>
28990
28991         * lib/getdate.y: Add three semicolons, each just before a closing
28992         brace. Bison (as of version 1.31) no longer papers over that mistake.
28993
28994 2002-01-05  Jim Meyering  <meyering@lucent.com>
28995
28996         * lib/version-etc.c (version_etc_copyright): Update copyright year.
28997
28998 2001-12-19  Paul Eggert  <eggert@twinsun.com>
28999
29000         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
29001         not silently exit merely because the output buffer happens to
29002         have nothing pending.
29003
29004 2001-12-18  Paul Eggert  <eggert@twinsun.com>
29005
29006         See the big note in ../ChangeLog.
29007         * lib/human.c (suffixes): Prefer K to k for 1024.
29008         (generate_suffix_backwards): New function.
29009         (human_readable_inexact): Use it.
29010         * lib/xstrtol.c (__xstrtol): If there is no number but there
29011         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
29012         Accept 'K' as well as 'k'.
29013
29014 2001-12-15  Jim Meyering  <meyering@lucent.com>
29015
29016         * lib/regex.h (__restrict_arr): Update from libc.
29017
29018         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
29019         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
29020         (STREQ): Define.
29021
29022 2001-12-14  Jim Meyering  <meyering@lucent.com>
29023
29024         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
29025         Suggestion from Bruno Haible.
29026
29027 2001-12-10  Jim Meyering  <meyering@lucent.com>
29028
29029         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
29030         xrealloc, Instead, include "xalloc.h".
29031         (initbuffer): Don't cast xmalloc return value to char*.
29032         (readline): Reword comment.
29033         Don't cast xrealloc return value to char*
29034         Return NULL, not 0.
29035
29036 2001-12-09  Jim Meyering  <meyering@lucent.com>
29037
29038         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
29039         about `signed and unsigned type in conditional expression'.
29040         * lib/posixtm.c (posix_time_parse): Likewise.
29041
29042         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
29043
29044         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
29045         to avoid a pedantic warning.
29046
29047         * lib/getstr.c: Don't include assert.h.
29048         (getstr): Remove warning-evoking assertions.
29049         Return -1 if offset parameter is out of bounds.
29050         Change the type of a local from int to size_t.
29051
29052         * lib/strftime.c (my_strftime_localtime_r): Include this function
29053         definition in the `#if ! HAVE_TM_GMTOFF' block.
29054
29055         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
29056         Include xalloc.h instead.
29057
29058 2001-12-02  Jim Meyering  <meyering@lucent.com>
29059
29060         * lib/tempname.c: Don't declare getenv, thus reverting the change of
29061         2001-11-18.  It's no longer necessary, now that stdlib.h is always
29062         included.
29063
29064         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
29065         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
29066
29067 2001-11-30  Akim Demaille  <akim@epita.fr>
29068
29069         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
29070         before being defined.
29071
29072 2001-11-27  Paul Eggert  <eggert@twinsun.com>
29073
29074         * lib/quotearg.h (quotearg_n, quotearg_n_style):
29075         First arg is int, not unsigned.
29076         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
29077         (SIZE_MAX, UINT_MAX): New macros.
29078         (quotearg_n_options): Abort if N is negative.
29079         Avoid overflow check on hosts where size_t is 64 bits and int
29080         is 32 bits, as overflow is impossible there.
29081         Fix off-by-one typo that caused unnecessary reallocation.
29082
29083 2001-11-27  Jim Meyering  <meyering@lucent.com>
29084
29085         * lib/tempname.c: Merge with version from libc.
29086         * lib/regex.c: Likewise.
29087
29088         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
29089         systems for which STDC_HEADERS is 0, it was not included, resulting in
29090         a warning about an integer-to-pointer conversion problem with getenv.
29091         Reported by Volker Borchert.
29092
29093 2001-11-26  Jim Meyering  <meyering@lucent.com>
29094
29095         * lib/gtod.h: Remove file.
29096         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
29097         * lib/gettimeofday.c: Don't include gtod.h.
29098         (GTOD_init): Remove function.
29099         (rpl_gettimeofday): Do its job here instead, rather than aborting.
29100         Suggestion from Volker Borchert.
29101
29102 2001-11-23  Jim Meyering  <meyering@lucent.com>
29103
29104         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
29105         it.
29106         * lib/hash.c (struct hash_table): Define it here instead.
29107
29108 2001-11-22  Jim Meyering  <meyering@lucent.com>
29109
29110         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
29111
29112 2001-11-20  Jim Meyering  <meyering@lucent.com>
29113
29114         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
29115         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
29116
29117 2001-11-19  Jim Meyering  <meyering@lucent.com>
29118
29119         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
29120         directory.  Use "conftestXXXXXX" as the template.
29121         Suggestion from Paul Eggert.
29122
29123         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
29124         immediately, so the test doesn't mistakenly hit the max-open-files
29125         limit.
29126
29127 2001-11-18  Paul Eggert  <eggert@twinsun.com>
29128
29129         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
29130         (TEMPORARIES): New macro.
29131         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
29132         removes an artificial limitation (e.g. HP-UX 10.20, where
29133         TMP_MAX is 17576).
29134
29135 2001-11-18  Jim Meyering  <meyering@lucent.com>
29136
29137         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
29138
29139 2001-11-18  Jim Meyering  <meyering@lucent.com>
29140
29141         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
29142         on SunOS 4.
29143
29144         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
29145         files will be created before anything else.
29146
29147 2001-11-17  Paul Eggert  <eggert@twinsun.com>
29148
29149         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
29150         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
29151
29152 2001-11-17  Jim Meyering  <meyering@lucent.com>
29153
29154         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
29155         Prompted by a report from Bob Proulx.
29156
29157         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
29158         Instead, require UTILS_FUNC_MKSTEMP.
29159
29160 2001-11-17  Jim Meyering  <meyering@lucent.com>
29161
29162         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
29163         Now, that's done as part of AC_FUNC_STRTOD.
29164
29165 2001-11-17  Jim Meyering  <meyering@lucent.com>
29166
29167         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
29168         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
29169         rather than group writable.  Patch by Juan F. Codagnone.
29170
29171         * lib/readtokens.c: Remove explicit declarations of xmalloc and
29172         xrealloc, Instead, include "xalloc.h".
29173
29174         * lib/mountlist.c: Include unlocked-io.h after all system headers.
29175         Remove explicit declarations of xmalloc, xrealloc,
29176         and xstrdup.  Instead, include "xalloc.h".
29177
29178         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
29179         unlocked-io.h.
29180         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
29181         Likewise.
29182         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
29183
29184         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
29185         Reported by Padraig Brady.
29186
29187         * lib/mkstemp.c: #undef mkstemp.
29188         Include config.h.
29189         (rpl_mkstemp): Rename from mkstemp.
29190         Protoize.
29191
29192 2001-11-16  Jim Meyering  <meyering@lucent.com>
29193
29194         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
29195         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
29196         determine the amount of total physical memory, use pstat_getstatic.
29197         HPUX-11 doesn't define _SC_PHYS_PAGES.
29198         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
29199         If sysconf couldn't be used to determine the amount of available
29200         physical memory, use both pstat_getstatic and pstat_getdynamic.
29201         Based on a patch from Bob Proulx.
29202
29203 2001-11-10  Jim Meyering  <meyering@lucent.com>
29204
29205         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
29206         (jm_PREREQ): Use it.
29207
29208 2001-11-09  Jim Meyering  <meyering@lucent.com>
29209
29210         * m4/jm-macros.m4: Require autoconf-2.52f.
29211         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
29212         Use these AC_-prefixed names, not the AM_-prefixed ones.
29213
29214         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
29215
29216 2001-11-05  Jim Meyering  <meyering@lucent.com>
29217
29218         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
29219
29220 2001-11-04  Jim Meyering  <meyering@lucent.com>
29221
29222         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
29223         $DEFS.
29224
29225 2001-11-03  Jim Meyering  <meyering@lucent.com>
29226
29227         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
29228         of AC_DEFUN.
29229
29230         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
29231         know the name of the variable in the macro definition.
29232
29233 2001-11-03  Jim Meyering  <meyering@lucent.com>
29234
29235         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
29236         in argmatch_to_argument call.
29237
29238         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
29239         argument.
29240
29241         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
29242         e.g., a fault due to an attempt to free a NULL pointer.
29243
29244 2001-11-01  Jim Meyering  <meyering@lucent.com>
29245
29246         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
29247         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
29248
29249 2001-11-01  Jim Meyering  <meyering@lucent.com>
29250
29251         * lib/dirfd.c, lib/dirfd.h: New files.
29252         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
29253
29254         * lib/hash.c (hash_print) [TESTING]: Clean up.
29255
29256 2001-10-22  Paul Eggert  <eggert@twinsun.com>
29257
29258         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
29259         to avoid a warning if -Wall.
29260
29261 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
29262
29263         * README: New file
29264         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
29265         (per RMS's instructions, this is now the canonical source)
29266         * lgpl/, gpl/: New directories.
29267
29268 2001-10-21  Paul Eggert  <eggert@twinsun.com>
29269
29270         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
29271
29272 2001-10-21  Jim Meyering  <meyering@lucent.com>
29273
29274         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
29275         this code would end up calling gettext even in packages built
29276         with --disable-nls.
29277         * lib/getopt.c (_): Likewise.
29278         * lib/regex.c (_): Likewise.
29279
29280 2001-10-20  Paul Eggert  <eggert@twinsun.com>
29281
29282         * m4/error.m4 (jm_PREREQ_ERROR):
29283         Do not invoke AC_CHECK_FUNCS with strerror_r, as
29284         AC_FUNC_STRERROR_R does that.
29285         Check for strerror declaration.
29286
29287         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
29288         are supposed to have them these days.
29289         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
29290         Merge changes from latest Autoconf CVS.
29291         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
29292         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
29293         POSIX decided to standardize on the int flavor of strerror_r.
29294
29295 2001-10-20  Paul Eggert  <eggert@twinsun.com>
29296
29297         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
29298         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
29299         Use strerror_r that is only a macro, even if it is not a function.
29300         (strerror): Check for HAVE_DECL_STRERROR before declaring.
29301         (private_strerror): Use prototypes, not old-style function definition.
29302         (print_errno_message): New function.
29303         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
29304         char*-flavored one.
29305         (error_tail, error, error_at_line): Use it.
29306
29307 2001-10-11  Jim Meyering  <meyering@lucent.com>
29308
29309         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
29310         and quote_n (1, ... to avoid clobbering a buffer.
29311
29312 2001-10-05  Jim Meyering  <meyering@lucent.com>
29313
29314         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
29315         hash-pjw.h.
29316         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
29317         * lib/hash-pjw.h: New file.
29318
29319 2001-09-30  Jim Meyering  <meyering@lucent.com>
29320
29321         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
29322         `struct fsstat' has the `f_fstypename' member.
29323         Use that to define FS_TYPE, which is now used to make
29324         the getfsstat link test tighter.
29325
29326 2001-09-30  Jim Meyering  <meyering@lucent.com>
29327
29328         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
29329         Include <sys/ucred.h>, for Apple Darwin.
29330         Include sys/mount.h and sys/fs_types.h only if available.
29331         (FS_TYPE): Define.
29332         (read_filesystem_list): Use FS_TYPE.
29333
29334 2001-09-29  Paul Eggert  <eggert@twinsun.com>
29335
29336         * lib/exclude.c (excluded_filename): 0 -> false, since it's
29337         a boolean context.
29338
29339 2001-09-29  Jim Meyering  <meyering@lucent.com>
29340
29341         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
29342         [one-argument getmntent function]): Include stdio.h before mntent.h.
29343         SunOS 4.1.x needs it for the declaration of `FILE'.
29344         Patch by Volker Borchert.
29345
29346         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
29347         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
29348         sys/fs_types.h, and make the link-test for getfsstat guard #include
29349         directives with appropriate #if HAVE_*_H tests so that we can
29350         detect getfsstat on Apple Darwin1.3.7 systems.
29351         Reported by Nelson Beebe.
29352         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
29353
29354 2001-09-28  Paul Eggert  <eggert@twinsun.com>
29355
29356         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
29357         #defines strtoimax.  Also treat the other strto* functions
29358         like strtoimax.
29359
29360         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
29361         Check for strtoul and strtoumax,
29362         as those declarations are made even in the signed case.
29363         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
29364         Likewise, for strtol and strtoimax.
29365
29366 2001-09-28  Paul Eggert  <eggert@twinsun.com>
29367
29368         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
29369         #defines strtoimax.  Also treat the other strto* functions
29370         like strtoimax.
29371
29372         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
29373         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
29374         (strtoimax, strtoumax): Do not declare if already defined as a macro.
29375
29376 2001-09-26  Jim Meyering  <meyering@lucent.com>
29377
29378         Most macros in unlocked-io.h had the wrong number of arguments.
29379         * lib/gen-uio: New script.
29380         (USE_UNLOCKED_IO): Define to 1 if not already defined.
29381         * lib/unlocked-io.hin: Remove file.
29382         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
29383         rather than trying to embed it here.
29384         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
29385         Reported by Padraig Brady.
29386
29387 2001-09-25  Volker Borchert  <bt@teknon.de>
29388
29389         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
29390         `result'.
29391
29392 2001-09-24  Jim Meyering  <meyering@lucent.com>
29393
29394         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
29395
29396 2001-09-23  Jim Meyering  <meyering@lucent.com>
29397
29398         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
29399         instead of the mere test for existence of mntent.h.  The latter
29400         would get a false-positive on AIX 3.4 systems.
29401         In the outer getmntent if-block, don't die if neither of the getmntent
29402         tests succeeds.  Instead, just fall through and continue with the
29403         remaining tests.
29404
29405 2001-09-23  Jim Meyering  <meyering@lucent.com>
29406
29407         * lib/mountlist.c: Remove useless parentheses in #if directives.
29408         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
29409         the deprecated MOUNTED symbol is no longer defined in mntent.h.
29410
29411 2001-09-22  Jim Meyering  <meyering@lucent.com>
29412
29413         * m4/gettext.m4: New file.  From gettext.
29414         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
29415         * m4/progtest.m4: Likewise
29416         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
29417         * m4/glibc21.m4: Likewise.
29418
29419         * m4/libintl.m4: Remove.  No longer used.
29420
29421 2001-09-22  Jim Meyering  <meyering@lucent.com>
29422
29423         * lib/localcharset.c: Update from latest gettext.
29424         * lib/config.charset: Likewise.
29425
29426 2001-09-20  Jim Meyering  <meyering@lucent.com>
29427
29428         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
29429         strtoimax.
29430         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
29431         strtoumax.
29432
29433 2001-09-20  Jim Meyering  <meyering@lucent.com>
29434
29435         * lib/xstrtol.c (strtoimax): Guard declaration with
29436         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
29437         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
29438         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
29439         (strtoumax): Likewise, for completeness (it wasn't necessary).
29440
29441 2001-09-17  Paul Eggert  <eggert@twinsun.com>
29442
29443         * lib/strtoimax.c (HAVE_LONG_LONG):
29444         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
29445         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
29446         to work around bug in IBM C compiler.
29447
29448 2001-09-17  Jim Meyering  <meyering@lucent.com>
29449
29450         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
29451         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
29452         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
29453         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
29454         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
29455         whenever the right hand side need not be expanded by the shell.
29456
29457 2001-09-16  Paul Eggert  <eggert@twinsun.com>
29458
29459         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
29460         library.  It's not correct, as some older glibcs are buggy.
29461         fnmatch wasn't fixed until glibc 2.2.
29462
29463         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
29464         special shell magic here.
29465
29466 2001-09-16  Jim Meyering  <meyering@lucent.com>
29467
29468         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
29469         * m4/jm-macros.m4: Require it.
29470
29471 2001-09-16  Jim Meyering  <meyering@lucent.com>
29472
29473         * lib/mkdir.c: New file.
29474
29475 2001-09-15  Jim Meyering  <meyering@lucent.com>
29476
29477         * m4/jm-macros.m4: Check for help2man.
29478
29479 2001-09-11  Jim Meyering  <meyering@lucent.com>
29480
29481         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
29482         The body, by Paul Eggert, was moved here from configure.in.
29483         * m4/jm-macros.m4: Require UTILS_HOST_OS.
29484
29485 2001-09-04  Paul Eggert  <eggert@twinsun.com>
29486
29487         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
29488         (jm_PREREQ): Use it.
29489
29490 2001-09-04  Paul Eggert  <eggert@twinsun.com>
29491
29492         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
29493         Use ssize_t, not int, to store result of readlink.
29494         Check for ssize_t overflow as well as size_t overflow,
29495         as POSIX says the result of readlink is implementation-defined
29496         when ssize_t overflows.
29497         Remove unnecessary cast to char*.
29498         Use free+malloc instead of realloc, as the storage doesn't need
29499         to be preserved and it's clearer and can be more efficient that way.
29500         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
29501         * lib/xreadlink.h (xreadlink): Update prototype.
29502
29503 2001-09-04  Paul Eggert  <eggert@twinsun.com>
29504
29505         * lib/xgetcwd.c: Revert some of the previous change; intead,
29506         fix the HAVE_GETCWD_NULL code to behave more like the
29507         !HAVE_GETCWD_NULL code used to.
29508
29509         Include "xalloc.h".
29510         (xgetcwd): Do not return NULL when memory is exhausted; instead,
29511         invoke xalloc_die.
29512
29513 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29514
29515         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
29516         sys/param.h, as pathmax.h includes them.
29517
29518 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29519
29520         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
29521         (jm_PREREQ_XGETCWD): New macro.
29522
29523         * m4/getcwd.m4: New file.
29524
29525 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29526
29527         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
29528         like the HAVE_GETCWD_NULL code.
29529         Include pathmax.h if not HAVE_GETCWD.
29530         Do not include xalloc.h.
29531         (INITIAL_BUFFER_SIZE): New symbol.
29532         Do not use xmalloc / xrealloc, since the caller is responsible for
29533         handling errors.  Preserve errno around `free' during failure.
29534         Do not overrun buffer when using getwd.
29535
29536 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29537
29538         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
29539         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
29540         getcwd (NULL, 0).
29541
29542 2001-09-03  Paul Eggert  <eggert@twinsun.com>
29543
29544         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
29545         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
29546         spotted by Jim Meyering.
29547
29548 2001-09-03  Jim Meyering  <meyering@lucent.com>
29549
29550         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
29551         failure.
29552
29553 2001-09-02  Jim Meyering  <meyering@lucent.com>
29554
29555         * lib/error.c: Update from GNU libc.
29556
29557 2001-09-01  Jim Meyering  <meyering@lucent.com>
29558
29559         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
29560         Used by df.
29561
29562 2001-09-01  Jim Meyering  <meyering@lucent.com>
29563
29564         * lib/xreadlink.c: New file.
29565         * lib/xreadlink.h: New file.
29566         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
29567         xreadlink.h.
29568
29569         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
29570         doesn't conflict with sparc Solaris 7's definition in
29571         /usr/include/sys/int_types.h.
29572
29573         * lib/exclude.c: Use `""', not `<>' to #include non-system header
29574         files.
29575         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
29576         and strncasecmp as r-values.  Unixware didn't have declarations.
29577
29578 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29579
29580         * lib/xstrtol.h: Add copyright notice.
29581         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
29582         LONGINT_INVALID_SUFFIX_CHAR.
29583
29584 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29585
29586         * lib/xstrtol.c (strtoimax): New decl.
29587
29588 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29589
29590         * lib/xgetcwd.c: Don't include pathmax.h.
29591         Include stdlib.h and unistd.h if available.
29592         Include xalloc.h.
29593         (xmalloc, xstrdup, free): Remove decls.
29594         (xgetcwd): Don't assume sizes fit in unsigned.
29595         Check for overflow when computing sizes.
29596         Simplify reallocation code.
29597
29598 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29599
29600         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
29601         a directory's st_size can have an arbitrary value, so the old
29602         usage could waste an arbitrary amount of memory.  All uses
29603         changed.
29604         * lib/savedir.h: Update prototype.
29605
29606 2001-08-31  Paul Eggert  <eggert@twinsun.com>
29607
29608         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
29609
29610         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
29611         old strtoimax.c.
29612
29613         Also, make the following further changes to make this file's
29614         configuration more similar to that of strtol.c:
29615         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
29616         (strtoumax, uintmax_t, strtoull, strtol): Remove.
29617         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
29618         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
29619         changed to signed values.
29620
29621         And make the following changes as well:
29622         Fix copyright notice, as 1999 was missing.
29623         (verify): New macro.
29624         (strtoimax): Check sizes at compile-time, not run-time.
29625         Prefer strtol to strtoll if both work.
29626         (main): Remove; it was not that useful and was a pain to maintain.
29627
29628         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
29629
29630 2001-08-31  Jim Meyering  <meyering@lucent.com>
29631
29632         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
29633         Use an initial, malloc'd, buffer of length 128 rather than
29634         a statically allocated one of length 1024.
29635
29636 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29637
29638         Simplify code, partly by assuming autoconf 2.52 semantics.
29639
29640         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
29641
29642         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
29643         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
29644         All uses removed.
29645         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
29646         Move AC_REQUIRE to next-to-top level, to avoid confusion.
29647         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
29648         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
29649         jm_AC_HEADER_INTTYPES_H.
29650         * m4/jm-macros.m4 (jm_MACROS): Likewise.
29651
29652         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
29653
29654         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
29655         Quote first arg of AC_DEFUN.
29656         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
29657         since they are needed to parse the include file even if we need
29658         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
29659         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
29660         but with opposite signedness.
29661
29662 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29663
29664         Merge 'exclude' changes from tar 1.13.22.
29665         This fixes one or two unlikely storage allocation overflow bugs,
29666         but doesn't change user-visible behavior otherwise.
29667
29668 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29669
29670         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
29671         (jm_PREREQ_EXCLUDE): New macro.
29672
29673 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29674
29675         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
29676         tm to be declared.
29677
29678 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29679
29680         * lib/hash.c: Remove '2001' from copyright notice.
29681
29682 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29683
29684         * lib/full-write.h: New file.
29685         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
29686         * lib/full-write.c: Correct credits, as cccp.c no longer
29687         exists and anyway it was so heavily changed from the old cccp
29688         code as to be unrecognizable.  Include full-write.h.
29689         (full_write) Return size_t, with short writes meaning failure.
29690         All callers changed.  This fixes a bug with large buffers
29691         on 64-bit hosts.
29692         * lib/utime.c: Include full-write.h.
29693
29694 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29695
29696         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
29697         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
29698         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
29699         Include if available.
29700         (<xalloc.h>): Include
29701         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
29702         (verify): New macro.  Use it to verify that EXCLUDE macros do not
29703         collide with FNM macros.
29704         (struct patopts): New struct.
29705         (struct exclude): Use it, as exclude patterns now come with options.
29706         (new_exclude): Support above changes.
29707         (new_exclude, add_exclude_file):
29708         Initial size must now be a power of two to simplify overflow checking.
29709         (free_exclude, fnmatch_no_wildcards): New function.
29710         (excluded_filename): No longer requires options arg, as the options
29711         are determined by add_exclude.  Now returns bool, not int.
29712         (excluded_filename, add_exclude):
29713         Add support for the fancy new exclusion options.
29714         (add_exclude, add_exclude_file): Now takes int options arg.
29715         Check for arithmetic overflow when computing sizes.
29716         (add_exclude_file): xrealloc might modify errno, so don't
29717         realloc until after errno might be used.
29718
29719         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
29720         New macros.
29721         (free_exclude): New decl.
29722         (add_exclude, add_exclude_file): Now takes int options arg.
29723         (excluded_filename): No longer requires options arg, as the options
29724         are determined by add_exclude.  Now returns bool, not int.
29725
29726 2001-08-30  Paul Eggert  <eggert@twinsun.com>
29727
29728         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
29729
29730 2001-08-27  Jim Meyering  <meyering@lucent.com>
29731
29732         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
29733
29734         * lib/version-etc.c (N_): Remove definition.
29735         Revert most of last change.
29736         Instead, simply don't mark the `Copyright...' string for translation.
29737         Based on advice from Paul Eggert.
29738
29739         * lib/strtoxmax.c: Tweak comment.
29740
29741 2001-08-26  Jim Meyering  <meyering@lucent.com>
29742
29743         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
29744
29745         * m4/xstrtoimax.m4: New file.
29746         * m4/xstrtoumax.m4: Add comments explaining why we
29747         AC_REPLACE_FUNCS(strtol).
29748
29749 2001-08-26  Jim Meyering  <meyering@lucent.com>
29750
29751         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
29752         of copyright with `%s' so translators don't get an untranslated
29753         message in 2002.
29754         (COPYRIGHT_YEAR): Define.
29755         (version_etc): Use fprintf rather than fputs.
29756         Suggestion from Ulrich Drepper.
29757
29758         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
29759
29760         * lib/strtoll.c: New file, from GNU libc.
29761         * lib/xstrtoimax.c: New file.
29762
29763         * lib/xstrtol.h: Add xstrtoimax.
29764         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
29765         * lib/strtoimax.c: New file.  Likewise, but first define
29766         STRTOUXMAX_SIGNED.
29767
29768         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
29769         ...
29770         * lib/strtoxmax.c: ... then renamed to this.
29771
29772 2001-08-18  Paul Eggert  <eggert@twinsun.com>
29773
29774         * m4/inttypes.m4: Add AC_PREREQ(2.13).
29775         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
29776         (jm_AC_TYPE_INTMAX_T): New macro.
29777         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
29778
29779         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
29780
29781         * m4/longlong.m4: Renamed from ulonglong.m4.
29782         * m4/inttypes.m4: Renamed from inttypes_h.m4.
29783         * m4/uintmax_t.m4: Removed.
29784
29785 2001-08-13  Paul Eggert  <eggert@twinsun.com>
29786
29787         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
29788         Port to Solaris 8, where 'sed' requires a space after the 'r'
29789         command, and where sh dislikes "$/".  Clean up the spacing a bit.
29790         Redirect output to $tmp just once.
29791
29792 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
29793
29794         * lib/addext.c (<errno.h>): Include.
29795         (errno): Declare if not defined.
29796         (addext): Work correctly when pathconf returns -1 and leaves
29797         errno alone because there is no limit.  Also, work even if
29798         pathconf returns a value greater than SIZE_MAX.
29799
29800 2001-08-12  Jim Meyering  <meyering@lucent.com>
29801
29802         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
29803         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
29804         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
29805         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
29806         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
29807         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
29808         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
29809         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
29810         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
29811         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
29812         utime.m4, utimes.m4, xstrtoumax.m4:
29813         Quote the first argument in each use of AC_DEFUN.
29814
29815 2001-08-12  Jim Meyering  <meyering@lucent.com>
29816
29817         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
29818         Simply `return getcwd (NULL, 0);'.
29819         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
29820         Use 1300 as initial value for length, not PATH_MAX.
29821
29822         * lib/pathmax.h: Clean up cpp syntax.
29823
29824 2001-08-12  Jim Meyering  <meyering@lucent.com>
29825
29826         * lib/gettimeofday.c: New file.
29827         * lib/gtod.h: New file.
29828         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
29829
29830 2001-08-05  Jim Meyering  <meyering@lucent.com>
29831
29832         * m4/jm-macros.m4: Require autoconf-2.52.
29833
29834 2001-08-04  Jim Meyering  <meyering@lucent.com>
29835
29836         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
29837         stmt, to get in sync with glibc.
29838
29839 2001-08-03  Paul Eggert  <eggert@twinsun.com>
29840
29841         The following changes are from gettext 0.10.39 as maintained by
29842         Bruno Haible.
29843
29844         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
29845         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
29846         with inverted sense.  All uses changed.
29847
29848         * lib/mbswidth.c: Don't include <limits.h>.
29849         Include <stdlib.h> and <string.h> unconditionally.
29850         (iswcntrl, mbsinit, ISCNTRL): New macros.
29851         (mbsnwidth): Use K&R style function declarations.
29852         Don't bother checking for MB_LEN_MAX == 1, since the compiler
29853         can optimize it when MB_CUR_MAX == 1.
29854         The width of control characters is zero, not 1.
29855
29856 2001-08-03  Paul Eggert  <eggert@twinsun.com>
29857
29858         The following changes are from gettext 0.10.39 as maintained by
29859         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
29860
29861         * m4/codeset.m4: Upgrade to serial AM1.
29862         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
29863         all uses changed.  Quote first arg of AC_DEFUN.
29864         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
29865
29866         * m4/iconv.m4: Upgrade to serial AM2.
29867         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
29868         Add --with-libconv-prefix.
29869         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
29870         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
29871         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
29872         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
29873         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
29874
29875         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
29876         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
29877         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
29878         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
29879         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
29880         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
29881         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
29882         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
29883         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
29884
29885         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
29886         string.h any more.
29887
29888         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
29889         not the default value.
29890
29891         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
29892         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
29893         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
29894         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
29895         Also check for iswcntrl, used for wcwidth fallback.
29896         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
29897         to Autoconf 2.13.
29898
29899 2001-08-03  Jim Meyering  <meyering@lucent.com>
29900
29901         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
29902         as it was in the original.  Reported by Paul Eggert.
29903
29904 2001-07-16  Jim Meyering  <meyering@lucent.com>
29905
29906         * m4/gettimeofday.m4: New file.
29907         Prompted by a report from Bernhard Baehr.
29908
29909 2001-07-15  Jim Meyering  <meyering@lucent.com>
29910
29911         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
29912         stuff. Now it's in ../Makefile.cfg.
29913
29914 2001-07-15  Jim Meyering  <meyering@lucent.com>
29915
29916         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
29917         (BUILT_SOURCES): Add unlocked-io.h.
29918         (io_functions): Define.
29919         (unlocked-io.h): New rule.
29920         (DISTCLEANFILES): Add unlocked-io.h.
29921         (all-local): Depend on unlocked-io.h, to ensure it is created.
29922
29923         * lib/unlocked-io.hin: New file
29924
29925         * lib/regex.c: Update from glibc.
29926
29927 2001-07-05  Jim Meyering  <meyering@lucent.com>
29928
29929         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
29930         recommendation.
29931         (libfetish_a_SOURCES): Put all .h files here instead.
29932         Remove a thus-exposed (better checks in automake) duplicate and
29933         two unnecessary .h files.
29934
29935 2001-07-04  Jim Meyering  <meyering@lucent.com>
29936
29937         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
29938         that generates jm-glibc-io.m4 so that it doesn't trigger any make
29939         distcheck failure.
29940
29941 2001-07-02  Jim Meyering  <meyering@lucent.com>
29942
29943         The following changes were prompted by suggestions from Bruno Haible.
29944
29945         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
29946         is now generated.
29947         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
29948         definition of EXTRA_DIST.
29949         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
29950         ensure that the generated file is created/updated whenever the list
29951         of $(unlocked_functions) is changed.
29952         (jm-glibc-io.m4): New rule.
29953         (unlocked-io.h): New rule -- currently unused.
29954
29955 2001-06-24  Jim Meyering  <meyering@lucent.com>
29956
29957         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
29958         unmatched right bracket, rather than kludging it with an extra,
29959         falsely-matching quote in a comment.  Patch by Akim Demaille.
29960
29961 2001-06-11  Jim Meyering  <meyering@lucent.com>
29962
29963         * lib/regex.c: Update from GNU libc.
29964
29965 2001-05-27  Jim Meyering  <meyering@lucent.com>
29966
29967         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
29968         Check for ut_type in struct utmp.
29969
29970 2001-05-27  Jim Meyering  <meyering@lucent.com>
29971
29972         * lib/readutmp.h (UT_TYPE): Define.
29973
29974 2001-05-24  Jim Meyering  <meyering@lucent.com>
29975
29976         * lib/argmatch.c: Include "quote.h".
29977         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
29978         quote function.  Reported by Göran Uddeborg.
29979
29980 2001-05-22  Jim Meyering  <meyering@lucent.com>
29981
29982         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
29983         now that we use the package-supplied version unconditionally.
29984         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
29985
29986 2001-05-21  Jim Meyering  <meyering@lucent.com>
29987
29988         * m4/regex.m4: Change a couple backticks to single quotes to avoid
29989         shell syntax errors.
29990
29991 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
29992
29993         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
29994
29995 2001-05-20  Paul Eggert  <eggert@twinsun.com>
29996
29997         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
29998         Don't bother to check library strftime, since
29999         we'll be using our own my_strftime function anyway.
30000         Define my_strftime instead of strftime.
30001
30002 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
30003
30004         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
30005         which is not yet declared.
30006
30007 2001-05-15  Jim Meyering  <meyering@lucent.com>
30008
30009         * m4/regex.m4: Use proper quoting so brackets appear in the test
30010         program.
30011         Reported by, and with help from, Bruno Haible.
30012
30013 2001-05-13  Jim Meyering  <meyering@lucent.com>
30014
30015         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
30016         undefined.
30017
30018 2001-05-11  Paul Eggert  <eggert@twinsun.com>
30019
30020         dirname code cleanup.  base_name now behaves more compatibly
30021         with POSIX basename when given file names that have trailing
30022         slashes, and similarly for dir_name.  Add new primitives
30023         base_len and dir_len.  Put the directory-name-related decls
30024         into dirname.h.
30025
30026         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
30027         * lib/backupfile.c (base_name): Likewise.
30028         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
30029         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
30030         * lib/makepath.c (strip_trailing_slashes): Likewise.
30031         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
30032         ISSLASH): Likewise.
30033         * lib/rename.c (strip_trailing_slashes): Likewise.
30034         * lib/same.c (base_name): Likewise.
30035         * lib/stripslash.c (ISSLASH): Likewise.
30036
30037         * lib/addext.c: Include <dirname.h> after size_t is defined.
30038         * lib/backupfile.c: Likewise.
30039
30040         * lib/addext.c (addext): Use base_len to trim redundant
30041         trailing slashes instead of doing it ourselves.
30042         But do not trim the last slash if it is not redundant.
30043
30044         * lib/backupfile.c (find_backup_file_name,
30045         max_backup_version): Use base_len instead of rolling it ourselves.
30046         Handle the case of "" and (on DOS) "C:" correctly.
30047
30048         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
30049         needed. Include <string.h>, <dirname.h>.
30050         (base_name): Allow file names ending in slashes, other than names
30051         that are all slashes.  In this case, return the basename followed
30052         by the slashes.  This is more general, and can be used in places
30053         where the original base_name purposely had an assertion failure.
30054         (base_len): New function.
30055
30056         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
30057         Do not include <assert.h>; no longer needed.
30058         Include xalloc.h.
30059         (memrchr): Remove decl.
30060         (dir_name_r): Remove.
30061         (dir_len): Renamed from dirlen.  All callers changed.
30062         Rewrite in terms of base_name, for simplicity and consistency.
30063         (dir_name): Never return NULL.  All callers changed.
30064         Do not include <stdlib.h> in test program; no longer needed.
30065         return 0; is fine for test program.
30066
30067         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
30068         New macros.
30069         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
30070
30071         * lib/path-concat.c (path_concat): Use base_len to compute
30072         base length, not strlen; this means we cannot rely on memcpy
30073         to null-terminate.
30074
30075         * lib/same.c (STREQ): Remove.
30076         (same_name): Handle the case where the basename ends in trailing '/'.
30077
30078         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
30079         a slash was stripped.  Do not strip the last slash after a
30080         file system prefix.
30081
30082 2001-05-11  Paul Eggert  <eggert@twinsun.com>
30083
30084         * lib/Makefile.am (libfetish_a_SOURCES):
30085         Add strftime.c, since we now compile it on all hosts.
30086
30087         * lib/strftime.c (my_strftime):
30088         Define to nstrftime if emacs, but only if my_strftime is not defined.
30089         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
30090         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
30091         Add one more extra argument: a nanoseconds value.
30092         All uses changed.
30093         (ns): New macro.
30094         (my_strftime function): Add %N format.
30095         (emacs_strftimeu): Renamed from emacs_strftime,
30096         with extra ut argument.
30097
30098 2001-05-09  Paul Eggert  <eggert@twinsun.com>
30099
30100         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
30101
30102 2001-04-21  Jim Meyering  <meyering@lucent.com>
30103
30104         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
30105         doesn't interfere.
30106
30107 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
30108
30109         * m4/ftruncate.m4: Check for chsize.
30110         Link with ftruncate.o unconditionally if ftruncate is missing.
30111         This was required when cross-compiling to i586-mingw32msvc.
30112
30113 2001-04-08  Jim Meyering  <meyering@lucent.com>
30114
30115         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
30116         recomputed; that's necessary when the offset spans a DST transition.
30117         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
30118
30119 2001-04-02  Jim Meyering  <meyering@lucent.com>
30120
30121         * lib/regex.h, regex.c: Update from GNU libc.
30122
30123 2001-03-24  Jim Meyering  <meyering@lucent.com>
30124
30125         * m4/jm-macros.m4: Require autoconf-2.49d.
30126
30127 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
30128
30129         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
30130
30131 2001-03-19  Paul Eggert  <eggert@twinsun.com>
30132
30133         * lib/version-etc.c (version_etc_copyright): Update to 2001.
30134
30135 2001-03-17  Jim Meyering  <meyering@lucent.com>
30136
30137         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
30138         now that the version in autoconf is equivalent.
30139         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
30140
30141         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
30142         Suggestion from Akim Demaille.
30143
30144         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
30145         (jm_PREREQ_TEMPNAME): New function.
30146
30147 2001-03-16  Paul Eggert  <eggert@twinsun.com>
30148
30149         * lib/tempname.c (uint64_t): Define to uintmax_t if
30150         not defined, and if UINT64_MAX is not defined.
30151         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
30152         Reported by John David Anglin.
30153
30154 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
30155
30156         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
30157         resolve alias if codeset is empty.
30158         * lib/config.charset (BeOS): Use wildcard syntax.
30159
30160 2001-03-13  Jim Meyering  <meyering@lucent.com>
30161
30162         * lib/path-concat.c (path_concat)
30163         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
30164         concatenating e.g., `C:' and `foo'.
30165         From Bruno Haible.
30166
30167 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
30168
30169         * lib/localcharset.c (locale_charset): Don't use
30170         setlocale(LC_CTYPE,NULL). Don't return NULL.
30171         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
30172
30173 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
30174
30175         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
30176         support for DOS/DJGPP.
30177
30178 2001-03-01  Paul Eggert  <eggert@twinsun.com>
30179
30180         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
30181         lacks mkstemp.  Compile our own tempname.c if we compile our own
30182         mkstemp.c, as mkstemp relies on tempname.
30183
30184 2001-03-01  Jim Meyering  <meyering@lucent.com>
30185
30186         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
30187         AH_VERBATIM really does output its argument verbatim.
30188
30189 2001-02-28  Paul Eggert  <eggert@twinsun.com>
30190
30191         * lib/Makefile.am (libfetish_a_SOURCES):
30192         Add dup-safer.c, fopen-safer.c.
30193         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
30194
30195         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
30196         * lib/unistd-safer.h: New files.
30197
30198 2001-02-25  Paul Eggert  <eggert@twinsun.com>
30199
30200         The mkstemp replacement is taken from glibc 2.2.2, with some
30201         portability fixes for use outside glibc, as follows:
30202
30203         * lib/tempname.c (struct_stat64): New macro.
30204         (direxists, __gen_tempname): Use it.
30205         This avoids a portability problem with Solaris 8.
30206
30207         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
30208         (<stddef.h>, <stdint.h>, <string.h>):
30209         Include only if STDC_HEADERS || _LIBC.
30210         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
30211         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
30212         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
30213         (__set_errno): Define this macro if <errno.h> doesn't.
30214         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
30215         Define these macros if <stdio.h> doesn't.
30216         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
30217         Define these macros if <sys/stat.h>
30218         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
30219         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
30220         __xstat64): Define if not _LIBC.
30221         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
30222         (__gen_tempname): Invoke gettimeofday only if
30223         HAVE_GETTIMEOFDAY || _LIBC;
30224         otherwise, fall back on plain "time".
30225         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
30226
30227         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
30228
30229         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
30230
30231 2001-02-18  Paul Eggert  <eggert@twinsun.com>
30232
30233         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
30234
30235 2001-02-17  Paul Eggert  <eggert@twinsun.com>
30236
30237         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
30238         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
30239         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
30240         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
30241
30242 2001-02-17  Paul Eggert  <eggert@twinsun.com>
30243
30244         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
30245         Remove workaround macros for hosts that have mbrtowc but not
30246         mbstate_t, as we now insist on proper declarations for both
30247         before using mbrtowc.
30248
30249 2001-02-17  Jim Meyering  <meyering@lucent.com>
30250
30251         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
30252         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
30253         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
30254         UnixWare 7.1.1.
30255
30256         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
30257         rather than AC_CACHE_VAL.
30258
30259 2001-02-17  Jim Meyering  <meyering@lucent.com>
30260
30261         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
30262         around included file name.
30263
30264         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
30265
30266         * lib/strftime.c: Update from GNU libc (the only changes were to
30267         comments).
30268
30269 2001-02-17  Jim Meyering  <meyering@lucent.com>
30270
30271         * lib/regex.c: Update from libc.
30272
30273 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
30274
30275         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
30276         clash.
30277
30278 2001-02-16  Paul Eggert  <eggert@twinsun.com>
30279
30280         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
30281         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
30282         Reported by Mark Hounschell via Paul Eggert.
30283
30284 2001-02-07  Jim Meyering  <meyering@lucent.com>
30285
30286         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
30287
30288 2001-02-05  Jim Meyering  <meyering@lucent.com>
30289
30290         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
30291         it includes the patch required for `large file' support with at least
30292         HP-UX's 10.20 /bin/cc.
30293
30294 2001-02-03  Jim Meyering  <meyering@lucent.com>
30295
30296         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
30297         AS_IF, now that it works once again (mysteriously).
30298         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
30299
30300 2001-01-30  Jim Meyering  <meyering@lucent.com>
30301
30302         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
30303         * m4/chown.m4: Rename conftestchown to conftest.chown.
30304         * m4/rename.m4: s/conftestdir/conftest.d1/ and
30305         s/conftestdir2/conftest.d2/.
30306         * m4/utimes.m4: s/conftestdata/conftest.data/
30307         Inspired by Pavel Roskin's change in autoconf.
30308
30309 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
30310
30311         * lib/config.charset: Update for FreeBSD 4.2.
30312
30313 2001-01-27  Jim Meyering  <meyering@lucent.com>
30314
30315         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
30316         a use of AS_IF.
30317         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
30318
30319 2001-01-26  Jim Meyering  <meyering@lucent.com>
30320
30321         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
30322         quotearg.c includes it.
30323
30324 2001-01-26  Jim Meyering  <meyering@lucent.com>
30325
30326         * lib/quotearg.c: Include stddef.h.
30327         * lib/quote.c: Include stddef.h.
30328         Reported by Axel Kittenberger.
30329
30330         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
30331         line in double quotes so that it evokes a better diagnostic.
30332         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
30333         Reported by Axel Kittenberger.
30334
30335 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
30336
30337         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
30338         as if it was a `charset'.
30339
30340 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
30341
30342         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
30343         has const.
30344
30345 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
30346
30347         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
30348         to avoid a warning.  Add back 'const' to inptr.
30349
30350 2001-01-20  Jim Meyering  <meyering@lucent.com>
30351
30352         Be sure that headers are checked before used in code compiled
30353         for the type checks.
30354         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
30355         In place of that, invoke jm_CHECK_ALL_TYPES.
30356         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
30357         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
30358         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
30359         The check for ssize_t was mistakenly run before the test for unistd.h.
30360
30361         The configure-time check for stdbool.h was missing.
30362         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
30363         (jm_PREREQ_HASH): New function.
30364
30365 2001-01-17  Jim Meyering  <meyering@lucent.com>
30366
30367         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
30368         for autoconf-2.49c.
30369         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
30370
30371 2001-01-16  Jim Meyering  <meyering@lucent.com>
30372
30373         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
30374         From Bruno Haible.
30375
30376 2001-01-14  Jim Meyering  <meyering@lucent.com>
30377
30378         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
30379         foo and bar.  Create conftestdir/ in the script, not in the C code.
30380         Remove directories in the script, not in the C code.
30381         Remove conftestdir{,2} before trying to create the directory.
30382         Make the entire configure script fail if the mkdir fails.
30383
30384 2001-01-14  Jim Meyering  <meyering@lucent.com>
30385
30386         * lib/rename.c: New file.  From Volker Borchert.
30387         Include stdlib.h, string.h or strings.h, and xalloc.h.
30388         Use strip_trailing_slashes rather than open-coding it.
30389
30390 2001-01-03  Paul Eggert  <eggert@twinsun.com>
30391
30392         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
30393
30394 2001-01-03  Jim Meyering  <meyering@lucent.com>
30395
30396         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
30397         of local `inptr' to avoid warning with some system declarations of
30398         iconv.
30399
30400 2001-01-02  Volker Borchert  <bt@teknon.de>
30401
30402         * m4/rename.m4: New file.
30403         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
30404
30405 2001-01-01  Jim Meyering  <meyering@lucent.com>
30406
30407         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
30408         even on systems with utmpx.h.  It's necessary for the declaration of
30409         utmp's ut_user member.  Reported by Andreas Jaeger.
30410
30411         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
30412         available. They are required for the declarations of getgrgid and
30413         getpwuid resp.
30414         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
30415         Reported by Andreas Jaeger.
30416
30417 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
30418
30419         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
30420         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
30421         so `make install' also works in VPATH builds.
30422
30423 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
30424
30425         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
30426         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
30427         can be used in subdirectories.
30428
30429 2000-12-29  Paul Eggert  <eggert@twinsun.com>
30430
30431         * lib/modechange.c: Do not assume that mode_t uses the
30432         traditional octal encoding.  E.g. "chmod 1 FOO" should set
30433         the other-execute bit of FOO even if S_IXOTH != 1.
30434
30435         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
30436         WOTH, XOTH, ALLM): New macros.
30437         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
30438          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
30439         Use them.
30440         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
30441         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
30442         (mode_compile):
30443         No need to use uintmax_t; unsigned long is long enough.
30444         Don't bother to get suffix since we don't use it.
30445
30446 2000-12-26  Jim Meyering  <meyering@lucent.com>
30447
30448         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
30449         better with autoheader.
30450
30451 2000-12-24  Jim Meyering  <meyering@lucent.com>
30452
30453         * lib/hash.c (is_prime): Return explicit boolean values.
30454         (hash_get_first): Return NULL to appease Irix5.6's 89.
30455         Reported by Nelson Beebe.
30456
30457 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
30458
30459         * lib/localcharset.c (locale_charset): Add support for Win32.
30460
30461 2000-12-18  Paul Eggert  <eggert@twinsun.com>
30462
30463         * lib/physmem.h, lib/physmem.c: New files.
30464
30465         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
30466         (noinst_HEADERS): Add physmem.h.
30467
30468         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
30469         't' for compatibility with Solaris 8 sort.
30470
30471 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
30472
30473         * lib/config.charset: Add support for BeOS.
30474
30475 2000-12-17  Jim Meyering  <meyering@lucent.com>
30476
30477         * m4/dos.m4 (jm_AC_DOS): New file and macro.
30478         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
30479
30480 2000-12-16  Jim Meyering  <meyering@lucent.com>
30481
30482         This bug had a serious impact on chown: `chown N:M FILE' (for integer
30483         N and M) would have treated it like `chown N:N FILE'.
30484
30485         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
30486
30487 2000-12-16  Jim Meyering  <meyering@lucent.com>
30488
30489         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
30490         SHELLS_FILE to a file name that's useful on djgpp systems.
30491         Include stdlib.h.
30492         (ADDITIONAL_DEFAULT_SHELLS): Define.
30493         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
30494         Based mostly on a patch from Prashant TR.
30495
30496 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
30497
30498         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
30499         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
30500         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
30501
30502 2000-12-08  Andreas Schwab  <schwab@suse.de>
30503
30504         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
30505         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
30506
30507 2000-12-07  Jim Meyering  <meyering@lucent.com>
30508
30509         * lib/stripslash.c (ISSLASH): Define.
30510         (strip_trailing_slashes): Use ISSLASH rather than comparing against
30511         `/'.
30512         From Prashant TR.
30513
30514         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
30515         (dir_name_r): Declare this function as static.
30516         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
30517         manifest itself on a name containing a mix of slashes and
30518         backslashes.
30519         Make this function work with names starting with a DOS-style
30520         drive letter and colon prefix.
30521         (dir_name): Append `.' if necessary.
30522         Based mostly on patches from Prashant TR and Eli Zaretskii.
30523
30524         * lib/dirname.h (dir_name_r): Remove prototype.
30525
30526 2000-12-06  Paul Eggert  <eggert@twinsun.com>
30527
30528         * m4/off_t-format.m4: Remove this file.
30529         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
30530
30531 2000-12-06  Jim Meyering  <meyering@lucent.com>
30532
30533         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
30534         replacement strtoull, we may well need the replacement strtoul, too.
30535         Check for declarations of strtoul and strtoull.
30536         Check for strtol.  Mainly as a cue to cause automake to include
30537         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
30538         Check for limits.h -- strtol.c needs it.
30539
30540 2000-12-05  Jim Meyering  <meyering@lucent.com>
30541
30542         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
30543
30544 2000-12-04  Jim Meyering  <meyering@lucent.com>
30545
30546         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
30547         Also include memory.h, stdlib.h, unistd.h if appropriate.
30548         Reported by Andreas Jaeger (conflicting declaration of malloc).
30549
30550 2000-12-02  Jim Meyering  <meyering@lucent.com>
30551
30552         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
30553         * m4/jm-macros.m4 (jm_MACROS): require it.
30554
30555 2000-12-02  Jim Meyering  <meyering@lucent.com>
30556
30557         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
30558
30559 2000-12-01  Paul Eggert  <eggert@twinsun.com>
30560
30561         * lib/memrchr.c: Include <config.h> before any system include file.
30562
30563 2000-11-30  Jim Meyering  <meyering@lucent.com>
30564
30565         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
30566
30567 2000-11-30  Jim Meyering  <meyering@lucent.com>
30568
30569         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
30570
30571 2000-11-29  Paul Eggert  <eggert@twinsun.com>
30572
30573         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
30574
30575 2000-11-26  Jim Meyering  <meyering@lucent.com>
30576
30577         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
30578
30579 2000-11-22  Paul Eggert  <eggert@twinsun.com>
30580
30581         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
30582         size of (size_t) -1; it's not portable.
30583
30584 2000-11-17  Jim Meyering  <meyering@lucent.com>
30585
30586         * lib/strstr.c: Update from GNU libc.
30587
30588 2000-11-17  Akim Demaille  <akim@epita.fr>
30589
30590         * lib/obstack.h: Formatting changes.
30591         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
30592         prevent type checking.
30593         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
30594         cast the value to (void *): assigning a `foo *' to a `void *'
30595         variable is valid.
30596         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
30597
30598 2000-11-16  Jim Meyering  <meyering@lucent.com>
30599
30600         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
30601
30602 2000-11-11  Jim Meyering  <meyering@lucent.com>
30603
30604         * lib/error.c: Add a couple #includes, merging from GNU libc version.
30605
30606 2000-11-10  Jim Meyering  <meyering@lucent.com>
30607
30608         * lib/obstack.h: Update from GNU libc.
30609         * lib/obstack.c: Likewise.
30610
30611 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
30612
30613         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
30614
30615 2000-11-06  Paul Eggert  <eggert@twinsun.com>
30616
30617         * lib/getusershell.c (setusershell): Use rewind rather than
30618         fseek/fseeko, to avoid configuration hassles with fseeko.
30619         Don't bother opening SHELLS_FILE if shellstream is NULL;
30620         it's not necessary.
30621
30622 2000-11-05  Jim Meyering  <meyering@lucent.com>
30623
30624         * lib/makepath.h (make_dir): Declare.
30625         * lib/makepath.c (make_dir): Remove `static' attribute.
30626         Tweak a comment.
30627
30628 2000-11-04  Jim Meyering  <meyering@lucent.com>
30629
30630         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
30631
30632 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
30633
30634         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
30635         last one in a bucket, advance to the next bucket.
30636
30637 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
30638
30639         * lib/fnmatch.c: Do not comment out all the code if we are using
30640         the GNU C library, because in some cases we are replacing buggy
30641         code in the GNU C library itself.
30642
30643 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
30644
30645         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
30646         (regex_compile): Catch bogus \(\1\).
30647
30648 2000-10-30  Paul Eggert  <eggert@twinsun.com>
30649
30650         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
30651         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
30652         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
30653
30654 2000-10-30  Paul Eggert  <eggert@twinsun.com>
30655
30656         * lib/error.h, getline.h, modechange.h:
30657         Remove "2000" from Copyright line, as the file hasn't been
30658         changed this year other than in the copyright notice.
30659
30660         * lib/xalloc.h: Add "2000" to Copyright line, as this file
30661         was changed this year.
30662
30663 2000-10-29  Jim Meyering  <meyering@lucent.com>
30664
30665         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
30666         renaming.
30667         * m4/ls-mntd-fs.m4: Likewise
30668
30669 2000-10-29  Jim Meyering  <meyering@lucent.com>
30670
30671         * lib/xstat.in: Fix grammar in comment.
30672
30673 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
30674
30675         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
30676         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
30677         doesn't define __restrict_arr.
30678
30679 2000-10-28  Jim Meyering  <meyering@lucent.com>
30680
30681         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
30682         (jm_PREREQ_MEMCHR): New function.
30683
30684 2000-10-28  Jim Meyering  <meyering@lucent.com>
30685
30686         * lib/memchr.c: Update from libc.
30687         Adjust for portability:
30688         [HAVE_STDLIB_H]: Include stdlib.h.
30689         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
30690         Undef __memchr, too.
30691         [!weak_alias]: Define __memchr to memchr.
30692
30693         * lib/regex.c: Update from libc.
30694         * lib/regex.h: Likewise.
30695         * lib/getopt1.c: Likewise.
30696         * lib/memcmp.c: Likewise.
30697
30698         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
30699         Avoid using fseek, when possible -- it's broken by design.
30700         Patch by Ulrich Drepper.
30701
30702 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
30703
30704         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
30705         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
30706         Giving in to popular pressure to shut up the compiler with casts.
30707
30708 2000-10-26  Jim Meyering  <meyering@lucent.com>
30709
30710         * lib/strftime.c: Update from libc.
30711
30712 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
30713
30714         * regex.c: More `unsigned char' -> `re_char' changes.
30715         Also change several `int' into `re_wchar_t'.
30716         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
30717         (PUSH_FAILURE_POINTER): Don't cast any more.
30718         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
30719         We want GCC to complain, since this piece of code makes
30720         re_match non-reentrant, which *should* be fixed.
30721         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
30722         (EXTEND_BUFFER): Use RETALLOC.
30723         (SET_LIST_BIT): Don't cast.
30724         (re_wchar_t): New type.
30725         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
30726         that those two functions will always properly return.
30727         (IMMEDIATE_QUIT_CHECK): Cast to void.
30728         (analyse_first): Use recursion rather than an explicit stack.
30729         (re_compile_fastmap): Can't fail anymore.
30730         (re_search_2): Don't check re_compile_fastmap for failure.
30731         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
30732         Now also sets the new value (passed in a new argument).
30733         (re_match_2_internal): Use it.
30734         Also, use a new var `reg' of type size_t when looping through regs
30735         rather than reuse the inappropriate `mcnt'.
30736
30737 2000-10-25  Jim Meyering  <meyering@lucent.com>
30738
30739         * lib/obstack.c: Update from libc.
30740
30741 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
30742
30743         * regex.c (regex_compile): Change the way of handling a range from
30744         a char less than 256 to a char not less than 256.
30745
30746 2000-10-24  Andrew Innes  <andrewi@gnu.org>
30747
30748         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
30749         NT-Emacs only.
30750         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
30751         so that re_search functions only quit when callers expect them to.
30752
30753 2000-10-23  Jim Meyering  <meyering@lucent.com>
30754
30755         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
30756         wrong.  That set_locale call must not have any side effects.
30757         From Paul Eggert.
30758
30759 2000-10-22  Jim Meyering  <meyering@lucent.com>
30760
30761         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
30762         [CYCLIC]: Remove now-unused definition.
30763
30764         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
30765         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
30766         Suggestion from Ulrich Drepper.
30767
30768 2000-10-21  Jim Meyering  <meyering@lucent.com>
30769
30770         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
30771         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
30772         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
30773
30774 2000-10-21  Jim Meyering  <meyering@lucent.com>
30775
30776         * lib/dirname.c (memrchr): Declare if necessary.
30777         (dir_name): Remove the restriction that there be no
30778         trailing slashes.  Now, this code skips past them, effectively
30779         ignoring them.
30780         [TEST_DIRNAME] (main): New unit tests.
30781
30782         * lib/memrchr.c: New file from GNU libc.
30783         Undef __memrchr, too.
30784         [!weak_alias]: Define __memrchr to memrchr.
30785         Guard weak_alias use with `#ifdef weak_alias'.
30786
30787 2000-10-21  Jim Meyering  <meyering@lucent.com>
30788
30789         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
30790         (dir_name): Use dir_name_r.
30791         * lib/dirname.h (dir_name_r): Declare it.
30792
30793 2000-10-17  Jim Meyering  <meyering@lucent.com>
30794
30795         * lib/quote.h (PARAMS): Define and use.
30796         Reported by Akim Demaille.
30797
30798         * lib/getopt.c: Update from libc.
30799
30800 2000-10-16  Jim Meyering  <meyering@lucent.com>
30801
30802         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
30803         setlocale.
30804         From Jan Fedak.
30805
30806 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
30807
30808         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
30809
30810 2000-09-25  Jim Meyering  <meyering@lucent.com>
30811
30812         * lib/md5.h (rol): Define (from GnuPG).
30813
30814         * lib/sha.c: Give credit (GnuPG) where due.
30815         (M): Use rol rather than open-coding it.
30816         Add a FIXME comment.
30817
30818 2000-09-21  Jim Meyering  <meyering@lucent.com>
30819
30820         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
30821         Reported by Michael Stone.
30822
30823 2000-09-20  Jim Meyering  <meyering@lucent.com>
30824
30825         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
30826         (noinst_HEADERS): Add sha.h.
30827         Based on code from Scott G. Miller and from GnuPG.
30828
30829 2000-09-18  Jim Meyering  <meyering@lucent.com>
30830
30831         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
30832         LIBS. Otherwise, everyone ends up linking with -lelf for some
30833         configurations.
30834         Reported by Mike Stone.
30835
30836 2000-09-15  Jim Meyering  <meyering@lucent.com>
30837
30838         * lib/regex.c: Update from libc.
30839
30840 2000-09-10  Jim Meyering  <meyering@lucent.com>
30841
30842         * lib/getopt.c (_getopt_internal): Update from glibc.
30843
30844 2000-09-09  Jim Meyering  <meyering@lucent.com>
30845
30846         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
30847         think it should be used as a general replacement for isascii.
30848         * lib/fnmatch.c: Likewise.
30849         * lib/mbswidth.c: Likewise
30850         * lib/regex.c: Likewise.
30851
30852         Don't use atoi.
30853         * lib/userspec.c: Include sys/param.h and limits.h.
30854         Include xstrtol.h.
30855         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
30856         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
30857         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
30858         UID, GID.  Check range.
30859
30860 2000-09-06  Jim Meyering  <meyering@lucent.com>
30861
30862         * lib/getopt.c (_getopt_internal): Update from glibc.
30863
30864 2000-08-30  Jim Meyering  <meyering@lucent.com>
30865
30866         * lib/strftime.c: Merge in changes from GNU libc.
30867
30868 2000-08-26  Jim Meyering  <meyering@lucent.com>
30869
30870         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
30871         * m4/fpending.m4: New file.
30872
30873 2000-08-26  Jim Meyering  <meyering@lucent.com>
30874
30875         * lib/closeout.c: Include "__fpending.h".
30876         (close_stdout_status): Return right away if there's nothing to flush.
30877
30878         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
30879         * lib/__fpending.c: New file.
30880         * lib/__fpending.h: New file.
30881
30882 2000-08-20  Jim Meyering  <meyering@lucent.com>
30883
30884         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
30885         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
30886         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
30887
30888 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
30889
30890         Improve fileutils installation on systems where running
30891         programs (like install) can't be unlinked.
30892         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
30893         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
30894
30895 2000-08-07  Paul Eggert  <eggert@twinsun.com>
30896
30897         Standardize on "memory exhausted" instead of "Memory exhausted"
30898         or "virtual memory exhausted".
30899         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
30900         "virtual memory exhausted".
30901         * lib/same.c (same_name): Invoke xalloc_die instead of printing
30902         our own message.
30903         * lib/userspec.c (parse_user_spec): Likewise.
30904         * lib/bumpalloc.h: comment fix
30905         * lib/same.c, userspec.c: Include xalloc.h.
30906
30907         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
30908         not char *const and pointing to a constant array.
30909         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
30910         (xrealloc): Comment fix.
30911
30912         * lib/userspec.c (parse_user_spec):
30913         Don't translate a message until just before returning,
30914         to avoid unnecessary translation.
30915
30916 2000-08-07  Jim Meyering  <meyering@lucent.com>
30917
30918         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
30919         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
30920         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
30921         getgroups.c, gethostname.c, getopt.h, group-member.c,
30922         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
30923         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
30924         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
30925         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
30926         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
30927         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
30928         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
30929         yesno.c: Back out Copyright date changes for each file with no change
30930         this year.  This eases coordination with other programs using the same
30931         source code modules.  From Paul Eggert.
30932
30933 2000-08-06  Paul Eggert  <eggert@twinsun.com>
30934
30935         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
30936         not char, for compatibility with glibc 2.1.3 strftime.c.
30937
30938 2000-08-03  Greg McGary  <greg@mcgary.org>
30939
30940         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
30941         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
30942         (EXTEND_BUFFER): Use them.
30943
30944 2000-08-01  Jim Meyering  <meyering@lucent.com>
30945
30946         * lib/dirname.c (ISSLASH): Define.
30947         (BACKSLASH_IS_PATH_SEPARATOR): Define.
30948         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
30949         both `\' and `/' may be use as path separators.
30950         Based on a patch from Prashant TR.
30951
30952 2000-07-31  Paul Eggert  <eggert@twinsun.com>
30953
30954         * lib/quotearg.c (quotearg_n_options): Don't make the initial
30955         slot vector a constant, since it might get modified.
30956
30957 2000-07-31  Jim Meyering  <meyering@lucent.com>
30958
30959         * lib/xmalloc.c: Use `virtual memory exhausted', not
30960         `Memory exhausted'.
30961         * lib/obstack.c (print_and_abort): Likewise.
30962
30963 2000-07-30  Paul Eggert  <eggert@twinsun.com>
30964
30965         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
30966         buffer, so that the caller can always quote one small
30967         component of a "memory exhausted" message in slot 0.
30968         From a suggestion by Jim Meyering.
30969
30970 2000-07-30  Jim Meyering  <meyering@lucent.com>
30971
30972         * lib/makepath.c (make_path): Quote the other instance, too.
30973
30974         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
30975         (STATIC_BUF_SIZE): Define.
30976         (quotearg_n_options): Use only statically allocated storage when
30977         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
30978         than STATIC_BUF_SIZE.
30979
30980 2000-07-29  Jim Meyering  <meyering@lucent.com>
30981
30982         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
30983         * lib/dirname.c (dir_name): Likewise.
30984
30985         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
30986         `/'.
30987
30988         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
30989         (dir_name): Assert that there are no trailing slashes.
30990
30991 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
30992
30993         * lib/mbswidth.h (mbswidth): Add a flags argument.
30994         (mbswidth): New declaration.
30995         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
30996         * lib/mbswidth.c (mbswidth): Add a flags argument.
30997         (mbsnwidth): New function.
30998
30999 2000-07-24  Jim Meyering  <meyering@lucent.com>
31000
31001         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
31002
31003 2000-07-23  Paul Eggert  <eggert@twinsun.com>
31004
31005         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
31006
31007 2000-07-23  Paul Eggert  <eggert@twinsun.com>
31008
31009         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
31010         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
31011         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
31012         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
31013         invoke multibyte primitives.
31014
31015 2000-07-23  Paul Eggert  <eggert@twinsun.com>
31016
31017         * lib/quotearg.c:
31018         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
31019         so that mbstate_t is always defined.
31020
31021         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
31022         be 1 in at least one GCC installation, and this configuration
31023         error is likely to be common.  Ignoring MB_LEN_MAX hurts
31024         performance on hosts that have mbrtowc but have only unibyte
31025         locales, but I assume these hosts are rare.
31026
31027 2000-07-23  Paul Eggert  <eggert@twinsun.com>
31028
31029         * lib/mbswidth.c (_XOPEN_SOURCE):
31030         Don't define; this causes problems on Solaris 7.
31031         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
31032
31033 2000-07-23  Jim Meyering  <meyering@lucent.com>
31034
31035         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
31036         too: getgrgid, getpwuid, getuid.
31037
31038 2000-07-23  Jim Meyering  <meyering@lucent.com>
31039
31040         * lib/basename.c (base_name): Add an assertion.
31041
31042 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
31043
31044         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
31045         shadow its mbsinit function.
31046
31047 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
31048
31049         * lib/mbswidth.h: New file.
31050         * lib/mbswidth.c: New file.
31051         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
31052         (noinst_HEADERS): Add mbswidth.h.
31053
31054 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
31055
31056         * lib/config.charset: Add support for FreeBSD. Improve support for
31057         HP-UX and IRIX 6.
31058
31059 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
31060
31061         * m4/mbswidth.m4: New file.
31062         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
31063
31064 2000-07-15  Jim Meyering  <meyering@lucent.com>
31065
31066         * lib/makepath.c: Include quote.h.
31067         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
31068         corresponding argument in a `quote (...)' call.
31069         Give better diagnostics.
31070
31071         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
31072         (noinst_HEADERS): Add quote.h.
31073
31074         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
31075         from tar's src/misc.c.
31076         * lib/quote.h: New file.  Prototypes for same.
31077
31078 2000-07-14  Paul Eggert  <eggert@twinsun.com>
31079
31080         From a suggestion by Bruno Haible.
31081         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
31082         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
31083         to decide whether to define the BeOS workaround macro;
31084         this adjusts to the change to AC_MBSTATE_T.
31085
31086 2000-07-14  Jim Meyering  <meyering@lucent.com>
31087
31088         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
31089         jm_AC_TYPE_UINTMAX_T.
31090
31091 2000-07-13  Paul Eggert  <eggert@twinsun.com>
31092
31093         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
31094
31095         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
31096         quotearg_buffer_restyled): Add support for
31097         clocale_quoting_style.  Undo previous change to
31098         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
31099         and "{RIGHT QUOTATION MARK}" msgids.
31100
31101 2000-07-10  Paul Eggert  <eggert@twinsun.com>
31102
31103         From a suggestion by Bruno Haible.
31104         * m4/mbstate_t.m4 (AC_MBSTATE_T):
31105         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
31106         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
31107         and mbstate_t, to a single-part test that simply defines mbstate_t.
31108         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
31109         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
31110
31111 2000-07-10  Jim Meyering  <meyering@lucent.com>
31112
31113         * m4/strerror_r.m4: Mirror the correction made in autoconf.
31114
31115         * m4/gnu-source.m4: Output to confdefs.h directly.
31116         Suggestion from Akim Demaille.
31117
31118 2000-07-09  Paul Eggert  <eggert@twinsun.com>
31119
31120         The old behavior of quoting `like this' doesn't look good with
31121         newer, ISO-style fonts.  See:
31122         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
31123
31124         Instead, quote "like this" by default.  Let the translator
31125         tailor the locale-specific quoting behavior by providing
31126         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
31127
31128         * lib/quotearg.c (N_): New macro.
31129         (gettext_default): New function.
31130         (quotearg_buffer_restyled): Use
31131         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
31132         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
31133
31134 2000-07-09  Jim Meyering  <meyering@lucent.com>
31135
31136         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
31137         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
31138
31139         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
31140         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
31141
31142 2000-07-09  Jim Meyering  <meyering@lucent.com>
31143
31144         * lib/Most files: Update copyright dates to include 2000.
31145
31146 2000-07-08  Jim Meyering  <meyering@lucent.com>
31147
31148         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
31149         if not defined.
31150         (xgethostname): Remove now-unnecessary #ifdef.
31151         Move declaration of `err' into loop where it's used.
31152
31153 2000-07-05  Paul Eggert  <eggert@twinsun.com>
31154         and Bruno Haible  <haible@clisp.cons.org>
31155
31156         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
31157         only if the test for an object-type mbstate_t fails.  This
31158         prevents us from mistakenly reporting that mbstate_t is a
31159         system object type after we "#define mbstate_t int" to work
31160         around its lack.
31161
31162 2000-07-05  Paul Eggert  <eggert@twinsun.com>
31163         and Bruno Haible  <haible@clisp.cons.org>
31164
31165         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
31166
31167 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
31168
31169         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
31170         to strerror_r.
31171         Include <ctype.h> for use of isalpha.
31172
31173 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
31174
31175         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
31176         by allocating a larger buffer. Test the gethostname return value for
31177         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
31178         returns an error and ENAMETOOLONG isn't defined.
31179
31180 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
31181
31182         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
31183         dimension.
31184
31185 2000-07-04  Jim Meyering  <meyering@lucent.com>
31186
31187         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
31188         of the deprecated AC_CHECKING.
31189
31190 2000-07-04  Jim Meyering  <meyering@lucent.com>
31191
31192         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
31193         Reported by Bruno Haible.
31194
31195 2000-07-04  Jim Meyering  <meyering@lucent.com>
31196
31197         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
31198         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
31199         lacks mbrtowc.
31200
31201 2000-07-03  Paul Eggert  <eggert@twinsun.com>
31202
31203         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
31204         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
31205
31206 2000-07-03  Paul Eggert  <eggert@twinsun.com>
31207         and Bruno Haible  <haible@clisp.cons.org>
31208
31209         * lib/quotearg.c (mbrtowc):
31210         Assign to *pwc, and return 1 only if result is nonzero.
31211         (iswprint): Use ISPRINT when substituting our own mbrtowc.
31212
31213 2000-07-03  Jim Meyering  <meyering@lucent.com>
31214
31215         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
31216
31217 2000-07-03  Jim Meyering  <meyering@lucent.com>
31218
31219         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
31220         This is necessary to get a definition of e.g., UTMP_FILE on
31221         HP-UX 10.20.
31222         From Bob Proulx.
31223
31224 2000-07-02  Jim Meyering  <meyering@lucent.com>
31225
31226         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
31227
31228         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
31229         AC_LIBOBJ(function_name).
31230         * m4/chown.m4: Likewise.
31231         * m4/fnmatch.m4: Likewise.
31232         * m4/ftruncate.m4: Likewise.
31233         * m4/getgroups.m4: Likewise.
31234         * m4/getline.m4: Likewise.
31235         * m4/group-member.m4: Likewise.
31236         * m4/jm-macros.m4: Likewise.
31237         * m4/lstat.m4: Likewise.
31238         * m4/malloc.m4: Likewise.
31239         * m4/memcmp.m4: Likewise.
31240         * m4/nanosleep.m4: Likewise.
31241         * m4/putenv.m4: Likewise.
31242         * m4/realloc.m4: Likewise.
31243         * m4/regex.m4: Likewise.
31244         * m4/stat.m4: Likewise.
31245         * m4/strftime.m4: Likewise.
31246
31247 2000-07-02  Jim Meyering  <meyering@lucent.com>
31248
31249         * lib/quotearg.c (mbstate_t): Don't define here.
31250
31251 2000-07-02  Jim Meyering  <meyering@lucent.com>
31252
31253         * lib/nanosleep.c (SIGCONT): Define if not already defined.
31254
31255 2000-07-01  Jim Meyering  <meyering@lucent.com>
31256
31257         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
31258
31259 2000-07-01  Jim Meyering  <meyering@lucent.com>
31260
31261         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
31262         problem.
31263
31264 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
31265
31266         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
31267         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
31268
31269 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
31270
31271         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
31272         per change in ../m4/ls-mntd-fs.m4.
31273         (read_filesystem_list): Ignore symbolic links.
31274
31275 2000-06-29  Jim Meyering  <meyering@lucent.com>
31276
31277         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
31278         for declaration of strcmp.
31279
31280         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
31281
31282         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
31283         Avoid warning by casting result to `char *' to remove `const'.
31284
31285 2000-06-28  Jim Meyering  <meyering@lucent.com>
31286
31287         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
31288         included by quotearg.c, for which we perform this test.  From
31289         Bruno Haible.
31290
31291 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
31292
31293         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
31294         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
31295         <utmpx.h> exists, put readutmp.o into LIBOBJS.
31296
31297 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
31298
31299         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
31300
31301 2000-06-26  Paul Eggert  <eggert@twinsun.com>
31302
31303         savedir now sets errno on failure and invokes xmalloc to get memory.
31304         Fix a couple of other minor bugs while we're at it.
31305
31306         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
31307         (NAMLEN): Remove macro.
31308         (malloc, realloc): Remove decls.
31309         (stpcpy): Likewise.
31310         ("xalloc.h"): Include.
31311         (NAME_SIZE_DEFAULT): New macro.
31312         (savedir): Use xmalloc / xrealloc to allocate memory.
31313         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
31314         Skip "" directory entries.
31315         Use strlen to calculate directory entry length, since the old method
31316         is rarely used these days and isn't worth supporting.
31317         Don't use a pointer after freeing it.
31318         Check for integer overflow when calculating allocation size.
31319         Use memcpy to copy entries, instead of stpcpy.
31320         Set errno properly when returning NULL.
31321         Check for readdir error.
31322
31323 2000-06-26  Jim Meyering  <meyering@lucent.com>
31324
31325         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
31326
31327 2000-06-25  Jim Meyering  <meyering@lucent.com>
31328
31329         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
31330         Linux header bug when _XOPEN_SOURCE is defined to 500.
31331
31332 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
31333
31334         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
31335         deficiency.
31336
31337 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
31338
31339         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
31340         Include xalloc.h.
31341         Don't include <stdlib.h>.  Don't declare malloc, realloc.
31342
31343 2000-06-24  Jim Meyering  <meyering@lucent.com>
31344
31345         * m4/strerror_r.m4: Revive this file -- to try out an experimental
31346         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
31347         for which strerror does return char*, but which lacks a conveniently
31348         accessible declaration of the function.  If the compile-test says
31349         strerror_r doesn't work, then resort to a `run'-test that works on
31350         BeOS and segfaults on DEC Unix.
31351
31352 2000-06-24  Jim Meyering  <meyering@lucent.com>
31353
31354         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
31355
31356 2000-06-23  Paul Eggert  <eggert@twinsun.com>
31357
31358         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
31359         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
31360
31361 2000-06-23  Paul Eggert  <eggert@twinsun.com>
31362
31363         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
31364         (mbrtowc, mbstate_t): Define substitutes if
31365         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
31366         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
31367         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
31368
31369 2000-06-23  Jim Meyering  <meyering@lucent.com>
31370
31371         * m4/afs.m4: Add missing AC_MSG_RESULT.
31372         Reported by Bruno Haible.
31373
31374         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
31375         Suggestion from Bruno Haible.
31376
31377 2000-06-23  Jim Meyering  <meyering@lucent.com>
31378
31379         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
31380
31381 2000-06-21  Jim Meyering  <meyering@lucent.com>
31382
31383         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
31384
31385 2000-06-21  Jim Meyering  <meyering@lucent.com>
31386
31387         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
31388         (noinst_HEADERS): Add getstr.h.
31389
31390         * lib/getline.c (getstr): Move into a separate file.
31391         * lib/getstr.c (getstr): New file, extracted from getline.c, with
31392         the following changes: new parameter, delim2; both delim[12]
31393         parameters have type `int', not `char'.  The latter would lose
31394         with 8-bit delimiters.
31395         * lib/getstr.h: New file.
31396
31397 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
31398
31399         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
31400         than 1024, return a memory chunk of least possible size, instead
31401         of size PATH_MAX + 2. In the loop, increment the size proportionally.
31402         Use free/xmalloc instead of xrealloc to avoid copying for very long
31403         paths.
31404
31405 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
31406
31407         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
31408         the empty string.
31409
31410 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
31411
31412         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
31413         address, not strdup.  Include <stdlib.h> and don't declare free().
31414
31415 2000-06-19  Jim Meyering  <meyering@lucent.com>
31416
31417         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
31418
31419 2000-06-18  Jim Meyering  <meyering@lucent.com>
31420
31421         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
31422
31423         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
31424         `checking whether...' message to be consistent with that of the
31425         lstat test.
31426
31427 2000-06-18  Jim Meyering  <meyering@lucent.com>
31428
31429         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
31430         Besides, these days every porting target provides a mkdir function.
31431
31432         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
31433         needed. (this snippet comes from src/system.h).
31434
31435 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
31436
31437         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
31438
31439 2000-06-15  Paul Eggert  <eggert@twinsun.com>
31440
31441         * lib/human.c (adjust_value): New function.
31442         (human_readable_inexact): Apply rounding style even when
31443         printing approximate values.
31444
31445 2000-06-14  Paul Eggert  <eggert@twinsun.com>
31446
31447         * lib/human.c (human_readable_inexact): Allow an input block
31448         size that is not a multiple of the output block size, and vice versa.
31449         Reported by Piergiorgio Sartor.
31450
31451 2000-06-14  Paul Eggert  <eggert@twinsun.com>
31452
31453         * lib/getdate.y (get_date): Apply relative times after time
31454         zone indicator, not before.  Reported by Todd A. Jacobs.
31455
31456 2000-06-13  Jim Meyering  <meyering@lucent.com>
31457
31458         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
31459
31460         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
31461
31462 2000-06-12  Paul Eggert  <eggert@twinsun.com>
31463
31464         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
31465
31466 2000-06-12  Jim Meyering  <meyering@lucent.com>
31467
31468         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
31469         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
31470         optional argument.
31471         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
31472         the optional argument, `lib'.
31473
31474 2000-06-08  Jim Meyering  <meyering@lucent.com>
31475
31476         * m4/largefile.m4: Remove file (now that it's part of autoconf).
31477
31478 2000-06-04  Paul Eggert  <eggert@twinsun.com>
31479
31480         Rewrite largefile configuration so that we don't need to run
31481         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
31482         AC_CANONICAL_HOST in configure.in -- jmm]
31483
31484         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
31485         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
31486         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
31487         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
31488         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
31489         All uses changed.
31490         Instead of inspecting the output of getconf, try to compile the
31491         test program without and with the macro definition.
31492         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
31493         for getconf.  Instead, check for the needed flags by compiling
31494         test programs.
31495
31496 2000-06-04  Paul Eggert  <eggert@twinsun.com>
31497
31498         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
31499
31500 2000-06-04  Jim Meyering  <meyering@lucent.com>
31501
31502         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
31503         SunOS 4.1.4 for which gid_t is an unsigned type.
31504
31505 2000-06-03  Jim Meyering  <meyering@lucent.com>
31506
31507         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
31508         now that autoconf requires that.
31509
31510         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
31511         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
31512         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
31513
31514 2000-06-03  Jim Meyering  <meyering@lucent.com>
31515
31516         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
31517
31518 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
31519
31520         * m4/glibc21.m4: New file.
31521         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
31522
31523 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
31524
31525         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
31526         newer, don't install charset.alias.
31527         * lib/config.charset: Change the Linux/glibc rules so they become empty
31528         on glibc-2.1 or newer.
31529
31530 2000-06-02  Jim Meyering  <meyering@lucent.com>
31531
31532         * lib/mountlist.c: Back out last change.  Instead, do this...
31533         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
31534         me_dummy member using the same `ignore'-testing code.
31535         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
31536         fs_type strings.
31537         From Mark D. Roth.
31538
31539 2000-05-29  Jim Meyering  <meyering@lucent.com>
31540
31541         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
31542         mounts with the `ignore' attribute.  Based on a patch from
31543         Mark D. Roth.
31544
31545 2000-05-28  Jim Meyering  <meyering@lucent.com>
31546
31547         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
31548         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
31549         * m4/stat.m4: Likewise.
31550         * m4/lstat.m4: Likewise.
31551         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
31552
31553         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
31554         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
31555
31556 2000-05-26  Jim Meyering  <meyering@lucent.com>
31557
31558         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
31559
31560 2000-05-24  Jim Meyering  <meyering@lucent.com>
31561
31562         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
31563         autoconf requires that.
31564         * m4/lib-check.m4: Likewise.
31565         * m4/jm-macros.m4: Likewise.
31566         * m4/strftime.m4: Likewise.
31567
31568         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
31569         AC_CHECK_DECLS, now that autoconf requires that.
31570
31571 2000-05-22  Jim Meyering  <meyering@lucent.com>
31572
31573         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
31574         * m4/lstat.m4: Likewise.
31575
31576 2000-05-22  Jim Meyering  <meyering@lucent.com>
31577
31578         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
31579
31580 2000-05-20  Jim Meyering  <meyering@lucent.com>
31581
31582         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
31583         (jm_PREREQ): Use it.
31584
31585 2000-05-18  Jim Meyering  <meyering@lucent.com>
31586
31587         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
31588         back, too, since it may have been modified by allocate_entry.
31589         (hash_delete): Rewrite to use neither the assignment operator
31590         nor the comma operator in an if-expression.
31591
31592 2000-05-15  Paul Eggert  <eggert@twinsun.com>
31593
31594         * lib/closeout.c:
31595         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
31596         Remove; no longer needed.
31597         "quotearg.h": Add include.
31598         (file_name): Do not bother to explicitly initialize to NULL; it's less
31599         efficient on some hosts.
31600         (close_stdout_status): Remove test as to whether stdout was already
31601         closed; it breaks for the case "echo x | sort >&-".
31602         Quote file name colons.
31603         Do not assume that _("write error") lacks format strings.
31604
31605 2000-05-15  Jim Meyering  <meyering@lucent.com>
31606
31607         * lib/version-etc.c (version_etc_copyright): Update the copyright
31608         string used in all --version output.
31609
31610 2000-05-14  Jim Meyering  <meyering@lucent.com>
31611
31612         * lib/closeout.c (close_stdout_set_file_name): New function.
31613         (close_stdout_status): Use new file-scoped global.
31614         Return right away if fstat says the stdout file descriptor is invalid.
31615         * lib/closeout.h (close_stdout_set_file_name): Declare.
31616
31617 2000-05-10  Jim Meyering  <meyering@lucent.com>
31618
31619         * lib/closeout.c [default_exit_status]: New file-scoped variable.
31620         (close_stdout_set_status): New function.
31621         * lib/closeout.h (close_stdout_set_status): Declare.
31622
31623 2000-05-09  Jim Meyering  <meyering@lucent.com>
31624
31625         * m4/gettext.m4: Rename this...
31626         * m4/libintl.m4: ...to this.
31627
31628 2000-05-08  Jim Meyering  <meyering@lucent.com>
31629
31630         * lib/long-options.c: Don't include closeout.h.
31631         (parse_long_options): Don't call close_stdout for --version.
31632
31633 2000-05-06  Paul Eggert  <eggert@twinsun.com>
31634
31635         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
31636         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
31637         2.1.3 bug.  This avoids a clash when files like regex.c define
31638         _GNU_SOURCE.
31639
31640 2000-05-06  Jim Meyering  <meyering@lucent.com>
31641
31642         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
31643         (AC_REPLACE_FUNCS): Add strnlen.
31644
31645         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
31646         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
31647
31648         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
31649         AC_SEARCH_LIBS call for nanosleep.
31650         (LIB_NANOSLEEP): Set and AC_SUBST.
31651
31652 2000-05-06  Jim Meyering  <meyering@lucent.com>
31653
31654         * lib/strnlen.c: Undefine __strnlen and strnlen.
31655         [!weak_alias]: Define __strnlen to strnlen.
31656
31657         * lib/atexit.c: New file, from libiberty.
31658
31659 2000-05-06  Jim Meyering  <meyering@lucent.com>
31660
31661         * lib/closeout.c (close_stdout_status): Also check for errors on the
31662         stderr stream.
31663
31664 2000-05-05  Jim Meyering  <meyering@lucent.com>
31665
31666         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
31667         AC_SEARCH_LIBS call for clock_gettime.
31668         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
31669
31670         * m4/search-libs.m4: Update from autoconf.
31671
31672         su doesn't work on Solaris 2.6.
31673         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
31674         <shadow.h>.  Reported by Dragos Harabor.
31675
31676 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
31677
31678         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
31679         memcpy instead of xmalloc, xrealloc, path_concat.
31680         (locale_charset): Treat empty environment variables as absent.
31681         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
31682
31683 2000-05-04  Jim Meyering  <meyering@lucent.com>
31684
31685         * lib/getopt.c: Update from glibc.
31686         * lib/obstack.c: Likewise.
31687         * lib/obstack.h: Likewise.
31688         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
31689         file
31690
31691         * lib/regex.h: Likewise.
31692         * lib/strndup.c: Likewise.
31693         * lib/strnlen.c: New file, from glibc.
31694
31695 2000-05-03  Jim Meyering  <meyering@lucent.com>
31696
31697         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
31698
31699 2000-05-02  Paul Eggert  <eggert@twinsun.com>
31700
31701         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
31702         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
31703         compile-time test, rather than inspecting host and OS, to
31704         decide whether to define _LARGEFILE_SOURCE.
31705
31706 2000-05-01  Jim Meyering  <meyering@lucent.com>
31707
31708         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
31709
31710         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
31711         Based on a patch from Bruno Haible.
31712
31713 2000-05-01  Jim Meyering  <meyering@lucent.com>
31714
31715         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
31716
31717 2000-04-29  Jim Meyering  <meyering@lucent.com>
31718
31719         * lib/path-concat.c: Declare strdup only if it's not defined.
31720         * lib/canon-host.c: Likewise.
31721
31722 2000-04-28  Jim Meyering  <meyering@lucent.com>
31723
31724         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
31725         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
31726         is included first, then limits.h is included by locale.h by libintl.h.
31727         From John David Anglin.
31728
31729 2000-04-25  Jim Meyering  <meyering@lucent.com>
31730
31731         * lib/makepath.c (S_IRWXUGO): Define.
31732         (make_path): Always perform explicit chmod if MODE specifies any
31733         of the `special' permission bits.  Prompted by a bug report against
31734         install from Mate Wierdl and Joost van Baal.
31735
31736 2000-04-18  Jim Meyering  <meyering@lucent.com>
31737
31738         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
31739         (jm_PREREQ): Use it.
31740
31741 2000-04-18  Jim Meyering  <meyering@lucent.com>
31742
31743         * lib/README: New file.
31744
31745         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
31746         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
31747
31748 2000-04-17  Jim Meyering  <meyering@lucent.com>
31749
31750         Get it right :-)
31751         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
31752         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
31753         Suggestion from Akim Demaille.
31754
31755 2000-04-17  Jim Meyering  <meyering@lucent.com>
31756
31757         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
31758         the definition of it to rpl_strftime also defined-away the system's
31759         declaration.
31760
31761 2000-04-15  Jim Meyering  <meyering@lucent.com>
31762
31763         Use `C' to denote so-called `contiguous' files, the same way
31764         that tar does.
31765         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
31766         (ftypelet): Use S_ISCTG.
31767         From Michael Deutschmann.
31768
31769 2000-04-14  Jim Meyering  <meyering@lucent.com>
31770
31771         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
31772         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
31773         clobbered.
31774
31775 2000-04-14  Jim Meyering  <meyering@lucent.com>
31776
31777         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
31778
31779 2000-04-13  Jim Meyering  <meyering@lucent.com>
31780
31781         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
31782         AH_VERBATIM to insert required #ifndef into config.h.in.
31783         Suggestion from Akim Demaille.
31784
31785 2000-04-12  Jim Meyering  <meyering@lucent.com>
31786
31787         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
31788         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
31789         Christian Krackowizer.
31790
31791         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
31792         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
31793         (AC_SYS_LARGEFILE): Require.
31794         (AM_C_PROTOTYPES): Require.
31795
31796 2000-04-08  Jim Meyering  <meyering@lucent.com>
31797
31798         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
31799         names don't conflict.  Reported by Eli Zaretskii.
31800
31801 2000-04-07  Jim Meyering  <meyering@lucent.com>
31802
31803         * lib/putenv.c: Move inclusion of errno.h so it follows that of
31804         sys/types.h, to work around system header problems on AIX 3.2.5.
31805         From Bruno Haible.
31806
31807 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
31808
31809         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
31810         bug.  Deal with the different error behavior of Irix iconv.
31811
31812 2000-04-05  Paul Eggert  <eggert@twinsun.com>
31813
31814         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
31815         IRIX if the installer said otherwise.
31816
31817 2000-04-05  Jim Meyering  <meyering@lucent.com>
31818
31819         Portability tweaks required for ultrix4.3.
31820         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
31821         (jm_CHECK_DECLS): Add getutent to the list of functions.
31822         (_jm_DECL_HEADERS): Add utmpx.h.
31823         From John David Anglin.
31824
31825         * m4/strftime.m4: Back out the 2000-04-02 change.
31826         Instead of that change, simply undefine putenv in the test program.
31827
31828 2000-04-05  Jim Meyering  <meyering@lucent.com>
31829
31830         Portability tweaks required for ultrix4.3.
31831         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
31832         getutent.
31833         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
31834         * lib/canon-host.c: Declare strdup.
31835         * lib/path-concat.c: Likewise.
31836         From John David Anglin.
31837
31838 2000-04-04  Jim Meyering  <meyering@lucent.com>
31839
31840         Be more DOS 8.3-friendly.
31841         * lib/ref-add.sin: Renamed from ref-add.sed.in.
31842         * lib/ref-del.sin: Renamed from ref-del.sed.in.
31843         * lib/Makefile.am: Reflect renaming.
31844         Reported by Eli Zaretskii.
31845
31846         Use a temporary file name that won't clash with `charset.alias'
31847         in the DOS 8.3 name space.
31848         * lib/Makefile.am (charset_tmp): Define.
31849         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
31850         (uninstall-local): Likewise.
31851         Reported by Eli Zaretskii.
31852
31853 2000-04-03  Jim Meyering  <meyering@lucent.com>
31854
31855         * m4/gettext.m4: Fix typo in comment.
31856
31857         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
31858         textutils/configure.in).  Suggestion from Paul Eggert.
31859         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
31860
31861 2000-04-02  Paul Eggert  <eggert@twinsun.com>
31862
31863         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
31864         variable in the shell rather than using putenv, which isn't
31865         portable.  This avoids the configure-time inter-test dependency
31866         on the potentially-renamed putenv function.
31867
31868 2000-03-30  Paul Eggert  <eggert@twinsun.com>
31869
31870         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
31871         before checking struct stat.st_blksize, so that
31872         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
31873
31874 2000-03-29  Paul Eggert  <eggert@twinsun.com>
31875
31876         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
31877         since strftime.c uses HAVE_STRFTIME to decide whether to use
31878         the underlying strftime.
31879
31880 2000-03-29  Paul Eggert  <eggert@twinsun.com>
31881
31882         * lib/time/strftime.c (my_strftime): Make sure we call the system
31883         strftime, not ourselves, when invoking the underlying strftime.
31884
31885 2000-03-24  Jim Meyering  <meyering@lucent.com>
31886
31887         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
31888         (charset_alias): Define.
31889         (install-exec-local): Factor out common code.
31890         (uninstall-local): Split lines longer than 80.
31891         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
31892         (SUFFIXES): Define.
31893         (.sed.in.sed): New rule.  Don't redirect directly to $@.
31894         (CLEANFILES): Add ref-add.sed and ref-del.sed.
31895
31896 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
31897
31898         * lib/config.charset: Output a line containing "Packages using this
31899         file".
31900         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
31901         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
31902         ref-del.sed): New rules.
31903
31904 2000-03-17  Jim Meyering  <meyering@lucent.com>
31905
31906         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
31907         Otherwise, include <strings.h>
31908
31909 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
31910
31911         * lib/unicodeio.c (utf8_wctomb): New function.
31912         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
31913         format instead of in UCS-4 with platform dependent endianness.
31914
31915 2000-03-10  Jim Meyering  <meyering@lucent.com>
31916
31917         * m4/lib-check.m4: Look for getspnam in -lgen, too.
31918         From Marco Franzen.
31919
31920 2000-03-07  Paul Eggert  <eggert@twinsun.com>
31921
31922         * lib/savedir.c (savedir): Work even if directory size is
31923         negative; this can happen with some screwy NFS configurations.
31924
31925 2000-03-06  Jim Meyering  <meyering@lucent.com>
31926
31927         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
31928         if it's NULL (because we ran out of memory).  From Bruno Haible.
31929
31930 2000-03-05  Jim Meyering  <meyering@lucent.com>
31931
31932         * lib/localcharset.c ("path-concat.h"): Include.
31933         (get_charset_aliases): Use path_concat instead of ANSI string
31934         concatenation.
31935
31936         * lib/unicodeio.h (PARAMS): Define.
31937         Use it to guard prototype.
31938
31939 2000-03-04  Jim Meyering  <meyering@lucent.com>
31940
31941         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
31942         for lib/localcharset.c.
31943
31944 2000-03-04  Jim Meyering  <meyering@lucent.com>
31945
31946         * lib/Makefile.am (install-exec-local): Create $(libdir) before
31947         installing into it.
31948         (uninstall-local): Uncomment this rule so `make distcheck' works
31949         once again.
31950
31951         * lib/unicodeio.c (<errno.h>): Include it.
31952         (errno): Declare if not defined.
31953
31954         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
31955
31956         * lib/config.charset: New version, incorporating remarks from a linux
31957         i18n mailing list.  From Bruno Haible.
31958
31959 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
31960
31961         * m4/codeset.m4: New file.
31962         * m4/iconv.m4: New file.
31963         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
31964
31965 2000-03-03  Jim Meyering  <meyering@lucent.com>
31966
31967         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
31968
31969 2000-03-02  Jim Meyering  <meyering@lucent.com>
31970
31971         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
31972         the messages come out on separate lines.
31973
31974         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
31975         rather than jm_CHECK_DECLARATIONS.
31976         * m4/decl.m4: Remove now-unused file.
31977
31978         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
31979         geteuid.
31980
31981 2000-03-02  Jim Meyering  <meyering@lucent.com>
31982
31983         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
31984
31985 2000-03-01  Jim Meyering  <meyering@lucent.com>
31986
31987         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
31988         * lib/unicodeio.c: Likewise.
31989
31990 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
31991
31992         * lib/config.charset: New file.
31993         * lib/localcharset.c: New file.
31994         * lib/unicodeio.h, lib/unicodeio.c: New files.
31995         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
31996         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
31997         (noinst_HEADERS): Add unicodeio.h.
31998         (all-local, install-exec-local, charset.alias): New targets.
31999
32000 2000-02-28  Paul Eggert  <eggert@twinsun.com>
32001
32002         * lib/quotearg.c (ALERT_CHAR): New macro.
32003         (quotearg_buffer_restyled): Use it.
32004
32005 2000-02-27  Jim Meyering  <meyering@lucent.com>
32006
32007         * m4/check-decl.m4: Add getenv to the list.
32008
32009 2000-02-27  Jim Meyering  <meyering@lucent.com>
32010
32011         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
32012         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
32013
32014         * lib/backupfile.c: Guard inclusion of stdlib.h with
32015         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
32016         Declare malloc if needed.
32017
32018         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
32019         `#ifndef HAVE_DECL..'
32020         now that autoconf always defines the HAVE_DECL_ symbols.
32021         * lib/human.c: Likewise.
32022         * lib/same.c: Likewise.
32023         * lib/strtoumax.c: Likewise.
32024
32025         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
32026         declaration check was not run.
32027         * lib/hash.c: Likewise.
32028         * lib/human.c: Likewise.
32029         * lib/same.c: Likewise.
32030         * lib/strtoumax.c: Likewise.
32031
32032         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
32033         `.', then first look up the entire `.'-containing string as a login
32034         name.
32035
32036 2000-02-23  Jim Meyering  <meyering@lucent.com>
32037
32038         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
32039         in place of my hack.
32040
32041 2000-02-18  Paul Eggert  <eggert@twinsun.com>
32042
32043         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
32044         (textint): New typedef.
32045         (parser_control): Member year changed from int to textint.
32046         All uses changed.
32047         (YYSTYPE): Removed; replaced by %union with int and textint members.
32048         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
32049         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
32050         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
32051         (tSNUMBER, tUNUMBER): Now of type <textintval>.
32052         (date, number, to_year): Use width of number in digits, not its value,
32053         to determine whether it's a 2-digit year, or a 2-digit time.
32054         (yylex): Store number of digits of numeric tokens.
32055         Reported by John Kendall.
32056
32057         (parser_control): Changed from struct parser_control to typedef (for
32058         consistency).  All uses changed.
32059
32060         (tID): Removed; not used.
32061         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
32062
32063 2000-02-14  Paul Eggert  <eggert@twinsun.com>
32064
32065         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
32066         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
32067
32068 2000-02-12  Jim Meyering  <meyering@lucent.com>
32069
32070         * lib/userspec.c (ISDIGIT): Define it.
32071         (isdigit): Remove definition.
32072         (is_number): Use ISDIGIT, not isdigit.
32073         <libintl.h>: Include.
32074         (_ and N_): Define.
32075         (parse_user_spec): Mark translatable strings.
32076
32077 2000-02-10  Jim Meyering  <meyering@lucent.com>
32078
32079         With these changes, nanosleep.[ch] are finally enough like the other
32080         lib/* replacement files to compile on a few more losing systems.
32081
32082         * lib/nanosleep.h: Don't include config.h.
32083         Remove prototype from declaration of nanosleep.
32084         (PARAMS): Remove now-unneeded definition.
32085         * lib/nanosleep.c: #undef nanosleep.
32086         (rpl_nanosleep): Rename from nanosleep.
32087
32088 2000-02-10  Jim Meyering  <meyering@lucent.com>
32089
32090         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
32091         gnu_nanosleep to rpl_nanosleep.
32092
32093 2000-02-09  Jim Meyering  <meyering@lucent.com>
32094
32095         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
32096         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
32097
32098 2000-02-08  Akim Demaille  <akim@epita.fr>
32099
32100         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
32101         `[' and `]' and remove uses of `changequote'.
32102         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
32103         (AC_SYS_LARGEFILE): Likewise.
32104         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
32105         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
32106         of changequote.
32107         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
32108         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
32109         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
32110         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
32111
32112 2000-02-05  Jim Meyering  <meyering@lucent.com>
32113
32114         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
32115         Remove explicit use of AC_HEADER_TIME.  It is required by
32116         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
32117         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
32118         in autoconf whereby the expansion of the latter ended up preceding
32119         the expansion of its prerequisite, AC_HEADER_TIME.
32120         Reported by Volker Borchert.
32121
32122 2000-02-03  Jim Meyering  <meyering@lucent.com>
32123
32124         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
32125
32126 2000-02-03  Jim Meyering  <meyering@lucent.com>
32127
32128         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
32129         rather than with `#if HAVE_UTMPNAME'.
32130
32131 2000-02-02  Jim Meyering  <meyering@lucent.com>
32132
32133         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
32134         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
32135         Reported by Eli Zaretskii.
32136
32137 2000-02-01  Jim Meyering  <meyering@lucent.com>
32138
32139         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
32140
32141 2000-01-31  Jim Meyering  <meyering@lucent.com>
32142
32143         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
32144         functions.  Add the time.h and sys/time.h headers along with the
32145         AC_REQUIRE'ment of AC_HEADER_TIME.
32146
32147 2000-01-31  Jim Meyering  <meyering@lucent.com>
32148
32149         * lib/nanosleep.h (nanosleep): Guard declaration with
32150         `#if ! HAVE_DECL_NANOSLEEP'.
32151         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
32152         the declaration in that vendor's sys/timers.h.
32153         Reported by Christian Krackowizer.
32154
32155         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
32156         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
32157         (ISPRINT): Likewise.
32158         Reported by Tom Tromey.
32159
32160 2000-01-30  Jim Meyering  <meyering@lucent.com>
32161
32162         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
32163
32164         * m4/prereq.m4 (utmp_includes): Define.
32165         Check for ut_user and ut_name members in both struct utmpx
32166         and struct utmp.
32167
32168 2000-01-30  Jim Meyering  <meyering@lucent.com>
32169
32170         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
32171         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
32172         header files where only utmpx.ut_user is declared.
32173
32174         * lib/readutmp.h (UT_USER): Define.
32175
32176 2000-01-29  Jim Meyering  <meyering@lucent.com>
32177
32178         * m4/lib-check.m4: New file containing library-related checks from
32179         fileutils and sh-utils (textutils had none).
32180
32181 2000-01-28  Jim Meyering  <meyering@lucent.com>
32182
32183         * m4/perl.m4: Change format of warning message to look more like that
32184         from the missing script.  Suggestion from François Pinard.
32185
32186 2000-01-25  Jim Meyering  <meyering@lucent.com>
32187
32188         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
32189         well as time.h in the compile check.
32190         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
32191         Fix typo in cross-compiling case: s/yes/no/.
32192
32193 2000-01-23  Jim Meyering  <meyering@lucent.com>
32194
32195         * m4/jm-macros.m4: Move df-related tests here from
32196         fileutils/configure.in
32197
32198         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
32199         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
32200
32201         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
32202         s/space/ac_fsusage_space/.
32203         (jm_FILE_SYSTEM_USAGE): Take two parameters.
32204
32205         * m4/ftruncate.m4: New file (derived from part of
32206         fileutils/configure.in).
32207         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
32208         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
32209
32210         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
32211         AC_SUBST these here, rather than just in sh-util/configure.in, so
32212         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
32213         all the same.
32214         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
32215         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
32216         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
32217         (AC_SUBST(POW_LIBM)): Likewise.
32218         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
32219
32220 2000-01-23  Jim Meyering  <meyering@lucent.com>
32221
32222         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
32223         obstack.c.
32224
32225 2000-01-22  Jim Meyering  <meyering@lucent.com>
32226
32227         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
32228
32229         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
32230
32231         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
32232         configure.in
32233         (AC_CHECK_HEADERS): Likewise for sh-utils.
32234         (AC_CHECK_HEADERS): Likewise for textutils.
32235         Merge the three lists of headers.
32236
32237         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
32238         from fileutils' configure.in.
32239
32240         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
32241         code. Moved tests into their own function (_jm_DECL_HEADERS) in
32242         check-decl.m4.
32243
32244         * m4/check-decl.m4: Use #if rather than #ifdef.
32245         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
32246         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
32247         (_jm_DECL_HEADERS): Define new function.
32248         (jm_CHECK_DECLARATIONS): Require it.
32249
32250 2000-01-22  Jim Meyering  <meyering@lucent.com>
32251
32252         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
32253         [! HAVE_DECL_STRTOULL]: Declare strtoull.
32254         Required for some AIX systems.  Reported by Christian Krackowizer.
32255         [TESTING] (main): New function.
32256
32257         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
32258         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
32259         letters.
32260
32261         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
32262         iswprint.
32263
32264         * lib/strverscmp.c (ISDIGIT): Define.
32265         (strverscmp): Use ISDIGIT, not isdigit.
32266
32267 2000-01-19  Jim Meyering  <meyering@lucent.com>
32268
32269         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
32270         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
32271         defines `struct timespec' in <sys/time.h>
32272
32273         * m4/c-bs-a.m4: Remove uses of changequote altogether.
32274         Thanks to Akim for explaining.
32275
32276 2000-01-17  Paul Eggert  <eggert@twinsun.com>
32277
32278         * lib/nanosleep.c (nanosleep):
32279         Don't use SA_INTERRUPT to decide whether to call sigaction, as
32280         POSIX.1 doesn't require SA_INTERRUPT and some systems
32281         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
32282         it's been part of POSIX.1 since day 1 (in 1988).
32283
32284 2000-01-17  Jim Meyering  <meyering@lucent.com>
32285
32286         * lib/interlock: Remove unused file.  Reported by François Pinard.
32287
32288 2000-01-16  Paul Eggert  <eggert@twinsun.com>
32289
32290         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
32291         alert, backslash, formfeed, and vertical tab unnecessarily in
32292         shell quoting style.
32293
32294 2000-01-16  Jim Meyering  <meyering@lucent.com>
32295
32296         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
32297         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
32298         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
32299         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
32300
32301 2000-01-16  Jim Meyering  <meyering@lucent.com>
32302
32303         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
32304         because the latter didn't work.
32305
32306 2000-01-15  Jim Meyering  <meyering@lucent.com>
32307
32308         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
32309         (AC_REPLACE_FUNCS): Add memcpy and memset.
32310         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
32311         Add strpbrk.
32312         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
32313
32314 2000-01-12  Jim Meyering  <meyering@lucent.com>
32315
32316         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
32317         (jm_PREREQ): Use it.
32318         (jm_PREREQ_READUTMP): New macro.
32319         (jm_PREREQ): Use it.
32320
32321 2000-01-11  Paul Eggert  <eggert@twinsun.com>
32322
32323         Quote multibyte characters correctly.
32324         * m4/c-bs-a.m4: New file.
32325         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
32326         (jm_PREREQ): Use it.
32327
32328 2000-01-11  Paul Eggert  <eggert@twinsun.com>
32329
32330         * m4/uintmax_t.m4: Port to autoconf 2.13.
32331
32332 2000-01-08  Jim Meyering  <meyering@ascend.com>
32333
32334         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
32335         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
32336
32337 2000-01-04  Jim Meyering  <meyering@ascend.com>
32338
32339         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
32340         jm_STRUCT_DIRENT_D_TYPE.
32341         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
32342         jm_STRUCT_DIRENT_D_INO.
32343         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
32344         jm_STRUCT_UTIMBUF.
32345         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
32346         renamings.
32347         * m4/utime.m4: Likewise.
32348
32349         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
32350         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
32351
32352 2000-01-03  Paul Eggert  <eggert@twinsun.com>
32353
32354         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
32355         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
32356
32357 2000-01-02  Jim Meyering  <meyering@ascend.com>
32358
32359         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
32360         remember if this is necessary.
32361
32362 1999-12-26  Jim Meyering  <meyering@ascend.com>
32363
32364         * m4/jm-macros.m4: Use it here.
32365         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
32366
32367 1999-12-23  Jim Meyering  <meyering@ascend.com>
32368
32369         * m4/jm-macros.m4: Check for clock_gettime (moved from
32370         fileutils/configure.in)
32371         Check for gettimeofday.
32372
32373 1999-12-20  Jim Meyering  <meyering@ascend.com>
32374
32375         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
32376         autoconf-2.14a-1999-12-20.
32377
32378 1999-12-19  Jim Meyering  <meyering@ascend.com>
32379
32380         * m4/lstat-slash.m4: New file.
32381         * m4/jm-macros.m4: Use the new macro:
32382         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
32383
32384 1999-12-07  Jim Meyering  <meyering@ascend.com>
32385
32386         * m4/perl.m4: Require that File::Compare be available, too.
32387         Too many systems seem to lack it.
32388
32389         * m4/strftime.m4: Add checks for most of the cpp macros tested in
32390         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
32391
32392 1999-11-18  Paul Eggert  <eggert@twinsun.com>
32393
32394         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
32395         problem with the QNX 4.25 shell, which doesn't propagate exit
32396         status of failed commands inside shell assignments.
32397
32398 1999-11-17  Jim Meyering  <meyering@ascend.com>
32399
32400         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
32401
32402 1999-11-07  Jim Meyering  <meyering@ascend.com>
32403
32404         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
32405
32406 1999-11-06  Jim Meyering  <meyering@ascend.com>
32407
32408         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
32409         * m4/jm-macros.m4 (jm_MACROS): Use it here.
32410
32411 1999-11-05  Jim Meyering  <meyering@ascend.com>
32412
32413         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
32414         configure.in of textutils, fileutils, and sh-utils into this one
32415         (shared between those packages) file.
32416         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
32417         AC_STRUCT_ST_BLKSIZE.
32418
32419 1999-11-03  Jim Meyering  <meyering@ascend.com>
32420
32421         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
32422         of AC_CHECK_TYPE checks includes unistd.h.
32423         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
32424         Suggestion from Akim Demaille.
32425
32426 1999-10-30  Jim Meyering  <meyering@ascend.com>
32427
32428         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
32429         m4-quoted string.
32430         * m4/ls-mntd-fs.m4: Likewise.
32431         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
32432         * m4/jm-winsz1.m4: Likewise.
32433
32434         * m4/const.m4: Remove file, since the fix made it into the experimental
32435         version of autoconf.
32436         * m4/mktime.m4: Likewise.
32437
32438         * m4/check-type.m4: Remove file, now that the latest version of
32439         AC_CHECK_TYPE takes a third arg to specify additional #includes.
32440
32441         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
32442         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
32443         AC_CHECK_TYPE.
32444
32445 1999-10-04  Jim Meyering  <meyering@ascend.com>
32446
32447         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
32448
32449 1999-09-22  Paul Eggert  <eggert@twinsun.com>
32450
32451         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
32452         2.95.1 bug with HP-UX 10.20.
32453
32454 1999-09-17  Jim Meyering  <meyering@ascend.com>
32455
32456         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
32457         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
32458         due to missing strdup (against sh-utils-2.0).
32459
32460 1999-08-29  Jim Meyering  <meyering@ascend.com>
32461
32462         * m4/jm-macros.m4: Require jm_BISON.
32463         * m4/bison.m4: New file.
32464
32465 1999-08-17  Paul Eggert  <eggert@twinsun.com>
32466
32467         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
32468         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
32469
32470 1999-08-05  Jim Meyering  <meyering@ascend.com>
32471
32472         * m4/getline.m4: Rename test file from conftestdata to conftest.data
32473         to avoid conflicts with `conftest' on 8+3 filesystems.
32474         Suggestion from Eli Zaretskii.
32475
32476 1999-08-04  Jim Meyering  <meyering@ascend.com>
32477
32478         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
32479         fileutils and sh-utils (textutils's getline test was inadequate).
32480         (AM_FUNC_GETLINE): Run this test.
32481         (AC_CHECK_FUNCS): Check for getdelim.
32482         Reported by Bob Proulx.
32483
32484 1999-08-02  Jim Meyering  <meyering@ascend.com>
32485
32486         * m4/jm-macros.m4: Add a comment.
32487
32488 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32489
32490         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
32491         <inttypes.h> defines strtoumax as a macro (and not as a
32492         function).
32493
32494 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32495
32496         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
32497         that we can shift, multiply and divide unsigned long long
32498         values; Ultrix cc can't do it.
32499
32500 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32501
32502         * m4/mktime.m4: New file, which is a preview of what should appear
32503         in the next public autoconf release.
32504
32505 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32506
32507         * m4/lfs.m4: Remove this file.
32508         * m4/largefile.m4: New file.  It contains the old contents of
32509         lfs.m4, except that all names with prefix AC_LFS have been
32510         changed to use the prefix AC_SYS_LARGEFILE instead, to be
32511         compatible with future autoconf versions.  Also, some minor m4
32512         quoting problems have been fixed.
32513
32514 1999-08-01  Paul Eggert  <eggert@twinsun.com>
32515
32516         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
32517         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
32518         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
32519         and simplify the shell code.
32520
32521 1999-08-01  Jim Meyering  <meyering@ascend.com>
32522
32523         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
32524         m4.
32525
32526 1999-07-20  Jim Meyering  <meyering@ascend.com>
32527
32528         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
32529
32530 1999-07-15  Jim Meyering  <meyering@ascend.com>
32531
32532         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
32533
32534 1999-05-22  Jim Meyering  <meyering@ascend.com>
32535
32536         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
32537
32538 1999-05-20  Jim Meyering  <meyering@ascend.com>
32539
32540         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
32541         Add a colon after each `then' in case $4 is empty.
32542
32543 1999-05-16  Jim Meyering  <meyering@ascend.com>
32544
32545         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
32546
32547 1999-05-10  Jim Meyering  <meyering@ascend.com>
32548
32549         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
32550
32551         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
32552         AC_FUNC_MKTIME.
32553
32554 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
32555
32556         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
32557
32558 1999-05-04  Paul Eggert  <eggert@twinsun.com>
32559
32560         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
32561         not CPPFLAGS, so that linking works correctly in IRIX.
32562
32563 1999-04-30  Paul Eggert  <eggert@twinsun.com>
32564
32565         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
32566
32567 1999-04-20  Paul Eggert  <eggert@twinsun.com>
32568
32569         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
32570         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
32571         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
32572         jm_AC_TYPE_UNSIGNED_LONG_LONG.
32573         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
32574
32575         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
32576
32577 1999-04-20  Jim Meyering  <meyering@ascend.com>
32578
32579         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
32580         AC_REPLACE xstroull if necessary.  From Paul Eggert.
32581         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
32582
32583 1999-04-18  Jim Meyering  <meyering@ascend.com>
32584
32585         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
32586         * m4/jm-macros.m4: Use it.
32587
32588 1999-04-06  Jim Meyering  <meyering@ascend.com>
32589
32590         * m4/strftime.m4: Remove test for %f.
32591
32592 1999-03-29  Jim Meyering  <meyering@ascend.com>
32593
32594         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
32595         superset of the AC_TYPE_* checks in the textutils, fileutils,
32596         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
32597         AC_TYPE_PID_T.
32598
32599 1999-03-28  Jim Meyering  <meyering@ascend.com>
32600
32601         * m4/jm-macros.m4: Define GNU_PACKAGE here.
32602         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
32603         replaced e.g., in the *.sh files of the sh-utils.
32604
32605 1999-03-20  Jim Meyering  <meyering@ascend.com>
32606
32607         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
32608         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
32609         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
32610
32611 1999-03-19  Jim Meyering  <meyering@ascend.com>
32612
32613         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
32614
32615 1999-03-12  Jim Meyering  <meyering@ascend.com>
32616
32617         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
32618
32619 1999-03-07  Jim Meyering  <meyering@ascend.com>
32620
32621         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
32622         declared.
32623
32624 1999-02-17  Jim Meyering  <meyering@ascend.com>
32625
32626         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
32627         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
32628
32629 1999-02-07  Jim Meyering  <meyering@ascend.com>
32630
32631         * m4/group-member.m4: New file -- extracted from sh-utils'
32632         configure.in.
32633
32634         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
32635         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
32636
32637 1999-02-06  Jim Meyering  <meyering@ascend.com>
32638
32639         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
32640         * m4/fnmatch.m4: Likewise.
32641         * m4/getgroups.m4: Likewise.
32642         * m4/lstat.m4: Likewise.
32643         * m4/malloc.m4: Likewise.
32644         * m4/putenv.m4: Likewise.
32645         * m4/realloc.m4: Likewise.
32646         * m4/regex.m4: Likewise.
32647         * m4/stat.m4: Likewise.
32648         * m4/strftime.m4: Likewise.
32649         Suggestion from Alain Magloire.
32650
32651         * m4/chown.m4: Use `.$ac_objext', not `.o'.
32652         * m4/fnmatch.m4: Likewise.
32653         * m4/getgroups.m4: Likewise.
32654         * m4/getline.m4: Likewise.
32655         * m4/lstat.m4: Likewise.
32656         * m4/malloc.m4: Likewise.
32657         * m4/memcmp.m4: Likewise.
32658         * m4/putenv.m4: Likewise.
32659         * m4/realloc.m4: Likewise.
32660         * m4/regex.m4: Likewise.
32661         * m4/stat.m4: Likewise.
32662         * m4/strftime.m4: Likewise.
32663         Suggestion from Alain Magloire.
32664
32665         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
32666         an argument.
32667
32668         * m4/regex.m4: Add a run-time Test for proper operation of
32669         re_compile_pattern.
32670
32671 1999-01-31  Jim Meyering  <meyering@ascend.com>
32672
32673         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
32674
32675 1999-01-30  Jim Meyering  <meyering@ascend.com>
32676
32677         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
32678
32679         * m4/jm-mktime.m4: Make this a wrapper around the official
32680         AM_FUNC_MKTIME rather than my private copy, now that the official one
32681         is up to date.
32682         * m4/mktime.m4: Remove file.
32683
32684         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
32685         * m4/uptime.m4: Likewise.
32686         * m4/uintmax_t.m4: Likewise.
32687
32688 1999-01-28  Jim Meyering  <meyering@ascend.com>
32689
32690         * m4/jm-macros.m4: Use jm_AFS.
32691         * m4/afs.m4: New file (from fileutils' configure.in).
32692
32693         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
32694         * m4/chown.m4: Likewise.
32695         * m4/d-ino.m4: Likewise.
32696         * m4/d-type.m4: Likewise.
32697         * m4/fnmatch.m4: Likewise.
32698         * m4/getgroups.m4: Likewise.
32699         * m4/gettext.m4: Likewise.
32700         * m4/jm-mktime.m4: Likewise.
32701         * m4/jm-winsz2.m4: Likewise.
32702         * m4/lcmessage.m4: Likewise.
32703         * m4/ls-mntd-fs.m4: Likewise.
32704         * m4/malloc.m4: Likewise.
32705         * m4/memcmp.m4: Likewise.
32706         * m4/putenv.m4: Likewise.
32707         * m4/realloc.m4: Likewise.
32708         * m4/st_mtim.m4: Likewise.
32709         * m4/strftime.m4: Likewise.
32710
32711 1999-01-16  Jim Meyering  <meyering@ascend.com>
32712
32713         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
32714         (ARGMATCH_DIE_DECL): Define.
32715
32716 1999-01-12  Jim Meyering  <meyering@ascend.com>
32717
32718         * m4/Makefile.am.in: Rewrite to avoid using fmt.
32719         Reported by Lars Hecking.
32720
32721 1999-01-10  Jim Meyering  <meyering@ascend.com>
32722
32723         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
32724         gross kludge.
32725         * m4/inttypes_h.m4: Likewise.
32726         * m4/lstat.m4: Likewise.
32727         * m4/malloc.m4: Likewise.
32728         * m4/readdir.m4: Likewise.
32729         * m4/realloc.m4: Likewise.
32730         * m4/st_dm_mode.m4: Likewise.
32731         * m4/stat.m4: Likewise.
32732         * m4/utimbuf.m4: Likewise.
32733         * m4/utimes.m4: Likewise.
32734
32735         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
32736         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
32737         comments in config.h.in are meaningful.
32738
32739         * m4/jm-macros.m4: Require autoconf-2.13 here.
32740
32741         * m4/regex.m4: By default, don't use the included regex.c on systems
32742         with glibc 2.  Suggestion from Uli Drepper.
32743
32744 1999-01-02  Jim Meyering  <meyering@ascend.com>
32745
32746         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
32747
32748 1998-12-18  Jim Meyering  <meyering@ascend.com>
32749
32750         * m4/Makefile.am.in (Makefile.am): Simplify rule.
32751         Based on a suggestion from Lars Hecking.
32752
32753 1998-11-16  Paul Eggert  <eggert@twinsun.com>
32754
32755         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
32756
32757 1998-11-16  Jim Meyering  <meyering@ascend.com>
32758
32759         * m4/lfs.m4: Double-quote the `uname...` expression.
32760
32761 1998-11-14  Jim Meyering  <meyering@ascend.com>
32762
32763         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
32764         * m4/stat.m4: Likewise.
32765
32766 1998-11-03  Jim Meyering  <meyering@ascend.com>
32767
32768         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
32769         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
32770
32771 1998-10-18  Jim Meyering  <meyering@ascend.com>
32772
32773         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
32774
32775 1998-10-17  Jim Meyering  <meyering@ascend.com>
32776
32777         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
32778         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
32779         calls for those previously hard-coded headers.  Instead, take a new
32780         parameter.
32781         (jm_CHECK_DECLARATIONS): Reflect interface change.
32782         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
32783         (jm_CHECK_DECL_LOCALTIME_R): New macro.
32784
32785         * m4/mktime.m4: Test for spring-forward gap before long-running test.
32786
32787 1998-10-14  Jim Meyering  <meyering@ascend.com>
32788
32789         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
32790         instead of "TZ=America/Vancouver".  From Paul Eggert.
32791
32792 1998-10-11  Jim Meyering  <meyering@ascend.com>
32793
32794         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
32795         This adds a test for a recently added compatibility fix for mktime.c.
32796         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
32797
32798 1998-09-27  Jim Meyering  <meyering@ascend.com>
32799
32800         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
32801
32802         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
32803         ../configure.in, including a change from Gordon Matzigkeit to allow
32804         cross-compiling for the Hurd.
32805
32806         * m4/glibc.m4: New file/macro to test for the GNU C Library
32807         versions 1 and 2.  From Gordon Matzigkeit.
32808         Indent.
32809
32810 1998-09-21  Jim Meyering  <meyering@ascend.com>
32811
32812         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
32813
32814 1998-08-18  Paul Eggert  <eggert@twinsun.com>
32815
32816         Port nanosecond-resolution times to UnixWare 2.1.2 and
32817         pedantic Solaris 2.6.
32818
32819         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
32820         AC_STRUCT_ST_MTIM.
32821         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
32822         Generate name of ns member, instead of just 1 or undef.
32823         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
32824
32825 1998-08-15  Jim Meyering  <meyering@ascend.com>
32826
32827         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
32828         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
32829         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
32830         instead of jm_TYPE_SSIZE_T.
32831
32832 1998-08-12  Jim Meyering  <meyering@ascend.com>
32833
32834         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
32835
32836 1998-08-02  Jim Meyering  <meyering@ascend.com>
32837
32838         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
32839         in acconfig.h manually.
32840
32841 1998-07-31  Paul Eggert  <eggert@twinsun.com>
32842
32843         * m4/st_mtim.m4: New file.
32844
32845 1998-07-28  Jim Meyering  <meyering@ascend.com>
32846
32847         * m4/utimes.m4: Undef stat.
32848
32849 1998-07-25  Jim Meyering  <meyering@ascend.com>
32850
32851         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
32852         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
32853
32854 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
32855
32856         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
32857         uid and gid actually remain unchanged.
32858
32859 1998-07-07  Jim Meyering  <meyering@ascend.com>
32860
32861         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
32862
32863 1998-07-04  Jim Meyering  <meyering@ascend.com>
32864
32865         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
32866         to prove that this macro can be used in packages without regex.c.
32867
32868 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
32869
32870         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
32871         is to be used.
32872
32873 1998-07-03  Jim Meyering  <meyering@ascend.com>
32874
32875         * m4/gettext.m4: Add -lintl if it's found to be necessary.
32876
32877         * m4/gettext.m4: New file -- from gettext-0.10.35.
32878         * m4/lcmessage.m4: Likewise.
32879         * m4/progtest.m4: Likewise.
32880
32881         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
32882         * m4/jm-macros.m4: Require the new macro.
32883
32884 1998-06-29  Jim Meyering  <meyering@ascend.com>
32885
32886         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
32887         for the definition of NGROUPS (used in a system header included
32888         by sys/mount.h).
32889
32890 1998-06-28  Jim Meyering  <meyering@ascend.com>
32891
32892         * m4/ls-mntd-fs.m4: New file.
32893         * m4/fstypename.m4: New file.
32894
32895         * m4/jm-macros.m4: Require the new macro.
32896         * m4/jm-glibc-io.m4: New file.
32897
32898 1998-05-19  Jim Meyering  <meyering@ascend.com>
32899
32900         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
32901         * m4/lchown.m4: New file.
32902
32903         * m4/Makefile.am.in: New file.
32904         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
32905
32906 1998-05-14  Jim Meyering  <meyering@ascend.com>
32907
32908         * m4/Makefile.am (EXTRA_DIST): Add them.
32909         * m4/jm-macros.m4: New file.
32910         * m4/utimbuf.m4: New file.
32911
32912 1998-05-12  Jim Meyering  <meyering@ascend.com>
32913
32914         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
32915
32916 1998-05-11  Jim Meyering  <meyering@ascend.com>
32917
32918         * m4/isc-posix.m4: New file.
32919
32920 1998-05-10  Jim Meyering  <meyering@ascend.com>