doc: regenerate INSTALL
[gnulib.git] / ChangeLog
1 2010-01-06  Eric Blake  <ebb9@byu.net>
2
3         doc: regenerate INSTALL
4         * doc/INSTALL: Reflect recent autoconf update.
5         * doc/INSTALL.ISO: Likewise.
6         * doc/INSTALL.UTF-8: Likewise.
7
8         pread: fix compilation on glibc
9         * m4/pread.m4 (gl_FUNC_PREAD): Request all interfaces.
10         Reported by Ralf Wildenhues.
11
12         dirent: fix test failure
13         * lib/dirent.in.h (includes): Guarantee ino_t.
14         Reported by Ralf Wildenhues.
15
16 2010-01-06  Petr Salinger  <Petr.Salinger@seznam.cz>  (tiny change)
17
18         linkat, renameat: avoid bad free
19         * lib/at-func2.c (at_func2): Fix typo.
20         Reported via Ian Beckwith, from http://bugs.debian.org/561117.
21
22 2010-01-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
23
24         cleanup after gl_FUNC_READLINK, for gl_FUNC_SYMLINK test
25         * m4/readlink.m4 (gl_FUNC_READLINK): Remove conftest.lnk2,
26         to avoid failure of symlink test later.
27
28 2010-01-06  Eric Blake  <ebb9@byu.net>
29
30         stdio, unistd: guarantee ssize_t
31         * lib/unistd.in.h (includes): Ensure that types required by POSIX
32         2008 are exposed when needed.
33         * lib/stdio.in.h (includes): Likewise.
34         Reported by Ralf Wildenhues.
35
36 2010-01-06  Paolo Bonzini  <bonzini@gnu.org>
37
38         nl_langinfo: do not call AC_CHECK_FUNC_ONCE inside if.
39         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Do not call
40         AC_CHECK_FUNC_ONCE inside if, do not adjust ac_cv_func_nl_langinfo.
41
42 2010-01-06  Jim Meyering  <meyering@redhat.com>
43
44         readtokens: this module *does* require xalloc.h
45         It uses only functions that were omitted by the old syntax-check rule.
46         * lib/readtokens.c: Include "xalloc.h" once again.
47         * modules/readtokens (Depends-on): Add xalloc.
48         This reverts part of 0e0f8f12ec241c0f1c1f21f960bb5cf908a0fa3c.
49
50 2010-01-05  Eric Blake  <ebb9@byu.net>
51
52         maint: support 'make announcement' from a VPATH build
53         * top/maint.mk (announcement): Look for correct NEWS file.
54
55 2010-01-05  Aurelien Jarno  <aurelien@aurel32.net>  (tiny change)
56
57         utimens (fdutimens): ignore a negative FD, per contract
58         * lib/utimens.c (fdutimens) [HAVE_FUTIMENS]: Call futimens only
59         when we have a valid file descriptor.  Otherwise, using a brand
60         new glibc (with just-patched futimens that now fails with EBADF)
61         would cause this function to fail with ENOSYS.
62         Reported by Guillaume Ayoub in http://bugs.debian.org/563726.
63         See also http://bugzilla.redhat.com/552320.
64
65 2010-01-05  Eric Blake  <ebb9@byu.net>
66
67         strcase: document what it provides
68         * doc/posix-functions/strcasecmp.texi (strcasecmp): Mention the
69         gnulib module.
70         * doc/posix-functions/strncasecmp.texi (strncasecmp): Likewise.
71         Reported by Dilyan Palauzov <Dilyan.Palauzov@aegee.org>.
72
73 2010-01-05  Jim Meyering  <meyering@redhat.com>
74
75         maint: remove useless inclusions of "xalloc.h"
76         * lib/getloadavg.c: Remove useless inclusion of "xalloc.h".
77         * lib/readtokens.c: Likewise.
78         * lib/same.c: Likewise.
79         * modules/getloadavg (Depends-on): Remove alloca.
80         * modules/readtokens: Likewise.
81         * modules/same: Likewise.
82
83         maint.mk: include 4 more function names in alloca.h-checking regexp
84         * top/maint.mk (sc_prohibit_xalloc_without_use): Use more complete
85         regexp.  Before, we would give a false-positive (saying alloca.h
86         is included unnecessarily) when the only uses involved omitted symbols.
87
88         xalloc.h: use consistent formatting
89         * lib/xalloc.h: Move declarations to start in the first column.
90
91 2010-01-05  Eric Blake  <ebb9@byu.net>
92
93         mkdir: avoid xalloc
94         * lib/mkdir.c (includes): Drop unused header.
95         Reported by John W. Eaton.
96
97 2010-01-04  Jim Meyering  <meyering@redhat.com>
98
99         nl_langinfo: avoid configure-time syntax error
100         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): When we've already tested
101         for nl_langinfo.h, AC_CHECK_FUNCS_ONCE([nl_langinfo]) expands to
102         the empty string.  Don't let that provoke a shell syntax error.
103
104         regcomp, regexec, fnmatch: avoid array bounds read error
105         * lib/regcomp.c (build_equiv_class): From glibc:
106         Use only the low 24 bits of a findidx return value as an index
107         into the weights array.  Patch by Ulrich Drepper:
108         http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commit;h=b7d1c5fa30
109         * lib/regexec.c (check_node_accept_bytes): Likewise.
110         * lib/fnmatch_loop.c (FCT): Likewise.
111
112         regcomp: skip collseq lookup when there are no rules
113         * lib/regcomp.c (lookup_collation_sequence_value): From glibc:
114         http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=a532a41df58
115
116         regcomp: recognize ill-formed { } expressions
117         * lib/regcomp.c (parse_dup_op): From glibc:
118         http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=a87cd2894cb
119
120         regcomp: fix typo in comment
121         * lib/regcomp.c (duplicate_node_closure): Sync from glibc.
122         s/satisfy/satisfies/.
123
124         regcomp: sync from glibc: remove dead store
125         * lib/regcomp.c (duplicate_node_closure): Remove useless
126         search_duplicated_node call and dead store.
127
128         regcomp: sync from glibc; always use nl_langinfo
129         * lib/regcomp.c (init_dfa) [!LIBC]: Always use nl_langinfo (CODESET),
130         now that gnulib provides it.  Recognize UTF8 as well as UTF-8.
131         * modules/regex (Depends-on): Add nl_langinfo.
132
133 2010-01-04  Eric Blake  <ebb9@byu.net>
134
135         fdopendir: fix configure test
136         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Check for existing file.
137
138 2010-01-01  Bruno Haible  <bruno@clisp.org>
139
140         wchar: Remove unused configure check.
141         * m4/wchar.m4 (gl_WCHAR_H): Don't test whether <wchar.h> is standalone.
142
143 2010-01-01  Eric Blake  <ebb9@byu.net>
144
145         headers: make check of system header explicit
146         * m4/netdb_h.m4 (gl_HEADER_NETDB): Don't exploit knowledge of
147         gl_CHECK_NEXT_HEADER internals, but call AC_CHECK_HEADERS_ONCE
148         ourselves.
149         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
150         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
151         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
152         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise, for gt_INTTYPES_PRI
153         internals.
154         * m4/wchar.m4 (gl_WCHAR_H): Skip followup test if header is
155         missing.
156         Suggested by Bruno Haible.
157
158 2010-01-01  Jim Meyering  <meyering@redhat.com>
159
160         ChangeLog: tweak to eliminate unnecessary copyright line
161         * ChangeLog: Remove a copyright line that was mistakenly updated
162         by today's update-copyright run.  Reported by Eric Blake.
163
164         test-update-copyright: don't let envvar setting cause test failure
165         * tests/test-update-copyright.sh: Set UPDATE_COPYRIGHT_MAX_LINE_LENGTH.
166
167 2010-01-01  Bruno Haible  <bruno@clisp.org>
168
169         localename: Avoid gcc warning.
170         * lib/localename.c (gl_locale_name_thread_unsafe): Don't define this
171         function if it is not used.
172
173 2010-01-01  Jim Meyering  <meyering@redhat.com>
174
175         update nearly all FSF copyright year lists to include 2010
176         Use the same procedure as for 2009, outlined in
177         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/20081
178
179         version-etc: set COPYRIGHT_YEAR to 2010
180         * lib/version-etc.c (COPYRIGHT_YEAR): Manually update the enum.
181
182 2009-12-31  Eric Blake  <ebb9@byu.net>
183
184         doc: correct availability of cygwin 1.5.x getopt
185         * doc/posix-functions/optarg.texi (optarg): Cygwin supplies getopt
186         variables.
187         * doc/posix-functions/opterr.texi (opterr): Likewise.
188         * doc/posix-functions/optind.texi (optind): Likewise.
189         * doc/posix-functions/optopt.texi (optopt): Likewise.
190         * doc/posix-functions/tzname.texi (tzname): Likewise.
191
192         openat: update maintainer
193         * modules/openat (Maintainer): Add myself.
194
195         utimens: avoid shadowing warning
196         * lib/utimens.c (fdutimens, lutimens): Consolidate separate stat
197         buffers into one, to avoid shadowing, as well as avoiding a
198         redundant stat.
199         Reported by Jim Meyering.
200
201         test-dup2: avoid compiler warning
202         * tests/test-dup2.c (is_inheritable): Only define if used.
203
204 2010-01-01  Bruno Haible  <bruno@clisp.org>
205
206         vasnprintf: Avoid passing an 'rpl_mbstate_t *' to the system's wcrtomb.
207         * lib/vasnprintf.c (VASNPRINTF): If GNULIB_defined_mbstate_t is
208         defined, use wctomb instead of wcrtomb.
209
210 2010-01-01  Bruno Haible  <bruno@clisp.org>
211
212         iconv: Reject native Solaris iconv.
213         * m4/iconv.m4 (AM_ICONV_LINK): Recognize native Solaris iconv() bug.
214         * doc/posix-functions/iconv.texi: Document native Solaris iconv() bug.
215
216 2009-12-31  Bruno Haible  <bruno@clisp.org>
217
218         * tests/test-signal.c (main): Remove test of 'SIG'.
219
220 2009-12-31  Bruno Haible  <bruno@clisp.org>
221
222         spawn: Fix incomplete fix.
223         * lib/spawn.in.h (posix_spawnattr_getflags, posix_spawnattr_setflags,
224         posix_spawnattr_getpgroup, posix_spawnattr_setpgroup): Correct the link
225         warnings for GNULIB_POSIXCHECK again.
226         Reported by Eric Blake.
227
228 2009-12-31  Bruno Haible  <bruno@clisp.org>
229
230         Avoid namespace pollution on glibc systems.
231         * lib/spawn.in.h: Don't include <sched.h>, <signal.h> on glibc systems.
232         * lib/sys_times.in.h: Don't include <time.h> on glibc systems.
233         * lib/wchar.in.h: Don't include <stddef.h>, <stdio.h>, <time.h> on
234         glibc systems.
235
236 2009-12-31  Bruno Haible  <bruno@clisp.org>
237
238         * m4/wchar.m4 (gl_WCHAR_H): Remove gl_STDDEF_H invocation.
239         (gl_REPLACE_WCHAR_H): Turn into a no-op.
240         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): Likewise.
241         * m4/dirent_h.m4 (gl_REPLACE_DIRENT_H): Likewise.
242         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H): Likewise.
243         * m4/spawn_h.m4 (gl_REPLACE_SPAWN_H): Likewise.
244         * m4/sys_ioctl_h.m4 (gl_REPLACE_SYS_IOCTL_H): Likewise.
245
246 2009-12-31  Bruno Haible  <bruno@clisp.org>
247
248         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Invoke
249         gl_CHECK_NEXT_HEADERS before testing ac_cv_header_sys_select_h, not
250         afterwards.
251
252 2009-12-31  Bruno Haible  <bruno@clisp.org>
253
254         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H_DEFAULTS): Don't set
255         SYS_UTSNAME_H.
256
257 2009-12-31  Bruno Haible  <bruno@clisp.org>
258
259         spawn: Fix misapplied patch.
260         * lib/spawn.in.h (posix_spawnattr_getflags, posix_spawnattr_setflags,
261         posix_spawnattr_getpgroup, posix_spawnattr_setpgroup): Correct the link
262         warnings for GNULIB_POSIXCHECK.
263
264 2009-12-31  Bruno Haible  <bruno@clisp.org>
265
266         times: Update after sys_times changed.
267         * m4/times.m4: New file, extracted from modules/times. Set HAVE_TIMES.
268         * modules/times (Files): Add it.
269         (configure.ac): Invoke gl_FUNC_TIMES.
270
271 2009-12-31  Bruno Haible  <bruno@clisp.org>
272
273         Use AC_C_INLINE where necessary.
274         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Require AC_C_INLINE.
275         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Likewise.
276         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
277         * m4/mbchar.m4 (gl_MBCHAR): Likewise.
278         * m4/mbfile.m4 (gl_MBFILE): Likewise.
279         * m4/mbiter.m4 (gl_MBITER): Likewise.
280         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
281         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
282         * m4/wait-process.m4 (gl_WAIT_PROCESS): Likewise.
283         * modules/u64 (configure.ac): Likewise.
284
285 2009-12-31  Bruno Haible  <bruno@clisp.org>
286
287         Use AC_C_INLINE instead of module 'inline' where possible.
288         * modules/inline (Description): Clarify purpose.
289         * m4/count-one-bits.m4 (gl_COUNT_ONE_BITS): Require AC_C_INLINE.
290         * modules/count-one-bits (Depends-on): Remove inline.
291         * m4/openat.m4 (gl_PREREQ_OPENAT): Require AC_C_INLINE.
292         * modules/openat (Depends-on): Remove inline.
293         * modules/fdutimensat (Depends-on, configure.ac): Require AC_C_INLINE
294         instead of depending on module 'inline'.
295         * modules/filevercmp (Depends-on, configure.ac): Likewise.
296         * modules/unicase/cased (Depends-on, configure.ac): Likewise.
297         * modules/unicase/ignorable (Depends-on, configure.ac): Likewise.
298         * modules/unictype/category-of (Depends-on, configure.ac): Likewise.
299         * modules/unictype/category-test (Depends-on, configure.ac): Likewise.
300         * modules/unictype/ctype-alnum (Depends-on, configure.ac): Likewise.
301         * modules/unictype/ctype-alpha (Depends-on, configure.ac): Likewise.
302         * modules/unictype/ctype-blank (Depends-on, configure.ac): Likewise.
303         * modules/unictype/ctype-cntrl (Depends-on, configure.ac): Likewise.
304         * modules/unictype/ctype-digit (Depends-on, configure.ac): Likewise.
305         * modules/unictype/ctype-graph (Depends-on, configure.ac): Likewise.
306         * modules/unictype/ctype-lower (Depends-on, configure.ac): Likewise.
307         * modules/unictype/ctype-print (Depends-on, configure.ac): Likewise.
308         * modules/unictype/ctype-punct (Depends-on, configure.ac): Likewise.
309         * modules/unictype/ctype-space (Depends-on, configure.ac): Likewise.
310         * modules/unictype/ctype-upper (Depends-on, configure.ac): Likewise.
311         * modules/unictype/ctype-xdigit (Depends-on, configure.ac): Likewise.
312         * modules/unictype/property-alphabetic (Depends-on, configure.ac):
313         Likewise.
314         * modules/unictype/property-ascii-hex-digit (Depends-on,
315         configure.ac): Likewise.
316         * modules/unictype/property-bidi-arabic-digit (Depends-on,
317         configure.ac): Likewise.
318         * modules/unictype/property-bidi-arabic-right-to-left (Depends-on,
319         configure.ac): Likewise.
320         * modules/unictype/property-bidi-block-separator (Depends-on,
321         configure.ac): Likewise.
322         * modules/unictype/property-bidi-boundary-neutral (Depends-on,
323         configure.ac): Likewise.
324         * modules/unictype/property-bidi-common-separator (Depends-on,
325         configure.ac): Likewise.
326         * modules/unictype/property-bidi-control (Depends-on, configure.ac):
327         Likewise.
328         * modules/unictype/property-bidi-embedding-or-override (Depends-on,
329         configure.ac): Likewise.
330         * modules/unictype/property-bidi-eur-num-separator (Depends-on,
331         configure.ac): Likewise.
332         * modules/unictype/property-bidi-eur-num-terminator (Depends-on,
333         configure.ac): Likewise.
334         * modules/unictype/property-bidi-european-digit (Depends-on,
335         configure.ac): Likewise.
336         * modules/unictype/property-bidi-hebrew-right-to-left (Depends-on,
337         configure.ac): Likewise.
338         * modules/unictype/property-bidi-left-to-right (Depends-on,
339         configure.ac): Likewise.
340         * modules/unictype/property-bidi-non-spacing-mark (Depends-on,
341         configure.ac): Likewise.
342         * modules/unictype/property-bidi-other-neutral (Depends-on,
343         configure.ac): Likewise.
344         * modules/unictype/property-bidi-pdf (Depends-on, configure.ac):
345         Likewise.
346         * modules/unictype/property-bidi-segment-separator (Depends-on,
347         configure.ac): Likewise.
348         * modules/unictype/property-bidi-whitespace (Depends-on,
349         configure.ac): Likewise.
350         * modules/unictype/property-combining (Depends-on, configure.ac):
351         Likewise.
352         * modules/unictype/property-composite (Depends-on, configure.ac):
353         Likewise.
354         * modules/unictype/property-currency-symbol (Depends-on,
355         configure.ac): Likewise.
356         * modules/unictype/property-dash (Depends-on, configure.ac): Likewise.
357         * modules/unictype/property-decimal-digit (Depends-on, configure.ac):
358         Likewise.
359         * modules/unictype/property-default-ignorable-code-point (Depends-on,
360         configure.ac): Likewise.
361         * modules/unictype/property-deprecated (Depends-on, configure.ac):
362         Likewise.
363         * modules/unictype/property-diacritic (Depends-on, configure.ac):
364         Likewise.
365         * modules/unictype/property-extender (Depends-on, configure.ac):
366         Likewise.
367         * modules/unictype/property-format-control (Depends-on, configure.ac):
368         Likewise.
369         * modules/unictype/property-grapheme-base (Depends-on, configure.ac):
370         Likewise.
371         * modules/unictype/property-grapheme-extend (Depends-on, configure.ac):
372         Likewise.
373         * modules/unictype/property-grapheme-link (Depends-on, configure.ac):
374         Likewise.
375         * modules/unictype/property-hex-digit (Depends-on, configure.ac):
376         Likewise.
377         * modules/unictype/property-hyphen (Depends-on, configure.ac):
378         Likewise.
379         * modules/unictype/property-id-continue (Depends-on, configure.ac):
380         Likewise.
381         * modules/unictype/property-id-start (Depends-on, configure.ac):
382         Likewise.
383         * modules/unictype/property-ideographic (Depends-on, configure.ac):
384         Likewise.
385         * modules/unictype/property-ids-binary-operator (Depends-on,
386         configure.ac): Likewise.
387         * modules/unictype/property-ids-trinary-operator (Depends-on,
388         configure.ac): Likewise.
389         * modules/unictype/property-ignorable-control (Depends-on,
390         configure.ac): Likewise.
391         * modules/unictype/property-iso-control (Depends-on, configure.ac):
392         Likewise.
393         * modules/unictype/property-join-control (Depends-on, configure.ac):
394         Likewise.
395         * modules/unictype/property-left-of-pair (Depends-on, configure.ac):
396         Likewise.
397         * modules/unictype/property-line-separator (Depends-on, configure.ac):
398         Likewise.
399         * modules/unictype/property-logical-order-exception (Depends-on,
400         configure.ac): Likewise.
401         * modules/unictype/property-lowercase (Depends-on, configure.ac):
402         Likewise.
403         * modules/unictype/property-math (Depends-on, configure.ac): Likewise.
404         * modules/unictype/property-non-break (Depends-on, configure.ac):
405         Likewise.
406         * modules/unictype/property-not-a-character (Depends-on, configure.ac):
407         Likewise.
408         * modules/unictype/property-numeric (Depends-on, configure.ac):
409         Likewise.
410         * modules/unictype/property-other-alphabetic (Depends-on,
411         configure.ac): Likewise.
412         * modules/unictype/property-other-default-ignorable-code-point
413         (Depends-on, configure.ac): Likewise.
414         * modules/unictype/property-other-grapheme-extend (Depends-on,
415         configure.ac): Likewise.
416         * modules/unictype/property-other-id-continue (Depends-on,
417         configure.ac): Likewise.
418         * modules/unictype/property-other-id-start (Depends-on, configure.ac):
419         Likewise.
420         * modules/unictype/property-other-lowercase (Depends-on, configure.ac):
421         Likewise.
422         * modules/unictype/property-other-math (Depends-on, configure.ac):
423         Likewise.
424         * modules/unictype/property-other-uppercase (Depends-on, configure.ac):
425         Likewise.
426         * modules/unictype/property-paired-punctuation (Depends-on,
427         configure.ac): Likewise.
428         * modules/unictype/property-paragraph-separator (Depends-on,
429         configure.ac): Likewise.
430         * modules/unictype/property-pattern-syntax (Depends-on, configure.ac):
431         Likewise.
432         * modules/unictype/property-pattern-white-space (Depends-on,
433         configure.ac): Likewise.
434         * modules/unictype/property-private-use (Depends-on, configure.ac):
435         Likewise.
436         * modules/unictype/property-punctuation (Depends-on, configure.ac):
437         Likewise.
438         * modules/unictype/property-quotation-mark (Depends-on, configure.ac):
439         Likewise.
440         * modules/unictype/property-radical (Depends-on, configure.ac):
441         Likewise.
442         * modules/unictype/property-sentence-terminal (Depends-on,
443         configure.ac): Likewise.
444         * modules/unictype/property-soft-dotted (Depends-on, configure.ac):
445         Likewise.
446         * modules/unictype/property-space (Depends-on, configure.ac): Likewise.
447         * modules/unictype/property-terminal-punctuation (Depends-on,
448         configure.ac): Likewise.
449         * modules/unictype/property-titlecase (Depends-on, configure.ac):
450         Likewise.
451         * modules/unictype/property-unassigned-code-value (Depends-on,
452         configure.ac): Likewise.
453         * modules/unictype/property-unified-ideograph (Depends-on,
454         configure.ac): Likewise.
455         * modules/unictype/property-uppercase (Depends-on, configure.ac):
456         Likewise.
457         * modules/unictype/property-variation-selector (Depends-on,
458         configure.ac): Likewise.
459         * modules/unictype/property-white-space (Depends-on, configure.ac):
460         Likewise.
461         * modules/unictype/property-xid-continue (Depends-on, configure.ac):
462         Likewise.
463         * modules/unictype/property-xid-start (Depends-on, configure.ac):
464         Likewise.
465         * modules/unictype/property-zero-width (Depends-on, configure.ac):
466         Likewise.
467         * modules/unictype/syntax-c-ident (Depends-on, configure.ac): Likewise.
468         * modules/unictype/syntax-java-ident (Depends-on, configure.ac):
469         Likewise.
470
471 2009-12-31  Bruno Haible  <bruno@clisp.org>
472
473         Remove unnecessary AC_C_INLINE invocation.
474         * m4/popen.m4 (gl_PREREQ_POPEN): Don't invoke AC_C_INLINE. Not needed
475         since 2009-08-21.
476
477 2009-12-31  Jim Meyering  <meyering@redhat.com>
478
479         maint.mk: don't require explicit gpg_key_ID in cfg.mk
480         * top/maint.mk (gpg_key_ID): Derive key ID from signed release tag.
481         With this change, we can all remove the gpg_key_ID = ... definition
482         from our respective cfg.mk files.
483
484         maint.mk: create announcement template in ~/, not in /tmp
485         * top/maint.mk (emit_upload_commands): Adjust.
486         (release-prep): Emit into ~/announce-..., not /tmp/announce-...
487         Remove temporary file, .ci-msg.
488
489 2009-12-31  Eric Blake  <ebb9@byu.net>
490
491         link-warning: always build headers with link warnings
492         * modules/arpa_inet (Makefile.am): Always build replacement
493         header.
494         * modules/ctype (Makefile.am): Likewise.
495         * modules/dirent (Makefile.am): Likewise.
496         * modules/inttypes (Makefile.am): Likewise.
497         * modules/langinfo (Makefile.am): Likewise.
498         * modules/locale (Makefile.am): Likewise.
499         * modules/spawn (Makefile.am): Likewise.
500         * modules/sys_file (Makefile.am): Likewise.
501         * modules/sys_ioctl (Makefile.am): Likewise.
502         * modules/sys_select (Makefile.am): Likewise.
503         * modules/sys_socket (Makefile.am): Likewise.
504         * modules/sys_times (Makefile.am): Likewise.
505         * modules/sys_utsname (Makefile.am): Likewise.
506         * modules/sys_wait (Makefile.am): Likewise.
507         * modules/wchar (Makefile.am): Likewise.
508         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET)
509         (gl_ARPA_INET_H_DEFAULTS): Drop unneeded variable.
510         * m4/ctype.m4 (gl_CTYPE_H_DEFAULTS): Likewise.
511         * m4/isblank.m4 (gl_FUNC_ISBLANK): Likewise.
512         * m4/dirent_h.m4 (gl_REPLACE_DIRENT_H, gl_DIRENT_H_DEFAULTS):
513         Likewise.
514         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
515         * m4/langinfo_h.m4 (gl_LANGINFO_H): Likewise.
516         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H, gl_LOCALE_H_DEFAULTS):
517         Likewise.
518         * m4/spawn_h.m4 (gl_REPLACE_SPAWN_H, gl_SPAWN_H_DEFAULTS):
519         Likewise.
520         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H): Likewise.
521         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H, gl_REPLACE_SYS_IOCTL_H)
522         (gl_SYS_IOCTL_H_DEFAULTS): Likewise.
523         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
524         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
525         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H)
526         (gl_SYS_UTSNAME_H_DEFAULTS): Likewise.
527         * m4/wchar.m4 (gl_WCHAR_H, gl_REPLACE_WCHAR_H)
528         (gl_WCHAR_H_DEFAULTS): Likewise.
529
530 2009-12-31  Eric Blake  <ebb9@byu.net>
531
532         signal, spawn: use link warnings
533         * lib/signal.in.h (sigset_t): Make unconditional.
534         (sigismember, sigemptyset, sigaddset, sigdelset, sigfillset)
535         (sigpending, sigprocmask, sigaction): Add link warnings.
536         * lib/spawn.in.h (posix_spawn, posix_spawnp, posix_spawnattr_init)
537         (posix_spawnattr_destroy, posix_spawnattr_getsigdefault)
538         (posix_spawnattr_setsigdefault, posix_spawnattr_getsigmask)
539         (posix_spawnattr_setsigmask, posix_spawnattr_getflags)
540         (posix_spawnattr_setflags, posix_spawnattr_getpgroup)
541         (posix_spawnattr_setpgroup, posix_spawnattr_getschedpolicy)
542         (posix_spawnattr_setschedpolicy, posix_spawnattr_getschedparam)
543         (posix_spawnattr_setschedparam, posix_spawn_file_actions_init)
544         (posix_spawn_file_actions_destroy)
545         (posix_spawn_file_actions_addopen)
546         (posix_spawn_file_actions_addclose)
547         (posix_spawwn_file_actions_adddup2): Likewise.
548         * m4/signal_h.m4 (gl_SIGNAL_H): Guarantee uid_t.
549         * tests/test-signal.c (main): Enhance test.
550
551         spawn: improve wrapper support
552         * m4/spawn_h.m4 (gl_SPAWN_H): Check for type existence.
553         (gl_SPAWN_H_DEFAULTS): New defaults.
554         * modules/spawn (Makefile.am): Substitute them.
555         * lib/spawn.in.h: (posix_spawnattr_t, posix_spawn_file_actions_t):
556         Only declare if missing or broken.
557
558         sys_times, sys_utsname: use include_next
559         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Support wrapping an existing
560         header.
561         (gl_SYS_TIMES_H_DEFAULTS): Add another variable.
562         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H)
563         (gl_SYS_UTSNAME_H_DEFAULTS): Likewise.
564         * modules/sys_times (Depends-on): Add include_next.
565         (Makefile.am): Substitute additional values.
566         * modules/sys_utsname (Depends-on, Makefile.am): Likewise.
567         * lib/sys_times.in.h (includes): Include native header, if
568         available.
569         * lib/sys_utsname.in.h (includes): Likewise.
570         * tests/test-sys_times.c (main): Enhance test.
571
572         fdutimensat: revert prior patch
573         * modules/fdutimensat (Depends-on): Re-add inline; it is needed by
574         utimens.h.
575         Reported by Bruno Haible.
576
577 2009-12-30  Eric Blake  <ebb9@byu.net>
578
579         sys_wait: drop link-warning dependency
580         * modules/sys_wait (Depends-on, Makefile.am): Drop unneeded
581         link-warning efforts.
582         * lib/sys_wait.in.h: Likewise.
583
584         fdutimensat: remove bogus dependency
585         * modules/fdutimensat (Depends-on): Drop inline.
586
587         unistd: fix typo
588         * lib/unistd.in.h (linkat) [GNULIB_POSIXCHECK]: Fix typo.
589
590 2009-12-30  Bruno Haible  <bruno@clisp.org>
591
592         Fix compilation error with Solaris cc.
593         * lib/unicase/u8-is-invariant.c: Include <stdbool.h>.
594         * lib/unicase/u16-is-invariant.c: Likewise.
595         * lib/unicase/u32-is-invariant.c: Likewise.
596         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
597
598 2009-12-30  Bruno Haible  <bruno@clisp.org>
599
600         Fix test crash.
601         * tests/test-localename.c (test_locale_name_thread): Skip unavailable
602         locales.
603         Reported by Simon Josefsson <simon@josefsson.org>.
604
605 2009-12-30  Bruno Haible  <bruno@clisp.org>
606
607         Fix compilation error on most platforms.
608         * tests/test-localename.c (categories): Define only if HAVE_NEWLOCALE.
609         Reported by Simon Josefsson <simon@josefsson.org>
610         and Nelson H. F. Beebe <beebe@math.utah.edu>.
611
612 2009-12-30  Eric Blake  <ebb9@byu.net>
613
614         futimens, utimensat: work around ntfs-3g bug
615         * lib/utimensat.c (rpl_utimensat): Drop attempts to cache whether
616         a ctime bug is present, and expand workaround to cover ntfs-3g.
617         * lib/utimens.c (fdutimens, lutimens): Likewise.
618         (utimensat_ctime_really, detect_ctime_bug): Drop cache mechanism.
619         (validate_timespec): Adjust return value.
620         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Update comment.
621         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
622         Reported by ctrn3e8 <ctrn3e8@gmail.com>.
623
624 2009-12-29  Eric Blake  <ebb9@byu.net>
625
626         link-warning: make usage consistent
627         * modules/ctype (Depends-on): Add link-warning.
628         (Makefile.am): Update rules accordingly.
629         * modules/langinfo (Depends-on, Makefile.am): Likewise.
630         * modules/locale (Depends-on, Makefile.am): Likewise.
631         * modules/sys_file (Makefile.am): Likewise.
632         * modules/getopt-posix (Makefile.am): Delete unused link warning
633         efforts.
634         * lib/ctype.in.h (GL_LINK_WARNING): Ensure definition before use.
635         * lib/langinfo.in.h (GL_LINK_WARNING): Likewise.
636         * lib/locale.in.h (GL_LINK_WARNING): Likewise.
637         * lib/sys_file.in.h (GL_LINK_WARNING): Likewise.
638
639         stdio: remove unused variables
640         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Remove unused variables.
641         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Likewise.
642         * m4/ftello.m4 (gl_FUNC_FTELLO): Likewise.
643
644         tests: test more substitute headers
645         * modules/ctype-tests: New file.
646         * modules/dirent-tests: Likewise.
647         * modules/spawn-tests: Likewise.
648         * modules/sys_file-tests: Likewise.
649         * modules/sys_ioctl-tests: Likewise.
650         * modules/sys_wait-tests: Likewise.
651         * tests/test-ctype.c: Likewise.
652         * tests/test-dirent.c: Likewise.
653         * tests/test-spawn.c: Likewise.
654         * tests/test-sys_file.c: Likewise.
655         * tests/test-sys_ioctl.c: Likewise.
656         * tests/test-sys_wait.c: Likewise.
657         * m4/spawn_h.m4 (gl_SPAWN_H): Replace header if it is missing.
658         * lib/sys_file.in.h (LOCK_SH, LOCK_EX, LOCK_UN, LOCK_NB): Provide
659         whether or not flock is in use.
660
661         tests: remove License section from module
662         * modules/arpa_inet-tests: Remove unneeded section.
663         * modules/byteswap-tests: Likewise.
664         * modules/ceilf-tests: Likewise.
665         * modules/ceill-tests: Likewise.
666         * modules/crypto/des-tests: Likewise.
667         * modules/crypto/gc-arcfour-tests: Likewise.
668         * modules/crypto/gc-arctwo-tests: Likewise.
669         * modules/crypto/gc-des-tests: Likewise.
670         * modules/crypto/gc-hmac-md5-tests: Likewise.
671         * modules/crypto/gc-hmac-sha1-tests: Likewise.
672         * modules/crypto/gc-md2-tests: Likewise.
673         * modules/crypto/gc-md4-tests: Likewise.
674         * modules/crypto/gc-md5-tests: Likewise.
675         * modules/crypto/gc-pbkdf2-sha1-tests: Likewise.
676         * modules/crypto/gc-rijndael-tests: Likewise.
677         * modules/crypto/gc-sha1-tests: Likewise.
678         * modules/crypto/gc-tests: Likewise.
679         * modules/crypto/md2-tests: Likewise.
680         * modules/crypto/md4-tests: Likewise.
681         * modules/fcntl-h-tests: Likewise.
682         * modules/floorf-tests: Likewise.
683         * modules/floorl-tests: Likewise.
684         * modules/frexp-nolibm-tests: Likewise.
685         * modules/frexp-tests: Likewise.
686         * modules/frexpl-nolibm-tests: Likewise.
687         * modules/frexpl-tests: Likewise.
688         * modules/getaddrinfo-tests: Likewise.
689         * modules/inttypes-tests: Likewise.
690         * modules/isfinite-tests: Likewise.
691         * modules/isinf-tests: Likewise.
692         * modules/ldexpl-tests: Likewise.
693         * modules/locale-tests: Likewise.
694         * modules/math-tests: Likewise.
695         * modules/netdb-tests: Likewise.
696         * modules/netinet_in-tests: Likewise.
697         * modules/printf-frexp-tests: Likewise.
698         * modules/printf-frexpl-tests: Likewise.
699         * modules/priv-set-tests: Likewise.
700         * modules/random_r-tests: Likewise.
701         * modules/round-tests: Likewise.
702         * modules/roundf-tests: Likewise.
703         * modules/roundl-tests: Likewise.
704         * modules/search-tests: Likewise.
705         * modules/select-tests: Likewise.
706         * modules/signal-tests: Likewise.
707         * modules/stdbool-tests: Likewise.
708         * modules/stddef-tests: Likewise.
709         * modules/stdint-tests: Likewise.
710         * modules/stdio-tests: Likewise.
711         * modules/stdlib-tests: Likewise.
712         * modules/string-tests: Likewise.
713         * modules/strings-tests: Likewise.
714         * modules/sys_select-tests: Likewise.
715         * modules/sys_socket-tests: Likewise.
716         * modules/sys_stat-tests: Likewise.
717         * modules/sys_time-tests: Likewise.
718         * modules/sys_utsname-tests: Likewise.
719         * modules/sysexits-tests: Likewise.
720         * modules/time-tests: Likewise.
721         * modules/trunc-tests: Likewise.
722         * modules/truncf-tests: Likewise.
723         * modules/truncl-tests: Likewise.
724         * modules/tsearch-tests: Likewise.
725         * modules/unistd-tests: Likewise.
726         * modules/wchar-tests: Likewise.
727         * modules/wctype-tests: Likewise.
728
729         tests: fix license on several tests
730         * tests/test-des.c: Update to GPLv3+.
731         * tests/test-flock.c: Likewise.
732         * tests/test-fsync.c: Likewise.
733         * tests/test-futimens.h: Likewise.
734         * tests/test-gc-arcfour.c: Likewise.
735         * tests/test-gc-arctwo.c: Likewise.
736         * tests/test-gc-des.c: Likewise.
737         * tests/test-gc-hmac-md5.c: Likewise.
738         * tests/test-gc-hmac-sha1.c: Likewise.
739         * tests/test-gc-md2.c: Likewise.
740         * tests/test-gc-md4.c: Likewise.
741         * tests/test-gc-md5.c: Likewise.
742         * tests/test-gc-pbkdf2-sha1.c: Likewise.
743         * tests/test-gc-rijndael.c: Likewise.
744         * tests/test-gc-sha1.c: Likewise.
745         * tests/test-gc.c: Likewise.
746         * tests/test-getcwd.c: Likewise.
747         * tests/test-link.c: Likewise.
748         * tests/test-link.h: Likewise.
749         * tests/test-lutimens.h: Likewise.
750         * tests/test-md2.c: Likewise.
751         * tests/test-md4.c: Likewise.
752         * tests/test-mkdir.h: Likewise.
753         * tests/test-rename.c: Likewise.
754         * tests/test-rename.h: Likewise.
755         * tests/test-safe-alloc.c: Likewise.
756         * tests/test-utimens-common.h: Likewise.
757         * tests/test-utimens.h: Likewise.
758
759         maint: sync license texts
760         * config/srclist.txt: Add gpl-1.3.texi, lgpl-1.3.texi.
761         * doc/gpl-3.0.texi: Revert copyright year update.
762         * doc/lgpl-3.0.texi: Likewise.
763
764 2009-12-29  Jim Meyering  <meyering@redhat.com>
765
766         update nearly all FSF copyright year lists to include 2009
767         The files named by the following are exempted:
768             grep -v '^#' config/srclist.txt|grep -v '^$' | while read src dst; do
769               test -f "$dst" && { echo "$dst"; continue; }
770               test -d "$dst" || continue
771               echo "$dst"/$(basename "$src")
772             done > exempt
773             git ls-files tests/unictype >> exempt
774         In the remaining files, convert to all-interval notation if
775         - there is already at least one year interval like 2000-2003
776         - the file is maintained by me
777         - the file is in lib/uni*/, where that style already prevails
778         Otherwise, use update-copyright's default.
779
780 2009-12-29  Simon Josefsson  <simon@josefsson.org>
781         and Eric Blake  <ebb9@byu.net>
782
783         tests: don't require debug system() to pass
784         * tests/test-lstat.h (test_lstat_func): Move debug cleanup...
785         * tests/test-rmdir.h (test_rmdir_func): Likewise.
786         * tests/test-unlink.h (test_unlink_func): Likewise.
787         * tests/test-fstatat.c (main): ...into callers.
788         * tests/test-lstat.c (main): Likewise.
789         * tests/test-rmdir.c (main): Likewise.
790         * tests/test-unlink.c (main): Likewise.
791         * tests/test-unlinkat.c (main): Likewise.
792         * tests/test-areadlink-with-size.c (main): Don't require a
793         debug-only system call to pass, aiding cross-testing to mingw.
794         * tests/test-areadlink.c (main): Likewise.
795         * tests/test-areadlinkat-with-size.c (main): Likewise.
796         * tests/test-areadlinkat.c (main): Likewise.
797         * tests/test-canonicalize-lgpl.c (main): Likewise.
798         * tests/test-canonicalize.c (main): Likewise.
799         * tests/test-chown.c (main): Likewise.
800         * tests/test-fchownat.c (main): Likewise.
801         * tests/test-lchown.c (main): Likewise.
802         * tests/test-fdutimensat.c (main): Likewise.
803         * tests/test-futimens.c (main): Likewise.
804         * tests/test-link.c (main): Likewise.
805         * tests/test-linkat.c (main): Likewise.
806         * tests/test-mkdir.c (main): Likewise.
807         * tests/test-mkdirat.c (main): Likewise.
808         * tests/test-mkfifo.c (main): Likewise.
809         * tests/test-mkfifoat.c (main): Likewise.
810         * tests/test-mknod.c (main): Likewise.
811         * tests/test-readlink.c (main): Likewise.
812         * tests/test-remove.c (main): Likewise.
813         * tests/test-rename.c (main): Likewise.
814         * tests/test-renameat.c (main): Likewise.
815         * tests/test-symlink.c (main): Likewise.
816         * tests/test-symlinkat.c (main): Likewise.
817         * tests/test-utimens.c (main): Likewise.
818         * tests/test-utimensat.c (main): Likewise.
819
820 2009-12-29  Simon Josefsson  <simon@josefsson.org>
821
822         * modules/selinux-h (selinux/selinux.h, selinux/context.h): Depend
823         on $(UNUSED_PARAMETER_H) to avoid build failure.
824
825 2009-12-28  Jim Meyering  <meyering@redhat.com>
826
827         update-copyright: you may specify a max. line length other than 72
828         * build-aux/update-copyright: Honor $UPDATE_COPYRIGHT_MAX_LINE_LENGTH.
829
830         maint: use consistent FSF copyright line syntax
831         * lib/posixtm.c: Add missing comma in FSF copyright line.
832         * lib/posixtm.h: Likewise.
833         * lib/getugroups.c: Add missing ", Inc.".
834
835         pmccabe2html: emit consistent FSF copyright; remove trailing blanks
836         * build-aux/pmccabe2html: Insert comma before "Inc." in emitted
837         FSF copyright line.  Remove trailing blanks.
838
839 2009-12-28  Eric Blake  <ebb9@byu.net>
840
841         test-dup2: reduce dependencies
842         * modules/cloexec (Configure.ac): Set witness.
843         * modules/dup2-tests (Depends-on): Drop cloexec.
844         * tests/test-dup2.c (main): Skip portion of test if cloexec module
845         not present.
846         Suggested by Bruno Haible.
847
848 2009-12-26  Bruno Haible  <bruno@clisp.org>
849
850         Remove an unneeded dependency.
851         * modules/fseterr (Depends-on): Remove dup2.
852
853 2009-12-26  Eric Blake  <ebb9@byu.net>
854
855         tests: use macros.h in more places
856         * tests/macros.h (ASSERT): Depend on ASSERT_STREAM.
857         (ASSERT_STREAM): Provide default of stderr.
858         * tests/test-dirent-safer.c: Include macros.h, using alternate
859         stream for assertions.
860         * tests/test-dup-safer.c: Likewise.
861         * tests/test-freopen-safer.c: Likewise.
862         * tests/test-getopt.c: Likewise.
863         * tests/test-openat-safer.c: Likewise.
864         * tests/test-pipe.c: Likewise.
865         * tests/test-popen-safer.c: Likewise.
866         * modules/dirent-safer-tests (Files): Include macros.h.
867         * modules/unistd-safer-tests (Files): Likewise.
868         * modules/freopen-safer-tests (Files): Likewise.
869         * modules/getopt-posix-tests (Files): Likewise.
870         * modules/openat-safer-tests (Files): Likewise.
871         * modules/pipe-tests (Files): Likewise.
872
873 2009-12-26  Bruno Haible  <bruno@clisp.org>
874
875         javacomp: Portability fix.
876         * m4/javacomp.m4 (gt_JAVACOMP): Fix creation of conftestver.class so
877         that it also works on Solaris.
878
879 2009-12-26  Bruno Haible  <bruno@clisp.org>
880
881         localename: Fix storage allocation of gl_locale_name_thread's result.
882         * lib/localename.c (SIZE_BITS, string_hash, struct hash_node,
883         HASH_TABLE_SIZE, struniq_hash_table, struniq_lock, struniq): Define on
884         all platforms that have 'uselocale'.
885         (gl_locale_name_thread_unsafe): New function, extracted from
886         gl_locale_name_thread.
887         (gl_locale_name_thread): Call struniq on all platforms that have
888         'uselocale'.
889         * tests/test-localename.c (test_locale_name_thread): Check that the
890         resulting strings are permanently allocated.
891         * modules/localename-tests (Depends-on): Add strdup.
892
893 2009-12-26  Bruno Haible  <bruno@clisp.org>
894
895         * tests/test-localename.c (categories): Fill in the strings.
896
897 2009-12-26  Jim Meyering  <meyering@redhat.com>
898
899         isdir: complete the removal of m4/isdir.m4
900         * modules/isdir (configure.ac): Remove reference to gl_ISDIR.
901
902         isdir: clean up, since at least grep still uses it
903         * lib/isdir.c: Include "isdir.h".
904         (S_ISDIR): Remove now-unneeded definition.
905         * modules/isdir (Files): Add lib/isdir.h.
906         * lib/isdir.h: New file, with declaration.
907         * m4/isdir.m4: Remove file -- unneeded.
908
909 2009-12-25  Bruno Haible  <bruno@clisp.org>
910
911         selinux-h: Make generated .h files standalone.
912         * lib/se-context.in.h: Arrange to include _GL_UNUSED_PARAMETER
913         definition. Use _GL_UNUSED_PARAMETER instead of _GL_UNUSED.
914         * lib/se-selinux.in.h: Likewise.
915         * modules/selinux-h (Depends-on): Add unused-parameter.
916         (Makefile.am): Insert definition of _GL_UNUSED_PARAMETER into
917         selinux/selinux.h and selinux/context.h.
918         Suggested by Eric Blake.
919
920 2009-12-25  Bruno Haible  <bruno@clisp.org>
921
922         Move gl_FCNTL_O_FLAGS to a separate .m4 file.
923         * m4/fcntl-o.m4: New file, extracted from m4/fcntl_h.m4.
924         * m4/fcntl_h.m4 (gl_FCNTL_O_FLAGS): Remove macro.
925         * modules/fcntl-h (Files): Add m4/fcntl-o.m4.
926         * modules/localcharset (Files): Likewise. Remove m4/fcntl_h.m4.
927
928 2009-12-24  Bruno Haible  <bruno@clisp.org>
929
930         openat: Fix warning.
931         * lib/openat-proc.c: Include <unistd.h>.
932
933 2009-12-24  Bruno Haible  <bruno@clisp.org>
934
935         New module 'unused-parameter'.
936         * build-aux/unused-parameter.h: New file, extracted from earlier
937         gnulib-common.m4.
938         * modules/unused-parameter: New file.
939         * lib/unistr.h: Include unused-parameter.h.
940         (u32_mbtouc_unsafe, u32_mbtouc): Use _GL_UNUSED_PARAMETER instead of
941         _GL_UNUSED.
942         * modules/unistr/base (Depends-on): Add unused-parameter.
943
944 2009-12-24  Bruno Haible  <bruno@clisp.org>
945
946         Add missing dependencies to 'extensions' module.
947         * m4/extensions.m4: Add comment.
948         * modules/accept4 (Depends-on): Add extensions.
949         * modules/dup3 (Depends-on): Likewise.
950         * modules/fcntl (Depends-on): Likewise.
951         * modules/futimens (Depends-on): Likewise.
952         * modules/mknod (Depends-on): Likewise.
953         * modules/pipe2 (Depends-on): Likewise.
954         * modules/stat-time (Depends-on): Likewise.
955         * modules/strcasestr-simple (Depends-on): Likewise.
956         * modules/strsignal (Depends-on): Likewise.
957         * modules/utimensat (Depends-on): Likewise.
958         * modules/localcharset (Depends-on): Likewise. Needed because of
959         gl_FCNTL_O_FLAGS.
960         * modules/wcrtomb (Depends-on): Likewise. Needed because of
961         AC_TYPE_MBSTATE_T.
962         * modules/wcsnrtombs (Depends-on): Likewise.
963         * modules/wcsrtombs (Depends-on): Likewise.
964
965 2009-12-24  Bruno Haible  <bruno@clisp.org>
966
967         binary-io: Avoid gcc warning due to SET_BINARY.
968         * lib/binary-io.h (SET_BINARY): Cast the result to void.
969         Reported by Jim Meyering <jim@meyering.net>. Suggestion by Eric Blake.
970
971 2009-12-24  Bruno Haible  <bruno@clisp.org>
972
973         Avoid future namespace pollution on glibc systems.
974         * lib/arpa_inet.in.h: Don't include <sys/socket.h> on glibc systems.
975         * lib/sys_ioctl.in.h: Don't include <unistd.h> on glibc systems.
976         * lib/sys_select.in.h: Don't include <sys/time.h> and <string.h> on
977         glibc systems.
978
979 2009-12-24  Bruno Haible  <bruno@clisp.org>
980
981         Refactor common macros used in tests.
982         * tests/macros.h: New file.
983         * tests/test-areadlink.c: Include macros.h. Don't include <stdio.h>
984         and/or <stdlib.h>, if appropriate.
985         (ASSERT, SIZEOF): Remove macros.
986         * tests/test-areadlink-with-size.c: Likewise.
987         * tests/test-areadlinkat.c: Likewise.
988         * tests/test-areadlinkat-with-size.c: Likewise.
989         * tests/test-argmatch.c: Likewise.
990         * tests/test-argv-iter.c: Likewise.
991         * tests/test-array-mergesort.c: Likewise.
992         * tests/test-array_list.c: Likewise.
993         * tests/test-array_oset.c: Likewise.
994         * tests/test-avltree_list.c: Likewise.
995         * tests/test-avltree_oset.c: Likewise.
996         * tests/test-avltreehash_list.c: Likewise.
997         * tests/test-base64.c: Likewise.
998         * tests/test-binary-io.c: Likewise.
999         * tests/test-bitrotate.c: Likewise.
1000         * tests/test-btowc.c: Likewise.
1001         * tests/test-byteswap.c: Likewise.
1002         * tests/test-c-ctype.c: Likewise.
1003         * tests/test-c-stack.c: Likewise.
1004         * tests/test-c-strcasecmp.c: Likewise.
1005         * tests/test-c-strcasestr.c: Likewise.
1006         * tests/test-c-strncasecmp.c: Likewise.
1007         * tests/test-c-strstr.c: Likewise.
1008         * tests/test-canonicalize-lgpl.c: Likewise.
1009         * tests/test-canonicalize.c: Likewise.
1010         * tests/test-carray_list.c: Likewise.
1011         * tests/test-ceilf1.c: Likewise.
1012         * tests/test-ceilf2.c: Likewise.
1013         * tests/test-ceill.c: Likewise.
1014         * tests/test-chown.c: Likewise.
1015         * tests/test-cloexec.c: Likewise.
1016         * tests/test-copy-acl.c: Likewise.
1017         * tests/test-copy-file.c: Likewise.
1018         * tests/test-count-one-bits.c: Likewise.
1019         * tests/test-dprintf-posix.c: Likewise.
1020         * tests/test-dup2.c: Likewise.
1021         * tests/test-dup3.c: Likewise.
1022         * tests/test-duplocale.c: Likewise.
1023         * tests/test-fbufmode.c: Likewise.
1024         * tests/test-fchdir.c: Likewise.
1025         * tests/test-fchownat.c: Likewise.
1026         * tests/test-fcntl-safer.c: Likewise.
1027         * tests/test-fcntl.c: Likewise.
1028         * tests/test-fdopendir.c: Likewise.
1029         * tests/test-fdutimensat.c: Likewise.
1030         * tests/test-fflush2.c: Likewise.
1031         * tests/test-file-has-acl.c: Likewise.
1032         * tests/test-filevercmp.c: Likewise.
1033         * tests/test-flock.c: Likewise.
1034         * tests/test-floorf1.c: Likewise.
1035         * tests/test-floorf2.c: Likewise.
1036         * tests/test-floorl.c: Likewise.
1037         * tests/test-fnmatch.c: Likewise.
1038         * tests/test-fopen.h: Likewise.
1039         * tests/test-fpending.c: Likewise.
1040         * tests/test-fprintf-posix.c: Likewise.
1041         * tests/test-fpurge.c: Likewise.
1042         * tests/test-freadable.c: Likewise.
1043         * tests/test-freadahead.c: Likewise.
1044         * tests/test-freading.c: Likewise.
1045         * tests/test-freadptr.c: Likewise.
1046         * tests/test-freadptr2.c: Likewise.
1047         * tests/test-freadseek.c: Likewise.
1048         * tests/test-freopen.c: Likewise.
1049         * tests/test-frexp.c: Likewise.
1050         * tests/test-frexpl.c: Likewise.
1051         * tests/test-fseek.c: Likewise.
1052         * tests/test-fseeko.c: Likewise.
1053         * tests/test-fstatat.c: Likewise.
1054         * tests/test-fstrcmp.c: Likewise.
1055         * tests/test-fsync.c: Likewise.
1056         * tests/test-ftell.c: Likewise.
1057         * tests/test-ftello.c: Likewise.
1058         * tests/test-func.c: Likewise.
1059         * tests/test-futimens.c: Likewise.
1060         * tests/test-fwritable.c: Likewise.
1061         * tests/test-fwriting.c: Likewise.
1062         * tests/test-getcwd.c: Likewise.
1063         * tests/test-getdate.c: Likewise.
1064         * tests/test-getdelim.c: Likewise.
1065         * tests/test-getdtablesize.c: Likewise.
1066         * tests/test-getgroups.c: Likewise.
1067         * tests/test-getline.c: Likewise.
1068         * tests/test-getndelim2.c: Likewise.
1069         * tests/test-glob.c: Likewise.
1070         * tests/test-hash.c: Likewise.
1071         * tests/test-i-ring.c: Likewise.
1072         * tests/test-iconv-utf.c: Likewise.
1073         * tests/test-iconv.c: Likewise.
1074         * tests/test-idpriv-drop.c: Likewise.
1075         * tests/test-idpriv-droptemp.c: Likewise.
1076         * tests/test-inet_ntop.c: Likewise.
1077         * tests/test-inet_pton.c: Likewise.
1078         * tests/test-isblank.c: Likewise.
1079         * tests/test-isfinite.c: Likewise.
1080         * tests/test-isinf.c: Likewise.
1081         * tests/test-isnan.c: Likewise.
1082         * tests/test-isnand.h: Likewise.
1083         * tests/test-isnanf.h: Likewise.
1084         * tests/test-isnanl.h: Likewise.
1085         * tests/test-lchown.c: Likewise.
1086         * tests/test-ldexpl.c: Likewise.
1087         * tests/test-link.c: Likewise.
1088         * tests/test-linkat.c: Likewise.
1089         * tests/test-linked_list.c: Likewise.
1090         * tests/test-linkedhash_list.c: Likewise.
1091         * tests/test-localename.c: Likewise.
1092         * tests/test-lseek.c: Likewise.
1093         * tests/test-lstat.c: Likewise.
1094         * tests/test-mbmemcasecmp.c: Likewise.
1095         * tests/test-mbmemcasecoll.c: Likewise.
1096         * tests/test-mbrtowc.c: Likewise.
1097         * tests/test-mbscasecmp.c: Likewise.
1098         * tests/test-mbscasestr1.c: Likewise.
1099         * tests/test-mbscasestr2.c: Likewise.
1100         * tests/test-mbscasestr3.c: Likewise.
1101         * tests/test-mbscasestr4.c: Likewise.
1102         * tests/test-mbschr.c: Likewise.
1103         * tests/test-mbscspn.c: Likewise.
1104         * tests/test-mbsinit.c: Likewise.
1105         * tests/test-mbsncasecmp.c: Likewise.
1106         * tests/test-mbsnrtowcs.c: Likewise.
1107         * tests/test-mbspbrk.c: Likewise.
1108         * tests/test-mbspcasecmp.c: Likewise.
1109         * tests/test-mbsrchr.c: Likewise.
1110         * tests/test-mbsrtowcs.c: Likewise.
1111         * tests/test-mbsspn.c: Likewise.
1112         * tests/test-mbsstr1.c: Likewise.
1113         * tests/test-mbsstr2.c: Likewise.
1114         * tests/test-mbsstr3.c: Likewise.
1115         * tests/test-memchr.c: Likewise.
1116         * tests/test-memchr2.c: Likewise.
1117         * tests/test-memcmp.c: Likewise.
1118         * tests/test-memmem.c: Likewise.
1119         * tests/test-memrchr.c: Likewise.
1120         * tests/test-mkdir.c: Likewise.
1121         * tests/test-mkdirat.c: Likewise.
1122         * tests/test-mkfifo.c: Likewise.
1123         * tests/test-mkfifoat.c: Likewise.
1124         * tests/test-mknod.c: Likewise.
1125         * tests/test-nanosleep.c: Likewise.
1126         * tests/test-nl_langinfo.c: Likewise.
1127         * tests/test-obstack-printf.c: Likewise.
1128         * tests/test-open.c: Likewise.
1129         * tests/test-openat.c: Likewise.
1130         * tests/test-pipe-filter-gi1.c: Likewise.
1131         * tests/test-pipe-filter-gi2-main.c: Likewise.
1132         * tests/test-pipe-filter-ii1.c: Likewise.
1133         * tests/test-pipe-filter-ii2-main.c: Likewise.
1134         * tests/test-pipe2.c: Likewise.
1135         * tests/test-popen.h: Likewise.
1136         * tests/test-posixtm.c: Likewise.
1137         * tests/test-pread.c: Likewise.
1138         * tests/test-printf-frexp.c: Likewise.
1139         * tests/test-printf-frexpl.c: Likewise.
1140         * tests/test-printf-posix.c: Likewise.
1141         * tests/test-priv-set.c: Likewise.
1142         * tests/test-quotearg.c: Likewise.
1143         * tests/test-random_r.c: Likewise.
1144         * tests/test-rawmemchr.c: Likewise.
1145         * tests/test-rbtree_list.c: Likewise.
1146         * tests/test-rbtree_oset.c: Likewise.
1147         * tests/test-rbtreehash_list.c: Likewise.
1148         * tests/test-readlink.c: Likewise.
1149         * tests/test-remove.c: Likewise.
1150         * tests/test-rename.c: Likewise.
1151         * tests/test-renameat.c: Likewise.
1152         * tests/test-rmdir.c: Likewise.
1153         * tests/test-round1.c: Likewise.
1154         * tests/test-roundf1.c: Likewise.
1155         * tests/test-roundl.c: Likewise.
1156         * tests/test-safe-alloc.c: Likewise.
1157         * tests/test-sameacls.c: Likewise.
1158         * tests/test-set-mode-acl.c: Likewise.
1159         * tests/test-setenv.c: Likewise.
1160         * tests/test-sigaction.c: Likewise.
1161         * tests/test-signbit.c: Likewise.
1162         * tests/test-sleep.c: Likewise.
1163         * tests/test-snprintf-posix.c: Likewise.
1164         * tests/test-snprintf.c: Likewise.
1165         * tests/test-sprintf-posix.c: Likewise.
1166         * tests/test-stat-time.c: Likewise.
1167         * tests/test-stat.c: Likewise.
1168         * tests/test-strcasestr.c: Likewise.
1169         * tests/test-strchrnul.c: Likewise.
1170         * tests/test-strerror.c: Likewise.
1171         * tests/test-striconv.c: Likewise.
1172         * tests/test-striconveh.c: Likewise.
1173         * tests/test-striconveha.c: Likewise.
1174         * tests/test-strsignal.c: Likewise.
1175         * tests/test-strstr.c: Likewise.
1176         * tests/test-strtod.c: Likewise.
1177         * tests/test-strverscmp.c: Likewise.
1178         * tests/test-symlink.c: Likewise.
1179         * tests/test-symlinkat.c: Likewise.
1180         * tests/test-trunc1.c: Likewise.
1181         * tests/test-trunc2.c: Likewise.
1182         * tests/test-truncf1.c: Likewise.
1183         * tests/test-truncf2.c: Likewise.
1184         * tests/test-truncl.c: Likewise.
1185         * tests/test-uname.c: Likewise.
1186         * tests/test-unlink.c: Likewise.
1187         * tests/test-unlinkat.c: Likewise.
1188         * tests/test-unsetenv.c: Likewise.
1189         * tests/test-usleep.c: Likewise.
1190         * tests/test-utimens.c: Likewise.
1191         * tests/test-utimensat.c: Likewise.
1192         * tests/test-vasnprintf-posix.c: Likewise.
1193         * tests/test-vasnprintf-posix2.c: Likewise.
1194         * tests/test-vasnprintf.c: Likewise.
1195         * tests/test-vasprintf-posix.c: Likewise.
1196         * tests/test-vasprintf.c: Likewise.
1197         * tests/test-vdprintf-posix.c: Likewise.
1198         * tests/test-vfprintf-posix.c: Likewise.
1199         * tests/test-vprintf-posix.c: Likewise.
1200         * tests/test-vsnprintf-posix.c: Likewise.
1201         * tests/test-vsnprintf.c: Likewise.
1202         * tests/test-vsprintf-posix.c: Likewise.
1203         * tests/test-wcrtomb.c: Likewise.
1204         * tests/test-wcsnrtombs.c: Likewise.
1205         * tests/test-wcsrtombs.c: Likewise.
1206         * tests/test-wctype.c: Likewise.
1207         * tests/test-wcwidth.c: Likewise.
1208         * tests/test-xfprintf-posix.c: Likewise.
1209         * tests/test-xmemdup0.c: Likewise.
1210         * tests/test-xprintf-posix.c: Likewise.
1211         * tests/test-xvasprintf.c: Likewise.
1212         * tests/unicase/test-locale-language.c: Likewise.
1213         * tests/unicase/test-mapping-part1.h: Likewise.
1214         * tests/unicase/test-predicate-part1.h: Likewise.
1215         * tests/unicase/test-u8-casecmp.c: Likewise.
1216         * tests/unicase/test-u8-casecoll.c: Likewise.
1217         * tests/unicase/test-u8-casefold.c: Likewise.
1218         * tests/unicase/test-u8-is-cased.c: Likewise.
1219         * tests/unicase/test-u8-is-casefolded.c: Likewise.
1220         * tests/unicase/test-u8-is-lowercase.c: Likewise.
1221         * tests/unicase/test-u8-is-titlecase.c: Likewise.
1222         * tests/unicase/test-u8-is-uppercase.c: Likewise.
1223         * tests/unicase/test-u8-tolower.c: Likewise.
1224         * tests/unicase/test-u8-totitle.c: Likewise.
1225         * tests/unicase/test-u8-toupper.c: Likewise.
1226         * tests/unicase/test-u16-casecmp.c: Likewise.
1227         * tests/unicase/test-u16-casecoll.c: Likewise.
1228         * tests/unicase/test-u16-casefold.c: Likewise.
1229         * tests/unicase/test-u16-is-cased.c: Likewise.
1230         * tests/unicase/test-u16-is-casefolded.c: Likewise.
1231         * tests/unicase/test-u16-is-lowercase.c: Likewise.
1232         * tests/unicase/test-u16-is-titlecase.c: Likewise.
1233         * tests/unicase/test-u16-is-uppercase.c: Likewise.
1234         * tests/unicase/test-u16-tolower.c: Likewise.
1235         * tests/unicase/test-u16-totitle.c: Likewise.
1236         * tests/unicase/test-u16-toupper.c: Likewise.
1237         * tests/unicase/test-u32-casecmp.c: Likewise.
1238         * tests/unicase/test-u32-casecoll.c: Likewise.
1239         * tests/unicase/test-u32-casefold.c: Likewise.
1240         * tests/unicase/test-u32-is-cased.c: Likewise.
1241         * tests/unicase/test-u32-is-casefolded.c: Likewise.
1242         * tests/unicase/test-u32-is-lowercase.c: Likewise.
1243         * tests/unicase/test-u32-is-titlecase.c: Likewise.
1244         * tests/unicase/test-u32-is-uppercase.c: Likewise.
1245         * tests/unicase/test-u32-tolower.c: Likewise.
1246         * tests/unicase/test-u32-totitle.c: Likewise.
1247         * tests/unicase/test-u32-toupper.c: Likewise.
1248         * tests/unicase/test-ulc-casecmp.c: Likewise.
1249         * tests/unicase/test-ulc-casecoll.c: Likewise.
1250         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
1251         * tests/uniconv/test-u8-conv-to-enc.c: Likewise.
1252         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
1253         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
1254         * tests/uniconv/test-u16-conv-from-enc.c: Likewise.
1255         * tests/uniconv/test-u16-conv-to-enc.c: Likewise.
1256         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
1257         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
1258         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
1259         * tests/uniconv/test-u32-conv-to-enc.c: Likewise.
1260         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
1261         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
1262         * tests/unictype/test-bidi_byname.c: Likewise.
1263         * tests/unictype/test-bidi_name.c: Likewise.
1264         * tests/unictype/test-bidi_of.c: Likewise.
1265         * tests/unictype/test-bidi_test.c: Likewise.
1266         * tests/unictype/test-block_list.c: Likewise.
1267         * tests/unictype/test-block_of.c: Likewise.
1268         * tests/unictype/test-block_test.c: Likewise.
1269         * tests/unictype/test-categ_and.c: Likewise.
1270         * tests/unictype/test-categ_and_not.c: Likewise.
1271         * tests/unictype/test-categ_byname.c: Likewise.
1272         * tests/unictype/test-categ_name.c: Likewise.
1273         * tests/unictype/test-categ_none.c: Likewise.
1274         * tests/unictype/test-categ_of.c: Likewise.
1275         * tests/unictype/test-categ_or.c: Likewise.
1276         * tests/unictype/test-categ_test_withtable.c: Likewise.
1277         * tests/unictype/test-combining.c: Likewise.
1278         * tests/unictype/test-decdigit.c: Likewise.
1279         * tests/unictype/test-digit.c: Likewise.
1280         * tests/unictype/test-mirror.c: Likewise.
1281         * tests/unictype/test-numeric.c: Likewise.
1282         * tests/unictype/test-pr_byname.c: Likewise.
1283         * tests/unictype/test-pr_test.c: Likewise.
1284         * tests/unictype/test-predicate-part1.h: Likewise.
1285         * tests/unictype/test-scripts.c: Likewise.
1286         * tests/unictype/test-sy_c_ident.c: Likewise.
1287         * tests/unictype/test-sy_java_ident.c: Likewise.
1288         * tests/unilbrk/test-u8-possible-linebreaks.c: Likewise.
1289         * tests/unilbrk/test-u8-width-linebreaks.c: Likewise.
1290         * tests/unilbrk/test-u16-possible-linebreaks.c: Likewise.
1291         * tests/unilbrk/test-u16-width-linebreaks.c: Likewise.
1292         * tests/unilbrk/test-u32-possible-linebreaks.c: Likewise.
1293         * tests/unilbrk/test-u32-width-linebreaks.c: Likewise.
1294         * tests/unilbrk/test-ulc-possible-linebreaks.c: Likewise.
1295         * tests/unilbrk/test-ulc-width-linebreaks.c: Likewise.
1296         * tests/uninorm/test-canonical-decomposition.c: Likewise.
1297         * tests/uninorm/test-compat-decomposition.c: Likewise.
1298         * tests/uninorm/test-composition.c: Likewise.
1299         * tests/uninorm/test-decomposing-form.c: Likewise.
1300         * tests/uninorm/test-decomposition.c: Likewise.
1301         * tests/uninorm/test-u8-nfc.c: Likewise.
1302         * tests/uninorm/test-u8-nfd.c: Likewise.
1303         * tests/uninorm/test-u8-nfkc.c: Likewise.
1304         * tests/uninorm/test-u8-nfkd.c: Likewise.
1305         * tests/uninorm/test-u8-normcmp.c: Likewise.
1306         * tests/uninorm/test-u8-normcoll.c: Likewise.
1307         * tests/uninorm/test-u16-nfc.c: Likewise.
1308         * tests/uninorm/test-u16-nfd.c: Likewise.
1309         * tests/uninorm/test-u16-nfkc.c: Likewise.
1310         * tests/uninorm/test-u16-nfkd.c: Likewise.
1311         * tests/uninorm/test-u16-normcmp.c: Likewise.
1312         * tests/uninorm/test-u16-normcoll.c: Likewise.
1313         * tests/uninorm/test-u32-nfc.c: Likewise.
1314         * tests/uninorm/test-u32-nfd.c: Likewise.
1315         * tests/uninorm/test-u32-nfkc.c: Likewise.
1316         * tests/uninorm/test-u32-nfkd.c: Likewise.
1317         * tests/uninorm/test-u32-normalize-big.c: Likewise.
1318         * tests/uninorm/test-u32-normcmp.c: Likewise.
1319         * tests/uninorm/test-u32-normcoll.c: Likewise.
1320         * tests/uninorm/test-uninorm-filter-nfc.c: Likewise.
1321         * tests/unistdio/test-u8-asnprintf1.c: Likewise.
1322         * tests/unistdio/test-u8-vasnprintf1.c: Likewise.
1323         * tests/unistdio/test-u8-vasnprintf2.c: Likewise.
1324         * tests/unistdio/test-u8-vasnprintf3.c: Likewise.
1325         * tests/unistdio/test-u8-vasprintf1.c: Likewise.
1326         * tests/unistdio/test-u8-vsnprintf1.c: Likewise.
1327         * tests/unistdio/test-u8-vsprintf1.c: Likewise.
1328         * tests/unistdio/test-u16-asnprintf1.c: Likewise.
1329         * tests/unistdio/test-u16-vasnprintf1.c: Likewise.
1330         * tests/unistdio/test-u16-vasnprintf2.c: Likewise.
1331         * tests/unistdio/test-u16-vasnprintf3.c: Likewise.
1332         * tests/unistdio/test-u16-vasprintf1.c: Likewise.
1333         * tests/unistdio/test-u16-vsnprintf1.c: Likewise.
1334         * tests/unistdio/test-u16-vsprintf1.c: Likewise.
1335         * tests/unistdio/test-u32-asnprintf1.c: Likewise.
1336         * tests/unistdio/test-u32-vasnprintf1.c: Likewise.
1337         * tests/unistdio/test-u32-vasnprintf2.c: Likewise.
1338         * tests/unistdio/test-u32-vasnprintf3.c: Likewise.
1339         * tests/unistdio/test-u32-vasprintf1.c: Likewise.
1340         * tests/unistdio/test-u32-vsnprintf1.c: Likewise.
1341         * tests/unistdio/test-u32-vsprintf1.c: Likewise.
1342         * tests/unistdio/test-ulc-asnprintf1.c: Likewise.
1343         * tests/unistdio/test-ulc-vasnprintf1.c: Likewise.
1344         * tests/unistdio/test-ulc-vasnprintf2.c: Likewise.
1345         * tests/unistdio/test-ulc-vasnprintf3.c: Likewise.
1346         * tests/unistdio/test-ulc-vasprintf1.c: Likewise.
1347         * tests/unistdio/test-ulc-vsnprintf1.c: Likewise.
1348         * tests/unistdio/test-ulc-vsprintf1.c: Likewise.
1349         * tests/uniwbrk/test-u8-wordbreaks.c: Likewise.
1350         * tests/uniwbrk/test-u16-wordbreaks.c: Likewise.
1351         * tests/uniwbrk/test-u32-wordbreaks.c: Likewise.
1352         * tests/uniwbrk/test-ulc-wordbreaks.c: Likewise.
1353         * tests/uniwidth/test-u8-strwidth.c: Likewise.
1354         * tests/uniwidth/test-u8-width.c: Likewise.
1355         * tests/uniwidth/test-u16-strwidth.c: Likewise.
1356         * tests/uniwidth/test-u16-width.c: Likewise.
1357         * tests/uniwidth/test-u32-strwidth.c: Likewise.
1358         * tests/uniwidth/test-u32-width.c: Likewise.
1359         * tests/uniwidth/test-uc_width.c: Likewise.
1360         * tests/uniwidth/test-uc_width2.c: Likewise.
1361         * modules/acl-tests (Files): Add tests/macros.h.
1362         * modules/areadlink-tests (Files): Likewise.
1363         * modules/areadlink-with-size-tests (Files): Likewise.
1364         * modules/areadlinkat-tests (Files): Likewise.
1365         * modules/areadlinkat-with-size-tests (Files): Likewise.
1366         * modules/argmatch-tests (Files): Likewise.
1367         * modules/argv-iter-tests (Files): Likewise.
1368         * modules/array-list-tests (Files): Likewise.
1369         * modules/array-mergesort-tests (Files): Likewise.
1370         * modules/array-oset-tests (Files): Likewise.
1371         * modules/avltree-list-tests (Files): Likewise.
1372         * modules/avltree-oset-tests (Files): Likewise.
1373         * modules/avltreehash-list-tests (Files): Likewise.
1374         * modules/base64-tests (Files): Likewise.
1375         * modules/binary-io-tests (Files): Likewise.
1376         * modules/bitrotate-tests (Files): Likewise.
1377         * modules/btowc-tests (Files): Likewise.
1378         * modules/byteswap-tests (Files): Likewise.
1379         * modules/c-ctype-tests (Files): Likewise.
1380         * modules/c-stack-tests (Files): Likewise.
1381         * modules/c-strcase-tests (Files): Likewise.
1382         * modules/c-strcasestr-tests (Files): Likewise.
1383         * modules/c-strstr-tests (Files): Likewise.
1384         * modules/canonicalize-lgpl-tests (Files): Likewise.
1385         * modules/canonicalize-tests (Files): Likewise.
1386         * modules/carray-list-tests (Files): Likewise.
1387         * modules/ceilf-tests (Files): Likewise.
1388         * modules/ceill-tests (Files): Likewise.
1389         * modules/chown-tests (Files): Likewise.
1390         * modules/cloexec-tests (Files): Likewise.
1391         * modules/copy-file-tests (Files): Likewise.
1392         * modules/count-one-bits-tests (Files): Likewise.
1393         * modules/dprintf-posix-tests (Files): Likewise.
1394         * modules/dup2-tests (Files): Likewise.
1395         * modules/dup3-tests (Files): Likewise.
1396         * modules/duplocale-tests (Files): Likewise.
1397         * modules/fbufmode-tests (Files): Likewise.
1398         * modules/fchdir-tests (Files): Likewise.
1399         * modules/fcntl-safer-tests (Files): Likewise.
1400         * modules/fcntl-tests (Files): Likewise.
1401         * modules/fdopendir-tests (Files): Likewise.
1402         * modules/fdutimensat-tests (Files): Likewise.
1403         * modules/fflush-tests (Files): Likewise.
1404         * modules/filevercmp-tests (Files): Likewise.
1405         * modules/flock-tests (Files): Likewise.
1406         * modules/floorf-tests (Files): Likewise.
1407         * modules/floorl-tests (Files): Likewise.
1408         * modules/fnmatch-tests (Files): Likewise.
1409         * modules/fopen-safer-tests (Files): Likewise.
1410         * modules/fopen-tests (Files): Likewise.
1411         * modules/fpending-tests (Files): Likewise.
1412         * modules/fprintf-posix-tests (Files): Likewise.
1413         * modules/fpurge-tests (Files): Likewise.
1414         * modules/freadable-tests (Files): Likewise.
1415         * modules/freadahead-tests (Files): Likewise.
1416         * modules/freading-tests (Files): Likewise.
1417         * modules/freadptr-tests (Files): Likewise.
1418         * modules/freadseek-tests (Files): Likewise.
1419         * modules/freopen-tests (Files): Likewise.
1420         * modules/frexp-nolibm-tests (Files): Likewise.
1421         * modules/frexp-tests (Files): Likewise.
1422         * modules/frexpl-nolibm-tests (Files): Likewise.
1423         * modules/frexpl-tests (Files): Likewise.
1424         * modules/fseek-tests (Files): Likewise.
1425         * modules/fseeko-tests (Files): Likewise.
1426         * modules/fstrcmp-tests (Files): Likewise.
1427         * modules/fsync-tests (Files): Likewise.
1428         * modules/ftell-tests (Files): Likewise.
1429         * modules/ftello-tests (Files): Likewise.
1430         * modules/func-tests (Files): Likewise.
1431         * modules/futimens-tests (Files): Likewise.
1432         * modules/fwritable-tests (Files): Likewise.
1433         * modules/fwriting-tests (Files): Likewise.
1434         * modules/getcwd-tests (Files): Likewise.
1435         * modules/getdate-tests (Files): Likewise.
1436         * modules/getdelim-tests (Files): Likewise.
1437         * modules/getdtablesize-tests (Files): Likewise.
1438         * modules/getgroups-tests (Files): Likewise.
1439         * modules/getline-tests (Files): Likewise.
1440         * modules/getndelim2-tests (Files): Likewise.
1441         * modules/glob-tests (Files): Likewise.
1442         * modules/hash-tests (Files): Likewise.
1443         * modules/i-ring-tests (Files): Likewise.
1444         * modules/iconv-tests (Files): Likewise.
1445         * modules/iconv_open-utf-tests (Files): Likewise.
1446         * modules/idpriv-drop-tests (Files): Likewise.
1447         * modules/idpriv-droptemp-tests (Files): Likewise.
1448         * modules/inet_ntop-tests (Files): Likewise.
1449         * modules/inet_pton-tests (Files): Likewise.
1450         * modules/isblank-tests (Files): Likewise.
1451         * modules/isfinite-tests (Files): Likewise.
1452         * modules/isinf-tests (Files): Likewise.
1453         * modules/isnan-tests (Files): Likewise.
1454         * modules/isnand-nolibm-tests (Files): Likewise.
1455         * modules/isnand-tests (Files): Likewise.
1456         * modules/isnanf-nolibm-tests (Files): Likewise.
1457         * modules/isnanf-tests (Files): Likewise.
1458         * modules/isnanl-nolibm-tests (Files): Likewise.
1459         * modules/isnanl-tests (Files): Likewise.
1460         * modules/lchown-tests (Files): Likewise.
1461         * modules/ldexpl-tests (Files): Likewise.
1462         * modules/link-tests (Files): Likewise.
1463         * modules/linkat-tests (Files): Likewise.
1464         * modules/linked-list-tests (Files): Likewise.
1465         * modules/linkedhash-list-tests (Files): Likewise.
1466         * modules/localename-tests (Files): Likewise.
1467         * modules/lseek-tests (Files): Likewise.
1468         * modules/lstat-tests (Files): Likewise.
1469         * modules/mbmemcasecmp-tests (Files): Likewise.
1470         * modules/mbmemcasecoll-tests (Files): Likewise.
1471         * modules/mbrtowc-tests (Files): Likewise.
1472         * modules/mbscasecmp-tests (Files): Likewise.
1473         * modules/mbscasestr-tests (Files): Likewise.
1474         * modules/mbschr-tests (Files): Likewise.
1475         * modules/mbscspn-tests (Files): Likewise.
1476         * modules/mbsinit-tests (Files): Likewise.
1477         * modules/mbsncasecmp-tests (Files): Likewise.
1478         * modules/mbsnrtowcs-tests (Files): Likewise.
1479         * modules/mbspbrk-tests (Files): Likewise.
1480         * modules/mbspcasecmp-tests (Files): Likewise.
1481         * modules/mbsrchr-tests (Files): Likewise.
1482         * modules/mbsrtowcs-tests (Files): Likewise.
1483         * modules/mbsspn-tests (Files): Likewise.
1484         * modules/mbsstr-tests (Files): Likewise.
1485         * modules/memchr-tests (Files): Likewise.
1486         * modules/memchr2-tests (Files): Likewise.
1487         * modules/memcmp-tests (Files): Likewise.
1488         * modules/memmem-tests (Files): Likewise.
1489         * modules/memrchr-tests (Files): Likewise.
1490         * modules/mkdir-tests (Files): Likewise.
1491         * modules/mkfifo-tests (Files): Likewise.
1492         * modules/mkfifoat-tests (Files): Likewise.
1493         * modules/mknod-tests (Files): Likewise.
1494         * modules/nanosleep-tests (Files): Likewise.
1495         * modules/nl_langinfo-tests (Files): Likewise.
1496         * modules/obstack-printf-tests (Files): Likewise.
1497         * modules/open-tests (Files): Likewise.
1498         * modules/openat-tests (Files): Likewise.
1499         * modules/pipe-filter-gi-tests (Files): Likewise.
1500         * modules/pipe-filter-ii-tests (Files): Likewise.
1501         * modules/pipe2-tests (Files): Likewise.
1502         * modules/popen-safer-tests (Files): Likewise.
1503         * modules/popen-tests (Files): Likewise.
1504         * modules/posixtm-tests (Files): Likewise.
1505         * modules/pread-tests (Files): Likewise.
1506         * modules/printf-frexp-tests (Files): Likewise.
1507         * modules/printf-frexpl-tests (Files): Likewise.
1508         * modules/printf-posix-tests (Files): Likewise.
1509         * modules/priv-set-tests (Files): Likewise.
1510         * modules/quotearg-tests (Files): Likewise.
1511         * modules/random_r-tests (Files): Likewise.
1512         * modules/rawmemchr-tests (Files): Likewise.
1513         * modules/rbtree-list-tests (Files): Likewise.
1514         * modules/rbtree-oset-tests (Files): Likewise.
1515         * modules/rbtreehash-list-tests (Files): Likewise.
1516         * modules/readlink-tests (Files): Likewise.
1517         * modules/remove-tests (Files): Likewise.
1518         * modules/rename-tests (Files): Likewise.
1519         * modules/renameat-tests (Files): Likewise.
1520         * modules/rmdir-tests (Files): Likewise.
1521         * modules/round-tests (Files): Likewise.
1522         * modules/roundf-tests (Files): Likewise.
1523         * modules/roundl-tests (Files): Likewise.
1524         * modules/safe-alloc-tests (Files): Likewise.
1525         * modules/setenv-tests (Files): Likewise.
1526         * modules/sigaction-tests (Files): Likewise.
1527         * modules/signbit-tests (Files): Likewise.
1528         * modules/sleep-tests (Files): Likewise.
1529         * modules/snprintf-posix-tests (Files): Likewise.
1530         * modules/snprintf-tests (Files): Likewise.
1531         * modules/sprintf-posix-tests (Files): Likewise.
1532         * modules/stat-tests (Files): Likewise.
1533         * modules/stat-time-tests (Files): Likewise.
1534         * modules/strcasestr-tests (Files): Likewise.
1535         * modules/strchrnul-tests (Files): Likewise.
1536         * modules/strerror-tests (Files): Likewise.
1537         * modules/striconv-tests (Files): Likewise.
1538         * modules/striconveh-tests (Files): Likewise.
1539         * modules/striconveha-tests (Files): Likewise.
1540         * modules/strsignal-tests (Files): Likewise.
1541         * modules/strstr-tests (Files): Likewise.
1542         * modules/strtod-tests (Files): Likewise.
1543         * modules/strverscmp-tests (Files): Likewise.
1544         * modules/symlink-tests (Files): Likewise.
1545         * modules/symlinkat-tests (Files): Likewise.
1546         * modules/trunc-tests (Files): Likewise.
1547         * modules/truncf-tests (Files): Likewise.
1548         * modules/truncl-tests (Files): Likewise.
1549         * modules/uname-tests (Files): Likewise.
1550         * modules/unicase/cased-tests (Files): Likewise.
1551         * modules/unicase/ignorable-tests (Files): Likewise.
1552         * modules/unicase/locale-language-tests (Files): Likewise.
1553         * modules/unicase/tolower-tests (Files): Likewise.
1554         * modules/unicase/totitle-tests (Files): Likewise.
1555         * modules/unicase/toupper-tests (Files): Likewise.
1556         * modules/unicase/u8-casecmp-tests (Files): Likewise.
1557         * modules/unicase/u8-casecoll-tests (Files): Likewise.
1558         * modules/unicase/u8-casefold-tests (Files): Likewise.
1559         * modules/unicase/u8-is-cased-tests (Files): Likewise.
1560         * modules/unicase/u8-is-casefolded-tests (Files): Likewise.
1561         * modules/unicase/u8-is-lowercase-tests (Files): Likewise.
1562         * modules/unicase/u8-is-titlecase-tests (Files): Likewise.
1563         * modules/unicase/u8-is-uppercase-tests (Files): Likewise.
1564         * modules/unicase/u8-tolower-tests (Files): Likewise.
1565         * modules/unicase/u8-totitle-tests (Files): Likewise.
1566         * modules/unicase/u8-toupper-tests (Files): Likewise.
1567         * modules/unicase/u16-casecmp-tests (Files): Likewise.
1568         * modules/unicase/u16-casecoll-tests (Files): Likewise.
1569         * modules/unicase/u16-casefold-tests (Files): Likewise.
1570         * modules/unicase/u16-is-cased-tests (Files): Likewise.
1571         * modules/unicase/u16-is-casefolded-tests (Files): Likewise.
1572         * modules/unicase/u16-is-lowercase-tests (Files): Likewise.
1573         * modules/unicase/u16-is-titlecase-tests (Files): Likewise.
1574         * modules/unicase/u16-is-uppercase-tests (Files): Likewise.
1575         * modules/unicase/u16-tolower-tests (Files): Likewise.
1576         * modules/unicase/u16-totitle-tests (Files): Likewise.
1577         * modules/unicase/u16-toupper-tests (Files): Likewise.
1578         * modules/unicase/u32-casecmp-tests (Files): Likewise.
1579         * modules/unicase/u32-casecoll-tests (Files): Likewise.
1580         * modules/unicase/u32-casefold-tests (Files): Likewise.
1581         * modules/unicase/u32-is-cased-tests (Files): Likewise.
1582         * modules/unicase/u32-is-casefolded-tests (Files): Likewise.
1583         * modules/unicase/u32-is-lowercase-tests (Files): Likewise.
1584         * modules/unicase/u32-is-titlecase-tests (Files): Likewise.
1585         * modules/unicase/u32-is-uppercase-tests (Files): Likewise.
1586         * modules/unicase/u32-tolower-tests (Files): Likewise.
1587         * modules/unicase/u32-totitle-tests (Files): Likewise.
1588         * modules/unicase/u32-toupper-tests (Files): Likewise.
1589         * modules/unicase/ulc-casecmp-tests (Files): Likewise.
1590         * modules/unicase/ulc-casecoll-tests (Files): Likewise.
1591         * modules/uniconv/u8-conv-from-enc-tests (Files): Likewise.
1592         * modules/uniconv/u8-conv-to-enc-tests (Files): Likewise.
1593         * modules/uniconv/u8-strconv-from-enc-tests (Files): Likewise.
1594         * modules/uniconv/u8-strconv-to-enc-tests (Files): Likewise.
1595         * modules/uniconv/u16-conv-from-enc-tests (Files): Likewise.
1596         * modules/uniconv/u16-conv-to-enc-tests (Files): Likewise.
1597         * modules/uniconv/u16-strconv-from-enc-tests (Files): Likewise.
1598         * modules/uniconv/u16-strconv-to-enc-tests (Files): Likewise.
1599         * modules/uniconv/u32-conv-from-enc-tests (Files): Likewise.
1600         * modules/uniconv/u32-conv-to-enc-tests (Files): Likewise.
1601         * modules/uniconv/u32-strconv-from-enc-tests (Files): Likewise.
1602         * modules/uniconv/u32-strconv-to-enc-tests (Files): Likewise.
1603         * modules/unictype/bidicategory-byname-tests (Files): Likewise.
1604         * modules/unictype/bidicategory-name-tests (Files): Likewise.
1605         * modules/unictype/bidicategory-of-tests (Files): Likewise.
1606         * modules/unictype/bidicategory-test-tests (Files): Likewise.
1607         * modules/unictype/block-list-tests (Files): Likewise.
1608         * modules/unictype/block-of-tests (Files): Likewise.
1609         * modules/unictype/block-test-tests (Files): Likewise.
1610         * modules/unictype/category-C-tests (Files): Likewise.
1611         * modules/unictype/category-Cc-tests (Files): Likewise.
1612         * modules/unictype/category-Cf-tests (Files): Likewise.
1613         * modules/unictype/category-Cn-tests (Files): Likewise.
1614         * modules/unictype/category-Co-tests (Files): Likewise.
1615         * modules/unictype/category-Cs-tests (Files): Likewise.
1616         * modules/unictype/category-L-tests (Files): Likewise.
1617         * modules/unictype/category-Ll-tests (Files): Likewise.
1618         * modules/unictype/category-Lm-tests (Files): Likewise.
1619         * modules/unictype/category-Lo-tests (Files): Likewise.
1620         * modules/unictype/category-Lt-tests (Files): Likewise.
1621         * modules/unictype/category-Lu-tests (Files): Likewise.
1622         * modules/unictype/category-M-tests (Files): Likewise.
1623         * modules/unictype/category-Mc-tests (Files): Likewise.
1624         * modules/unictype/category-Me-tests (Files): Likewise.
1625         * modules/unictype/category-Mn-tests (Files): Likewise.
1626         * modules/unictype/category-N-tests (Files): Likewise.
1627         * modules/unictype/category-Nd-tests (Files): Likewise.
1628         * modules/unictype/category-Nl-tests (Files): Likewise.
1629         * modules/unictype/category-No-tests (Files): Likewise.
1630         * modules/unictype/category-P-tests (Files): Likewise.
1631         * modules/unictype/category-Pc-tests (Files): Likewise.
1632         * modules/unictype/category-Pd-tests (Files): Likewise.
1633         * modules/unictype/category-Pe-tests (Files): Likewise.
1634         * modules/unictype/category-Pf-tests (Files): Likewise.
1635         * modules/unictype/category-Pi-tests (Files): Likewise.
1636         * modules/unictype/category-Po-tests (Files): Likewise.
1637         * modules/unictype/category-Ps-tests (Files): Likewise.
1638         * modules/unictype/category-S-tests (Files): Likewise.
1639         * modules/unictype/category-Sc-tests (Files): Likewise.
1640         * modules/unictype/category-Sk-tests (Files): Likewise.
1641         * modules/unictype/category-Sm-tests (Files): Likewise.
1642         * modules/unictype/category-So-tests (Files): Likewise.
1643         * modules/unictype/category-Z-tests (Files): Likewise.
1644         * modules/unictype/category-Zl-tests (Files): Likewise.
1645         * modules/unictype/category-Zp-tests (Files): Likewise.
1646         * modules/unictype/category-Zs-tests (Files): Likewise.
1647         * modules/unictype/category-and-not-tests (Files): Likewise.
1648         * modules/unictype/category-and-tests (Files): Likewise.
1649         * modules/unictype/category-byname-tests (Files): Likewise.
1650         * modules/unictype/category-name-tests (Files): Likewise.
1651         * modules/unictype/category-none-tests (Files): Likewise.
1652         * modules/unictype/category-of-tests (Files): Likewise.
1653         * modules/unictype/category-or-tests (Files): Likewise.
1654         * modules/unictype/category-test-withtable-tests (Files): Likewise.
1655         * modules/unictype/combining-class-tests (Files): Likewise.
1656         * modules/unictype/ctype-alnum-tests (Files): Likewise.
1657         * modules/unictype/ctype-alpha-tests (Files): Likewise.
1658         * modules/unictype/ctype-blank-tests (Files): Likewise.
1659         * modules/unictype/ctype-cntrl-tests (Files): Likewise.
1660         * modules/unictype/ctype-digit-tests (Files): Likewise.
1661         * modules/unictype/ctype-graph-tests (Files): Likewise.
1662         * modules/unictype/ctype-lower-tests (Files): Likewise.
1663         * modules/unictype/ctype-print-tests (Files): Likewise.
1664         * modules/unictype/ctype-punct-tests (Files): Likewise.
1665         * modules/unictype/ctype-space-tests (Files): Likewise.
1666         * modules/unictype/ctype-upper-tests (Files): Likewise.
1667         * modules/unictype/ctype-xdigit-tests (Files): Likewise.
1668         * modules/unictype/decimal-digit-tests (Files): Likewise.
1669         * modules/unictype/digit-tests (Files): Likewise.
1670         * modules/unictype/mirror-tests (Files): Likewise.
1671         * modules/unictype/numeric-tests (Files): Likewise.
1672         * modules/unictype/property-alphabetic-tests (Files): Likewise.
1673         * modules/unictype/property-ascii-hex-digit-tests (Files): Likewise.
1674         * modules/unictype/property-bidi-arabic-digit-tests (Files): Likewise.
1675         * modules/unictype/property-bidi-arabic-right-to-left-tests (Files):
1676         Likewise.
1677         * modules/unictype/property-bidi-block-separator-tests (Files):
1678         Likewise.
1679         * modules/unictype/property-bidi-boundary-neutral-tests (Files):
1680         Likewise.
1681         * modules/unictype/property-bidi-common-separator-tests (Files):
1682         Likewise.
1683         * modules/unictype/property-bidi-control-tests (Files): Likewise.
1684         * modules/unictype/property-bidi-embedding-or-override-tests (Files):
1685         Likewise.
1686         * modules/unictype/property-bidi-eur-num-separator-tests (Files):
1687         Likewise.
1688         * modules/unictype/property-bidi-eur-num-terminator-tests (Files):
1689         Likewise.
1690         * modules/unictype/property-bidi-european-digit-tests (Files): Likewise.
1691         * modules/unictype/property-bidi-hebrew-right-to-left-tests (Files):
1692         Likewise.
1693         * modules/unictype/property-bidi-left-to-right-tests (Files): Likewise.
1694         * modules/unictype/property-bidi-non-spacing-mark-tests (Files):
1695         Likewise.
1696         * modules/unictype/property-bidi-other-neutral-tests (Files): Likewise.
1697         * modules/unictype/property-bidi-pdf-tests (Files): Likewise.
1698         * modules/unictype/property-bidi-segment-separator-tests (Files):
1699         Likewise.
1700         * modules/unictype/property-bidi-whitespace-tests (Files): Likewise.
1701         * modules/unictype/property-byname-tests (Files): Likewise.
1702         * modules/unictype/property-combining-tests (Files): Likewise.
1703         * modules/unictype/property-composite-tests (Files): Likewise.
1704         * modules/unictype/property-currency-symbol-tests (Files): Likewise.
1705         * modules/unictype/property-dash-tests (Files): Likewise.
1706         * modules/unictype/property-decimal-digit-tests (Files): Likewise.
1707         * modules/unictype/property-default-ignorable-code-point-tests (Files):
1708         Likewise.
1709         * modules/unictype/property-deprecated-tests (Files): Likewise.
1710         * modules/unictype/property-diacritic-tests (Files): Likewise.
1711         * modules/unictype/property-extender-tests (Files): Likewise.
1712         * modules/unictype/property-format-control-tests (Files): Likewise.
1713         * modules/unictype/property-grapheme-base-tests (Files): Likewise.
1714         * modules/unictype/property-grapheme-extend-tests (Files): Likewise.
1715         * modules/unictype/property-grapheme-link-tests (Files): Likewise.
1716         * modules/unictype/property-hex-digit-tests (Files): Likewise.
1717         * modules/unictype/property-hyphen-tests (Files): Likewise.
1718         * modules/unictype/property-id-continue-tests (Files): Likewise.
1719         * modules/unictype/property-id-start-tests (Files): Likewise.
1720         * modules/unictype/property-ideographic-tests (Files): Likewise.
1721         * modules/unictype/property-ids-binary-operator-tests (Files): Likewise.
1722         * modules/unictype/property-ids-trinary-operator-tests (Files):
1723         Likewise.
1724         * modules/unictype/property-ignorable-control-tests (Files): Likewise.
1725         * modules/unictype/property-iso-control-tests (Files): Likewise.
1726         * modules/unictype/property-join-control-tests (Files): Likewise.
1727         * modules/unictype/property-left-of-pair-tests (Files): Likewise.
1728         * modules/unictype/property-line-separator-tests (Files): Likewise.
1729         * modules/unictype/property-logical-order-exception-tests (Files):
1730         Likewise.
1731         * modules/unictype/property-lowercase-tests (Files): Likewise.
1732         * modules/unictype/property-math-tests (Files): Likewise.
1733         * modules/unictype/property-non-break-tests (Files): Likewise.
1734         * modules/unictype/property-not-a-character-tests (Files): Likewise.
1735         * modules/unictype/property-numeric-tests (Files): Likewise.
1736         * modules/unictype/property-other-alphabetic-tests (Files): Likewise.
1737         * modules/unictype/property-other-default-ignorable-code-point-tests
1738         (Files): Likewise.
1739         * modules/unictype/property-other-grapheme-extend-tests (Files):
1740         Likewise.
1741         * modules/unictype/property-other-id-continue-tests (Files): Likewise.
1742         * modules/unictype/property-other-id-start-tests (Files): Likewise.
1743         * modules/unictype/property-other-lowercase-tests (Files): Likewise.
1744         * modules/unictype/property-other-math-tests (Files): Likewise.
1745         * modules/unictype/property-other-uppercase-tests (Files): Likewise.
1746         * modules/unictype/property-paired-punctuation-tests (Files): Likewise.
1747         * modules/unictype/property-paragraph-separator-tests (Files): Likewise.
1748         * modules/unictype/property-pattern-syntax-tests (Files): Likewise.
1749         * modules/unictype/property-pattern-white-space-tests (Files): Likewise.
1750         * modules/unictype/property-private-use-tests (Files): Likewise.
1751         * modules/unictype/property-punctuation-tests (Files): Likewise.
1752         * modules/unictype/property-quotation-mark-tests (Files): Likewise.
1753         * modules/unictype/property-radical-tests (Files): Likewise.
1754         * modules/unictype/property-sentence-terminal-tests (Files): Likewise.
1755         * modules/unictype/property-soft-dotted-tests (Files): Likewise.
1756         * modules/unictype/property-space-tests (Files): Likewise.
1757         * modules/unictype/property-terminal-punctuation-tests (Files):
1758         Likewise.
1759         * modules/unictype/property-test-tests (Files): Likewise.
1760         * modules/unictype/property-titlecase-tests (Files): Likewise.
1761         * modules/unictype/property-unassigned-code-value-tests (Files):
1762         Likewise.
1763         * modules/unictype/property-unified-ideograph-tests (Files): Likewise.
1764         * modules/unictype/property-uppercase-tests (Files): Likewise.
1765         * modules/unictype/property-variation-selector-tests (Files): Likewise.
1766         * modules/unictype/property-white-space-tests (Files): Likewise.
1767         * modules/unictype/property-xid-continue-tests (Files): Likewise.
1768         * modules/unictype/property-xid-start-tests (Files): Likewise.
1769         * modules/unictype/property-zero-width-tests (Files): Likewise.
1770         * modules/unictype/scripts-tests (Files): Likewise.
1771         * modules/unictype/syntax-c-ident-tests (Files): Likewise.
1772         * modules/unictype/syntax-c-whitespace-tests (Files): Likewise.
1773         * modules/unictype/syntax-java-ident-tests (Files): Likewise.
1774         * modules/unictype/syntax-java-whitespace-tests (Files): Likewise.
1775         * modules/unilbrk/u8-possible-linebreaks-tests (Files): Likewise.
1776         * modules/unilbrk/u8-width-linebreaks-tests (Files): Likewise.
1777         * modules/unilbrk/u16-possible-linebreaks-tests (Files): Likewise.
1778         * modules/unilbrk/u16-width-linebreaks-tests (Files): Likewise.
1779         * modules/unilbrk/u32-possible-linebreaks-tests (Files): Likewise.
1780         * modules/unilbrk/u32-width-linebreaks-tests (Files): Likewise.
1781         * modules/unilbrk/ulc-possible-linebreaks-tests (Files): Likewise.
1782         * modules/unilbrk/ulc-width-linebreaks-tests (Files): Likewise.
1783         * modules/uninorm/canonical-decomposition-tests (Files): Likewise.
1784         * modules/uninorm/compat-decomposition-tests (Files): Likewise.
1785         * modules/uninorm/composition-tests (Files): Likewise.
1786         * modules/uninorm/decomposing-form-tests (Files): Likewise.
1787         * modules/uninorm/decomposition-tests (Files): Likewise.
1788         * modules/uninorm/filter-tests (Files): Likewise.
1789         * modules/uninorm/nfc-tests (Files): Likewise.
1790         * modules/uninorm/nfd-tests (Files): Likewise.
1791         * modules/uninorm/nfkc-tests (Files): Likewise.
1792         * modules/uninorm/nfkd-tests (Files): Likewise.
1793         * modules/uninorm/u8-normcmp-tests (Files): Likewise.
1794         * modules/uninorm/u8-normcoll-tests (Files): Likewise.
1795         * modules/uninorm/u16-normcmp-tests (Files): Likewise.
1796         * modules/uninorm/u16-normcoll-tests (Files): Likewise.
1797         * modules/uninorm/u32-normcmp-tests (Files): Likewise.
1798         * modules/uninorm/u32-normcoll-tests (Files): Likewise.
1799         * modules/unistdio/u8-asnprintf-tests (Files): Likewise.
1800         * modules/unistdio/u8-vasnprintf-tests (Files): Likewise.
1801         * modules/unistdio/u8-vasprintf-tests (Files): Likewise.
1802         * modules/unistdio/u8-vsnprintf-tests (Files): Likewise.
1803         * modules/unistdio/u8-vsprintf-tests (Files): Likewise.
1804         * modules/unistdio/u16-asnprintf-tests (Files): Likewise.
1805         * modules/unistdio/u16-vasnprintf-tests (Files): Likewise.
1806         * modules/unistdio/u16-vasprintf-tests (Files): Likewise.
1807         * modules/unistdio/u16-vsnprintf-tests (Files): Likewise.
1808         * modules/unistdio/u16-vsprintf-tests (Files): Likewise.
1809         * modules/unistdio/u32-asnprintf-tests (Files): Likewise.
1810         * modules/unistdio/u32-vasnprintf-tests (Files): Likewise.
1811         * modules/unistdio/u32-vasprintf-tests (Files): Likewise.
1812         * modules/unistdio/u32-vsnprintf-tests (Files): Likewise.
1813         * modules/unistdio/u32-vsprintf-tests (Files): Likewise.
1814         * modules/unistdio/ulc-asnprintf-tests (Files): Likewise.
1815         * modules/unistdio/ulc-vasnprintf-tests (Files): Likewise.
1816         * modules/unistdio/ulc-vasprintf-tests (Files): Likewise.
1817         * modules/unistdio/ulc-vsnprintf-tests (Files): Likewise.
1818         * modules/unistdio/ulc-vsprintf-tests (Files): Likewise.
1819         * modules/uniwbrk/u8-wordbreaks-tests (Files): Likewise.
1820         * modules/uniwbrk/u16-wordbreaks-tests (Files): Likewise.
1821         * modules/uniwbrk/u32-wordbreaks-tests (Files): Likewise.
1822         * modules/uniwbrk/ulc-wordbreaks-tests (Files): Likewise.
1823         * modules/uniwidth/u8-strwidth-tests (Files): Likewise.
1824         * modules/uniwidth/u8-width-tests (Files): Likewise.
1825         * modules/uniwidth/u16-strwidth-tests (Files): Likewise.
1826         * modules/uniwidth/u16-width-tests (Files): Likewise.
1827         * modules/uniwidth/u32-strwidth-tests (Files): Likewise.
1828         * modules/uniwidth/u32-width-tests (Files): Likewise.
1829         * modules/uniwidth/width-tests (Files): Likewise.
1830         * modules/unlink-tests (Files): Likewise.
1831         * modules/unsetenv-tests (Files): Likewise.
1832         * modules/usleep-tests (Files): Likewise.
1833         * modules/utimens-tests (Files): Likewise.
1834         * modules/utimensat-tests (Files): Likewise.
1835         * modules/vasnprintf-posix-tests (Files): Likewise.
1836         * modules/vasnprintf-tests (Files): Likewise.
1837         * modules/vasprintf-posix-tests (Files): Likewise.
1838         * modules/vasprintf-tests (Files): Likewise.
1839         * modules/vdprintf-posix-tests (Files): Likewise.
1840         * modules/vfprintf-posix-tests (Files): Likewise.
1841         * modules/vprintf-posix-tests (Files): Likewise.
1842         * modules/vsnprintf-posix-tests (Files): Likewise.
1843         * modules/vsnprintf-tests (Files): Likewise.
1844         * modules/vsprintf-posix-tests (Files): Likewise.
1845         * modules/wcrtomb-tests (Files): Likewise.
1846         * modules/wcsnrtombs-tests (Files): Likewise.
1847         * modules/wcsrtombs-tests (Files): Likewise.
1848         * modules/wctype-tests (Files): Likewise.
1849         * modules/wcwidth-tests (Files): Likewise.
1850         * modules/xmemdup0-tests (Files): Likewise.
1851         * modules/xprintf-posix-tests (Files): Likewise.
1852         * modules/xvasprintf-tests (Files): Likewise.
1853
1854 2009-12-24  Eric Blake  <ebb9@byu.net>
1855
1856         test-nanosleep: fix typo
1857         * tests/test-nanosleep.c (SIGNATURE_CHECK): Fix typo in previous
1858         patch.
1859         Reported by Bruno Haible.
1860
1861 2009-12-24  Bruno Haible  <bruno@clisp.org>
1862
1863         Reduce namespace pollution on glibc systems.
1864         * lib/inttypes.in.h: Don't include <stdint.h> on glibc systems.
1865         * lib/stdlib.in.h: Don't include <stdint.h>, <unistd.h> on glibc
1866         systems.
1867         * lib/unistd.in.h: Don't include <stdio.h>, <fcntl.h>, <stdlib.h>,
1868         <getopt.h> on glibc systems.
1869         * lib/fcntl.in.h: Don't include <sys/stat.h>, <unistd.h> on glibc
1870         systems.
1871         * lib/fcntl.c: Include <unistd.h> here instead.
1872
1873 2009-12-24  Bruno Haible  <bruno@clisp.org>
1874
1875         * lib/stdlib.in.h (includes): Fix typo in today's commit.
1876
1877 2009-12-24  Eric Blake  <ebb9@byu.net>
1878
1879         tests: add signature checks
1880         * tests/signature.h (SIGNATURE_CHECK): New file.
1881         * modules/atexit-tests (Files): Use it.
1882         * modules/btowc-tests (Files): Likewise.
1883         * modules/canonicalize-lgpl-tests (Files): Likewise.
1884         * modules/ceilf-tests (Files): Likewise.
1885         * modules/ceill-tests (Files): Likewise.
1886         * modules/chown-tests (Files): Likewise.
1887         * modules/dprintf-posix-tests (Files): Likewise.
1888         * modules/dup2-tests (Files): Likewise.
1889         * modules/dup3-tests (Files): Likewise.
1890         * modules/duplocale-tests (Files): Likewise.
1891         * modules/fchdir-tests (Files): Likewise.
1892         * modules/fcntl-tests (Files): Likewise.
1893         * modules/fdopendir-tests (Files): Likewise.
1894         * modules/fflush-tests (Files): Likewise.
1895         * modules/flock-tests (Files): Likewise.
1896         * modules/floorf-tests (Files): Likewise.
1897         * modules/floorl-tests (Files): Likewise.
1898         * modules/fnmatch-tests (Files): Likewise.
1899         * modules/fopen-tests (Files): Likewise.
1900         * modules/fprintf-posix-tests (Files): Likewise.
1901         * modules/freopen-tests (Files): Likewise.
1902         * modules/frexp-nolibm-tests (Files): Likewise.
1903         * modules/frexp-tests (Files): Likewise.
1904         * modules/frexpl-nolibm-tests (Files): Likewise.
1905         * modules/frexpl-tests (Files): Likewise.
1906         * modules/fseek-tests (Files): Likewise.
1907         * modules/fseeko-tests (Files): Likewise.
1908         * modules/fsync-tests (Files): Likewise.
1909         * modules/ftell-tests (Files): Likewise.
1910         * modules/ftello-tests (Files): Likewise.
1911         * modules/futimens-tests (Files): Likewise.
1912         * modules/getaddrinfo-tests (Files): Likewise.
1913         * modules/getcwd-tests (Files): Likewise.
1914         * modules/getdelim-tests (Files): Likewise.
1915         * modules/getdtablesize-tests (Files): Likewise.
1916         * modules/getgroups-tests (Files): Likewise.
1917         * modules/gethostname-tests (Files): Likewise.
1918         * modules/getline-tests (Files): Likewise.
1919         * modules/getopt-posix-tests (Files): Likewise.
1920         * modules/gettimeofday-tests (Files): Likewise.
1921         * modules/glob-tests (Files): Likewise.
1922         * modules/iconv-tests (Files): Likewise.
1923         * modules/inet_ntop-tests (Files): Likewise.
1924         * modules/inet_pton-tests (Files): Likewise.
1925         * modules/isblank-tests (Files): Likewise.
1926         * modules/lchown-tests (Files): Likewise.
1927         * modules/ldexpl-tests (Files): Likewise.
1928         * modules/link-tests (Files): Likewise.
1929         * modules/linkat-tests (Files): Likewise.
1930         * modules/lseek-tests (Files): Likewise.
1931         * modules/lstat-tests (Files): Likewise.
1932         * modules/mbrtowc-tests (Files): Likewise.
1933         * modules/mbsinit-tests (Files): Likewise.
1934         * modules/mbsnrtowcs-tests (Files): Likewise.
1935         * modules/mbsrtowcs-tests (Files): Likewise.
1936         * modules/memchr-tests (Files): Likewise.
1937         * modules/memcmp-tests (Files): Likewise.
1938         * modules/memmem-tests (Files): Likewise.
1939         * modules/memrchr-tests (Files): Likewise.
1940         * modules/mkdir-tests (Files): Likewise.
1941         * modules/mkfifo-tests (Files): Likewise.
1942         * modules/mkfifoat-tests (Files): Likewise.
1943         * modules/mknod-tests (Files): Likewise.
1944         * modules/nanosleep-tests (Files): Likewise.
1945         * modules/nl_langinfo-tests (Files): Likewise.
1946         * modules/obstack-printf-tests (Files): Likewise.
1947         * modules/open-tests (Files): Likewise.
1948         * modules/openat-tests (Files): Likewise.
1949         * modules/perror-tests (Files): Likewise.
1950         * modules/pipe2-tests (Files): Likewise.
1951         * modules/poll-tests (Files): Likewise.
1952         * modules/popen-tests (Files): Likewise.
1953         * modules/posix_spawn-tests (Files): Likewise.
1954         * modules/posix_spawnp-tests (Files): Likewise.
1955         * modules/pread-tests (Files): Likewise.
1956         * modules/printf-posix-tests (Files): Likewise.
1957         * modules/pty-tests (Files): Likewise.
1958         * modules/random_r-tests (Files): Likewise.
1959         * modules/rawmemchr-tests (Files): Likewise.
1960         * modules/readlink-tests (Files): Likewise.
1961         * modules/remove-tests (Files): Likewise.
1962         * modules/rename-tests (Files): Likewise.
1963         * modules/renameat-tests (Files): Likewise.
1964         * modules/rmdir-tests (Files): Likewise.
1965         * modules/round-tests (Files): Likewise.
1966         * modules/roundf-tests (Files): Likewise.
1967         * modules/roundl-tests (Files): Likewise.
1968         * modules/select-tests (Files): Likewise.
1969         * modules/setenv-tests (Files): Likewise.
1970         * modules/sigaction-tests (Files): Likewise.
1971         * modules/sleep-tests (Files): Likewise.
1972         * modules/snprintf-posix-tests (Files): Likewise.
1973         * modules/snprintf-tests (Files): Likewise.
1974         * modules/sprintf-posix-tests (Files): Likewise.
1975         * modules/stat-tests (Files): Likewise.
1976         * modules/strcasestr-tests (Files): Likewise.
1977         * modules/strchrnul-tests (Files): Likewise.
1978         * modules/strerror-tests (Files): Likewise.
1979         * modules/strsignal-tests (Files): Likewise.
1980         * modules/strstr-tests (Files): Likewise.
1981         * modules/strtod-tests (Files): Likewise.
1982         * modules/strverscmp-tests (Files): Likewise.
1983         * modules/symlink-tests (Files): Likewise.
1984         * modules/symlinkat-tests (Files): Likewise.
1985         * modules/times-tests (Files): Likewise.
1986         * modules/trunc-tests (Files): Likewise.
1987         * modules/truncf-tests (Files): Likewise.
1988         * modules/truncl-tests (Files): Likewise.
1989         * modules/tsearch-tests (Files): Likewise.
1990         * modules/uname-tests (Files): Likewise.
1991         * modules/unlink-tests (Files): Likewise.
1992         * modules/unsetenv-tests (Files): Likewise.
1993         * modules/usleep-tests (Files): Likewise.
1994         * modules/utimensat-tests (Files): Likewise.
1995         * modules/vasprintf-tests (Files): Likewise.
1996         * modules/vdprintf-posix-tests (Files): Likewise.
1997         * modules/vfprintf-posix-tests (Files): Likewise.
1998         * modules/vprintf-posix-tests (Files): Likewise.
1999         * modules/vsnprintf-posix-tests (Files): Likewise.
2000         * modules/vsnprintf-tests (Files): Likewise.
2001         * modules/vsprintf-posix-tests (Files): Likewise.
2002         * modules/wcrtomb-tests (Files): Likewise.
2003         * modules/wcsnrtombs-tests (Files): Likewise.
2004         * modules/wcsrtombs-tests (Files): Likewise.
2005         * modules/wcwidth-tests (Files): Likewise.
2006         * tests/test-isfinite.c (isfinite): Ensure macro declaration.
2007         * tests/test-isinf.c (isinf): Likewise.
2008         * tests/test-isnan.c (isnan): Likewise.
2009         * tests/test-signbit.c (signbit): Likewise.
2010         * tests/test-select.c (FD_CLR, FD_ISSET, FD_SET, FD_ZERO): Ensure
2011         declaration, either as macro or with correct signature.
2012         (select): Ensure function under test is declared with correct
2013         signature in correct header.
2014         * tests/test-atexit.c (atexit): Likewise.
2015         * tests/test-btowc.c (btowc): Likewise.
2016         * tests/test-canonicalize-lgpl.c (realpath)
2017         (canonicalize_file_name): Likewise.
2018         * tests/test-ceilf1.c (ceilf): Likewise.
2019         * tests/test-ceill.c (ceill): Likewise.
2020         * tests/test-chown.c (chown): Likewise.
2021         * tests/test-dprintf-posix.c (dprintf): Likewise.
2022         * tests/test-dup2.c (dup2): Likewise.
2023         * tests/test-dup3.c (dup3): Likewise.
2024         * tests/test-duplocale.c (duplocale): Likewise.
2025         * tests/test-fchdir.c (fchdir): Likewise.
2026         * tests/test-fchownat.c (fchownat): Likewise.
2027         * tests/test-fcntl.c (fcntl): Likewise.
2028         * tests/test-fdopendir.c (fdopendir): Likewise.
2029         * tests/test-fflush.c (fflush): Likewise.
2030         * tests/test-flock.c (flock): Likewise.
2031         * tests/test-floorf1.c (floorf): Likewise.
2032         * tests/test-floorl.c (floorl): Likewise.
2033         * tests/test-fnmatch.c (fnmatch): Likewise.
2034         * tests/test-fopen.c (fopen): Likewise.
2035         * tests/test-fprintf-posix.c (fprintf): Likewise.
2036         * tests/test-freopen.c (freopen): Likewise.
2037         * tests/test-frexp.c (frexp): Likewise.
2038         * tests/test-frexpl.c (frexpl): Likewise.
2039         * tests/test-fseek.c (fseek): Likewise.
2040         * tests/test-fseeko.c (fseeko): Likewise.
2041         * tests/test-fstatat.c (fstatat): Likewise.
2042         * tests/test-fsync.c (fsync): Likewise.
2043         * tests/test-ftell.c (ftell): Likewise.
2044         * tests/test-ftello.c (ftello): Likewise.
2045         * tests/test-futimens.c (futimens): Likewise.
2046         * tests/test-getaddrinfo.c (getaddrinfo, freeaddrinfo)
2047         (gai_strerror): Likewise.
2048         * tests/test-getcwd.c (getcwd): Likewise.
2049         * tests/test-getdelim.c (getdelim): Likewise.
2050         * tests/test-getdtablesize.c (getdtablesize): Likewise.
2051         * tests/test-getgroups.c (getgroups): Likewise.
2052         * tests/test-gethostname.c (gethostname): Likewise.
2053         * tests/test-getline.c (getline): Likewise.
2054         * tests/test-getopt.c (getopt, getopt_long, getopt_long_only):
2055         Likewise.
2056         * tests/test-gettimeofday.c (gettimeofday): Likewise.
2057         * tests/test-glob.c (glob, globfree): Likewise.
2058         * tests/test-iconv.c (iconv, iconv_open, iconv_close): Likewise.
2059         * tests/test-inet_ntop.c (inet_ntop): Likewise.
2060         * tests/test-inet_pton.c (inet_pton): Likewise.
2061         * tests/test-isblank.c (isblank): Likewise.
2062         * tests/test-lchown.c (lchown): Likewise.
2063         * tests/test-ldexpl.c (ldexpl): Likewise.
2064         * tests/test-link.c (link): Likewise.
2065         * tests/test-linkat.c (linkat): Likewise.
2066         * tests/test-lseek.c (lseek): Likewise.
2067         * tests/test-lstat.c (lstat): Likewise.
2068         * tests/test-mbrtowc.c (mbrtowc): Likewise.
2069         * tests/test-mbsinit.c (mbsinit): Likewise.
2070         * tests/test-mbsnrtowcs.c (mbsnrtowcs): Likewise.
2071         * tests/test-mbsrtowcs.c (mbsrtowcs): Likewise.
2072         * tests/test-memchr.c (memchr): Likewise.
2073         * tests/test-memcmp.c (memcmp): Likewise.
2074         * tests/test-memmem.c (memmem): Likewise.
2075         * tests/test-memrchr.c (memrchr): Likewise.
2076         * tests/test-mkdir.c (mkdir): Likewise.
2077         * tests/test-mkdirat.c (mkdirat): Likewise.
2078         * tests/test-mkfifo.c (mkfifo): Likewise.
2079         * tests/test-mkfifoat.c (mkfifoat, mknodat): Likewise.
2080         * tests/test-mknod.c (mknod): Likewise.
2081         * tests/test-nanosleep.c (nanosleep): Likewise.
2082         * tests/test-nl_langinfo.c (nl_langinfo): Likewise.
2083         * tests/test-obstack-printf.c (obstack_printf, obstack_vprintf):
2084         Likewise.
2085         * tests/test-open.c (open): Likewise.
2086         * tests/test-openat.c (openat): Likewise.
2087         * tests/test-perror.c (perror): Likewise.
2088         * tests/test-pipe2.c (pipe2): Likewise.
2089         * tests/test-poll.c (poll): Likewise.
2090         * tests/test-popen.c (popen, pclose): Likewise.
2091         * tests/test-posix_spawn1.c (posix_spawnp, posix_spawnattr_init)
2092         (posix_spawnattr_destroy, posix_spawnattr_setsigmask)
2093         (posix_spawnattr_setflags, posix_spawn_file_actions_init)
2094         (posix_spawn_file_actions_destroy)
2095         (posix_spawn_file_actions_addclose)
2096         (posix_spawn_file_actions_addopen)
2097         (posix_spawn_file_actions_adddup2): Likewise.
2098         * tests/test-posix_spawn3.c (posix_spawn): Likewise.
2099         * tests/test-pread.c (pread): Likewise.
2100         * tests/test-printf-posix.c (printf): Likewise.
2101         * tests/test-pty.c (openpty, forkpty): Likewise.
2102         * tests/test-random_r.c (srandom_r, initstate_r, setstate_r)
2103         (random_r): Likewise.
2104         * tests/test-rawmemchr.c (rawmemchr): Likewise.
2105         * tests/test-readlink.c (readlink): Likewise.
2106         * tests/test-remove.c (remove): Likewise.
2107         * tests/test-rename.c (rename): Likewise.
2108         * tests/test-renameat.c (renameat): Likewise.
2109         * tests/test-rmdir.c (rmdir): Likewise.
2110         * tests/test-round1.c (round): Likewise.
2111         * tests/test-roundf1.c (roundf): Likewise.
2112         * tests/test-roundl.c (roundl): Likewise.
2113         * tests/test-setenv.c (setenv): Likewise.
2114         * tests/test-sigaction.c (sigaction): Likewise.
2115         * tests/test-sleep.c (sleep): Likewise.
2116         * tests/test-snprintf.c (snprintf): Likewise.
2117         * tests/test-sprintf-posix.c (sprintf): Likewise.
2118         * tests/test-stat.c (stat): Likewise.
2119         * tests/test-stpncpy.c (stpncpy): Likewise.
2120         * tests/test-strcasestr.c (strcasestr): Likewise.
2121         * tests/test-strchrnul.c (strchrnul): Likewise.
2122         * tests/test-strerror.c (strerror): Likewise.
2123         * tests/test-strsignal.c (strsignal): Likewise.
2124         * tests/test-strstr.c (strstr): Likewise.
2125         * tests/test-strtod.c (strtod): Likewise.
2126         * tests/test-strverscmp.c (strverscmp): Likewise.
2127         * tests/test-symlink.c (symlink): Likewise.
2128         * tests/test-symlinkat.c (symlinkat, readlinkat): Likewise.
2129         * tests/test-times.c (times): Likewise.
2130         * tests/test-trunc1.c (trunc): Likewise.
2131         * tests/test-truncf1.c (truncf): Likewise.
2132         * tests/test-truncl.c (truncl): Likewise.
2133         * tests/test-tsearch.c (tdelete, tfind, tsearch, twalk):
2134         Likewise.
2135         * tests/test-uname.c (uname): Likewise.
2136         * tests/test-unlink.c (unlink): Likewise.
2137         * tests/test-unlinkat.c (unlinkat): Likewise.
2138         * tests/test-unsetenv.c (unsetenv): Likewise.
2139         * tests/test-usleep.c (usleep): Likewise.
2140         * tests/test-utimensat.c (utimensat): Likewise.
2141         * tests/test-vasprintf.c (asprintf, vasprintf): Likewise.
2142         * tests/test-vdprintf-posix.c (vdprintf): Likewise.
2143         * tests/test-vfprintf-posix.c (vfprintf): Likewise.
2144         * tests/test-vprintf-posix.c (vprintf): Likewise.
2145         * tests/test-vsnprintf.c (vsnprintf): Likewise.
2146         * tests/test-vsprintf-posix.c (vsprintf): Likewise.
2147         * tests/test-wcrtomb.c (wcrtomb): Likewise.
2148         * tests/test-wcsnrtombs.c (wcsnrtombs): Likewise.
2149         * tests/test-wcsrtombs.c (wcsrtombs): Likewise.
2150         * tests/test-wcwidth.c (wcwidth): Likewise.
2151
2152         build: pull in conditional headers during GNULIB_POSIXCHECK
2153         * lib/stdio.in.h (includes): Using GNULIB_POSIXCHECK also requires
2154         definitions from any conditionally-included headers.
2155         * lib/stdlib.in.h (includes): Likewise.
2156         * lib/unistd.in.h (includes): Likewise.
2157
2158 2009-12-24  Bruno Haible  <bruno@clisp.org>
2159
2160         * tests/test-argv-iter.c: Include header file being tested immediately
2161         after config.h.
2162         * tests/test-base64.c: Likewise.
2163         * tests/test-flock.c: Likewise.
2164         * tests/test-fsync.c: Likewise.
2165         * tests/test-getdate.c: Likewise.
2166         * tests/test-getndelim2.c: Likewise.
2167         * tests/test-isfinite.c: Likewise.
2168         * tests/test-isinf.c: Likewise.
2169         * tests/test-strerror.c: Likewise.
2170         * tests/test-strsignal.c: Likewise.
2171
2172 2009-12-23  Eric Blake  <ebb9@byu.net>
2173
2174         unistd: work around cygwin bug
2175         * lib/unistd.in.h (includes): Pick up headers needed for cygwin.
2176         * doc/posix-functions/unlinkat.texi (unlinkat): Document the bug.
2177         * doc/posix-functions/symlinkat.texi (symlinkat): Likewise.
2178
2179 2009-12-23  Bruno Haible  <bruno@clisp.org>
2180
2181         localename: More tests.
2182         * tests/test-localename.c (SIZEOF): New macro.
2183         (categories): New variable.
2184         (test_locale_name, test_locale_name_posix, test_locale_name_environ,
2185         test_locale_name_default): Add test w.r.t. thread locale.
2186         (test_locale_name_thread): New function.
2187         (main): Invoke it.
2188
2189         localename: Make aware of thread locale.
2190         * lib/localename.h (gl_locale_name_thread): New declaration.
2191         (gl_locale_name, gl_locale_name_posix, gl_locale_name_default): Clarify
2192         behaviour with respect to thread locale.
2193         * lib/localename.c: Include <limits.h>, <stddef.h>, <xlocale.h>,
2194         <langinfo.h>, glthread/lock.h.
2195         (SIZE_BITS): New macro.
2196         (string_hash): New function.
2197         (struct hash_node): New type.
2198         (HASH_TABLE_SIZE): New macro.
2199         (struniq_hash_table, struniq_lock): New variables.
2200         (struniq): New function.
2201         (gl_locale_name_thread): New function.
2202         (gl_locale_name): Invoke it.
2203         * m4/localename.m4 (gl_LOCALENAME): Test for uselocale function.
2204         * modules/localename (Depends-on): Add lock.
2205         Reported by Mike Gran <spk121@yahoo.com>.
2206
2207 2009-12-23  Eric Blake  <ebb9@byu.net>
2208
2209         va-args: new module
2210         * modules/va-args: New file.
2211         * m4/va-args.m4 (gl_VA_ARGS): Likewise.
2212         * MODULES.html.sh (Core language properties): Mention it.
2213
2214         gnulib-common: prefer _GL_UNUSED over _UNUSED_PARAMETER_
2215         * m4/gnulib-common.m4 (gl_COMMON): Create a more-appropriately
2216         named alias for __attribute__((__unused__)).
2217         * lib/chown.c: Update client.
2218         * lib/fchmodat.c: Likewise.
2219         * lib/fts.c: Likewise.
2220         * lib/getdate.y: Likewise.
2221         * lib/getgroups.c: Likewise.
2222         * lib/getopt.c: Likewise.
2223         * lib/getugroups.c: Likewise.
2224         * lib/mkdir.c: Likewise.
2225         * lib/mkfifo.c: Likewise.
2226         * lib/mkfifoat.c: Likewise.
2227         * lib/mknod.c: Likewise.
2228         * lib/mknodat.c: Likewise.
2229         * lib/readlink.c: Likewise.
2230         * lib/se-context.in.h: Likewise.
2231         * lib/se-selinux.in.h: Likewise.
2232         * lib/sockets.c: Likewise.
2233         * lib/symlink.c: Likewise.
2234         * lib/symlinkat.c: Likewise.
2235         * lib/unicodeio.c: Likewise.
2236         * lib/unistr.h: Likewise.
2237         * tests/test-areadlink.c: Likewise.
2238         * tests/test-areadlinkat.c: Likewise.
2239         * tests/test-filenamecat.c: Likewise.
2240         * tests/test-fseeko.c: Likewise.
2241         * tests/test-ftello.c: Likewise.
2242         * tests/test-getdate.c: Likewise.
2243         * tests/test-getgroups.c: Likewise.
2244         * tests/test-gethostname.c: Likewise.
2245         * tests/test-quotearg.c: Likewise.
2246         * tests/test-version-etc.c: Likewise.
2247         * tests/test-xalloc-die.c: Likewise.
2248         * tests/test-xfprintf-posix.c: Likewise.
2249         * tests/test-xprintf-posix.c: Likewise.
2250         * tests/test-xvasprintf.c: Likewise.
2251
2252         tests: avoid compiler warnings
2253         * tests/test-fcntl.c (main): Delete unused parameters.
2254         * tests/test-freopen-safer.c (main): Likewise.
2255         * tests/test-xalloc-die.c (main): Mark unused parameters.
2256         * tests/test-fseeko.c (main): Likewise.
2257         * tests/test-ftello.c (main): Likewise.
2258         * tests/test-nanosleep.c (main): Avoid declaration warning.
2259         * tests/test-sleep.c (main): Likewise.
2260         * tests/test-unsetenv.c (main): Silence warning about string
2261         literal.
2262         * m4/setenv.m4 (gl_FUNC_UNSETENV): Likewise.
2263
2264 2009-12-23  Bruno Haible  <bruno@clisp.org>
2265
2266         * tests/test-localename.c (test_locale_name): New function, extracted
2267         from main. Also test mixed situations.
2268         (test_locale_name_posix, test_locale_name_environ,
2269         test_locale_name_default): New functions.
2270         (main): Invoke them all.
2271         * modules/localename-tests (configure.ac): Test for newlocale.
2272
2273 2009-12-23  Bruno Haible  <bruno@clisp.org>
2274
2275         unistd: Ensure getcwd gets declared before being overridden.
2276         * lib/unistd.in.h: Conditionally include <io.h>.
2277
2278 2009-12-22  Bruno Haible  <bruno@clisp.org>
2279
2280         wchar: Diagnose broken combination of glibc and gcc versions and flags.
2281         * m4/wchar.m4 (gl_WCHAR_H_INLINE_OK): New macro.
2282         (gl_WCHAR_H): Invoke it.
2283         * m4/btowc.m4 (gl_FUNC_BTOWC): Require it.
2284         * doc/posix-headers/wchar.texi: Mention the interoperability problem.
2285         Reported by Karl Berry <karl@freefriends.org>.
2286
2287 2009-12-22  Eric Blake  <ebb9@byu.net>
2288
2289         math, unistd: avoid redundant includes
2290         * lib/math.in.h (isnan): No need to re-include <math.h>.
2291         * lib/unistd.in.h (getcwd): Likewise, for <stdlib.h>.
2292
2293         getsubopt: work around cygwin bug
2294         * lib/stdlib.in.h (includes): Move unistd inclusion sooner, to
2295         avoid conflicting with system getsubopt.
2296         * doc/posix-functions/getsubopt.texi (getsubopt): Document the
2297         bug.
2298
2299         getopt: synchronize from glibc
2300         * lib/getopt.c (_getopt_initialize, _getopt_internal_r): Swap
2301         parameter order.  Adjust all callers.
2302         (_getopt_internal_r, main): Adjust quoting in error messages.
2303         Drop considerations for outdated POSIX 1003.2 error message.
2304         * lib/getopt1.c (_getopt_long_r, _getopt_long_only_r): Adjust
2305         callers.
2306         * lib/getopt_int.h (_getopt_internal_r): Adjust prototype.
2307
2308         test-getopt: test stderr behavior
2309         * modules/getopt-posix-tests (Depends-on): Add dup2.
2310         * tests/test-getopt.c (ASSERT): Avoid stderr.
2311         (main): Move stderr to a temporary file.
2312         * tests/test-getopt.h (getopt_loop): No longer manipulate opterr.
2313         Instead, add parameter to inform caller if output occurred.
2314         (test_getopt): Adjust all existing tests to expect silence, and
2315         add new tests of leading ":".
2316         * doc/glibc-functions/getopt_long.texi (getopt_long): Document
2317         glibc shortcomings with leading "-:" or "+:" in optstring.
2318         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
2319         Likewise.
2320         * doc/posix-functions/getopt.texi (getopt): Likewise.
2321
2322         test-getopt: enhance test
2323         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Require that getopt_long
2324         supports optind=0.
2325         * tests/test-getopt.c (OPTIND_MIN): Move...
2326         * tests/test-getopt.h (OPTIND_MIN): ...here.
2327         * tests/test-getopt_long.h (test_getopt_long): Add more coverage.
2328         Require that optind=0 works, since modern BSD supports it in
2329         addition to optreset, and since coreutils expects it.
2330         (test_getopt_long_only): New test.
2331         * doc/glibc-functions/getopt_long.texi (getopt_long): Document
2332         glibc shortcomings with 'W;', and enforcement of optind=0.
2333         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
2334         Likewise.
2335
2336 2009-12-21  Bruno Haible  <bruno@clisp.org>
2337
2338         localename: Improvements for MacOS X and Cygwin.
2339         * lib/localename.h (gl_locale_name_environ): New declaration.
2340         * lib/localename.c (gl_locale_name_environ): New function, extracted from
2341         gl_locale_name_posix. Ignore dummy LANG values on MacOS X and Cygwin.
2342         (gl_locale_name_posix): Invoke it.
2343         (gl_locale_name_default): Add comments. Use Windows native API also on
2344         Cygwin.
2345
2346 2009-12-21  Bruno Haible  <bruno@clisp.org>
2347
2348         Update list of Win32 locale ids.
2349         * lib/localename.c (LANG_ROMANSH): Renamed from LANG_RHAETO_ROMANCE.
2350         (LANG_SAMI): Renamed from LANG_SAAMI.
2351         (LANG_BASHKIR, LANG_LUXEMBOURGISH, LANG_GREENLANDIC,
2352         LANG_MAPUDUNGUN, LANG_MOHAWK, LANG_BRETON, LANG_OCCITAN, LANG_CORSICAN,
2353         LANG_ALSATIAN, LANG_YAKUT, LANG_KICHE, LANG_KINYARWANDA, LANG_WOLOF,
2354         LANG_DARI, LANG_SCOTTISH_GAELIC): New macros.
2355         (SUBLANG_AFRIKAANS_SOUTH_AFRICA, SUBLANG_ALBANIAN_ALBANIA,
2356         SUBLANG_ALSATIAN_FRANCE, SUBLANG_AMHARIC_ETHIOPIA,
2357         SUBLANG_ARMENIAN_ARMENIA, SUBLANG_ASSAMESE_INDIA,
2358         SUBLANG_BASHKIR_RUSSIA, SUBLANG_BASQUE_BASQUE,
2359         SUBLANG_BELARUSIAN_BELARUS, SUBLANG_BRETON_FRANCE,
2360         SUBLANG_BULGARIAN_BULGARIA, SUBLANG_CAMBODIAN_CAMBODIA,
2361         SUBLANG_CATALAN_SPAIN, SUBLANG_CORSICAN_FRANCE,
2362         SUBLANG_CZECH_CZECH_REPUBLIC, SUBLANG_DANISH_DENMARK,
2363         SUBLANG_DARI_AFGHANISTAN, SUBLANG_DIVEHI_MALDIVES,
2364         SUBLANG_DUTCH_SURINAM, SUBLANG_ESTONIAN_ESTONIA,
2365         SUBLANG_FAEROESE_FAROE_ISLANDS, SUBLANG_FARSI_IRAN,
2366         SUBLANG_FINNISH_FINLAND, SUBLANG_FRISIAN_NETHERLANDS,
2367         SUBLANG_GALICIAN_SPAIN, SUBLANG_GEORGIAN_GEORGIA,
2368         SUBLANG_GREEK_GREECE, SUBLANG_GREENLANDIC_GREENLAND,
2369         SUBLANG_GUJARATI_INDIA, SUBLANG_HAUSA_NIGERIA_LATIN,
2370         SUBLANG_HEBREW_ISRAEL, SUBLANG_HINDI_INDIA, SUBLANG_HUNGARIAN_HUNGARY,
2371         SUBLANG_ICELANDIC_ICELAND, SUBLANG_IGBO_NIGERIA,
2372         SUBLANG_INDONESIAN_INDONESIA, SUBLANG_INUKTITUT_CANADA,
2373         SUBLANG_INUKTITUT_CANADA_LATIN, SUBLANG_IRISH_IRELAND,
2374         SUBLANG_JAPANESE_JAPAN, SUBLANG_KANNADA_INDIA,
2375         SUBLANG_KAZAK_KAZAKHSTAN, SUBLANG_KICHE_GUATEMALA,
2376         SUBLANG_KINYARWANDA_RWANDA, SUBLANG_KONKANI_INDIA,
2377         SUBLANG_KYRGYZ_KYRGYZSTAN, SUBLANG_LAO_LAOS, SUBLANG_LATVIAN_LATVIA,
2378         SUBLANG_LITHUANIAN_LITHUANIA, SUBLANG_LOWER_SORBIAN_GERMANY,
2379         SUBLANG_LUXEMBOURGISH_LUXEMBOURG, SUBLANG_MACEDONIAN_MACEDONIA,
2380         SUBLANG_MALAYALAM_INDIA, SUBLANG_MALTESE_MALTA,
2381         SUBLANG_MAORI_NEW_ZEALAND, SUBLANG_MAPUDUNGUN_CHILE,
2382         SUBLANG_MARATHI_INDIA, SUBLANG_MOHAWK_CANADA, SUBLANG_NEPALI_NEPAL,
2383         SUBLANG_OCCITAN_FRANCE, SUBLANG_ORIYA_INDIA,
2384         SUBLANG_PASHTO_AFGHANISTAN, SUBLANG_POLISH_POLAND,
2385         SUBLANG_ROMANSH_SWITZERLAND, SUBLANG_SAMI_NORTHERN_NORWAY,
2386         SUBLANG_SAMI_NORTHERN_SWEDEN, SUBLANG_SAMI_NORTHERN_FINLAND,
2387         SUBLANG_SAMI_LULE_NORWAY, SUBLANG_SAMI_LULE_SWEDEN,
2388         SUBLANG_SAMI_SOUTHERN_NORWAY, SUBLANG_SAMI_SOUTHERN_SWEDEN,
2389         SUBLANG_SAMI_SKOLT_FINLAND, SUBLANG_SAMI_INARI_FINLAND,
2390         SUBLANG_SANSKRIT_INDIA, SUBLANG_SINHALESE_SRI_LANKA,
2391         SUBLANG_SLOVAK_SLOVAKIA, SUBLANG_SLOVENIAN_SLOVENIA,
2392         SUBLANG_SOTHO_SOUTH_AFRICA, SUBLANG_SWAHILI_KENYA,
2393         SUBLANG_SWEDISH_SWEDEN, SUBLANG_SYRIAC_SYRIA,
2394         SUBLANG_TAGALOG_PHILIPPINES, SUBLANG_TAJIK_TAJIKISTAN,
2395         SUBLANG_TAMIL_INDIA, SUBLANG_TATAR_RUSSIA, SUBLANG_TELUGU_INDIA,
2396         SUBLANG_THAI_THAILAND, SUBLANG_TSWANA_SOUTH_AFRICA,
2397         SUBLANG_TURKISH_TURKEY, SUBLANG_TURKMEN_TURKMENISTAN,
2398         SUBLANG_UKRAINIAN_UKRAINE, SUBLANG_UPPER_SORBIAN_GERMANY,
2399         SUBLANG_VIETNAMESE_VIETNAM, SUBLANG_WELSH_UNITED_KINGDOM,
2400         SUBLANG_WOLOF_SENEGAL, SUBLANG_XHOSA_SOUTH_AFRICA,
2401         SUBLANG_YAKUT_RUSSIA, SUBLANG_YI_PRC, SUBLANG_YORUBA_NIGERIA,
2402         SUBLANG_ZULU_SOUTH_AFRICA): New macros.
2403         (gl_locale_name_from_win32_LANGID): Handle also the territory neutral
2404         locale ids. Add support for Alsatian, Bashkir, Breton, Corsican, Dari,
2405         Greenlandic, K'iche', Kinyarwanda, Luxembourgish, Mapudungun, Mohawk,
2406         Occitan, Scottish Gaelic, Wolof, Yakut. Change language code for Yi.
2407         Add more languages and countries for Sami, Sorbian. Add more countries
2408         for Serbian, Dutch. Add more scripts for Inuktitut. Be more precise
2409         for Pashto. Change country for Syriac, Tswana.
2410
2411 2009-12-21  Eric Blake  <ebb9@byu.net>
2412
2413         test-utimens: avoid spurious failure
2414         * tests/test-chown.h (nap): Factor...
2415         * tests/nap.h: ...into new file.
2416         * tests/test-lchown.h (nap): Avoid duplication.
2417         * tests/test-utimens-common.h (nap): Use shared implementation,
2418         necessary on file systems with 1-second resolution.
2419         * modules/chown-tests (Files): Include new file.
2420         * modules/fdutimensat-tests (Files): Likewise.
2421         * modules/futimens-tests (Files): Likewise.
2422         * modules/lchown-tests (Files): Likewise.
2423         * modules/openat-tests (Files): Likewise.
2424         * modules/utimens-tests (Files): Likewise.
2425         * modules/utimensat-tests (Files): Likewise.
2426
2427 2009-12-19  Eric Blake  <ebb9@byu.net>
2428
2429         futimens, utimensat: work around Linux bug
2430         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Detect ctime bug.
2431         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
2432         * lib/utimensat.c (rpl_utimensat): Work around it.
2433         * lib/futimens.c (rpl_futimens): Adjust comment.
2434
2435         utimens: work around Linux ctime bug
2436         * lib/utimens.c (detect_ctime_bug): New helper function.
2437         (update_timespec): Differentiate between workaround needed for
2438         this bug vs. what is needed for systems that lack utimensat.
2439         (fdutimens, lutimens): Work around bug.
2440
2441         utimens: check for ctime update
2442         * tests/test-utimens-common.h (check_ctime): Define.
2443         * tests/test-utimens.h (test_utimens): Expose the Linux bug.
2444         * tests/test-futimens.h (test_futimens): Likewise.
2445         * tests/test-lutimens.h (test_lutimens): Likewise.
2446         * doc/posix-functions/futimens.texi (futimens): Document the bug.
2447         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
2448
2449 2009-12-19  Bruno Haible  <bruno@clisp.org>
2450
2451         dprintf-posix: Check against memory leak fixed on 2009-12-15.
2452         * tests/test-dprintf-posix2.sh: New file.
2453         * tests/test-dprintf-posix2.c: New file.
2454         * modules/dprintf-posix-tests (Files): Add them.
2455         (configure.ac): Check for getrlimit and setrlimit.
2456         (Makefile.am): Augment TESTS and CHECK_PROGRAMS.
2457
2458 2009-12-19  Bruno Haible  <bruno@clisp.org>
2459
2460         fprintf-posix: Check against memory leak fixed on 2009-12-15.
2461         * tests/test-fprintf-posix3.sh: New file.
2462         * tests/test-fprintf-posix3.c: New file.
2463         * modules/fprintf-posix-tests (Files): Add them.
2464         (Makefile.am): Augment TESTS and CHECK_PROGRAMS.
2465
2466 2009-12-19  Eric Blake  <ebb9@byu.net>
2467
2468         dirfd: fix prototype
2469         * lib/dirent.in.h (dirfd): Argument is not const, per POSIX.
2470         * lib/dirfd.c (dirfd): Likewise.
2471
2472         canonicalize: reduce memory usage
2473         * lib/canonicalize.c (canonicalize_filename_mode): Trim the
2474         allocation to size.
2475         Reported by Solar Designer <solar@openwall.com>.
2476
2477 2009-12-19  Bruno Haible  <bruno@clisp.org>
2478
2479         New module attribute 'Applicability'.
2480         * modules/TEMPLATE-EXTENDED: New field 'Applicability'.
2481         * gnulib-tool: New option --extract-applicability.
2482         (func_usage): Document it.
2483         (sed_extract_prog): Recognize it.
2484         (func_get_applicability): New function.
2485         (func_import): Generalize handling of 'link-warning' module.
2486         * modules/link-warning (Applicability): New section.
2487         * modules/arg-nonnull (Applicability): New section.
2488         Repoted by Simon Josefsson <simon@josefsson.org>.
2489
2490 2009-12-19  Bruno Haible  <bruno@clisp.org>
2491
2492         fflush: tweak
2493         * lib/fflush.c (update_fpos_cache): Don't use fpos_t on Cygwin.
2494         * lib/fseeko.c (rpl_fseeko): Likewise.
2495
2496 2009-12-16  José E. Marchesi  <jemarch@gnu.org>  (tiny change)
2497
2498         * lib/gl_list.h: Fix typo in comment.
2499
2500 2009-12-16  Eric Blake  <ebb9@byu.net>
2501
2502         fcntl: use to simplify other modules
2503         * modules/cloexec (Depends-on): Add fcntl.
2504         * modules/fchdir (Depends-on): Likewise.
2505         * modules/fd-safer-flag (Depends-on): Likewise.
2506         * modules/unistd-safer (Depends-on): Likewise.
2507         * modules/dup3 (configure.ac): Set module indicator.
2508         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Replace fcntl if fchdir is
2509         missing.
2510         * lib/fchdir.c (_gl_register_dup): Fix comment.
2511         * lib/cloexec.c (dup_cloexec): Simplify, by relying on fcntl.
2512         * lib/dup-safer.c (dup_safer): Likewise.
2513         * lib/dup-safer-flag.c (dup_safer_flag): Likewise.
2514         * lib/dup3.c (dup3): Likewise.
2515         * tests/test-fchdir.c (main): Enhance test.
2516         Fixes a dup_cloexec bug reported by OndÅ™ej Vašík.
2517
2518         fcntl: port portions of fcntl to mingw
2519         * m4/fcntl.m4 (gl_FUNC_FCNTL): Also build fcntl.c on mingw.
2520         * lib/fcntl.c (fcntl) <F_DUPFD, F_DUPFD_CLOEXEC, F_GETFD>: Provide
2521         replacement for mingw.
2522         * modules/fcntl (Description): Update.
2523         (Depends-on): Add dup2.
2524         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Add witness.
2525         * modules/fcntl-h (Makefile.am): Substitute it.
2526         * lib/fcntl.in.h (fcntl): Update declaration.
2527         (F_DUPFD, F_GETFD): New macros, when needed.
2528         * doc/posix-headers/fcntl.texi (fcntl.h): Update documentation.
2529         * doc/posix-functions/fcntl.texi (fcntl): Likewise.
2530         * tests/test-fcntl.c (check_flags, main): Enhance test for items
2531         we now guarantee.
2532
2533         fcntl: work around cygwin bug in F_DUPFD
2534         * m4/fcntl.m4 (gl_REPLACE_FCNTL): New macro.
2535         (gl_FUNC_FCNTL): Use it.  Test for F_DUPFD bug.
2536         * lib/fcntl.c (rpl_fcntl) <F_DUPFD>: Work around it.
2537         <F_DUPFD_CLOEXEC>: Reduce calls to _gl_register_dup.
2538         * doc/posix-functions/fcntl.texi (fcntl): Document it.
2539
2540         fcntl: support F_DUPFD_CLOEXEC on systems with fcntl
2541         * modules/fcntl (Files): List new files.
2542         (configure.ac): Run a test.
2543         * m4/fcntl.m4 (gl_FUNC_FCNTL): New file.
2544         * lib/fcntl.c (rpl_fcntl): Likewise.
2545         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Add witness defaults.
2546         (gl_FCNTL_H): Always replace fcntl.h.
2547         * modules/fcntl-h (Makefile.am): Substitute witnesses.
2548         * lib/fcntl.in.h (fcntl): Declare replacement.
2549         (F_DUPFD_CLOEXEC, GNULIB_defined_F_DUPFD_CLOEXEC): New macro when
2550         needed, plus a witness.
2551         * doc/posix-functions/fcntl.texi (fcntl): Document this.
2552         * doc/posix-headers/fcntl.texi (fcntl.h): Likewise.
2553         * tests/test-fcntl.c: New file.
2554         * modules/fcntl-tests: Likewise.
2555
2556         binary-io: avoid potential compilation warning
2557         * lib/binary-io.h [__DJGPP__]: Avoid null preprocessor
2558         directives.
2559
2560         fflush: avoid compilation error on NetBSD
2561         * lib/fflush.c (update_fpos_cache): Use a union to safely convert
2562         between off_t and fpos_t, since the latter is sometimes a struct.
2563         * lib/fseeko.c (rpl_fseeko): Likewise.
2564         Reported by Alexander Nasonov <alnsn@yandex.ru>.
2565
2566 2009-12-15  Eric Blake  <ebb9@byu.net>
2567
2568         fcntl-h, stdio, sys_ioctl: fix declarations
2569         * lib/stdio.in.h (dprintf): Use of link warning on a variadic
2570         function must not take arguments.
2571         * lib/sys_ioctl.in.h (ioctl): Likewise.
2572         * lib/fcntl.in.h (openat): Likewise.  Declare extern.
2573         (open): Add a link warning.
2574
2575 2009-12-15  Jim Meyering  <meyering@redhat.com>
2576
2577         areadlink, areadlink-with-size: relax license to LGPLv2+
2578         * modules/areadlink (License): Relax to LGPLv2+.
2579         * modules/areadlink-with-size (License): Likewise.
2580
2581 2009-12-15  Joel E. Denny  <jdenny@clemson.edu>
2582             Bruno Haible  <bruno@clisp.org>
2583
2584         *printf: Fix memory leak.
2585         * lib/fprintf.c (fprintf): Free memory allocated by vasnprintf.
2586         * lib/vfprintf.c (vfprintf): Likewise.
2587         * lib/dprintf.c (dprintf): Likewise.
2588         * lib/vdprintf.c (vdprintf): Likewise.
2589
2590 2009-12-14  Eric Blake  <ebb9@byu.net>
2591
2592         accept4: adjust module dependencies
2593         * modules/accept4 (Depends-on): Use fcntl-h, not fcntl.
2594
2595         utimens: one more try at avoiding compiler warning
2596         * lib/utimens.c (lutimens): Lower scope of result.
2597
2598 2009-12-13  Bruno Haible  <bruno@clisp.org>
2599
2600         Move the malloc checking from module 'list' to new module 'xlist'.
2601         * modules/xlist: New file.
2602         * lib/gl_xlist.h: New file.
2603         * lib/gl_xlist.c: New file.
2604         * lib/gl_list.h (gl_list_create_empty, gl_list_create,
2605         gl_list_node_set_value, gl_list_set_at, gl_list_add_first,
2606         gl_list_add_last, gl_list_add_before, gl_list_add_after,
2607         gl_list_nx_add_at, gl_sortedlist_add): Disable declarations.
2608         (gl_list_nx_create_empty, gl_list_nx_create, gl_list_node_nx_set_value,
2609         gl_list_nx_set_at, gl_list_nx_add_first, gl_list_nx_add_last,
2610         gl_list_nx_add_before, gl_list_nx_add_after, gl_list_nx_add_at,
2611         gl_sortedlist_nx_add): New declarations.
2612         (struct gl_list_implementation): Rename and change methods accordingly.
2613         (gl_list_nx_create_empty): Renamed from gl_list_create_empty.
2614         (gl_list_nx_create): Renamed from gl_list_create.
2615         (gl_list_node_nx_set_value): Renamed from gl_list_node_set_value.
2616         (gl_list_nx_set_at): Renamed from gl_list_set_at.
2617         (gl_list_nx_add_first): Renamed from gl_list_add_first.
2618         (gl_list_nx_add_last): Renamed from gl_list_add_last.
2619         (gl_list_nx_add_before): Renamed from gl_list_add_before.
2620         (gl_list_nx_add_after): Renamed from gl_list_add_after.
2621         (gl_list_nx_add_at): Renamed from gl_list_add_at.
2622         (gl_sortedlist_nx_add): Renamed from gl_sortedlist_add.
2623         * lib/gl_list.c (gl_list_nx_create_empty): Renamed from
2624         gl_list_create_empty.
2625         (gl_list_nx_create): Renamed from gl_list_create.
2626         (gl_list_node_nx_set_value): Renamed from gl_list_node_set_value.
2627         (gl_list_nx_set_at): Renamed from gl_list_set_at.
2628         (gl_list_nx_add_first): Renamed from gl_list_add_first.
2629         (gl_list_nx_add_last): Renamed from gl_list_add_last.
2630         (gl_list_nx_add_before): Renamed from gl_list_add_before.
2631         (gl_list_nx_add_after): Renamed from gl_list_add_after.
2632         (gl_list_nx_add_at): Renamed from gl_list_add_at.
2633         (gl_sortedlist_nx_add): Renamed from gl_sortedlist_add.
2634         * lib/gl_array_list.c: Don't include xalloc.h.
2635         (gl_array_nx_create_empty): Renamed from gl_array_create_empty. Return
2636         NULL upon out-of-memory.
2637         (gl_array_nx_create): Renamed from gl_array_create. Return NULL upon
2638         out-of-memory.
2639         (gl_array_node_nx_set_value): Renamed from gl_array_node_set_value.
2640         Change return type to 'int'.
2641         (gl_array_nx_set_at): Renamed from gl_array_set_at.
2642         (grow): Change return type to 'int'. Return -1 upon out-of-memory.
2643         (gl_array_nx_add_first): Renamed from gl_array_add_first. Return NULL
2644         upon out-of-memory.
2645         (gl_array_nx_add_last): Renamed from gl_array_add_last. Return NULL
2646         upon out-of-memory.
2647         (gl_array_nx_add_before): Renamed from gl_array_add_before. Return NULL
2648         upon out-of-memory.
2649         (gl_array_nx_add_after): Renamed from gl_array_add_after. Return NULL
2650         upon out-of-memory.
2651         (gl_array_nx_add_at): Renamed from gl_array_add_at. Return NULL upon
2652         out-of-memory.
2653         (gl_array_sortedlist_nx_add): Renamed from gl_array_sortedlist_add.
2654         Update.
2655         (gl_array_list_implementation): Update.
2656         * lib/gl_carray_list.c: Don't include xalloc.h.
2657         (gl_carray_nx_create_empty): Renamed from gl_carray_create_empty.
2658         Return NULL upon out-of-memory.
2659         (gl_carray_nx_create): Renamed from gl_carray_create. Return NULL upon
2660         out-of-memory.
2661         (gl_carray_node_nx_set_value): Renamed from gl_carray_node_set_value.
2662         Change return type to 'int'.
2663         (gl_carray_nx_set_at): Renamed from gl_carray_set_at.
2664         (grow): Change return type to 'int'. Return -1 upon out-of-memory.
2665         (gl_carray_nx_add_first): Renamed from gl_carray_add_first. Return NULL
2666         upon out-of-memory.
2667         (gl_carray_nx_add_last): Renamed from gl_carray_add_last. Return NULL
2668         upon out-of-memory.
2669         (gl_carray_nx_add_at): Renamed from gl_carray_add_at. Return NULL upon
2670         out-of-memory.
2671         (gl_carray_nx_add_before): Renamed from gl_carray_add_before. Update.
2672         (gl_carray_nx_add_after): Renamed from gl_carray_add_after. Update.
2673         (gl_carray_sortedlist_nx_add): Renamed from gl_carray_sortedlist_add.
2674         Update.
2675         (gl_carray_list_implementation): Update.
2676         * lib/gl_anyhash_list2.h (hash_resize): Do nothing upon out-of-memory.
2677         * lib/gl_anylinked_list2.h (gl_linked_nx_create_empty): Renamed from
2678         gl_linked_create_empty. Return NULL upon out-of-memory.
2679         (gl_linked_nx_create): Renamed from gl_linked_create. Return NULL upon
2680         out-of-memory.
2681         (gl_linked_node_nx_set_value): Renamed from gl_linked_node_set_value.
2682         Change return type to 'int'. Return -1 upon out-of-memory.
2683         (gl_linked_nx_set_at): Renamed from gl_linked_set_at. Return NULL upon
2684         out-of-memory.
2685         (gl_linked_nx_add_first): Renamed from gl_linked_add_first. Return NULL
2686         upon out-of-memory.
2687         (gl_linked_nx_add_last): Renamed from gl_linked_add_last. Return NULL
2688         upon out-of-memory.
2689         (gl_linked_nx_add_before): Renamed from gl_linked_add_before. Return
2690         NULL upon out-of-memory.
2691         (gl_linked_nx_add_after): Renamed from gl_linked_add_after. Return NULL
2692         upon out-of-memory.
2693         (gl_linked_nx_add_at): Renamed from gl_linked_add_at. Return NULL upon
2694         out-of-memory.
2695         (gl_linked_sortedlist_nx_add): Renamed from gl_linked_sortedlist_add.
2696         Update.
2697         * lib/gl_linked_list.c: Don't include xalloc.h.
2698         (gl_linked_list_implementation): Update.
2699         * lib/gl_linkedhash_list.c: Don't include xalloc.h.
2700         (add_to_bucket): Change return type to 'int'.
2701         (gl_linkedhash_list_implementation): Update.
2702         * lib/gl_anytree_list1.h (free_subtree): New function.
2703         * lib/gl_anytree_list2.h (gl_tree_nx_create_empty): Renamed from
2704         gl_tree_create_empty. Return NULL upon out-of-memory.
2705         (gl_tree_node_nx_set_value): Renamed from gl_tree_node_set_value.
2706         Change return type to 'int'. Return -1 upon out-of-memory.
2707         (gl_tree_nx_set_at): Renamed from gl_tree_set_at. Return NULL upon
2708         out-of-memory.
2709         (gl_tree_nx_add_at): Renamed from gl_tree_add_at. Update.
2710         (gl_tree_remove_node): New function, moved here from
2711         lib/gl_anyavltree_list2.h and lib/gl_anyrbtree_list2.h.
2712         (gl_tree_sortedlist_nx_add): Renamed from gl_tree_sortedlist_add.
2713         Update.
2714         * lib/gl_anyavltree_list2.h (create_subtree_with_contents): Use
2715         malloc, not xmalloc. Return NULL upon out-of-memory.
2716         (gl_tree_nx_create): Renamed from gl_tree_create. Return NULL upon
2717         out-of-memory.
2718         (gl_tree_remove_node_from_tree): New function, extracted from
2719         gl_tree_remove_node.
2720         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Return NULL
2721         upon out-of-memory.
2722         (gl_tree_nx_add_last): Renamed from gl_tree_add_last. Return NULL upon
2723         out-of-memory.
2724         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Return NULL
2725         upon out-of-memory.
2726         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Return NULL
2727         upon out-of-memory.
2728         (gl_tree_remove_node): Remove function. Moved to gl_anytree_list2.h.
2729         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents): Use malloc,
2730         not xmalloc. Return NULL upon out-of-memory.
2731         (gl_tree_nx_create): Renamed from gl_tree_create. Return NULL upon
2732         out-of-memory.
2733         (gl_tree_remove_node_from_tree): New function, extracted from
2734         gl_tree_remove_node.
2735         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Return NULL
2736         upon out-of-memory.
2737         (gl_tree_nx_add_last): Renamed from gl_tree_add_last. Return NULL upon
2738         out-of-memory.
2739         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Return NULL
2740         upon out-of-memory.
2741         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Return NULL
2742         upon out-of-memory.
2743         (gl_tree_remove_node): Remove function. Moved to gl_anytree_list2.h.
2744         * lib/gl_avltree_list.c: Don't include xalloc.h. Include
2745         gl_anytree_list1.h before gl_anyavltree_list2.h.
2746         (gl_avltree_list_implementation): Update.
2747         * lib/gl_rbtree_list.c: Don't include xalloc.h. Include
2748         gl_anytree_list1.h before gl_anyavltree_list2.h.
2749         (gl_rbtree_list_implementation): Update.
2750         * lib/gl_anytreehash_list1.h (add_to_bucket, add_nodes_to_buckets):
2751         Change return type to 'int'. Return -1 upon out-of-memory. Use
2752         __builtin_expect.
2753         * lib/gl_avltreehash_list.c: Don't include xalloc.h.
2754         (gl_avltreehash_list_implementation): Update.
2755         * lib/gl_rbtreehash_list.c: Don't include xalloc.h.
2756         (gl_rbtreehash_list_implementation): Update.
2757         * modules/array-list (Depends-on): Remove xalloc.
2758         * modules/carray-list (Depends-on): Likewise.
2759         * modules/linked-list (Depends-on): Likewise.
2760         * modules/linkedhash-list (Depends-on): Likewise.
2761         * modules/avltree-list (Depends-on): Likewise.
2762         * modules/rbtree-list (Depends-on): Likewise.
2763         * modules/avltreehash-list (Depends-on): Likewise.
2764         * modules/rbtreehash-list (Depends-on): Likewise.
2765
2766         * modules/xsublist: New file.
2767         * lib/gl_xsublist.h: New file.
2768         * lib/gl_xsublist.c: New file.
2769         * lib/gl_sublist.h (gl_sublist_create): Disable declaration.
2770         (gl_sublist_nx_create): New declaration.
2771         * lib/gl_sublist.c: Don't include xalloc.h.
2772         (gl_sublist_nx_create_empty): Renamed from gl_sublist_create_empty.
2773         (gl_sublist_nx_create_fill): Renamed from gl_sublist_create_fill.
2774         (gl_sublist_node_nx_set_value): Renamed from gl_sublist_node_set_value.
2775         Change return type to 'int'. Return -1 upon out-of-memory.
2776         (gl_sublist_nx_set_at): Renamed from gl_sublist_set_at. Return NULL
2777         upon out-of-memory.
2778         (gl_sublist_nx_add_first): Renamed from gl_sublist_add_first. Return
2779         NULL upon out-of-memory.
2780         (gl_sublist_nx_add_last): Renamed from gl_sublist_add_last. Return NULL
2781         upon out-of-memory.
2782         (gl_sublist_nx_add_before): Renamed from gl_sublist_add_before. Return
2783         NULL upon out-of-memory.
2784         (gl_sublist_nx_add_after): Renamed from gl_sublist_add_after. Return
2785         NULL upon out-of-memory.
2786         (gl_sublist_nx_add_at): Renamed from gl_sublist_add_at. Return NULL
2787         upon out-of-memory.
2788         (gl_sublist_sortedlist_nx_add): Renamed from gl_sublist_sortedlist_add.
2789         (gl_sublist_list_implementation): Update.
2790         (gl_sublist_nx_create): Renamed from gl_sublist_create. Return NULL
2791         upon out-of-memory.
2792         * modules/sublist (Depends-on): Remove xalloc.
2793
2794         * tests/test-array_list.c: Use gl_list_nx_* functions where possible.
2795         * tests/test-carray_list.c: Likewise.
2796         * tests/test-linked_list.c: Likewise.
2797         * tests/test-linkedhash_list.c: Likewise.
2798         * tests/test-avltree_list.c: Likewise.
2799         * tests/test-rbtree_list.c: Likewise.
2800         * tests/test-avltreehash_list.c: Likewise.
2801         * tests/test-rbtreehash_list.c: Likewise.
2802         * modules/array-list-tests (Makefile.am): Don't link with @LIBINTL@.
2803         * modules/carray-list-tests (Makefile.am): Likewise.
2804         * modules/linked-list-tests (Makefile.am): Likewise.
2805         * modules/linkedhash-list-tests (Makefile.am): Likewise.
2806         * modules/avltree-list-tests (Makefile.am): Likewise.
2807         * modules/rbtree-list-tests (Makefile.am): Likewise.
2808         * modules/avltreehash-list-tests (Makefile.am): Likewise.
2809         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
2810
2811         * NEWS: Mention the changes.
2812
2813         * lib/clean-temp.c: Include gl_xlist.h.
2814         * modules/clean-temp (Depends-on): Add xlist.
2815
2816         * lib/git-merge-changelog.c: Include gl_xlist.h instead of gl_list.h.
2817         * modules/git-merge-changelog (Depends-on): Add xlist. Remove list.
2818
2819         * tests/test-array_oset.c: Include gl_xlist.h.
2820         * modules/array-oset-tests (Depends-on): Add xlist.
2821
2822         Reported by José E. Marchesi <jemarch@gnu.org>.
2823
2824 2009-12-13  Bruno Haible  <bruno@clisp.org>
2825
2826         Move the malloc checking from module 'oset' to new module 'xoset'.
2827         * modules/xoset: New file.
2828         * lib/gl_xoset.h: New file.
2829         * lib/gl_xoset.c: New file.
2830         * lib/gl_oset.h (gl_oset_create_empty, gl_oset_add): Disable
2831         declarations.
2832         (gl_oset_nx_create_empty, gl_oset_nx_add): New declarations.
2833         (struct gl_oset_implementation): Rename and change methods accordingly.
2834         (gl_oset_nx_create_empty): Renamed from gl_oset_create_empty.
2835         (gl_oset_nx_add): Renamed from gl_oset_add. Change return type to
2836         'int'. Mark as __warn_unused_result__.
2837         * lib/gl_oset.c (gl_oset_nx_create_empty): Renamed from
2838         gl_oset_create_empty.
2839         (gl_oset_nx_add): Renamed from gl_oset_add. Change return type to
2840         'int'.
2841         * lib/gl_array_oset.c: Don't include xalloc.h.
2842         (gl_array_nx_create_empty): Renamed from gl_array_create_empty. Use
2843         malloc, not xmalloc.
2844         (grow): Change return type to 'int'. Don't call xalloc_die.
2845         (gl_array_nx_add_at): Renamed from gl_array_add_at. Change return type
2846         to 'int'.
2847         (gl_array_nx_add): Renamed from gl_array_add. Change return type to
2848         'int'.
2849         (gl_array_oset_implementation): Update.
2850         * lib/gl_anytree_oset.h (gl_tree_nx_create_empty): Renamed from
2851         gl_tree_create_empty.
2852         (gl_tree_nx_add): Renamed from gl_tree_add. Change return type to
2853         'int'.
2854         * lib/gl_avltree_oset.c: Don't include xalloc.h.
2855         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Use malloc, not
2856         xmalloc.
2857         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Use malloc,
2858         not xmalloc.
2859         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Use malloc, not
2860         xmalloc.
2861         (gl_avltree_oset_implementation): Update.
2862         * lib/gl_rbtree_oset.c: Don't include xalloc.h.
2863         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Use malloc, not
2864         xmalloc.
2865         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Use malloc,
2866         not xmalloc.
2867         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Use malloc, not
2868         xmalloc.
2869         (gl_rbtree_oset_implementation): Update.
2870         * modules/array-oset (Depends-on): Remove xalloc.
2871         * modules/avltree-oset (Depends-on): Likewise.
2872         * modules/rbtree-oset (Depends-on): Likewise.
2873         * tests/test-array_oset.c: Use gl_oset_nx_* functions where possible.
2874         * tests/test-avltree_oset.c: Likewise.
2875         * tests/test-rbtree_oset.c: Likewise.
2876         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
2877         * modules/avltree-oset-tests (Makefile.am): Don't link with @LIBINTL@.
2878         * modules/rbtree-oset-tests (Makefile.am): Likewise.
2879         * NEWS: Mention the change.
2880
2881 2009-12-05  Alfred M. Szmidt  <ams@gnu.org>
2882
2883         maint.mk: allow a project to override release-prep commands
2884         * top/maint.mk (alpha, beta, stable): Move release-preparatory
2885         commands into a new rule.
2886         (release-prep): New rule.
2887         (release-prep-hook): New overridable variable.
2888
2889 2009-12-13  Bruno Haible  <bruno@clisp.org>
2890
2891         * lib/localcharset.c (locale_charset): Fix comment about use of GetACP.
2892
2893 2009-12-13  Jim Meyering  <meyering@redhat.com>
2894
2895         maint.mk (null_AM_MAKEFLAGS, built_programs): remove unused definitions
2896         * top/maint.mk (null_AM_MAKEFLAGS, built_programs): Remove definitions.
2897
2898 2009-12-12  Bruno Haible  <bruno@clisp.org>
2899
2900         duplocale: Tweak.
2901         * lib/duplocale.c (rpl_duplocale): Mark categories array as 'const'.
2902
2903 2009-12-12  Karl Berry  <karl@gnu.org>
2904
2905         * config/srclist.txt (strtoll.c): tab changes, no more sync.
2906
2907 2009-12-12  Bruno Haible  <bruno@clisp.org>
2908
2909         * m4/po.m4: Undo incorrect untabification.
2910
2911 2009-12-12  Bruno Haible  <bruno@clisp.org>
2912
2913         c-strtod, c-strtold: Use multithread-safe implementation on MacOS X.
2914         * modules/c-strtod (Depends-on): Add locale.
2915         * modules/c-strtold (Depends-on): Likewise.
2916
2917 2009-12-12  Bruno Haible  <bruno@clisp.org>
2918
2919         * lib/localcharset.c (locale_charset): Add comment about use of GetACP.
2920
2921 2009-12-11  Eric Blake  <ebb9@byu.net>
2922
2923         setenv: relax requirement in light of POSIX ruling
2924         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Test handling of "" but
2925         not NULL.
2926         * tests/test-setenv.c (main): Relax test.
2927         * tests/test-unsetenv.c (main): Likewise.
2928         * doc/posix-functions/setenv.texi (setenv): Document this.
2929         * doc/posix-functions/unsetenv.texi (unsetenv): Likewise.
2930
2931 2009-12-11  Bruno Haible  <bruno@clisp.org>
2932
2933         New module 'fd-safer-flag'.
2934         * lib/dup-safer-flag.c: New file, extracted from lib/dup-safer.c.
2935         * lib/dup-safer.c (dup_safer_flag): Remove function.
2936         * lib/fd-safer-flag.c: New file, extracted from lib/fd-safer.c.
2937         * lib/fd-safer.c (fd_safer_flag): Remove function.
2938         * lib/unistd-safer.h (dup_safer_flag, fd_safer_flag): Update condition.
2939         * modules/cloexec (configure.ac): Drop indicator macro.
2940         * modules/fd-safer-flag: New file.
2941         * modules/pipe2-safer (Depends-on): Add fd-safer-flag. Remove cloexec.
2942         * modules/stdlib-safer (Depends-on): Add fd-safer-flag.
2943         * modules/unistd-safer-tests (Depends-on): Add fd-safer-flag.
2944
2945 2009-12-11  Bruno Haible  <bruno@clisp.org>
2946
2947         Tests for module 'nl_langinfo'.
2948         * modules/nl_langinfo-tests: New file.
2949         * tests/test-nl_langinfo.sh: New file.
2950         * tests/test-nl_langinfo.c: New file.
2951
2952         New module 'nl_langinfo'.
2953         * lib/nl_langinfo.c: New file.
2954         * m4/nl_langinfo.m4: New file.
2955         * modules/nl_langinfo: New file.
2956         * doc/posix-functions/nl_langinfo.texi: Mention the new module.
2957
2958 2009-12-11  Bruno Haible  <bruno@clisp.org>
2959
2960         Tests for module 'langinfo'.
2961         * modules/langinfo-tests: New file.
2962         * tests/test-langinfo.c: New file.
2963
2964         New module 'langinfo'.
2965         * lib/langinfo.in.h: New file.
2966         * m4/langinfo_h.m4: New file.
2967         * modules/langinfo: New file.
2968         * doc/posix-headers/langinfo.texi: Mention the new module.
2969
2970 2009-12-11  Bruno Haible  <bruno@clisp.org>
2971
2972         * lib/config.charset: Untabify.
2973
2974 2009-12-11  Bruno Haible  <bruno@clisp.org>
2975
2976         * modules/unistd-safer (configure.ac): Drop indicator macro.
2977
2978 2009-12-11  Bruno Haible  <bruno@clisp.org>
2979
2980         Move pipe2-safer code to its own file.
2981         * lib/pipe2-safer.c: New file, extracted from lib/pipe-safer.c.
2982         * lib/pipe-safer.c (pipe2_safer): Remove function.
2983         * modules/pipe2-safer (Files): Add lib/pipe2-safer.c.
2984         (Makefile.am): Add it to lib_SOURCES.
2985
2986 2009-12-10  Bruno Haible  <bruno@clisp.org>
2987
2988         * lib/recvfrom.c (rpl_recvfrom): Allow the from argument to be NULL.
2989
2990 2009-12-10  Bruno Haible  <bruno@clisp.org>
2991
2992         Declare which arguments expect non-NULL values, for GCC and clang.
2993         * build-aux/arg-nonnull.h: New file.
2994         * modules/arg-nonnull: New file.
2995         * lib/arpa_inet.in.h (_GL_ARG_NONNULL): New placeholder.
2996         (inet_ntop, inet_pton): Use it.
2997         * lib/dirent.in.h (_GL_ARG_NONNULL): New placeholder.
2998         (closedir, dirfd, opendir, scandir, alphasort): Use it.
2999         * lib/fcntl.in.h (_GL_ARG_NONNULL): New placeholder.
3000         (open, openat): Use it.
3001         * lib/fnmatch.in.h (_GL_ARG_NONNULL): New placeholder.
3002         (fnmatch): Use it.
3003         * lib/getopt.in.h (_GL_ARG_NONNULL): New placeholder.
3004         (getopt, getopt_long, getopt_long_only): Use it.
3005         * lib/glob.in.h (_GL_ARG_NONNULL): New placeholder.
3006         * lib/glob-libc.h (glob, globfree, glob64, globfree64, glob_pattern_p):
3007         Use it.
3008         * lib/iconv.in.h (_GL_ARG_NONNULL): New placeholder.
3009         (iconv_open): Use it.
3010         * lib/inttypes.in.h (_GL_ARG_NONNULL): New placeholder.
3011         (strtoimax, strtoumax): Use it.
3012         * lib/locale.in.h (_GL_ARG_NONNULL): New placeholder.
3013         (duplocale): Use it.
3014         * lib/math.in.h (_GL_ARG_NONNULL): New placeholder.
3015         (frexp, frexpl): Use it.
3016         * lib/netdb.in.h (_GL_ARG_NONNULL): New placeholder.
3017         (getaddrinfo, freeaddrinfo, getnameinfo): Use it.
3018         * lib/search.in.h (_GL_ARG_NONNULL): New placeholder.
3019         (tsearch, tfind, tdelete, twalk): Use it.
3020         * lib/signal.in.h (_GL_ARG_NONNULL): New placeholder.
3021         (sigismember, sigemptyset, sigaddset, sigdelset, sigfillset,
3022         sigpending): Use it.
3023         * lib/spawn.in.h (_GL_ARG_NONNULL): New placeholder.
3024         (posix_spawn, posix_spawnp, posix_spawnattr_init,
3025         posix_spawnattr_destroy, posix_spawnattr_getsigdefault,
3026         posix_spawnattr_setsigdefault, posix_spawnattr_getsigmask,
3027         posix_spawnattr_setsigmask, posix_spawnattr_getflags,
3028         posix_spawnattr_setflags, posix_spawnattr_getpgroup,
3029         posix_spawnattr_setpgroup, posix_spawnattr_getschedpolicy,
3030         posix_spawnattr_setschedpolicy, posix_spawnattr_getschedparam,
3031         posix_spawnattr_setschedparam, posix_spawn_file_actions_init,
3032         posix_spawn_file_actions_destroy, posix_spawn_file_actions_addopen,
3033         posix_spawn_file_actions_addclose, posix_spawn_file_actions_adddup2):
3034         Use it.
3035         * lib/stdio.in.h (_GL_ARG_NONNULL): New placeholder.
3036         (dprintf, fclose, fopen, fprintf, fpurge, fputc, fputs, freopen,
3037         rpl_fseek, fseeko, rpl_ftell, ftello, fwrite, getdelim, getline,
3038         obstack_printf, obstack_vprintf, popen, printf, putc, puts, remove,
3039         rename, renameat, snprintf, sprintf, asprintf, vasprintf, vdprintf,
3040         vfprintf, vprintf, vsnprintf, vsprintf): Use it.
3041         * lib/stdlib.in.h (_GL_ARG_NONNULL): New placeholder.
3042         (atoll, canonicalize_file_name, getloadavg, getsubopt, mkdtemp,
3043         mkostemp, mkostemps, mkstemp, mkstemps, putenv, srandom_r, initstate_r,
3044         setstate_r, random_r, realpath, rpmatch, setenv, strtod, strtoll,
3045         strtoull, unsetenv): Use it.
3046         * lib/string.in.h (_GL_ARG_NONNULL): New placeholder.
3047         (memchr, memmem, mempcpy, memrchr, rawmemchr, stpcpy, stpncpy,
3048         strchrnul, strdup, strndup, strnlen, strpbrk, strsep, strstr,
3049         strcasestr, strtok_r, mbslen, mbsnlen, mbschr, mbsrchr, mbsstr,
3050         mbscasecmp, mbsncasecmp, mbspcasecmp, mbscasestr, mbscspn, mbspbrk,
3051         mbsspn, mbssep, mbstok_r, strverscmp): Use it.
3052         * lib/strings.in.h (_GL_ARG_NONNULL): New placeholder.
3053         (strcasecmp, strncasecmp): Use it.
3054         * lib/sys_socket.in.h (_GL_ARG_NONNULL): New placeholder.
3055         (rpl_connect, rpl_bind, rpl_getpeername, rpl_getsockname,
3056         rpl_getsockopt, rpl_recv, rpl_send, rpl_recvfrom, rpl_sendto,
3057         rpl_setsockopt): Use it.
3058         * lib/sys_stat.in.h (_GL_ARG_NONNULL): New placeholder.
3059         (fchmodat, fstat, fstatat, lchmod, rpl_lstat, mkdir, mkdirat, mkfifo,
3060         mkfifoat, mknod, mknodat, stat, utimensat): Use it.
3061         * lib/sys_time.in.h (_GL_ARG_NONNULL): New placeholder.
3062         (gettimeofday): Use it.
3063         * lib/sys_times.in.h (_GL_ARG_NONNULL): New placeholder.
3064         (times): Use it.
3065         * lib/sys_utsname.in.h (_GL_ARG_NONNULL): New placeholder.
3066         (uname): Use it.
3067         * lib/time.in.h (_GL_ARG_NONNULL): New placeholder.
3068         (nanosleep, mktime, localtime_r, gmtime_r, strptime, timegm): Use it.
3069         * lib/unistd.in.h (_GL_ARG_NONNULL): New placeholder.
3070         (chown, euidaccess, faccessat, _gl_register_fd, fchownat,
3071         getdomainname, gethostname, getlogin_r, lchown, link, linkat, pipe2,
3072         pread, readlink, readlinkat, rmdir, symlink, symlinkat, unlink,
3073         unlinkat, write): Use it.
3074         * lib/wchar.in.h (_GL_ARG_NONNULL): New placeholder.
3075         (mbsrtowcs, mbsnrtowcs, wcsrtombs, wcsnrtombs): Use it.
3076         * lib/argv-iter.h: Include arg-nonnull.h.
3077         (_ATTRIBUTE_NONNULL_): Remove macro.
3078         (argv_iter_init_argv, argv_iter_init_stream, argv_iter,
3079         argv_iter_n_args, argv_iter_free): Use _GL_ARG_NONNULL.
3080         * lib/canonicalize-lgpl.c (_GL_ARG_NONNULL): Define, to defeat gcc
3081         optimization.
3082         * lib/getaddrinfo.c (_GL_ARG_NONNULL): Likewise.
3083         * lib/getdelim.c (_GL_ARG_NONNULL): Likewise.
3084         * lib/glob.c (_GL_ARG_NONNULL): Likewise.
3085         * lib/random_r.c (_GL_ARG_NONNULL): Likewise.
3086         * lib/setenv.c (_GL_ARG_NONNULL): Likewise.
3087         * lib/strtod.c (_GL_ARG_NONNULL): Likewise.
3088         * lib/tsearch.c (_GL_ARG_NONNULL): Likewise.
3089         * lib/unsetenv.c (_GL_ARG_NONNULL): Likewise.
3090         * modules/arpa_inet (Depends-on): Add arg-nonnull.
3091         (Makefile.am): Insert arg-nonnull.h into arpa/inet.h.
3092         * modules/dirent (Depends-on): Add arg-nonnull.
3093         (Makefile.am): Insert arg-nonnull.h into dirent.h.
3094         * modules/fcntl-h (Depends-on): Add arg-nonnull.
3095         (Makefile.am): Insert arg-nonnull.h into fcntl.h.
3096         * modules/fnmatch (Depends-on): Add arg-nonnull.
3097         (Makefile.am): Insert arg-nonnull.h into fnmatch.h.
3098         * modules/getopt-posix (Depends-on): Add arg-nonnull.
3099         (Makefile.am): Insert arg-nonnull.h into getopt.h.
3100         * modules/glob (Depends-on): Add arg-nonnull.
3101         (Makefile.am): Insert arg-nonnull.h into glob.h.
3102         * modules/iconv_open (Depends-on): Add arg-nonnull.
3103         (Makefile.am): Insert arg-nonnull.h into iconv.h.
3104         * modules/inttypes (Depends-on): Add arg-nonnull.
3105         (Makefile.am): Insert arg-nonnull.h into inttypes.h.
3106         * modules/locale (Depends-on): Add arg-nonnull.
3107         (Makefile.am): Insert arg-nonnull.h into locale.h.
3108         * modules/math (Depends-on): Add arg-nonnull.
3109         (Makefile.am): Insert arg-nonnull.h into math.h.
3110         * modules/netdb (Depends-on): Add arg-nonnull.
3111         (Makefile.am): Insert arg-nonnull.h into netdb.h.
3112         * modules/search (Depends-on): Add arg-nonnull.
3113         (Makefile.am): Insert arg-nonnull.h into search.h.
3114         * modules/signal (Depends-on): Add arg-nonnull.
3115         (Makefile.am): Insert arg-nonnull.h into signal.h.
3116         * modules/spawn (Depends-on): Add arg-nonnull.
3117         (Makefile.am): Insert arg-nonnull.h into spawn.h.
3118         * modules/stdio (Depends-on): Add arg-nonnull.
3119         (Makefile.am): Insert arg-nonnull.h into stdio.h.
3120         * modules/stdlib (Depends-on): Add arg-nonnull.
3121         (Makefile.am): Insert arg-nonnull.h into stdlib.h.
3122         * modules/string (Depends-on): Add arg-nonnull.
3123         (Makefile.am): Insert arg-nonnull.h into string.h.
3124         * modules/strings (Depends-on): Add arg-nonnull.
3125         (Makefile.am): Insert arg-nonnull.h into strings.h.
3126         * modules/sys_socket (Depends-on): Add arg-nonnull.
3127         (Makefile.am): Insert arg-nonnull.h into sys/socket.h.
3128         * modules/sys_stat (Depends-on): Add arg-nonnull.
3129         (Makefile.am): Insert arg-nonnull.h into sys/stat.h.
3130         * modules/sys_time (Depends-on): Add arg-nonnull.
3131         (Makefile.am): Insert arg-nonnull.h into sys/time.h.
3132         * modules/sys_times (Depends-on): Add arg-nonnull.
3133         (Makefile.am): Insert arg-nonnull.h into sys/times.h.
3134         * modules/sys_utsname (Depends-on): Add arg-nonnull.
3135         (Makefile.am): Insert arg-nonnull.h into sys/utsname.h.
3136         * modules/time (Depends-on): Add arg-nonnull.
3137         (Makefile.am): Insert arg-nonnull.h into time.h.
3138         * modules/unistd (Depends-on): Add arg-nonnull.
3139         (Makefile.am): Insert arg-nonnull.h into unistd.h.
3140         * modules/wchar (Depends-on): Add arg-nonnull.
3141         (Makefile.am): Insert arg-nonnull.h into wchar.h.
3142         * modules/argv-iter (Depends-on): Add arg-nonnull.
3143         * tests/test-canonicalize.c (null_ptr): New function.
3144         (main): Use it.
3145         * tests/test-canonicalize-lgpl.c (null_ptr): New function.
3146         (main): Use it.
3147         * tests/test-memmem.c (null_ptr): New function.
3148         (main): Use it.
3149         Reported by Jim Meyering.
3150
3151 2009-12-10  Bruno Haible  <bruno@clisp.org>
3152
3153         Use spaces for indentation, not tabs.
3154         * lib/**/*.[hcy] except lib/reg*.[hc]: Untabify.
3155         * m4/*.m4: Untabify.
3156         * build-aux/*.h: Untabify.
3157         * tests/**/*.[hc]: Untabify.
3158         * README: New section "Indent with spaces, not TABs", based on
3159         coreutils/HACKING and comments by Pádraig Brady and Paolo Bonzini.
3160         * NEWS: Mention the change.
3161
3162 2009-12-10  Bruno Haible  <bruno@clisp.org>
3163
3164         pty test: Fix link error.
3165         * modules/pty-tests (Makefile.am): Add the default LDADD value to
3166         test_pty_LDADD.
3167
3168 2009-12-07  Simon Josefsson  <simon@josefsson.org>
3169
3170         * modules/pty: New file.
3171         * modules/pty-tests: New file.
3172         * m4/pty.m4: New file.
3173         * tests/test-pty.c: New file.
3174         * doc/glibc-headers/pty.texi: Modified.
3175         * doc/glibc-functions/forkpty.texi: Modified.
3176         * doc/glibc-functions/openpty.texi: Modified.
3177
3178 2009-12-10  Bruno Haible  <bruno@clisp.org>
3179
3180         Avoid syntax error in C++ mode.
3181         * lib/stdio.in.h (rename): Don't use parameter name 'new'.
3182
3183 2009-12-10  Bruno Haible  <bruno@clisp.org>
3184
3185         Use sed with option -e.
3186         * gnulib-tool (func_version, func_emit_copyright_notice,
3187         func_emit_initmacro_end, func_import, func_create_testdir): Pass
3188         option -e to sed.
3189         * modules/link-warning (Makefile.am): Likewise.
3190
3191 2009-12-10  Jim Meyering  <meyering@redhat.com>
3192
3193         mgetgroups: do not write bytes beyond end of malloc'd buffer
3194         * lib/mgetgroups.c: Fix an off-by-one error.  When we have no
3195         username, we call getgroups with a one-element-shorter buffer,
3196         but still told it the length was original, max_n_groups.
3197
3198 2009-12-09  Eric Blake  <ebb9@byu.net>
3199
3200         cloexec: relax license
3201         * modules/cloexec (Maintainer): Add myself.
3202         (License): Use LGPL, not GPL.
3203
3204         link-warning: optimize generation
3205         * modules/link-warning (Makefile.am): Reduce process usage.
3206
3207 2009-12-09  Bruno Haible  <bruno@clisp.org>
3208
3209         * doc/posix-functions/unsetenv.texi: Mention Solaris 10 bug for which a
3210         workaround was added on 2009-11-17.
3211
3212 2009-12-09  Jim Meyering  <meyering@redhat.com>
3213             Bruno Haible  <bruno@clisp.org>
3214
3215         link-warning: Allow extra lines at the top of build-aux/link-warning.h.
3216         * modules/link-warning (Makefile.am): Make the comment-removing sed
3217         command more robust in the face of bootstrap-prepended comment lines.
3218
3219 2009-12-09  Bruno Haible  <bruno@clisp.org>
3220
3221         * lib/mgetgroups.c (mgetgroups): Don't remove duplicates if there is at
3222         most one group.
3223
3224 2009-12-09  Simon Josefsson <simon@josefsson.org>
3225             Bruno Haible  <bruno@clisp.org>
3226
3227         * build-aux/link-warning.h: Add copyright notice.
3228         * modules/link-warning (Makefile.am): Generate link-warning.h from
3229         build-aux/link-warning.h. Update LINK_WARNING_H accordingly.
3230         * NEWS: Mention change in link-warning module.
3231         * modules/arpa_inet (Makefile.am): Add dependency to arpa/inet.h.
3232         * modules/dirent (Makefile.am): Add dependency to dirent.h.
3233         * modules/fcntl-h (Makefile.am): Add dependency to fcntl.h.
3234         * modules/getopt-posix (Makefile.am): Add dependency to getopt.h.
3235         * modules/inttypes (Makefile.am): Add dependency to inttypes.h.
3236         * modules/math (Makefile.am): Add dependency to math.h.
3237         * modules/search (Makefile.am): Add dependency to search.h.
3238         * modules/signal (Makefile.am): Add dependency to signal.h.
3239         * modules/spawn (Makefile.am): Add dependency to spawn.h.
3240         * modules/stdio (Makefile.am): Add dependency to stdio.h.
3241         * modules/stdlib (Makefile.am): Add dependency to stdlib.h.
3242         * modules/string (Makefile.am): Add dependency to string.h.
3243         * modules/strings (Makefile.am): Add dependency to strings.h.
3244         * modules/sys_ioctl (Makefile.am): Add dependency to sys/ioctl.h.
3245         * modules/sys_select (Makefile.am): Add dependency to sys/select.h.
3246         * modules/sys_socket (Makefile.am): Add dependency to sys/socket.h.
3247         * modules/sys_stat (Makefile.am): Add dependency to sys/stat.h.
3248         * modules/sys_times (Makefile.am): Add dependency to sys/times.h.
3249         * modules/sys_utsname (Makefile.am): Add dependency to sys/utsname.h.
3250         * modules/sys_wait (Makefile.am): Add dependency to sys/wait.h.
3251         * modules/unistd (Makefile.am): Add dependency to unistd.h.
3252         * modules/wchar (Makefile.am): Add dependency to wchar.h.
3253
3254 2009-12-09  Bruno Haible  <bruno@clisp.org>
3255
3256         fchdir: Optimize away rpl_fstat when possible.
3257         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Set REPLACE_FSTAT only together with
3258         REPLACE_OPEN_DIRECTORY.
3259         * lib/fchdir.c (rpl_fstat): Define only when REPLACE_OPEN_DIRECTORY.
3260
3261 2009-12-09  Bruno Haible  <bruno@clisp.org>
3262
3263         * lib/fchdir.c: Update comment.
3264
3265 2009-12-09  Bruno Haible  <bruno@clisp.org>
3266
3267         * lib/cloexec.c (set_cloexec_flag): Clarify intent of dup2 call.
3268
3269 2009-12-08  Eric Blake  <ebb9@byu.net>
3270
3271         fchdir: avoid memory leak on re-registration.
3272         * lib/fchdir.c (ensure_dirs_slot): Avoid memory leak.
3273
3274 2009-12-08  Jim Meyering  <meyering@redhat.com>
3275
3276         init.sh: avoid Solaris 10 /bin/sh portability problem
3277         Solaris 10's /bin/sh does not pass '.' arguments 2.. to the
3278         sourced script:
3279           $ printf 'echo "$@"\n' > f; /bin/sh -c '. ./f bar'
3280           $ printf 'echo "$@"\n' > f; /bin/bash -c '. ./f bar'
3281           bar
3282         tests/init.sh relied on that, accepting a --set-path=DIR argument,
3283         and two tests used that idiom.
3284         * tests/init.sh: Update suggested usage comments.
3285         (path_prepend_): New function, to be used in place
3286         of the --src-path=DIR option.
3287         (setup_): Move PATH-prepending code into path_prepend_.
3288         * tests/test-pread.sh: Adapt to new usage.
3289         * tests/test-xalloc-die.sh: Likewise.
3290
3291 2009-12-08  Simon Josefsson  <simon@josefsson.org>
3292
3293         * doc/gnulib.texi (Glibc pty.h): Add.
3294         * doc/glibc-functions/forkpty.texi: Add.
3295         * doc/glibc-functions/openpty.texi: Add.
3296         Suggested by Bruno Haible.
3297
3298 2009-12-08  Eric Blake  <ebb9@byu.net>
3299
3300         fchdir: fix logic bugs
3301         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Fix logic bug.
3302         * tests/test-fchdir.c (main): Enhance test.
3303         * lib/fchdir.c (rpl_fstat): Always provide if fchdir replacement
3304         is in use.
3305
3306         dup2: fix logic bugs
3307         * lib/dup2.c (dup2): Fix logic bugs.  Use HAVE_DUP2 rather than
3308         REPLACE_DUP2 to decide when rpl_dup2 is needed.
3309         * m4/dup2.m4 (gl_REPLACE_DUP2): Only define REPLACE_DUP2 when dup2
3310         exists.
3311         (gl_FUNC_DUP2): Drop unneeded AC_DEFINE.
3312
3313 2009-12-07  Eric Blake  <ebb9@byu.net>
3314
3315         unlink: fix m4 detection
3316         * m4/unlink.m4 (gl_FUNC_UNLINK): Include correct header.
3317
3318         unistd-safer: add unit test
3319         * modules/unistd-safer-tests: New file.
3320         * tests/test-dup-safer.c: Likewise.
3321         * tests/test-cloexec.c (setmode): Avoid compiler warning.
3322         * tests/test-dup2.c (setmode): Likewise.
3323         * lib/cloexec.c (dup_cloexec): Fix mingw compile error.
3324
3325         cloexec: preserve text vs. binary across dup_cloexec
3326         * lib/cloexec.c (dup_cloexec) [W32]: Query and use translation
3327         mode.
3328         * modules/dup2-tests (Depends-on): Add binary-io.
3329         * modules/cloexec-tests (Depends-on): Likewise.
3330         * tests/test-dup2.c (setmode, is_mode): New helpers.
3331         (main): Add tests that translation mode is preserved.
3332         * tests/test-cloexec.c (setmode, is_mode, main): Likewise.
3333         Reported by Bruno Haible.
3334
3335         mgetgroups: reduce duplicate listings
3336         * lib/mgetgroups.c (mgetgroups): Reduce duplicates from the
3337         resulting array.
3338         * tests/test-chown.h (test_chown): Simplify client.
3339         * tests/test-lchown.h (test_lchown): Likewise.
3340
3341 2009-12-06  Bruno Haible  <bruno@clisp.org>
3342
3343         * lib/cloexec.c (dup_cloexec): Fix handling of _gl_register_dup return
3344         value.
3345
3346 2009-12-06  Bruno Haible  <bruno@clisp.org>
3347
3348         * lib/progname.c: Include stdio.h, stdlib.h.
3349         (set_program_name): Reject a NULL argument.
3350
3351 2009-12-05  Eric Blake  <ebb9@byu.net>
3352
3353         pipe2-safer: new module
3354         * modules/pipe2-safer: New file.
3355         * lib/unistd-safer.h (pipe2_safer): New prototype.
3356         * lib/unistd--.h (pipe2): New wrapper.
3357         * lib/pipe-safer.c (pipe2_safer): New function.
3358         * modules/pipe (Depends-on): Add pipe2-safer.
3359         * lib/pipe.c (create_pipe) [WIN32]: Let pipe2_safer do the work.
3360
3361         stdlib-safer: preserve cloexec flag for mkostemp[s]
3362         * lib/mkstemp-safer.c (mkostemp_safer, mkostemps_safer): Use new
3363         fd_safer_flag.
3364
3365         unistd-safer: allow preservation of cloexec status via flag
3366         * lib/unistd-safer.h (dup_safer_flag, fd_safer_flag): New
3367         prototypes.
3368         * lib/dup-safer.c (dup_safer_flag): New function.
3369         * lib/fd-safer.c (fd_safer_flag): Likewise.
3370         * modules/cloexec (configure.ac): Set witness.
3371
3372         test-dup2: enhance test
3373         * modules/dup2-tests (Depends-on): Add cloexec.
3374         * tests/test-dup2.c (main): Enhance test.
3375
3376         cloexec: add dup_cloexec
3377         * lib/cloexec.h (dup_cloexec): New prototype.  Add copyright
3378         header and comments.
3379         * lib/cloexec.c (set_cloexec_flag): Add comments.
3380         (dup_cloexec): New function, with mingw implementation borrowed
3381         from...
3382         * lib/w32spawn.h (dup_noinherit): ...here.
3383         * modules/execute (Depends-on): Add cloexec.
3384         * modules/pipe (Depends-on): Likewise.
3385         * modules/cloexec (Depends-on): Add dup2.
3386         * modules/cloexec-tests (Files): New file.
3387         * tests/test-cloexec.c: Likewise.
3388
3389         test-xalloc-die: fix test for mingw
3390         * modules/xalloc-die-tests (Files): Add tests/init.sh.
3391         * tests/test-xalloc-die.sh: Rewrite to use init.sh.  Strip
3392         directory and .exe suffix off argv[0] output.
3393
3394         test-fseeko: fix test for mingw
3395         * tests/test-fseeko.c (fseek): Redefine GL_LINK_WARNING, rather
3396         than undefining fseek, so test will pass on mingw.
3397
3398 2009-12-05  Bruno Haible  <bruno@clisp.org>
3399
3400         * lib/progname.h (set_program_name): Clarify specification.
3401         * lib/progname.c (set_program_name): Likewise.
3402         Reported by Jim Meyering.
3403
3404 2009-12-05  Jim Meyering  <meyering@redhat.com>
3405
3406         maint.mk: backslash-escape parens in default regexp
3407         * top/maint.mk (news-check-regexp): Now that we're using grep -E,
3408         backslash-escape the literal parentheses.
3409
3410         maint.mk: news-date-check: use grep -E
3411         * top/maint.mk (today): Define a Make variable, not a...
3412         (news-date-check): ...shell variable.
3413         (news-date-regexp): Use the Make variable.
3414         Use grep's -E option.  Change the failing diagnostic to mention
3415         the variable, $(news-date-regexp).
3416
3417 2009-12-04  Alfred M. Szmidt  <ams@gnu.org>
3418
3419         maintainer-makefile: allow customization of NEWS entry format
3420         * top/maint.mk (news-date-regexp): New overridable variable.
3421         (news-date-check): Use it.
3422
3423 2009-12-04  Eric Blake  <ebb9@byu.net>
3424
3425         mgetgroups: add xgetgroups, and avoid ENOSYS failures
3426         * lib/mgetgroups.h (xgetgroups): New prototype.
3427         * lib/mgetgroups.c (xgetgroups): New wrapper.
3428         (mgetgroups): Handle ENOSYS.
3429         * modules/mgetgroups (Depends-on): Add realloc.
3430         Reported by Scott Harrison <scott.gnu.2009@scottrix.co.uk>.
3431
3432         mgetgroups: avoid argument promotion issues with -1
3433         * lib/mgetgroups.c (mgetgroups): A cast is required when checking
3434         for invalid gid_t.
3435         * tests/test-chown.h (getegid, test_chown): Likewise.
3436         * tests/test-lchown.h (getegid, test_lchown): Likewise.
3437
3438 2009-12-03  Paolo Bonzini  <bonzini@gnu.org>
3439
3440         exclude: Fix header file problems.
3441         * lib/exclude.h: Add multiple inclusion guards and include stdbool.h.
3442
3443 2009-12-01  Jim Meyering  <meyering@redhat.com>
3444
3445         fts: fts_open: do not let an empty string cause immediate failure
3446         This is required in support of GNU rm, for which the command
3447         "rm A '' B" must process and remove both A and B, in spite of
3448         the empty string argument.
3449         * lib/fts.c (fts_open): Do not let the presence of an empty string
3450         cause fts_open to fail immediately.  Most fts-using tools must be
3451         able to process all arguments, in order, and can be expected to
3452         diagnose such arguments themselves.
3453
3454 2009-11-30  Eric Blake  <ebb9@byu.net>
3455
3456         utimens: fix compilation error
3457         * lib/utimens.c (lutimens) [!HAVE_UTIMENSAT && HAVE_LUTIMES]:
3458         Declare variable at right scope.
3459
3460 2009-11-29  Jim Meyering  <meyering@redhat.com>
3461
3462         bootstrap: handle perl-5.11's changed --version output
3463         * build-aux/bootstrap (get_version): Handle perl separately,
3464         since perl-5.11's --version output is different.
3465
3466 2009-11-28  Jim Meyering  <meyering@redhat.com>
3467
3468         userspec: depend on the inttostr module, too
3469         * modules/userspec (Depends-on): Add inttostr.
3470
3471         userspec: disallow an ID that maps to (uid_t)-1 or (gid_t)-1
3472         * lib/userspec.c (parse_with_separator): Do not accept a user ID
3473         number of MAXUID when it evaluates to (uid_t) -1.
3474         Likewise for group ID.  Reported by Matt McCutchen in
3475         <http://savannah.gnu.org/bugs/?28113>
3476
3477         userspec: reformat to use spaces, not TABs
3478         * lib/userspec.c: Expand TABs to spaces.
3479         Add Emacs' "indent-tabs-mode: nil" hint.
3480
3481 2009-11-27  Eric Blake  <ebb9@byu.net>
3482
3483         getopt-gnu: flush out another BSD bug
3484         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Test for the bug.
3485         * tests/test-getopt.c (main): Check POSIXLY_CORRECT first, to
3486         flush out BSD bug.
3487         * tests/test-getopt.h (test_getopt): End lists with NULL.
3488         * tests/test-getopt_long.h (test_getopt_long): Likewise.
3489         (test_getopt_long_posix): Enhance test.
3490         * modules/getopt-posix-tests (Depends-on): Add stdbool.
3491         * doc/glibc-functions/getopt_long.texi (getopt_long): Mention
3492         getopt-gnu.
3493         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
3494         Likewise.
3495
3496 2009-11-27  Simon Josefsson  <simon@josefsson.org>
3497
3498         * modules/idpriv-droptemp-tests (Notice): Fix text.
3499
3500 2009-11-27  Jim Meyering  <meyering@redhat.com>
3501
3502         test-xalloc-die: avoid spurious failure due to libtool argv difference
3503         In a libtool-enabled project, this test would fail due to a difference
3504         in the emitted program name, e.g.,
3505         -test-xalloc-die: memory exhausted
3506         +/tmp/.../tests/.libs/lt-test-xalloc-die: memory exhausted
3507         Use program to avoid that.
3508         * modules/xalloc-die-tests (Depends-on): Add progname.
3509         * tests/test-xalloc-die.c: Include progname.h".
3510         (program_name): Remove decl.
3511         (main): Call set_program_name.
3512         * tests/test-xalloc-die.sh (compare): Remove unnecessary ${EXE}.
3513
3514 2009-11-26  Richard Jones  <rjones@redhat.com>
3515
3516         w32sock: leave win32 error in place.
3517         * lib/w32sock.h (set_winsock_errno): Do not call WSASetLastError.
3518
3519 2009-11-26  Eric Blake  <ebb9@byu.net>
3520
3521         init.sh: suggest to use skip_ and fail_ functions in comments
3522         * tests/init.sh: Add a sentence.
3523
3524 2009-11-25  Bruno Haible  <bruno@clisp.org>
3525
3526         init.sh: add documentation in comments
3527         * tests/init.sh: Add some developer and user documentation.
3528
3529 2009-11-26  Jim Meyering  <meyering@redhat.com>
3530
3531         init.sh: accommodate even those who specify bogus srcdir manually
3532         * tests/init.sh: Normally, srcdir is guaranteed by automake and
3533         configure-time tests to be sanitized, so that there is no need to
3534         use "$srcdir" in Makefile rules and shell scripts.  Using $srcdir
3535         (with no double quotes) suffices.  However, since tests may be
3536         invoked manually, and since you may explicitly set srcdir to the
3537         name of a directory containing spaces, do quote its uses here.
3538         * tests/test-pread.sh: Likewise.
3539         Suggested by Bruno Haible.
3540
3541         test-pread.sh: avoid diagnostics for those who ignore SIGPIPE
3542         * tests/test-pread.sh: Write no data into the pipe, because
3543         test-pread actually reads none.  This avoids a diagnostic,
3544         "bash: echo: write error: Broken pipe", that arises in the unusual
3545         event something is ignoring SIGPIPE, and might be interpreted
3546         as some sort of failure.  Reported by Bruno Haible.
3547
3548 2009-11-25  Jim Meyering  <meyering@redhat.com>
3549
3550         test-pread: cover failure with ESPIPE and EINVAL
3551         * tests/test-pread.c (main): Test for failure, too.
3552         * tests/test-pread.sh: Invoke with stdin on a pipe.
3553         Suggested by Eric Blake.
3554
3555         pread: improvement and fix
3556         * modules/pread (Depends-on): Depend on lseek, for portability to
3557         e.g., mingw.  Suggested by Eric Blake.
3558         * lib/pread.c (__libc_read): Define.  Reported by Richard W.M. Jones.
3559
3560         unistd.in.h: correct declaration of pread
3561         * lib/unistd.in.h: Correct type of "buf" parameter: void*, not char*
3562         Reported by Richard W.M. Jones.
3563
3564         test-pread.sh: distribute the test script
3565         * modules/pread-tests (Files): Include test-pread.sh.
3566
3567         test-pread.sh: clean up
3568         * tests/test-pread.sh: Don't refer to $builddir. Just use equivalent ".".
3569         * modules/pread-tests (TESTS_ENVIRONMENT): Don't export builddir.
3570         That is unnecessary, since it's always ".".
3571         Suggestion from Eric Blake.
3572
3573         test-pread.sh: make executable
3574         * tests/test-pread.sh: Set executable bit.
3575         Reported by Eric Blake.
3576
3577         correct typo in test-pread.sh
3578         * tests/test-pread.sh: Add #! line.
3579
3580         test pread
3581         * tests/test-pread.c: New file.
3582         * tests/test-pread.sh: Likewise.
3583         * modules/pread-tests: Likewise.
3584
3585         pread: new module
3586         * modules/pread: New file.
3587         * lib/unistd.in.h (pread): Define/declare.
3588         * lib/pread.c (pread): New file.
3589         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Define defaults.
3590         * modules/unistd (Makefile.am): Substitute witnesses.
3591         * doc/posix-functions/pread.texi (pread): Update.
3592         * MODULES.html.sh: Add pread.
3593
3594 2009-11-25  Jim Meyering  <meyering@redhat.com>
3595
3596         tests/init.sh: new file to be used via most *.sh tests
3597         * tests/init.sh: New file.
3598
3599 2009-11-25  Eric Blake  <ebb9@byu.net>
3600
3601         utimens: work around older Linux failure with symlinks
3602         * lib/utimens.c (lutimensat_works_really): New variable.
3603         (fdutimens, lutimens): Use it to manage kernels that support
3604         nanosecond times on files, but not on symlinks.
3605         Reported by OndÅ™ej Vašík.
3606
3607         utimes: fix configure grammar
3608         * m4/utimes.m4 (gl_FUNC_UTIMES): Delete spurious word.
3609
3610 2009-11-25  Paolo Bonzini  <bonzini@gnu.org>
3611
3612         regex: Fix fastmap for multibyte character ranges.
3613         * lib/regcomp.c (re_compute_fastmap_iter): Add all multibyte lead
3614         characters when a multibyte character range is included.
3615
3616 2009-11-22  Andy Wingo  <wingo@pobox.com>
3617
3618         version-etc: work also with AM_INIT_AUTOMAKE's no-define option
3619         * lib/version-etc.c [!defined PACKAGE]: Define to PACKAGE_TARNAME.
3620
3621 2009-11-24  Bruno Haible  <bruno@clisp.org>
3622
3623         doc: Most *_l functions exist in MacOS X 10.5.
3624         * doc/posix-functions/duplocale.texi: Update platforms list.
3625         * doc/posix-functions/freelocale.texi: Likewise.
3626         * doc/posix-functions/newlocale.texi: Likewise.
3627         * doc/posix-functions/uselocale.texi: Likewise.
3628         * doc/posix-functions/isalnum_l.texi: Likewise.
3629         * doc/posix-functions/isalpha_l.texi: Likewise.
3630         * doc/posix-functions/isblank_l.texi: Likewise.
3631         * doc/posix-functions/iscntrl_l.texi: Likewise.
3632         * doc/posix-functions/isdigit_l.texi: Likewise.
3633         * doc/posix-functions/isgraph_l.texi: Likewise.
3634         * doc/posix-functions/islower_l.texi: Likewise.
3635         * doc/posix-functions/isprint_l.texi: Likewise.
3636         * doc/posix-functions/ispunct_l.texi: Likewise.
3637         * doc/posix-functions/isspace_l.texi: Likewise.
3638         * doc/posix-functions/isupper_l.texi: Likewise.
3639         * doc/posix-functions/iswalnum_l.texi: Likewise.
3640         * doc/posix-functions/iswalpha_l.texi: Likewise.
3641         * doc/posix-functions/iswblank_l.texi: Likewise.
3642         * doc/posix-functions/iswcntrl_l.texi: Likewise.
3643         * doc/posix-functions/iswctype_l.texi: Likewise.
3644         * doc/posix-functions/iswdigit_l.texi: Likewise.
3645         * doc/posix-functions/iswgraph_l.texi: Likewise.
3646         * doc/posix-functions/iswlower_l.texi: Likewise.
3647         * doc/posix-functions/iswprint_l.texi: Likewise.
3648         * doc/posix-functions/iswpunct_l.texi: Likewise.
3649         * doc/posix-functions/iswspace_l.texi: Likewise.
3650         * doc/posix-functions/iswupper_l.texi: Likewise.
3651         * doc/posix-functions/iswxdigit_l.texi: Likewise.
3652         * doc/posix-functions/isxdigit_l.texi: Likewise.
3653         * doc/posix-functions/nl_langinfo_l.texi: Likewise.
3654         * doc/posix-functions/strcasecmp_l.texi: Likewise.
3655         * doc/posix-functions/strcoll_l.texi: Likewise.
3656         * doc/posix-functions/strfmon_l.texi: Likewise.
3657         * doc/posix-functions/strftime_l.texi: Likewise.
3658         * doc/posix-functions/strncasecmp_l.texi: Likewise.
3659         * doc/posix-functions/strxfrm_l.texi: Likewise.
3660         * doc/posix-functions/tolower_l.texi: Likewise.
3661         * doc/posix-functions/toupper_l.texi: Likewise.
3662         * doc/posix-functions/towctrans_l.texi: Likewise.
3663         * doc/posix-functions/towlower_l.texi: Likewise.
3664         * doc/posix-functions/towupper_l.texi: Likewise.
3665         * doc/posix-functions/wcscoll_l.texi: Likewise.
3666         * doc/posix-functions/wcsxfrm_l.texi: Likewise.
3667         * doc/posix-functions/wctrans_l.texi: Likewise.
3668         * doc/posix-functions/wctype_l.texi: Likewise.
3669         * doc/glibc-functions/strptime_l.texi: Likewise.
3670         * doc/glibc-functions/strtod_l.texi: Likewise.
3671         * doc/glibc-functions/strtof_l.texi: Likewise.
3672         * doc/glibc-functions/strtol_l.texi: Likewise.
3673         * doc/glibc-functions/strtold_l.texi: Likewise.
3674         * doc/glibc-functions/strtoll_l.texi: Likewise.
3675         * doc/glibc-functions/strtoul_l.texi: Likewise.
3676         * doc/glibc-functions/strtoull_l.texi: Likewise.
3677         * doc/glibc-functions/wcsftime_l.texi: Likewise.
3678         * doc/glibc-functions/wcstod_l.texi: Likewise.
3679         * doc/glibc-functions/wcstof_l.texi: Likewise.
3680         * doc/glibc-functions/wcstol_l.texi: Likewise.
3681         * doc/glibc-functions/wcstold_l.texi: Likewise.
3682         * doc/glibc-functions/wcstoll_l.texi: Likewise.
3683         * doc/glibc-functions/wcstoul_l.texi: Likewise.
3684         * doc/glibc-functions/wcstoull_l.texi: Likewise.
3685
3686 2009-11-24  Bruno Haible  <bruno@clisp.org>
3687
3688         duplocale: Fix logic bug.
3689         * lib/duplocale.c: Don't include <langinfo.h>.
3690         (_NL_LOCALE_NAME): Remove macro.
3691         (rpl_duplocale): Use setlocale instead of nl_langinfo.
3692         * tests/test-duplocale.c (main): Also test duplocale after uselocale.
3693
3694 2009-11-23  Jim Meyering  <meyering@redhat.com>
3695
3696         test-update-copyright: don't hard-code /usr/bin/perl
3697         * tests/test-update-copyright.sh (YEAR): Use date +%Y, rather than
3698         perl to print the current year.  Gilles Espinasse reported that
3699         the replaced use of perl was hard-coded as /usr/bin/perl.
3700
3701 2009-11-23  Bruno Haible  <bruno@clisp.org>
3702
3703         duplocale: Add support for glibc 2.3.x.
3704         * lib/duplocale.c (rpl_duplocale): Add fallback code for glibc 2.3.x.
3705
3706 2009-11-22  Bruno Haible  <bruno@clisp.org>
3707
3708         vasnprintf: Tiny optimization.
3709         * lib/vasnprintf.c (decimal_point_char): Choose the fast path also on
3710         MacOS X.
3711
3712 2009-11-22  Bruno Haible  <bruno@clisp.org>
3713
3714         Tests for module 'duplocale'.
3715         * modules/duplocale-tests: New file.
3716         * tests/test-duplocale.c: New file.
3717
3718         New module 'duplocale'.
3719         * m4/duplocale.m4: New file.
3720         * lib/locale.in.h (duplocale): New declaration.
3721         * lib/duplocale.c: New file.
3722         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H, gl_LOCALE_MODULE_INDICATOR,
3723         gl_LOCALE_H_DEFAULTS): New macros.
3724         (gl_LOCALE_H): Require gl_LOCALE_H_DEFAULTS. Invoke
3725         gl_CHECK_NEXT_HEADERS unconditionally. Invoke gl_REPLACE_LOCALE_H.
3726         * modules/locale (Makefile.am): Substitute also GNULIB_DUPLOCALE,
3727         REPLACE_DUPLOCALE.
3728         * modules/duplocale: New file.
3729         * doc/posix-functions/duplocale.texi: Mention the glibc bug.
3730
3731 2009-11-22  Bruno Haible  <bruno@clisp.org>
3732
3733         * modules/locale-tests (configure.ac): Test for newlocale function.
3734         * tests/test-locale.c: When the system has extended locale functions,
3735         verify that <locale.h> defines locale_t and LC_GLOBAL_LOCALE.
3736
3737         locale: Make locale_t available when possible.
3738         * lib/locale.in.h: Include <xlocale.h> when it exists.
3739         * m4/locale_h.m4 (gl_LOCALE_H): Check for <xlocale.h> and arrange to
3740         replace <locale.h> if it does not define locale_t but <xlocale.h> does.
3741         * modules/locale (Depends-on): Add extensions.
3742         (Makefile.am): Also substitute HAVE_XLOCALE_H.
3743         * doc/posix-headers/locale.texi: Document the problem with locale_t.
3744
3745 2009-11-22  Bruno Haible  <bruno@clisp.org>
3746
3747         Add comments.
3748         * m4/dirent_h.m4 (gl_DIRENT_H): Add comment about gl_CHECK_NEXT_HEADERS
3749         invocation.
3750         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
3751         * m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
3752         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
3753
3754 2009-11-22  Bruno Haible  <bruno@clisp.org>
3755
3756         error: account for the possibility of freopen (stdout).
3757         * lib/error.c: Include <unistd.h>.
3758         (flush_stdout): New function, extracted from error and error_at_line.
3759         Determine stdout's fd dynamically.
3760         (error, error_at_line): Invoke flush_stdout.
3761         * m4/error.m4 (gl_PREREQ_ERROR): Require AC_C_INLINE.
3762         * modules/error (Depends-on): Add unistd.
3763
3764 2009-11-22  Bruno Haible  <bruno@clisp.org>
3765
3766         diffseq: Add comment.
3767         * lib/diffseq.h (IF_LINT): Add comment about pitfall.
3768
3769 2009-11-22  Jim Meyering  <meyering@redhat.com>
3770
3771         c-stack: avoid defining an unused static function
3772         * lib/c-stack.c (find_stack_direction): Do not define this function
3773         when it will not be used.
3774
3775         diffseq: avoid spurious gcc warnings
3776         * lib/diffseq.h (IF_LINT2): Define.
3777         (compareseq): Use it to initialize two members of "part".
3778         This avoids two used-uninitialized warnings.
3779
3780 2009-11-21  Jim Meyering  <meyering@redhat.com>
3781
3782         c-stack: avoid "ignoring return value of `write'" warning
3783         * lib/c-stack.c: Include "ignore-value.h".
3784         (die): Explicitly ignore each write return value.
3785         * modules/c-stack (Depends-on): Add ignore-value.
3786
3787 2009-11-21  Bruno Haible  <bruno@clisp.org>
3788
3789         diffseq: reduce scope of variable 'best'.
3790         * lib/diffseq.h (diag) [USE_HEURISTIC]: Reduce scope of 'best'
3791         variable, earlier used for two different purposes.
3792
3793 2009-11-21  Jim Meyering  <meyering@redhat.com>
3794
3795         diffseq: remove useless assignment to "best"
3796         * lib/diffseq.h (diag) [USE_HEURISTIC]: Remove useless "best = 0"
3797         assignment.  At that point "best" is already guaranteed to be zero.
3798
3799 2009-11-20  Eric Blake  <ebb9@byu.net>
3800
3801         build: mention ftp redirector in release announcements
3802         * top/maint.mk (gnu_rel_host, url_dir_list): Provide defaults for
3803         values that used to come from cfg.mk; mention FTP redirect URL.
3804         * build-aux/announce-gen: Mention the mirror list.
3805         Suggested by Karl Berry.
3806
3807         nanosleep: improve port to mingw
3808         * lib/nanosleep.c (rpl_nanosleep): Reject invalid arguments.
3809         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Incorporate LIBSOCKET into
3810         LIB_NANOSLEEP, but only when needed.
3811         * modules/select (Link): Document LIBSOCKET.
3812         * m4/select.m4 (gl_FUNC_SELECT): Ensure LIBSOCKET is defined early
3813         enough.
3814
3815         nanosleep: work around cygwin bug
3816         * lib/nanosleep.c (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]:
3817         Fix logic bug when nanosleep fails.  Work around cygwin 1.5.x
3818         bug.
3819         (getnow): Delete, not needed.
3820         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): No longer require
3821         LIB_CLOCK_GETTIME.
3822         * modules/nanosleep (Depends-on): Add intprops and verify.  Drop
3823         clock-time, gettime.
3824         * doc/posix-functions/nanosleep.texi (nanosleep): Document the
3825         bug.
3826         * modules/nanosleep-tests: New test.
3827         * tests/test-nanosleep.c: New file.
3828
3829         sleep: work around cygwin bug
3830         * lib/sleep.c (rpl_sleep): Work around the bug.
3831         * m4/sleep.m4 (gl_FUNC_SLEEP): Detect the bug.
3832         (gl_PREREQ_SLEEP): Delete unused macro.
3833         * modules/sleep (Depends-on): Add verify.
3834         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add default.
3835         * modules/unistd (Makefile.am): Substitute witness.
3836         * lib/unistd.in.h (sleep): Update prototype.
3837         * doc/posix-functions/sleep.texi (sleep): Document the bug.
3838         * tests/test-sleep.c (main) [HAVE_DECL_ALARM]: Test it.
3839         * modules/sleep-tests (Depends-on): Check for alarm.
3840
3841 2009-11-20  Jim Meyering  <meyering@redhat.com>
3842
3843         maint.mk: improve sc_prohibit_magic_number_exit
3844         * top/maint.mk (sc_prohibit_magic_number_exit): Tighten regexp
3845         so it does not match uses like System.exit(1).
3846         Add comments showing how to correct all offenders.
3847
3848 2009-11-19  Eric Blake  <ebb9@byu.net>
3849
3850         xalloc-die-tests: add missing library
3851         * modules/xalloc-die-tests (Makefile.am): Add LDADD line.
3852
3853         test-xvasprintf: silence compiler warnings
3854         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Mask
3855         empty string from gcc.
3856
3857 2009-11-19  Jim Meyering  <meyering@redhat.com>
3858
3859         xfreopen: new module, from coreutils
3860         * modules/xfreopen: New module.
3861         * lib/xfreopen.c: New file.
3862         * lib/xfreopen.h: New file.
3863         * MODULES.html.sh (File stream based Input/Output"): Add it.
3864
3865 2009-11-19  Eric Blake  <ebb9@byu.net>
3866
3867         manywarnings: depend on warnings
3868         * modules/manywarnings (Depends-on): Add warnings.
3869
3870         build: avoid compiler warnings
3871         * lib/select.c (rpl_select): Delete unused variable.
3872         * lib/setsockopt.c (rpl_setsockopt): Avoid incompatible pointer.
3873
3874 2009-11-18  Eric Blake  <ebb9@byu.net>
3875
3876         tests: avoid false negative with --with-packager
3877         * tests/test-version-etc.sh: Discard packager information.
3878         * tests/test-argp-version-etc-1.sh: Likewise.
3879         Reported by Mike Frysinger.
3880
3881         utimens: fix regression on Solaris
3882         * m4/utimens.m4 (gl_UTIMENS): Check for BSD bug.
3883         * lib/utimens.c (fdutimens): Revert 2009-11-08 change; Solaris 10
3884         can only change fd timestamps via futimesat.  Instead, use an
3885         additional witness macro to avoid BSD bug.
3886         Reported by Jim Meyering.
3887
3888 2009-11-17  Eric Blake  <ebb9@byu.net>
3889
3890         usleep: use it to simplify tests
3891         * modules/stat-time-tests (Depends-on): Add usleep.
3892         (configure.ac): Drop usleep check.
3893         * modules/chown-tests (Depends-on, configure.ac): Likewise.
3894         * modules/lchown-tests (Depends-on, configure.ac): Likewise.
3895         * modules/fdutimensat-tests (Depends-on, configure.ac): Likewise.
3896         * modules/futimens-tests (Depends-on, configure.ac): Likewise.
3897         * modules/openat-tests (Depends-on, configure.ac): Likewise.
3898         * modules/utimens-tests (Depends-on, configure.ac): Likewise.
3899         * modules/utimensat-tests (Depends-on, configure.ac): Likewise.
3900         * modules/pipe-filter-gi-tests (Depends-on, configure.ac):
3901         Likewise.
3902         * tests/test-chown.h (nap): Rely on nicer usleep semantics.
3903         * tests/test-lchown.h (nap): Likewise.
3904         * tests/test-pipe-filter-gi2-main.c (small_nap): Likewise.
3905         * tests/test-stat-time.c (nap): Likewise.
3906         * tests/test-utimens-common.h (nap): Update comments.
3907
3908         usleep: new module
3909         * modules/usleep: New file.
3910         * m4/usleep.m4 (gl_FUNC_USLEEP): Likewise.
3911         * lib/usleep.c (usleep): Likewise.
3912         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add defaults.
3913         * modules/unistd (Makefile.am): Substitute witnesses.
3914         * lib/unistd.in.h (usleep): Add declaration.
3915         * doc/pastposix-functions/usleep.texi (usleep): Document this.
3916         * MODULES.html.sh (Date and time): Likewise.
3917         * modules/usleep-tests (Depends-on): New test.
3918         * tests/test-usleep.c: New file.
3919
3920         chown: work around OpenBSD bug
3921         * lib/chown.c (rpl_chown): Work around the bug.
3922         * lib/lchown.c (rpl_lchown): Attempt to do likewise.
3923         * m4/chown.m4 (gl_FUNC_CHOWN): Test for ctime bug.
3924         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check for lchmod.
3925         * modules/chown (Depends-on): Add stdbool.
3926         * modules/lchown (Depends-on): Likewise.
3927         * doc/posix-functions/chown.texi (chown): Document the bug.
3928         * doc/posix-functions/lchown.texi (lchown): Likewise.
3929         * tests/test-lchown.h (test_chown): Relax test.
3930
3931         mkstemp: avoid conflict with C++ keyword template
3932         * lib/mkdtemp.c (mkdtemp): Change spelling of template.
3933         * lib/mkostemp.c (mkostemp): Likewise.
3934         * lib/mkostemps.c (mkostemps): Likewise.
3935         * lib/mkstemp.c (mkstemp): Likewise.
3936         * lib/mkstemps.c (mkstemps): Likewise.
3937
3938         xalloc-die-tests: optimize
3939         * tests/test-xalloc-die.sh: Reduce number of processes.
3940
3941 2009-11-17  Simon Josefsson  <simon@josefsson.org>
3942
3943         * gnulib-tool: Support LGPLv3+ licenses in module files.  Tiny
3944         patch from ludo@gnu.org (Ludovic Courtès).
3945
3946 2009-11-17  Jim Meyering  <meyering@redhat.com>
3947
3948         version-etc: use proper license string
3949         * modules/version-etc (License): Use LGPL, not LGPLv3+.
3950         * modules/version-etc-fsf: Likewise.
3951
3952 2009-11-17  Simon Josefsson  <simon@josefsson.org>
3953
3954         * tests/test-xalloc-die.sh: Add license.  Check that nothing is
3955         printed to stdout.  Deal with EOL differences.
3956
3957 2009-11-17  Eric Blake  <ebb9@byu.net>
3958
3959         unsetenv: work around Solaris bug
3960         * m4/setenv.m4 (gl_FUNC_UNSETENV): Check for bug.
3961         * lib/unsetenv.c (rpl_unsetenv): Work around it.
3962         Reported by Jim Meyering.
3963
3964         vasnprintf: avoid compiler warnings
3965         * lib/vasnprintf.c (VASNPRINTF): Avoid shadowing our own local
3966         variables.
3967         * lib/printf-args.c (PRINTF_FETCHARGS): Avoid type mismatch.
3968
3969 2009-11-17  Simon Josefsson  <simon@josefsson.org>
3970
3971         * modules/xalloc-die-tests (Makefile.am): Drop XFAIL_TESTS
3972         settings since xalloc-die is no longer the self test,
3973         xalloc-die.sh is.
3974
3975 2009-11-17  Jim Meyering  <meyering@redhat.com>
3976
3977         test-xalloc-die.sh: make the code agree with the commit log
3978         * tests/test-xalloc-die.sh: Put "." at the front of $PATH, not
3979         at the end, just in case you happen to have a test-xalloc-die
3980         program in some other PATH directory.
3981
3982         test-xalloc-die.sh: fix a portability bug
3983         * tests/test-xalloc-die.sh: Do not invoke via ./test-xalloc-die.
3984         Instead, set PATH to start with "." and invoke via "test-xalloc-die".
3985         Otherwise, argv[0] (as often seen in diagnostics) would be too
3986         system-dependent, sometimes with, and sometimes without the leading "./".
3987
3988         version-etc-fsf: relax license to LGPLv3+
3989         * modules/version-etc-fsf (License): Relax license.
3990
3991 2009-11-16  Eric Blake  <ebb9@byu.net>
3992
3993         xalloc-die-tests: avoid printing null pointer
3994         * modules/xalloc-die-tests (Files, Makefile.am): Wrap execution in
3995         shell script.
3996         * tests/test-xalloc-die.c (program_name): Declare.
3997         * tests/test-xalloc-die.sh (tmpfiles): New file.
3998
3999         setenv, unsetenv: work around various bugs
4000         * lib/setenv.c (setenv) [!HAVE_SETENV]: Resync from glibc.
4001         (setenv) [HAVE_SETENV]: Work around bugs.
4002         * lib/unsetenv.c (unsetenv) [HAVE_UNSETENV]: Work around bugs.
4003         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE, gl_FUNC_UNSETENV): Check
4004         for bugs.
4005         (gl_FUNC_SETENV): Write in terms of gl_FUNC_SETENV_SEPARATE.
4006         * m4/environ.m4 (gl_ENVIRON): Avoid expand-before-require.
4007         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Update defaults.
4008         * modules/stdlib (Makefile.am): Update substitutions.
4009         * lib/stdlib.in.h (setenv, unsetenv): Update prototypes.
4010         * doc/posix-functions/setenv.texi (setenv): Document the bugs.
4011         * doc/posix-functions/unsetenv.texi (unsetenv): Likewise.
4012         * modules/setenv-tests: New test.
4013         * modules/unsetenv-tests: Likewise.
4014         * tests/test-setenv.c: New file.
4015         * tests/test-unsetenv.c: Likewise.
4016
4017 2009-11-16  Jim Meyering  <meyering@redhat.com>
4018
4019         version-etc: relax license to LGPLv3+
4020         * modules/version-etc (License): Relax license.
4021
4022         better AC_REQUIRE expanded-before-required-warning avoidance
4023         * m4/chown.m4 (gl_FUNC_CHOWN, gl_FUNC_CHOWN_FOLLOWS_SYMLINK): Define
4024         with AC_DEFUN_ONCE, rather than AC_DEFUN, to avoid AC_REQUIRE warnings.
4025         Suggested by Eric Blake.  This change also reverts commit 1b712ba8,
4026         which is no longer needed.
4027
4028 2009-11-16  Eric Blake  <ebb9@byu.net>
4029
4030         test-freading: clean up temporary file
4031         * tests/test-freading.c (main): Remove file on success, and use
4032         ASSERT more liberally.
4033         Reported by Jim Meyering.
4034
4035 2009-11-16  Jim Meyering  <meyering@redhat.com>
4036
4037         avoid new AC_REQUIRE expanded-before-required warnings
4038         * modules/chown (configure.ac): Require gl_FUNC_CHOWN, rather than
4039         merely using it.
4040         * modules/euidaccess (configure.ac): Likewise for gl_FUNC_EUIDACCESS.
4041         * modules/faccessat (configure.ac): Likewise for gl_FUNC_FACCESSAT.
4042
4043 2009-11-15  Simon Josefsson  <simon@josefsson.org>
4044
4045         * tests/test-xalloc-die.c: New file.
4046         * modules/xalloc-die-tests: New file.
4047         * gnulib-tool (func_emit_tests_Makefile_am): Also initialize
4048         XFAIL_TESTS so it can be appended by modules.
4049
4050 2009-11-15  Simon Josefsson  <simon@josefsson.org>
4051
4052         * lib/gc-pbkdf2-sha1.c: Remove comments from RFC 2898.  Reported
4053         by Vladimir 'phcoder' Serbinenko <phcoder@gmail.com>.
4054
4055 2009-11-14  Eric Blake  <ebb9@byu.net>
4056
4057         fnmatch: avoid compiler warning
4058         * lib/fnmatch_loop.c (NEW_PATTERN): Coerce addition to unsigned,
4059         to silence compiler warning about mismatch signedness in ?:.
4060         Reported by Robert Millan.
4061
4062         intprops: add double-inclusion guard
4063         * lib/intprops.h: Allow idempotent includes.
4064         Suggested by Bruce Korb.
4065
4066         openat: detect Solaris fchownat bug
4067         * lib/fchownat.c (rpl_fchownat): Work around Solaris bug.  Avoid
4068         penalizing glibc chownat when only lchownat is broken.
4069         * m4/openat.m4 (gl_FUNC_FCHOWNAT): Replace fchownat if there are
4070         trailing slash bugs.
4071         * doc/posix-functions/fchownat.texi (fchownat): Document the bug.
4072         * modules/openat-tests (Files): Include more files.
4073         (Depends-on): Add mgetgroups, sleep, stat-time.
4074         (configure.ac): Add additional checks.
4075         (Makefile.am): Build new test.
4076         * tests/test-fchownat.c: New file.
4077
4078         lchown: detect Solaris and FreeBSD bug
4079         * lib/lchown.c (rpl_lchown): Work around bug.
4080         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check for trailing slash bugs.
4081         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
4082         * modules/unistd (Makefile.am): Populate it.
4083         * lib/unistd.in.h (lchown): Update declaration.
4084         * doc/posix-functions/lchown.texi (lchown): Document the bug.
4085         * modules/lchown-tests: New file.
4086         * tests/test-lchown.h (test_lchown): Likewise.
4087         * tests/test-lchown.c (main): Likewise.
4088
4089         chown: detect Solaris and FreeBSD bug
4090         * lib/chown.c (rpl_chown): Work around bug.
4091         * m4/chown.m4 (gl_FUNC_CHOWN): Check for trailing slash bugs.
4092         (gl_PREREQ_CHOWN): Delete.
4093         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
4094         * modules/unistd (Makefile.am): Populate it.
4095         * lib/unistd.in.h (chown): Update declaration.
4096         * lib/lchown.c (chown): Update client.
4097         * modules/lchown (Depends-on): Add lstat.
4098         * doc/posix-functions/chown.texi (chown): Document the bug.
4099         * doc/posix-functions/getgroups.texi (getgroups): Document
4100         getgroups pitfall.
4101         * modules/chown-tests: New file.
4102         * tests/test-chown.h (test_chown): Likewise.
4103         * tests/test-chown.c (main): Likewise.
4104
4105 2009-11-14  Robert Millan  <rmh.grub@aybabtu.com>  (tiny change)
4106
4107         gnulib-tool: correctly detect absence of m4 directories
4108         * gnulib-tool: Avoid extra newline on data passed to wc -l.
4109
4110 2009-11-14  Jim Meyering  <meyering@redhat.com>
4111
4112         maint.mk: Prohibit inclusion of "xalloc.h" without use.
4113         * top/maint.mk (sc_prohibit_close_stream_without_use): New rule.
4114
4115 2009-11-14  John W. Eaton  <jwe@gnu.org>
4116
4117         strftime.h: wrap funtion declaration in extern "C" block
4118         * lib/strftime.h (nstrftime) [__cplusplus]: Wrap declaration.
4119
4120 2009-11-13  Eric Blake  <ebb9@byu.net>
4121
4122         getgroups: avoid compiler warning
4123         * lib/getgroups.c (rpl_getgroups): Delete shadowed variable.
4124
4125         getgroups: work around FreeBSD bug
4126         * lib/getgroups.c (rpl_getgroups): Work around the bug.
4127         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Detect the bug.
4128         * doc/posix-functions/getgroups.texi (getgroups): Document it.
4129         * tests/test-getgroups.c (main): Fix buffer overrun.
4130
4131         getgroups: avoid compilation failure
4132         * lib/getgroups.c (includes): Include <stdint.h> for SIZE_MAX.
4133         * modules/getgroups (Depends-on): Add stdint.
4134
4135 2009-11-13  Jim Meyering  <meyering@redhat.com>
4136
4137         test-getgroups: avoid compilation failure
4138         * tests/test-getgroups.c: Include <stdint.h> for use of SIZE_MAX.
4139
4140 2009-11-13  Eric Blake  <ebb9@byu.net>
4141
4142         mgetgroups: new module, taken from coreutils
4143         * modules/mgetgroups: New file.
4144         * lib/mgetgroups.h: Likewise.
4145         * lib/mgetgroups.c (mgetgroups): Likewise.
4146         * m4/mgetgroups.m4 (gl_MGETGROUPS): Likewise.
4147         * MODULES.html.sh (Users and groups): Mention it.
4148
4149         getgroups: don't expose GETGROUPS_T to user
4150         * lib/getgroups.c (rpl_getgroups): Change signature.  Copy array
4151         an element at a time if GETGROUPS_T is wrong size.
4152         * lib/getugroups.h (getugroups): Change signature.
4153         * lib/unistd.in.h (getgroups): Likewise.
4154         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Use replacement if
4155         signature needs fixing.
4156         * m4/getugroups.m4 (gl_GETUGROUPS): No longer need
4157         AC_TYPE_GETGROUPS.
4158         * modules/group-member (Depends-on): Add getgroups.
4159         * lib/group-member.c (group_info, get_group_info): Use gid_t.
4160         (group_member): Rely on getgroups replacement.
4161         * lib/getugroups.c (getugroups): Use gid_t.
4162         * tests/test-getgroups.c (main): Likewise.
4163         * NEWS: Mention the signature change.
4164         * doc/posix-functions/getgroups.texi (getgroups): Mention the
4165         problem with signature.
4166         * doc/glibc-functions/setgroups.texi (setgroups): Mention that
4167         GETGROUPS_T is still useful for setgroups.
4168
4169         getgroups, getugroups: provide stubs for mingw
4170         * lib/getgroups.c (getgroups): Provide ENOSYS stub for mingw.
4171         * lib/getugroups.c (getugroups): Likewise.
4172         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Check for missing
4173         function.  Modernize replacement scheme.
4174         (gl_PREREQ_GETGROUPS): Delete.
4175         * m4/getugroups.m4 (gl_GETUGROUPS): Check for <grp.h>.
4176         * modules/getgroups (configure.ac): Declare witness.
4177         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add default.
4178         * modules/unistd (Depends-on): Substitute witness.
4179         * lib/unistd.in.h (getgroups): Declare replacement.
4180
4181         getgroups: avoid calling exit
4182         * modules/getgroups (Depends-on): Add malloc-posix and unistd,
4183         drop xalloc.
4184         * modules/getgroups-tests (Depends-on, Makefile.am): Drop unneeded
4185         dependencies.
4186         * lib/getgroups.c (rpl_getgroups): Fail with ENOMEM rather than
4187         exiting, in the rare case of malloc failure.
4188
4189         getgroups: fix logic error
4190         * lib/getgroups.c (rpl_getgroups): Don't fail if current process
4191         has more than 20 groups.
4192         * modules/getgroups-tests: New test.
4193         * tests/test-getgroups.c: New file.
4194
4195 2009-11-13  Simon Josefsson  <simon@josefsson.org>
4196
4197         * tests/test-base64.c: Improve.
4198
4199 2009-11-13  Simon Josefsson  <simon@josefsson.org>
4200
4201         * tests/test-xvasprintf.c: Fix memory leak, suggested by Eric
4202         Blake <ebb9@byu.net>.
4203
4204 2009-11-13  Simon Josefsson  <simon@josefsson.org>
4205
4206         * tests/test-xvasprintf.c: Add %s%s related checks.
4207
4208 2009-11-12  Eric Blake  <ebb9@byu.net>
4209
4210         version-etc: match standards.texi style
4211         * lib/version-etc.c (emit_bug_reporting_address): Drop periods,
4212         and use <> only for URLs.
4213
4214 2009-11-10  Kamil Dudka  <kdudka@redhat.com>
4215
4216         fts: do not fail on a submount during traversal
4217         * lib/fts.c (fts_build): Read the stat info again after opening
4218         a directory if the FTS_TIGHT_CYCLE_CHECK flag is set.
4219         Original report at http://bugzilla.redhat.com/501848.
4220
4221 2009-11-12  Jim Meyering  <meyering@redhat.com>
4222
4223         bootstrap: sync from coreutils
4224         * build-aux/bootstrap (bootstrap_epilogue): New function.
4225         Use git_modules_config in one more place.  This make bootstrap's
4226         --gnulib-srcdir option more useful for testing.
4227
4228         bootstrap: generalize autoheader check
4229         * build-aux/bootstrap: Look for AC_CONFIG_HEADER as well as
4230         AC_CONFIG_HEADERS.
4231
4232 2009-11-11  Eric Blake  <ebb9@byu.net>
4233
4234         mkfifoat: use new modules for Solaris and BSD bugs
4235         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Simplify.
4236         * lib/mkfifoat.c (mknodat): Split...
4237         * lib/mknodat.c (mknodat): ...into new file.
4238         * modules/mkfifoat (Files): Ship new file.
4239         (Depends-on): Add mkfifo, mknod.
4240         * modules/mkfifoat-tests (Files): Reuse mkfifo tests.
4241         (Depends-on): Add symlink.
4242         * tests/test-mkfifoat.c (main): Enhance test.  Drop portions now
4243         redundant with test_mkfifo.h.
4244         (do_mkfifoat, do_mknodat): New helpers.
4245
4246         mknod: new module
4247         * modules/mknod: New file.
4248         * m4/mknod.m4 (gl_FUNC_MKNOD): Likewise.
4249         * lib/mknod.c (mknod): Likewise.
4250         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Set witness
4251         defaults.
4252         * modules/sys_stat (Makefile.am): Substitute them.
4253         * lib/sys_stat.in.h (mknod): Declare replacement.
4254         * MODULES.html.sh (Support for systems lacking POSIX:2008):
4255         Document it.
4256         * doc/posix-functions/mknod.texi (mknod): Likewise.
4257         * modules/mknod-tests: New test.
4258         * tests/test-mknod.c: Likewise.
4259
4260         mkfifo: new module
4261         * modules/mkfifo: New file.
4262         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Likewise.
4263         * lib/mkfifo.c (mkfifo): Likewise.
4264         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Set witness
4265         defaults.
4266         * modules/sys_stat (Makefile.am): Substitute them.
4267         * lib/sys_stat.in.h (mkfifo): Declare replacement.
4268         * MODULES.html.sh (Support for systems lacking POSIX:2008):
4269         Document it.
4270         * doc/posix-functions/mkfifo.texi (mkfifo): Likewise.
4271         * modules/mkfifo-tests: New test.
4272         * tests/test-mkfifo.h (test_mkfifo): New file, borrowed in part
4273         from test-mkfifoat.c.
4274         * tests/test-mkfifo.c: New file.
4275
4276         readlink: detect FreeBSD bug
4277         * m4/readlink.m4 (gl_FUNC_READLINK): Also detect FreeBSD bug with
4278         slash on symlink.
4279         * doc/posix-functions/readlink.texi (readlink): Document the bug.
4280         * tests/test-readlink.h (test_readlink): Enhance test.
4281
4282         symlink: detect FreeBSD bug
4283         * m4/symlink.m4 (gl_FUNC_SYMLINK): Also detect FreeBSD bug with
4284         slash on symlink.
4285         * doc/posix-functions/symlink.texi (symlink): Document the bug.
4286         * tests/test-symlink.h (test_symlink): Enhance test.
4287
4288 2009-11-10  Eric Blake  <ebb9@byu.net>
4289
4290         link: detect FreeBSD bug
4291         * m4/link.m4 (gl_FUNC_LINK): Also detect FreeBSD bug with slash on
4292         symlink.
4293         * doc/posix-functions/link.texi (link): Document the bug.
4294         * tests/test-link.h (test_link): Enhance test.
4295         * tests/test-linkat.c (main): Update caller.
4296
4297         unlink, remove: detect FreeBSD bug
4298         * m4/unlink.m4 (gl_FUNC_UNLINK): Also detect FreeBSD bug with
4299         slash on symlink.
4300         * doc/posix-functions/unlink.texi (unlink): Document the bug.
4301         * doc/posix-functions/remove.texi (remove): Likewise.
4302         * tests/test-unlink.h (test_unlink): Enhance test.
4303         * tests/test-remove.c (main): Likewise.
4304
4305 2009-11-09  Eric Blake  <ebb9@byu.net>
4306
4307         rename: detect FreeBSD bug
4308         * m4/rename.m4 (gl_FUNC_RENAME): Also detect FreeBSD bug with
4309         slash on symlink.
4310         * modules/renameat-tests (Depends-on): Add filenamecat.
4311         * tests/test-rename.h (test_rename): Allow one more errno.
4312         * tests/test-renameat.c (main): Likewise.
4313         * doc/posix-functions/rename.texi (rename): Document the bug.
4314
4315         open: detect FreeBSD bug
4316         * m4/open.m4 (gl_FUNC_OPEN): Also detect FreeBSD bug with slash on
4317         symlink.
4318         * doc/posix-functions/open.texi (open): Document the bug.
4319         * doc/posix-functions/utimes.texi (utimes): Likewise.
4320         * tests/test-open.h (test_open): Add parameters, and test symlink
4321         handling.
4322         * tests/test-open.c (main): Adjust caller.
4323         * tests/test-fcntl-safer.c (main): Likewise.
4324         * modules/open-tests (Depends-on): Add stdbool, symlink.
4325         * modules/fcntl-safer-tests (Depends-on): Likewise.
4326         * tests/test-openat.c (main): Add test-open tests.
4327
4328         stat: detect FreeBSD bug
4329         * m4/stat.m4 (gl_FUNC_STAT): Also detect FreeBSD bug with slash on
4330         symlink.
4331         * doc/posix-functions/stat.texi (stat): Document the bug.
4332         * tests/test-stat.h (test_stat_func): Add argument.
4333         * tests/test-stat.c (main): Adjust caller.
4334         * tests/test-fstatat.c (main): Likewise.
4335         * modules/stat-tests (Depends-on): Add stdbool, symlink.
4336         Reported by Jim Meyering.
4337
4338 2009-11-09  James Youngman  <jay@gnu.org>
4339
4340         strftime.c: include ignore-value.h only when FPRINTFTIME is defined
4341         * lib/strftime.c: Correct placement of #include "ignore-value.h".
4342
4343 2009-11-08  Jim Meyering  <meyering@redhat.com>
4344
4345         utimens: remove invalid futimesat call
4346         * lib/utimens.c (fdutimens): Remove invalid futimesat call.
4347         It used the file descriptor of the target file as the DIR_FD
4348         parameter and NULL as the file name.  That caused failure with
4349         errno == EFAULT on FreeBSD-8.0-rc2
4350
4351 2009-11-07  Eric Blake  <ebb9@byu.net>
4352
4353         fflush, freadseek: use fseeko, not fseek
4354         * lib/fflush.c (clear_ungetc_buffer_preserving_position)
4355         (clear_ungetc_buffer): Avoid potential problems on large files.
4356         * lib/freadseek.c (freadseek): Likewise.
4357         * modules/freadseek (Depends-on): Add fseeko.
4358         * modules/fseek (configure.ac): Set a witness.
4359         * tests/test-fflush.c (main): Use fseeko.
4360         * tests/test-fpurge.c (fseek): Disable link warning.
4361         * tests/test-freadable.c (fseek): Likewise.
4362         * tests/test-freading.c (fseek): Likewise.
4363         * tests/test-fseeko.c (fseek): Likewise.
4364         * tests/test-ftell.c (fseek): Likewise.
4365         * tests/test-ftello.c (fseek): Likewise.
4366         * tests/test-fwritable.c (fseek): Likewise.
4367         * tests/test-fwriting.c (fseek): Likewise.
4368
4369 2009-11-06  Simon Josefsson  <simon@josefsson.org>
4370
4371         * modules/memchr (Depends-on): Drop getpagesize dependency.
4372
4373 2009-11-06  Simon Josefsson  <simon@josefsson.org>
4374
4375         * build-aux/pmccabe2html: Disable execute bit.  Suggested by
4376         Reported by Ludovic Courtès.
4377         * build-aux/pmccabe2html: Improve example usage.
4378         * build-aux/pmccabe2html: Drop #! header.  Doc fix.
4379
4380 2009-11-06  Jim Meyering  <meyering@redhat.com>
4381
4382         do-release-commit-and-tag: New module.
4383         Automate the release-commit and tag process.
4384         * build-aux/do-release-commit-and-tag: New script, from coreutils.
4385         * modules/do-release-commit-and-tag: New file.
4386         * MODULES.html.sh (Support for maintaining and releasing): Add it.
4387
4388 2009-11-06  Simon Josefsson  <simon@josefsson.org>
4389
4390         * modules/select-tests (test_select_LDADD): Add $(INET_PTON_LIB)
4391         because test-select.c uses inet_pton.
4392
4393 2009-11-06  Simon Josefsson  <simon@josefsson.org>
4394
4395         * m4/getaddrinfo.m4: Add content of INET_NTOP_LIB to
4396         GETADDRINFO_LIB.  Bump serial number.
4397         * modules/getaddrinfo (Link): Only mention GETADDRINFO_LIB again.
4398         Suggested by Eric Blake <ebb9@byu.net>.
4399
4400 2009-11-05  Eric Blake  <ebb9@byu.net>
4401
4402         strtod: detect darwin bug
4403         * m4/strtod.m4 (gl_FUNC_STRTOD): Filter out darwin bug on "nan(".
4404         Reported by Leo Davis.
4405
4406         freopen-safer: new module
4407         * modules/freopen-safer: New module.
4408         * m4/stdio-safer.m4 (gl_FREOPEN_SAFER): New macro.
4409         * lib/freopen-safer.c (freopen_safer): New file.
4410         * lib/stdio-safer.h (freopen_safer): New declaration.
4411         * lib/stdio--.h (freopen): New override.
4412         * MODULES.html.sh (File stream based Input/Output): Mention it.
4413         * doc/posix-functions/freopen.texi (freopen): Mention pitfalls and
4414         freopen-safer module.
4415         * doc/posix-functions/stderr.texi (stderr): Likewise.
4416         * doc/posix-functions/stdin.texi (stdin): Likewise.
4417         * doc/posix-functions/stdout.texi (stdout): Likewise.
4418         * modules/freopen-safer-tests: New test.
4419         * tests/test-reopen-safer.c: New file.
4420
4421 2009-11-05  Jim Meyering  <meyering@redhat.com>
4422
4423         maint.mk: Prohibit inclusion of "close-stream.h" without use.
4424         * top/maint.mk (sc_prohibit_close_stream_without_use): New rule.
4425
4426 2009-11-05  Simon Josefsson  <simon@josefsson.org>
4427
4428         * modules/pmccabe2html (configure.ac): Check for pmccabe tool.
4429
4430 2009-11-05  Simon Josefsson  <simon@josefsson.org>
4431
4432         * modules/getaddrinfo (Link): Add $(INET_NTOP_LIB).
4433
4434 2009-11-05  Simon Josefsson  <simon@josefsson.org>
4435
4436         Fix link error.
4437         * m4/inet_ntop.m4 (gl_INET_NTOP): Fix test of AC_SEARCH_LIBS result.
4438         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
4439
4440 2009-11-05  Simon Josefsson  <simon@josefsson.org>
4441
4442         * tests/test-func.c: Also test value of __func__.
4443
4444 2009-11-05  Simon Josefsson  <simon@josefsson.org>
4445
4446         * tests/test-sys_socket.c: Use smaller constant value, sa_family_t
4447         may be an 8-bit type.  Reported by Bruno Haible <bruno@clisp.org>.
4448
4449 2009-11-05  Bruno Haible  <bruno@clisp.org>
4450
4451         Fix link error.
4452         * m4/inet_ntop.m4 (gl_INET_NTOP): Fix test of AC_SEARCH_LIBS result.
4453         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
4454         Reported by Brad Hards <bradh@frogmouth.net> via Simon Josefsson.
4455
4456 2009-11-05  Bruno Haible  <bruno@clisp.org>
4457
4458         Tests for module 'inet_pton'.
4459         * modules/inet_pton-tests: New file.
4460         * tests/test-inet_pton.c: New file.
4461
4462 2009-11-05  Bruno Haible  <bruno@clisp.org>
4463
4464         Tests for module 'inet_ntop'.
4465         * modules/inet_ntop-tests: New file.
4466         * tests/test-inet_ntop.c: New file.
4467
4468 2009-11-04  Eric Blake  <ebb9@byu.net>
4469
4470         stdlib-safer: wrap all mkstemp variants
4471         * modules/mkostemp (configure.ac): Set witness.
4472         * modules/mkostemps (configure.ac): Likewise.
4473         * modules/mkstemps (configure.ac): Likewise.
4474         * lib/stdlib-safer.h (mkostemp_safer, mkostemps_safer)
4475         (mkstemps_safer): Wrap more functions.
4476         * lib/stdlib--.h (mkostemp, mkostemps, mkstemps): Default the
4477         wrapping.
4478         * lib/mkstemp-safer.c (mkostemp_safer, mkostemps_safer)
4479         (mkstemps_safer): Implement the wrappers.
4480
4481         mkstemps, mkostemps: new modules
4482         * modules/mkostemps: New module.
4483         * modules/mkstemps: Likewise.
4484         * lib/mkostemps.c (mkostemps): New file.
4485         * lib/mkstemps.c (mkstemps): Likewise.
4486         * m4/mkostemps.m4 (gl_FUNC_MKOSTEMPS): Likewise.
4487         * m4/mkstemps.m4 (gl_FUNC_MKSTEMPS): Likewise.
4488         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Add witnesses.
4489         * modules/stdlib (Makefile.am): Substitute them.
4490         * lib/stdlib.in.h (mkostemps, mkstemps): Declare them.
4491         * doc/glibc-functions/mkstemps.texi (mkstemps): New file.
4492         * doc/glibc-functions/mkostemps.texi (mkostemps): Likewise.
4493         * doc/gnulib.texi (Glibc stdlib.h): Include them.
4494         * MODULES.html.sh (File system functions): Mention them.
4495
4496         tempname: resync from glibc
4497         * lib/tempname.c (__gen_tempname): Add suffixlen argument.  Use
4498         same values for __GT_FILE as glibc.  Abort even when assertions
4499         are disabled.
4500         * lib/tempname.h (GT_FILE): Use glibc __GT_FILE, if available, and
4501         match its value otherwise.  Allow idempotent inclusion.
4502         * lib/mkdtemp.c (mkdtemp): Adjust caller.
4503         * lib/mkostemp.c (mkostemp): Likewise.
4504         * lib/mkstemp.c (mkstemp): Likewise.
4505         * lib/tmpfile.c (tmpfile): Likewise.
4506         * NEWS: Document this.
4507
4508         utimens: fix use of futimens on older Linux
4509         * lib/utimens.c (fdutimens): Use updated, rather than original,
4510         timespec to avoid bug in older Linux kernel.
4511         Reported by Simon Josefsson.
4512
4513 2009-11-04  Bruno Haible  <bruno@clisp.org>
4514
4515         Make num_processors more flexible and consistent.
4516         * lib/nproc.h (enum nproc_query): New type.
4517         (num_processors): Add a 'query' argument.
4518         * lib/nproc.c: Include <stdlib.h>, <sched.h>, c-ctype.h.
4519         (num_processors): Add a 'query' argument. Test the value of the
4520         OMP_NUM_THREADS environment variable if requested. On Linux, NetBSD,
4521         mingw, count the number of CPUs available for the current process.
4522         * m4/nproc.m4 (gl_PREREQ_NPROC): Require AC_USE_SYSTEM_EXTENSIONS.
4523         Check for sched_getaffinity and sched_getaffinity_np.
4524         * modules/nproc (Depends-on): Add c-ctype, extensions.
4525         * NEWS: Mention the change.
4526
4527 2009-11-03  Bruno Haible  <bruno@clisp.org>
4528
4529         * NEWS: Document the new library dependencies of inet_ntop, inet_pton.
4530
4531 2009-11-03  Jim Meyering  <meyering@redhat.com>
4532
4533         test-getaddrinfo: avoid compilation failure on FreeBSD 7.2
4534         * tests/test-getaddrinfo.c (simple): Test for EAI_NODATA only
4535         if it is defined.
4536
4537 2009-11-02  Eric Blake  <ebb9@byu.net>
4538
4539         mktime, timegm: share common declaration
4540         * lib/mktime-internal.h: New file.
4541         * lib/mktime.c: Use it rather than open-coding a declaration.
4542         * lib/timegm.c: Likewise.
4543         * modules/mktime (Files): Ship it.
4544         * modules/timegm (Files): Likewise.
4545         Suggested by Bruno Haible.
4546
4547         test-update-copyright: update test to match script changes
4548         * tests/test-update-copyright.sh: Avoid hard-coding perl
4549         location.  Don't update *.bak created by earlier runs.
4550
4551 2009-11-02  Paul Eggert  <eggert@cs.ucla.edu>
4552             Simon Josefsson  <simon@josefsson.org>
4553             Bruno Haible  <bruno@clisp.org>
4554
4555         Fix link error on Solaris 8.
4556         * m4/inet_pton.m4 (gl_INET_PTON): Search for the function inet_pton
4557         also in libnsl. Define also INET_PTON_LIB.
4558         * modules/inet_pton (Link): New section.
4559
4560 2009-11-02  Simon Josefsson  <simon@josefsson.org>
4561             Bruno Haible  <bruno@clisp.org>
4562
4563         * m4/inet_ntop.m4 (gl_INET_NTOP): Define also INET_NTOP_LIB.
4564         * modules/inet_ntop (Link): New section.
4565         Reported by Boyan Kasarov <bkasarov@gmail.com>.
4566
4567 2009-11-02  Eric Blake  <ebb9@byu.net>
4568
4569         maint: avoid compiler warnings in m4 macros
4570         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Avoid unused variable.
4571         * m4/rmdir.m4 (gl_FUNC_RMDIR): Include correct header.
4572
4573 2009-11-02  Simon Josefsson  <simon@josefsson.org>
4574
4575         * m4/pmccabe2html.m4: Remove file.
4576         * modules/pmccabe2html: Drop pmccabe2html.m4.  Don't call m4
4577         function.  Change maintainer.
4578         * build-aux/pmccabe2html: Use /bin/sh with magic instead of
4579         hard-coding path to awk.  Tiny patch from ludo@gnu.org (Ludovic
4580         Courtès).
4581
4582 2009-10-31  Eric Blake  <ebb9@byu.net>
4583
4584         fseeko: fix m4 regression
4585         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Use modern macro.  Fixes
4586         regression from 2009-10-27.
4587         Reported by Ralf Wildenhues.
4588
4589 2009-10-31  Jim Meyering  <meyering@redhat.com>
4590
4591         inttostr: aesthetics and improved (compile-time) safety
4592         Define inttype_is_signed rather than inttype_is_unsigned,
4593         since the sole use is via "#if inttype_is_signed".
4594         * lib/imaxtostr.c (inttype_is_signed): Define this, rather than
4595         inttype_is_unsigned.
4596         * lib/offtostr.c (inttype_is_signed): Likewise.
4597         * lib/uinttostr.c (inttype_is_signed): Likewise.
4598         * lib/umaxtostr.c (inttype_is_signed): Likewise.
4599         * lib/inttostr.c (inttostr): Use verify to cross-check the
4600         inttype_is_signed value and the signedness of the actual type.
4601         * modules/inttostr (Depends-on): Add verify.
4602
4603 2009-10-30  Eric Blake  <ebb9@byu.net>
4604
4605         build: avoid compiler warnings
4606         * lib/fchmodat.c (lchmod): Mark unused variables.
4607         * lib/getopt.c (_getopt_initialize): Likewise.
4608         * lib/mktime.c (__mktime_internal): Provide prototype.
4609         * lib/inttostr.c (inttostr): Avoid compiler warning even with
4610         older gcc that do not understand #pragma GCC diagnostic.
4611         * lib/uinttostr.c (inttype_is_unsigned): Define.
4612         * lib/umaxtostr.c (inttype_is_unsigned): Likewise.
4613
4614 2009-10-30  Michael Haubenwallner  <michael.haubenwallner@salomon.at>
4615
4616         stat: fix compilation on AIX
4617         * lib/sys_stat.in.h (stat): Work with fact that large files on AIX
4618         only see struct stat64.
4619
4620 2009-10-30  Eric Blake  <ebb9@byu.net>
4621
4622         exclude: make more robust
4623         * lib/exclude.c (excluded_file_name): Abort on unexpected value,
4624         rather than masking a coding bug.
4625         Suggested by Bruno Haible.
4626
4627 2009-10-30  Jim Meyering  <meyering@redhat.com>
4628
4629         perl scripts: remove #!/usr/bin/perl in favor of more portable...
4630         Rather than putting #!/usr/bin/perl on the first line,
4631         start with a variant of what's recommended by "man perlrun" that
4632         invokes the first "perl" program from your shell's search path.
4633         * build-aux/gitlog-to-changelog: Replace #!... as above.
4634         Add a "Local Variables" perl mode setting.
4635         Prompted by a patch from Ludovic Courtès.
4636         Improved by Eric Blake.
4637         * build-aux/useless-if-before-free: Likewise.
4638         * build-aux/announce-gen: Likewise.
4639         * build-aux/update-copyright: Likewise.
4640
4641 2009-10-29  Eric Blake  <ebb9@byu.net>
4642
4643         filenamecat-lgpl: adjust clients
4644         * modules/linkat (Depends-on): Use filenamecat-lgpl, not
4645         filenamecat.
4646         * modules/renameat (Depends-on): Likewise.
4647
4648         filenamecat: split into filenamecat-lgpl
4649         * modules/filenamecat-lgpl: New module.
4650         * modules/filenamecat (Files): Move library-safe files into
4651         filenamecat-lgpl.
4652         (Depends-on): Add filenamecat-lgpl.
4653         (configure.ac): Declare witness.
4654         * lib/filenamecat.h (file_name_concat): Only declare when using
4655         GPL module.
4656         * lib/filenamecat.c (longest_relative_suffix, mfile_name_concat):
4657         Move...
4658         * lib/filenamecat-lgpl.c: ...into new file.
4659         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT_LGPL): New macro.
4660         (gl_FILE_NAME_CONCAT): Use it.
4661         * MODULES.html.sh (File system functions): Mention new module.
4662
4663         argp: avoid memory leak
4664         * modules/argp (Depends-on): Use dirname-lgpl, not dirname.
4665         * lib/argp-namefrob.h (__argp_base_name): Use last_component, not
4666         base_name, since the latter malloc()s and can call exit().
4667         Leak introduced 2006-07-03.
4668
4669         dirname-lgpl: adjust clients that don't need full dirname
4670         * modules/backupfile (Depends-on): Use dirname-lgpl, not dirname.
4671         * modules/filenamecat (Depends-on): Likewise.
4672         * modules/linkat (Depends-on): Likewise.
4673         * modules/mkancesdirs (Depends-on): Likewise.
4674         * modules/mkdir (Depends-on): Likewise.
4675         * modules/openat (Depends-on): Likewise.
4676         * modules/savewd (Depends-on): Likewise.
4677         * modules/rename (Depends-on): Likewise.
4678         (License): Relax license.
4679         * modules/mkdir-tests (Depends-on): Drop progname.
4680         (Makefile.am): Delete unneeded LDADD.
4681         * modules/rename-tests (Depends-on, Makefile.am): Likewise.
4682
4683         dirname: split into dirname-lgpl
4684         * modules/dirname-lgpl: New module.
4685         * modules/dirname (Files): Move library-safe files into
4686         dirname-lgpl.
4687         (Depends-on): Add dirname-lgpl.
4688         (configure.ac): Declare witness.
4689         * modules/double-slash-root (License): Relax license.
4690         * lib/dirname.h (base_name, dir_name): Only declare when using GPL
4691         module.
4692         * lib/dirname.c (dir_len, mdir_name): Move...
4693         * lib/dirname-lgpl.c: ...into new file.
4694         * lib/basename.c (last_component, base_len): Move...
4695         * lib/basename-lgpl.c: ...into new file.
4696         * m4/dirname.m4 (gl_DIRNAME_LGPL): New macro.
4697         (gl_DIRNAME): Use it.
4698         * MODULES.html.sh (Enhancements for POSIX:2008 functions):
4699         Mention new module.
4700         * modules/dirname-tests (Depends-on): Add progname.
4701         * tests/test-dirname.c (program_name): Delete.
4702
4703         mkdir: make safe for libraries
4704         * modules/mkdir (Depends-on): Drop xalloc.
4705         * lib/mkdir.c (rpl_mkdir): Fail with ENOMEM rather than calling
4706         exit.
4707
4708         tests: avoid some compiler warnings
4709         * tests/test-getaddrinfo.c (simple): Mark static, and allow string
4710         literals.
4711         * tests/test-memchr.c (main): Avoid type mismatch.
4712         * tests/test-arpa_inet.c (main): Avoid unused parameters.
4713         * tests/test-base64.c (main): Likewise.
4714         * tests/test-getdelim.c (main): Likewise.
4715         * tests/test-gethostname.c (main): Likewise.
4716         * tests/test-getline.c (main): Likewise.
4717         * tests/test-netinet_in.c (main): Likewise.
4718         * tests/test-select.c (open_server_socket, main): Likewise.
4719         * tests/test-select-stdin.c (main): Likewise.
4720         * tests/test-sockets.c (main): Likewise.
4721         * tests/test-strsignal.c (main): Likewise.
4722         * tests/test-sys_select.c (main): Likewise.
4723         * tests/test-sys_socket.c (main): Likewise.
4724         * tests/test-u64.c (main): Likewise.
4725         * tests/test-xfprintf-posix.c (main): Likewise.
4726         * tests/test-xvasprintf.c (test_xvasprintf, main): Likewise.
4727
4728         sockets: avoid compiler warning
4729         * lib/sockets.c (gl_sockets_startup): Mark unused parameter.
4730
4731         maint: detect usage(1) and other suspicious exits
4732         * top/maint.mk (sc_prohibit_magic_number_exit): New rule.
4733
4734 2009-10-29  Jim Meyering  <meyering@redhat.com>
4735
4736         timespec: long-to-int truncation could make timespec_cmp malfunction
4737         * lib/timespec.h (timespec_cmp): Do not interpret a difference of
4738         a multiple of 2^32 nanoseconds as no difference.
4739
4740 2009-10-28  Jim Meyering  <meyering@redhat.com>
4741
4742         fprintftime: wrap macro code argument in "do {...} while(0)"
4743         * lib/strftime.c (cpy) [FPRINTFTIME]: The second argument to the
4744         cpy macro must be a statement that can be followed by a semicolon.
4745         Now that the else clause contains a comment and is hence longer
4746         than one line, I require curly braces.  That in turn requires
4747         that we wrap this code block in the standard do...while(0).
4748
4749         fprintftime: remove stray semicolon from previous change
4750         * lib/strftime.c (cpy) [FPRINTFTIME]: Remove trailing semicolon.
4751
4752         fprintftime: avoid a warning about ignored fwrite return value
4753         * lib/strftime.c [FPRINTFTIME]: Include "ignore-value.h".
4754         (cpy) [FPRINTFTIME]: Ignore fwrite failure, even though technically,
4755         that is unsafe.
4756         * modules/fprintftime (Depends-on): Add ignore-value.
4757
4758         exclude: avoid an unwarranted warning
4759         * lib/exclude.c (excluded_file_name): Initialize "rc" before switch.
4760
4761 2009-10-27  Eric Blake  <ebb9@byu.net>
4762
4763         fseek: avoid compilation failure when fflush is replaced
4764         * m4/fseek.m4 (gl_REPLACE_FSEEK): New macro.
4765         * m4/fseeko.m4 (gl_REPLACE_FSEEKO): Also replace fseek, if fseek
4766         module is in use.
4767         * lib/stdio.in.h (GNULIB_FSEEKO): Only poison fseek if fseek
4768         module is not in use; since REPLACE_FSEEK worked otherwise.
4769         (GNULIB_FTELLO): Likewise for ftell.
4770         Reported by Ian Beckwith and others.
4771
4772 2009-10-27  Bruno Haible  <bruno@clisp.org>
4773
4774         * lib/isnan.c (rpl_isnan[fdl]): Repeat the specification declaration.
4775         Reported by Jim Meyering.
4776
4777 2009-10-27  Jim Meyering  <jim@meyering.net>
4778             Bruno Haible  <bruno@clisp.org>
4779
4780         Avoid warning despite dropping the return value of fwrite.
4781         * lib/unicodeio.c: Include ignore-value.h.
4782         (fwrite_success_callback): Explicitly ignore fwrite's return value.
4783         * modules/unicodeio (Depends-on): Add ignore-value.
4784
4785 2009-10-26  Eric Blake  <ebb9@byu.net>
4786
4787         areadlinkat: fix fallback path
4788         * lib/at-func.c (AT_FUNC_NAME): Avoid signed comparison between
4789         pointer and zero.
4790
4791 2009-10-22  Pádraig Brady  <P@draigBrady.com>
4792
4793         Use a better IO block size for modern systems
4794         * lib/copy-file.c (copy_file_preserving): Used a 32KiB malloced buffer.
4795         * lib/md2.c: Likewise.
4796         * lib/md4.c: Likewise.
4797         * lib/md5.c: Likewise.
4798         * lib/sha1.c: Likewise.
4799         * lib/sha256.c: Likewise.
4800         * lib/sha512.c: Likewise.
4801
4802 2009-10-22  Eric Blake  <ebb9@byu.net>
4803
4804         tests: avoid several compiler warnings
4805         * tests/test-getcwd.c (main): Avoid buffer underflow.
4806         * tests/test-getdate.c (main): String literals are not safe with
4807         putenv, so use setenv.  Declare unused argument.
4808         * modules/getdate-tests (Depends-on): Add setenv.
4809         * tests/test-argv-iter.c (main): Declare unused argument.  Avoid
4810         problems with string literals in char *.
4811         * tests/test-hash.c (main): Avoid shadowing declaration.
4812         (insert_new): Treat string literals as char const *.
4813         * tests/test-getopt.h (test_getopt): Likewise.
4814         (getopt_loop): Alter types to minimize casting elsewhere.
4815         * tests/test-getopt_long.h (test_getopt_long, getopt_long_loop)
4816         (test_getopt_long_posix): Likewise.
4817         (do_getopt_long): Add wrapper to minimize casting.
4818         * tests/test-atexit.c (clear_temp_file): Use void.
4819         * tests/test-areadlink-with-size.c (main): Declare unused
4820         arguments.
4821         * tests/test-areadlink.c (main): Likewise.
4822         * tests/test-areadlinkat-with-size.c (main): Likewise.
4823         * tests/test-areadlinkat.c (main): Likewise.
4824         * tests/test-canonicalize-lgpl.c (main): Likewise.
4825         * tests/test-canonicalize.c (main): Likewise.
4826         * tests/test-dirent-safer.c (main): Likewise.
4827         * tests/test-dirname.c (main): Likewise.
4828         * tests/test-dup2.c (main): Likewise.
4829         * tests/test-fchdir.c (main): Likewise.
4830         * tests/test-fcntl-h.c (main): Likewise.
4831         * tests/test-fcntl-safer.c (main): Likewise.
4832         * tests/test-fdopendir.c (main): Likewise.
4833         * tests/test-fdutimensat.c (main): Likewise.
4834         * tests/test-fflush.c (main): Likewise.
4835         * tests/test-filenamecat.c (main): Likewise.
4836         * tests/test-filevercmp.c (main): Likewise.
4837         * tests/test-fopen-safer.c (main): Likewise.
4838         * tests/test-fopen.c (main): Likewise.
4839         * tests/test-fpending.c (main): Likewise.
4840         * tests/test-fpurge.c (main): Likewise.
4841         * tests/test-freading.c (main): Likewise.
4842         * tests/test-fstatat.c (main): Likewise.
4843         * tests/test-fsync.c (main): Likewise.
4844         * tests/test-futimens.c (main): Likewise.
4845         * tests/test-getndelim2.c (main): Likewise.
4846         * tests/test-gettimeofday.c (main): Likewise.
4847         * tests/test-getopt.c (main): Likewise.
4848         * tests/test-i-ring.c (main): Likewise.
4849         * tests/test-inttypes.c (main): Likewise.
4850         * tests/test-link.c (main): Likewise.
4851         * tests/test-lstat.c (main): Likewise.
4852         * tests/test-math.c (main): Likewise.
4853         * tests/test-md5.c (main): Likewise.
4854         * tests/test-memchr2.c (main): Likewise.
4855         * tests/test-memrchr.c (main): Likewise.
4856         * tests/test-mkdir.c (main): Likewise.
4857         * tests/test-mkdirat.c (main): Likewise.
4858         * tests/test-mkfifoat.c (main): Likewise.
4859         * tests/test-open.c (main): Likewise.
4860         * tests/test-openat-safer.c (main): Likewise.
4861         * tests/test-openat.c (main): Likewise.
4862         * tests/test-quotearg.c (main): Likewise.
4863         * tests/test-rawmemchr.c (main): Likewise.
4864         * tests/test-readlink.c (main): Likewise.
4865         * tests/test-remove.c (main): Likewise.
4866         * tests/test-rename.c (main): Likewise.
4867         * tests/test-renameat.c (main): Likewise.
4868         * tests/test-rmdir.c (main): Likewise.
4869         * tests/test-sha1.c (main): Likewise.
4870         * tests/test-signal.c (main): Likewise.
4871         * tests/test-sigaction.c (main): Likewise.
4872         * tests/test-stat.c (main): Likewise.
4873         * tests/test-stat-time.c (main): Likewise.
4874         * tests/test-stddef.c (main): Likewise.
4875         * tests/test-stdint.c (main): Likewise.
4876         * tests/test-stdio.c (main): Likewise.
4877         * tests/test-stdlib.c (main): Likewise.
4878         * tests/test-strchrnul.c (main): Likewise.
4879         * tests/test-strerror.c (main): Likewise.
4880         * tests/test-string.c (main): Likewise.
4881         * tests/test-strtod.c (main): Likewise.
4882         * tests/test-strverscmp.c (main): Likewise.
4883         * tests/test-symlink.c (main): Likewise.
4884         * tests/test-symlinkat.c (main): Likewise.
4885         * tests/test-sys_stat.c (main): Likewise.
4886         * tests/test-sys_time.c (main): Likewise.
4887         * tests/test-time.c (main): Likewise.
4888         * tests/test-unistd.c (main): Likewise.
4889         * tests/test-unlink.c (main): Likewise.
4890         * tests/test-unlinkat.c (main): Likewise.
4891         * tests/test-utimens.c (main): Likewise.
4892         * tests/test-utimensat.c (main): Likewise.
4893         * tests/test-version-etc.c (main): Likewise.
4894         * tests/test-wchar.c (main): Likewise.
4895         * tests/test-wctype.c (main): Likewise.
4896         * tests/test-xprintf-posix.c (main): Likewise.
4897         * tests/test-posixtm.c (main): Likewise.
4898         (STREQ): Delete unused macro.
4899         * tests/test-linkat.c (main): Declare unused arguments.  Avoid
4900         shadowed variables.
4901         * tests/test-memchr.c (main): Likewise.
4902
4903 2009-10-21  Eric Blake  <ebb9@byu.net>
4904
4905         areadlinkat: avoid failure on older glibc
4906         * lib/at-func.c (AT_FUNC_NAME): Check for explicit FUNC_FAIL,
4907         rather than mis-comparing 0 against FUNC_RESULT of char*.
4908
4909 2009-10-21  Bruno Haible  <bruno@clisp.org>
4910
4911         * modules/stpncpy (License): Relicense under LGPLv2+.
4912         Reported by David Lutterkort <lutter@redhat.com>.
4913
4914 2009-10-20  Eric Blake  <ebb9@byu.net>
4915
4916         utimensat: work around Solaris 9 bug
4917         * lib/utimens.c (fdutimens, lutimens): Force a stat if platform
4918         has trailing slash bugs.
4919         * tests/test-lutimens.h (test_lutimens): Enhance test.
4920         * tests/test-utimens.h (test_utimens): Likewise.
4921         * doc/posix-functions/utime.texi (utime): Enhance documentation.
4922         * doc/posix-functions/utimes.texi (utimes): Likewise.
4923         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
4924         * doc/glibc-functions/futimesat.texi (futimesat): Likewise.
4925         * doc/glibc-functions/lutimes.texi (lutimes): Likewise.
4926         * doc/posix-functions/futimens.texi (futimens): Likewise.
4927
4928         fdutimensat: new module
4929         * modules/fdutimensat: New file.
4930         * lib/fdutimensat.c (fdutimensat): Likewise.
4931         * lib/utimens.h (fdutimensat, lutimensat): Declare new functions.
4932         * MODULES.html.sh (File system functions): Mention module.
4933         * modules/fdutimensat-tests: New test.
4934         * tests/test-fdutimensat.c: Likewise.
4935
4936         doc: regenerate INSTALL
4937         * doc/INSTALL: Reflect recent autoconf update.
4938         * doc/INSTALL.ISO: Likewise.
4939         * doc/INSTALL.UTF-8: Likewise.
4940
4941 2009-10-20  Pádraig Brady  <P@draigBrady.com>
4942
4943         acl: warn if ACL support is not detected
4944         * m4/acl.m4 (gl_FUNC_ACL): Output a warning if ACL support is not found.
4945
4946 2009-10-19  Giuseppe Scrivano  <gscrivano@gnu.org>
4947
4948         * lib/nproc.h: Add extern "C" block for C++.
4949
4950 2009-10-18  Reuben Thomas  <rrt@sc3d.org>
4951             Bruno Haible  <bruno@clisp.org>
4952
4953         * doc/posix-functions/isascii.texi: Document the 2 alternative APIs.
4954         * doc/posix-functions/isalnum.texi: Document the 4 alternative APIs.
4955         * doc/posix-functions/isalpha.texi: Likewise.
4956         * doc/posix-functions/isblank.texi: Likewise.
4957         * doc/posix-functions/iscntrl.texi: Likewise.
4958         * doc/posix-functions/isdigit.texi: Likewise.
4959         * doc/posix-functions/isgraph.texi: Likewise.
4960         * doc/posix-functions/islower.texi: Likewise.
4961         * doc/posix-functions/isprint.texi: Likewise.
4962         * doc/posix-functions/ispunct.texi: Likewise.
4963         * doc/posix-functions/isspace.texi: Likewise.
4964         * doc/posix-functions/isupper.texi: Likewise.
4965         * doc/posix-functions/isxdigit.texi: Likewise.
4966
4967 2009-10-18  Bruno Haible  <bruno@clisp.org>
4968
4969         Tests for module 'isblank'.
4970         * modules/isblank-tests: New file.
4971         * tests/test-isblank.c: New file.
4972
4973         New module 'isblank'.
4974         * lib/isblank.c: New file.
4975         * m4/isblank.m4: New file.
4976         * modules/isblank: New file.
4977         * doc/posix-functions/isblank.texi: Mention the new module.
4978
4979 2009-10-18  Bruno Haible  <bruno@clisp.org>
4980
4981         New module 'ctype'.
4982         * lib/ctype.in.h: New file.
4983         * m4/ctype.m4: New file.
4984         * modules/ctype: New file.
4985         * doc/posix-headers/ctype.texi: Mention the new module.
4986
4987 2009-10-18  Jim Meyering  <meyering@redhat.com>
4988
4989         m4: stylistic-only: hoist AC_SUBST to be adjacent to initialization
4990         Declare a variable like LIB_CLOCK_GETTIME to be AC_SUBSTituted
4991         right after its initialization, rather than farther down.
4992         Keeping these in close proximity makes it easier to ensure
4993         that each such variable is initialized.  E.g.,
4994
4995             LIB_CLOCK_GETTIME=
4996             AC_SUBST([LIB_CLOCK_GETTIME])
4997
4998         This change also increments these serial numbers.
4999         * m4/clock_time.m4 (gl_CLOCK_TIME): Hoist AC_SUBST use.
5000         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
5001         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
5002
5003 2009-10-18  Bruno Haible  <bruno@clisp.org>
5004
5005         Don't let environment variables perturb build.
5006         * m4/gethrxtime.m4 (gl_GETHRXTIME): Initialize LIB_GETHRXTIME here...
5007         (gl_PREREQ_GETHRXTIME): ... not here.
5008
5009 2009-10-18  Bruno Haible  <bruno@clisp.org>
5010
5011         Avoid symlink attack in localcharset module.
5012         * lib/localcharset.c: Include <fcntl.h>, <unistd.h>.
5013         (O_NOFOLLOW): Define fallback.
5014         (get_charset_aliases): Don't open the file if it is a symbolic link.
5015         * m4/fcntl_h.m4 (gl_FCNTL_O_FLAGS): New macro, extracted from
5016         gl_FCNTL_H.
5017         (gl_FCNTL_H): Require it.
5018         * m4/localcharset.m4 (gl_LOCALCHARSET): Likewise.
5019         * modules/localcharset (Files): Add m4/fcntl_h.m4.
5020         Reported by Fergal Glynn <fglynn@veracode.com>.
5021
5022 2009-10-18  Bruno Haible  <bruno@clisp.org>
5023
5024         Implement nproc for mingw.
5025         * lib/nproc.c: Include <windows.h>
5026         (num_processors): On native Windows platforms, try GetSystemInfo.
5027
5028 2009-10-18  Bruno Haible  <bruno@clisp.org>
5029
5030         Implement nproc for IRIX.
5031         * lib/nproc.c: Include <sys/sysmp.h>.
5032         (num_processors): On IRIX systems, try sysmp.
5033         * m4/nproc.m4 (gl_PREREQ_NPROC): Check for sys/sysmp.h and sysmp.
5034
5035 2009-10-18  Bruno Haible  <bruno@clisp.org>
5036
5037         Implement nproc for HP-UX.
5038         * lib/nproc.c: Include <sys/pstat.h>
5039         (num_processors): On HP-UX systems, try pstat_getdynamic.
5040         * m4/nproc.m4 (gl_PREREQ_NPROC): Check for sys/pstat.h and
5041         pstat_getdynamic.
5042
5043 2009-10-18  Giuseppe Scrivano  <gscrivano@gnu.org>
5044             Bruno Haible  <bruno@clisp.org>
5045
5046         Implement nproc for NetBSD, OpenBSD.
5047         * lib/nproc.c: Include <sys/types.h>, <sys/param.h>, <sys/sysctl.h>.
5048         (ARRAY_SIZE): New macro.
5049         (num_processors): On BSD systems, try sysctl of HW_NCPU.
5050         * m4/nproc.m4: New file.
5051         * modules/nproc (Files): Add m4/nproc.m4.
5052         (configure.ac): Invoke gl_NPROC. Remove AC_LIBOBJ invocation.
5053         (Makefile.am): Instead, augment lib_SOURCES.
5054
5055 2009-10-18  Bruno Haible  <bruno@clisp.org>
5056
5057         Fix recognition of sys/sysctl.h on OpenBSD 4.0.
5058         * m4/physmem.m4 (gl_PHYSMEM): Before including sys/sysctl.h, include
5059         sys/param.h.
5060
5061 2009-10-16  Eric Blake  <ebb9@byu.net>
5062
5063         utimensat: new module
5064         * modules/utimensat: New file.
5065         * lib/utimensat.c (utimensat): Likewise.
5066         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
5067         * lib/utimens.c (utimensat): Avoid recursion into rpl_utimensat,
5068         so we can work around Linux bugs.
5069         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
5070         * modules/sys_stat (Makefile.am): Substitute them.
5071         * lib/sys_stat.in.h (utimensat): Declare it.
5072         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
5073         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
5074         * modules/utimensat-tests: New test.
5075         * tests/test-utimensat.c: Likewise.
5076
5077         utimens: let lutimens work on non-symlinks
5078         * lib/utimens.c (lutimens): Fall back to utimens rather than
5079         failing with ENOSYS, when file is not a symlink.
5080         (utimens): Reduce redirection.
5081         * tests/test-lutimens.h (test_lutimens): Update test to cover
5082         non-symlinks.
5083         * tests/test-utimens.h (test_utimens): Update test to cover
5084         symlinks.
5085         * tests/test-utimens.c (main): Update caller.
5086
5087         utimens: cache whether utimensat syscall works
5088         * lib/utimens.c (utimensat_works_really): New cache variable.
5089         (fdutimens, lutimens): Use it to avoid failing syscall.
5090
5091         test-stat-time, test-utimens: improve portability
5092         * tests/test-stat-time.c (nap): Lengthen delay to 20ms, for
5093         ext4 on alpha, and for cygwin.
5094         * tests/test-utimens-common.h: New file.
5095         (nap): Factor delays into single function.
5096         * tests/test-lutimens.h (test_lutimens): Use new header.
5097         * tests/test-futimens.h (test_futimens): Likewise.
5098         * tests/test-utimens.h (test_utimens): Likewise.  Also, force NFS
5099         timestamps to occur from same machine, as was done previously for
5100         test_utimens.
5101         * modules/utimens-tests (Files): Ship new file.
5102         * modules/futimens-tests (Files): Likewise.
5103         Reported in part by Jim Meyering.
5104
5105         sys_stat: sort replacement declarations
5106         * lib/sys_stat.in.h: Sort declarations.
5107         * lib/futimens.c (futimens): Fix typo.
5108
5109 2009-10-15  Jim Meyering  <meyering@redhat.com>
5110
5111         don't let environment settings perturb build
5112         Setting the envvars, LIB_CLOCK_GETTIME, LIB_EACCESS or LIB_NANOSLEEP
5113         could cause a configure-time and/or build-time malfunction.
5114         Typically, a configure-time function-in-library test is performed
5115         via code like this:
5116
5117           LIB_VAR=
5118           AC_SUBST([LIB_VAR])
5119           prefix_saved_LIBS=$LIBS
5120             AC_SEARCH_LIBS([FUNC], [LIB_NAME],
5121                        [test "$ac_cv_search_FUNC" = "none required" ||
5122                         LIB_VAR=$ac_cv_search_FUNC])
5123           LIBS=$prefix_saved_LIBS
5124
5125         However, in each of the files affected by this change, the LIB_VAR=
5126         initialization was omitted.  Thus, when set in the environment, its
5127         value would propagate into generated Makefiles when FUNC is not found
5128         in LIB_NAME.
5129         * m4/clock_time.m4 (gl_CLOCK_TIME): Initialize AC_SUBST'd var.
5130         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
5131         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
5132
5133 2009-10-14  Eric Blake  <ebb9@byu.net>
5134
5135         fchdir: avoid infinite recursion in mingw
5136         * lib/fchdir.c (rpl_fstat): Call system fstat, rather than
5137         recursing.
5138
5139         test-stat-time: port to mingw
5140         * tests/test-stat-time.c (force_unlink): Return a value.
5141         (test_ctime) [W32]: Fix compilation error.
5142         (nap): Don't call usleep with too large an argument.  Use
5143         force_unlink.
5144         * doc/pastposix-functions/usleep.texi (usleep): Document the
5145         portability issue.
5146
5147 2009-10-13  Jim Meyering  <meyering@redhat.com>
5148
5149         use AC_CHECK_FUNCS_ONCE, not AC_CHECK_FUNCS in modules/*
5150         * modules/pipe-filter-gi: Use AC_CHECK_FUNCS_ONCE, not AC_CHECK_FUNCS.
5151         * modules/pipe-filter-ii: Likewise.
5152         * modules/sys_socket-tests: Likewise.
5153         * modules/tsearch-tests: Likewise.
5154         * Makefile (sc_prefer_ac_check_funcs_once): New rule.
5155         (check): Depend on it.
5156
5157 2009-10-12  Eric Blake  <ebb9@byu.net>
5158
5159         utimens-tests: port to NFS file systems
5160         * tests/test-utimens.h (test_utimens): Refactor utimecmp
5161         comparisons to avoid spurious failures from timestamp drift
5162         between NFS machines.
5163
5164 2009-10-12  Eric Blake  <ebb9@byu.net>
5165
5166         stat-time-tests: minor cleanups
5167         * modules/stat-time-tests (configure.ac): Use AC_CHECK_FUNCS_ONCE.
5168         * tests/test-stat-time.c (nap): Separate assignment from call.
5169         Suggested by Paolo Bonzini and Bruno Haible.
5170
5171         sys_stat: guarantee struct timespec
5172         * lib/sys_stat.in.h (includes): Always include <time.h>
5173         * modules/sys_stat (Depends-on): Add time.
5174         * tests/test-sys_stat.c: Guarantee struct timespec, as well as
5175         mode_t permission values.
5176         * doc/posix-headers/sys_stat.texi (sys/stat.h): Document how to
5177         get at subsecond timestamps.
5178
5179 2009-10-10  Eric Blake  <ebb9@byu.net>
5180
5181         futimens: new module
5182         * modules/futimens: New file.
5183         * lib/futimens.c (futimens): Likewise.
5184         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Likewise.
5185         * lib/utimens.c (futimens): Avoid recursion into rpl_futimens, so
5186         we can work around Linux bugs.
5187         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
5188         * modules/sys_stat (Makefile.am): Substitute them.
5189         * lib/sys_stat.in.h (futimens): Declare it.
5190         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
5191         * doc/posix-functions/futimens.texi (futimens): Likewise.
5192         * modules/futimens-tests: New test.
5193         * tests/test-futimens.c: Likewise.
5194
5195         utimens: introduce fdutimens
5196         * lib/utimens.h (fdutimens): New prototype.
5197         * lib/utimens.c (gl_futimens): Move guts...
5198         (fdutimens): ...to new interface.
5199         * tests/test-utimens.c (do_fdutimens): Use it.
5200
5201         utimens: add UTIME_NOW and UTIME_OMIT support
5202         * lib/utimens.c (validate_timespec, update_timespec): New helper
5203         functions.
5204         (gl_futimens, lutimens): Use them.
5205         * modules/utimens (Depends-on): Add gettime, lstat, stat-time,
5206         stdbool, sys_stat.
5207         (Link): Mention resulting library dependency.
5208         * modules/utimecmp (Link): Likewise.
5209         * modules/utimens-tests (Depends-on): Drop stat-time, stdbool.
5210         (Makefile.am): Pick up library dependency.
5211         * lib/sys_stat.in.h (UTIME_NOW, UTIME_OMIT): Guarantee a
5212         definition.
5213         * tests/test-sys_stat.c: Test the definitions.
5214         * doc/posix-headers/sys_stat.texi (sys/stat.h): Document this.
5215         * NEWS: Document library dependency.
5216
5217         utimecmp: support symlink timestamps
5218         * lib/utimecmp.c (utimecmp): Use new interface.  Skip effort of
5219         hashing when possible.  Use pathconf when available.
5220         (SYSCALL_RESOLUTION): Recognize tighter resolution.
5221         * modules/utimecmp (Depends-on): Add lstat.
5222
5223         utimens: add lutimens interface
5224         * lib/utimens.c (lutimens): New function.
5225         * m4/utimens.m4 (gl_UTIMENS): Check for lutimes.
5226         * lib/utimens.h (lutimens): Declare new interface.
5227         * tests/test-utimens.c (main): Enhance test.
5228         * tests/test-lutimens.h (test_lutimens): New file.
5229         * modules/utimens-tests (Files): Distribute it.
5230         (Depends-on): Add symlink.
5231         (configure.ac): Check for usleep.
5232
5233         utimens: validate futimens usage
5234         * lib/utimens.c (gl_futimens): Require valid fd up front, using
5235         fewer syscalls on failure later on.  Avoid compiler warning on
5236         mingw.
5237         * modules/utimens (Depends-on): Add dup2.
5238
5239         utimens: add test
5240         * modules/utimens-tests: New test.
5241         * tests/test-utimens.h: New file.
5242         * tests/test-futimens.h: Likewise.
5243         * tests/test-utimens.c: Likewise.
5244
5245         doc: mention timestamp portability issues
5246         * doc/glibc-functions/lutimes.texi (lutimes): Refer to utimensat
5247         instead.
5248         * doc/posix-functions/utime.texi (utime): Likewise.
5249         * doc/posix-functions/utimes.texi (utimes): Likewise.
5250         * doc/glibc-functions/futimes.texi (futimes): Refer to futimens
5251         instead.
5252         * doc/posix-functions/futimens.texi (futimens): Mention utimens
5253         module.
5254         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
5255         Mention weakness with symlink timestamps.
5256         * doc/glibc-functions/futimesat.texi (futimesat): New file; refer
5257         to utimensat/futimens instead.
5258         * doc/gnulib.texi (Glibc sys/time.h): Include new file.
5259
5260         test-dup2: enhance test
5261         * tests/test-dup2.c (main): Also check AT_FDCWD.
5262
5263         test-stat-time: avoid more spurious failures
5264         * tests/test-stat-time.c (nap): Wait for 15ms rather than 2ms, for
5265         xfs; and avoid race if the two timestamps cross quantization edge.
5266
5267         relocatable: prefer 'file system' over 'filesystem'
5268         * m4/relocatable-lib.m4 (gl_RELOCATABLE_NOP): Use AS_HELP_STRING.
5269         (gl_RELOCATABLE_LIBRARY_BODY): Fix spelling.
5270         * doc/relocatable-maint.texi (Supporting Relocation): Likewise.
5271         * doc/relocatable.texi (Enabling Relocatability): Likewise.
5272         * lib/relocatable.c (compute_curr_prefix): Likewise.
5273
5274 2009-10-10  Jim Meyering  <meyering@redhat.com>
5275
5276         stat-time-tests: check for the usleep function
5277         * modules/stat-time-tests (configure.ac): Now that we test HAVE_USLEEP.
5278
5279 2009-10-10  Bruno Haible  <bruno@clisp.org>
5280
5281         * modules/xnanosleep: Put the Link section after the Include section.
5282
5283 2009-10-09  Eric Blake  <ebb9@byu.net>
5284
5285         dup2: work around FreeBSD 6.1 bug
5286         * m4/dup2.m4 (gl_FUNC_DUP2): Detect bug.
5287         * doc/posix-functions/dup2.texi (dup2): Document it.
5288         Reported by Nelson H. F. Beebe and Jim Meyering.
5289
5290         test-stat-time: port to buggy NFS clients
5291         * tests/test-stat-time.c (main) [W32]: Reduce ifdefs.
5292         (test_ctime): Also skip test if mtime and ctime are skewed.
5293
5294         maint: prefer 'file system' over 'filesystem'
5295         * doc/posix-functions/fstatat.texi (fstatat): Likewise.
5296         * doc/posix-functions/lstat.texi (lstat): Likewise.
5297         * lib/file-has-acl.c (file_has_acl): Likewise.
5298         * lib/fwriteerror.c [TEST]: Likewise.
5299         * tests/test-areadlink.h (test_areadlink): Likewise.
5300         * tests/test-areadlinkat-with-size.c (main): Likewise.
5301         * tests/test-areadlinkat.c (main): Likewise.
5302         * tests/test-canonicalize-lgpl.c (main): Likewise.
5303         * tests/test-canonicalize.c (main): Likewise.
5304         * tests/test-fstatat.c (main): Likewise.
5305         * tests/test-linkat.c (main): Likewise.
5306         * tests/test-lstat.h (test_lstat_func): Likewise.
5307         * tests/test-mkdir.h (test_mkdir): Likewise.
5308         * tests/test-readlink.h (test_readlink): Likewise.
5309         * tests/test-remove.c (main): Likewise.
5310         * tests/test-rename.h (test_rename): Likewise.
5311         * tests/test-renameat.c (main): Likewise.
5312         * tests/test-rmdir.h (test_rmdir_func): Likewise.
5313         * tests/test-symlink.h (test_symlink): Likewise.
5314         * tests/test-symlinkat.c (main): Likewise.
5315         * tests/test-unlink.h (test_unlink_func): Likewise.
5316         * tests/test-unlinkat.c (main): Likewise.
5317
5318         maint: make realtime library usage explicit
5319         * modules/gethrxtime (Link): Mention LIB_GETHRXTIME.
5320         * modules/gettime (Link): Mention LIB_CLOCK_GETTIME.
5321         * modules/settime (Link): Likewise.
5322         * modules/xnanosleep (Link): Mention LIB_NANOSLEEP.
5323
5324         test-stat-time: speed up execution
5325         * tests/test-stat-time.c (test_ctime) [!W32]: Avoid compiler
5326         warning on mingw.
5327         (nap): New helper function.
5328         (prepare_test): Use it to reduce sleep time.
5329         (test_mtime, test_ctime, test_birthtime): Allow for subsecond
5330         execution.
5331         * modules/stat-time-tests (configure.ac): Check for usleep.
5332
5333 2009-10-09  Jim Meyering  <meyering@redhat.com>
5334
5335         selinux-h: always use getfilecon wrappers
5336         * lib/getfilecon.c: New file.
5337         * lib/se-selinux.in.h: Use a better inclusion guard symbol name.
5338         [HAVE_SELINUX_SELINUX_H]: Include-next <selinux/selinux.h>.
5339         [!HAVE_SELINUX_SELINUX_H]: Use better parameter names.
5340         (fgetfilecon): Provide a stub.
5341         * m4/selinux-selinux-h.m4 (gl_HEADERS_SELINUX_SELINUX_H): Don't
5342         AC_SUBST SELINUX_SELINUX_H, since now we're generating that
5343         file unconditionally.
5344         When <selinux/selinux.h> is found, arrange to use wrappers.
5345         * modules/selinux-h (Files): Add getfilecon.c.
5346         (Makefile.am): Substitute include-next-related bits
5347         into the now-always-generated selinux/selinux.h file.
5348         * doc/glibc-functions/lgetfilecon.texi: New file.
5349         * doc/glibc-functions/fgetfilecon.texi: New file.
5350         * doc/glibc-functions/getfilecon.texi: New file.
5351         * doc/glibc-functions/getfilecon-desc.texi: New file.
5352         * doc/gnulib.texi (Glibc selinux/selinux.h): New section, by
5353         which to pull in the new files.
5354         * MODULES.html.sh (Misc): Add selinux-h.
5355
5356 2009-10-08  Jim Meyering  <meyering@redhat.com>
5357
5358         unistd: fix comment typo
5359         * lib/unistd.in.h (euidaccess): Fix a comment typo.
5360
5361 2009-10-08  Eric Blake  <ebb9@byu.net>
5362
5363         areadlink: use SIZE_MAX consistently
5364         * modules/areadlink (Depends-on): Add stdint.
5365         * modules/areadlink-with-size (Depends-on): Likewise.
5366         * lib/areadlink-with-size.c (includes): Drop stdio, since stdlib
5367         gives NULL; drop sys/types, since unistd gives size_t; and add
5368         stdint for SIZE_MAX.
5369         (SIZE_MAX): Rely on headers.
5370         * lib/areadlinkat-with-size.c (includes): Drop stdio, sys/types,
5371         and add stdint.
5372         * lib/areadlink.c (includes): Drop sys/types, and add stdint.
5373         (SIZE_MAX): Likewise.
5374         (INITIAL_BUF_SIZE): Turn into enum.
5375         * lib/areadlinkat.c (INITIAL_BUF_SIZE): Likewise.
5376
5377 2009-10-08  Jim Meyering  <meyering@redhat.com>
5378
5379         areadlinkat: avoid compilation failure
5380         * lib/areadlinkat.c: Include <stdint.h> for use of SIZE_MAX.
5381         Fix typo in comment.
5382
5383 2009-10-07  Eric Blake  <ebb9@byu.net>
5384
5385         areadlinkat-with-size: new module
5386         * modules/areadlinkat-with-size: New module.
5387         * lib/areadlinkat-with-size.c (areadlinkat_with_size): New file.
5388         * lib/areadlink.h (areadlinkat): Declare it.
5389         * MODULES.html.sh (File system functions): Mention it.
5390         * modules/areadlinkat-with-size-tests: New test.
5391         * tests/test-areadlinkat-with-size.c: New file.
5392
5393         xreadlinkat: new module
5394         * modules/xreadlinkat: New module.
5395         * lib/xreadlinkat.c (xreadlinkat): New file.
5396         * lib/xreadlink.h (xreadlinkat): Declare it.
5397         * MODULES.html.sh (File system functions): Mention it.
5398
5399         areadlinkat: new module
5400         * lib/at-func.c (FUNC_FAIL): New define.
5401         (AT_FUNC_NAME, VALIDATE_FLAG): Use it rather than raw -1.
5402         * modules/areadlinkat: New module.
5403         * lib/linkat.c (areadlinkat): Move...
5404         * lib/areadlinkat.c (areadlinkat): ...to new file.
5405         * lib/areadlink.h (areadlinkat): Declare it.
5406         * modules/linkat (Depends-on): Add areadlinkat.
5407         * MODULES.html.sh (File system functions): Mention it.
5408         * modules/areadlinkat-tests: New test.
5409         * tests/test-areadlinkat.c: New file.
5410
5411         areadlink, areadlink-with-size: add tests
5412         * modules/areadlink-tests: New test.
5413         * modules/areadlink-with-size-tests: Likewise.
5414         * tests/test-areadlink.h: New file.
5415         * tests/test-areadlink.c: Likewise.
5416         * tests/test-areadlink-with-size.c: Likewise.
5417
5418         maint: minor cleanups
5419         * lib/fts.c (ATTRIBUTE_UNUSED): Delete; use gnulib-guaranteed
5420         _UNUSED_PARAMETER_ instead.
5421         * lib/getdate.y (ATTRIBUTE_UNUSED): Likewise.
5422         * lib/utimens.c (ATTRIBUTE_UNUSED): Likewise.
5423         * modules/linkat-tests (Files): Distribute test-link.h.
5424
5425         openat, utimens: whitespace cleanup
5426         * lib/openat.c: Prefer space throughout, rather than mix of 8
5427         spaces vs. tabs.
5428         * lib/at-func.c: Likewise.
5429         * lib/utimens.c: Likewise.
5430
5431         openat: avoid using wrong fd
5432         * lib/openat.c (openat_permissive): Reject user's fd if saving the
5433         working directory chooses same fd.
5434         * lib/at-func.c (AT_FUNC_NAME): Likewise.
5435
5436         mkdir, mkdirat: fix cygwin 1.5.x bug
5437         * lib/mkdir.c (rpl_mkdir) [FUNC_MKDIR_DOT_BUG]: Work around bug.
5438         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Move...
5439         * m4/mkdir.m4 (gl_FUNC_MKDIR): ...here, and add check for cygwin
5440         bug.
5441         (gl_PREREQ_MKDIR): Delete unused macro.
5442         * modules/mkdir (Files): Track file rename.
5443         (configure.ac): Update macro name.
5444         * modules/openat (Depends-on): Add mkdir.
5445         * doc/posix-functions/mkdir.texi (mkdir): Document the bug.
5446
5447         mkdir, mkdirat: add tests
5448         * modules/mkdir-tests: New test.
5449         * tests/test-mkdir.h: New file.
5450         * tests/test-mkdir.c: Likewise.
5451         * tests/test-mkdirat.c: Likewise.
5452         * modules/openat-tests (Files): Add new files.
5453         (Makefile.am): Run new test.
5454
5455 2009-10-06  Eric Blake  <ebb9@byu.net>
5456
5457         doc: tweak *at function documentation
5458         * doc/posix-functions/faccessat.texi (faccessat): Mention
5459         known issue with replacement.
5460         * doc/posix-functions/fchdir.texi (fchdir): Likewise.
5461         * doc/posix-functions/linkat.texi (linkat): Likewise.
5462         * doc/posix-functions/mkfifoat.texi (mkfifoat): Likewise.
5463         * doc/posix-functions/mknodat.texi (mknodat): Likewise.
5464         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
5465         * doc/posix-functions/renameat.texi (renameat): Likewise.
5466         * doc/posix-functions/symlinkat.texi (symlinkat): Likewise.
5467
5468         openat: fix GNU/Hurd bug in unlinkat
5469         * m4/openat.m4 (gl_FUNC_OPENAT): Replace unlinkat if unlink is
5470         broken.
5471         * doc/posix-functions/unlink.texi (unlink): Document this.
5472         * doc/posix-functions/unlinkat.texi (unlinkat): Likewise.
5473
5474         fdopendir: fix GNU/Hurd bug
5475         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Check for Hurd bug in
5476         allowing non-directory fds.
5477         * lib/fdopendir.c (rpl_fdopendir): Work around it.
5478         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): New witness.
5479         * modules/dirent (Makefile.am): Substitute it.
5480         * lib/dirent.in.h (fdopendir): Declare replacement.
5481         * doc/posix-functions/fdopendir.texi (fdopendir): Document this.
5482         * tests/test-fdopendir.c (main): Test something other than
5483         /dev/null, since on Hurd that behaves like a directory.
5484
5485         test-symlink: port to GNU/Hurd
5486         * tests/test-symlink.h (test_symlink): Relax expected errno.
5487
5488         doc: tweak more cygwin information
5489         * doc/glibc-headers/getopt.texi (getopt.h): Cygwin 1.7 getopt is
5490         now compatible with glibc.
5491         * doc/posix-functions/getopt.texi (getopt): Likewise.
5492
5493         getopt-gnu: add another test
5494         * tests/test-getopt_long.h (test_getopt_long_posix): New test, to
5495         guarantee behavior relied on by m4.
5496         * tests/test-getopt.c (main): Use it.
5497         * modules/getopt-posix-tests (Depends-on): Add setenv.
5498         See http://lists.gnu.org/archive/html/bug-m4/2006-09/msg00028.html.
5499
5500         getopt: fix compilation on darwin
5501         * lib/getopt.in.h (includes): Leave breadcrumbs during system
5502         include.
5503         * lib/unistd.in.h (getopt): Use them to avoid recursive include.
5504         Reported by Ludovic Courtès.
5505
5506 2009-10-06  Bruno Haible  <bruno@clisp.org>
5507
5508         * modules/size_max (Description): Discourage its use.
5509         Reported by Simon Josefsson.
5510
5511 2009-10-06  Jim Meyering  <meyering@redhat.com>
5512
5513         linkat: avoid compilation failure
5514         * lib/linkat.c: Include <stdint.h> for use of SIZE_MAX.
5515
5516 2009-10-05  Eric Blake  <ebb9@byu.net>
5517
5518         linkat: support Linux 2.6.17
5519         * m4/linkat.m4 (gl_FUNC_LINKAT): Default to always replacing
5520         linkat on Linux, but allow cache variable override.
5521         * lib/linkat.c (rpl_linkat): Define override.
5522         * modules/linkat (Depends-on): Add symlinkat.
5523         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add new default.
5524         * modules/unistd (Makefile.am): Substitute it.
5525         * lib/unistd.in.h (linkat): Declare replacement.
5526         Reported by Pádraig Brady.
5527
5528         quotearg: port test to systems with C.UTF-8 locale
5529         * tests/test-quotearg.c (struct result_strings): Add another
5530         member, differentiating between C.ASCII and C.UTF-8 handling.
5531         (compare_strings): Add parameter.
5532         (main): Adjust all callers.
5533
5534         getopt: avoid clash with FreeBSD _getopt_internal
5535         * lib/getopt.in.h (_getopt_internal): Override the name.
5536         * lib/getopt_int.h (includes): Pick up any overrides.
5537         Reported by Reuben Thomas.
5538
5539         hash: allow C89 compilation
5540         * lib/hash.c (check_tuning): Move declaration before statement.
5541         Reported by Reuben Thomas.
5542
5543 2009-10-05  Karl Berry  <karl@gnu.org>
5544
5545         * doc/gnulib.texi: @include execvpe.texi, missing for several days.
5546
5547 2009-10-04  Paolo Bonzini  <bonzini@gnu.org>
5548             Bruno Haible  <bruno@clisp.org>
5549
5550         * lib/uname.c (uname): Use a table-driven algorithm to compute
5551         Windows NT versions.
5552
5553 2009-10-04  Bruno Haible  <bruno@clisp.org>
5554
5555         * lib/progname.c (set_program_name): Also remove the "lt-" prefix from
5556         program_invocation_short_name.
5557         * modules/progname (configure.ac): Test for presence of
5558         program_invocation_short_name.
5559         Reported by Sergey Poznyakoff <gray@gnu.org.ua>.
5560
5561 2009-10-04  Bruno Haible  <bruno@clisp.org>
5562
5563         * lib/progname.c (set_program_name): Fix comment.
5564         Reported by Jim Meyering.
5565
5566 2009-10-03  Paolo Bonzini  <bonzini@gnu.org>
5567             Bruno Haible  <bruno@clisp.org>
5568
5569         * lib/uname.c: Include <string.h>.
5570         (uname): Do only one call to GetVersionEx in the common case.
5571
5572 2009-10-03  Paolo Bonzini  <bonzini@gnu.org>
5573             Bruno Haible  <bruno@clisp.org>
5574
5575         * lib/uname.c (VER_PLATFORM_WIN32_CE, PROCESSOR_ARCHITECTURE_AMD64,
5576         PROCESSOR_ARCHITECTURE_IA32_ON_WIN64): Define fallbacks.
5577         (uname): Add support for Windows CE and various non-x86 CPU types.
5578
5579 2009-10-03  Bruno Haible  <bruno@clisp.org>
5580
5581         * gnulib-tool (func_create_testdir): Conditionally emit AM_PROG_CC_C_O
5582         invocation to tests/configure.ac.
5583         Reported by Ian Beckwith <ianb@erislabs.net>.
5584
5585 2009-10-02  Eric Blake  <ebb9@byu.net>
5586
5587         fchdir: avoid compiler warning
5588         * lib/fchdir.c (canonicalize_file_name)
5589         [!HAVE_CANONICALIZE_FILE_NAME]: Avoid compiler warning on mingw.
5590
5591         test-open: support mingw errno values
5592         * tests/test-open.h (test_open): Relax test.
5593         * tests/test-fopen.h (test_fopen): Likewise.
5594         * tests/test-openat-safer.c (main): Likewise.
5595
5596         open: fix opening directory on mingw
5597         * lib/open.c (open) [REPLACE_OPEN_DIRECTORY]: Correct typo.
5598
5599         test-open: on GNU/Hurd, /dev/null is a directory
5600         * tests/test-fopen.h (main): Rename...
5601         (test_fopen): ...to this.  Use a guaranteed non-directory when
5602         confirming open behavior on trailing slash.
5603         * tests/test-openat-safer.c (main): Likewise.
5604         * tests/test-open.h (main): Likewise....
5605         (test_open): ...to this.
5606         * tests/test-fopen.c (main): Adjust caller.
5607         * tests/test-fopen-safer.c (main): Likewise.
5608         * tests/test-open.c (main): Likewise.
5609         * tests/test-fcntl-safer.c (main): Likewise.
5610         Reported by Samuel Thibault.
5611
5612         rename, fchdir: don't ignore chdir failure
5613         * lib/fchdir.c (get_name): Abort on unexpected chdir failure.
5614         * lib/rename.c (rpl_rename) [W32]: Likewise.
5615         (rpl_rename) [RENAME_DEST_EXISTS_BUG]: Avoid one case of losing
5616         an empty destination directory if source cannot be renamed,
5617         although there is still possibility for failure.
5618         * doc/posix-functions/rename.texi (rename): Document the race.
5619         Reported by Jim Meyering.
5620
5621         maint: cleanup whitespace in recent commits
5622         * lib/rename.c (rpl_rename): Remove tabs.
5623         * tests/test-link.h (test_link): Likewise.
5624         * lib/fchdir.c (get_name): Likewise.
5625         Reported by Jim Meyering.
5626
5627 2009-10-02  Ben Pfaff  <blp@gnu.org>
5628
5629         relocatable-prog-wrapper: Add missing dependency on
5630         double-slash-root.
5631         * modules/relocatable-prog-wrapper: Add dependency.
5632         Reported by Ian Beckwith <ianb@erislabs.net>.
5633
5634 2009-10-02  Eric Blake  <ebb9@byu.net>
5635
5636         renameat: fix Solaris bugs
5637         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Replace renameat if rename
5638         needed fixing.
5639         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): New witness.
5640         * modules/stdio (Makefile.am): Substitute it.
5641         * lib/stdio.in.h (renameat): Declare replacement.
5642         * lib/renameat.c (rpl_renameat): Implement fix.
5643
5644         renameat: new module
5645         * modules/renameat: New file.
5646         * lib/renameat.c (renameat): Likewise.
5647         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Likewise.
5648         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add witnesses.
5649         * modules/stdio (Makefile.am): Substitute them.
5650         * lib/stdio.in.h (renameat): Declare it.
5651         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
5652         * doc/posix-functions/renameat.texi (renameat): Likewise.
5653         * modules/renameat-tests: New test.
5654         * tests/test-renameat.c: Likewise.
5655
5656         rename: fix mingw bugs
5657         * lib/rename.c (rpl_rename) [W32]: Fix trailing slash and
5658         directory overwrite bugs.
5659
5660         rename: fix another cygwin 1.5 bug
5661         * m4/rename.m4 (gl_FUNC_RENAME): Split cygwin bugs into two
5662         checks.
5663         * lib/rename.c (rpl_rename): Don't penalize NetBSD with
5664         unnecessary cygwin workarounds.  Also work around bug with moving
5665         full directory onto an empty one.
5666         * modules/rename (Depends-on): Add canonicalize-lgpl, rmdir.
5667
5668         rename-dest-slash: merge into rename module
5669         * modules/rename-dest-slash (Status): Mark obsolete.
5670         (Depends-on): Add rename.
5671         (Files): Let rename do it all.
5672         * m4/rename.m4 (gl_FUNC_RENAME): Also test for NetBSD bugs,
5673         subsuming the test from gl_FUNC_RENAME_TRAILING_DEST_SLASH...
5674         * m4/rename-dest-slash.m4: ...so this file can be deleted.
5675         * lib/rename-dest-slash.c (rpl_rename_dest_slash): Delete.
5676         * lib/rename.c (rpl_rename): Update comments.
5677
5678         rename: fix cygwin 1.5.x bugs
5679         * m4/rename.m4 (gl_FUNC_RENAME): Detect cygwin bugs.
5680         * lib/rename.c (rpl_rename): Work around them.
5681         * modules/rename (Depends-on): Add same-inode.
5682
5683         rename: fix Solaris 10 bug
5684         * m4/rename.m4 (gl_FUNC_RENAME): Detect Solaris bug.
5685         * lib/rename.c (rpl_rename): Don't cripple POSIX behavior if this
5686         was the only bug.
5687
5688         rename: fix Solaris 9 bug
5689         * lib/rename.c (rpl_rename): Rewrite to recognize trailing slash
5690         on non-directory.  Avoid calling exit.
5691         * modules/rename (Depends-on): Drop xalloc; add lstat, stdbool,
5692         strdup.
5693         * modules/rename-tests (Depends-on): Drop lstat.
5694         * m4/rename.m4 (gl_FUNC_RENAME): Detect Solaris bug.
5695         (gl_PREREQ_RENAME): Delete unused macro.
5696
5697         rename-dest-slash: fix NetBSD bug
5698         * lib/rename-dest-slash.c (rpl_rename_dest_slash): Detect hard
5699         links.
5700         * modules/rename-dest-slash (Depends-on): Add same-inode.
5701
5702         rename-tests: new test, exposes several platform bugs
5703         * modules/rename-tests: New file.
5704         * tests/test-rename.h: Likewise.
5705         * tests/test-rename.c: Likewise.
5706         * doc/posix-functions/rename.texi (rename): Improve documentation,
5707         including bugs that will eventually be fixed in gnulib.
5708
5709 2009-10-02  Paolo Bonzini  <bonzini@gnu.org>
5710
5711         * lib/uname.c: Include <stdlib.h>
5712         (uname): Assume version info is available.
5713
5714 2009-10-02  Jim Meyering  <meyering@redhat.com>
5715
5716         gnu-web-doc-update: correct --help output
5717         * build-aux/gnu-web-doc-update: Make --help output relevant.
5718
5719         gnu-web-doc-update: add standard options
5720         * build-aux/gnu-web-doc-update: Add --help, --version, etc.
5721
5722         gnu-web-doc-update: New module.
5723         Use this script to automatically update the on-line web documentation
5724         for your GNU project at http://www.gnu.org/software/$pkg/manual/
5725         * modules/gnu-web-doc-update: New file, from coreutils.
5726         * build-aux/gnu-web-doc-update: New script.
5727
5728 2009-10-01  Paolo Bonzini  <bonzini@gnu.org>
5729
5730         link: LoadLibrary is not needed.
5731         * lib/link.c: Use GetModuleHandle.
5732
5733 2009-10-01  Eric Blake  <ebb9@byu.net>
5734
5735         getopt: bump serial number
5736         * m4/getopt.m4: Increment serial number, to account for 2009-09-24
5737         change.
5738
5739         tests: tighten link, rmdir, and remove tests
5740         * tests/test-link.h (includes): No need to use <config.h> here.
5741         Clean up if directory hard link was created, otherwise test for
5742         trailing '.'.
5743         * tests/test-linkat.c (main): Simplify.
5744         * tests/test-remove.c (main): Enhance test for trailing '.'.
5745         * tests/test-rmdir.h (test_rmdir_func): Likewise.
5746
5747 2009-10-01  Jim Meyering  <meyering@redhat.com>
5748
5749         maint.mk: requiring "make major" was annoying, for a "minor" release.
5750         What is intended is "stable", to contrast with alpha and beta,
5751         so require "make stable", not "make major".
5752         * build-aux/announce-gen (%valid_release_types): s/major/stable/.
5753         (get_tool_versions): Likewise.
5754         * top/maint.mk (ALL_RECURSIVE_TARGETS): s/major/stable/
5755
5756 2009-09-30  Ben Pfaff  <blp@gnu.org>
5757
5758         Fix broken build of replacement for Windows tmpfile().
5759         * lib/tmpfile.c (tmpfile): Fix call to gen_tempname() to provide
5760         flags argument added along with the 'mkostemp' module.
5761
5762 2009-09-28  Bruno Haible  <bruno@clisp.org>
5763
5764         Avoid identifier clash with POSIX function 'remove' defined as a macro.
5765         * lib/gl_list.h (struct gl_list_implementation): Rename field 'remove'
5766         to 'remove_elt'.
5767         (gl_list_remove): Update.
5768         * lib/gl_list.c (gl_list_remove): Update.
5769         * lib/gl_oset.h (struct gl_oset_implementation): Rename field 'remove'
5770         to 'remove_elt'.
5771         (gl_oset_remove): Update.
5772         * lib/gl_list.c (gl_oset_remove): Update.
5773         Reported by Eric Blake.
5774
5775 2009-09-28  Eric Blake  <ebb9@byu.net>
5776
5777         doc: mention yet more cygwin 1.7 status
5778         * doc/posix-functions/fexecve.texi (fexecve): Now implemented in
5779         cygwin.
5780         * doc/glibc-functions/execvpe.texi (execvpe): New file.
5781         * doc/gnulib.texi (Glibc unistd.h): Mention it.
5782
5783         argp: fix test failure
5784         * lib/argp-help.c (hol_entry_cmp): Don't use _tolower on values
5785         that are not upper-case.  Pass correct range to tolower.
5786
5787 2009-09-27  Jim Meyering  <meyering@redhat.com>
5788
5789         test-yesno: work around sparc-dash here-document infelicity
5790         Without this change, the literal \177 byte in a here document
5791         would make dash 0.5.5.1-3 access uninitialized memory.
5792         * tests/test-yesno.sh: Don't put the \177 byte in the here document.
5793         Instead, use a marker, "@", and filter through tr to create the desired
5794         contents.  Reported as <http://bugs.debian.org/548493> by Kurt Roeckx.
5795
5796 2009-09-27  Bruno Haible  <bruno@clisp.org>
5797
5798         Disable untested support for new flavours of ACLs on AIX.
5799         * lib/file-has-acl.c (file_has_acl): Mark newer AIX code as work in
5800         progress.
5801         * lib/set-mode-acl.c (qset_acl): Likewise.
5802
5803 2008-12-07  Bruno Haible  <bruno@clisp.org>
5804
5805         Add support for new flavours of ACLs on AIX. (Untested.)
5806         * lib/file-has-acl.c [AIX] (acl_nfs4_nontrivial): New function.
5807         (file_has_acl): Add support for newer AIX.
5808         * lib/set-mode-acl.c (qset_acl): Likewise.
5809         * tests/test-sameacls.c (main): Fix use of aclx_get function. Hint by
5810         Rainer Tammer <tammer@tammer.net>.
5811
5812 2009-09-26  Eric Blake  <ebb9@byu.net>
5813
5814         argp: fix compilation of getopt
5815         * lib/getopt.in.h (includes): Use different guard than glibc.
5816         Reported by Sergey Poznyakoff.
5817
5818         doc: mention more cygwin 1.7 status
5819         * doc/posix-functions/access.texi (access): Mention cygwin 1.5
5820         bug.
5821         * doc/posix-functions/execl.texi (execl): Likewise.
5822         * doc/posix-functions/execle.texi (execle): Likewise.
5823         * doc/posix-functions/execlp.texi (execlp): Likewise.
5824         * doc/posix-functions/execv.texi (execv): Likewise.
5825         * doc/posix-functions/execve.texi (execve): Likewise.
5826         * doc/posix-functions/execvp.texi (execvp): Likewise.
5827         * doc/glibc-functions/canonicalize_file_name.texi
5828         (canonicalize_file_name): Cygwin 1.7 now provides this.
5829         * doc/glibc-functions/euidaccess.texi (euidaccess): Likewise.
5830         * doc/posix-functions/fchmodat.texi (fchmodat): Mention limitation
5831         on AT_SYMLINK_NOFOLLOW.
5832
5833 2009-09-24  Eric Blake  <ebb9@byu.net>
5834
5835         test-linkat: make test more robust
5836         * tests/test-linkat.c (main): Avoid collision with EEXIST.
5837
5838         getopt: fix inclusion guards for cygwin
5839         * modules/getopt-posix (Depends-on): Add include-next.
5840         (Makefile.am): Substitute more items in replacement header.
5841         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Also check for native
5842         <getopt.h>.
5843         * lib/getopt.in.h (includes): Use split inclusion guard, and
5844         prefer <getopt.h> over include <unistd.h> when one is present.
5845         (option): Also override name of 'struct option'.
5846
5847         same-inode: revert prior change; it is not yet ready
5848         * NEWS: Undo mention of this change.
5849         * lib/same-inode.h (same-inode.h): Undo tri-state change.
5850         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Update caller.
5851         * lib/cycle-check.c (cycle_check): Likewise.
5852         * lib/same.c (same_name): Likewise.
5853         * lib/at-func2.c (at_func2): Likewise.
5854
5855 2009-09-23  Eric Blake  <ebb9@byu.net>
5856
5857         linkat: new module
5858         * modules/linkat: New file.
5859         * lib/at-func2.c (at_func2): Likewise.
5860         * lib/linkat.c (linkat): Likewise.
5861         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
5862         * lib/openat-priv.h (at_func2): Add declaration.
5863         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witnesses.
5864         * modules/unistd (Makefile.am): Substitute them.
5865         * lib/unistd.in.h (linkat): Declare it.
5866         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
5867         * doc/posix-functions/linkat.texi (linkat): Likewise.
5868         * doc/posix-functions/link.texi (link): Tweak wording.
5869         * tests/test-link.c (main): Move guts...
5870         * tests/test-link.h (test_link): ...into new file.
5871         * modules/linkat-tests: New test.
5872         * tests/test-linkat.c: Likewise.
5873         * modules/link-tests (Files): Ship new file.
5874         (Depends-on): Add stdbool.
5875
5876         dirname: add library-safe mdir_name
5877         * lib/dirname.h (mdir_name): New prototype.
5878         * lib/dirname.c (dir_name): Move guts...
5879         (mdir_name): ...to new function that avoids xalloc_die.
5880
5881         fchdir: another mingw fix
5882         * modules/fchdir (Depends-on): Drop canonicalize-lgpl.
5883         * lib/fchdir.c (get_name): New helper method; skips canonicalize
5884         on mingw (where it has not yet been ported), and make it optional
5885         elsewhere.
5886         (_gl_register_fd): Use it.
5887
5888         same-inode: make SAME_INODE tri-state, to port to mingw
5889         * NEWS: Mention this change.
5890         * lib/same-inode.h (same-inode.h): Recognize mingw limitation of
5891         st_ino always being 0.
5892         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Update caller.
5893         * lib/cycle-check.c (cycle_check): Likewise.
5894         * lib/same.c (same_name): Likewise.
5895
5896         lstat: avoid mingw compilation error
5897         * m4/lstat.m4 (gl_FUNC_LSTAT): Avoid duplicate calls to
5898         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK, and deal with missing
5899         lstat ourselves.
5900         * lib/lstat.c [!HAVE_LSTAT]: Do nothing if <sys/stat.h> override
5901         was adequate.
5902         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Let lstat module handle
5903         the checks for lstat.
5904         (gl_SYS_STAT_H_DEFAULTS): Set default for HAVE_LSTAT.
5905
5906         link: fix test failure on Solaris 9
5907         * lib/link.c (rpl_link): Don't assume link will catch bogus
5908         trailing slash on source.
5909
5910         test-symlinkat: enhance test
5911         * tests/test-readlink.c (main): Move guts...
5912         * tests/test-readlink.h (test_readlink): ...into new file.
5913         * tests/test-symlink.c (main): Move guts...
5914         * tests/test-symlink.h (test_symlink): ...into new file.
5915         * tests/test-symlinkat.c (main): Use new files for further
5916         coverage.
5917         (do_symlink, do_readlink): New helper functions.
5918         * modules/symlink-tests (Files): Ship new file.
5919         (Depends-on): Add stdbool.
5920         * modules/readlink-tests (Files): Ship new file.
5921         (Depends-on): Add stdbool.
5922         * modules/symlinkat-tests (Files): Use new files.
5923
5924 2009-09-23  Eric Blake  <ebb9@byu.net>
5925
5926         readlink: document portability issue with symlink length
5927         * doc/posix-functions/lstat.texi (lstat): Mention that some file
5928         systems have bogus st_size on symlinks, and mention the
5929         areadlink-with-size module.
5930         * doc/posix-functions/fstatat.texi (fstatat): Likewise.
5931         * doc/posix-functions/readlink.texi (readlink): Mention the
5932         areadlink module, and ERANGE failure.
5933         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
5934         * tests/test-readlink.c (main): Relax test for AIX, HP-UX.
5935
5936         readlink: fix Solaris 9 bug with trailing slash
5937         * lib/readlink.c (rpl_readlink): Work around trailing slash bug.
5938         * m4/readlink.m4 (gl_FUNC_READLINK): Detect the bug.
5939         * doc/posix-functions/readlink.texi (readlink): Document this.
5940         * modules/readlink-tests: New test.
5941         * tests/test-readlink.c: Likewise.
5942
5943         readlink: fix cygwin 1.5.x bug with return type
5944         * m4/readlink.m4 (gl_FUNC_READLINK): Require correct signature.
5945         * lib/unistd.in.h (readlink): Use ssize_t.
5946         * lib/readlink.c (readlink): Likewise.
5947         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
5948         * modules/unistd (Makefile.am): Substitute it.
5949         * lib/unistd.in.h (readlink): Declare replacement.
5950         * doc/posix-functions/readlink.texi (readlink): Document this.
5951
5952         symlink: use throughout gnulib
5953         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Omit symlink check.
5954         * lib/symlinkat.c (symlinkat) [!HAVE_SYMLINK]: Document why
5955         symlink is not used.
5956         * modules/symlinkat (Depends-on): Add symlink.
5957         * modules/canonicalize-lgpl-tests (Depends-on): Likewise.
5958         * modules/canonicalize-tests (Depends-on): Likewise.
5959         * modules/lstat-tests (Depends-on): Likewise.
5960         * modules/openat-tests (Depends-on): Likewise.
5961         * modules/remove-tests (Depends-on): Likewise.
5962         * modules/rmdir-tests (Depends-on): Likewise.
5963         * modules/unlink-tests (Depends-on): Likewise.
5964         * tests/test-canonicalize-lgpl.c (symlink): Delete stub.
5965         * tests/test-canonicalize.c (symlink): Likewise.
5966         * tests/test-fstatat.c (symlink): Likewise.
5967         * tests/test-lstat.c (symlink): Likewise.
5968         * tests/test-remove.c (symlink): Likewise.
5969         * tests/test-rmdir.c (symlink): Likewise.
5970         * tests/test-unlink.c (symlink): Likewise.
5971         * tests/test-unlinkat.c (symlink): Likewise.
5972
5973         symlink: new module, for Solaris 9 bug
5974         * modules/symlink: New file.
5975         * m4/symlink.m4 (gl_FUNC_SYMLINK): Likewise.
5976         * lib/symlink.c: Likewise.
5977         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add defaults.
5978         * modules/unistd (Makefile.am): Substitute them.
5979         * lib/unistd.in.h (symlink): Declare replacement.
5980         * MODULES.html.sh (File system functions): Mention it.
5981         * doc/posix-functions/symlink.texi (symlink): Likewise.
5982         * modules/symlink-tests: New test.
5983         * tests/test-symlink.c: Likewise.
5984
5985 2009-09-23  Bruno Haible  <bruno@clisp.org>
5986
5987         * gnulib-tool (func_import): Add 'link-warning' to testsrelated_modules
5988         when needed.
5989         Test case: gnulib-tool --import --with-tests atexit inttypes.
5990         Reported by Pauli Miettinen <pauli.miettinen@cs.helsinki.fi>.
5991
5992 2009-09-23  Bruno Haible  <bruno@clisp.org>
5993
5994         * gnulib-tool (func_emit_tests_Makefile_am): Set uses_subdirs in a
5995         subcommand, not in a subshell.
5996
5997 2009-09-22  Eric Blake  <ebb9@byu.net>
5998
5999         unistd: sort replacement declarations
6000         * lib/unistd.in.h: Sort declarations.
6001
6002         open, openat: minor optimization
6003         * lib/open.c (open): If open succeeded, len is non-zero.
6004         * lib/openat.c (rpl_openat): Likewise.
6005
6006         link-follow: ensure correct result
6007         * m4/fcntl_h.m4 (gl_FCNTL_H): Clean up temporary file.
6008         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Likewise, and
6009         distinguish between possible failures.
6010
6011 2009-09-21  Eric Blake  <ebb9@byu.net>
6012
6013         fts: avoid compiler warning
6014         * lib/fts.c (dirent_inode_sort_may_be_useful)
6015         (leaf_optimization_applies) [!__linux__]: Mark unused parameters.
6016
6017 2009-09-19  Bruno Haible  <bruno@clisp.org>
6018
6019         * lib/progreloc.c (canonicalize_file_name): New declaration.
6020
6021 2009-09-19  Eric Blake  <ebb9@byu.net>
6022
6023         link: fix quoting
6024         * m4/link.m4 (gl_FUNC_LINK): Fix shell quoting.
6025
6026         openat: fix openat bugs on Solaris 9
6027         * lib/openat.c (rpl_openat): Work around Solaris 9 bug.
6028         * m4/openat.m4 (gl_FUNC_OPENAT): Also replace openat on Solaris.
6029         * modules/openat (Depends-on): Add open.
6030         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Provide new default.
6031         * modules/fcntl-h (Makefile.am): Substitute it.
6032         * lib/fcntl.in.h (openat): Declare replacement.
6033         * doc/posix-functions/openat.texi (openat): Document this.
6034
6035         openat: move fstatat and unlinkat into correct files
6036         * m4/openat.m4 (gl_FUNC_OPENAT): Adjust which files will be
6037         compiled.
6038         * lib/openat.c (fstatat, unlinkat): Move...
6039         * lib/fstatat.c (fstatat): ...into correct files.
6040         * lib/unlinkat.c (unlinkat): Likewise.
6041
6042         openat: fix unlinkat bugs on Solaris 9
6043         * lib/unlinkat.c (unlinkat): New file.
6044         * modules/openat (Depends-on): Add unlink.
6045         (Files): Distribute it.
6046         * m4/openat.m4 (gl_FUNC_OPENAT): Mark unlinkat for replacement if
6047         trailing slash behavior is broken.
6048         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
6049         * modules/unistd (Makefile.am): Substitute it.
6050         * lib/unistd.in.h (unlinkat): Declare replacement.
6051         * doc/posix-functions/unlinkat.texi (unlinkat): Document this.
6052
6053         openat: fix fstatat bugs on Solaris 9
6054         * lib/fstatat.c (rpl_fstatat): Copy recent fixes from lstat and
6055         stat.
6056         * doc/posix-functions/fstatat.texi (fstatat): Document this.
6057
6058         test-unlinkat: enhance test, to expose Solaris 9 bug
6059         * tests/test-unlink.c (main): Factor guts...
6060         * tests/test-unlink.h (test_rmdir_func): ...into new file.
6061         * tests/test-rmdir.h (test_rmdir_func): Add parameter.
6062         * tests/test-rmdir.c (main): Adjust caller.
6063         * tests/test-unlinkat.c (main): Likewise.  Add unlink tests.
6064         (unlinker): New helper function.
6065         (rmdirat): Enhance check.
6066         * modules/rmdir-tests (Depends-on): Add stdbool.
6067         * modules/unlink-tests (Depends-on): Likewise.
6068         (Files): Add test-unlink.h.
6069         * modules/openat-tests (Files): Likewise.
6070         (Depends-on): Add unlinkdir.
6071
6072         test-fstatat: new test, to expose Solaris 9 bugs
6073         * tests/test-stat.c (main): Factor guts...
6074         * tests/test-stat.h (test_stat_func): ...into new file.
6075         * tests/test-lstat.c (main): Factor guts...
6076         * tests/test-lstat.h (test_lstat_func): ...into new file.
6077         * tests/test-fstatat.c: New file.
6078         * modules/stat-tests (Files): Add test-stat.h.
6079         * modules/lstat-tests (Files): Add test-lstat.h.
6080         (Depends-on): Add stdbool.
6081         * modules/openat-tests (Depends-on): Add pathmax.
6082         (Files): Add test-lstat.h, test-stat.h, test-fstatat.c.
6083         (Makefile.am): Run new test.
6084
6085         remove: new module, for mingw and Solaris 9 bugs
6086         * modules/remove: New file.
6087         * lib/remove.c: Likewise.
6088         * m4/remove.m4 (gl_FUNC_REMOVE): Likewise.
6089         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add witnesses.
6090         * modules/stdio (Makefile.am): Use them.
6091         * lib/stdio.in.h (remove): Declare replacement.
6092         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
6093         * doc/posix-functions/remove.texi (remove): Likewise.
6094         * modules/remove-tests: New test.
6095         * tests/test-remove.c: Likewise.
6096
6097         unlink: new module, for Solaris 9 bug
6098         * modules/unlink: New file.
6099         * lib/unlink.c: Likewise.
6100         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
6101         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witnesses.
6102         * modules/unistd (Makefile.am): Use them.
6103         * lib/unistd.in.h (stat): Declare replacement.
6104         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
6105         * doc/posix-functions/unlink.texi (unlink): Likewise.
6106         * modules/unlink-tests: New test.
6107         * tests/test-unlink.c: Likewise.
6108
6109         lstat: fix Solaris 9 bug
6110         * lib/lstat.c (lstat): Also check for trailing slash on
6111         non-symlink, non-directories.  Use stat module to simplify logic.
6112         * doc/posix-functions/lstat.texi (lstat): Document it.
6113         * modules/lstat-tests (Depends-on): Add errno, same-inode.
6114         (configure.ac): Check for symlink.
6115         * tests/test-lstat.c (main): Add more tests.
6116
6117         stat: add as dependency to other modules
6118         * modules/chown (Depends-on): Add stat.
6119         * modules/euidaccess (Depends-on): Likewise.
6120         * modules/fchdir (Depends-on): Likewise.
6121         * modules/isdir (Depends-on): Likewise.
6122         * modules/link (Depends-on): Likewise.
6123         * modules/lstat (Depends-on): Likewise.
6124         * modules/mkdir-p (Depends-on): Likewise.
6125         * modules/modechange (Depends-on): Likewise.
6126         * modules/open (Depends-on): Likewise.
6127         * modules/readlink (Depends-on): Likewise.
6128         * modules/same (Depends-on): Likewise.
6129
6130         stat: fix Solaris 9 bug
6131         * m4/stat.m4 (gl_FUNC_STAT): Detect Solaris 9 bug with trailing
6132         slash.
6133         * lib/stat.c (rpl_stat): Work around it.
6134         * doc/posix-functions/stat.texi (stat): Update documentation.
6135
6136         stat: new module, for mingw bug
6137         * modules/stat: New file.
6138         * lib/stat.c: Likewise.
6139         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
6140         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
6141         * modules/sys_stat (Makefile.am): Use them.
6142         * lib/sys_stat.in.h (stat): Declare replacement.
6143         * lib/openat.c (fstatat): Deal with lstat and stat being function
6144         macros.
6145         * modules/openat (Depends-on): Add inline.
6146         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
6147         * doc/posix-functions/stat.texi (stat): Likewise.
6148         * modules/stat-tests: New test.
6149         * tests/test-stat.c: Likewise.
6150
6151 2009-09-19  Jim Meyering  <meyering@redhat.com>
6152
6153         syntax-check: detect unnecessary inclusion of canonicalize.h
6154         * top/maint.mk (sc_prohibit_canonicalize_without_use): New rule.
6155
6156 2009-09-19  Eric Blake  <ebb9@byu.net>
6157
6158         canonicalize-lgpl: adjust clients to use correct header
6159         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
6160         (gl_CANONICALIZE_LGPL): Use correct shell quoting.
6161         * modules/relocatable-prog-wrapper (Files): Drop canonicalize.h.
6162         * lib/fchdir.c (includes): Use <stdlib.h>, not "canonicalize.h".
6163         * lib/progreloc.c (includes): Likewise.
6164
6165 2009-09-19  Jim Meyering  <meyering@redhat.com>
6166
6167         test-posixtm.c: correct a comment
6168         * tests/test-posixtm.c: Correct first-line comment.
6169         Spotted by Eric Blake.
6170
6171 2009-09-16  Jim Meyering  <meyering@redhat.com>
6172
6173         posixtm-tests: make T const-correct; add a test case
6174         * tests/test-posixtm.c (T): Declare const.
6175         Add a test for -(2^31+1).
6176         Remove useless can-succeed-only-in-2002 test.
6177
6178         posixtm-tests: adjust the sole failing test
6179         * tests/test-posixtm.c: Correct 0000-01-01 00:00:00 test so that
6180         expected output matches what mktime now produces.  Cross-checked via
6181         erlang's calendar:datetime_to_gregorian_seconds({{1970,1,1},{0,0,0}})
6182
6183         posixtm: move #ifdef'd tests into a new module
6184         * lib/posixtm.c (posixtime): Remove #ifdef'd tests.  Move to...
6185         * tests/test-posixtm.c: ... this new file.
6186         * modules/posixtm-tests: New module.
6187
6188 2009-09-19  Eric Blake  <ebb9@byu.net>
6189
6190         openat: simplify use of at-func.c
6191         * lib/at-func.c (includes): Include prerequisites here, to
6192         simplify requirements on client files.
6193         * lib/openat-priv.h: Add double-inclusion guard.
6194         * lib/faccessat.c (includes): Simplify.
6195         * lib/fchmodat.c (includes): Likewise.
6196         * lib/fchownat.c (includes): Likewise.
6197         * lib/mkdirat.c (includes): Likewise.
6198         * lib/mkfifoat.c (includes): Likewise.
6199         * lib/symlinkat.c (includes): Likewise.
6200
6201         openat: allow return of fd 0
6202         * modules/chdir-long (Depends-on): Relax openat-safer to openat.
6203         * modules/save-cwd (Depends-on): Replace fcntl-safer with
6204         unistd-safer.
6205         * lib/chdir-long.c (includes): Replace "fcntl--.h" with
6206         <fcntl.h>; this module does not leak fds.
6207         * lib/openat.c (includes): Do not use "fcntl_safer"; plain openat
6208         must be allowed to return 0, leaving openat_safer to add the
6209         safety.
6210         (openat_permissive): Avoid writing to just-opened fd 2 if
6211         restoring the current directory fails.
6212         * lib/openat-die.c (openat_restore_fail): Add comment.
6213         * lib/save-cwd.c (includes): Make "fcntl--.h" conditional.
6214         (save_cwd): Guarantee safe fd, but without use of open_safer.
6215         * tests/test-openat.c: New test.
6216         * modules/openat-tests (Files, Makefile.am): Distribute and build
6217         new file.
6218
6219         relocatable-prog-wrapper: fix build
6220         * modules/relocatable-prog-wrapper (Files): Update name of
6221         canonicalize m4 file, broken on 2009-09-17.
6222         Reported by emad hajjar <aleppos@hotmail.com>.
6223
6224 2009-09-19  Bruno Haible  <bruno@clisp.org>
6225
6226         * lib/safe-alloc.h: Use the standard header with GPL copyright.
6227         * lib/safe-alloc.c: Likewise.
6228         Reported by Ian Beckwith <ianb@erislabs.net>.
6229
6230 2009-09-18  Bruno Haible  <bruno@clisp.org>
6231
6232         * gnulib-tool: Add advice to "cannot find configure.ac" error message.
6233         Reported by <erobles@sensacd.com.mx>.
6234
6235 2009-09-17  Eric Blake  <ebb9@byu.net>
6236
6237         canonicalize: in CAN_ALL_BUT_LAST, allow trailing slash
6238         * lib/canonicalize.c (canonicalize_filename_mode): Skip trailing
6239         slashes when checking if last component is missing.
6240         * tests/test-canonicalize.c (main): Test this.
6241
6242         canonicalize, canonicalize-lgpl: honor // if distinct from /
6243         * modules/canonicalize (Files): Add double-slash-root.m4.
6244         * modules/canonicalize-lgpl (Files): Likewise.
6245         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
6246         (gl_CANONICALIZE_LGPL_SEPARATE): Add dependency.
6247         * lib/canonicalize.c (DOUBLE_SLASH_IS_DISTINCT_ROOT): Provide
6248         fallback definition.
6249         (canonicalize_filename_mode): Use it to protect //.
6250         * lib/canonicalize-lgpl.c (DOUBLE_SLASH_IS_DISTINCT_ROOT)
6251         (__realpath): Likewise.
6252         * tests/test-canonicalize.c (main): Test this.
6253         * tests/test-canonicalize-lgpl.c (main): Likewise.
6254         * modules/canonicalize-tests (Depends-on): Add same-inode.
6255         * modules/canonicalize-lgpl-tests (Depends-on): Likewise.
6256
6257         canonicalize-lgpl: fix glibc bug with trailing slash
6258         * m4/canonicalize-lgpl.m4: Move contents...
6259         * m4/canonicalize.m4: ...here.
6260         (gl_CANONICALIZE_LGPL): Factor realpath check...
6261         (gl_FUNC_REALPATH_WORKS): ...into new macro.  Enhance to catch
6262         glibc 2.3.5 bug, fixed 2005-04-27.
6263         (gl_FUNC_CANONICALIZE_FILENAME_MODE): Use it.
6264         (gl_PREREQ_CANONICALIZE_LGPL): Inline...
6265         (gl_CANONICALIZE_LGPL_SEPARATE): ...into this macro.
6266         * modules/canonicalize-lgpl (Files): Manage file rename.
6267         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Provide default.
6268         * modules/stdlib (Makefile.am): Substitute witness.
6269         * lib/stdlib.in.h (canonicalize_file_name): Declare if replacement
6270         is needed.
6271         * lib/canonicalize-lgpl.c: Also compile if canonicalize_file_name
6272         replacement is required.
6273         * lib/canonicalize.c (canonicalize_file_name): Likewise.
6274         * doc/glibc-functions/canonicalize_file_name.texi
6275         (canonicalize_file_name): Document this.
6276         * doc/posix-functions/realpath.texi (realpath): Likewise.
6277
6278         canonicalize-lgpl: reject non-directory with trailing slash
6279         * lib/canonicalize-lgpl.c (__realpath): Synchronize with glibc.
6280         * tests/test-canonicalize-lgpl.c (main): Enhance test.  This
6281         catches failures in glibc 2.3.5.
6282         * tests/test-canonicalize.c (main): Likewise.
6283
6284         canonicalize-lgpl: use native realpath if it works
6285         * lib/canonicalize-lgpl.c (realpath): Guard with
6286         FUNC_REALPATH_WORKS.
6287         * lib/stdlib.in.h (realpath): Make declaration optional based on
6288         HAVE_REALPATH.
6289         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL): Check whether
6290         native realpath works.
6291         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Provide default.
6292         * modules/stdlib (Makefile.am): Substitute witness.
6293
6294         canonicalize, canonicalize-lgpl: use <stdlib.h>
6295         * modules/canonicalize-lgpl (Files): Drop canonicalize.h.
6296         (Include): Mention <stdlib.h>.
6297         (configure.ac): Mention functions we provide.
6298         * modules/canonicalize (configure.ac): Likewise.
6299         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL): Always replace
6300         realpath if canonicalize_file_name is missing.
6301         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Provide defaults.
6302         * modules/stdlib (Makefile.am): Substitute witnesses.
6303         * lib/stdlib.in.h (canonicalize_file_name, realpath): Declare.
6304         * lib/canonicalize-lgpl.c (includes): Adjust accordingly.
6305         * lib/canonicalize.h (canonicalize_file_name): Drop declaration.
6306         * NEWS: Document this.
6307         * doc/glibc-functions/canonicalize_file_name.texi
6308         (canonicalize_file_name): Likewise.
6309         * doc/posix-functions/realpath.texi (realpath): Likewise.
6310         * tests/test-canonicalize-lgpl.c (includes): Use <stdlib.h>.
6311
6312         test-canonicalize: consolidate into single C program
6313         * tests/test-canonicalize.sh: Delete; move setup into...
6314         * tests/test-canonicalize.c (main): ...the program, making it
6315         easier to run in debugger.  Add some tests.
6316         * modules/canonicalize-tests (Files): Remove unused file.
6317         (Depends-on): Add progname.
6318         (configure.ac, Makefile.am): Simplify.
6319
6320         test-canonicalize-lgpl: consolidate into single C program
6321         * tests/test-canonicalize-lgpl.sh: Delete; move setup into...
6322         * tests/test-canonicalize-lgpl.c (main): ...the program, making it
6323         easier to run in debugger.  Add some tests.
6324         * modules/canonicalize-lgpl-tests (Files): Remove unused file.
6325         (configure.ac, Makefile.am): Simplify.
6326
6327         canonicalize: avoid resolvepath
6328         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE): Delete
6329         unnecessary checks.
6330         * lib/canonicalize.c (includes): Simplify.
6331         (canonicalize_file_name): Drop resolvepath implementation.
6332         * modules/canonicalize (Depends-on): Drop filenamecat.
6333
6334         canonicalize: don't lose errno
6335         * lib/canonicalize.c (canonicalize_filename_mode): Protect errno
6336         over calls to free.
6337
6338         canonicalize: simplify errno handling
6339         * lib/canonicalize.c (__set_errno): Delete macro, and use direct
6340         assignment.
6341
6342         canonicalize, canonicalize-lgpl: update module dependencies
6343         * modules/canonicalize (Depends-on): Add extensions, lstat,
6344         pathmax, stdlib.
6345         (Files): Drop pathmax.h.
6346         (configure.ac): Adjust macro name.
6347         * modules/canonicalize-lgpl (Depends-on): Add errno, extensions,
6348         lstat, stdlib, sys_stat.
6349         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Rename...
6350         (gl_FUNC_CANONICALIZE_FILENAME_MODE): ...to this, and require
6351         extensions.
6352         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL)
6353         (gl_CANONICALIZE_LGPL_SEPARATE): Require extensions.
6354         (gl_PREREQ_CANONICALIZE_LGPL): Assume unistd.h.
6355         * lib/canonicalize.h (canonicalize_file_name): Use <stdlib.h>
6356         declaration, if available.
6357         * lib/canonicalize-lgpl.c [HAVE_READLINK]: Delete this condition;
6358         we can rely on the readlink module.
6359         (MAXSYMLINKS): Also consult SYMLOOP_MAX.
6360         (includes): Use <unistd.h> unconditionally.
6361
6362 2009-09-17  Eric Blake  <ebb9@byu.net>
6363
6364         maint: make Include sections of modules consistent
6365         * modules/alloca: Use only header name; no need to list #include.
6366         * modules/alloca-opt: Likewise.
6367         * modules/arpa_inet: Likewise.
6368         * modules/canon-host: Likewise.
6369         * modules/configmake: Likewise.
6370         * modules/dirent: Likewise.
6371         * modules/eealloc: Likewise.
6372         * modules/environ: Likewise.
6373         * modules/fchdir: Likewise.
6374         * modules/fcntl: Likewise.
6375         * modules/fcntl-h: Likewise.
6376         * modules/gethrxtime: Likewise.
6377         * modules/gettime: Likewise.
6378         * modules/ignore-value: Likewise.
6379         * modules/inet_ntop: Likewise.
6380         * modules/inet_pton: Likewise.
6381         * modules/inttypes: Likewise.
6382         * modules/isnand-nolibm: Likewise.
6383         * modules/isnanf-nolibm: Likewise.
6384         * modules/mbchar: Likewise.
6385         * modules/mbfile: Likewise.
6386         * modules/mbiter: Likewise.
6387         * modules/mbuiter: Likewise.
6388         * modules/netdb: Likewise.
6389         * modules/netinet_in: Likewise.
6390         * modules/nproc: Likewise.
6391         * modules/pagealign_alloc: Likewise.
6392         * modules/poll: Likewise.
6393         * modules/printf-frexp: Likewise.
6394         * modules/pthread: Likewise.
6395         * modules/putenv: Likewise.
6396         * modules/random_r: Likewise.
6397         * modules/relocatable-prog: Likewise.
6398         * modules/search: Likewise.
6399         * modules/select: Likewise.
6400         * modules/selinux-h: Likewise.
6401         * modules/settime: Likewise.
6402         * modules/signal: Likewise.
6403         * modules/size_max: Likewise.
6404         * modules/socklen: Likewise.
6405         * modules/ssize_t: Likewise.
6406         * modules/stdarg: Likewise.
6407         * modules/stdbool: Likewise.
6408         * modules/stddef: Likewise.
6409         * modules/stdint: Likewise.
6410         * modules/stdio: Likewise.
6411         * modules/stdlib: Likewise.
6412         * modules/string: Likewise.
6413         * modules/strings: Likewise.
6414         * modules/sys_file: Likewise.
6415         * modules/sys_ioctl: Likewise.
6416         * modules/sys_select: Likewise.
6417         * modules/sys_socket: Likewise.
6418         * modules/sys_stat: Likewise.
6419         * modules/sys_time: Likewise.
6420         * modules/sys_times: Likewise.
6421         * modules/sys_utsname: Likewise.
6422         * modules/sys_wait: Likewise.
6423         * modules/sysexits: Likewise.
6424         * modules/time: Likewise.
6425         * modules/times: Likewise.
6426         * modules/tmpfile: Likewise.
6427         * modules/trim: Likewise.
6428         * modules/unistd: Likewise.
6429         * modules/wchar: Likewise.
6430         * modules/wctype: Likewise.
6431
6432 2009-09-17  Bruno Haible  <bruno@clisp.org>
6433
6434         Make getdate.y compile on QNX and NetBSD 5 / i386.
6435         * m4/getdate.m4 (gl_GETDATE): Conditionally define
6436         TIME_T_FITS_IN_LONG_INT.
6437         * lib/getdate.y (long_time_t): New type.
6438         (relative_time): Change type of 'seconds' field to long_time_t.
6439         (get_date): Update types of local variables. Check against overflow
6440         during conversion from long_time_t to time_t.
6441         Reported by Matt Kraai <kraai@ftbfs.org>
6442         and Hasso Tepper <hasso@netbsd.org>.
6443
6444 2009-09-17  Bruno Haible  <bruno@clisp.org>
6445
6446         * modules/COPYING: Update copyright years.
6447         * modules/README: Likeiwse.
6448         * doc/gnulib-intro.texi (Copyright): Use a wildcard year.
6449         Reported by Ian Beckwith <ianb@erislabs.net>.
6450
6451 2009-09-17  Ian Beckwith  <ianb@erislabs.net>  (tiny change)
6452
6453         * users.txt: Update references for gnuit package.
6454
6455 2009-09-17  Ian Beckwith  <ianb@erislabs.net>  (tiny change)
6456
6457         * m4/getdelim.m4: Fix typo in copyright line.
6458
6459 2009-09-17  Bruno Haible  <bruno@clisp.org>
6460
6461         * lib/atoll.c: Use the standard header with GPL copyright.
6462         * lib/argz.in.h: Likewise.
6463         * lib/glob.c: Likewise.
6464         * lib/glob-libc.h: Likewise.
6465         * lib/random_r.c: Likewise.
6466         * lib/siglist.h: Likewise.
6467         * lib/strsignal.c: Likewise.
6468         Reported by Ian Beckwith <ianb@erislabs.net>.
6469
6470 2009-09-17  Eric Blake  <ebb9@byu.net>
6471
6472         rmdir: ensure correct dependency order
6473         * m4/rmdir.m4 (gl_FUNC_RMDIR): Require unistd defaults.
6474
6475 2009-09-17  Bruno Haible  <bruno@clisp.org>
6476
6477         Disable assertion that fails on NetBSD 5 / i386.
6478         * lib/mktime.c (ydhms_diff): Disable assertion about time_t size.
6479         Reported by Sam Steingold <sds@gnu.org>
6480         and Hasso Tepper <hasso@netbsd.org>.
6481
6482 2009-09-16  Eric Blake  <ebb9@byu.net>
6483
6484         unlinkdir: port to mingw
6485         * m4/unlinkdir.m4 (gl_UNLINKDIR): Add mingw to list of platforms
6486         on which no one can unlink a directory.
6487
6488         stdlib: sort witness names
6489         * modules/stdlib (Makefile.am): Sort replacements.
6490         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
6491         * lib/stdlib.in.h: Likewise.
6492
6493         parse-duration-tests: avoid link failure
6494         * modules/parse-duration-tests (test_parse_duration_LDADD): Add
6495         LIBINTL.
6496         Reported by Tom G. Christensen.
6497
6498         openat-tests: ensure unlinkat behaves like rmdir
6499         * tests/test-rmdir.c (main): Factor guts...
6500         * tests/test-rmdir.h (test_rmdir_func): ...into new file.
6501         * modules/rmdir-tests (Files): Ship new file.
6502         * modules/openat-tests: New test.
6503         * tests/test-unlinkat.c: Likewise.
6504
6505         rmdir-errno: mark obsolete, it is unsafe for cross-compilation
6506         * modules/rmdir-errno (Status, Notice): Now obsolete.
6507
6508         rmdir: work around cygwin 1.5.x and mingw bugs
6509         * m4/rmdir.m4 (gl_FUNC_RMDIR): Detect the bugs.
6510         * lib/rmdir.c (rmdir): Work around it.
6511         * modules/rmdir (Status, Notice): No longer obsolete.
6512         (Files): Add dos.m4.
6513         (Depends-on): Add unistd.
6514         (configure.ac): Set witnesses.
6515         (License): Relax to LGPLv2+.
6516         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set defaults.
6517         * modules/unistd (Makefile.am): Substitute witnesses.
6518         * lib/unistd.in.h (rmdir): Declare replacement.
6519         * doc/posix-functions/rmdir.texi (rmdir): Document this.
6520         * modules/rmdir-tests: New tests.
6521         * tests/test-rmdir.c: Likewise.
6522
6523 2009-09-15  Eric Blake  <ebb9@byu.net>
6524
6525         fchdir: improve use of replacement functions
6526         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Set appropriate witnesses.
6527         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add REPLACE_FSTAT.
6528         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Add REPLACE_OPENDIR,
6529         REPLACE_CLOSEDIR.
6530         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add REPLACE_DUP.
6531         * modules/sys_stat (Makefile.am): Substitute correct witness.
6532         * modules/dirent (Makefile.am): Likewise.
6533         * modules/unistd (Makefile.am): Likewise.
6534         * lib/dirent.in.h (opendir, closedir): Use better witnesses.
6535         * lib/unistd.in.h (dup): Likewise.
6536         * lib/sys_stat.in.h (fstat): Likewise.
6537
6538         maint: ignore gnulib-tool temp files
6539         * .gitignore: Ignore files created during gnulib-tool --test.
6540
6541 2009-09-13  Jim Meyering  <meyering@redhat.com>
6542
6543         posixtm: don't reject a time that specify "60" as the number of seconds
6544         * lib/posixtm.c (posixtime): The code to reject invalid dates
6545         would also reject a time specified with the .60 suffix.
6546         But POSIX allows that, in order to accommodate leap seconds.
6547         So don't reject it.
6548         (main): Adjust tests accordingly.
6549         * modules/posixtm (Depends-on): Add stpcpy.
6550
6551 2009-09-11  Jim Meyering  <meyering@redhat.com>
6552
6553         announce-gen: include [$release_type] in emitted Subject:
6554         * build-aux/announce-gen (get_tool_versions): Include [$release_type],
6555         e.g., [stable] in the emitted Subject: line.
6556
6557 2009-09-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6558
6559         Remove obsolete macros from several modules.
6560         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Replace
6561         obsolete Autoconf macros with their modern counterparts.
6562         * m4/check-math-lib.m4 (gl_CHECK_MATH_LIB): Likewise.
6563         * m4/gc-camellia.m4 (gl_GC_CAMELLIA): Likewise.
6564         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Likewise.
6565         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
6566         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Likewise.
6567         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
6568         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Likewise.
6569         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Likewise.
6570         * m4/poll.m4 (gl_FUNC_POLL): Likewise.
6571         * m4/readline.m4 (gl_FUNC_READLINE): Likewise.
6572         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
6573         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
6574         * m4/select.m4 (gl_FUNC_SELECT): Likewise.
6575         * m4/sockets.m4 (gl_SOCKETS): Likewise.
6576         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Likewise.
6577         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Likewise.
6578         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
6579         * m4/time_r.m4 (gl_TIME_R): Likewise.
6580         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Likewise.
6581         * m4/vararrays.m4 (AC_C_VARARRAYS): Likewise.
6582         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
6583
6584         Fix copyright header in build-aux scripts.
6585         * build-aux/git-version-gen: Fix copyright header to match GPLv3
6586         recommendation.
6587         * build-aux/ncftpput-ftp: Likewise.
6588         * build-aux/update-copyright: Likewise.
6589
6590 2009-09-09  Eric Blake  <ebb9@byu.net>
6591
6592         test-link: allow Linux choice of errno
6593         * tests/test-link.c (main): Relax test for alternate error.
6594
6595         strndup: fix improper m4 caching
6596         * m4/strndup.m4 (gl_FUNC_STRNDUP): Rework to avoid side effects
6597         inside AC_CACHE_CHECK.  Use REPLACE_STRNDUP, not HAVE_STRNDUP.
6598         (gl_PREREQ_STRNDUP): Delete.
6599         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Update default.
6600         * modules/string (Makefile.am): Substitute it.
6601         * lib/string.in.h (strndup): Modernize prototype.
6602
6603         getcwd: port to mingw
6604         * m4/getcwd.m4 (gl_FUNC_GETCWD): Mingw directories are very
6605         different from the POSIX assumptions made throughout the getcwd
6606         module; fortunately, the mingw getcwd does not need replacement.
6607         (gl_FUNC_GETCWD_NULL): Skip test on mingw.
6608         * modules/getcwd-tests: New test.
6609         * tests/test-getcwd.c: Likewise.
6610
6611         link: fix platform bugs
6612         * m4/link.m4 (gl_FUNC_LINK): Detect Solaris and Cygwin bugs.
6613         * lib/link.c (link): Work around them.  Fix related mingw bug.
6614         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add REPLACE_LINK.
6615         * modules/unistd (Makefile.am): Substitute it.
6616         * lib/unistd.in.h (link): Declare replacement.
6617         * doc/posix-functions/link.texi (link): Document this.
6618         * modules/link (Depends-on): Add strdup-posix, sys_stat.
6619
6620         test-link: consolidate into single C program, test more cases
6621         * tests/test-link.sh: Delete.
6622         * tests/test-link.c: Test more error conditions.  Exposes bugs on
6623         at least Cygwin and Solaris.
6624         * modules/link-tests (Files): Remove unused file.
6625         (Depends-on): Add errno, sys_stat.
6626         (Makefile.am): Simplify.
6627
6628 2009-09-08  Bruno Haible  <bruno@clisp.org>
6629
6630         Work around towlower, towupper bug on mingw.
6631         * lib/wctype.in.h (towlower, towupper) [__MINGW32__]: New replacements.
6632         * m4/wctype.m4 (gl_WCTYPE_H): Replace <wctype.h> also on mingw.
6633         * doc/posix-functions/towlower.texi: Mention the mingw bug.
6634         * doc/posix-functions/towupper.texi: Likewise.
6635         Reported by Eric Blake.
6636
6637 2009-09-08  Jim Meyering  <meyering@redhat.com>
6638
6639         build: don't try to run autoheader if we don't use it
6640         * build-aux/bootstrap: Define AUTOHEADER=true when AC_CONFIG_HEADERS
6641         is not used in configure.ac.
6642
6643 2009-09-08  Eric Blake  <ebb9@byu.net>
6644
6645         euidaccess: fix compilation error
6646         * lib/euidaccess.c (includes): Add <fcntl.h>, for AT_EACCESS.
6647
6648         rawmemchr: relax license
6649         * modules/rawmemchr (License): Derived from glibc, so LGPLv2+ is
6650         okay.
6651         Reported by Jim Meyering.
6652
6653         mkfifoat: new module
6654         * modules/mkfifoat: New file.
6655         * lib/mkfifoat.c: Likewise.
6656         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Likewise.
6657         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
6658         * modules/sys_stat (Makefile.am): Use them.
6659         * lib/sys_stat.in.h (mkfifoat, mknodat): Declare them.
6660         * MODULES.html.sh (File system functions): Mention module.
6661         * doc/posix-functions/mkfifoat.texi (mkfifoat): Likewise.
6662         * doc/posix-functions/mknodat.texi (mknodat): Likewise.
6663         * modules/mkfifoat-tests: New test.
6664         * tests/test-mkfifoat.c: Likewise.
6665
6666         strchrnul: relax license
6667         * modules/strchrnul (License): Derived from glibc, so LGPLv2+ is
6668         okay.
6669         Reported by Jim Meyering.
6670
6671 2009-09-08  Eric Blake  <ebb9@byu.net>
6672
6673         fstatat: fix compilation on Solaris
6674         * lib/fstatat.c (includes): Add fcntl.h.
6675         Reported by Pádraig Brady.
6676
6677 2009-09-07  Eric Blake  <ebb9@byu.net>
6678
6679         rename: modernize replacement
6680         * modules/rename (Depends-on): Add stdio.
6681         (configure.ac): Declare witness.
6682         * m4/rename.m4 (gl_FUNC_RENAME): Ensure dependency order, and let
6683         stdio take care of replacement.
6684         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add new defaults.
6685         * modules/stdio (Makefile.am): Substitute them.
6686         * lib/stdio.in.h (rename): Declare replacement.
6687         * lib/rename.c (includes): Allow cross-compilation to non-windows
6688         machines.
6689         * doc/posix-functions/rename.texi (rename): Improve
6690         documentation.
6691
6692         stdio: sort witness names
6693         * modules/stdio (Makefile.am): Sort replacements.
6694         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
6695         * lib/stdio.in.h: Likewise.
6696
6697         getcwd: minor cleanups
6698         * lib/getcwd.c (AT_FDCWD): Delete; rely on <fcntl.h> instead.
6699         (is_ENAMETOOLONG): Delete; ENAMETOOLONG is portable.
6700
6701         openat: provide more convenience names
6702         * modules/faccessat (configure.ac): Add C witness.
6703         * lib/unistd.in.h (readlinkat): Fix typo.
6704         * lib/openat.h (statat, lstatat, accessat, euidaccessat): New
6705         convenience wrappers.
6706         * top/maint.mk (sc_prohibit_openat_without_use): Allow these
6707         wrappers in syntax checks.
6708
6709 2009-09-06  Eric Blake  <ebb9@byu.net>
6710
6711         doc: fix comments in recent patches
6712         * lib/faccessat.c: Mention correct function.
6713         * lib/fchmodat.c: Likewise.
6714         * lib/fchownat.c: Likewise.
6715         * lib/symlinkat.c: Likewise.
6716         * doc/posix-headers/fcntl.texi (fcntl.h): Cygwin 1.7 has AT_*
6717         constants.
6718
6719         faccessat, symlinkat: continue cleanup of previous patch
6720         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Ensure dependency order.
6721         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Likewise.
6722         * modules/unistd (Makefile.am): Substitute GNULIB_READLINKAT.
6723         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Offer GNULIB_READLINKAT.
6724         * modules/symlinkat (configure.ac): Set GNULIB_READLINKAT.
6725         * lib/unistd.in.h (readlinkat): Declare if GNULIB_READLINKAT is
6726         set.
6727
6728 2009-09-06  Bruno Haible  <bruno@clisp.org>
6729
6730         * lib/sys_stat.in.h (fchmodat): Declare if GNULIB_FCHMODAT is set.
6731         (fstatat): Declare if GNULIB_FSTATAT is set.
6732         (mkdirat): Declare if GNULIB_MKDIRAT is set.
6733         * lib/unistd.in.h (fchownat): Declare if GNULIB_FCHOWNAT is set.
6734         (unlinkat): Declare if GNULIB_UNLINKAT is set.
6735         * modules/fcntl-h (Files): Remove m4/openat.m4.
6736         * modules/sys_stat (Files): Remove m4/openat.m4.
6737         (Makefile.am): Substitute GNULIB_FCHMODAT, GNULIB_FSTATAT,
6738         GNULIB_MKDIRAT instead of GNULIB_OPENAT.
6739         * modules/unistd (Files): Remove m4/openat.m4.
6740         (Makefile.am): Substitute GNULIB_FCHOWNAT, GNULIB_UNLINKAT instead of
6741         GNULIB_OPENAT.
6742         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Initialize GNULIB_OPENAT,
6743         HAVE_OPENAT here. Don't require gl_OPENAT_DEFAULTS.
6744         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize
6745         GNULIB_FCHMODAT, GNULIB_FSTATAT, GNULIB_MKDIRAT, HAVE_FCHMODAT,
6746         HAVE_FSTATAT, HAVE_MKDIRAT, REPLACE_FSTATAT here. Don't require
6747         gl_OPENAT_DEFAULTS.
6748         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_FCHOWNAT,
6749         GNULIB_UNLINKAT, HAVE_FCHOWNAT, HAVE_UNLINKAT, REPLACE_FCHOWNAT here.
6750         Don't require gl_OPENAT_DEFAULTS.
6751         * m4/openat.m4 (gl_FUNC_OPENAT): Require gl_FCNTL_H_DEFAULTS,
6752         gl_SYS_STAT_H_DEFAULTS, gl_UNISTD_H_DEFAULTS. Set GNULIB_FCHMODAT,
6753         GNULIB_FSTATAT, GNULIB_MKDIRAT, GNULIB_FCHOWNAT, GNULIB_UNLINKAT.
6754         (gl_OPENAT_DEFAULTS): Remove macro.
6755
6756 2009-09-06  Bruno Haible  <bruno@clisp.org>
6757
6758         * modules/openat (configure.ac): Remove unneeded witness.
6759
6760 2009-09-06  Bruno Haible  <bruno@clisp.org>
6761
6762         Set errno to ENOSYS when a function is entirely unsupported.
6763         * lib/chown.c (rpl_chown) [!HAVE_CHOWN]: Set errno to ENOSYS instead of
6764         EOPNOTSUPP.
6765         * lib/lchown.c (lchown) [!HAVE_CHOWN]: Likewise.
6766         * modules/chown (Depends-on): Remove errno.
6767
6768 2009-09-06  Bruno Haible  <bruno@clisp.org>
6769
6770         * doc/posix-headers/fcntl.texi (AT_*): Mention affected platforms.
6771
6772 2009-09-06  Bruno Haible  <bruno@clisp.org>
6773
6774         * lib/sys_stat.in.h: Fix preprocessor command indentation.
6775
6776 2009-09-06  Ben Pfaff  <blp@gnu.org>
6777             Bruno Haible  <bruno@clisp.org>
6778
6779         Work around a glibc bug in strtok_r.
6780         * lib/string.in.h (strtok_r): Replace if REPLACE_STRTOK_R is set.
6781         Undefine if UNDEFINE_STRTOK_R is set.
6782         * lib/strtok_r.c (strtok_r, __strtok_r) [!_LIBC]: Don't undefine.
6783         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
6784         REPLACE_STRTOK_R and UNDEFINE_STRTOK_R.
6785         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Check against the glibc bug.
6786         * modules/string (Makefile.am): Substitute REPLACE_STRTOK_R,
6787         UNDEFINE_STRTOK_R.
6788         * doc/posix-functions/strtok_r.texi: Mention the glibc 2.7 bug.
6789
6790 2009-09-06  Sergey Poznyakoff  <gray@gnu.org.ua>
6791
6792         exclude: minor fix
6793         * lib/exclude.c: Include wctype.h
6794
6795 2009-09-06  Akim Demaille  <demaille@gostai.com>
6796
6797         bootstrap: improve error message
6798         * build-aux/bootstrap (find_tool): Upon failure, report the list
6799         of candidates.
6800         Honor the initial value of the envvar.
6801
6802 2009-09-05  Eric Blake  <ebb9@byu.net>
6803
6804         symlinkat: new module
6805         * modules/symlinkat: New file.
6806         * lib/symlinkat.c: Likewise.
6807         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Likewise.
6808         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witnesses.
6809         * modules/unistd (Makefile.am): Use them.
6810         * lib/unistd.in.h (symlinkat, readlinkat): Declare them.
6811         (faccessat) [GNULIB_POSIXCHECK]: Fix typo.
6812         * lib/at-func.c (FUNC_RESULT): New macro, defaulting to int.
6813         * MODULES.html.sh (File system functions): Mention module.
6814         * doc/posix-functions/symlinkat.texi (symlinkat): Likewise.
6815         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
6816         * modules/symlinkat-tests: New test.
6817         * tests/test-symlinkat.c: Likewise.
6818
6819         test-openat-safer: add more checks
6820         * tests/test-openat-safer.c (main): Check more code paths.
6821
6822 2009-09-05  Jim Meyering  <meyering@redhat.com>
6823
6824         syntax-check: detect unnecessary inclusion of openat.h
6825         * top/maint.mk (sc_prohibit_openat_without_use): New rule.
6826
6827 2009-09-05  Bruno Haible  <bruno@clisp.org>
6828
6829         Support towlower, towupper.
6830         * doc/posix-functions/towlower.texi: Mention module wctype.
6831         * doc/posix-functions/towupper.texi: Likewise.
6832         * lib/wctype.in.h (towlower, towupper): New functions.
6833         * tests/test-wctype.c: Include stdio.h, stdlib.h.
6834         (ASSERT): New macro.
6835         (e): New variable.
6836         (main): Test also towlower, towupper. Test WEOF argument.
6837         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
6838
6839 2009-09-05  Bruno Haible  <bruno@clisp.org>
6840
6841         Fix conversion behaviour when the input is invalid.
6842         * lib/striconveh.c (mem_cd_iconveh_internal): Fix storing of question
6843         mark occurring in first pass of indirect conversion.
6844         * tests/test-striconveh.c (main): Test conversion of invalid ASCII
6845         input.
6846         Found by clang's static analyzer.
6847
6848 2009-09-05  Bruno Haible  <bruno@clisp.org>
6849
6850         * tests/test-striconveh.c (main): Test indirect conversion on platforms
6851         where direct conversion is possible.
6852
6853 2009-09-04  Eric Blake  <ebb9@byu.net>
6854
6855         openat: fail with ENOENT on empty name
6856         * lib/openat-proc.c (openat_proc_name): Special-case the empty
6857         buffer.
6858
6859         link-follow: fix logic bug in prior patch
6860         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Fix bug that
6861         reversed sense of yes and no in prior patch.  Avoid confusing
6862         compilation failure with desired semantics.
6863
6864         link-follow: accomodate mingw and cross-compilation
6865         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Rename...
6866         (gl_FUNC_LINK_FOLLOWS_SYMLINK): ...to this.  Change
6867         cross-compilation results to -1, to make linkat easier to
6868         implement when cross-compiling.  Trivially support mingw.
6869         * modules/link-follow (configure.ac): Call new name.
6870         * NEWS: Mention this.
6871
6872 2009-09-03  Eric Blake  <ebb9@byu.net>
6873
6874         faccessat: compile replacement
6875         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Build replacement when
6876         needed.
6877
6878         fts: fix compilation error
6879         * lib/fts.c (includes): Re-add "openat.h", for
6880         openat_needs_fchdir.
6881
6882         faccessat: new module
6883         * modules/faccessat: New file.
6884         * lib/faccessat.c: Likewise.
6885         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Likewise.
6886         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
6887         * modules/unistd (Makefile.am): Use it.
6888         * lib/unistd.in.h (faccessat): Declare it.
6889         (F_OK, X_OK, W_OK, R_OK): Provide definitions.
6890         * lib/fcntl.in.h (AT_SYMLINK_FOLLOW, AT_EACCESS): Likewise.
6891         * MODULES.html.sh (File system functions): Mention it.
6892         * doc/posix-functions/faccessat.texi (faccessat): Likewise.
6893         * doc/posix-headers/fcntl.texi (fcntl.h): Likewise.
6894
6895         euidaccess: prefer POSIX over non-standard implementation
6896         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Check for faccessat.
6897         * lib/euidaccess.c (euidaccess): Use it if available.
6898
6899         openat: make template easier to use
6900         * lib/at-func.c (CALL_FUNC): Allow AT_FUNC_USE_F1_COND and
6901         AT_FUNC_F2 to be undefined.
6902         (VALIDATE_FLAG): New macro; use it to reject bad flags.
6903         (AT_FUNC_USE_F1_COND): Change sense to just flag bit.
6904         * lib/fchmodat.c (AT_FUNC_USE_F1_COND): Adjust.
6905         * lib/fchownat.c (AT_FUNC_USE_F1_COND): Likewise.
6906         * lib/openat.c (AT_FUNC_USE_F1_COND) [fstatat, unlinkat]:
6907         Likewise.
6908         * lib/mkdirat.c (AT_FUNC_F2, AT_FUNC_USE_F1_COND): Delete.
6909         * lib/selinux-at.c (AT_FUNC_F2, AT_FUNC_USE_F1_COND)
6910         [getfileconat, lgetfileconat, setfileconat, lsetfileconat]:
6911         Likewise.
6912
6913         openat: declare in POSIX headers
6914         * NEWS: Mention this.
6915         * modules/openat (configure.ac): Declare witnesses.
6916         (Depends-on): Add fcntl-h, sys_stat, unistd.
6917         (Include): Mention correct headers.
6918         * modules/fcntl-h (Depends-on): Add link-warning.
6919         (Files): Add openat.m4.
6920         (Makefile.am): Substitute witnesses.
6921         * modules/sys_stat (Files, Makefile.am): Likewise.
6922         * modules/unistd (Files, Makefile.am): Likewise.
6923         * m4/openat.m4 (gl_FUNC_OPENAT, gl_FUNC_FCHOWNAT): Set witnesses.
6924         (gl_OPENAT_DEFAULTS): New macro.
6925         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Use it.
6926         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Likewise.
6927         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Likewise.
6928         (SYS_STAT_H): Remove unused variable.
6929         * doc/posix-headers/fcntl.texi (fcntl.h): Update content.
6930         * lib/fcntl--.h (includes): Remove unneeded header.
6931         * lib/openat-safer.c (includes): Likewise.
6932         * lib/openat.h (AT_FDCWD, AT_SYMLINK_NOFOLLOW, AT_REMOVEDIR)
6933         (openat, fstatat, unlinkat, mkdirat, fchmodat, fchownat): Move to
6934         appropriate headers.
6935         (__OPENAT_PREFIX): Delete.
6936         * lib/fcntl.in.h (openat): Provide declaration.
6937         (AT_FDCWD): Fix Solaris bug.
6938         (AT_SYMLINK_NOFOLLOW, AT_REMOVEDIR): Provide macros.
6939         * lib/sys_stat.in.h (fstatat, mkdirat): Provide declaration.
6940         * lib/fchmodat.c (includes):  Adjust to find declaration.
6941         * lib/fchownat.c (includes): Likewise.
6942         * lib/mkdirat.c (includes): Likewise.
6943         * lib/fstatat.c (includes): Likewise.  Ensure original fstatat is
6944         still visible.
6945
6946 2009-09-02  Eric Blake  <ebb9@byu.net>
6947
6948         errno: use consistently
6949         * lib/c-stack.c (ENOTSUP): <errno.h> guarantees a definition.
6950         * lib/canonicalize-lgpl.c (ENAMETOOLONG): Likewise.
6951         * lib/canonicalize.c (ELOOP): Likewise.
6952         * lib/inet_ntop.c (EAFNOSUPPORT): Likewise.
6953         * lib/inet_pton.c (EAFNOSUPPORT): Likewise.
6954         * lib/lchown.c (EOPNOTSUPP): Likewise.
6955         * lib/openat-priv.h (ENOSYS, EOPNOTSUPP): Likewise.
6956         * lib/savewd.c (ESTALE): Likewise.
6957         * lib/settime.c (ENOSYS): Likewise.
6958         * lib/utimens.c (ENOSYS): Likewise.
6959         * lib/xgethostname.c (ENAMETOOLONG): Likewise.
6960         * lib/chdir-safer.c (ELOOP): Likewise.
6961         (chdir_no_follow): Use HAVE_READLINK, not ELOOP, as witness.
6962         * modules/c-stack (Depends-on): Add errno.
6963         * modules/canonicalize (Depends-on): Likewise.
6964         * modules/chdir-safer (Depends-on): Likewise.
6965         * modules/fdopendir (Depends-on): Likewise.
6966         * modules/inet_ntop (Depends-on): Likewise.
6967         * modules/inet_pton (Depends-on): Likewise.
6968         * modules/lchown (Depends-on): Likewise.
6969         * modules/openat (Depends-on): Likewise.
6970         * modules/savewd (Depends-on): Likewise.
6971         * modules/settime (Depends-on): Likewise.
6972         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Check for readlink.
6973
6974         fts: avoid leaking fds
6975         * modules/fts (Depends-on): Add cloexec.
6976         * lib/fts.c (opendirat, diropen, fts_build): Set close-on-exec
6977         flag.
6978
6979         fts: make directory fds more robust
6980         * lib/fts.c (O_DIRECTORY): Let <fcntl.h> take care of this.
6981         (opendirat): Specify O_DIRECTORY, and add fallbacks for safety.
6982
6983         backupfile, chdir-long, fts, savedir: make safer
6984         * lib/backupfile.c (includes): Use "dirent--.h", since
6985         numbered_backup can write to stderr during readdir.
6986         * lib/savedir.c (includes): Likewise.
6987         * lib/chdir-long.c (includes): Use "fcntl--.h", since openat
6988         emulation can write to stderr on failure.
6989         * lib/fts.c (includes) [!_LIBC]: Likewise for opendir and openat.
6990         * lib/getcwd.c: Document why opendir_safer is unused.
6991         * lib/glob.c: Likewise.
6992         * lib/scandir.c: Likewise.
6993         * lib/openat-proc.c: Likewise, for open_safer.
6994         * modules/backupfile (Depends-on): Add dirent-safer.
6995         * modules/savedir (Depends-on): Likewise.
6996         * modules/fts (Depends-on): Add dirent-safer and openat-safer.
6997         * modules/chdir-long (Depends-on): Add openat-safer.
6998
6999         openat-safer: new module
7000         * modules/openat-safer: New file.
7001         * lib/openat-safer.c: Likewise.
7002         * m4/fcntl-safer.m4 (gl_OPENAT_SAFER): New macro.
7003         * lib/fcntl-safer.h (openat_safer): Declare.
7004         * lib/fcntl--.h (openat): Override.
7005         * MODULES.html.sh (File descriptor based I/O): Mention it.
7006         * lib/openat.h: Add double-inclusion guards.
7007         * lib/openat.c (includes): Only include "fcntl-safer.h", not
7008         "fcntl--.h", so we can implement openat.
7009         * modules/openat-safer-tests: New test.
7010         * tests/test-openat-safer.c: New file.
7011
7012         dirent-safer: new module
7013         * modules/dirent-safer: New file.
7014         * lib/dirent--.h: Likewise.
7015         * lib/dirent-safer.h: Likewise.
7016         * lib/opendir-safer.c: Likewise.
7017         * m4/dirent-safer.m4: Likewise.
7018         * MODULES.html.sh (Enhancements for POSIX:2008): Mention it.
7019         * modules/dirent-safer-tests: New test.
7020         * tests/test-dirent-safer.c: New file.
7021         * lib/fdopendir.c (includes): Ensure fdopendir is also safe.
7022
7023         fdopendir: optimize on mingw
7024         * lib/unistd.in.h (_gl_directory_name): New prototype.
7025         * lib/fchdir.c (_gl_directory_name): Implement it.
7026         (fchdir): Use it to simplify implementation.
7027         * lib/fdopendir.c (fdopendir) [REPLACE_FCHDIR]: Use metadata from
7028         fchdir, when available, to avoid calling [f]chdir().
7029
7030         fdopendir: split into its own module
7031         * lib/openat.c (fdopendir): Move...
7032         * lib/fdopendir.c: ...into new file.
7033         * modules/fdopendir: New module.
7034         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): New file.
7035         * modules/openat (Depends-on): Add fdopendir.
7036         * m4/openat.m4 (gl_FUNC_OPENAT): No longer need to check for
7037         fdopendir here.
7038         * modules/savedir (Depends-on): Only need fdopendir, not full
7039         openat.
7040         * lib/savedir.c (include): Use <dirent.h>, not "openat.h".
7041         * lib/openat.h (fdopendir): Drop prototype.
7042         * lib/dirent.in.h (fdopendir): Provide prototype.
7043         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Add replacements.
7044         * modules/dirent (Makefile.am): Substitute them.
7045         * MODULES.html.sh (File system functions): Mention it.
7046         * doc/posix-functions/fdopendir.texi (fdopendir): Likewise.
7047         * modules/fdopendir-tests: New file.
7048         * tests/test-fdopendir.c: Likewise.
7049
7050         fchdir: use more consistent macro convention
7051         * lib/fcntl.in.h (_gl_register_fd): Move declaration to unistd.
7052         * lib/sys_stat.in.h (rpl_fstat): Declare via make-time
7053         REPLACE_FCHDIR, rather than relying on config.h macros.
7054         * lib/unistd.in.h (fchdir): Move all fchdir internal declarations
7055         inside a single make-time REPLACE_FCHDIR block, rather than using
7056         the config.h FCHDIR_REPLACEMENT.
7057         * m4/fchdir.m4 (gl_FUNC_FCHDIR): REPLACE_FCHDIR was already
7058         AC_SUBST'd, also AC_DEFINE it.  Don't define FCHDIR_REPLACEMENT.
7059         Manage fstat replacement.
7060         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Pick up
7061         REPLACE_FCHDIR.
7062         * modules/sys_stat (Files): Add m4/unistd_h.m4.
7063         (Makefile.am): Substitute REPLACE_FCHDIR.
7064         * lib/close.c (rpl_close): Use REPLACE_FCHDIR, not
7065         FCHDIR_REPLACEMENT.
7066         * lib/dup-safer.c (dup_safer): Likewise.
7067         * lib/dup2.c (rpl_dup2): Likewise.
7068         * lib/dup3.c (rpl_dup3): Likewise.
7069         * lib/open.c (rpl_open): Likewise.
7070
7071         fchdir: simplify error handling, and support dup3
7072         * modules/fchdir (Depends-on): Use strdup-posix, not strdup.  Add
7073         stdbool, malloc-posix, realloc-posix.
7074         * lib/fchdir.c (struct dir_info_t): Delete saved_errno.
7075         (ensure_dirs_slot): Return false on allocation failure.
7076         (rpl_dup2): Delete.
7077         (_gl_register_dup): New function.
7078         (_gl_unregister_fd, rpl_opendir, rpl_dup): Update callers.
7079         (_gl_register_fd): Close fd on allocation failure.
7080         * lib/fcntl.in.h (_gl_register_fd): Update signature.
7081         * lib/unistd.in.h (_gl_register_dup) [FCHDIR_REPLACEMENT]: New
7082         prototype.
7083         (rpl_dup2_fchdir): Delete prototype.
7084         * lib/open.c (open): Update caller.
7085         * lib/dup2.c (dup2): Track fchdir metadata.
7086         * lib/dup3.c (dup3): Likewise.
7087         * m4/dup2.m4 (gl_REPLACE_DUP2): New macro.
7088         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Use it.
7089
7090 2009-09-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7091
7092         * gnulib-tool (func_create_testdir, func_create_megatestdir): Use
7093         AC_CONFIG_HEADERS instead of AM_CONFIG_HEADER. Use AC_CONFIG_FILES and
7094         don't pass arguments to AC_OUTPUT.
7095
7096 2009-09-02  Bruno Haible  <bruno@clisp.org>
7097
7098         * modules/mkdtemp (License): Relicense under LGPLv2+.
7099         Reported by Paolo Bonzini.
7100
7101 2009-09-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7102
7103         Replace uses of obsolete autoconf macros in Jim's modules.
7104         The Autoconf macros AC_TRY_CPP, AC_TRY_COMPILE, AC_TRY_LINK and
7105         AC_TRY_RUN have been obsolete since Autoconf 2.55, and each use
7106         can evoke a warning from autoconf when run with -Wobsolete
7107         enabled.  They were declared obsolete for good reasons (see
7108         the `AC_FOO_IFELSE vs AC_TRY_FOO' node in the Autoconf manual,
7109         recently renamed to `AC_ACT_IFELSE vs AC_TRY_ACT'), and we
7110         should not continue using the deprecated macros.
7111         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Replace
7112         obsolete Autoconf macros with modern counterparts.
7113         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
7114         * m4/dos.m4 (gl_AC_DOS): Likewise.
7115         * m4/fpending.m4 (gl_FUNC_FPENDING): Likewise.
7116         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Likewise.
7117         * m4/getloadavg.m4 (gl_PREREQ_GETLOADAVG): Likewise.
7118         * m4/jm-winsz1.m4 (gl_WINSIZE_IN_PTEM): Likewise.
7119         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Likewise.
7120         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Likewise.
7121         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Likewise.
7122         * m4/mode_t.m4 (gl_PROMOTED_TYPE_MODE_T): Likewise.
7123         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
7124         Likewise.
7125         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
7126         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
7127         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Likewise.
7128         * m4/st_dm_mode.m4 (AC_STRUCT_ST_DM_MODE): Likewise.
7129         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
7130         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
7131
7132 2009-09-01  Eric Blake  <ebb9@byu.net>
7133
7134         fchdir: fix off-by-one bug in previous patch
7135         * lib/fchdir.c (rpl_fstat): Use correct bounds.
7136         (_gl_unregister_fd): Delete useless if.
7137
7138 2009-09-01  Daniel P. Berrange  <berrange@redhat.com>
7139
7140         maint.mk: sort the list of syntax-check rules
7141         * top/maint.mk (syntax-check-rules): Sort syntax-check rules, so it's
7142         easier to get a sense of progress when the rules are run sequentially
7143         and take a long time.
7144
7145 2009-09-01  Simon Josefsson  <simon@josefsson.org>
7146
7147         * modules/arpa_inet: Use $(MKDIR_P) instead of @MKDIR_P@.
7148         * modules/netinet_in: Likewise.
7149         * modules/sys_file: Likewise.
7150         * modules/sys_ioctl: Likewise.
7151         * modules/sys_select: Likewise.
7152         * modules/sys_socket: Likewise.
7153         * modules/sys_stat: Likewise.
7154         * modules/sys_time: Likewise.
7155         * modules/sys_times: Likewise.
7156         * modules/sys_utsname: Likewise.
7157         * modules/sys_wait: Likewise.
7158
7159 2009-09-01  Jim Meyering  <meyering@redhat.com>
7160
7161         fts: help ensure that return values are not ignored
7162         * lib/fts_.h (__GNUC_PREREQ): Define.
7163         (__attribute_warn_unused_result__): Define.
7164         (fts_children, fts_close, fts_open, fts_read): Declare with
7165         __attribute_warn_unused_result__.
7166
7167         fts: fts_close now fails also when closing a dir file descriptor fails
7168         * lib/fts.c (fts_close): Detect close failure, not just fchdir failure,
7169         and propagate to caller, along with errno.
7170
7171         announce-gen: correct formatting in --help output
7172         * build-aux/announce-gen (usage): Move the one-line description in
7173         --help output "up", to where it belongs, just after Usage:.
7174
7175 2009-08-31  Eric Blake  <ebb9@byu.net>
7176
7177         fchdir: port to mingw
7178         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Check for mingw bug.
7179         * lib/open.c (open) [FCHDIR_REPLACEMENT]: If directories can't be
7180         opened, then use a substitute.
7181         * lib/sys_stat.in.h (fstat) [REPLACE_OPEN_DIRECTORY]: Declare
7182         replacement.
7183         * lib/fchdir.c (fstat) [REPLACE_OPEN_DIRECTORY]: Implement it.
7184         (_gl_register_fd): No need to check stat if open already filters
7185         all directories.
7186         (fchdir): Fix error condition to match POSIX.
7187         * modules/fchdir (Depends-on): Add sys_stat.
7188         * doc/posix-functions/open.texi (open): Document the limitation.
7189         * modules/fchdir-tests: New file.
7190         * tests/test-fchdir.c: Likewise.
7191
7192         canonicalize: allow cross-testing from cygwin to mingw
7193         * modules/canonicalize-tests (configure.ac): Define HAVE_SYMLINK.
7194         (Makefile.am): Pass it through TESTS_ENVIRONMENT.
7195         * modules/canonicalize-lgpl-tests (configure.ac, Makefile.am):
7196         Likewise.
7197         * tests/test-canonicalize.sh: Also skip test if 'ln -s' works, but
7198         target does not support symlinks.
7199         * tests/test-canonicalize-lgpl.sh: Likewise.
7200
7201         chown: avoid compilation warning on mingw
7202         * m4/chown.m4 (gl_FUNC_CHOWN): Recognize missing chown.
7203         * lib/chown.c (rpl_chown) [!HAVE_CHOWN]: Always return failure on
7204         mingw.
7205         * lib/lchown.c (lchown) [!HAVE_CHOWN]: Likewise.
7206         * modules/chown (Depends-on): Add errno.
7207
7208 2009-08-31  Stefano Lattarini  <stefano.lattarini@gmail.com>  (tiny change)
7209
7210         * gnulib-tool: Fix test whether $CONFIG_SHELL has a working 'echo'
7211         command.
7212
7213 2009-08-31  Jim Meyering  <meyering@redhat.com>
7214
7215         canonicalize: remove useless initialization
7216         * lib/canonicalize.c (canonicalize_filename_mode): Remove useless
7217         initialization of local, "end".
7218
7219 2009-08-30  Bruno Haible  <bruno@clisp.org>
7220
7221         Fix an unnecessary error on Solaris 10 on NFSv3 file systems.
7222         * lib/set-mode-acl.c (qset_acl) [Solaris 10 new]: Treat EOPNOTSUPP like
7223         ENOSYS.
7224
7225 2009-08-30  Bruno Haible  <bruno@clisp.org>
7226
7227         * tests/test-pipe-filter-ii1.sh: Prefer /usr/xpg6/bin/tr over
7228         /usr/xpg4/bin/tr when it exists.
7229         * tests/test-pipe-filter-gi1.sh: Likewise.
7230
7231 2009-08-30  Bruno Haible  <bruno@clisp.org>
7232
7233         Work around deficient /usr/bin/id program on Solaris.
7234         * tests/test-file-has-acl.sh (ID): New variable.
7235         * tests/test-set-mode-acl.sh (ID): Likewise.
7236         * tests/test-copy-acl.sh (ID): Likewise.
7237         * tests/test-copy-file.sh (ID): Likewise.
7238
7239 2009-08-30  Bruno Haible  <bruno@clisp.org>
7240
7241         New module 'xstriconveh'.
7242         * lib/xstriconveh.h: New file.
7243         * lib/xstriconveh.c: New file.
7244         * modules/xstriconveh: New file.
7245
7246 2009-08-30  Bruno Haible  <bruno@clisp.org>
7247
7248         Make it easier to use mem_cd_iconveh.
7249         * lib/striconveh.h (iconveh_t): New type.
7250         (iconveh_open, iconveh_close): New declarations.
7251         (mem_cd_iconveh, str_cd_iconveh): Replace the three iconv_t arguments
7252         with a single 'const iconveh_t *' argument.
7253         * lib/striconveh.c (iconveh_open, iconveh_close): New functions.
7254         (mem_cd_iconveh, str_cd_iconveh): Replace the three iconv_t arguments
7255         with a single 'const iconveh_t *' argument.
7256         (mem_iconveh, str_iconveh): Use iconveh_open, iconveh_close.
7257         * tests/test-striconveh.c (main): Update.
7258         * NEWS: Mention the change.
7259
7260 2009-08-30  Bruno Haible  <bruno@clisp.org>
7261
7262         * doc/posix-functions/iconv_open.texi: Mention indirect conversion
7263         problem.
7264
7265 2009-08-30  Bruno Haible  <bruno@clisp.org>
7266
7267         Work around iconv_open problem on Solaris.
7268         * lib/iconv_open-solaris.gperf: New file.
7269         * lib/iconv_open.c (ICONV_FLAVOR_SOLARIS): New macro.
7270         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Also handle Solaris.
7271         * modules/iconv_open (Files): Add lib/iconv_open-solaris.gperf.
7272         (Makefile.am): Add rule for iconv_open-solaris.h. Augment
7273         BUILT_SOURCES, MOSTLYCLEANFILES, MAINTAINERCLEANFILES, EXTRA_DIST.
7274         * doc/posix-functions/iconv_open.texi: Mention the Solaris problem.
7275
7276 2009-08-29  Jim Meyering  <meyering@redhat.com>
7277
7278         maint.mk: remove more coreutils-specific targets; XZ_OPT=-9ev
7279         * top/maint.mk (cvs-check): Remove target; it was just an alias
7280         to the better-named vc-diff-check.
7281         (maintainer-distcheck): Remove rule.  It was used only from
7282         the (alpha/beta/major) target, and all of its commands but one
7283         were coreutils-specific.
7284         (vc-dist): Remove rule.
7285         (alpha beta major): Run "$(MAKE) distcheck" explicitly.
7286         Run vc-diff-check, not vc-dist.
7287         Run $(MAKE) dist with XZ_OPT=-9ev.  Note spelling, with "-".
7288
7289 2009-08-27  Bruno Haible  <bruno@clisp.org>
7290
7291         * tests/test-bitrotate.c (main): Remove test that uses a shift count
7292         of 0.
7293
7294 2009-08-27  Bruno Haible  <bruno@clisp.org>
7295
7296         * tests/test-func.c (main): Don't verify sizeof __func__ on SunPRO C
7297         compilers.
7298         * doc/func.texi: Document the SunPRO C bug.
7299
7300 2009-08-27  Bruno Haible  <bruno@clisp.org>
7301
7302         Fix link error on Solaris.
7303         * tests/test-parse-duration.c (xstrdup): Remove function.
7304
7305 2009-08-26  Pádraig Brady  <P@draigbrady.com>
7306
7307         ignore-value: handle pointer types, too
7308         * lib/ignore-value.h (__attribute__): Remove definition.
7309         (ignore_value): Remove use of "__attribute__ ((unused))" in favor
7310         of a more concise and more-often effective "(void) i" statement.
7311         (ignore_ptr): New function to suppress warnings from functions that
7312         return pointers, and to make it explicit that one function doesn't
7313         handle all cases.
7314
7315 2009-08-25  Bruno Haible  <bruno@clisp.org>
7316
7317         dup2: work around a Linux bug.
7318         * m4/dup2.m4 (gl_FUNC_DUP2): Test for the Linux bug.
7319         * lib/dup2.c (rpl_dup2): Correct the return value if it is -EBADF.
7320         * doc/posix-functions/dup2.texi: Mention the Linux bug.
7321         Reported by Simon Josefsson.
7322
7323 2009-08-25  Jim Meyering  <meyering@redhat.com>
7324
7325         libguestfs uses gnulib
7326         * users.txt: Add libguestfs.
7327
7328 2009-08-24  Eric Blake  <ebb9@byu.net>
7329
7330         dup2, pipe2: fix some recent test failures on cygwin 1.5.x
7331         * lib/pipe2.c (includes): Add binary-io.h.
7332         * lib/dup2.c (rpl_dup2): Correct buggy errno value.
7333
7334 2009-08-24  Bruno Haible  <bruno@clisp.org>
7335
7336         Tolerate declared but missing accept4 syscall.
7337         * lib/accept4.c (accept4): Invoke original accept4 function first, if
7338         available.
7339         * lib/sys_socket.in.h (accept4): If the function is already present,
7340         override it.
7341         * m4/accept4.m4 (gl_FUNC_ACCEPT4): Remove AC_LIBOBJ invocation.
7342         * modules/accept4 (Makefile.am): Compile accept4.c always.
7343         Reported by Paolo Bonzini and Eric Blake.
7344
7345 2009-08-23  Bruno Haible  <bruno@clisp.org>
7346
7347         New module 'accept4'.
7348         * lib/sys_socket.in.h (accept4): New declaration.
7349         * lib/accept4.c: New file.
7350         * m4/accept4.m4: New file.
7351         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Initialize
7352         GNULIB_ACCEPT4, HAVE_ACCEPT4.
7353         * modules/sys_socket (Makefile.am): Substitute GNULIB_ACCEPT4,
7354         HAVE_ACCEPT4.
7355         * modules/accept4: New file.
7356         * doc/glibc-functions/accept4.texi: Mention the new module.
7357
7358 2009-08-24  Jim Meyering  <meyering@redhat.com>
7359
7360         progname: also set global program_invocation_name, when possible
7361         Before this change, a libtool-enabled program that calls glibc's
7362         error function would report the program name as
7363         "/abs/dir/.libs/lt-program_name" rather than the desired program_name.
7364         * modules/progname (configure.ac): Check for a declaration of
7365         program_invocation_name.
7366         * lib/progname.c:  Include <errno.h>.
7367         (set_program_name) [HAVE_DECL_PROGRAM_INVOCATION_NAME]:
7368         Set program_invocation_name.
7369
7370 2009-08-23  Bruno Haible  <bruno@clisp.org>
7371
7372         * lib/dup3.c: Include <string.h>.
7373
7374 2009-08-23  Bruno Haible  <bruno@clisp.org>
7375
7376         * lib/dup3.c (dup3): Test only once whether the system actually exists.
7377         * lib/pipe2.c (pipe2): Likewise.
7378         Suggested by Eric Blake.
7379
7380 2009-08-23  Bruno Haible  <bruno@clisp.org>
7381
7382         Tolerate declared but missing dup3 syscall.
7383         * lib/dup3.c (dup3): Invoke original dup3 function first, if available.
7384         * lib/unistd.in.h (dup3): If the function is already present,
7385         override it.
7386         * m4/dup3.m4 (gl_FUNC_DUP3): Remove AC_LIBOBJ invocation.
7387         * modules/dup3 (Makefile.am): Compile dup3.c always.
7388         Reported by Paolo Bonzini.
7389
7390 2009-08-23  Bruno Haible  <bruno@clisp.org>
7391
7392         Tolerate declared but missing pipe2 syscall.
7393         * lib/pipe2.c (pipe2): Invoke original pipe2 function first, if
7394         available.
7395         * lib/unistd.in.h (pipe2): If the function is already present,
7396         override it.
7397         * m4/pipe2.m4 (gl_FUNC_PIPE2): Remove AC_LIBOBJ invocation.
7398         * modules/pipe2 (Makefile.am): Compile pipe2.c always.
7399         Reported by Paolo Bonzini.
7400
7401 2009-08-23  Bruno Haible  <bruno@clisp.org>
7402
7403         * lib/pipe2.c (pipe2): Move #ifs inside function.
7404
7405 2009-08-22  Joel E. Denny  <jdenny@clemson.edu>
7406
7407         quotearg: document limitations of quote_these_too
7408         * lib/quotearg.c (quotearg_buffer_restyled): Add comments where
7409         those limitations are created.
7410         * lib/quotearg.h (set_char_quoting): Document that digits and
7411         letters that are special after backslash are not permitted.
7412         (quotearg_char): Cross-reference set_char_quoting documentation.
7413
7414 2009-08-23  Joel E. Denny  <jdenny@clemson.edu>
7415
7416         quotearg: implement custom_quoting_style
7417         * lib/quotearg.c: (struct quoting_options): Add left_quote and
7418         right_quote fields.
7419         (set_custom_quoting): New public function.
7420         (quotearg_buffer_restyled): Add left_quote and right_quote
7421         arguments, handle them very much like locale quoting, and update
7422         all uses.
7423         (quotearg_n_custom): New public function.
7424         (quotearg_n_custom_mem): New public function.
7425         (quotearg_custom): New public function.
7426         (quotearg_custom_mem): New public function.
7427         * lib/quotearg.h: Prototype and document new public functions.
7428         (enum quoting_style): For escape_quoting_style and
7429         clocale_quoting_style, comment that QA_SPLIT_TRIGRAPHS is
7430         ignored even though they're otherwise like c_quoting_style.
7431         Add custom_quoting_style member and document with comparison to
7432         clocale_quoting_style.
7433         * tests/test-quotearg.c (custom_quotes): New array.
7434         (custom_results): New array.
7435         (main): Extend to test custom quoting.
7436
7437 2009-08-22  Joel E. Denny  <jdenny@clemson.edu>
7438
7439         quotearg: fix right quote escaping when it's in quote_these_too
7440         * lib/quotearg.c (quotearg_buffer_restyled): Upon seeing a right
7441         quote, be sure to prepend only one backslash.
7442         * tests/test-quotearg.c (use_quote_double_quotes): New function.
7443         (main): Test it.
7444
7445 2009-08-22  Joel E. Denny  <jdenny@clemson.edu>
7446
7447         quotearg-tests: test escaping of embedded locale quotes
7448         * tests/test-quotearg.c (struct result_strings): Add member for
7449         new input.
7450         (LQ_ENC, RQ_ENC, RQ_ESC): New macros.
7451         (inputs): Add new input.
7452         (results_g): Add expected results.
7453         (flag_results): Likewise.
7454         (locale_results): Likewise.
7455         (compare_strings): Check those.
7456
7457 2009-08-23  Bruno Haible  <bruno@clisp.org>
7458
7459         Tests for module 'dup3'.
7460         * modules/dup3-tests: New file.
7461         * tests/test-dup3.c: New file.
7462
7463         New module 'dup3'.
7464         * lib/unistd.in.h (dup3): New declaration.
7465         * lib/dup3.c: New file.
7466         * m4/dup3.m4: New file.
7467         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_DUP3 and
7468         HAVE_DUP3.
7469         * modules/unistd (Makefile.am): Substitute GNULIB_DUP3 and HAVE_DUP3.
7470         * modules/dup3: New file.
7471         * doc/glibc-functions/dup3.texi: Mention the new module.
7472
7473 2009-08-23  Bruno Haible  <bruno@clisp.org>
7474
7475         Tweak the dup2 test.
7476         * tests/test-dup2.c (main): Create the test file empty. Verify that an
7477         out-of-range fd yields EBADF. Verify that after writing to /dev/null,
7478         the test file is still empty. Fix argument order of lseek.
7479
7480 2009-08-23  Bruno Haible  <bruno@clisp.org>
7481
7482         Avoid test link errors when the modules getopt-gnu, gettext are used.
7483         * modules/getopt-posix-tests (Makefile.am): Define test_getopt_LDADD.
7484         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
7485
7486 2009-08-23  Bruno Haible  <bruno@clisp.org>
7487
7488         Fix getdtablesize() on mingw.
7489         * lib/getdtablesize.c (getdtablesize): Implement differently.
7490         * lib/unistd.in.h (getdtablesize): Improve comment.
7491
7492 2009-08-23  Bruno Haible  <bruno@clisp.org>
7493
7494         New module 'mkostemp'.
7495         Based on Ulrich Drepper's 2007-08-10 change in glibc.
7496         * lib/stdlib.in.h (mksotemp): New declaration.
7497         * lib/mkostemp.c: New file, from glibc with modifications.
7498         * lib/tempname.h (GT_FILE): Remove outdated comment.
7499         (gen_tempname): Add flags argument.
7500         * lib/tempname.c (__GT_BIGFILE): Remove macro.
7501         (__GT_FILE): Map to 1.
7502         (small_open, large_open): Remove macros.
7503         (__gen_tempname): Add flags argument. Remove code for __GT_BIGFILE.
7504         * lib/mkstemp.c (mkstemp): Update.
7505         * lib/mkdtemp.c (mkdtemp): Likewise.
7506         * m4/mkostemp.m4: New file.
7507         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_MKOSTEMP,
7508         HAVE_MKOSTEMP.
7509         * modules/stdlib (Makefile.am): Substitute GNULIB_MKOSTEMP,
7510         HAVE_MKOSTEMP.
7511         * modules/mkostemp: New file, based on modules/mkstemp.
7512         * doc/glibc-functions/mkostemp.texi: Mention the new module.
7513         * NEWS: Mention the change.
7514
7515 2009-08-23  Bruno Haible  <bruno@clisp.org>
7516
7517         * lib/pipe2.c (pipe2): Support O_TEXT, O_BINARY on all platforms.
7518         Reported by Eric Blake.
7519
7520 2009-08-23  Bruno Haible  <bruno@clisp.org>
7521
7522         * lib/pipe2.c (pipe2): Fix test of fcntl's return value.
7523         Reported by Eric Blake.
7524
7525 2009-08-23  Bruno Haible  <bruno@clisp.org>
7526
7527         * modules/fchdir (Depends-on): Use fcntl-h instead of fcntl.
7528         * modules/pipe2 (Depends-on): Likewise.
7529
7530 2009-08-23  Eric Blake  <ebb9@byu.net>
7531
7532         fcntl-h: add O_TTY_INIT support
7533         * lib/fcntl.in.h (O_TTY_INIT): Support another POSIX macro.
7534         * tests/test-fcntl-h.c (o): Test it.
7535         * doc/posix-headers/fcntl.texi (fcntl.h): Update documentation.
7536
7537         fcntl-h: rename from fcntl, in preparation for fcntl(2)
7538         * modules/fcntl: Move <fcntl.h> header replacement...
7539         * modules/fcntl-h: ...to new name, so as not to collide with
7540         like-named function.
7541         * tests/test-fcntl.c: Rename...
7542         * tests/test-fcntl-h.c: ...to this.  Test FD_CLOEXEC.
7543         * modules/fcntl-tests: Rename...
7544         * modules/fcntl-h-tests: ...to this.  Update test file name.
7545         * modules/chdir-long (Depends-on): Update clients.
7546         * modules/chdir-safer (Depends-on): Likewise.
7547         * modules/fcntl-safer (Depends-on): Likewise.
7548         * modules/fts (Depends-on): Likewise.
7549         * modules/mkancesdirs (Depends-on): Likewise.
7550         * modules/mkdir-p (Depends-on): Likewise.
7551         * modules/open (Depends-on): Likewise.
7552         * modules/savewd (Depends-on): Likewise.
7553         * MODULES.html.sh (systems lacking POSIX:2008): Update name.
7554         * doc/posix-headers/fcntl.texi (fcntl.h): Update documentation.
7555
7556 2009-08-22  Bruno Haible  <bruno@clisp.org>
7557
7558         * modules/binary-io (License): Relicense under LGPL.
7559         * modules/pipe2 (License): Likewise.
7560
7561 2009-08-22  Bruno Haible  <bruno@clisp.org>
7562
7563         * lib/pipe-filter-ii.c (pipe_filter_ii_execute): Fix test of fcntl's
7564         return value.
7565         * lib/pipe-filter-gi.c (filter_init): Likewise.
7566         Reported by Eric Blake.
7567
7568 2009-08-22  Bruno Haible  <bruno@clisp.org>
7569
7570         * lib/pipe.c (create_pipe): Use pipe2 instead of _pipe.
7571         * modules/pipe (Depends-on): Add pipe2.
7572
7573 2009-08-22  Bruno Haible  <bruno@clisp.org>
7574
7575         Tests for module 'pipe2'.
7576         * modules/pipe2-tests: New file.
7577         * tests/test-pipe2.c: New file.
7578
7579         New module 'pipe2'.
7580         * lib/unistd.in.h (pipe2): New declaration.
7581         * lib/pipe2.c: New file.
7582         * m4/pipe2.m4: New file.
7583         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_PIPE2 and
7584         HAVE_PIPE2.
7585         * modules/unistd (Makefile.am): Substitute GNULIB_PIPE2 and HAVE_PIPE2.
7586         * modules/pipe2: New file.
7587         * doc/glibc-functions/pipe2.texi: Mention the new module.
7588
7589 2009-08-22  Bruno Haible  <bruno@clisp.org>
7590
7591         Reference some new glibc functions.
7592         * doc/glibc-functions/accept4.texi: New file.
7593         * doc/glibc-functions/dup3.texi: New file.
7594         * doc/glibc-functions/mkostemp.texi: New file.
7595         * doc/glibc-functions/pipe2.texi: New file.
7596         * doc/gnulib.texi (Glibc stdlib.h): Refer to mkostemp.
7597         (Glibc sys/socket.h): Refer to accept4.
7598         (Glibc unistd.h): Refer to dup3, pipe2.
7599         Reported by Eric Blake.
7600
7601 2009-08-22  Jim Meyering  <meyering@redhat.com>
7602             Bruno Haible  <bruno@clisp.org>
7603
7604         annotate automake snippets with $(AM_V_GEN) and $(AM_V_at)
7605         This makes it so packages using automake-1.11's silent-rules option
7606         can print e.g., a single "GEN    configmake.h" line, rather than
7607         the 30+ statements that perform the job.  If you want to see the
7608         actual commands, you can still run "make V=1".
7609         * modules/alloca-opt: Add $(AM_V_GEN) and $(AM_V_at) prefixes
7610         so that make output is abbreviated when those variables are defined
7611         appropriately.
7612         * modules/argz: Likewise.
7613         * modules/arpa_inet: Likewise.
7614         * modules/byteswap: Likewise.
7615         * modules/configmake: Likewise.
7616         * modules/dirent: Likewise.
7617         * modules/errno: Likewise.
7618         * modules/fcntl: Likewise.
7619         * modules/float: Likewise.
7620         * modules/fnmatch: Likewise.
7621         * modules/getopt-posix: Likewise.
7622         * modules/glob: Likewise.
7623         * modules/iconv_open: Likewise.
7624         * modules/inttypes: Likewise.
7625         * modules/localcharset: Likewise.
7626         * modules/locale: Likewise.
7627         * modules/math: Likewise.
7628         * modules/netdb: Likewise.
7629         * modules/netinet_in: Likewise.
7630         * modules/poll: Likewise.
7631         * modules/posix_spawnp-tests: Likewise.
7632         * modules/sched: Likewise.
7633         * modules/search: Likewise.
7634         * modules/selinux-h: Likewise.
7635         * modules/signal: Likewise.
7636         * modules/spawn: Likewise.
7637         * modules/stdarg: Likewise.
7638         * modules/stdbool: Likewise.
7639         * modules/stddef: Likewise.
7640         * modules/stdint: Likewise.
7641         * modules/stdio: Likewise.
7642         * modules/stdlib: Likewise.
7643         * modules/string: Likewise.
7644         * modules/strings: Likewise.
7645         * modules/sys_file: Likewise.
7646         * modules/sys_ioctl: Likewise.
7647         * modules/sys_select: Likewise.
7648         * modules/sys_socket: Likewise.
7649         * modules/sys_stat: Likewise.
7650         * modules/sys_time: Likewise.
7651         * modules/sys_times: Likewise.
7652         * modules/sys_utsname: Likewise.
7653         * modules/sys_wait: Likewise.
7654         * modules/sysexits: Likewise.
7655         * modules/time: Likewise.
7656         * modules/unistd: Likewise.
7657         * modules/wchar: Likewise.
7658         * modules/wctype: Likewise.
7659
7660 2009-08-22  Jim Meyering  <meyering@redhat.com>
7661
7662         announce-gen: detect write failure
7663         * build-aux/announce-gen: Add Coda at end.
7664         Remove equivalent-but-more-verbose block at top.
7665
7666 2009-08-19  Akim Demaille  <demaille@gostai.com>
7667
7668         bootstrap: --help to stdout.
7669         * bootstrap (usage): Don't send --help to stderr.
7670         Use a here doc instead of a long string.
7671
7672 2009-08-21  Eric Blake  <ebb9@byu.net>
7673
7674         test-popen-safer: split from test-popen
7675         * tests/test-popen.c (main): Move...
7676         * tests/test-popen.h: ...into new file.
7677         * tests/test-popen-safer2.c: New file.
7678         * modules/popen-tests (Files): Add test-popen.h.
7679         * modules/popen-safer-tests (Files): Add test-popen-safer2.c.
7680         Suggested by Bruno Haible.
7681
7682         test-fcntl-safer: split from test-open
7683         * tests/test-open.c (main): Move...
7684         * tests/test-open.h: ...into new file.
7685         * tests/test-fcntl-safer.c: New file.
7686         * modules/open-tests (Files): Add test-open.h.
7687         * modules/fcntl-safer-tests: New file.
7688         Suggested by Bruno Haible.
7689
7690         test-fopen-safer: split from test-fopen
7691         * tests/test-fopen.c (main): Move...
7692         * tests/test-fopen.h: ...into new file.
7693         * tests/test-fopen-safer.c: New file.
7694         * modules/fopen-tests (Files): Add test-fopen.h.
7695         * modules/fopen-safer-tests: New file.
7696         Suggested by Bruno Haible.
7697
7698 2009-08-21  Paolo Bonzini  <bonzini@gnu.org>
7699
7700         popen-safer: test O_CLOEXEC at run-time.
7701         * lib/popen-safer.c: Test O_CLOEXEC at run-time.
7702
7703 2009-08-21  Paolo Bonzini  <bonzini@gnu.org>
7704
7705         fcntl: move more flags to the header
7706         * lib/cloexec.c: Do not define FD_CLOEXEC here.
7707         * lib/popen-safer.c: Do not alias O_NOINHERIT to O_CLOEXEC here.
7708         * lib/fcntl.in.h: Do both things here.
7709
7710 2009-08-21  Jim Meyering  <meyering@redhat.com>
7711
7712         consistently remove $@-t before redirecting to it
7713         * modules/argz: Remove $@-t and $@ before redirecting to the former.
7714         * modules/alloca-opt: Likewise.
7715         * modules/byteswap: Likewise.
7716         * modules/fnmatch: Likewise.
7717         * modules/getopt-posix: Likewise.
7718         * modules/glob: Likewise.
7719         * modules/poll: Likewise.
7720         * modules/posix_spawnp-tests: Likewise.
7721         * modules/sys_socket: Likewise.
7722         * modules/sysexits: Likewise.
7723
7724 2009-08-21  Eric Blake  <ebb9@byu.net>
7725
7726         popen: simplify access to original popen
7727         * lib/popen.c (rpl_popen): No need to worry about popen being a
7728         macro.
7729         Reported by Bruno Haible.
7730
7731 2009-08-20  Eric Blake  <ebb9@byu.net>
7732
7733         build: avoid some compiler warnings
7734         * lib/selinux-at.h: Use dir_fd, not dirfd, to avoid shadowing.
7735         * lib/exclude.c (fnmatch_pattern_has_wildcards): Use correct
7736         type.
7737         (new_exclude_segment, excluded_file_pattern_p)
7738         (excluded_file_name_p): Reduce scope.
7739         * lib/vasnprintf.c (decimal_point_char): Avoid warning on
7740         old-style declaration.
7741
7742 2009-08-20  Simon Josefsson  <simon@josefsson.org>
7743
7744         * tests/test-exclude1.sh: Handle Windows EOL.
7745         * tests/test-exclude2.sh: Likewise.
7746         * tests/test-exclude3.sh: Likewise.
7747         * tests/test-exclude4.sh: Likewise.
7748         * tests/test-exclude5.sh: Likewise.
7749         * tests/test-exclude6.sh: Likewise.
7750         * tests/test-exclude7.sh: Likewise.
7751
7752 2009-08-19  Akim Demaille  <demaille@gostai.com>
7753
7754         bootstrap: find sha1sum when named gsha1sum.
7755         * bootstrap (find_tool): New.
7756         ($SHA1SUM): New.
7757         Use it.
7758
7759 2009-08-20  Jim Meyering  <meyering@redhat.com>
7760
7761         maint.mk: _header_without_use: fix a quoting bug and remove a bash'ism
7762         * top/maint.mk (_header_without_use): Use "\\\\", not "\\" in the sed
7763         expression that converts "." in a file name to "\." in the resulting
7764         regexp.  Start with a dummy statement, so that prior shell variable
7765         definitions are expanded portably.  Reported by Simon Josefsson.
7766
7767 2009-08-20  Paolo Bonzini  <bonzini@gnu.org>
7768
7769         Fix polling for writeability of a screen buffer.
7770         * lib/poll.c: Distinguish input and screen buffers for the
7771         Win32 implementation.
7772         * lib/select.c: Likewise.
7773
7774 2009-08-19  Eric Blake  <ebb9@byu.net>
7775
7776         popen-safer: prevent popen from clobbering std descriptors
7777         * modules/popen-safer: New file.
7778         * lib/popen-safer.c: Likewise.
7779         * m4/stdio-safer.m4 (gl_POPEN_SAFER): New macro.
7780         * lib/stdio--.h (popen): Provide override.
7781         * lib/stdio-safer.h (popen_safer): Provide declaration.
7782         * tests/test-popen.c (includes): Partially test this.
7783         * modules/popen-safer-tests: New file, for more tests.
7784         * tests/test-popen-safer.c: Likewise.
7785         * MODULES.html.sh (file stream based Input/Output): Mention it.
7786
7787         tests: test some of the *-safer modules
7788         * modules/fopen-safer (Depends-on): Add fopen.
7789         * modules/fcntl-safer (Depends-on): Add fcntl.
7790         * modules/stdlib-safer (Depends-on): Add stdlib.
7791         (configure.ac): Set indicator.
7792         * modules/unistd-safer (configure.ac): Likewise.
7793         * modules/tmpfile-safer (configure.ac): Likewise.
7794         (Depends-on): Add tmpfile.
7795         * lib/stdio--.h (fopen, tmpfile): Don't override unless module is
7796         active.
7797         * tests/test-fopen.c (includes): Test safer versions when they are
7798         in use.
7799         * tests/test-open.c (includes): Likewise.
7800
7801         popen: fix cygwin 1.5 bug when stdin closed
7802         * doc/posix-functions/popen.texi (popen): Document cygwin bugs.
7803         * modules/popen: New file.
7804         * modules/popen-tests: Likewise.
7805         * tests/test-popen.c: Likewise.
7806         * m4/popen.m4: Likewise.
7807         * lib/popen.c: Likewise.
7808         * lib/stdio.in.h (popen): New declaration.
7809         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add popen.
7810         * modules/stdio (Makefile.am): Likewise.
7811         * MODULES.html.sh (systems lacking POSIX:2008): Mention it.
7812
7813 2009-08-17  Joel E. Denny  <jdenny@clemson.edu>
7814
7815         maint.mk: give full control over update-copyright exclusions
7816         * top/maint.mk (VC_LIST_EXCEPT): Instead of ChangeLog, use
7817         ${VC_LIST_EXCEPT_DEFAULT-ChangeLog} as the default exclusion.
7818         (update-copyright): Don't force inclusion of top-level
7819         ChangeLog.  Don't force exclusion of all COPYING files, but make
7820         them the default exclusion instead.
7821
7822 2009-08-16  Bruno Haible  <bruno@clisp.org>
7823
7824         Fix test failures on Solaris 10.
7825         * tests/uniconv/test-u8-conv-from-enc.c (main): Disable autodetect_jp
7826         tests when Solaris iconv() is used.
7827         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
7828         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
7829         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
7830         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
7831         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
7832
7833 2009-08-16  Bruno Haible  <bruno@clisp.org>
7834
7835         Fix test failures on Solaris 10.
7836         * tests/test-pipe-filter-ii1.sh: Determine the filename of a working
7837         'tr' program and pass it as first argument.
7838         * tests/test-pipe-filter-gi1.sh: Likewise.
7839         * tests/test-pipe-filter-ii1.c (main): Except the filename of a 'tr'
7840         program as first argument.
7841         * tests/test-pipe-filter-gi1.c (main): Likewise.
7842
7843 2009-08-16  Eric Blake  <ebb9@byu.net>
7844
7845         fpurge: fix previous commits
7846         * modules/fpurge (Makefile.am): Make replacement conditional,
7847         partially reverting 2007-04-29 change; missed in previous
7848         attempt.
7849         * m4/fpurge.m4 (gl_FUNC_FPURGE): Also compile fpurge.c when fpurge
7850         is missing.
7851
7852 2009-08-16  Bruno Haible  <bruno@clisp.org>
7853
7854         Clarify fpurge's effect on the file position.
7855         * lib/stdio.in.h (fpurge): Specify the file position after fpurge.
7856         * tests/test-fpurge.c (main): Make a second pass for checking the file
7857         position.
7858
7859 2009-08-16  Bruno Haible  <bruno@clisp.org>
7860
7861         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't compile fpurge.c if only the
7862         declaration of fpurge is missing.
7863         * tests/test-fpurge.c (main): Check that the file has not more contents
7864         than expected. Close the file before removing it.
7865
7866 2009-08-15  Eric Blake  <ebb9@byu.net>
7867
7868         fpurge: don't wrap working cygwin implementation
7869         * lib/fpurge.c (fpurge): Fix comment typo.
7870         * m4/fpurge.m4 (gl_FUNC_FPURGE): Detect BSD bug, allowing cygwin
7871         1.7 to avoid replacement.
7872         * tests/test-fpurge.c (main): Enhance test.
7873
7874 2009-08-15  Eric Blake  <ebb9@byu.net>
7875         and Jim Meyering  <meyering@redhat.com>
7876
7877         test-update-copyright: skip if perl is insufficient
7878         * tests/test-update-copyright.sh: Failure to run maintainer tool
7879         should not cause testsuite failure on cygwin 1.5.
7880
7881 2009-08-14  Eric Blake  <ebb9@byu.net>
7882
7883         doc: mention more functions added in cygwin 1.7.0
7884         * doc/posix-headers/limits.texi (limits.h): Update for recent
7885         cygwin additions.
7886         * doc/posix-headers/wordexp.texi (wordexp.h): Likewise.
7887         * doc/posix-functions/wordexp.texi (wordexp): Likewise.
7888         * doc/posix-functions/wordfree.texi (wordfree): Likewise.
7889         * doc/posix-functions/setlocale.texi (setlocale): Likewise.
7890         * doc/posix-functions/nl_langinfo.texi (nl_langinfo): Likewise.
7891
7892 2009-08-14  Eric Blake  <ebb9@byu.net>
7893
7894         maint.mk: simplify update-copyright rule
7895         * top/maint.mk (update-copyright-local): Delete, and document how
7896         to do it in cfg.mk instead.
7897         (update-copyright-exclude-regexp): Delete, and document how to do
7898         it in .x-update-copyright instead.
7899         (update-copyright): Simplify, thanks to VC_LIST_EXCEPT.  Don't
7900         exclude ChangeLog.
7901
7902 2009-08-14  Bruno Haible  <bruno@clisp.org>
7903
7904         * m4/wchar.m4 (gl_WCHAR_H): Undo invalid optimization in last commit.
7905
7906 2009-08-14  Joel E. Denny  <jdenny@clemson.edu>
7907
7908         maint.mk: support update-copyright-env
7909         * top/maint.mk (update-copyright-env): Define place-holder.
7910         (update-copyright): Expand $(update-copyright-env) before
7911         invoking update-copyright.
7912
7913 2009-08-14  Joel E. Denny  <jdenny@clemson.edu>
7914
7915         update-copyright: implement forced reformatting
7916         * build-aux/update-copyright: Implement and document
7917         UPDATE_COPYRIGHT_FORCE.
7918         * tests/test-update-copyright.sh: Test it.
7919
7920 2009-08-14  Eric Blake  <ebb9@byu.net>
7921         and Bruno Haible  <bruno@clisp.org>
7922
7923         stddef: fix NetBSD 5.0 NULL bug, rather than working around it
7924         * tests/test-locale.c: Revert previous patch related to NULL.
7925         * tests/test-stdio.c: Likewise.
7926         * tests/test-stdlib.c: Likewise.
7927         * tests/test-string.c: Likewise.
7928         * tests/test-unistd.c: Likewise.
7929         * modules/time-tests (Depends-on): Add verify.
7930         * modules/wchar-tests (Depends-on): Likewise.
7931         * tests/test-time.c: Test for NULL compliance.
7932         * tests/test-wchar.c: Likewise.
7933         * modules/locale (Depends-on): Add stddef.
7934         * modules/stdio (Depends-on): Likewise.
7935         * modules/stdlib (Depends-on): Likewise.
7936         * modules/string (Depends-on): Likewise.
7937         * modules/time (Depends-on): Likewise.
7938         * modules/unistd (Depends-on): Likewise.
7939         * modules/wchar (Depends-on): Likewise.
7940         * lib/locale.in.h (includes): Use <stddef.h> to fix NULL.
7941         * lib/stdlib.in.h (includes): Likewise.
7942         * lib/string.in.h (includes): Likewise.
7943         * lib/time.in.h (includes): Likewise.
7944         * lib/unistd.in.h (includes): Likewise.
7945         * m4/locale_h.m4 (gl_LOCALE_H): Replace locale.h if stddef.h was
7946         replaced.
7947         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
7948         * m4/stddef_h.m4: New file.
7949         * modules/stddef: Likewise.
7950         * lib/stddef.in.h: Likewise.
7951         * modules/stddef-tests: Likewise.
7952         * tests/test-stddef.c: Likewise.
7953         * MODULES.html.sh (Basic types <stddef.h>): Mention new module.
7954         * doc/posix-headers/stddef.texi (stddef.h): Document the bug.
7955         * doc/posix-headers/locale.texi (locale.h): Likewise.
7956         * doc/posix-headers/stdio.texi (stdio.h): Likewise.
7957         * doc/posix-headers/stdlib.texi (stdlib.h): Likewise.
7958         * doc/posix-headers/string.texi (string.h): Likewise.
7959         * doc/posix-headers/time.texi (time.h): Likewise.
7960         * doc/posix-headers/unistd.texi (unistd.h): Likewise.
7961         * doc/posix-headers/wchar.texi (wchar.h): Likewise.
7962
7963 2009-08-14  Eric Blake  <ebb9@byu.net>
7964
7965         doc: improve git diff of texinfo files
7966         * .gitattributes: Add rule for *.texi files, with hint on how to
7967         use it.
7968         Copied from m4, and based on a report by Bruno Haible.
7969
7970 2009-08-14  Bruno Haible  <bruno@clisp.org>
7971
7972         Disable multithread support by default on Cygwin 1.5.x for real.
7973         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Fix last commit.
7974
7975 2009-08-14  Joel E. Denny  <jdenny@clemson.edu>
7976
7977         update-copyright: much ado about intervals
7978         * build-aux/update-copyright: Implement and document
7979         UPDATE_COPYRIGHT_USE_INTERVALS to control expansion and collapse
7980         of copyright year intervals.
7981         Also, document UPDATE_COPYRIGHT_YEAR.
7982         * tests/test-update-copyright.sh: Test it.
7983
7984         update-copyright: convert 2-digit to 4-digit years
7985         * build-aux/update-copyright: Implement and document.
7986         * tests/test-update-copyright.sh: Update.
7987
7988 2009-08-14  Jim Meyering  <meyering@redhat.com>
7989
7990         test-exclude: avoid coreutils "make check" failure
7991         * tests/test-exclude.c (ARGMATCH_DIE_DECL) [ARGMATCH_DIE_DECL]: Define,
7992         just as in test-argmatch.c.
7993
7994 2009-08-13  Eric Blake  <ebb9@byu.net>
7995
7996         test-dup2: fix bad assumption
7997         * tests/test-dup2.c (main): Tolerate leaked fds from environment.
7998         Reported by Peter Breitenlohner <peb@mppmu.mpg.de>.
7999
8000         test-version-etc: fix CRLF portability issue
8001         * tests/test-version-etc.sh: Use tr, not sed, as not all sed
8002         recognize \r.
8003         * tests/test-argp-version-etc-1.sh: Likewise.
8004
8005         getopt: update client modules
8006         * modules/argp (Depends-on): Use getopt-gnu.
8007         * modules/git-merge-changelog (Depends-on): Likewise.
8008         * modules/long-options (Depends-on): Likewise.
8009         * modules/xstrtol (Depends-on): Likewise.
8010
8011 2009-08-13  Simon Josefsson  <simon@josefsson.org>
8012
8013         * tests/test-version-etc.sh: Don't fail on different
8014         project/version.  Don't fail on CRLF differences.  Rewrite to use
8015         multiple -e instead of multiple sed forks, suggested by Eric Blake
8016         <ebb9@byu.net>.
8017         * tests/test-argp-version-etc-1.sh: Likewise.
8018
8019 2009-08-13  Simon Josefsson  <simon@josefsson.org>
8020
8021         * tests/test-version-etc.sh: Don't fail on different
8022         project/version.
8023
8024 2009-08-12  Bruno Haible  <bruno@clisp.org>
8025
8026         Tests for modules 'getopt-posix', 'getopt-gnu'.
8027         * modules/getopt-posix-tests: New file.
8028         * tests/test-getopt.c: New file.
8029         * tests/test-getopt.h: New file.
8030         * tests/test-getopt_long.h: New file.
8031
8032         New modules 'getopt-posix', 'getopt-gnu'.
8033         * modules/getopt-gnu: New file, renamed from modules/getopt.
8034         * modules/getopt-posix: New file.
8035         * modules/getopt: Turn into an obsolete alias for getopt-gnu.
8036         * m4/getopt.m4 (gl_FUNC_GETOPT_POSIX, gl_FUNC_GETOPT_GNU): New macros.
8037         (gl_GETOPT): Remove macro.
8038         (gl_GETOPT_CHECK_HEADERS): Do some checks only for gl_FUNC_GETOPT_GNU.
8039         Disable the test against BSD systems that declare optreset. Test
8040         against mingw bug. Test against lack of support of optional arguments
8041         on many platforms.
8042         * doc/glibc-headers/getopt.texi: Update module name and list of
8043         relevant platforms.
8044         * doc/posix-functions/getopt.texi: Mention modules 'getopt-posix' and
8045         'getopt-gnu' and more portability problems.
8046         * NEWS: Mention the changes.
8047
8048 2009-08-12  Bruno Haible  <bruno@clisp.org>
8049
8050         Ensure that optarg etc. get declared by <unistd.h>.
8051         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Require
8052         AC_USE_SYSTEM_EXTENSIONS.
8053         * modules/getopt (Depends-on): Add 'extensions'.
8054
8055 2009-08-12  Bruno Haible  <bruno@clisp.org>
8056
8057         Avoid test link errors.
8058         * modules/pipe-filter-ii-tests (Makefile.am): Define
8059         test_pipe_filter_ii1_LDADD and test_pipe_filter_ii2_main_LDADD.
8060         * modules/pipe-filter-gi-tests (Makefile.am): Define
8061         test_pipe_filter_gi1_LDADD and test_pipe_filter_gi2_main_LDADD.
8062         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
8063
8064 2009-08-12  Bruno Haible  <bruno@clisp.org>
8065
8066         * m4/getopt.m4 (gl_REPLACE_GETOPT): New macro, was called
8067         gl_GETOPT_SUBSTITUTE before.
8068         (gl_GETOPT): Use it.
8069         * m4/argp.m4 (gl_ARGP): Update.
8070         Reported by Sergey Poznyakoff.
8071
8072         * m4/getopt.m4: Reorder macros.
8073         (gl_GETOPT): Inline gl_GETOPT_SUBSTITUTE.
8074         (gl_GETOPT_SUBSTITUTE): Remove macro.
8075
8076 2009-08-12  Sergey Poznyakoff  <gray@gnu.org.ua>
8077
8078         Minor improvement in gitlog-to-changelog
8079
8080         * build-aux/gitlog-to-changelog: New option `--format' makes
8081         output format string configurable.
8082
8083 2009-08-12  Sergey Poznyakoff  <gray@gnu.org.ua>
8084
8085         Optimize exclude: use hash tables for non-wildcard patterns.
8086
8087         * lib/exclude.c: Include hash.h and mbuiter.h
8088         (struct exclude_pattern, exclude_segment): New data types.
8089         (struct exclude): Rewrite.
8090         (fnmatch_pattern_has_wildcards): New function.
8091         (new_exclude_segment, free_exclude_segment): New functions.
8092         (excluded_file_pattern_p, excluded_file_name_p): New functions.
8093         (excluded_file_name, add_exclude): Rewrite using new struct exclude.
8094         * lib/exclude.h (is_fnmatch_pattern): New prototype.
8095         * modules/exclude: Depend on hash and mbuiter.
8096
8097         * modules/exclude-tests: New file.
8098         * tests/test-exclude.c: New file.
8099         * tests/test-exclude1.sh: New file.
8100         * tests/test-exclude2.sh: New file.
8101         * tests/test-exclude3.sh: New file.
8102         * tests/test-exclude4.sh: New file.
8103         * tests/test-exclude5.sh: New file.
8104         * tests/test-exclude6.sh: New file.
8105         * tests/test-exclude7.sh: New file.
8106
8107 2009-08-12  Bruno Haible  <bruno@clisp.org>
8108
8109         Ensure that getopt() gets declared by <unistd.h>.
8110         * lib/unistd.in.h: Conditionally include getopt.h.
8111         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Require gl_UNISTD_H_DEFAULTS.
8112         Set GNULIB_UNISTD_H_GETOPT.
8113         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
8114         GNULIB_UNISTD_H_GETOPT.
8115         * modules/unistd (Makefile.am): Substitute GNULIB_UNISTD_H_GETOPT.
8116
8117 2009-08-12  Bruno Haible  <bruno@clisp.org>
8118
8119         Clarify logic.
8120         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS, gl_GETOPT_IFELSE): Use
8121         gl_replace_getopt instead of GETOPT_H.
8122
8123 2009-08-12  Bruno Haible  <bruno@clisp.org>
8124
8125         * m4/getopt.m4: Add comments.
8126
8127 2009-08-12  Bruno Haible  <bruno@clisp.org>
8128
8129         Disable multithread support by default on Cygwin 1.5.x.
8130         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): On Cygwin 1.5.x and older,
8131         set gl_use_threads=no if not specified otherwise.
8132
8133 2009-08-11  Bruno Haible  <bruno@clisp.org>
8134
8135         Avoid compilation error on NetBSD 5.0.
8136         * tests/test-locale.c: Write sizeof (NULL) instead of sizeof NULL.
8137         * tests/test-stdio.c: Likewise.
8138         * tests/test-stdlib.c: Likewise.
8139         * tests/test-string.c: Likewise.
8140         * tests/test-unistd.c: Likewise.
8141         Reported by Greg Troxel <gdt@ir.bbn.com>
8142         at <https://savannah.gnu.org/support/?106973>.
8143
8144 2009-08-11  Bruno Haible  <bruno@clisp.org>
8145
8146         * modules/dup2-tests (Depends-on): Remove close.
8147
8148         Undo 2009-07-19 commit.
8149         * modules/acl-tests (Depends-on): Remove close.
8150         * modules/binary-io-tests (Depends-on): Likewise.
8151         * modules/closein-tests (Depends-on): Likewise.
8152         * modules/flock-tests (Depends-on): Likewise.
8153         * modules/fsync-tests (Depends-on): Likewise.
8154         * modules/lseek-tests (Depends-on): Likewise.
8155         * modules/pipe-tests (Depends-on): Likewise.
8156         * modules/posix_spawn-tests (Depends-on): Likewise.
8157         * modules/posix_spawnp-tests (Depends-on): Likewise.
8158         * modules/stat-time-tests (Depends-on): Likewise.
8159         * modules/yesno-tests (Depends-on): Likewise.
8160
8161 2009-08-10  Bruno Haible  <bruno@clisp.org>
8162
8163         * lib/vasnprintf.c (DCHAR_SET): Undefine at the end.
8164
8165 2009-08-10  Bruno Haible  <bruno@clisp.org>
8166
8167         Fix a gcc warning.
8168         * lib/write.c (rpl_write): Cast result of _get_osfhandle.
8169
8170 2009-08-10  Bruno Haible  <bruno@clisp.org>
8171
8172         Don't optimize AC_LIBOBJs, as they may appear in different contexts.
8173         * m4/close.m4 (gl_REPLACE_CLOSE): Execute AC_LIBOBJ unconditionally,
8174         not only the first time.
8175         * m4/fclose.m4 (gl_REPLACE_FCLOSE): Likewise.
8176         * m4/open.m4 (gl_REPLACE_OPEN): Likewise.
8177         * m4/strstr.m4 (gl_FUNC_STRSTR): Execute AC_LIBOBJ when REPLACE_STRSTR
8178         is 1, not only the the first time.
8179
8180 2009-08-10  Bruno Haible  <bruno@clisp.org>
8181
8182         Make it possible to use module 'gethostname' without module 'close'.
8183         * lib/unistd.in.h (close): Evoke a link error only if
8184         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS is set.
8185         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
8186         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
8187         * modules/unistd (Makefile.am): Substitute
8188         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
8189         * lib/sys_ioctl.in.h (ioctl): Evoke a link error only if
8190         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS is set.
8191         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H_DEFAULTS): Initialize
8192         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
8193         * modules/sys_ioctl (Makefile.am): Substitute
8194         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
8195         * modules/socket (configure.ac): On native Windows, set
8196         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS and
8197         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
8198         Reported by Sam Steingold <sds@gnu.org>.
8199
8200 2009-08-10  Bruno Haible  <bruno@clisp.org>
8201
8202         * m4/close.m4 (gl_FUNC_CLOSE): Add comment.
8203         * modules/ioctl (configure.ac): Likewise.
8204
8205 2009-08-10  Bruno Haible  <bruno@clisp.org>
8206
8207         Avoid collision between gnulib wrapper and libintl wrapper.
8208         * lib/stdio-write.c (printf): Don't define if a printf wrapper is
8209         already defined in intl/printf.c.
8210         (vprintf): Test REPLACE_VPRINTF_POSIX, not REPLACE_VFPRINTF_POSIX.
8211         (vfprintf): Test REPLACE_VFPRINTF_POSIX, not REPLACE_VPRINTF_POSIX.
8212
8213 2009-08-09  Bruno Haible  <bruno@clisp.org>
8214
8215         Make <sys/select.h> really self-contained, also on Solaris 10.
8216         * lib/sys_select.in.h: Include <string.h>.
8217         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Test also against
8218         Solaris 10 problem.
8219         * tests/test-sys_select.c (main): Add check that FD_ZERO can be used.
8220         * doc/posix-headers/sys_select.texi: Mention the Solaris 10 problem.
8221         Reported by Jim Meyering.
8222
8223 2009-08-09  Bruno Haible  <bruno@clisp.org>
8224
8225         Avoid warnings from 'aclocal' that are due to a use of macro name
8226         AM_XGETTEXT_OPTION that is not defined in automake.
8227         * modules/argp (configure.ac): Hide use of AM_XGETTEXT_OPTION from
8228         automake.
8229         * modules/error (configure.ac): Likewise.
8230         * modules/propername (configure.ac): Likewise.
8231         * modules/vasprintf (configure.ac): Likewise.
8232         * modules/verror (configure.ac): Likewise.
8233         * modules/xprintf (configure.ac): Likewise.
8234         * modules/xvasprintf (configure.ac): Likewise.
8235
8236 2009-08-08  Bruno Haible  <bruno@clisp.org>
8237
8238         Avoid compilation error in C++ mode.
8239         * lib/gettimeofday.c (rpl_gettimeofday): Cast timezone argument.
8240         Reported by Sam Steingold <sds@gnu.org>.
8241
8242 2009-08-08  Bruno Haible  <bruno@clisp.org>
8243
8244         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Define HOST_NAME_MAX also
8245         for the various Unix platforms.
8246         * doc/posix-headers/limits.texi: Update platforms list regarding
8247         HOST_NAME_MAX.
8248         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
8249
8250 2009-08-07  Jim Meyering  <meyering@redhat.com>
8251
8252         selinux-at: fix typo in a comment
8253         * lib/selinux-at.h: s/getfileconat/getfilecon/ in a comment.
8254         Spotted by Paolo Bonzini.
8255
8256         selinux-at: remove redundant m4 code, add documentation
8257         * modules/selinux-at (configure.ac): Remove redundant code.
8258         LIB_SELINUX is already set via the dependent module, selinux-h.
8259         (Include): Add quotes around selinux-at.h.
8260         * lib/selinux-at.h: Add documentation.
8261         Reported by Bruno Haible in
8262         http://marc.info/?l=gnulib-bug&m=124958988300749
8263
8264 2009-08-07  Bruno Haible  <bruno@clisp.org>
8265
8266         Avoid link error on MacOS X 10.3 and 10.4.
8267         * lib/argp-ba.c (argp_program_bug_address): Explicitly zero-initialize
8268         on non-ELF systems.
8269         * lib/argp-pv.c (argp_program_version): Likewise.
8270         Reported by Simon Josefsson.
8271
8272 2009-08-07  Simon Josefsson  <simon@josefsson.org>
8273
8274         * tests/test-version-etc.sh: Use $EXEEXT.
8275
8276 2009-08-06  Joel E. Denny  <jdenny@clemson.edu>
8277
8278         update-copyright: update documentation to point to maint.mk
8279         * build-aux/update-copyright: Here.
8280
8281 2009-08-06  Jim Meyering  <meyering@redhat.com>
8282
8283         maint.mk: support update-copyright-local
8284         * top/maint.mk (update-copyright-local): Define place-holder.
8285         (update-copyright): Depend on $(update-copyright-local).
8286
8287 2009-08-06  Jim Meyering  <meyering@redhat.com>
8288
8289         selinux-at: new module
8290         Initially written for coreutils, this module will soon be
8291         used by findutils, too.
8292         * MODULES.html.sh [Misc]: Add selinux-at.
8293         * lib/selinux-at.h: New file, from coreutils.
8294         * lib/selinux-at.c: Likewise.
8295         * modules/selinux-at: Likewise.
8296         (License): Change from LGPL to GPL, since it depends
8297         on the GPL'd openat module.
8298
8299         doc: update README
8300         * README: Remove references to cogito.
8301         Remove cvs-repo-updating instructions from 2007.
8302         Don't imply that CVS is better if you have limited disk space.
8303
8304 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
8305
8306         update-copyright: support C-style comments
8307         * build-aux/update-copyright: Implement and document.
8308         * tests/test-update-copyright.sh: Test.
8309
8310 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
8311
8312         update-copyright: support omitted "(C)"
8313         * build-aux/update-copyright: Implement and document.  Also,
8314         allow variable whitespace before "(C)".
8315         * tests/test-update-copyright.sh: Test.
8316
8317 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
8318
8319         update-copyright: don't trip on non-FSF copyright statements
8320         * build-aux/update-copyright: Fix so that the first correctly
8321         formatted FSF copyright statement is recognized no matter what
8322         appears before it.  Update documentation.
8323         * tests/test-update-copyright.sh: Test that.
8324
8325 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
8326
8327         update-copyright: clean up code a little
8328         * build-aux/update-copyright: Append "_re" to the name of any
8329         variable holding a regular expression.
8330         Replace "old" and "new" with "stmt" in variable names.
8331         Do not accept 2-digit UPDATE_COPYRIGHT_YEAR, which was not
8332         handled correctly.
8333         Format code more consistently.
8334
8335 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
8336
8337         update-copyright-tests: improve portability
8338         * tests/test-update-copyright.sh: Use cmp if diff cannot handle
8339         -u or /dev/null.  Suggested by Jim Meyering and Eric Blake.
8340
8341 2009-08-03  Joel E. Denny  <jdenny@clemson.edu>
8342
8343         update-copyright: support @copyright{} and &copy;
8344         * build-aux/update-copyright: Implement and document.
8345         * tests/test-update-copyright.sh: Test.
8346
8347 2009-08-04  Jim Meyering  <meyering@redhat.com>
8348
8349         update-copyright-tests: correctly test EOL=\r\n handling
8350         * tests/test-update-copyright.sh: Put \r at the end of some lines
8351         for the dos-eol tests.  Based on a patch by Joel E. Denny.
8352
8353         maint.mk: make update-copyright exclusion list more configurable
8354         * top/maint.mk (update-copyright): Default to excluding COPYING,
8355         but allow an override, in case someone does want to update that file.
8356
8357         maint.mk: don't update copyright date in COPYING
8358         * top/maint.mk (update-copyright): Exclude COPYING.
8359
8360         maint.mk: add a copyright-updating rule
8361         * top/maint.mk (update-copyright): New rule.
8362         Derived from coreutils/Makefile.am.
8363
8364         update-copyright: rename some variables
8365         * build-aux/update-copyright: Rename a few variables for clarity.
8366         Tweak syntax.  List Joel E. Denny as coauthor.
8367
8368 2009-08-03  Joel E. Denny  <jdenny@clemson.edu>
8369
8370         update-copyright: fix bug for 2-digit last year and add tests
8371         * build-aux/update-copyright: Fix bug.
8372         Use UPDATE_COPYRIGHT_YEAR from environment as current year if
8373         specified.
8374         * modules/update-copyright-tests: New
8375         * tests/test-update-copyright.sh: New.
8376
8377 2009-07-31  Joel E. Denny  <jdenny@clemson.edu>
8378
8379         update-copyright: handle leading tabs in line prefix
8380         * build-aux/update-copyright: Count leading tabs as 8 spaces
8381         when computing margin.  This helps with the formatting of
8382         ChangeLogs, for example.
8383         Fix documentation a little.
8384
8385 2009-07-31  Joel E. Denny  <jdenny@clemson.edu>
8386
8387         update-copyright: support EOL=\r\n
8388         * build-aux/update-copyright: Implement that.
8389
8390 2009-07-31  Joel E. Denny  <jdenny@clemson.edu>
8391
8392         update-copyright: automatically format copyright statements
8393         * build-aux/update-copyright: Implement that.
8394         Also, be a little more predictable and safer by always failing
8395         when the full copyright format is not perfectly recognized as an
8396         unbroken whole.  Discussed at
8397         <http://lists.gnu.org/archive/html/bug-gnulib/2009-07/msg00131.html>.
8398         Rewrite documentation.
8399
8400 2009-08-03  Bruno Haible  <bruno@clisp.org>
8401
8402         * m4/iconv.m4 (AM_ICONV): Fix displayed message with autoconf-2.64.
8403
8404 2009-08-02  Bruno Haible  <bruno@clisp.org>
8405
8406         Tests for module 'uname'.
8407         * modules/uname-tests: New file.
8408         * tests/test-uname.c: New file.
8409
8410         New module 'uname'.
8411         * lib/uname.c: New file.
8412         * m4/uname.m4: New file.
8413         * modules/uname: New file.
8414         * doc/posix-functions/uname.texi: Mention the new module.
8415
8416 2009-08-02  Bruno Haible  <bruno@clisp.org>
8417
8418         Tests for module 'sys_utsname'.
8419         * modules/sys_utsname-tests: New file.
8420         * tests/test-sys_utsname.c: New file.
8421
8422         New module 'sys_utsname'.
8423         * lib/sys_utsname.in.h: New file, based on glibc's <sys/utsname.h>.
8424         * m4/sys_utsname_h.m4: New file.
8425         * modules/sys_utsname: New file.
8426         * doc/posix-headers/sys_utsname.texi: Mention the new module.
8427
8428 2009-08-02  Bruno Haible  <bruno@clisp.org>
8429
8430         Implicitly initialize the sockets library.
8431         * lib/gethostname.c: Include sockets.h.
8432         (rpl_gethostname): Invoke gl_sockets_startup.
8433         * lib/socket.c: Include sockets.h.
8434         (rpl_socket): Invoke gl_sockets_startup.
8435         * modules/gethostname (Depends-on): Add sockets.
8436         * modules/socket (Depends-on): Likewise.
8437         * tests/test-poll.c: Don't include sockets.h.
8438         (main): Don't invoke gl_sockets_startup.
8439         * tests/test-select.c: Don't include sockets.h.
8440         (main): Don't invoke gl_sockets_startup.
8441
8442 2009-08-02  Bruno Haible  <bruno@clisp.org>
8443
8444         Allow multiple calls to gl_sockets_startup.
8445         * lib/sockets.c (initialized_sockets_version): New variable.
8446         (gl_sockets_startup): Do nothing if already called for this or a higher
8447         version.
8448         (gl_sockets_cleanup): Reset initialized_sockets_version.
8449
8450 2009-08-03  Simon Josefsson  <simon@josefsson.org>
8451
8452         * tests/test-argp-version-etc-1.sh: Use EXEEXT.  Don't fail on
8453         different project/version.
8454
8455 2009-08-02  Paolo Bonzini  <bonzini@gnu.org>
8456             Bruno Haible  <bruno@clisp.org>
8457
8458         Tests for module 'pipe-filter-gi'.
8459         * modules/pipe-filter-gi-tests: New file.
8460         * tests/test-pipe-filter-gi1.sh: New file.
8461         * tests/test-pipe-filter-gi1.c: New file.
8462         * tests/test-pipe-filter-gi2.sh: New file.
8463         * tests/test-pipe-filter-gi2-main.c: New file.
8464         * tests/test-pipe-filter-gi2-child.c: New file.
8465
8466         New module 'pipe-filter-gi'.
8467         * lib/pipe-filter-gi.c: New file.
8468         * modules/pipe-filter-gi: New file.
8469
8470 2009-08-02  Bruno Haible  <bruno@clisp.org>
8471             Paolo Bonzini  <bonzini@gnu.org>
8472
8473         Tests for module 'pipe-filter-ii'.
8474         * modules/pipe-filter-ii-tests: New file.
8475         * tests/test-pipe-filter-ii1.sh: New file.
8476         * tests/test-pipe-filter-ii1.c: New file.
8477         * tests/test-pipe-filter-ii2.sh: New file.
8478         * tests/test-pipe-filter-ii2-main.c: New file.
8479         * tests/test-pipe-filter-ii2-child.c: New file.
8480
8481         New module 'pipe-filter-ii'.
8482         * lib/pipe-filter.h: New file.
8483         * lib/pipe-filter-ii.c: New file.
8484         * lib/pipe-filter-aux.h: New file.
8485         * modules/pipe-filter-ii: New file.
8486
8487 2009-08-02  Simon Josefsson  <simon@josefsson.org>
8488
8489         * lib/gc-libgcrypt.c: Change copyright to FSF.
8490         * lib/gc-gnulib.c: Likewise.
8491
8492 2009-08-02  Martin Lambers  <marlam@marlam.de>  (tiny change)
8493
8494         * lib/gethostname.c: Include limits.h.
8495
8496 2009-08-02  Simon Josefsson  <simon@josefsson.org>
8497             Bruno Haible  <bruno@clisp.org>
8498
8499         Ensure HOST_NAME_MAX as part of the gethostname module.
8500         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): On native Windows platforms,
8501         define also HOST_NAME_MAX.
8502         * tests/test-gethostname.c: Include <limits.h>.
8503         (main): Check also HOST_NAME_MAX.
8504         * doc/posix-headers/limits.texi: Document the mingw problem.
8505
8506 2009-08-02  Bruno Haible  <bruno@clisp.org>
8507
8508         * lib/gethostname.c (gethostname): Fix handling of large len argument.
8509         Add comments.
8510
8511 2009-03-31  Simon Josefsson  <simon@josefsson.org>
8512
8513         * lib/gethostname.c: Add Windows wrapper.
8514         * m4/gethostname.m4: Look for gethostname in -lws2_32.
8515         * modules/gethostname: Depend on sys_socket & errno, for also
8516         added lib/w32sock.h.  Add GETHOSTNAME_LIB link directive.
8517         * modules/gethostname-tests: Link to @GETHOSTNAME_LIB@.
8518
8519 2009-07-31  Jim Meyering  <meyering@redhat.com>
8520
8521         getloadavg: fix symbol name in comment
8522         * lib/getloadavg.c: Correct a typo I introduced when adding
8523         comments to Matt's change: s/NLIST_POINTER/N_NAME_POINTER/.
8524         Matt Kraai spotted the problem.
8525
8526 2009-07-29  Matt Kraai  <mkraai@beckman.com>
8527
8528         getloadavg: check whether n_name is a pointer, for QNX 6.4.1
8529         * lib/getloadavg.c (getloadavg): Use the strcpy-into-nlist.n_name
8530         code also if ! defined N_NAME_POINTER.
8531         * m4/getloadavg.m4 (gl_GETLOADAVG): Add a link-test for N_NAME_POINTER.
8532         This is required on QNX 6.4.1, where /usr/include/nlist.h exists,
8533         but the n_name member is a 12-byte array.
8534
8535 2009-07-29  Joel E. Denny  <jdenny@clemson.edu>
8536
8537         update-copyright: generalize comment handling
8538         * build-aux/update-copyright: Handle copyright statements
8539         within more comment styles.
8540         Document usage.
8541         Report any file with an external copyright holder or parse failure.
8542
8543 2009-07-29  Jim Meyering  <meyering@redhat.com>
8544
8545         mktime: correct setting of REPLACE_MKTIME
8546         * m4/mktime.m4 (gl_FUNC_MKTIME): Set REPLACE_MKTIME=0, when required.
8547
8548         update-copyright: new module
8549         * modules/update-copyright: New file.
8550         * build-aux/update-copyright: New file.
8551         * MODULES.html.sh (maint+release support): Add update-copyright.
8552
8553 2009-07-27  Bruno Haible  <bruno@clisp.org>
8554
8555         Fix compilation error when <ctime> is used and mktime is replaced.
8556         * lib/time.in.h (mktime): New declaration.
8557         * m4/mktime.m4 (gl_FUNC_MKTIME): Require gl_HEADER_TIME_H_DEFAULTS. Set
8558         REPLACE_MKTIME instead of defining mktime in config.h.
8559         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize REPLACE_MKTIME.
8560         * modules/time (Makefile.am): Substitute REPLACE_MKTIME.
8561         Reported by Ross McFarland <rwmcfa1@neces.com>.
8562
8563 2009-07-27  Bruno Haible  <bruno@clisp.org>
8564
8565         * lib/math.in.h (cosl, logl, sinl): Undefine before declaring it.
8566         Reported by Matt Kraai <mkraai@beckman.com>.
8567
8568 2009-07-25  Jim Meyering  <meyering@redhat.com>
8569
8570         maint.mk: avoid warnings about missing files
8571         * top/maint.mk (PREV_VERSION): Suppress stderr, to hide a
8572         diagnostic when .prev-version does not exist.
8573         (_cfg_mk): Define, so it can be empty when cfg.mk does not exist.
8574         (syntax-check-rules): Use $(_cfg_mk) to avoid a diagnostic about
8575         nonexistent cfg.mk.
8576         Suggestions from Simon Josefsson.
8577
8578 2009-07-25  Bruno Haible  <bruno@clisp.org>
8579
8580         * lib/math.in.h (cosl, logl, sinl): Don't declare if they are already
8581         defined as macros. Needed on QNX 6.4.1.
8582         Reported by Matt Kraai <mkraai@beckman.com>.
8583
8584 2009-07-23  Jim Meyering  <meyering@redhat.com>
8585
8586         maint.mk: invoke "make dist" with a working value of XZ_OPT
8587         * top/maint.mk (vc-dist): Use no "-" in the value of XZ_OPT.
8588
8589 2009-07-22  Matt Kraai  <mkraai@beckman.com>  (tiny change)
8590
8591         Make fseeko.c compile on QNX.
8592         * lib/fseeko.c (rpl_fseeko): Use the numerical value of _MWRITE.
8593
8594 2009-07-22  Peter Simons  <simons@cryp.to>
8595
8596         C++: wrap md2,md5,sha1,etc. function declarations in extern "C" scope
8597         * lib/md2.h [__cplusplus]: Wrap declarations in extern "C" scope.
8598         * lib/md4.h: Likewise.
8599         * lib/md5.h: Likewise.
8600         * lib/sha1.h: Likewise.
8601         * lib/sha256.h: Likewise.
8602         * lib/sha512.h: Likewise.
8603
8604         tests-sha1: don't assign literal string to 'char *' variable
8605         * tests/test-sha1.c (main): Declare locals with "const" to match
8606         attributes of the right hand side.
8607
8608 2009-07-21  Eric Blake  <ebb9@byu.net>
8609
8610         dup2: fix more mingw problems
8611         * lib/dup2.c (rpl_dup2) [_WIN32]: Avoid hanging when duplicating
8612         fd to itself.
8613         * doc/posix-functions/dup2.texi (dup2): Document the bug.
8614         * lib/unistd.in.h (dup2) [REPLACE_FCHDIR]: Avoid name collision.
8615         * lib/fchdir.c (dup2): Manage preprocessor macros correctly.
8616         (rpl_dup2_fchdir): Rename from rpl_dup2, and let dup2 module take
8617         care of mingw bugs.
8618
8619 2009-07-21  Jim Meyering  <meyering@redhat.com>
8620
8621         vc-list-files: avoid failure when /bin/sh is dash
8622         * build-aux/vc-list-files: Avoid a shell portability problem with dash.
8623         On some Debian based systems, /bin/sh is a symlink to dash, and running
8624         this command would omit the "/" following each 'tests' prefix:
8625           dash -x build-aux/vc-list-files -C . tests
8626         That is because bash and dash work differently:
8627           $ for i in bash dash; do $i -c 'a=odd; a=ok b=$a; echo '$i' $b'; done
8628           bash ok
8629           dash odd
8630
8631 2009-07-21  Eric Blake  <ebb9@byu.net>
8632
8633         dup2-tests: test previous patch
8634         * modules/dup2-tests: New file.
8635         * tests/test-dup2.c: Likewise.
8636         * tests/test-open.c (main): Avoid unspecified behavior.
8637         * tests/test-pipe.c (child_main): Use dup2 semantics to simplify
8638         test.
8639
8640         dup2: work around mingw and cygwin 1.5 bug
8641         * m4/dup2.m4 (gl_FUNC_DUP2): Detect mingw bug.
8642         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
8643         * modules/unistd (Makefile.am): Substitute it.
8644         * lib/unistd.in.h (dup2): Declare the replacement.
8645         * lib/dup2.c (dup2) [REPLACE_DUP2]: Implement it.
8646         * doc/posix-functions/dup2.texi (dup2): Document the bugs.
8647         * lib/fchdir.c (rpl_dup2): Don't collide with mingw replacement.
8648         * modules/execute (Depends-on): Add dup2.
8649         * modules/fseterr (Depends-on): Likewise.
8650         * modules/pipe (Depends-on): Likewise.
8651         * modules/posix_spawn-internal (Depends-on): Likewise.
8652
8653 2009-07-21  Bruno Haible  <bruno@clisp.org>
8654
8655         * modules/.gitattributes: New file.
8656
8657 2009-07-20  Bruno Haible  <bruno@clisp.org>
8658
8659         * tests/test-pipe.c (BACKUP_STDERR_FILENO): New macro.
8660         (main): Use it.
8661
8662 2009-07-20  Eric Blake  <ebb9@byu.net>
8663
8664         test-pipe: make a bit more robust.
8665         * tests/test-pipe.c (myerr): Allow error messages regardless of
8666         what we do to stderr.
8667         (test_pipe): Rearrange to avoid deadlock.
8668         (child_main): Try a larger read, to ensure we avoided deadlock.
8669         * lib/pipe.c (create_pipe) [_WIN32]: Fix comment.
8670         * lib/pipe.h (create_pipe_bidi): Document potential for deadlock
8671         if misused.
8672
8673 2009-07-19  Jim Meyering  <meyering@redhat.com>
8674
8675         fts: avoid false-positive cycle-detection
8676         * lib/fts.c (fts_read): Reinitialize cycle-detection data structures
8677         for each new command line argument.
8678
8679 2009-07-19  Bruno Haible  <bruno@clisp.org>
8680
8681         Fix build error on mingw with the modules sys_select and unistd.
8682         * modules/acl-tests (Depends-on): Add close.
8683         * modules/binary-io-tests (Depends-on): Likewise.
8684         * modules/closein-tests (Depends-on): Likewise.
8685         * modules/flock-tests (Depends-on): Likewise.
8686         * modules/fsync-tests (Depends-on): Likewise.
8687         * modules/lseek-tests (Depends-on): Likewise.
8688         * modules/pipe-tests (Depends-on): Likewise.
8689         * modules/posix_spawn-tests (Depends-on): Likewise.
8690         * modules/posix_spawnp-tests (Depends-on): Likewise.
8691         * modules/stat-time-tests (Depends-on): Likewise.
8692         * modules/yesno-tests (Depends-on): Likewise.
8693
8694 2009-07-19  Bruno Haible  <bruno@clisp.org>
8695
8696         Unify conditionals.
8697         * lib/pipe.h: Detect native Win32 by looking at _WIN32 and __WIN32__
8698         macros, not at the compiler macros.
8699         * lib/pipe.c: Likewise.
8700         * lib/execute.c: Likewise.
8701         * lib/spawni.c: Likewise.
8702
8703 2009-07-19  Bruno Haible  <bruno@clisp.org>
8704
8705         Fix handling of closed stdin/stdout/stderr on mingw.
8706         * lib/w32spawn.h: Include unistd.h.
8707         (dup_noinherit): Return -1 if the old handle is invalid. Allocate new
8708         file descriptor with O_NOINHERIT flag.
8709         (fd_safer_noinherit): New function, based on fd-safer.c.
8710         (dup_safer_noinherit): New function, based on dup-safer.c.
8711         (undup_safer_noinherit): New function.
8712         * lib/execute.c (execute) [WIN32]: Use dup_safer_noinherit instead of
8713         dup_noinherit. Use undup_safer_noinherit instead of dup2 and close.
8714         * lib/pipe.c (create_pipe) [WIN32]: Likewise. Use fd_safer_noinherit
8715         instead of fd_safer.
8716         * tests/test-pipe.c: Include <windows.h>.
8717         (child_main) [WIN32]: Test the handle of STDERR_FILENO, not its close() result.
8718
8719         * tests/test-pipe.c (child_main, parent_main): New functions, extracted
8720         from main.
8721         (test_pipe): Pass an extra argument for disambiguation.
8722         (main): Invoke parent_main or child_main.
8723
8724         * tests/test-pipe.c (test_pipe): Pass slave_process = true argument
8725         consistently.
8726
8727 2009-07-18  Eric Blake  <ebb9@byu.net>
8728
8729         test-pipe: fix mingw build
8730         * tests/test-pipe.c (main): Avoid fcntl on mingw.
8731
8732 2009-07-18  Bruno Haible  <bruno@clisp.org>
8733
8734         * modules/pipe-tests (Makefile.am): Fix typo.
8735
8736 2009-07-18  Eric Blake  <ebb9@byu.net>
8737
8738         error: fix mingw build
8739         * lib/error.c (error, error_at_line): Avoid fcntl on mingw.
8740         Reported by Bruno Haible.
8741
8742         error: avoid undefined use of stdout
8743         * lib/error.c (error, error_at_line): Check that fd 1 is open
8744         before flushing stdout.  Avoids a crash on cygwin when libsigsegv
8745         is handling faults and the close_stdout module wants to report the
8746         detection of closed stdout as an error.
8747
8748 2009-07-17  Eric Blake  <ebb9@byu.net>
8749
8750         pipe: be robust in face of closed fds
8751         * lib/pipe.c (create_pipe): Closed standard descriptors in parent
8752         should cause child to misbehave.
8753         * modules/pipe-tests: New module.
8754         * tests/test-pipe.c: New file.
8755         * tests/test-pipe.sh: New file.
8756         Reported by Akim Demaille.
8757
8758 2009-07-14  Bruno Haible  <bruno@clisp.org>
8759
8760         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Guess it works on glibc systems.
8761         Reported by anonymous kc.
8762
8763 2009-07-07  Jim Meyering  <meyering@redhat.com>
8764
8765         maint.mk: don't look for translatable strings in *.m4 or *.mk
8766         * top/maint.mk (sc_po_check): Skip *.m4 and *.mk files,
8767         when searching for translatable strings.
8768
8769 2009-07-05  Jim Meyering  <meyering@redhat.com>
8770
8771         remove superfluous parentheses in STREQ definition
8772         * tests/test-argv-iter.c (STREQ): Remove redundant parentheses.
8773         * lib/getugroups.c (STREQ): Likewise.
8774         * lib/fnmatch.c (STREQ): Likewise.
8775         Spotted by Bruno Haible.
8776
8777 2009-07-04  Jim Meyering  <meyering@redhat.com>
8778
8779         argv-iter: new module
8780         * MODULES.html.sh: Add argv-iter.
8781         * lib/argv-iter.c, lib/argv-iter.h: New files.
8782         * modules/argv-iter: New file.
8783         * modules/argv-iter-tests: New file.
8784         * tests/test-argv-iter.c: Test it.
8785
8786 2009-07-04  Bruno Haible  <bruno@clisp.org>
8787
8788         Fix assertion.
8789         * lib/git-merge-changelog.c (compute_mapping): In the case where file1
8790         contains more exact copies of a given entry than file2, leave the extra
8791         copies unpaired rather than aborting.
8792         Reported by Eric Blake.
8793
8794 2009-07-02  Bruno Haible  <bruno@clisp.org>
8795
8796         Speedup git-merge-changelog for git cherry-pick.
8797         * lib/git-merge-changelog.c (struct entries_mapping): New type.
8798         (entries_mapping_get): New function, extracted from compute_mapping.
8799         (entries_mapping_reverse_get): New function.
8800         (compute_mapping): Add a 'full' argument. Return the result in a
8801         'struct entries_mapping'.
8802         (main): Update. Access the mappings through entries_mapping_get.
8803         Reported by Eric Blake.
8804
8805 2009-07-02  Bruno Haible  <bruno@clisp.org>
8806
8807         * lib/git-merge-changelog.c (compute_mapping): Fix determination of
8808         best_i.
8809
8810 2009-07-02  Bruno Haible  <bruno@clisp.org>
8811
8812         Speed up approximate search for matching ChangeLog entries.
8813         * lib/git-merge-changelog.c (entry_fstrcmp): Add a lower_bound
8814         argument. Call fstrcmp_bounded instead of fstrcmp.
8815         (compute_mapping, try_split_merged_entry, main): Update callers.
8816
8817 2009-07-02  Bruno Haible  <bruno@clisp.org>
8818
8819         * lib/git-merge-changelog.c (main): Add comment about git cherry-pick.
8820
8821 2009-06-30  Bruno Haible  <bruno@clisp.org>
8822
8823         Reduce the number of uc_is_cased calls.
8824         * lib/unicase.h (casing_suffix_context_t): Add
8825         'first_char_except_ignorable' field.
8826         * lib/unicase/context.h (SCC_FINAL_SIGMA_MASK): Remove macro.
8827         (SCC_MORE_ABOVE_MASK, SCC_BEFORE_DOT_MASK): Update.
8828         * lib/unicase/empty-suffix-context.c (unicase_empty_suffix_context):
8829         Update initializer.
8830         * lib/unicase/u-casemap.h (FUNC): Don't invoke uc_is_cased on
8831         case-ignorable characters.
8832         * lib/unicase/u-ct-totitle.h (FUNC): Likewise.
8833         * lib/unicase/u-suffix-context.h (FUNC2): Don't call uc_is_cased here.
8834         * modules/unicase/u8-suffix-context (Depends-on): Remove unicase/cased.
8835         * modules/unicase/u16-suffix-context (Depends-on): Likewise.
8836         * modules/unicase/u32-suffix-context (Depends-on): Likewise.
8837
8838 2009-06-30  Bruno Haible  <bruno@clisp.org>
8839
8840         Tests for module 'unicase/ignorable'.
8841         * modules/unicase/ignorable-tests: New file.
8842         * tests/unicase/test-ignorable.c: New file, generated by
8843         gen-uni-tables.
8844
8845         Tests for module 'unicase/cased'.
8846         * modules/unicase/cased-tests: New file.
8847         * tests/unicase/test-cased.c: New file, generated by gen-uni-tables.
8848         * tests/unicase/test-predicate-part1.h: New file, derived from
8849         tests/unictype/test-predicate-part1.h.
8850         * tests/unicase/test-predicate-part2.h: New file, same as
8851         tests/unictype/test-predicate-part2.h.
8852
8853         Fix evaluation of "Before C" condition of FINAL_SIGMA.
8854         * lib/gen-uni-tables.c (is_cased, is_case_ignorable): New functions.
8855         (output_casing_properties): New function.
8856         (main): Call it.
8857         * lib/unicase/cased.h: New file, generated by gen-uni-tables.
8858         * lib/unicase/cased.c: Include unictype/bitmap.h.
8859         (uc_is_cased): Define through a bitmap lookup.
8860         * lib/unicase/ignorable.h: New file, generated by gen-uni-tables.
8861         * lib/unicase/ignorable.c: Include unictype/bitmap.h.
8862         (uc_is_case_ignorable): Define through a bitmap lookup.
8863         * modules/unicase/cased (Files): Add lib/unicase/cased.h,
8864         lib/unictype/bitmap.h.
8865         (Depends-on): Add inline. Clean up.
8866         * modules/unicase/ignorable (Files): Add lib/unicase/ignorable.h,
8867         lib/unictype/bitmap.h.
8868         (Depends-on): Add inline. Clean up.
8869         * tests/unicase/test-u8-tolower.c (main): Add more tests of FINAL_SIGMA
8870         recognition.
8871         * tests/unicase/test-u16-tolower.c (main): Likewise.
8872         * tests/unicase/test-u32-tolower.c (main): Likewise.
8873
8874 2009-06-30  Bruno Haible  <bruno@clisp.org>
8875
8876         * lib/unicase/u8-casemap.c: Don't include uniwbrk.h.
8877         * lib/unicase/u16-casemap.c: Likewise.
8878         * lib/unicase/u32-casemap.c: Likewise.
8879
8880 2009-06-29  Bruno Haible  <bruno@clisp.org>
8881
8882         Define u32_casefold as a wrapper around u32_ct_casefold.
8883         * lib/unicase/u32-casefold.c: Update.
8884         * modules/unicase/u32-casefold (Depends-on): Add
8885         unicase/u32-ct-casefold, unicase/empty-prefix-context,
8886         unicase/empty-suffix-context. Clean up.
8887
8888         Define u16_casefold as a wrapper around u16_ct_casefold.
8889         * lib/unicase/u16-casefold.c: Update.
8890         * modules/unicase/u16-casefold (Depends-on): Add
8891         unicase/u16-ct-casefold, unicase/empty-prefix-context,
8892         unicase/empty-suffix-context. Clean up.
8893
8894         Define u8_casefold as a wrapper around u8_ct_casefold.
8895         * lib/unicase/u-casefold.h (FUNC): Delegate to U_CT_CASEFOLD.
8896         * lib/unicase/u8-casefold.c: Update.
8897         * modules/unicase/u8-casefold (Depends-on): Add unicase/u8-ct-casefold,
8898         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
8899
8900         Define u32_totitle as a wrapper around u32_ct_totitle.
8901         * lib/unicase/u32-totitle.c: Update.
8902         * modules/unicase/u32-totitle (Depends-on): Add unicase/u32-ct-totitle,
8903         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
8904
8905         Define u16_totitle as a wrapper around u16_ct_totitle.
8906         * lib/unicase/u16-totitle.c: Update.
8907         * modules/unicase/u16-totitle (Depends-on): Add unicase/u16-ct-totitle,
8908         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
8909
8910         Define u8_totitle as a wrapper around u8_ct_totitle.
8911         * lib/unicase/u-totitle.h (is_cased, is_case_ignorable): Remove
8912         functions.
8913         (FUNC): Delegate to U_CT_TOTITLE.
8914         * lib/unicase/u8-totitle.c: Update.
8915         * modules/unicase/u8-totitle (Depends-on): Add unicase/u8-ct-totitle,
8916         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
8917
8918         * lib/unicase/u32-tolower.c (u32_tolower): Update u32_casemap
8919         invocation.
8920         * modules/unicase/u32-tolower (Depends-on): Add
8921         unicase/empty-prefix-context, unicase/empty-suffix-context.
8922
8923         * lib/unicase/u16-tolower.c (u16_tolower): Update u16_casemap
8924         invocation.
8925         * modules/unicase/u16-tolower (Depends-on): Add
8926         unicase/empty-prefix-context, unicase/empty-suffix-context.
8927
8928         * lib/unicase/u8-tolower.c (u8_tolower): Update u8_casemap invocation.
8929         * modules/unicase/u8-tolower (Depends-on): Add
8930         unicase/empty-prefix-context, unicase/empty-suffix-context.
8931
8932         * lib/unicase/u32-toupper.c (u32_toupper): Update u32_casemap
8933         invocation.
8934         * modules/unicase/u32-toupper (Depends-on): Add
8935         unicase/empty-prefix-context, unicase/empty-suffix-context.
8936
8937         * lib/unicase/u16-toupper.c (u16_toupper): Update u16_casemap
8938         invocation.
8939         * modules/unicase/u16-toupper (Depends-on): Add
8940         unicase/empty-prefix-context, unicase/empty-suffix-context.
8941
8942         * lib/unicase/u8-toupper.c (u8_toupper): Update u8_casemap invocation.
8943         * modules/unicase/u8-toupper (Depends-on): Add
8944         unicase/empty-prefix-context, unicase/empty-suffix-context.
8945
8946         New module 'unicase/u32-ct-casefold'.
8947         * lib/unicase/u32-ct-casefold.c: New file.
8948         * modules/unicase/u32-ct-casefold: New file.
8949
8950         New module 'unicase/u16-ct-casefold'.
8951         * lib/unicase/u16-ct-casefold.c: New file.
8952         * modules/unicase/u16-ct-casefold: New file.
8953
8954         New module 'unicase/u8-ct-casefold'.
8955         * lib/unicase/u8-ct-casefold.c: New file.
8956         * lib/unicase/u-ct-casefold.h: New file, derived from
8957         lib/unicase/u-casefold.h.
8958         * modules/unicase/u8-ct-casefold: New file.
8959
8960         New module 'unicase/u32-ct-totitle'.
8961         * lib/unicase/u32-ct-totitle.c: New file.
8962         * modules/unicase/u32-ct-totitle: New file.
8963
8964         New module 'unicase/u16-ct-totitle'.
8965         * lib/unicase/u16-ct-totitle.c: New file.
8966         * modules/unicase/u16-ct-totitle: New file.
8967
8968         New module 'unicase/u8-ct-totitle'.
8969         * lib/unicase/u8-ct-totitle.c: New file.
8970         * lib/unicase/u-ct-totitle.h: New file, derived from
8971         lib/unicase/u-totitle.h.
8972         * modules/unicase/u8-ct-totitle: New file.
8973
8974         New module 'unicase/u32-ct-tolower'.
8975         * lib/unicase/u32-ct-tolower.c: New file.
8976         * modules/unicase/u32-ct-tolower: New file.
8977
8978         New module 'unicase/u16-ct-tolower'.
8979         * lib/unicase/u16-ct-tolower.c: New file.
8980         * modules/unicase/u16-ct-tolower: New file.
8981
8982         New module 'unicase/u8-ct-tolower'.
8983         * lib/unicase/u8-ct-tolower.c: New file.
8984         * modules/unicase/u8-ct-tolower: New file.
8985
8986         New module 'unicase/u32-ct-toupper'.
8987         * lib/unicase/u32-ct-toupper.c: New file.
8988         * modules/unicase/u32-ct-toupper: New file.
8989
8990         New module 'unicase/u16-ct-toupper'.
8991         * lib/unicase/u16-ct-toupper.c: New file.
8992         * modules/unicase/u16-ct-toupper: New file.
8993
8994         New module 'unicase/u8-ct-toupper'.
8995         * lib/unicase/u8-ct-toupper.c: New file.
8996         * modules/unicase/u8-ct-toupper: New file.
8997
8998         Add context arguments to u*_casemap functions.
8999         * lib/unicase/unicasemap.h: Include unicase.h.
9000         (u8_casemap, u16_casemap, u32_casemap): Add prefix_context and
9001         suffix_context arguments.
9002         * lib/unicase/u-casemap.h (is_cased, is_case_ignorable): Remove
9003         functions.
9004         (FUNC): Add prefix_context and suffix_context arguments. Use
9005         uc_is_cased and uc_is_case_ignorable.
9006         * lib/unicase/u8-casemap.c: Include caseprop.h and context.h.
9007         * lib/unicase/u16-casemap.c: Likewise.
9008         * lib/unicase/u32-casemap.c: Likewise.
9009         * modules/unicase/u8-casemap (Files): Add lib/unicase/context.h.
9010         (Depends-on): Add unicase/cased, unicase/ignorable. Clean up.
9011         * modules/unicase/u16-casemap (Files): Add lib/unicase/context.h.
9012         (Depends-on): Add unicase/cased, unicase/ignorable. Clean up.
9013         * modules/unicase/u32-casemap (Files): Add lib/unicase/context.h.
9014         (Depends-on): Add unicase/cased, unicase/ignorable. Clean up.
9015
9016         New module 'unicase/u32-suffix-context'.
9017         * lib/unicase/u32-suffix-context.c: New file.
9018         * modules/unicase/u32-suffix-context: New file.
9019
9020         New module 'unicase/u16-suffix-context'.
9021         * lib/unicase/u16-suffix-context.c: New file.
9022         * modules/unicase/u16-suffix-context: New file.
9023
9024         New module 'unicase/u8-suffix-context'.
9025         * lib/unicase/u8-suffix-context.c: New file.
9026         * lib/unicase/u-suffix-context.h: New file.
9027         * modules/unicase/u8-suffix-context: New file.
9028
9029         New module 'unicase/empty-suffix-context'.
9030         * lib/unicase/empty-suffix-context.c: New file.
9031         * modules/unicase/empty-suffix-context: New file.
9032
9033         New module 'unicase/u32-prefix-context'.
9034         * lib/unicase/u32-prefix-context.c: New file.
9035         * modules/unicase/u32-prefix-context: New file.
9036
9037         New module 'unicase/u16-prefix-context'.
9038         * lib/unicase/u16-prefix-context.c: New file.
9039         * modules/unicase/u16-prefix-context: New file.
9040
9041         New module 'unicase/u8-prefix-context'.
9042         * lib/unicase/u8-prefix-context.c: New file.
9043         * lib/unicase/u-prefix-context.h: New file.
9044         * lib/unicase/context.h: New file.
9045         * modules/unicase/u8-prefix-context: New file.
9046
9047         New module 'unicase/empty-prefix-context'.
9048         * lib/unicase/empty-prefix-context.c: New file.
9049         * modules/unicase/empty-prefix-context: New file.
9050
9051         New module 'unicase/ignorable'.
9052         * lib/unicase/ignorable.c: New file.
9053         * modules/unicase/ignorable: New file.
9054
9055         New module 'unicase/cased'.
9056         * lib/unicase/caseprop.h: New file.
9057         * lib/unicase/cased.c: New file.
9058         * modules/unicase/cased: New file.
9059
9060         New functions for case mapping of substrings.
9061         * lib/unicase.h (casing_prefix_context_t): New type.
9062         (unicase_empty_prefix_context): New variable.
9063         (u8_casing_prefix_context, u16_casing_prefix_context,
9064         u32_casing_prefix_context, u8_casing_prefixes_context,
9065         u16_casing_prefixes_context, u32_casing_prefixes_context): New
9066         declarations.
9067         (casing_suffix_context_t): New type.
9068         (unicase_empty_suffix_context): New variable.
9069         (u8_casing_suffix_context, u16_casing_suffix_context,
9070         u32_casing_suffix_context, u8_casing_suffixes_context,
9071         u16_casing_suffixes_context, u32_casing_suffixes_context,
9072         u8_ct_toupper, u16_ct_toupper, u32_ct_toupper, u8_ct_tolower,
9073         u16_ct_tolower, u32_ct_tolower, u8_ct_totitle, u16_ct_totitle,
9074         u32_ct_totitle, u8_ct_casefold, u16_ct_casefold, u32_ct_casefold): New
9075         declarations.
9076
9077 2009-06-28  Jim Meyering  <meyering@redhat.com>
9078
9079         boostrap: indent only with spaces
9080         * build-aux/bootstrap: Indent only with spaces, never TABs.
9081
9082         bootstrap: split long lines
9083         * build-aux/bootstrap: Keep line length < 80.
9084
9085         bootstrap: sync from coreutils
9086         * build-aux/bootstrap: Honor variables like $ACLOCAL, etc.,
9087         just as autoreconf does.  Verify a list of prerequisite
9088         package-name,version-number pairs if defined in bootstrap.conf.
9089         Refer to README-prereq, if prerequisites are not satisfied.
9090
9091 2009-06-27  Eric Blake  <ebb9@byu.net>
9092
9093         tests: add test for bogus NULL definition
9094         * tests/test-stdio.c: Ensure POSIX 2008 requirement on NULL.
9095         * tests/test-stdlib.c: Likewise.
9096         * tests/test-string.c: Likewise.
9097         * tests/test-locale.c: Likewise.
9098         * tests/test-unistd.c: Likewise.
9099         * modules/stdio-tests (Depends-on): Add verify.
9100         * modules/stdlib-tests (Depends-on): Likewise.
9101         * modules/string-tests (Depends-on): Likewise.
9102         * modules/locale-tests (Depends-on): Likewise.
9103         * modules/unistd-tests (Depends-on): Likewise.
9104
9105 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
9106
9107         * m4/selinux-context-h (gl_HEADERS_SELINUX_CONTEXT_H): Remove
9108         self-explaining comment.
9109         * m4/selinux-selinux-h: Update serial.
9110         (gl_LIBSELINUX): New macro, adding a warning for missing development
9111         packages to code extracted from...
9112         (gl_HEADERS_SELINUX_SELINUX_H): ... this one.  Require gl_LIBSELINUX.
9113         Add warning for missing development packages here, too.
9114
9115 2009-06-26  Paolo Bonzini  <bonzini@gnu.org>
9116
9117         * build-aux/bootstrap: Do not use GIT_CONFIG_LOCAL.
9118
9119 2009-06-25  Eric Blake  <ebb9@byu.net>
9120
9121         version-etc: fix regression
9122         * lib/version-etc.h (ATTRIBUTE_SENTINEL): Define for new enough
9123         gcc.
9124         (version_etc): Use it, to catch bugs with trailing NULL.
9125         * lib/version-etc.c (version_etc_arn): Delete unused argument.
9126         (version_etc_va): Fix logic bug.
9127         * modules/version-etc-tests: Add test.
9128         * tests/test-version-etc.c: New file.
9129         * tests/test-version-etc.sh: Likewise.
9130
9131 2009-06-25  Sam Steingold  <sds@gnu.org>
9132
9133         * mbrtowc.m4 (gl_MBRTOWC_SANITYCHECK): Include <stdlib.h>, for the
9134         mbtowc declaration.
9135
9136 2009-06-25  Eric Blake  <ebb9@byu.net>
9137
9138         fpurge: migrate into <stdio.h>
9139         * lib/fpurge.h: Delete...
9140         * lib/stdio.in.h (fpurge): ...and declare here, instead.
9141         * lib/fpurge.c (fpurge): Change declaring header.
9142         * modules/fpurge (Files): Drop deleted file.
9143         (Depends-on): Add stdio.
9144         (configure.ac): Set witness.
9145         * modules/stdio (Makefile.am): Support fpurge macros.
9146         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
9147         * m4/fpurge.m4 (gl_FUNC_FPURGE): Set appropriate variables.
9148         * lib/fflush.c: Update client.
9149         * tests/test-fpurge.c: Likewise.
9150         * NEWS: Mention the change.
9151
9152 2009-06-25  Sergey Poznyakoff  <gray@gnu.org.ua>
9153
9154         * lib/argp-version-etc.c (program_authors): Add const
9155         qualifier.
9156         * lib/version-etc.c: Fix typos in the comments.
9157         * modules/argp-version-etc: Depends on version-etc.
9158
9159 2009-06-25  Sergey Poznyakoff  <gray@gnu.org.ua>
9160
9161         argp-version-etc: new module.
9162
9163         * lib/argp-version-etc.c: New file.
9164         * lib/argp-version-etc.h: New file.
9165         * modules/argp-version-etc: New file.
9166         * modules/argp-version-etc-tests: New file.
9167         * tests/test-argp-version-etc.c: New test.
9168         * tests/test-argp-version-etc-1.sh: New test.
9169
9170 2009-06-25  Sergey Poznyakoff  <gray@gnu.org.ua>
9171
9172         Provide additional interfaces and documentation for version-etc
9173         module.
9174
9175         * lib/version-etc.c (version_etc_arn, version_etc_ar): New
9176         interfaces.
9177         * lib/version-etc.h (version_etc_arn, version_etc_ar): New
9178         prototypes.
9179
9180 2009-06-24  Bruno Haible  <bruno@clisp.org>
9181
9182         * m4/lib-link.m4 (AC_LIB_HAVE_LINKFLAGS): Fix description of
9183         HAVE_LIB${NAME} macro.
9184         Reported by Sam Steingold <sds@gnu.org>.
9185
9186 2009-06-23  Simon Josefsson  <simon@josefsson.org>
9187
9188         * modules/hash-tests (test_hash_LDADD): Link to libintl when
9189         needed.
9190
9191 2009-06-21  Bruno Haible  <bruno@clisp.org>
9192
9193         Make two consecutive identical invocations of AC_LIB_HAVE_LINKFLAGS
9194         work.
9195         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Reset HAVE_LIB${NAME}
9196         together with LIB${NAME}, LTLIB${NAME}.
9197         Reported by Sam Steingold <sds@gnu.org>.
9198
9199 2009-06-20  Jim Meyering  <meyering@redhat.com>
9200
9201         tests: make sc_require_test_exit_idiom more generic
9202         * top/maint.mk (Exit_witness_file): New overridable variable.
9203         (sc_require_test_exit_idiom): Don't hard-code tests/test-lib.sh.
9204         Relax test for /^Exit \$fail$$/ to just /^Exit ./.
9205
9206 2009-06-19  Jim Meyering  <meyering@redhat.com>
9207
9208         hash: reverse order of src/dst parameters in an internal interface
9209         * lib/hash.c (transfer_entries): Reverse order of parameters to
9210         put DST before SRC.  Adjust callers.
9211
9212         tests: test-hash: avoid wholesale duplication
9213         * tests/test-hash.c (main): Don't copy/paste a 60-line loop.
9214         Instead, use a loop and add a single conditional.
9215
9216         tests: test-hash: allow seed selection via a command line argument
9217         * tests/test-hash.c (get_seed): New function.
9218         (main): Use it.
9219
9220 2009-06-19  Eric Blake  <ebb9@byu.net>
9221
9222         hash: avoid memory leak on allocation failure
9223         * lib/hash.c: (hash_rehash): Avoid memory leak on allocation
9224         failure.  Factor repeated algorithm...
9225         (transfer_entries): ...into new helper routine.
9226         (hash_delete): React to hash_rehash return value.
9227
9228         hash: reduce memory pressure in hash_rehash no-op case
9229         * lib/hash.c (next_prime): Avoid overflow.
9230         (hash_initialize): Factor bucket size computation...
9231         (compute_bucket_size): ...into new helper function.
9232         (hash_rehash): Use new function and open coding to reduce memory
9233         pressure, and avoid a memory leak in USE_OBSTACK code.
9234         Reported by Jim Meyering.
9235
9236 2009-06-18  Eric Blake  <ebb9@byu.net>
9237
9238         hash: make rotation more obvious
9239         * modules/hash (Depends-on): Add bitrotate and stdint.
9240         * lib/bitrotate.h (rotl_sz, rotr_sz): New functions.
9241         * lib/hash.c (headers): Drop limits.h.  Add stdint.h.
9242         (SIZE_MAX): Rely on headers for definition.
9243         (hash_string) [USE_DIFF_HASH]: Use rotl_sz.
9244         (raw_hasher): Use rotr_sz.
9245         Suggested by Jim Meyering.
9246
9247         hash: fix memory leak in last patch
9248         * lib/hash.c (hash_rehash): Avoid memory leak.
9249
9250         hash: avoid no-op rehashing
9251         * lib/hash.c (hash_rehash): Recognize useless rehash attempts.
9252
9253         hash: provide default callback functions
9254         * lib/hash.c (raw_hasher, raw_comparator): New functions.
9255         (hash_initialize): Use them as defaults.
9256         * tests/test-hash.c (main): Test this.
9257
9258         hash: minor optimization
9259         * lib/hash.c (hash_lookup, hash_find_entry): Avoid function call
9260         when possible.
9261         (hash_initialize): Document this promise.
9262         (hash_do_for_each, hash_clear, hash_free): Use C89 syntax.
9263         * tests/test-hash.c (hash_compare_strings): Test this.
9264
9265 2009-06-18  Bruno Haible  <bruno@clisp.org>
9266
9267         * m4/strstr.m4 (gl_FUNC_STRSTR): Skip linear time test if strstr is
9268         going to be replaced anyway.
9269
9270 2009-06-18  Bruno Haible  <bruno@clisp.org>
9271
9272         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Invoke AC_LIBOBJ only
9273         in one place.
9274         (gl_FUNC_STRCASESTR): Skip linear time test if strcasestr is going to
9275         be replaced anyway.
9276
9277 2009-06-18  Eric Blake  <ebb9@byu.net>
9278
9279         hash: check for resize before insertion
9280         * lib/hash.c (hash_insert): Check whether bucket usage exceeds
9281         threshold before insertion, so that a pathological hash_rehash
9282         that fills every bucket can still trigger another rehash.
9283
9284 2009-06-18  Jim Meyering  <meyering@redhat.com>
9285
9286         hash-tests: add a loop around the small tests
9287         * tests/test-hash.c (main): Repeat small tests with selected
9288         small initial table sizes.
9289
9290 2009-06-17  Eric Blake  <ebb9@byu.net>
9291
9292         hash: minor cleanups
9293         * lib/hash.h (hash_entry): Make opaque, by moving...
9294         * lib/hash.c (hash_entry): ...here.
9295         (hash_insert): Clarify restrictions on what can be inserted.
9296         (hash_get_next): Clarify when it is safe to remove an element
9297         during traversal.
9298         (check_tuning): Skip verification when tuning is known safe.
9299         (hash_initialize): Clarify restrictions on tuning.
9300
9301 2009-06-17  Jim Meyering  <jim@meyering.net>
9302         and Eric Blake  <ebb9@byu.net>
9303
9304         hash-tests: new module
9305         * modules/hash-tests: New file.
9306         * tests/test-hash.c: New file.
9307
9308 2009-06-17  Eric Blake  <ebb9@byu.net>
9309
9310         strstr-simple: document new module
9311         * MODULES.html.sh: Document new module.
9312
9313         strstr, strcasestr: replace on platforms with broken memchr
9314         * modules/strstr: Split into...
9315         * modules/strstr-simple: ...new module that does not care about
9316         performance, but does care about glibc bug.
9317         * m4/strstr.m4 (gl_FUNC_STRSTR): Split...
9318         (gl_FUNC_STRSTR_SIMPLE): ...into new macro, which replaces strstr
9319         if platform memchr is broken, per Debian bug 521737.
9320         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): React to broken
9321         memchr.
9322         * m4/memchr.m4 (gl_FUNC_MEMCHR): Only expand once.
9323         * doc/posix-functions/strstr.texi (strstr): Document the fix.
9324         * doc/glibc-functions/strcasestr.texi (strcasestr): Likewise.
9325         * modules/mountlist (Depends-on): Add strstr-simple.
9326         * modules/gen-uni-tables (Depends-on): Likewise.
9327         * modules/argz (Depends-on): Add strstr.
9328
9329 2009-06-17  Bruno Haible  <bruno@clisp.org>
9330
9331         * modules/posix_spawn-internal (Depends-on): Add errno.
9332
9333 2009-06-17  Bruno Haible  <bruno@clisp.org>
9334
9335         Define missing ESTALE on Interix 3.5.
9336         * lib/errno.in.h (ESTALE): Assign a value if missing.
9337         * lib/strerror.c (rpl_strerror): Handle missing ESTALE and ECANCELED.
9338         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Also test whether ESTALE is
9339         missing.
9340         * doc/posix-headers/errno.texi: Mention the Interix bug.
9341         Reported by Jay Krell <jay.krell@cornell.edu> via Eric Blake.
9342
9343 2009-06-15  Eric Blake  <ebb9@byu.net>
9344
9345         memchr, memchr2: add valgrind exception
9346         * lib/memchr.valgrind: New file.
9347         * lib/memchr2.valgrind: New file.
9348         * modules/memchr (Files): Distribute valgrind file.
9349         * modules/memchr2 (Files): Likewise.
9350
9351         docs: memchr is no longer obsolete
9352         * MODULES.html.sh: Move memchr from obsolete to string.h section.
9353         * lib/string.in.h (memchr): Simplify logic.
9354
9355 2009-06-14  Jim Meyering  <meyering@redhat.com>
9356
9357         link-follow: fix the "checking..." message to not mention trailing slash
9358         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): This test has
9359         never considered trailing slashes.
9360
9361 2009-06-14  Bruno Haible  <bruno@clisp.org>
9362
9363         * m4/memchr.m4: Mention also the bug on IA-64.
9364         * doc/posix-functions/memchr.texi: Likewise.
9365
9366 2009-06-12  Eric Blake  <ebb9@byu.net>
9367
9368         memchr: detect broken x86_64 and alpha implementations
9369         * modules/memchr-tests (Depends-on): Move mmap detection...
9370         * modules/memchr (Depends-on): ...here.
9371         (configure.ac): Set indicator.
9372         * lib/string.in.h (memchr): Declare replacement.
9373         * modules/string (Makefile.am): Trigger replacement.
9374         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
9375         * m4/memchr.m4 (gl_FUNC_MEMCHR): Use mmap to detect platform
9376         bugs.
9377         * doc/posix-functions/memchr.texi (memchr): Document the bug.
9378         * modules/getpagesize (License): Relax license.
9379
9380 2009-06-11  Bruno Haible  <bruno@clisp.org>
9381
9382         * lib/idpriv.h: Add more references.
9383
9384 2009-06-08  Bruno Haible  <bruno@clisp.org>
9385
9386         Tests for module 'idpriv-droptemp'.
9387         * modules/idpriv-droptemp-tests: New file.
9388         * tests/test-idpriv-droptemp.sh: New file.
9389         * tests/test-idpriv-droptemp.su.sh: New file.
9390         * tests/test-idpriv-droptemp.c: New file.
9391
9392         New module 'idpriv-droptemp'.
9393         * lib/idpriv-droptemp.c: New file.
9394         * modules/idpriv-droptemp: New file.
9395
9396 2009-06-08  Bruno Haible  <bruno@clisp.org>
9397
9398         Tests for module 'idpriv-drop'.
9399         * modules/idpriv-drop-tests: New file.
9400         * tests/test-idpriv-drop.sh: New file.
9401         * tests/test-idpriv-drop.su.sh: New file.
9402         * tests/test-idpriv-drop.c: New file.
9403
9404         New module 'idpriv-drop'.
9405         * lib/idpriv.h: New file.
9406         * lib-idpriv-drop.c: New file.
9407         * m4/idpriv.m4: New file.
9408         * modules/idpriv-drop: New file.
9409
9410 2009-06-08  Bruno Haible  <bruno@clisp.org>
9411
9412         * modules/unistdio/u8-vasnprintf (Depends-on): Add memchr.
9413         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
9414         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
9415         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
9416         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
9417         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
9418         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
9419
9420 2009-06-08  Eric Blake  <ebb9@byu.net>
9421
9422         test-strstr: use memory fence, when possible
9423         * tests/test-strstr.c (main): Use memory fence, in order to be
9424         more likely to trigger Debian bug 521737.
9425         * modules/strstr-tests (Files): Pull in additional files.
9426
9427         memchr: no longer obsolete, for wider field testing
9428         * modules/memchr (Status, Notice): Delete, this module is no
9429         longer obsolete.
9430         * modules/vasnprintf (Depends-on): Add memchr.
9431
9432 2009-06-07  Jim Meyering  <meyering@redhat.com>
9433
9434         hash: declare some functions with the warn_unused_result attribute
9435         * lib/hash.h (__attribute__, ATTRIBUTE_WUR): Define.
9436
9437 2009-06-07  Bruno Haible  <bruno@clisp.org>
9438
9439         * tests/test-alignof.c: Don't test int64_t if it does not exist.
9440         Reported by Eric Blake.
9441
9442 2009-06-06  Eric Blake  <ebb9@byu.net>
9443
9444         test-alignof: fix typo with long double
9445         * tests/test-alignof.c (CHECK): Use longdouble typedef to avoid
9446         compiler error.
9447
9448 2009-06-06  Neil Jerram  <neil@ossau.uklinux.net>  (tiny change)
9449
9450         Escape non-texinfo { and }s.
9451         * doc/ld-output-def.texi (Visual Studio Compatibility): Fix
9452         markup error.
9453
9454 2009-06-04  Jim Meyering  <meyering@redhat.com>
9455
9456         gitlog-to-changelog: don't infloop on an empty commit log
9457         * build-aux/gitlog-to-changelog: Warn about an empty log message.
9458         Reported by Boris Petersen <transacid@centerim.org>.
9459
9460 2009-06-03  Mike Frysinger  <vapier@gentoo.org>
9461
9462         version-etc: extend for packagers
9463         Add three new configure options, intended for packagers:
9464           --with-packager="packager name"
9465           --with-packager-version="packager-specific version"
9466           --with-packager-bug-reports="packager bug reporting"
9467         An example with coreutils:
9468           $ ./configure \
9469             --with-packager=Gentoo \
9470             --with-packager-bug-report=http://bugs.gentoo.org/ \
9471             --with-packager-version="patchset 1.6"
9472           $ ./src/ls --version | head -n2
9473           ls (GNU coreutils) 7.1-dirty
9474           Packaged by Gentoo (patchset 1.6)
9475         Note that the bug reporting info via --help doesn't show up because
9476         coreutils uses its own custom emit_bug_reporting_address() implementation
9477         in src/system.h.  If it didn't, it'd look like:
9478           $ ./src/ls --help | tail -n4
9479           Report bugs to <bug-coreutils@gnu.org>.
9480           Report Gentoo bugs to <http://bugs.gentoo.org/>.
9481           GNU coreutils home page: <http://www.gnu.org/software/coreutils/>.
9482           General help using GNU software: <http://www.gnu.org/gethelp/>.
9483         * lib/version-etc.c: Print new information, if provided.
9484         * m4/version-etc.m4: New file.
9485         * modules/version-etc (Files): Add m4/version-etc.m4.
9486         (configure.ac): Add gl_VERSION_ETC.
9487
9488 2009-05-31  Bruno Haible  <bruno@clisp.org>
9489
9490         * tests/test-alignof.c: Include <stdint.h>. Check also 'long double'
9491         and 'int64_t'.
9492         * modules/alignof-tests (Dependencies): Add stdint.
9493         Reported by Eric Blake.
9494
9495 2009-05-31  Bruno Haible  <bruno@clisp.org>
9496
9497         * lib/alignof.h (alignof_slot, alignof_type, alignof): Document
9498         restriction due to compiler bugs.
9499         Reported by Eric Blake.
9500
9501 2009-05-31  Simon Josefsson  <simon@josefsson.org>
9502             Bruno Haible  <bruno@clisp.org>
9503
9504         Fix test-alignof failure.
9505         * lib/alignof.h (alignof_slot): New macro.
9506         (alignof_type): New macro, with the same semantics as the previous
9507         'alignof'.
9508         (alignof): Alias to alignof_slot.
9509         * tests/test-alignof.c (CHECK): Check alignof_slot, not alignof. Also
9510         check that the results are usable as constant expressions.
9511
9512 2009-05-31  Bruno Haible  <bruno@clisp.org>
9513
9514         * tests/zerosize-ptr.h (zerosize_ptr): Specify more details.
9515         * tests/test-memchr.c (main): Check that memchr does not read past the
9516         first occurrence of the byte.
9517         * tests/test-strstr.c (main): Update comment.
9518         Suggested by Eric Blake.
9519
9520 2009-05-30  Bruno Haible  <bruno@clisp.org>
9521
9522         * doc/ld-output-def.texi (Visual Studio Compatibility): Explain in more
9523         detail how to use dumpbin.
9524         Reported by David Byron <dbyron@dbyron.com>.
9525
9526 2009-06-02  Simon Josefsson  <simon@josefsson.org>
9527
9528         * tests/test-parse-duration.sh: Don't use non-portable 'read -u3'.
9529
9530 2009-06-02  Simon Josefsson  <simon@josefsson.org>
9531
9532         * m4/manywarnings.m4: Add GCC 4.4 warnings.
9533
9534 2009-05-28  Bruno Haible  <bruno@clisp.org>
9535
9536         * gnulib-tool (func_import): Don't do HAVE_CONFIG_H replacements on
9537         build-aux/ files.
9538
9539 2009-05-28  Simon Josefsson  <simon@josefsson.org>
9540
9541         * gnulib-tool (func_import): Transform license on build-aux/ files too.
9542
9543 2009-05-27  Simon Josefsson  <simon@josefsson.org>
9544
9545         * gnulib-tool (sed_transform_main_lib_file)
9546         (sed_transform_testsrelated_lib_file): : Don't use non-POSIX
9547         regexps.
9548
9549 2009-05-26  Simon Josefsson  <simon@josefsson.org>
9550
9551         * tests/test-strstr.c: Add another self-test.
9552         * tests/test-strstr.c: Rewrite to use malloc/strcpy instead of
9553         strdup.  Suggested by Eric Blake  <ebb9@byu.net>.
9554
9555 2009-05-23  Bruno Haible  <bruno@clisp.org>
9556
9557         * doc/havelib.texi (AC_LIB_HAVE_LINKFLAGS): Update for 2009-04-26
9558         change.
9559
9560 2009-05-21  Bruno Haible  <bruno@clisp.org>
9561
9562         Simplify use of mode_t varargs.
9563         * lib/open.c (open): Use PROMOTED_MODE_T instead of a conditional that
9564         uses 'mode_t' or 'int'.
9565         * lib/openat.c (openat): Likewise.
9566         * lib/open-safer.c (open_safer): Likewise.
9567         * m4/mode_t.m4: New file.
9568         * m4/open.m4 (gl_PREREQ_OPEN): Require gl_PROMOTED_TYPE_MODE_T.
9569         * m4/openat.m4 (gl_PREREQ_OPENAT): Likewise.
9570         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Likewise.
9571         * modules/open (Files): Add m4/mode_t.m4.
9572         * modules/openat (Files): Likewise.
9573         * modules/fcntl-safer (Files): Likewise.
9574         Suggested by Eric Blake.
9575
9576 2009-05-21  Pádraig Brady  <P@draigbrady.com>
9577
9578         * doc/glibc-functions/fallocate.texi: New file.
9579         * doc/gnulib.texi: Include it.
9580
9581 2009-05-21  Eric Blake  <ebb9@byu.net>
9582             Bruno Haible  <bruno@clisp.org>
9583
9584         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Remove redundant m4_quote
9585         invocations.
9586         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
9587
9588 2009-05-21  Eric Blake  <ebb9@byu.net>
9589             Bruno Haible  <bruno@clisp.org>
9590
9591         Second attempt to work around an AIX 5.3, 6.1 compiler bug with
9592         include_next. Fix of 2008-11-20 commit.
9593         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Also set
9594         NEXT_AS_FIRST_DIRECTIVE_FOO_H.
9595         * lib/math.in.h: Use NEXT_AS_FIRST_DIRECTIVE_MATH_H instead of
9596         NEXT_MATH_H.
9597         * modules/math (Makefile.am): Substitute NEXT_AS_FIRST_DIRECTIVE_MATH_H
9598         instead of NEXT_MATH_H.
9599
9600 2009-05-21  Bruno Haible  <bruno@clisp.org>
9601
9602         Avoid redefinition warnings for SIZE_MAX.
9603         * m4/size_max.m4 (gl_SIZE_MAX): Avoid redefining SIZE_MAX in config.h.
9604         Reported by Simon Josefsson.
9605
9606 2009-05-21  Bruno Haible  <bruno@clisp.org>
9607
9608         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_CACHE_CHECK instead of
9609         AC_CACHE_VAL.
9610
9611 2009-05-20  Bruno Haible  <bruno@clisp.org>
9612
9613         Make zeroptr.h work on mingw.
9614         * tests/zerosize-ptr.h: Test for the presence of <sys/mman.h> and
9615         mprotect.
9616         * modules/memchr-tests (configure.ac): Also test for sys/mman.h.
9617         * modules/memchr2-tests (configure.ac): Likewise.
9618         * modules/memcmp-tests (configure.ac): Likewise.
9619         * modules/memmem-tests (configure.ac): Likewise.
9620         * modules/memrchr-tests (configure.ac): Likewise.
9621         Reported by Simon Josefsson.
9622
9623 2009-05-20  Simon Josefsson  <simon@josefsson.org>
9624
9625         * tests/test-glob.c: Include string.h for strcmp prototype.
9626
9627 2009-05-20  Simon Josefsson  <simon@josefsson.org>
9628
9629         * modules/getdelim (Depends-on): Add explicit stdint, although it
9630         was implicitly already pulled in via realloc-posix.
9631         * lib/getdelim.c: Get SIZE_MAX from stdint.h.
9632
9633 2009-05-20  Simon Josefsson  <simon@josefsson.org>
9634
9635         MinGW and IRIX does not have sa_family_t type.  Reported by "Tom
9636         G. Christensen" <tgc@jupiterrise.com>.
9637         * m4/sys_socket_h.m4: Check for sa_family_t.
9638         * lib/sys_socket.in.h: Typedef sa_family_t when needed.
9639         * modules/sys_socket: Substitute HAVE_SA_FAMILY_T.
9640         * tests/test-sys_socket.c: Check that sa_family_t works.
9641
9642 2009-05-18  Eric Blake  <ebb9@byu.net>
9643
9644         maint.mk: allow gnulib_dir in VPATH build
9645         * top/maint.mk (gnulib_dir): Make relative to $(srcdir).
9646
9647 2009-05-15  Jim Meyering  <meyering@redhat.com>
9648
9649         maint.mk: Give gnulib_dir a default definition.
9650         * top/maint.mk (gnulib_dir): Define to 'gnulib', by default.
9651         Thus, most packages no longer need to specify this variable in cfg.mk
9652
9653 2009-05-14  Tom Prince  <tom.prince@ualberta.net>  (tiny change)
9654
9655         rename.m4: fix typos that would make non-mingw cross-configure fail
9656         * m4/rename.m4 (gl_FUNC_RENAME): Fix typos.
9657
9658 2009-05-13  Eric Blake  <ebb9@byu.net>
9659
9660         mmap-anon: avoid out-of-order autoconf expansion
9661         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Use correct
9662         SYSTEM_EXTENSIONS macro to silence warnings from autoconf 2.63b.
9663         * modules/memchr-tests (Depends-on): Add extensions.
9664         * modules/memchr2-tests (Depends-on): Add extensions.
9665         * modules/memcmp-tests (Depends-on): Add extensions.
9666         * modules/memmem-tests (Depends-on): Add extensions.
9667         * modules/memrchr-tests (Depends-on): Add extensions.
9668
9669 2009-05-13  Bruno Haible  <bruno@clisp.org>
9670
9671         Make some tests ISO C 99 compliant.
9672         * tests/zerosize-ptr.h: New file.
9673         * tests/test-memchr.c: Include zerosize-ptr.h.
9674         (main): Use a zero-size object pointer instead of NULL.
9675         * tests/test-memchr2.c: Include zerosize-ptr.h.
9676         (main): Use a zero-size object pointer instead of NULL.
9677         * tests/test-memcmp.c: Include zerosize-ptr.h.
9678         (main): Use a zero-size object pointer instead of NULL.
9679         * tests/test-memmem.c: Include zerosize-ptr.h.
9680         (main): Use a zero-size object pointer instead of NULL.
9681         * tests/test-memrchr.c: Include zerosize-ptr.h.
9682         (main): Use a zero-size object pointer instead of NULL.
9683         * modules/memchr-tests (Files): Add tests/zerosize-ptr.h,
9684         m4/mmap-anon.m4.
9685         (Depends-on): Add getpagesize.
9686         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
9687         * modules/memchr2-tests (Files): Add tests/zerosize-ptr.h,
9688         m4/mmap-anon.m4.
9689         (Depends-on): Add getpagesize.
9690         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
9691         * modules/memcmp-tests (Files): Add tests/zerosize-ptr.h,
9692         m4/mmap-anon.m4.
9693         (Depends-on): Add getpagesize.
9694         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
9695         * modules/memmem-tests (Files): Add tests/zerosize-ptr.h,
9696         m4/mmap-anon.m4.
9697         (Depends-on): Add getpagesize.
9698         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
9699         * modules/memrchr-tests (Files): Add tests/zerosize-ptr.h,
9700         m4/mmap-anon.m4.
9701         (Depends-on): Add getpagesize.
9702         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
9703
9704 2009-05-12  Bruno Haible  <bruno@clisp.org>
9705
9706         Tests for module 'alignof'.
9707         * modules/alignof-tests: New file.
9708         * tests/test-alignof.c: New file.
9709
9710 2009-05-12  Bruno Haible  <bruno@clisp.org>
9711
9712         Fix alignof macro.
9713         * lib/alignof.h (alignof): Remove special cases for AIX and HP-UX
9714         vendor compilers that are always correct.
9715
9716 2009-05-12  Bruno Haible  <bruno@clisp.org>
9717
9718         Make the MAP_ANONYMOUS detection work on HP-UX 11.
9719         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check whether mmap exists, but
9720         not whether its fully works.
9721
9722 2009-05-12  Bruno Haible  <bruno@clisp.org>
9723
9724         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Add comments.
9725
9726 2009-05-12  Jim Meyering  <meyering@redhat.com>
9727
9728         * top/maint.mk: Adjust backslash alignment.
9729
9730 2009-05-11  Simon Josefsson  <simon@josefsson.org>
9731
9732         * top/maint.mk: Make $(srcdir)/build-aux configurable.
9733
9734 2009-05-11  Eric Blake  <ebb9@byu.net>
9735
9736         argp: avoid undefined behavior
9737         * lib/argp-fmtstream.c (weak_alias): Pass correct types to ctype
9738         macros.
9739
9740 2009-05-08  Simon Josefsson  <simon@josefsson.org>
9741
9742         * tests/test-vc-list-files-git.sh: Do git config of user.email and
9743         user.name to prevent git commit from complaining.
9744
9745 2009-05-10  Bruno Haible  <bruno@clisp.org>
9746
9747         * gnulib-tool (func_import, func_create_testdir, copy-file): Change
9748         sed_rewrite_old_files, sed_rewrite_new_files, sed_rewrite_files so that
9749         it rewrites every file name only once.
9750         Reported by Simon Josefsson. Helped by Ralf Wildenhues.
9751
9752 2009-05-08  Bruno Haible  <bruno@clisp.org>
9753
9754         * lib/sys_socket.in.h (_SS_PADSIZE): Use a conditional expression
9755         instead of 'max'.
9756
9757 2009-05-08  Simon Josefsson  <simon@josefsson.org>
9758
9759         * m4/sys_socket_h.m4: Test for ws2tcpip.h earlier, needed for
9760         sockaddr_storage test.
9761
9762 2009-05-07  Simon Josefsson  <simon@josefsson.org>
9763
9764         * modules/sys_socket (Makefile.am): Substitute
9765         HAVE_STRUCT_SOCKADDR_STORAGE.  Depend on alignof.
9766         * m4/sys_socket_h.m4: Check for sockaddr_storage.
9767         * lib/sys_socket.in.h (sockaddr_storage): Define when needed.
9768         * tests/test-sys_socket.c: Check sockaddr_storage.
9769
9770 2009-05-08  Bruno Haible  <bruno@clisp.org>
9771
9772         New module 'alignof'.
9773         * lib/alignof.h: New file.
9774         * modules/alignof: New file.
9775
9776 2009-05-04  David Bartley  <dtbartle@csclub.uwaterloo.ca>
9777             Bruno Haible  <bruno@clisp.org>
9778
9779         Fix test-file-has-acl on FreeBSD.
9780         * tests/test-file-has-acl.sh: Also test a directory. On FreeBSD, the
9781         mask is implicitly added.
9782         * tests/test-file-has-acl.c: Include <signal.h>.
9783         (main): Terminate the test after 5 seconds.
9784         * modules/acl-tests (configure.ac): Check for alarm function.
9785
9786 2009-05-04  Bruno Haible  <bruno@clisp.org>
9787
9788         Exploit new semantics of AC_DEFUN_ONCE available since 2009-01-26.
9789         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Remove outdated comment.
9790         * modules/errno (configure.ac): Drop AC_REQUIRE.
9791         * m4/multiarch.m4 (gl_MULTIARCH): Remove outdated comment.
9792         * modules/multiarch (configure.ac): Drop AC_REQUIRE.
9793
9794 2009-05-04  Simon Josefsson  <simon@josefsson.org>
9795
9796         * modules/glob-tests: New module.
9797         * tests/test-glob.c: Add.
9798
9799 2009-05-04  Simon Josefsson  <simon@josefsson.org>
9800
9801         * modules/fnmatch-tests: New module.
9802         * tests/test-fnmatch.c: Add.
9803
9804 2009-05-04  Eric Blake  <ebb9@byu.net>
9805
9806         maint: make the new no-submodule-changes rule VPATH-safe
9807         * top/maint.mk (no-submodule-changes): Don't assume a srcdir build.
9808
9809 2009-05-04  David Bartley  <dtbartle@csclub.uwaterloo.ca>
9810             Bruno Haible  <bruno@clisp.org>
9811
9812         acl: Fix infinite loop on FreeBSD.
9813         * lib/acl_entries.c (acl_entries) [Linux, FreeBSD]: Fix interpretation
9814         of return value from acl_get_entry.
9815         * lib/file-has-acl.c (acl_access_nontrivial) [Linux, FreeBSD]:
9816         Likewise.
9817
9818 2009-05-03  Bruno Haible  <bruno@clisp.org>
9819
9820         * lib/acl-internal.h (acl_entries): Clarify return value.
9821         * lib/acl_entries.c (acl_entries): Likewise.
9822
9823 2009-05-04  David Bartley  <dtbartle@csclub.uwaterloo.ca>
9824
9825         Bug fix in acl module.
9826         * lib/set-mode-acl.c: Use correct struct with ACL_SETACL.
9827
9828 2009-05-03  Bruno Haible  <bruno@clisp.org>
9829
9830         Create gperf-generated file in the source dir, not in the build dir.
9831         * modules/iconv_open (iconv_open-aix.h, iconv_open-hpux.h,
9832         iconv_open-irix.h, iconv_open-osf.h): Create file in the source tree.
9833         * modules/unicase/locale-language (unicase/locale-languages.h):
9834         Likewise.
9835         * modules/unicase/special-casing (unicase/special-casing-table.h):
9836         Likewise.
9837         * modules/unictype/property-byname (unictype/pr_byname.h): Likewise.
9838         * modules/unictype/scripts (unictype/scripts_byname.h): Likewise.
9839         * modules/uninorm/composition (uninorm/composition-table.h): Likewise.
9840         Reported by Ralf Wildenhues.
9841
9842 2009-05-03  Bruno Haible  <bruno@clisp.org>
9843
9844         * modules/fnmatch (Description, configure.ac): Taken from
9845         fnmatch-posix.
9846         * modules/fnmatch-posix: Turn into a symbolic reference to the
9847         'fnmatch' module, and deprecate.
9848         * doc/posix-functions/fnmatch.texi: Mention the fnmatch module.
9849
9850 2009-05-03  Bruno Haible  <bruno@clisp.org>
9851
9852         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF,
9853         gl_PREREQ_VASNPRINTF_LONG_DOUBLE): Define through AC_DEFUN_ONCE.
9854         Reported by Ralf Wildenhues.
9855
9856 2009-05-04  Simon Josefsson  <simon@josefsson.org>
9857
9858         * m4/fnmatch.m4: Fix fnmatch re-define.
9859
9860 2009-04-27  David Bartley  <dtbartle@csclub.uwaterloo.ca>
9861
9862         priv-set: new module and tests; adapt write-any-file
9863         * lib/priv-set.c: New file.
9864         * lib/priv-set.h: New file.
9865         * lib/unlinkdir.c: Make cannot_unlink_dir thread-safe.
9866         * lib/write-any-file.c: Simplify by using priv-set module.
9867         * m4/priv-set.m4: New file.
9868         * modules/priv-set: New file.
9869         * modules/unlinkdir: Add dependency on priv-set module.
9870         * modules/write-any-file: Likewise.
9871
9872         Tests for module 'priv-set'.
9873         * modules/priv-set-tests: New file.
9874         * tests/test-priv-set.c: New file.
9875
9876 2009-05-03  Jim Meyering  <meyering@redhat.com>
9877             Bruno Haible  <bruno@clisp.org>
9878
9879         * lib/propername.c (proper_name_utf8): Ignore no-op translations;
9880         use the converted UTF-8 variant of the name instead.
9881
9882 2009-05-03  Jim Meyering  <meyering@redhat.com>
9883
9884         tests: tighten some getdate tests
9885         * tests/test-getdate.c (main): Tighten tests: require equality,
9886         not just greater than.  Set TZ envvar to UTC0.
9887
9888 2009-05-03  Giuseppe Scrivano  <gscrivano@gnu.org>
9889
9890         getdate: correctly interpret "next monday" when run on a Monday
9891         * lib/getdate.y (get_date): Correct the calculation of tm_mday so
9892         that e.g., "next tues" (when run on a tuesday) results in a date
9893         that is one week in the future, and not today's date.
9894         I.e., add a week when the wday is the same as the current one.
9895         Reported by Tom Broadhurst in http://savannah.gnu.org/bugs/?25406,
9896         and earlier by Martin Bernreuther and Jan Minář.
9897         * tests/test-getdate.c (main): Check that "next DAY" is always in
9898         the future and that "last DAY" is always in the past.
9899
9900 2009-05-02  Jim Meyering  <meyering@redhat.com>
9901
9902         build: ensure that a release build fails when a submodule is unclean
9903         * top/maint.mk (no-submodule-changes): New rule.
9904         (alpha beta major): Depend on it.
9905
9906 2009-05-02  Bruno Haible  <bruno@clisp.org>
9907
9908         Remove incompatibility between modules fnmatch-posix and fnmatch-gnu.
9909         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX, gl_FUNC_FNMATCH_GNU): Use a
9910         shell variable gl_fnmatch_required to detect which variant is
9911         requested.
9912         (_AC_FUNC_FNMATCH_IF, _AC_LIBOBJ_FNMATCH): Remove macros. Inlined into
9913         gl_FUNC_FNMATCH_POSIX.
9914         * gnulib-tool (func_create_testdir, func_create_megatestdir): Don't
9915         exclude fnmatch-posix.
9916
9917 2009-05-02  Bruno Haible  <bruno@clisp.org>
9918
9919         Relicense mbsrtowcs and strnlen1 under LGPLv2+.
9920         * modules/mbsrtowcs (License): Change to LGPLv2+.
9921         * modules/strnlen1 (License): Likewise.
9922         Reported by Simon Josefsson.
9923
9924 2009-05-02  Bruno Haible  <bruno@clisp.org>
9925
9926         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Say "guessing no" instead of
9927         "cross".
9928         (gl_FUNC_FNMATCH_POSIX, gl_FUNC_FNMATCH_GNU): Update. Don't assume that
9929         gnulib-tool was called with option --source-base=lib.
9930
9931 2009-05-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9932
9933         Use automake *-local hooks without commands, for extensibility.
9934         * modules/localcharset (Makefile.am): Rename install-exec-local
9935         rule to install-exec-localcharset, and make it a prerequisite of
9936         install-exec-local.  Likewise, rename the uninstall-local rule to
9937         uninstall-localcharset, and make it a prerequisite of the former.
9938
9939 2009-05-01  Bruno Haible  <bruno@clisp.org>
9940
9941         * lib/wchar.in.h (wcsnrtombs): Define if REPLACE_WCSNRTOMBS is 1.
9942         * m4/wcsnrtombs.m4 (gl_FUNC_WCSRTOMBS): Invoke gl_MBSTATE_T_BROKEN, and
9943         set REPLACE_WCSNRTOMBS if mbstate_t must be replaced.
9944         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCSNRTOMBS.
9945         * modules/wchar (Makefile.am): Substitute REPLACE_WCSNRTOMBS.
9946         * modules/wcsnrtombs (Files): Add m4/mbrtowc.m4, m4/locale-ja.m4,
9947         m4/locale-zh.m4, m4/codeset.m4.
9948
9949         * m4/wcsrtombs.m4 (gl_FUNC_WCSNRTOMBS): Invoke gl_MBSTATE_T_BROKEN, and
9950         set REPLACE_WCSRTOMBS if mbstate_t must be replaced.
9951         * modules/wcsrtombs (Files): Add m4/mbrtowc.m4, m4/locale-ja.m4,
9952         m4/locale-zh.m4.
9953
9954         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Invoke gl_MBSTATE_T_BROKEN, and set
9955         REPLACE_WCRTOMB if mbstate_t must be replaced.
9956         * modules/wcrtomb (Files): Add m4/mbrtowc.m4.
9957         Reported by Jens Rehsack <rehsack@googlemail.com> via Eric Blake.
9958
9959 2009-05-01  Bruno Haible  <bruno@clisp.org>
9960
9961         Avoid compiler warnings when redefining macros defined by <libintl.h>.
9962         * lib/gettext.h [!ENABLE_NLS] (gettext, dgettext, dcgettext, ngettext,
9963         dngettext, dcngettext, textdomain, bindtextdomain,
9964         bind_textdomain_codeset): Undefine before redefining.
9965
9966 2009-04-30  Bruno Haible  <bruno@clisp.org>
9967
9968         Fix bug introduced on 2009-04-25.
9969         * lib/math.in.h (gl_signbitf_OPTIMIZED_MACRO,
9970         gl_signbitd_OPTIMIZED_MACRO, gl_signbitl_OPTIMIZED_MACRO): New macros.
9971         * lib/signbitf.c (gl_signbitd): Undefine if gl_signbitf_OPTIMIZED_MACRO
9972         is defined.
9973         * lib/signbitd.c (gl_signbitd): Undefine if gl_signbitd_OPTIMIZED_MACRO
9974         is defined.
9975         * lib/signbitl.c (gl_signbitd): Undefine if gl_signbitl_OPTIMIZED_MACRO
9976         is defined.
9977         Reported by Elbert_Pol <elbert.pol@gmail.com>.
9978
9979 2009-04-28  Bruno Haible  <bruno@clisp.org>
9980
9981         Comment tweaks.
9982         * lib/unistr.h (u*_cmp2): Clarify what memcmp2 is.
9983         * lib/uninorm.h (u*_normxfrm): Fix description of return value.
9984         * lib/unicase.h (u*_casexfrm): Likewise.
9985         Reported by Paolo Bonzini.
9986
9987 2009-04-28  Bruno Haible  <bruno@clisp.org>
9988
9989         Fix a compilation error.
9990         * lib/mbsrtowcs-state.c (_gl_mbsrtowcs_state): Fix initializer.
9991         * lib/wcsrtombs-state.c (_gl_wcsrtombs_state): Likewise.
9992         Reported by Jim Meyering.
9993
9994 2009-04-27  Bruno Haible  <bruno@clisp.org>
9995
9996         New module 'libunistring'.
9997         * modules/libunistring: New file.
9998         * m4/libunistring.m4: New file.
9999         * MODULES.html.sh (Unicode string functions): Add it.
10000
10001 2009-04-27  Eric Blake  <ebb9@byu.net>
10002
10003         maint.mk: allow package-specific header to provide <config.h>
10004         * top/maint.mk (sc_require_config_h): New variable.
10005         (sc_require_config_h, sc_require_config_h_first): Use it.
10006
10007 2009-04-27  Simon Josefsson  <simon@josefsson.org>
10008
10009         * top/maint.mk (sc_avoid_if_before_free): Except
10010         useless-if-before-free script.
10011
10012 2009-04-27  Eric Blake  <ebb9@byu.net>
10013
10014         maintainer-makefile: depend on all required helper scripts
10015         * modules/maintainer-makefile (Depends-on): Add vc-list-files and
10016         useless-if-before-free.
10017         * top/maint.mk (VC_LIST, sc_avoid_if_before_free): Use local
10018         version, rather than assuming gnulib checkout is available.
10019         Reported by Simen Josefsson.
10020
10021 2009-04-26  Bruno Haible  <bruno@clisp.org>
10022
10023         Make the lib vs. lib64 recognition work on openSUSE 11 with "gcc -m32".
10024         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Ignore paths that end in
10025         "../" or "..".
10026
10027 2009-04-26  Bruno Haible  <bruno@clisp.org>
10028
10029         * m4/lib-link.m4 (AC_LIB_HAVE_LINKFLAGS): Accept a fifth argument.
10030         * m4/libsigsegv.m4 (gl_LIBSIGSEGV): Simplify by using
10031         AC_LIB_HAVE_LINKFLAGS.
10032
10033 2009-04-26  Bruno Haible  <bruno@clisp.org>
10034
10035         Simplify calling convention of u*_conv_from_encoding.
10036         * lib/uniconv.h (u8_conv_from_encoding, u16_conv_from_encoding,
10037         u32_conv_from_encoding): Expect a resultbuf argument and return the
10038         result directly as a pointer.
10039         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Likewise.
10040         * lib/uniconv/u-conv-from-enc.h (FUNC): Likewise.
10041         * lib/uniconv/u-strconv-from-enc.h (FUNC): Update.
10042         * lib/unicase/ulc-casecmp.c (ulc_u8_casefold): Update.
10043         * lib/unicase/ulc-casexfrm.c (ulc_casexfrm): Update.
10044         * lib/unilbrk/ulc-possible-linebreaks.c (ulc_possible_linebreaks):
10045         Update.
10046         * lib/unilbrk/ulc-width-linebreaks.c (ulc_width_linebreaks): Update.
10047         * lib/uniwbrk/ulc-wordbreaks.c (ulc_wordbreaks): Update.
10048         * lib/vasnprintf.c (VASNPRINTF): Update.
10049         * tests/uniconv/test-u8-conv-from-enc.c (main): Update.
10050         * tests/uniconv/test-u16-conv-from-enc.c (main): Update.
10051         * tests/uniconv/test-u32-conv-from-enc.c (main): Update.
10052         * NEWS: Mention the change.
10053
10054 2009-04-26  Bruno Haible  <bruno@clisp.org>
10055
10056         Simplify calling convention of u*_conv_to_encoding.
10057         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
10058         u32_conv_to_encoding): Expect a resultbuf argument and return the
10059         result directly as a pointer.
10060         * lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise.
10061         * lib/uniconv/u-conv-to-enc.h (FUNC): Likewise. Preserve errno while
10062         freeing scaled_offsets if mem_iconveha failed.
10063         * lib/unicase/u-casexfrm.h (FUNC): Update.
10064         * lib/uninorm/u-normxfrm.h (FUNC): Update.
10065         * lib/vasnprintf.c (VASNPRINTF): Update.
10066         * tests/uniconv/test-u8-conv-to-enc.c (main): Update.
10067         * tests/uniconv/test-u16-conv-to-enc.c (main): Update.
10068         * tests/uniconv/test-u32-conv-to-enc.c (main): Update.
10069         * NEWS: Mention the change.
10070
10071 2009-04-26  Bruno Haible  <bruno@clisp.org>
10072
10073         Avoid test failures on AIX and OSF/1.
10074         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Avoid calling
10075         malloc(0).
10076         * lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise.
10077         * lib/unilbrk/ulc-possible-linebreaks.c (ulc_possible_linebreaks):
10078         Likewise.
10079         * lib/unilbrk/ulc-width-linebreaks.c (ulc_width_linebreaks): Likewise.
10080         * lib/uniwbrk/ulc-wordbreaks.c (ulc_wordbreaks): Likewise.
10081         * lib/uniconv/u-conv-to-enc.h (FUNC): Likewise. Fix memory leak.
10082         * lib/unistr/u-cpy-alloc.h (FUNC): Call malloc(1) instead of malloc(0).
10083         * doc/posix-functions/malloc.texi: Document the portability problem
10084         related to malloc(0).
10085
10086 2009-04-26  Bruno Haible  <bruno@clisp.org>
10087
10088         * modules/unistr/u8-cpy-alloc (Depends-on): Add malloc-posix.
10089         * modules/unistr/u16-cpy-alloc (Depends-on): Likewise.
10090         * modules/unistr/u32-cpy-alloc (Depends-on): Likewise.
10091
10092 2009-04-25  Bruno Haible  <bruno@clisp.org>
10093
10094         Avoid link error when creating a namespace clean library.
10095         * lib/math.in.h (gl_signbitf, gl_signbitd, gl_signbitl): Don't define
10096         as macro with arguments if already defined as an alias.
10097         * lib/signbitf.c (gl_signbitf): Don't undefine.
10098         * lib/signbitd.c (gl_signbitd): Don't undefine.
10099         * lib/signbitl.c (gl_signbitl): Don't undefine.
10100
10101 2009-04-25  Jim Meyering  <meyering@redhat.com>
10102
10103         vc-list-files: fix another quoting bug
10104         * build-aux/vc-list-files: Avoid sed backslash expansion
10105         of pathological directory names.
10106
10107 2009-04-25  Eric Blake  <ebb9@byu.net>
10108
10109         vc-list-files: fix shell quoting error
10110         * build-aux/vc-list-files: Protect against $ in $dir.  Normalize
10111         timestamp.
10112
10113 2009-04-25  Jim Meyering  <meyering@redhat.com>
10114
10115         vc-list-files: restore lost functionality with subdir argument
10116         * build-aux/vc-list-files: When given a non-"." sub-directory
10117         argument, substitute the $dir/ prefix back onto each resulting name.
10118         Otherwise, coreutils' root_tests check would fail.
10119
10120 2009-04-24  Eric Blake  <ebb9@byu.net>
10121
10122         vc-list-files: ignore git symlinks
10123         * build-aux/vc-list-files (.git): Use ls-tree and a filter, rather
10124         than ls-files, to ignore git symlinks.
10125
10126         maint.mk: import improvements from m4
10127         * top/maint.mk (VC-tag): Use signing key from cfg.mk.
10128         (move_if_change): Delete unused macro.
10129         (news-date-check, vc-diff-check): Support VPATH builds.
10130         (announcement): Likewise.  Split --bootstrap-tools list...
10131         (boostrap-tools): ...into separate list, which can be overridden
10132         in cfg.mk.
10133         (sc_avoid_if_before_free): Point to $(gnulib_dir), rather than
10134         requiring dependency on useless-if-before-free module.
10135         (VC_LIST, VC_LIST_EXCEPT): Likewise for vc-list-files module.
10136         Support VPATH builds.
10137
10138 2009-04-24  Jim Meyering  <meyering@redhat.com>
10139
10140         maint.mk: remove coreutils-specific rules and variables
10141         * top/maint.mk (bin, taint-distcheck, coreutils-path-check, t): Remove.
10142         (fake_home, install-transform-check, my-instcheck, pfx, TMPDIR): Remove.
10143         (t_prefix, t_taint, tp, warn_cflags, write_loser, my-distcheck): Remove.
10144
10145         maint.mk: remove obsolete rule
10146         * top/maint.mk (rel-check): Remove rule.
10147         (WGET, WGETFLAGS): Remove now-unused variables.
10148
10149 2009-04-24  Simon Josefsson  <simon@josefsson.org>
10150
10151         * top/maint.mk (makefile-check): Renamed to sc_makefile_check for
10152         consistency.
10153
10154         * modules/vc-list-files-tests (TESTS_ENVIRONMENT): Use
10155         '$(PATH_SEPARATOR)' instead of ':'.
10156
10157 2009-04-24  Simon Josefsson  <simon@josefsson.org>
10158
10159         * lib/getopt1.c (main): Use 'const' for static array.
10160
10161 2009-04-24  Simon Josefsson  <simon@josefsson.org>
10162
10163         * top/maint.mk: Sync with coreutils.
10164         * NEWS: Explain incompatibilities.
10165
10166 2009-04-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
10167             Bruno Haible  <bruno@clisp.org>
10168
10169         Fix cross-compilation results.
10170         * m4/btowc.m4 (gl_FUNC_BTOWC): Use no-op statement, rather than empty
10171         statement, as third argument of AC_TRY_RUN.
10172         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE, gl_MBRTOWC_SANITYCHECK,
10173         gl_MBRTOWC_NULL_ARG, gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL):
10174         Likewise.
10175         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Likewise.
10176         * m4/wcsrtombs.m4 (gl_WCSRTOMBS_TERMINATION, gl_WCSRTOMBS_NULL):
10177         Likewise.
10178         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
10179         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise. Update for AIX 4.3.
10180         * doc/posix-functions/wcrtomb.texi: Mention the bug on AIX 4.3.
10181
10182 2009-04-20  Bruno Haible  <bruno@clisp.org>
10183
10184         Avoid test failure on mingw.
10185         * tests/uniwidth/test-uc_width2.sh: Convert newlines in output.
10186
10187 2009-04-20  Bruno Haible  <bruno@clisp.org>
10188
10189         Avoid compilation error on mingw.
10190         * modules/localename-tests (Depends-on): Add locale.
10191
10192 2009-04-19  Bruno Haible  <bruno@clisp.org>
10193
10194         Support for building a shared library on Windows platforms.
10195         * tests/uninorm/test-nfc.c (n): Don't define if WOE32DLL.
10196         (main): Test the presence of UNINORM_NFC here.
10197         * tests/uninorm/test-nfd.c (n): Don't define if WOE32DLL.
10198         (main): Test the presence of UNINORM_NFD here.
10199         * tests/uninorm/test-nfkc.c (n): Don't define if WOE32DLL.
10200         (main): Test the presence of UNINORM_NFKC here.
10201         * tests/uninorm/test-nfkd.c (n): Don't define if WOE32DLL.
10202         (main): Test the presence of UNINORM_NFKD here.
10203
10204 2009-04-19  Bruno Haible  <bruno@clisp.org>
10205
10206         Avoid a compiler warning.
10207         * tests/uninorm/test-u32-normalize-big.c (read_normalization_test_file):
10208         Change type of variable 'sequence'.
10209
10210 2009-04-19  Bruno Haible  <bruno@clisp.org>
10211
10212         * modules/configmake (Makefile.am): When the contents of configmake.h
10213         does not change, arrange to preserve its modification time.
10214
10215 2009-04-17  Simon Josefsson  <simon@josefsson.org>
10216
10217         * top/maint.mk (PO_DOMAIN): New variable, allows overriding of
10218         gettext domain.
10219
10220 2009-04-16  Jim Meyering  <meyering@redhat.com>
10221
10222         useless-if-before-free: improve conversion code
10223         * build-aux/useless-if-before-free: Adjust code-in-comment to match
10224         "...!= 0" as well as "...!= NULL".  emacs has one of the former.
10225
10226 2009-04-14  Bruno Haible  <bruno@clisp.org>
10227
10228         * modules/fcntl (Depends-on): Add extensions.
10229         * m4/fcntl_h.m4 (gl_FCNTL_H): Add a comment.
10230
10231 2009-04-12  Ben Pfaff  <blp@gnu.org>
10232
10233         Make fcntl module detect O_NOATIME, O_NOFOLLOW on GNU/Linux.
10234         * m4/fcntl_h.m4 (gl_FCNTL_H): Require AC_USE_SYSTEM_EXTENSIONS.
10235
10236 2009-03-20  Ben Pfaff  <blp@gnu.org>
10237
10238         Make rename replace existing destinations on Windows.
10239         * m4/rename.m4: Add test for Mingw.
10240         * lib/rename.c: Add rename replacement that uses MoveFileEx with
10241         MOVEFILE_REPLACE_EXISTING to replace existing destination files.
10242         * doc/posix-functions/rename.texi: Document.
10243
10244 2009-04-10  Bruno Haible  <bruno@clisp.org>
10245
10246         New include file "iconveh.h".
10247         * lib/iconveh.h: New file, extracted from lib/striconveh.h.
10248         * lib/striconveh.h: Include it.
10249         (enum iconv_ilseq_handler): Remove definition.
10250         * lib/striconveha.h: Include <stddef.h> and iconveh.h instead of
10251         striconveh.h.
10252         * lib/striconveha.c: Include striconveh.h.
10253         * lib/uniconv.h: Include iconveh.h instead of striconveh.h.
10254         * modules/striconveh (Files): Add lib/iconveh.h.
10255         * modules/uniconv/base (Files): Add lib/iconveh.h. Remove
10256         lib/striconveh.h.
10257
10258 2009-04-10  Bruno Haible  <bruno@clisp.org>
10259
10260         * lib/uniconv.h: Update comment.
10261
10262 2009-04-10  Bruno Haible  <bruno@clisp.org>
10263
10264         * lib/unistr/u8-mbtouc-aux.c: Inside libunistring, define the function
10265         always.
10266         * lib/unistr/u8-mbtouc-unsafe-aux.c: Likewise.
10267         * lib/unistr/u16-mbtouc-aux.c: Likewise.
10268         * lib/unistr/u16-mbtouc-unsafe-aux.c: Likewise.
10269         * lib/unistr/u8-mbtouc.c: Inside libunistring, include
10270         "unistring-notinline.h", so that the function gets defined always.
10271         * lib/unistr/u8-mbtouc-unsafe.c: Likewise.
10272         * lib/unistr/u8-uctomb.c: Likewise.
10273         * lib/unistr/u16-mbtouc.c: Likewise.
10274         * lib/unistr/u16-mbtouc-unsafe.c: Likewise.
10275         * lib/unistr/u16-uctomb.c: Likewise.
10276         * lib/unistr/u32-mbtouc.c: Likewise.
10277         * lib/unistr/u32-mbtouc-unsafe.c: Likewise.
10278         * lib/unistr/u32-uctomb.c: Likewise.
10279
10280 2009-04-10  Bruno Haible  <bruno@clisp.org>
10281
10282         Mark 'utime' obsolete.
10283         * modules/utime (Status, Notice): New sections.
10284         Suggested by Jim Meyering.
10285
10286         Fix cross-compile guess for utime test.
10287         * m4/utime.m4 (AC_FUNC_UTIME_NULL): Add definition from newest unstable
10288         autoconf.
10289         * doc/posix-functions/utime.texi: Give more precisions.
10290         Reported by Jan <ipif@ymail.com>.
10291
10292 2009-04-09  Kamil Dudka  <kdudka@redhat.com>
10293
10294         filevercmp: correct today's change
10295         * lib/filevercmp.c: Also handle coreutils' test inputs.
10296         * tests/test-filevercmp.c: Add inputs from one of coreutils' test scripts.
10297
10298         Fix regression in 'filevercmp' module. Thanks Sven Joachim
10299         for reporting it.
10300         * lib/filevercmp.c: Special handle for "", "." and "..".
10301         * tests/test-filevercmp.c: Enlarge the set suite.
10302
10303 2009-04-07  Jim Meyering  <meyering@redhat.com>
10304
10305         useless-if-before-free: show how to remove braced useless free, too
10306         * build-aux/useless-if-before-free: still only in a comment, though.
10307
10308 2009-04-07  Reuben Thomas  <rrt@sc3d.org>
10309
10310         maint.mk: import changes to syntax-check macros from coreutils
10311         * top/maint.mk (_prohibit_regexp, _header_without_use): Define.
10312         Use them in the relevant macros.
10313
10314 2009-04-06  Bruno Haible  <bruno@clisp.org>
10315
10316         Fix unportable use of bit-fields.
10317         * lib/unicase/special-casing.h (struct special_casing_rule): Change the
10318         bit-field type from 'int' to 'signed int'. Otherwise Solaris cc,
10319         AIX xlc, and OSF/1 cc interpret it as 'unsigned int'.
10320
10321 2009-04-06  Bruno Haible  <bruno@clisp.org>
10322
10323         Avoid test failures on AIX and OSF/1.
10324         * tests/unicase/test-u8-casefold.c (check): Account for the possibility
10325         that malloc(0) = NULL.
10326         * tests/unicase/test-u8-tolower.c (check): Likewise.
10327         * tests/unicase/test-u8-totitle.c (check): Likewise.
10328         * tests/unicase/test-u8-toupper.c (check): Likewise.
10329         * tests/unicase/test-u16-casefold.c (check): Likewise.
10330         * tests/unicase/test-u16-tolower.c (check): Likewise.
10331         * tests/unicase/test-u16-totitle.c (check): Likewise.
10332         * tests/unicase/test-u16-toupper.c (check): Likewise.
10333         * tests/unicase/test-u32-casefold.c (check): Likewise.
10334         * tests/unicase/test-u32-tolower.c (check): Likewise.
10335         * tests/unicase/test-u32-totitle.c (check): Likewise.
10336         * tests/unicase/test-u32-toupper.c (check): Likewise.
10337         * tests/uninorm/test-u8-nfc.c (check): Likewise.
10338         * tests/uninorm/test-u8-nfd.c (check): Likewise.
10339         * tests/uninorm/test-u8-nfkc.c (check): Likewise.
10340         * tests/uninorm/test-u8-nfkd.c (check): Likewise.
10341         * tests/uninorm/test-u16-nfc.c (check): Likewise.
10342         * tests/uninorm/test-u16-nfd.c (check): Likewise.
10343         * tests/uninorm/test-u16-nfkc.c (check): Likewise.
10344         * tests/uninorm/test-u16-nfkd.c (check): Likewise.
10345         * tests/uninorm/test-u32-nfc.c (check): Likewise.
10346         * tests/uninorm/test-u32-nfd.c (check): Likewise.
10347         * tests/uninorm/test-u32-nfkc.c (check): Likewise.
10348         * tests/uninorm/test-u32-nfkd.c (check): Likewise.
10349
10350 2009-04-05  Bruno Haible  <bruno@clisp.org>
10351
10352         Work around an autoconf limitation.
10353         * gnulib-tool (func_emit_lib_Makefile_am): Omit the "Reproduce by"
10354         comment line if it would be longer than 3 KB.
10355
10356 2009-04-05  Bruno Haible  <bruno@clisp.org>
10357
10358         Avoid test failure with libiconv-1.13.
10359         * tests/test-striconveh.c (main): Allow result of libiconv 1.13 as one
10360         of the expected test results.
10361
10362 2009-04-05  Bruno Haible  <bruno@clisp.org>
10363
10364         * gnulib-tool (func_emit_lib_Makefile_am): Don't add the library to
10365         noinst_LTLIBRARIES if the Makefile.am in the same directory specifies
10366         that it should be installed.
10367
10368 2009-04-05  Bruno Haible  <bruno@clisp.org>
10369
10370         * gnulib-tool: New option --copy-file.
10371         (func_usage): Document it.
10372         (func_dest_tmpfilename): Moved out of func_import.
10373         (func_add_file, func_update_file): New functions, extracted from
10374         func_import.
10375         (func_import): Update.
10376
10377 2009-04-05  Karl Berry  <karl@gnu.org>
10378
10379         * README: prominently mention gnulib-tool.
10380         Rearrange sections so getting the code is near the top.
10381
10382 2009-04-05  Bruno Haible  <bruno@clisp.org>
10383
10384         * lib/unicase.h: Mention u*_cmp2.
10385         * lib/unicase/u-casecmp.h (FUNC): Invoke U_CMP2 instead of U_CMP.
10386         * lib/unicase/u8-casecmp.c: Use u8_cmp2 instead of u8_cmp.
10387         * lib/unicase/ulc-casecmp.c: Likewise.
10388         * lib/unicase/u16-casecmp.c: Use u16_cmp2 instead of u16_cmp.
10389         * lib/unicase/u32-casecmp.c: Use u32_cmp2 instead of u32_cmp.
10390         * modules/unicase/u8-casecmp (Depends-on): Add unistr/u8-cmp2, remove
10391         unistr/u8-cmp.
10392         * modules/unicase/ulc-casecmp (Depends-on): Likewise.
10393         * modules/unicase/u16-casecmp (Depends-on): Add unistr/u16-cmp2, remove
10394         unistr/u16-cmp.
10395         * modules/unicase/u32-casecmp (Depends-on): Add unistr/u32-cmp2, remove
10396         unistr/u32-cmp.
10397
10398         * lib/uninorm.h: Mention u*_cmp2.
10399         * lib/uninorm/u-normcmp.h (FUNC): Invoke U_CMP2 instead of U_CMP.
10400         * lib/uninorm/u8-normcmp.c: Use u8_cmp2 instead of u8_cmp.
10401         * lib/uninorm/u16-normcmp.c: Use u16_cmp2 instead of u16_cmp.
10402         * lib/uninorm/u32-normcmp.c: Use u32_cmp2 instead of u32_cmp.
10403         * modules/uninorm/u8-normcmp (Depends-on): Add unistr/u8-cmp2, remove
10404         unistr/u8-cmp.
10405         * modules/uninorm/u16-normcmp (Depends-on): Add unistr/u16-cmp2, remove
10406         unistr/u16-cmp.
10407         * modules/uninorm/u32-normcmp (Depends-on): Add unistr/u32-cmp2, remove
10408         unistr/u32-cmp.
10409
10410         New module 'unistr/u32-cmp2'.
10411         * lib/unistr/u32-cmp2.c: New file.
10412         * modules/unistr/u32-cmp2: New file.
10413
10414         New module 'unistr/u16-cmp2'.
10415         * lib/unistr/u16-cmp2.c: New file.
10416         * modules/unistr/u16-cmp2: New file.
10417
10418         New module 'unistr/u8-cmp2'.
10419         * lib/unistr.h (u8_cmp2, u16_cmp2, u32_cmp2): New declarations.
10420         * lib/unistr/u8-cmp2.c: New file.
10421         * lib/unistr/u-cmp2.h: New file.
10422         * modules/unistr/u8-cmp2: New file.
10423
10424 2009-04-05  Bruno Haible  <bruno@clisp.org>
10425
10426         * lib/unictype.h (uc_property_is_valid): New macro.
10427         * tests/unictype/test-pr_byname.c (main): Use it.
10428
10429         * lib/unistr.h: Doc fixes.
10430         * lib/uniconv.h: Doc fixes.
10431         * lib/unictype.h: Doc fixes.
10432
10433 2009-04-03  Paul Eggert  <eggert@cs.ucla.edu>
10434
10435         Port coreutils 7.2 to Solaris 8.
10436
10437         * modules/arpa_inet (arpa/inet.h): Depend on arpa_inet.in.h.
10438         * m4/inet_ntop.m4 (gl_INET_NTOP): Search for inet_ntop in -lnsl,
10439         for Solaris 8.  This is a bit of a hack, as it means it's the
10440         caller's responsibility to add -lnsl if needed, but most likely it
10441         won't be needed since only getaddrinfo uses this and getaddrinfo
10442         isn't needed on Solaris 8.
10443
10444         * modules/fnmatch (Depends-on): Add mbsrtowcs, to fix a porting
10445         problem to Solaris 8 encountered with coreutils 7.2, which
10446         resulted in a message "fnmatch.c:292: warning: passing argument 4
10447         of 'mbsrtowcs' from incompatible pointer type".  Also, add mbsinit
10448         at the suggestion of Bruno Haible, since fnmatch uses mbsinit.
10449
10450 2009-04-03  Simon Josefsson  <simon@josefsson.org>
10451
10452         * m4/ld-version-script.m4: Add FIXME comment.
10453
10454 2009-04-02  Simon Josefsson  <simon@josefsson.org>
10455
10456         * doc/ld-output-def.texi: Use DLL_VERSION instead of confusing
10457         SOVERSION variable.
10458
10459 2009-04-02  Bruno Haible  <bruno@clisp.org>
10460
10461         * Makefile (info, html, dvi, pdf): Combine the rules.
10462         Suggested by Jim Meyering.
10463
10464 2009-04-01  Bruno Haible  <bruno@clisp.org>
10465
10466         * Makefile (info, html, dvi, pdf): New targets.
10467         Reported by Reuben Thomas <rrt@sc3d.org>.
10468
10469 2009-04-01  Bruno Haible  <bruno@clisp.org>
10470
10471         * doc/gnulib-tool.texi (Invoking gnulib-tool): Document how gnulib-tool
10472         can be put into PATH.
10473         Reported by Reuben Thomas <rrt@sc3d.org>. Suggested by Karl Berry.
10474
10475 2009-04-01  Bruno Haible  <bruno@clisp.org>
10476
10477         * doc/lib-symbol-visibility.texi: Follow texinfo style conventions.
10478
10479 2009-04-01  Bruno Haible  <bruno@clisp.org>
10480
10481         Rename module 'visibility'.
10482         * modules/lib-symbol-visibility: Renamed from modules/visibility.
10483         * doc/lib-symbol-visibility.texi: Renamed from visibility.texi.
10484         * doc/gnulib.texi: Update.
10485         * MODULES.html.sh (Misc): Update.
10486         * NEWS: Mention the change.
10487
10488 2009-04-01  Simon Josefsson  <simon@josefsson.org>
10489
10490         * modules/lib-msvc-compat: New module.  Thanks to Bruno Haible
10491         <bruno@clisp.org>, Ralf Wildenhues <Ralf.Wildenhues@gmx.de>, and
10492         Eric Blake <ebb9@byu.net> for review.
10493         * MODULES.html.sh: Add lib-msvc-compat.
10494         * doc/gnulib.texi: Link to new section.
10495         * m4/ld-output-def.m4: New file.
10496         * doc/ld-output-def.texi: New file.
10497
10498 2009-04-01  Simon Josefsson  <simon@josefsson.org>
10499
10500         Rename ld-version-script to lib-symbol-versions.  Suggested by
10501         Bruno Haible <bruno@clisp.org>.
10502         * modules/ld-version-script: Renamed to lib-symbol-versions.
10503         * doc/ld-version-script.texi: Fix module name.
10504         * MODULES.html.sh: Add lib-symbol-versions.
10505
10506 2009-03-31  Simon Josefsson  <simon@josefsson.org>
10507
10508         * modules/u64-tests: New file.
10509         * tests/test-u64.c: New file.
10510
10511 2009-03-04  Simon Josefsson  <simon@josefsson.org>
10512
10513         * MODULES.html.sh: Mention u64.
10514         * modules/u64: New module.
10515         * modules/crypto/sha512: Depend on u64 module instead of providing
10516         u64.h.
10517
10518 2009-03-27  Eric Blake  <ebb9@byu.net>
10519
10520         test-strerror: make debugging EAI_SYSTEM easier
10521         * modules/getaddrinfo-tests (Depends-on): Add strerror.
10522         * test-getaddrinfo.c (simple) [ENABLE_DEBUGGING]: Report errno if
10523         failure was EAI_SYSTEM.
10524
10525 2009-03-25  Bruno Haible  <bruno@clisp.org>
10526
10527         Fix a problem with --enable-relocatable on Solaris 7.
10528         * modules/relocatable-prog-wrapper (Depends-on): Add environ. Needed
10529         since 2008-02-24.
10530
10531 2009-03-25  Eric Blake  <ebb9@byu.net>
10532
10533         test-sockets: avoid gcc warning
10534         * tests/test-sockets.c (main): Silence compiler warning.
10535
10536 2009-03-25  Paul Eggert  <eggert@cs.ucla.edu>
10537
10538         New modules nproc, pthread, contributed by Glen Lenker.
10539
10540         * MODULES.html.sh: Add pthread, nproc.
10541         * lib/nproc.c: New file.
10542         * lib/nproc.h: New file.
10543         * lib/pthread.in.h: New file.
10544         * m4/pthread.m4: New file.
10545         * modules/nproc: New file.
10546         * modules/pthread: New file.
10547
10548 2009-03-24  Simon Josefsson  <simon@josefsson.org>
10549
10550         * modules/unicase/locale-language-tests (test_locale_language_LDADD):
10551         New variable.
10552
10553 2009-03-24  Kamil Dudka  <kdudka@redhat.com>
10554
10555         filevercmp: handle simple~ and numbered.~3~ backup suffixes
10556         * lib/filevercmp.c: Handle simple~ and numbered.~3~ backup suffixes.
10557         * tests/test-filevercmp.c: Add tests for backup suffixes.
10558
10559 2009-03-24  Simon Josefsson  <simon@josefsson.org>
10560
10561         * modules/stdlib (Depends-on): Add stdint, needed when defining
10562         struct random_data on, for example, HP-UX 10.20.  Reported by
10563         Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
10564
10565 2009-03-24  Simon Josefsson  <simon@josefsson.org>
10566
10567         * lib/readline.c (readline): Call fflush on stdout after printing
10568         prompt.
10569
10570 2009-03-20  Bruno Haible  <bruno@clisp.org>
10571
10572         Remove dependency from 'close' module to -lws2_32 on native Windows.
10573         * lib/close-hook.h: New file.
10574         * lib/close-hook.c: New file.
10575         * lib/close.c: Include close-hook.h. Don't include <sys/socket.h>,
10576         w32sock.h.
10577         (_gl_close_fd_maybe_socket): Remove function.
10578         (rpl_close): Invoke execute_all_close_hooks instead of
10579         _gl_close_fd_maybe_socket.
10580         * lib/sockets.c: Include close-hook.h, w32sock.h.
10581         (close_fd_maybe_socket): New function, essentially from lib/close.c.
10582         (close_sockets_hook): New variable.
10583         (gl_sockets_startup): Register close_fd_maybe_socket as a hook.
10584         (gl_sockets_cleanup): Unregister it.
10585         * lib/unistd.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET): Remove macro.
10586         * m4/close.m4 (gl_REPLACE_CLOSE): Undo 2009-02-05 change.
10587         * modules/close-hook: New file.
10588         * modules/close (Files): Remove lib/w32sock.h.
10589         (Depends-on): Add close-hook.
10590         (Link): Remove section.
10591         * modules/sockets (Files): Add lib/w32sock.h.
10592         (Depends-on): Add close-hook.
10593         * modules/sys_socket (configure.ac): Remove gl_MODULE_INDICATOR
10594         invocation.
10595         * NEWS: Mention that LIB_CLOSE is gone.
10596
10597 2009-03-23  Eric Blake  <ebb9@byu.net>
10598
10599         signal-tests: test previous patch
10600         * tests/test-signal.c: New file.
10601         * modules/signal-tests: Likewise.
10602
10603         signal.h: always support 'volatile sig_atomic_t'
10604         * m4/signal_h.m4 (gl_SIGNAL_H): Check for AIX limitation.
10605         (gl_SIGNAL_H_DEFAULTS): Add a default.
10606         * modules/signal (Makefile.am): Substitute if needed.
10607         * lib/signal.in.h (sig_atomic_t): Redefine if needed, so that
10608         users can blindly add volatile.
10609         * doc/posix-headers/signal.texi (signal.h): Document it.
10610         Reported by Matthew Woehlke.
10611
10612 2009-03-23  Jim Meyering  <meyering@redhat.com>
10613
10614         pathmax: PATH_MAX: use pathconf only when available
10615         * lib/pathmax.h (PATH_MAX): Select the pathconf-using definition
10616         only if HAVE_PATHCONF is defined.  Patch by Sylvain Beucler.
10617         * m4/pathmax.m4 (gl_PATHMAX): Check for pathconf.
10618         This avoids a link failure in a PSP cross-compilation environment
10619         described in http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/17048
10620
10621         * lib/vasnprintf.c (divide): Fix typo in comment.
10622
10623 2009-03-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10624
10625         * gnulib-tool (func_filter_filelist): Fix comment.
10626
10627 2009-03-20  Bruno Haible  <bruno@clisp.org>
10628
10629         Make sockets.h self-contained.
10630         * lib/sockets.c: Include sockets.h first.
10631         * lib/sockets.h: Include <sys/socket.h> before using the SOCKET type.
10632
10633 2009-03-19  Eric Blake  <ebb9@byu.net>
10634
10635         doc: mention more functions added in cygwin 1.7.0
10636         * doc/posix-functions/log2.texi: Mention recent cygwin 1.7.0
10637         addition.
10638         * doc/posix-functions/log2f.texi: Likewise.
10639
10640 2009-03-19  Jim Meyering  <meyering@redhat.com>
10641
10642         fsusage: avoid syntax error due to statement-before-declaration
10643         * lib/fsusage.c (get_fs_usage): Put warning-avoidance statement
10644         after all declarations.  Reported by Matthew Woehlke in
10645         http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/16231
10646
10647 2009-03-18  Eric Blake  <ebb9@byu.net>
10648
10649         build-aux/compile: sync from automake
10650         * build-aux/compile: New file, from automake.
10651         * config/srclist.txt: Mention build-aux/compile.
10652
10653 2009-03-17  Bruno Haible  <bruno@clisp.org>
10654
10655         * lib/git-merge-changelog.c: Fix typo in comment.
10656         Reported by Reuben Thomas <rrt@sc3d.org>.
10657
10658 2009-03-17  Reuben Thomas  <rrt@sc3d.org>
10659
10660         * m4/regex.m4: update and improve help for
10661         --without-included-regex.
10662
10663 2009-03-17  Simon Josefsson  <simon@josefsson.org>
10664
10665         * modules/isnanl-nolibm-tests (Files): Add tests/nan.h to avoid
10666         failure on missing include files.
10667
10668 2009-03-17  Eric Blake  <ebb9@byu.net>
10669
10670         doc: mention more functions added in cygwin 1.7.0
10671         * doc/posix-functions/fwprintf.texi: Mention recent cygwin 1.7.0
10672         addition.
10673         * doc/posix-functions/fwscanf.texi: Likewise.
10674         * doc/posix-functions/swprintf.texi: Likewise.
10675         * doc/posix-functions/swscanf.texi: Likewise.
10676         * doc/posix-functions/vfwprintf.texi: Likewise.
10677         * doc/posix-functions/vfwscanf.texi: Likewise.
10678         * doc/posix-functions/vswprintf.texi: Likewise.
10679         * doc/posix-functions/vswscanf.texi: Likewise.
10680         * doc/posix-functions/vwprintf.texi: Likewise.
10681         * doc/posix-functions/vwscanf.texi: Likewise.
10682         * doc/posix-functions/wcscasecmp.texi: Likewise.
10683         * doc/posix-functions/wcsdup.texi: Likewise.
10684         * doc/posix-functions/wcsftime.texi: Likewise.
10685         * doc/posix-functions/wcsncasecmp.texi: Likewise.
10686         * doc/posix-functions/wprintf.texi: Likewise.
10687         * doc/posix-functions/wscanf.texi: Likewise.
10688         * doc/glibc-functions/gethostbyname2.texi: Likewise.
10689
10690 2009-03-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10691
10692         maint.mk: really add $(AM_MAKEFLAGS)
10693         * top/maint.mk (init-coverage, build-coverage): `$(AM_MAKEFLAGS)'
10694         was inadvertently omitted in the last commit.
10695         Spotted by Bruno Haible.
10696
10697         maint.mk: use $(MAKE) $(AM_MAKEFLAGS) not make
10698         * top/maint.mk (init-coverage, build-coverage): Use `$(MAKE)
10699         $(AM_MAKEFLAGS)' rather than plain `make'.
10700
10701         gnulib-tool: execute $MAKE not make
10702         * gnulib-tool: Default $MAKE to 'make'.
10703         (func_create_testdir, func_create_megatestdir): Use $MAKE rather
10704         than make.  Initialize $MAKE in the do-autobuild script.
10705
10706         gnulib-tool: use $MAKE not make in generated files
10707         * gnulib-tool (func_create_megatestdir): Use $MAKE rather than
10708         make, in generated files.  Initialize $MAKE in the do-autobuild
10709         script.
10710
10711         * top/GNUmakefile (_have-git-version-gen): Fix typo.
10712
10713         GNUmakefile: disable parallelism only for multiple, recursive targets
10714         * top/GNUmakefile (ALL_RECURSIVE_TARGETS): New macro; allow user
10715         additions in the Makefile.
10716         (AM_RECURSIVE_TARGETS): New macro, override only if not provided
10717         by Automake.
10718         (.NOTPARALLEL): Only disable parallel builds if multiple targets
10719         are listed on the command line and at least one of them is
10720         listed in $(ALL_RECURSIVE_TARGETS).
10721
10722 2009-03-14  Bruno Haible  <bruno@clisp.org>
10723
10724         * modules/unilbrk/u8-possible-linebreaks (Depends-on): Replace
10725         utf8-ucs4-unsafe with unistr/u8-mbtouc-unsafe.
10726         * modules/unilbrk/u8-width-linebreaks (Depends-on): Likewise.
10727         * modules/unilbrk/u16-possible-linebreaks (Depends-on): Replace
10728         utf16-ucs4-unsafe with unistr/u16-mbtouc-unsafe.
10729         * modules/unilbrk/u16-width-linebreaks (Depends-on): Likewise.
10730         * modules/unistr/u8-chr (Depends-on): Replace ucs4-utf8 with
10731         unistr/u8-uctomb.
10732         * modules/unistr/u8-strchr (Depends-on): Likewise.
10733         * modules/unistr/u8-strrchr (Depends-on): Likewise.
10734         * modules/unistr/u16-chr (Depends-on): Replace ucs4-utf16 with
10735         unistr/u16-uctomb.
10736         * modules/unistr/u16-strchr (Depends-on): Likewise.
10737         * modules/unistr/u16-strrchr (Depends-on): Likewise.
10738
10739 2009-03-12  Bruno Haible  <bruno@clisp.org>
10740
10741         Work around select() bug on Interix 3.5.
10742         * lib/sys_select.in.h (select): Also replace if REPLACE_SELECT is 1.
10743         * lib/select.c (rpl_select): Add an implementation for Unix platforms.
10744         * m4/select.m4: New file.
10745         * m4/sys_select_h.m4 (gl_SYS_SELECT_H_DEFAULTS): Initialize REPLACE_SELECT.
10746         * modules/sys_select (Makefile.am): Substitute REPLACE_SELECT.
10747         * modules/select (Files): Add m4/select.m4.
10748         (configure.ac): Move conditional to m4/select.m4. Invoke gl_FUNC_SELECT.
10749         * modules/nanosleep (Depends-on): Add select.
10750         * modules/poll (Depends-on): Likewise.
10751         * doc/posix-functions/select.texi: Mention the Interix bug.
10752         Reported by Markus Duft <mduft@gentoo.org>.
10753
10754         * lib/select.c: Renamed from lib/winsock-select.c.
10755         * modules/select (Files): Add lib/select.c, remove
10756         lib/winsock-select.c.
10757         (configure.ac): Update.
10758
10759 2009-03-12  Jim Meyering  <meyering@redhat.com>
10760
10761         avoid gcc warnings about unused macro definitions
10762         * lib/readtokens.c (STREQ): Remove unused definition.
10763         * lib/xmalloc.c (SIZE_MAX): Likewise.
10764         * lib/openat-die.c (N_): Likewise.
10765         * lib/mountlist.c (SIZE_MAX): Remove definition.
10766         Instead, include <stdint.h>.
10767         * lib/readutmp.c: Likewise.
10768         * modules/readutmp (Depends-on): Add stdint.
10769         * modules/mountlist (Depends-on): Add stdint.
10770         * lib/userspec.c (ISDIGIT): Move definition into #if block where used.
10771
10772 2009-03-10  Bruno Haible  <bruno@clisp.org>
10773
10774         Tests for module 'mbmemcasecoll'.
10775         * modules/mbmemcasecoll-tests: New file.
10776         * tests/test-mbmemcasecoll1.sh: New file.
10777         * tests/test-mbmemcasecoll2.sh: New file.
10778         * tests/test-mbmemcasecoll3.sh: New file.
10779         * tests/test-mbmemcasecoll.c: New file.
10780
10781         New module 'mbmemcasecoll'.
10782         * lib/mbmemcasecoll.h: New file.
10783         * lib/mbmemcasecoll.c: New file.
10784         * modules/mbmemcasecoll: New file.
10785
10786         * tests/test-mbmemcasecmp.h: New file, extracted from
10787         tests/test-mbmemcasecmp.c.
10788         * tests/test-mbmemcasecmp.c: Include test-mbmemcasecmp.h.
10789         (test_ascii, test_iso_8859_1, test_utf_8): Remove functions.
10790         (main): Update.
10791         * modules/mbmemcasecmp-tests (Files): Add tests/test-mbmemcasecmp.h.
10792
10793 2009-03-09  Bruno Haible  <bruno@clisp.org>
10794
10795         Tests for module 'mbmemcasecmp'.
10796         * modules/mbmemcasecmp-tests: New file.
10797         * tests/test-mbmemcasecmp1.sh: New file.
10798         * tests/test-mbmemcasecmp2.sh: New file.
10799         * tests/test-mbmemcasecmp3.sh: New file.
10800         * tests/test-mbmemcasecmp.c: New file.
10801
10802         New module 'mbmemcasecmp'.
10803         * lib/mbmemcasecmp.h: New file.
10804         * lib/mbmemcasecmp.c: New file.
10805         * modules/mbmemcasecmp: New file.
10806
10807 2009-03-09  Bruno Haible  <bruno@clisp.org>
10808
10809         Tests for module 'unicase/ulc-casecoll'.
10810         * modules/unicase/ulc-casecoll-tests: New file.
10811         * tests/unicase/test-ulc-casecoll1.sh: New file.
10812         * tests/unicase/test-ulc-casecoll2.sh: New file.
10813         * tests/unicase/test-ulc-casecoll.c: New file.
10814
10815         New module 'unicase/ulc-casecoll'.
10816         * lib/unicase.h (ulc_casecoll): New declaration.
10817         * lib/unicase/ulc-casecoll.c: New file.
10818         * modules/unicase/ulc-casecoll: New file.
10819
10820         New module 'unicase/ulc-casexfrm'.
10821         * lib/unicase.h (ulc_casexfrm): New declaration.
10822         * lib/unicase/ulc-casexfrm.c: New file.
10823         * modules/unicase/ulc-casexfrm: New file.
10824
10825 2009-03-09  Bruno Haible  <bruno@clisp.org>
10826
10827         Followup to 2008-12-22 commit: Remove unnecessary AC_FUNC_MBRTOWC
10828         invocations.
10829
10830         * m4/mbscasecmp.m4: Remove file.
10831         * modules/mbscasecmp (Files): Remove it and m4/mbrtowc.m4
10832         (configure.ac): Remove gl_FUNC_MBSCASECMP invocation.
10833
10834         * m4/mbscasestr.m4: Remove file.
10835         * modules/mbscasestr (Files): Remove it and m4/mbrtowc.m4
10836         (configure.ac): Remove gl_FUNC_MBSCASESTR invocation.
10837
10838         * m4/mbschr.m4: Remove file.
10839         * modules/mbschr (Files): Remove it and m4/mbrtowc.m4
10840         (configure.ac): Remove gl_FUNC_MBSCHR invocation.
10841
10842         * m4/mbscspn.m4: Remove file.
10843         * modules/mbscspn (Files): Remove it and m4/mbrtowc.m4
10844         (configure.ac): Remove gl_FUNC_MBSCSPN invocation.
10845
10846         * m4/mbslen.m4: Remove file.
10847         * modules/mbslen (Files): Remove it and m4/mbrtowc.m4
10848         (configure.ac): Remove gl_FUNC_MBSLEN invocation.
10849
10850         * m4/mbsncasecmp.m4: Remove file.
10851         * modules/mbsncasecmp (Files): Remove it and m4/mbrtowc.m4
10852         (configure.ac): Remove gl_FUNC_MBSNCASECMP invocation.
10853
10854         * m4/mbsnlen.m4: Remove file.
10855         * modules/mbsnlen (Files): Remove it and m4/mbrtowc.m4
10856         (configure.ac): Remove gl_FUNC_MBSNLEN invocation.
10857
10858         * m4/mbspbrk.m4: Remove file.
10859         * modules/mbspbrk (Files): Remove it and m4/mbrtowc.m4
10860         (configure.ac): Remove gl_FUNC_MBSPBRK invocation.
10861
10862         * m4/mbspcasecmp.m4: Remove file.
10863         * modules/mbspcasecmp (Files): Remove it and m4/mbrtowc.m4
10864         (configure.ac): Remove gl_FUNC_MBSPCASECMP invocation.
10865
10866         * m4/mbsrchr.m4: Remove file.
10867         * modules/mbsrchr (Files): Remove it and m4/mbrtowc.m4
10868         (configure.ac): Remove gl_FUNC_MBSRCHR invocation.
10869
10870         * m4/mbssep.m4: Remove file.
10871         * modules/mbssep (Files): Remove it and m4/mbrtowc.m4
10872         (configure.ac): Remove gl_FUNC_MBSSEP invocation.
10873
10874         * m4/mbsspn.m4: Remove file.
10875         * modules/mbsspn (Files): Remove it and m4/mbrtowc.m4
10876         (configure.ac): Remove gl_FUNC_MBSSPN invocation.
10877
10878         * m4/mbsstr.m4: Remove file.
10879         * modules/mbsstr (Files): Remove it and m4/mbrtowc.m4
10880         (configure.ac): Remove gl_FUNC_MBSSTR invocation.
10881
10882         * m4/mbstok_r.m4: Remove file.
10883         * modules/mbstok_r (Files): Remove it and m4/mbrtowc.m4
10884         (configure.ac): Remove gl_FUNC_MBSTOK_R invocation.
10885
10886         * m4/mbswidth.m4 (gl_MBSWIDTH): Remove AC_FUNC_MBRTOWC invocation.
10887
10888         * m4/quotearg.m4 (gl_QUOTEARG): Remove mbsinit test and
10889         AC_TYPE_MBSTATE_T, AC_FUNC_MBRTOWC invocations.
10890
10891         * modules/trim (configure.ac): Remove AC_FUNC_MBRTOWC invocation.
10892
10893 2009-03-08  Bruno Haible  <bruno@clisp.org>
10894
10895         Tests for module 'unicase/ulc-casecmp'.
10896         * modules/unicase/ulc-casecmp-tests: New file.
10897         * tests/unicase/test-ulc-casecmp1.sh: New file.
10898         * tests/unicase/test-ulc-casecmp2.sh: New file.
10899         * tests/unicase/test-ulc-casecmp.c: New file.
10900
10901         New module 'unicase/ulc-casecmp'.
10902         * lib/unicase.h (ulc_casecmp): New declaration.
10903         * lib/unicase/ulc-casecmp.c: New file.
10904         * lib/unicase/u-casecmp.h (FUNC): Change argument types to
10905         'const SRC_UNIT *'.
10906         * lib/unicase/u8-casecmp.c (SRC_UNIT): Define like UNIT.
10907         * lib/unicase/u16-casecmp.c (SRC_UNIT): Likewise.
10908         * lib/unicase/u32-casecmp.c (SRC_UNIT): Likewise.
10909         * modules/unicase/ulc-casecmp: New file.
10910
10911         Tests for module 'unicase/u32-is-cased'.
10912         * modules/unicase/u32-is-cased-tests: New file.
10913         * tests/unicase/test-u32-is-cased.c: New file.
10914
10915         Tests for module 'unicase/u16-is-cased'.
10916         * modules/unicase/u16-is-cased-tests: New file.
10917         * tests/unicase/test-u16-is-cased.c: New file.
10918
10919         Tests for module 'unicase/u8-is-cased'.
10920         * modules/unicase/u8-is-cased-tests: New file.
10921         * tests/unicase/test-u8-is-cased.c: New file.
10922         * tests/unicase/test-is-cased.h: New file.
10923
10924         New module 'unicase/u32-is-cased'.
10925         * lib/unicase/u32-is-cased.c: New file.
10926         * modules/unicase/u32-is-cased: New file.
10927
10928         New module 'unicase/u16-is-cased'.
10929         * lib/unicase/u16-is-cased.c: New file.
10930         * modules/unicase/u16-is-cased: New file.
10931
10932         New module 'unicase/u8-is-cased'.
10933         * lib/unicase/u8-is-cased.c: New file.
10934         * lib/unicase/u-is-cased.h: New file.
10935         * modules/unicase/u8-is-cased: New file.
10936
10937         Tests for module 'unicase/u32-is-casefolded'.
10938         * modules/unicase/u32-is-casefolded-tests: New file.
10939         * tests/unicase/test-u32-is-casefolded.c: New file.
10940
10941         Tests for module 'unicase/u16-is-casefolded'.
10942         * modules/unicase/u16-is-casefolded-tests: New file.
10943         * tests/unicase/test-u16-is-casefolded.c: New file.
10944
10945         Tests for module 'unicase/u8-is-casefolded'.
10946         * modules/unicase/u8-is-casefolded-tests: New file.
10947         * tests/unicase/test-u8-is-casefolded.c: New file.
10948         * tests/unicase/test-is-casefolded.h: New file.
10949
10950         New module 'unicase/u32-is-casefolded'.
10951         * lib/unicase/u32-is-casefolded.c: New file.
10952         * modules/unicase/u32-is-casefolded: New file.
10953
10954         New module 'unicase/u16-is-casefolded'.
10955         * lib/unicase/u16-is-casefolded.c: New file.
10956         * modules/unicase/u16-is-casefolded: New file.
10957
10958         New module 'unicase/u8-is-casefolded'.
10959         * lib/unicase/u8-is-casefolded.c: New file.
10960         * modules/unicase/u8-is-casefolded: New file.
10961
10962         Tests for module 'unicase/u32-is-titlecase'.
10963         * modules/unicase/u32-is-titlecase-tests: New file.
10964         * tests/unicase/test-u32-is-titlecase.c: New file.
10965
10966         Tests for module 'unicase/u16-is-titlecase'.
10967         * modules/unicase/u16-is-titlecase-tests: New file.
10968         * tests/unicase/test-u16-is-titlecase.c: New file.
10969
10970         Tests for module 'unicase/u8-is-titlecase'.
10971         * modules/unicase/u8-is-titlecase-tests: New file.
10972         * tests/unicase/test-u8-is-titlecase.c: New file.
10973         * tests/unicase/test-is-titlecase.h: New file.
10974
10975         New module 'unicase/u32-is-titlecase'.
10976         * lib/unicase/u32-is-titlecase.c: New file.
10977         * modules/unicase/u32-is-titlecase: New file.
10978
10979         New module 'unicase/u16-is-titlecase'.
10980         * lib/unicase/u16-is-titlecase.c: New file.
10981         * modules/unicase/u16-is-titlecase: New file.
10982
10983         New module 'unicase/u8-is-titlecase'.
10984         * lib/unicase/u8-is-titlecase.c: New file.
10985         * modules/unicase/u8-is-titlecase: New file.
10986
10987         Tests for module 'unicase/u32-is-lowercase'.
10988         * modules/unicase/u32-is-lowercase-tests: New file.
10989         * tests/unicase/test-u32-is-lowercase.c: New file.
10990
10991         Tests for module 'unicase/u16-is-lowercase'.
10992         * modules/unicase/u16-is-lowercase-tests: New file.
10993         * tests/unicase/test-u16-is-lowercase.c: New file.
10994
10995         Tests for module 'unicase/u8-is-lowercase'.
10996         * modules/unicase/u8-is-lowercase-tests: New file.
10997         * tests/unicase/test-u8-is-lowercase.c: New file.
10998         * tests/unicase/test-is-lowercase.h: New file.
10999
11000         New module 'unicase/u32-is-lowercase'.
11001         * lib/unicase/u32-is-lowercase.c: New file.
11002         * modules/unicase/u32-is-lowercase: New file.
11003
11004         New module 'unicase/u16-is-lowercase'.
11005         * lib/unicase/u16-is-lowercase.c: New file.
11006         * modules/unicase/u16-is-lowercase: New file.
11007
11008         New module 'unicase/u8-is-lowercase'.
11009         * lib/unicase/u8-is-lowercase.c: New file.
11010         * modules/unicase/u8-is-lowercase: New file.
11011
11012         Tests for module 'unicase/u32-is-uppercase'.
11013         * modules/unicase/u32-is-uppercase-tests: New file.
11014         * tests/unicase/test-u32-is-uppercase.c: New file.
11015
11016         Tests for module 'unicase/u16-is-uppercase'.
11017         * modules/unicase/u16-is-uppercase-tests: New file.
11018         * tests/unicase/test-u16-is-uppercase.c: New file.
11019
11020         Tests for module 'unicase/u8-is-uppercase'.
11021         * modules/unicase/u8-is-uppercase-tests: New file.
11022         * tests/unicase/test-u8-is-uppercase.c: New file.
11023         * tests/unicase/test-is-uppercase.h: New file.
11024
11025         New module 'unicase/u32-is-uppercase'.
11026         * lib/unicase/u32-is-uppercase.c: New file.
11027         * modules/unicase/u32-is-uppercase: New file.
11028
11029         New module 'unicase/u16-is-uppercase'.
11030         * lib/unicase/u16-is-uppercase.c: New file.
11031         * modules/unicase/u16-is-uppercase: New file.
11032
11033         New module 'unicase/u8-is-uppercase'.
11034         * lib/unicase/u8-is-uppercase.c: New file.
11035         * modules/unicase/u8-is-uppercase: New file.
11036
11037         New module 'unicase/u32-is-invariant'.
11038         * lib/unicase/u32-is-invariant.c: New file.
11039         * modules/unicase/u32-is-invariant: New file.
11040
11041         New module 'unicase/u16-is-invariant'.
11042         * lib/unicase/u16-is-invariant.c: New file.
11043         * modules/unicase/u16-is-invariant: New file.
11044
11045         New module 'unicase/u8-is-invariant'.
11046         * lib/unicase/u8-is-invariant.c: New file.
11047         * lib/unicase/invariant.h: New file.
11048         * lib/unicase/u-is-invariant.h: New file.
11049         * modules/unicase/u8-is-invariant: New file.
11050
11051         Tests for module 'unicase/u32-casecoll'.
11052         * modules/unicase/u32-casecoll-tests: New file.
11053         * tests/unicase/test-u32-casecoll.c: New file.
11054
11055         Tests for module 'unicase/u16-casecoll'.
11056         * modules/unicase/u16-casecoll-tests: New file.
11057         * tests/unicase/test-u16-casecoll.c: New file.
11058
11059         Tests for module 'unicase/u8-casecoll'.
11060         * modules/unicase/u8-casecoll-tests: New file.
11061         * tests/unicase/test-u8-casecoll.c: New file.
11062
11063         New module 'unicase/u32-casecoll'.
11064         * lib/unicase/u32-casecoll.c: New file.
11065         * modules/unicase/u32-casecoll: New file.
11066
11067         New module 'unicase/u16-casecoll'.
11068         * lib/unicase/u16-casecoll.c: New file.
11069         * modules/unicase/u16-casecoll: New file.
11070
11071         New module 'unicase/u8-casecoll'.
11072         * lib/unicase/u8-casecoll.c: New file.
11073         * lib/unicase/u-casecoll.h: New file.
11074         * modules/unicase/u8-casecoll: New file.
11075
11076         New module 'unicase/u32-casexfrm'.
11077         * lib/unicase/u32-casexfrm.c: New file.
11078         * modules/unicase/u32-casexfrm: New file.
11079
11080         New module 'unicase/u16-casexfrm'.
11081         * lib/unicase/u16-casexfrm.c: New file.
11082         * modules/unicase/u16-casexfrm: New file.
11083
11084         New module 'unicase/u8-casexfrm'.
11085         * lib/unicase/u8-casexfrm.c: New file.
11086         * lib/unicase/u-casexfrm.h: New file.
11087         * modules/unicase/u8-casexfrm: New file.
11088
11089         Tests for module 'unicase/u32-casecmp'.
11090         * modules/unicase/u32-casecmp-tests: New file.
11091         * tests/unicase/test-u32-casecmp.c: New file.
11092
11093         Tests for module 'unicase/u16-casecmp'.
11094         * modules/unicase/u16-casecmp-tests: New file.
11095         * tests/unicase/test-u16-casecmp.c: New file.
11096
11097         Tests for module 'unicase/u8-casecmp'.
11098         * modules/unicase/u8-casecmp-tests: New file.
11099         * tests/unicase/test-u8-casecmp.c: New file.
11100         * tests/unicase/test-casecmp.h: New file.
11101
11102         New module 'unicase/u32-casecmp'.
11103         * lib/unicase/u32-casecmp.c: New file.
11104         * modules/unicase/u32-casecmp: New file.
11105
11106         New module 'unicase/u16-casecmp'.
11107         * lib/unicase/u16-casecmp.c: New file.
11108         * modules/unicase/u16-casecmp: New file.
11109
11110         New module 'unicase/u8-casecmp'.
11111         * lib/unicase/u8-casecmp.c: New file.
11112         * lib/unicase/u-casecmp.h: New file.
11113         * modules/unicase/u8-casecmp: New file.
11114
11115         Tests for module 'unicase/u32-casefold'.
11116         * modules/unicase/u32-casefold-tests: New file.
11117         * tests/unicase/test-u32-casefold.c: New file.
11118
11119         Tests for module 'unicase/u16-casefold'.
11120         * modules/unicase/u16-casefold-tests: New file.
11121         * tests/unicase/test-u16-casefold.c: New file.
11122
11123         Tests for module 'unicase/u8-casefold'.
11124         * modules/unicase/u8-casefold-tests: New file.
11125         * tests/unicase/test-u8-casefold.c: New file.
11126
11127         New module 'unicase/u32-casefold'.
11128         * lib/unicase/u32-casefold.c: New file.
11129         * modules/unicase/u32-casefold: New file.
11130
11131         New module 'unicase/u16-casefold'.
11132         * lib/unicase/u16-casefold.c: New file.
11133         * modules/unicase/u16-casefold: New file.
11134
11135         New module 'unicase/u8-casefold'.
11136         * lib/unicase/u8-casefold.c: New file.
11137         * lib/unicase/u-casefold.h: New file.
11138         * modules/unicase/u8-casefold: New file.
11139
11140         New module 'unicase/tocasefold'.
11141         * lib/unicase/casefold.h: New file.
11142         * lib/unicase/tocasefold.c: New file.
11143         * lib/unicase/tocasefold.h: New file, generated by gen-uni-tables.c.
11144         * modules/unicase/tocasefold: New file.
11145
11146         Tests for module 'unicase/u32-totitle'.
11147         * modules/unicase/u32-totitle-tests: New file.
11148         * tests/unicase/test-u32-totitle.c: New file.
11149
11150         Tests for module 'unicase/u16-totitle'.
11151         * modules/unicase/u16-totitle-tests: New file.
11152         * tests/unicase/test-u16-totitle.c: New file.
11153
11154         Tests for module 'unicase/u8-totitle'.
11155         * modules/unicase/u8-totitle-tests: New file.
11156         * tests/unicase/test-u8-totitle.c: New file.
11157
11158         New module 'unicase/u32-totitle'.
11159         * lib/unicase/u32-totitle.c: New file.
11160         * modules/unicase/u32-totitle: New file.
11161
11162         New module 'unicase/u16-totitle'.
11163         * lib/unicase/u16-totitle.c: New file.
11164         * modules/unicase/u16-totitle: New file.
11165
11166         New module 'unicase/u8-totitle'.
11167         * lib/unicase/u8-totitle.c: New file.
11168         * lib/unicase/u-totitle.h: New file.
11169         * modules/unicase/u8-totitle: New file.
11170
11171         Tests for module 'unicase/u32-tolower'.
11172         * modules/unicase/u32-tolower-tests: New file.
11173         * tests/unicase/test-u32-tolower.c: New file.
11174
11175         Tests for module 'unicase/u16-tolower'.
11176         * modules/unicase/u16-tolower-tests: New file.
11177         * tests/unicase/test-u16-tolower.c: New file.
11178
11179         Tests for module 'unicase/u8-tolower'.
11180         * modules/unicase/u8-tolower-tests: New file.
11181         * tests/unicase/test-u8-tolower.c: New file.
11182
11183         New module 'unicase/u32-tolower'.
11184         * lib/unicase/u32-tolower.c: New file.
11185         * modules/unicase/u32-tolower: New file.
11186
11187         New module 'unicase/u16-tolower'.
11188         * lib/unicase/u16-tolower.c: New file.
11189         * modules/unicase/u16-tolower: New file.
11190
11191         New module 'unicase/u8-tolower'.
11192         * lib/unicase/u8-tolower.c: New file.
11193         * modules/unicase/u8-tolower: New file.
11194
11195         Tests for module 'unicase/u32-toupper'.
11196         * modules/unicase/u32-toupper-tests: New file.
11197         * tests/unicase/test-u32-toupper.c: New file.
11198
11199         Tests for module 'unicase/u16-toupper'.
11200         * modules/unicase/u16-toupper-tests: New file.
11201         * tests/unicase/test-u16-toupper.c: New file.
11202
11203         Tests for module 'unicase/u8-toupper'.
11204         * modules/unicase/u8-toupper-tests: New file.
11205         * tests/unicase/test-u8-toupper.c: New file.
11206
11207         New module 'unicase/u32-toupper'.
11208         * lib/unicase/u32-toupper.c: New file.
11209         * modules/unicase/u32-toupper: New file.
11210
11211         New module 'unicase/u16-toupper'.
11212         * lib/unicase/u16-toupper.c: New file.
11213         * modules/unicase/u16-toupper: New file.
11214
11215         New module 'unicase/u8-toupper'.
11216         * lib/unicase/u8-toupper.c: New file.
11217         * modules/unicase/u8-toupper: New file.
11218
11219         New module 'unicase/u32-casemap'.
11220         * lib/unicase/u32-casemap.c: New file.
11221         * modules/unicase/u32-casemap: New file.
11222
11223         New module 'unicase/u16-casemap'.
11224         * lib/unicase/u16-casemap.c: New file.
11225         * modules/unicase/u16-casemap: New file.
11226
11227         New module 'unicase/u8-casemap'.
11228         * lib/unicase/unicasemap.h: New file.
11229         * lib/unicase/u8-casemap.c: New file.
11230         * lib/unicase/u-casemap.h: New file.
11231         * modules/unicase/u8-casemap: New file.
11232
11233         New module 'unicase/special-casing'.
11234         * lib/unicase/special-casing.h: New file.
11235         * lib/unicase/special-casing.c: New file.
11236         * lib/unicase/special-casing-table.gperf: New file, generated by
11237         gen-uni-tables.c.
11238         * modules/unicase/special-casing: New file.
11239
11240         Tests for module 'unicase/locale-language'.
11241         * modules/unicase/locale-language-tests: New file.
11242         * tests/unicase/test-locale-language.sh: New file.
11243         * tests/unicase/test-locale-language.c: New file.
11244
11245         New module 'unicase/locale-language'.
11246         * lib/unicase/locale-language.c: New file.
11247         * lib/unicase/locale-languages.gperf: New file.
11248         * modules/unicase/locale-language: New file.
11249
11250         Generate more tables for case conversion and case folding.
11251         * lib/gen-uni-tables.c (SCC_*): New enum items.
11252         (struct special_casing_rule): New type.
11253         (casing_rules, num_casing_rules, allocated_casing_rules): New
11254         variables.
11255         (add_casing_rule, fill_casing_rules): New functions.
11256         (struct casefold_rule): New type.
11257         (casefolding_rules, num_casefolding_rules,
11258         allocated_casefolding_rules): New variables.
11259         (fill_casefolding_rules): New function.
11260         (unicode_casefold): New variable.
11261         (to_casefold, redistribute_casefolding_rules, compare_casing_rules,
11262         sort_casing_rules, output_casing_rules): New functions.
11263         (main): Accept to more arguments: SpecialCasing.txt and
11264         CaseFolding.txt. Invoke fill_casing_rules, fill_casefolding_rules,
11265         redistribute_casefolding_rules, sort_casing_rules, output_casing_rules.
11266         Output mapping for casefolding.
11267
11268         * lib/unicase.h: Include stdbool.h, uninorm.h.
11269         (u8_toupper, u16_toupper, u32_toupper, u8_tolower, u16_tolower,
11270         u32_tolower, u8_totitle, u16_totitle, u32_totitle): Add nf argument.
11271         (u8_casefold, u16_casefold, u32_casefold): Add iso639_language and nf
11272         arguments.
11273         (u8_casecmp, u16_casecmp, u32_casecmp): Add iso639_language, nf,
11274         resultp arguments.
11275         (u8_casexfrm, u16_casexfrm, u32_casexfrm): New declarations.
11276         (u8_casecoll, u16_casecoll, u32_casecoll): Add iso639_language, nf,
11277         resultp arguments.
11278         (u8_is_uppercase, u16_is_uppercase, u32_is_uppercase, u8_is_lowercase,
11279         u16_is_lowercase, u32_is_lowercase, u8_is_titlecase, u16_is_titlecase,
11280         u32_is_titlecase, u8_is_casefolded, u16_is_casefolded,
11281         u32_is_casefolded, u8_is_cased, u16_is_cased, u32_is_cased): New
11282         declarations.
11283         * modules/unicase/base (Depends-on): Add uninorm/base, stdbool.
11284
11285 2009-03-08  Bruno Haible  <bruno@clisp.org>
11286
11287         * lib/uninorm.h (u8_normcmp, u16_normcmp, u32_normcmp, u8_normcoll,
11288         u16_normcoll, u32_normcoll): Rename argument 'result' to 'resultp'.
11289         * lib/uninorm/u-normcmp.h (FUNC): Likewise.
11290         * lib/uninorm/u-normcoll.h (FUNC): Likewise.
11291
11292 2009-03-07  Bruno Haible  <bruno@clisp.org>
11293
11294         Adjust u*_normcmp, u*_normcoll API.
11295         * lib/uninorm.h (u8_normcmp, u16_normcmp, u32_normcmp, u8_normcoll,
11296         u16_normcoll, u32_normcoll): Change failure conventions.
11297         * lib/uninorm/u-normcmp.h (FUNC): Upon failure, store the error code in
11298         errno and return -1.
11299         * lib/uninorm/u-normcoll.h (FUNC): Likewise.
11300
11301 2009-03-07  Bruno Haible  <bruno@clisp.org>
11302
11303         Tests for module 'uninorm/u32-normcoll'.
11304         * modules/uninorm/u32-normcoll-tests: New file.
11305         * tests/uninorm/test-u32-normcoll.c: New file.
11306
11307         Tests for module 'uninorm/u16-normcoll'.
11308         * modules/uninorm/u16-normcoll-tests: New file.
11309         * tests/uninorm/test-u16-normcoll.c: New file.
11310
11311         Tests for module 'uninorm/u8-normcoll'.
11312         * modules/uninorm/u8-normcoll-tests: New file.
11313         * tests/uninorm/test-u8-normcoll.c: New file.
11314
11315 2009-03-07  Bruno Haible  <bruno@clisp.org>
11316
11317         * tests/uninorm/test-u32-normcmp.h: New file, extracted from
11318         tests/uninorm/test-u32-normcmp.c.
11319         * tests/uninorm/test-u32-normcmp.c: Include it.
11320         (test_nonascii): New function, extracted from main. Add some more
11321         tests.
11322         (main): Invoke test_ascii and test_nonascii.
11323         * modules/uninorm/u32-normcmp-tests (Files): Add
11324         tests/uninorm/test-u32-normcmp.h.
11325         (Depends-on): Remove uninorm/u32-normcmp.
11326
11327         * tests/uninorm/test-u16-normcmp.h: New file, extracted from
11328         tests/uninorm/test-u16-normcmp.c.
11329         * tests/uninorm/test-u16-normcmp.c: Include it.
11330         (test_nonascii): New function, extracted from main. Add some more
11331         tests.
11332         (main): Invoke test_ascii and test_nonascii.
11333         * modules/uninorm/u16-normcmp-tests (Files): Add
11334         tests/uninorm/test-u16-normcmp.h.
11335         (Depends-on): Remove uninorm/u16-normcmp.
11336
11337         * tests/uninorm/test-u8-normcmp.h: New file, extracted from
11338         tests/uninorm/test-u8-normcmp.c.
11339         * tests/uninorm/test-u8-normcmp.c: Include it.
11340         (test_nonascii): New function, extracted from main. Add some more
11341         tests.
11342         (main): Invoke test_ascii and test_nonascii.
11343         * modules/uninorm/u8-normcmp-tests (Files): Add
11344         tests/uninorm/test-u8-normcmp.h.
11345         (Depends-on): Remove uninorm/u8-normcmp.
11346
11347 2009-03-07  Bruno Haible  <bruno@clisp.org>
11348
11349         New module 'uninorm/u32-normcoll'.
11350         * lib/uninorm/u32-normcoll.c: New file.
11351         * modules/uninorm/u32-normcoll: New file.
11352
11353         New module 'uninorm/u16-normcoll'.
11354         * lib/uninorm/u16-normcoll.c: New file.
11355         * modules/uninorm/u16-normcoll: New file.
11356
11357         New module 'uninorm/u8-normcoll'.
11358         * lib/uninorm.h (u8_normcoll, u16_normcoll, u32_normcoll): New
11359         declarations.
11360         * lib/uninorm/u8-normcoll.c: New file.
11361         * lib/uninorm/u-normcoll.h: New file.
11362         * modules/uninorm/u8-normcoll: New file.
11363
11364         New module 'uninorm/u32-normxfrm'.
11365         * lib/uninorm/u32-normxfrm.c: New file.
11366         * modules/uninorm/u32-normxfrm: New file.
11367
11368         New module 'uninorm/u16-normxfrm'.
11369         * lib/uninorm/u16-normxfrm.c: New file.
11370         * modules/uninorm/u16-normxfrm: New file.
11371
11372         New module 'uninorm/u8-normxfrm'.
11373         * lib/uninorm.h (u8_normxfrm, u16_normxfrm, u32_normxfrm): New
11374         declarations.
11375         * lib/uninorm/u8-normxfrm.c: New file.
11376         * lib/uninorm/u-normxfrm.h: New file.
11377         * modules/uninorm/u8-normxfrm: New file.
11378
11379 2009-03-07  Bruno Haible  <bruno@clisp.org>
11380
11381         * modules/uninorm/u8-normcmp (Depends-on): Add uninorm/base.
11382         * modules/uninorm/u16-normcmp (Depends-on): Likewise.
11383         * modules/uninorm/u32-normcmp (Depends-on): Likewise.
11384
11385 2009-03-07  Bruno Haible  <bruno@clisp.org>
11386
11387         New module 'memxfrm'.
11388         * lib/memxfrm.h: New file.
11389         * lib/memxfrm.c: New file.
11390         * modules/memxfrm: New file.
11391
11392 2009-03-07  Bruno Haible  <bruno@clisp.org>
11393
11394         New module 'memcmp2'.
11395         * lib/memcmp2.h: New file.
11396         * lib/memcmp2.c: New file.
11397         * modules/memcmp2: New file.
11398
11399 2009-03-07  Bruno Haible  <bruno@clisp.org>
11400
11401         Tests for module 'uninorm/decomposing-form'.
11402         * modules/uninorm/decomposing-form-tests: New file.
11403         * tests/uninorm/test-decomposing-form.c: New file.
11404
11405         New module 'uninorm/decomposing-form'.
11406         * lib/uninorm.h (uninorm_decomposing_form): New declaration.
11407         * lib/uninorm/normalize-internal.h (struct unicode_normalization_form):
11408         Add 'decomposing_variant' field.
11409         * lib/uninorm/decomposing-form.c: New file.
11410         * lib/uninorm/nfc.c (uninorm_nfc): Update.
11411         * lib/uninorm/nfd.c (uninorm_nfd): Update.
11412         * lib/uninorm/nfkc.c (uninorm_nfkc): Update.
11413         * lib/uninorm/nfkd.c (uninorm_nfkd): Update.
11414         * modules/uninorm/decomposing-form: New file.
11415         * modules/uninorm/nfc (Depends-on): Add uninorm/nfd.
11416         * modules/uninorm/nfkc (Depends-on): Add uninorm/nfkd.
11417
11418 2009-03-07  Bruno Haible  <bruno@clisp.org>
11419
11420         * lib/uninorm/u-normcmp.h (FUNC): Use stack=allocated buffers for small
11421         strings.
11422
11423 2009-03-06  Bruno Haible  <bruno@clisp.org>
11424
11425         Tests for module 'uninorm/u32-normcmp'.
11426         * tests/uninorm/test-u32-normcmp.c: New file.
11427         * modules/uninorm/u32-normcmp-tests: New file.
11428
11429         Tests for module 'uninorm/u16-normcmp'.
11430         * tests/uninorm/test-u16-normcmp.c: New file.
11431         * modules/uninorm/u16-normcmp-tests: New file.
11432
11433         Tests for module 'uninorm/u8-normcmp'.
11434         * tests/uninorm/test-u8-normcmp.c: New file.
11435         * modules/uninorm/u8-normcmp-tests: New file.
11436
11437         New module 'uninorm/u32-normcmp'.
11438         * lib/uninorm/u32-normcmp.c: New file.
11439         * modules/uninorm/u32-normcmp: New file.
11440
11441         New module 'uninorm/u16-normcmp'.
11442         * lib/uninorm/u16-normcmp.c: New file.
11443         * modules/uninorm/u16-normcmp: New file.
11444
11445         New module 'uninorm/u8-normcmp'.
11446         * lib/uninorm.h (u8_normcmp, u16_normcmp, u32_normcmp): New
11447         declarations.
11448         * lib/uninorm/u8-normcmp.c: New file.
11449         * lib/uninorm/u-normcmp.h: New file.
11450         * modules/uninorm/u8-normcmp: New file.
11451
11452 2009-03-06  Bruno Haible  <bruno@clisp.org>
11453
11454         * lib/w32spawn.h (dup_noinherit): Add cast, to avoid gcc warning.
11455         Reported by Eric Blake.
11456
11457 2009-03-06  Eric Blake  <ebb9@byu.net>
11458             Bruno Haible  <bruno@clisp.org>
11459
11460         * lib/spawni.c (__spawni) [WIN32_NATIVE]: Define as a stub.
11461         * modules/posix_spawn-tests (configure.ac): Define POSIX_SPAWN_PORTED
11462         condition.
11463         (Makefile.am): Do nothing if POSIX_SPAWN_PORTED is false.
11464         * modules/posix_spawnp-tests (configure.ac): Define POSIX_SPAWN_PORTED
11465         condition.
11466         (Makefile.am): Do nothing if POSIX_SPAWN_PORTED is false.
11467
11468 2009-03-06  Eric Blake  <ebb9@byu.net>
11469
11470         * lib/execute.c (execute) [WIN32_NATIVE]: Cast arguments of spawnvpe,
11471         to avoid compiler warnings.
11472         * lib/pipe.c (create_pipe) [WIN32_NATIVE]: Likewise.
11473
11474 2009-03-05  Bruno Haible  <bruno@clisp.org>
11475
11476         * tests/test-ftell.c (main): Disable test beyond end of file on
11477         FreeMiNT.
11478         Patch by Alan Hourihane <alanh@fairlite.co.uk>.
11479
11480 2009-03-05  Kamil Dudka  <kdudka@redhat.com>
11481
11482         * lib/filevercmp.c: Move hidden files up in ordering.
11483         * tests/test-filevercmp.c: Add tests for hidden files.
11484
11485 2009-03-04  Bruno Haible  <bruno@clisp.org>
11486
11487         * modules/visibility (Makefile.am): Augment AM_CFLAGS.
11488         * gnulib-tool (func_emit_lib_Makefile_am): Emit initialization of
11489         AM_CFLAGS.
11490         Reported by Simon Josefsson.
11491
11492 2009-03-03  Bruno Haible  <bruno@clisp.org>
11493
11494         * doc/visibility.texi: Recommend to use HAVE_VISIBILITY as a C macro.
11495         Reported by Simon Josefsson.
11496
11497         * doc/ld-version-script.texi: Update node reference.
11498
11499 2009-03-03  Bruno Haible  <bruno@clisp.org>
11500
11501         * modules/visibility (License): Change to 'unlimited'.
11502         Suggested by Simon Josefsson.
11503
11504 2009-03-03  Jim Meyering  <meyering@redhat.com>
11505
11506         unlinkdir: cannot_unlink_dir may modify process state
11507         * lib/unlinkdir.c (cannot_unlink_dir): Add a comment warning that
11508         it's neither thread-safe nor appropriate for use in a library.
11509
11510 2009-03-03  Eric Blake  <ebb9@byu.net>
11511
11512         test-closein: silence test under Darwin
11513         * tests/test-closein.sh: Ignore stderr from cat, since we don't
11514         care if it dies from EPIPE or EBADF.
11515
11516 2009-03-03  Bruno Haible  <bruno@clisp.org>
11517
11518         * doc/gnulib.texi: Include visibility.texi and ld-version-script.texi
11519         earlier.
11520         * doc/visibility.texi: Fix @node and @section.
11521
11522 2009-03-03  Simon Josefsson  <simon@josefsson.org>
11523
11524         * doc/gnulib.texi: Link to sections for ld version script and
11525         visibility.
11526         * doc/visibility.texi: Add @node and @section.
11527         * modules/ld-version-script: New module.
11528         * m4/ld-version-script.m4: New file.
11529         * doc/ld-version-script.texi: New file.
11530
11531 2009-03-02  David Lutterkort  <lutter@redhat.com>
11532
11533         * lib/safe-alloc.h (__GNUC_PREREQ): New macro.
11534         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
11535
11536 2009-03-02  Bruno Haible  <bruno@clisp.org>
11537
11538         * doc/visibility.texi: Mention libtool's -export-symbols option.
11539
11540 2009-03-02  Jim Meyering  <meyering@redhat.com>
11541
11542         announce-gen: new option: --no-print-checksums
11543         * build-aux/announce-gen (usage): Describe it.
11544         (print_checksums): Print a newline here, not in the [*] footnote.
11545         (main): Honor it.
11546
11547 2009-03-01  Bruno Haible  <bruno@clisp.org>
11548
11549         Use socklen_t in the native Windows replacements prototypes.
11550         * lib/sys_socket.in.h (rpl_getsockopt, rpl_setsockopt): Use socklen_t
11551         instead of 'int'.
11552         * lib/getsockopt.c (rpl_getsockopt): Likewise.
11553         * lib/setsockopt.c (rpl_setsockopt): Likewise.
11554         * modules/getsockopt (Depends-on): Add socklen.
11555         * modules/setsockopt (Depends-on): Add socklen.
11556
11557 2009-03-01  Bruno Haible  <bruno@clisp.org>
11558
11559         * gnulib-tool (sed): Do alias as "sed --posix" if sed's version is at
11560         least 4.2.
11561
11562 2009-03-01  Eric Blake  <ebb9@byu.net>
11563             Bruno Haible  <bruno@clisp.org>
11564
11565         * lib/wait-process.h (wait_subprocess): Describe effect of termsigp on
11566         error messages.
11567         * lib/wait-process.c (wait_subprocess): Omit error message about
11568         deadly signal sent to the child of termsigp != NULL.
11569
11570 2009-03-01  Eric Blake  <ebb9@byu.net>
11571
11572         * lib/wait-process.c (wait_subprocess): Remove unnecessary cast.
11573
11574 2009-03-01  Bruno Haible  <bruno@clisp.org>
11575
11576         Avoid a gcc warning.
11577         * tests/test-sched.c (b): Make global.
11578         Reported by Eric Blake.
11579
11580 2009-01-19  Martin Lambers  <marlam@marlam.de>
11581
11582         Provide POSIX semantics for socket timeout options on W32.
11583         * lib/setsockopt.c: Convert struct timeval to milliseconds on W32.
11584         * lib/getsockopt.c: Convert milliseconds to struct timeval on W32.
11585         * modules/setsockopt: Depend on sys_time module for struct timeval.
11586         * modules/getsockopt: Depend on sys_time module for struct timeval.
11587
11588 2009-03-01  Simon Josefsson  <simon@josefsson.org>
11589
11590         * lib/gai_strerror.c (values): Use EAI_INPROGRESS instead of
11591         __USE_GNU, for consistency with netdb.in.h.
11592         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
11593
11594 2009-03-01  Bruno Haible  <bruno@clisp.org>
11595
11596         More support for FreeMiNT.
11597         * lib/fseeko.c (rpl_fseeko): Complete last commit.
11598         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
11599
11600 2009-03-01  Bruno Haible  <bruno@clisp.org>
11601
11602         More support for FreeMiNT.
11603         * lib/fpurge.c (fpurge): Correct last commit.
11604         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
11605
11606 2009-03-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11607
11608         Fix unportable awk script in vc-list-files.
11609         * build-aux/vc-list-files: In the replacement awk script, use
11610         substr with a second argument of 1, not zero.
11611         Report by Simon Josefsson.
11612
11613 2009-02-28  Bruno Haible  <bruno@clisp.org>
11614
11615         More support for FreeMiNT.
11616         * lib/freading.c (freading) [__MINT__]: Use new macros that were added
11617         to FreeMiNT today.
11618         * lib/fwriting.c (fwriting): Likewise.
11619         Based on patch by Alan Hourihane <alanh@fairlite.co.uk>.
11620
11621 2009-02-28  Bruno Haible  <bruno@clisp.org>
11622
11623         * tests/test-freadseek.c (main): Disable test beyond end of file on
11624         FreeMiNT.
11625         * tests/test-ftello.c (main): Likewise.
11626         Patch by Alan Hourihane <alanh@fairlite.co.uk>.
11627
11628 2009-02-28  Bruno Haible  <bruno@clisp.org>
11629
11630         Add tentative support for FreeMiNT.
11631         * lib/fbufmode.c (fbufmode) [__MINT__]: Add conditional code.
11632         * lib/fpurge.c (fpurge): Likewise.
11633         * lib/freadable.c (freadable): Likewise.
11634         * lib/freading.c (freading): Likewise.
11635         * lib/freadptr.c (freadptr): Likewise.
11636         * lib/freadseek.c (freadptrinc): Likewise.
11637         * lib/fseeko.c (rpl_fseeko): Likewise.
11638         * lib/fseterr.c (fseterr): Likewise.
11639         * lib/fwritable.c (fwritable): Likewise.
11640         * lib/fwriting.c (fwriting): Likewise.
11641         * lib/freadahead.c (freadahead): Likewise, based on code by Alan
11642         Hourihane.
11643         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
11644
11645 2009-02-28  Bruno Haible  <bruno@clisp.org>
11646
11647         * lib/wait-process.h (wait_subprocess): Clarify restriction regarding
11648         SIGCHLD.
11649         Reported by Jim Meyering.
11650
11651 2009-02-28  Bruno Haible  <bruno@clisp.org>
11652
11653         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Separate the two first tests.
11654         Mention the results of these tests on various platforms.
11655         * doc/posix-functions/fprintf.texi: Mention platforms in canonical
11656         order.
11657         * doc/posix-functions/printf.texi: Likewise.
11658         * doc/posix-functions/snprintf.texi: Likewise.
11659         * doc/posix-functions/sprintf.texi: Likewise.
11660         * doc/posix-functions/vfprintf.texi: Likewise.
11661         * doc/posix-functions/vprintf.texi: Likewise.
11662         * doc/posix-functions/vsnprintf.texi: Likewise.
11663         * doc/posix-functions/vsprintf.texi: Likewise.
11664         * doc/glibc-functions/obstack_printf.texi: Likewise.
11665         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
11666
11667 2009-02-28  Bruno Haible  <bruno@clisp.org>
11668
11669         * build-aux/po/Makefile.in.in: Update from GNU gettext 0.17.
11670         Reported by Loïc Minier <lool@dooz.org>.
11671
11672 2009-02-27  Bruno Haible  <bruno@clisp.org>
11673
11674         * gnulib-tool (func_import): Make the sed expression used to create the
11675         sed script for updating the .gitignore file POSIX compliant.
11676         Reported by Eric Blake.
11677
11678 2009-02-27  Bruno Haible  <bruno@clisp.org>
11679
11680         * gnulib-tool (sed): Don't alias as "sed --posix".
11681         Reported by Eric Blake.
11682
11683 2009-02-27  Bruno Haible  <bruno@clisp.org>
11684
11685         Avoid test link errors.
11686         * modules/uninorm/nfc-tests (test_u32_nfc_big_LDADD): New variable.
11687         * modules/uninorm/nfd-tests (test_u32_nfd_big_LDADD): New variable.
11688         * modules/uninorm/nfkc-tests (test_u32_nfkc_big_LDADD): New variable.
11689         * modules/uninorm/nfkd-tests (test_u32_nfkd_big_LDADD): New variable.
11690         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
11691
11692 2009-02-27  Bruno Haible  <bruno@clisp.org>
11693
11694         Avoid spurious "(cached)" in configure output.
11695         * m4/gnulib-common.m4 (gl_CACHE_VAL_SILENT): New macro.
11696         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): Use it instead of AC_CACHE_VAL.
11697         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): Likewise.
11698         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): Likewise.
11699         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): Likewise.
11700         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): Likewise.
11701         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): Likewise.
11702         * m4/stdarg.m4 (gl_STDARG_H): Likewise.
11703         Reported by Eric Blake.
11704
11705 2009-02-27  Eric Blake  <ebb9@byu.net>
11706
11707         printf: fix regression in previous patch
11708         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Fix compilation error.
11709
11710 2009-02-27  Bruno Haible  <bruno@clisp.org>
11711
11712         * lib/inttypes.in.h: Test merely whether _LP64 is defined, not its
11713         value.
11714         * lib/stdint.in.h: Likewise.
11715         Suggested by Eric Blake. Reported by Peter Bray <pdb_ml@yahoo.com.au>.
11716
11717 2009-02-27  Eric Blake  <ebb9@byu.net>
11718
11719         doc: mention more functions added in cygwin 1.7.0
11720         * doc/posix-functions/mbsnrtowcs.texi: Mention recent cygwin 1.7.0
11721         addition.
11722         * doc/posix-functions/open_wmemstream.texi: Likewise.
11723         * doc/posix-functions/wcsnlen.texi: Likewise.
11724         * doc/posix-functions/wcsnrtombs.texi: Likewise.
11725         * doc/posix-functions/wcstod.texi: Likewise.
11726         * doc/posix-functions/wcstof.texi: Likewise.
11727         * doc/posix-functions/wcstoimax.texi: Likewise.
11728         * doc/posix-functions/wcstok.texi: Likewise.
11729         * doc/posix-functions/wcstoumax.texi: Likewise.
11730
11731         Detect bug in cygwin 1.5.x *printf on 1-character %ls.
11732         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Enhance filter.
11733         * doc/posix-functions/fprintf.texi: Update.
11734         * doc/posix-functions/printf.texi: Update.
11735         * doc/posix-functions/snprintf.texi: Update.
11736         * doc/posix-functions/sprintf.texi: Update.
11737         * doc/posix-functions/vfprintf.texi: Update.
11738         * doc/posix-functions/vprintf.texi: Update.
11739         * doc/posix-functions/vsnprintf.texi: Update.
11740         * doc/posix-functions/vsprintf.texi: Update.
11741         * doc/glibc-functions/obstack_printf.texi: Update.
11742         * doc/glibc-functions/obstack_vprintf.texi: Update.
11743
11744 2009-02-26  Eric Blake  <ebb9@byu.net>
11745
11746         avoid gcc 3.4.3 bug on long double NaN on Irix 6.5
11747         * tests/nan.h (NaNl): Rewrite as function on Irix, to avoid
11748         compilation bug by using runtime conversion.
11749         * m4/isfinite.m4 (gl_ISFINITE): Likewise.
11750         * m4/isnanl.m4 (gl_FUNC_ISNANL): Likewise.
11751         * modules/ceill-tests (Files): Use nan.h.
11752         * modules/floorl-tests (Files): Likewise.
11753         * modules/frexpl-tests (Files): Likewise.
11754         * modules/isnanl-tests (Files): Likewise.
11755         * modules/ldexpl-tests (Files): Likewise.
11756         * modules/roundl-tests (Files): Likewise.
11757         * modules/truncl-tests (Files): Likewise.
11758         * tests/test-ceill.c (main): Use a working NaN.
11759         * tests/test-floorl.c (main): Likewise.
11760         * tests/test-frexpl.c (main): Likewise.
11761         * tests/test-isnan.c (test_long_double): Likewise.
11762         * tests/test-isnanl.h (main): Likewise.
11763         * tests/test-ldexpl.h (main): Likewise.
11764         * tests/test-roundl.h (main): Likewise.
11765         * tests/test-truncl.h (main): Likewise.
11766         See http://lists.gnu.org/archive/html/bug-gnulib/2009-02/msg00190.html.
11767
11768 2009-02-26  Eric Blake  <ebb9@byu.net>
11769             Bruno Haible  <bruno@clisp.org>
11770
11771         Work around a *printf bug with %ls on Solaris.
11772         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Also test whether, when a
11773         precision is specified, sprintf stops converting the wide string
11774         argument when the number of bytes that have been produced by this
11775         conversion equals or exceeds the precision.
11776         * doc/posix-functions/fprintf.texi: Update.
11777         * doc/posix-functions/printf.texi: Update.
11778         * doc/posix-functions/snprintf.texi: Update.
11779         * doc/posix-functions/sprintf.texi: Update.
11780         * doc/posix-functions/vfprintf.texi: Update.
11781         * doc/posix-functions/vprintf.texi: Update.
11782         * doc/posix-functions/vsnprintf.texi: Update.
11783         * doc/posix-functions/vsprintf.texi: Update.
11784         * doc/glibc-functions/obstack_printf.texi: Update.
11785         * doc/glibc-functions/obstack_vprintf.texi: Update.
11786
11787 2009-02-26  Eric Blake  <ebb9@byu.net>
11788
11789         stdlib: favor compiler check of random.h
11790         * m4/stdlib_h.m4 (gl_STDLIB_H): Skip preprocessor check.  Needed
11791         to avoid an ObjC random.h installed by Swarm.
11792
11793 2009-02-26  Bruno Haible  <bruno@clisp.org>
11794
11795         Work around *printf bug with %g directive and 0.0 on HP-UX 10.20.
11796         * m4/printf.m4 (gl_PRINTF_INFINITE): Also test for %g output of -0.0.
11797         Reported by Gary V. Vaughan <gary@gnu.org>.
11798
11799 2009-02-26  Bruno Haible  <bruno@clisp.org>
11800
11801         Fix *printf behaviour regarding the %ls directive.
11802         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): New macro.
11803         * lib/vasnprintf.c (local_wcslen, VASNPRINTF): Handle
11804         NEED_PRINTF_DIRECTIVE_LS.
11805         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_LS): New macro.
11806         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
11807         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
11808         gl_PREREQ_VASNPRINTF_DIRECTIVE_LS and test its result. Invoke
11809         gl_PREREQ_VASNPRINTF_DIRECTIVE_LS.
11810         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_POSIX): Likewise.
11811         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX): Likewise.
11812         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
11813         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
11814         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
11815         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
11816         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_POSIX): Likewise.
11817         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
11818         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
11819         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
11820         * doc/posix-functions/fprintf.texi: Update.
11821         * doc/posix-functions/printf.texi: Update.
11822         * doc/posix-functions/snprintf.texi: Update.
11823         * doc/posix-functions/sprintf.texi: Update.
11824         * doc/posix-functions/vfprintf.texi: Update.
11825         * doc/posix-functions/vprintf.texi: Update.
11826         * doc/posix-functions/vsnprintf.texi: Update.
11827         * doc/posix-functions/vsprintf.texi: Update.
11828         * doc/glibc-functions/obstack_printf.texi: Update.
11829         * doc/glibc-functions/obstack_vprintf.texi: Update.
11830         Reported by Eric Blake.
11831
11832 2009-02-25  Bruno Haible  <bruno@clisp.org>
11833
11834         * m4/mbrtowc.m4 (gl_MBRTOWC_NUL_RETVAL): Update guess for Solaris 8
11835         with known value.
11836         Reported by Gary V. Vaughan <gary@gnu.org>.
11837
11838 2009-02-25  Bruno Haible  <bruno@clisp.org>
11839
11840         Work around mbrtowc bug in zh_CN.GB18030 locale on Solaris 8.
11841         * m4/mbrtowc.m4 (gl_MBRTOWC_SANITYCHECK): New macro.
11842         (gl_MBSTATE_T_BROKEN): Invoke it. Replace mbstate_t when it says "no".
11843         * doc/posix-functions/mbrtowc.texi: Document the Solaris 8 bug.
11844         Reported by Gary V. Vaughan <gary@gnu.org>.
11845
11846 2009-02-25  Bruno Haible  <bruno@clisp.org>
11847
11848         Work around broken INT8_MAX, UINT8_MAX etc. values on HP-UX 11.23.
11849         * m4/stdint.m4 (gl_STDINT_H): Also check whether the expansions of
11850         INT8_MAX, UINT8_MAX etc. contain casts to elementary types.
11851         * doc/posix-headers/stdint.texi: Mention the HP-UX bug.
11852         Reported by Gary V. Vaughan <gary@gnu.org>.
11853
11854 2009-02-25  Eric Blake  <ebb9@byu.net>
11855
11856         tests: skip fseek/ftell tests if ungetc is broken
11857         * m4/ungetc.m4: New file.
11858         * modules/fseek-tests: Split test, so ungetc dependency is
11859         separate from rest of test.
11860         * modules/fseeko-tests: Likewise.
11861         * modules/ftell-tests: Likewise.
11862         * modules/ftello-tests: Likewise.
11863         * tests/test-fseek.c (main): Isolate ungetc dependency.
11864         * tests/test-fseeko.c (main): Likewise.
11865         * tests/test-ftell.c (main): Likewise.
11866         * tests/test-ftello.c (main): Likewise.
11867         * tests/test-fseek2.sh: New file.
11868         * tests/test-fseeko2.sh: Likewise.
11869         * tests/test-ftell2.sh: Likewise.
11870         * tests/test-ftello2.sh: Likewise.
11871
11872 2009-02-25  OndÅ™ej Vašík  <ovasik@redhat.com>
11873
11874         test-getaddrinfo: fix usage of skip return code 77
11875         * tests/test-gettaddrinfo.c: Return skip code 77 only
11876         for first occurance of skip (4x77 is not 77)
11877
11878 2009-02-25  Gary V. Vaughan  <gary@gnu.org>
11879
11880         strtod: avoid C99 decl-after-statement
11881         * m4/strtod.m4 (gl_FUNC_STRTOD): Rearrange declaration.
11882
11883 2009-02-24  Eric Blake  <ebb9@byu.net>
11884
11885         strtod: detect HP-UX 11.31 bug
11886         * m4/strtod.m4 (gl_FUNC_STRTOD): Detect errno handling bug.
11887         Reported by Gary V. Vaughan.
11888
11889 2009-02-23  Bruno Haible  <bruno@clisp.org>
11890
11891         Fix invalid read past end of memory block.
11892         * lib/vasnprintf.c (DCHAR_SET): Define.
11893         (local_wcslen): Define only when needed.
11894         (local_strnlen, local_wcsnlen): New functions.
11895         (VASNPRINTF) [!USE_SNPRINTF && HAVE_WCHAR_T]: Implement the %s and %ls
11896         directives that involve a conversion ourselves.
11897         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for strnlen,
11898         wcsnlen, mbrtowc, wcrtomb.
11899         * tests/test-vasnprintf-posix.c (test_function): Add tests for %.*s.
11900         * tests/test-vasprintf-posix.c (test_function): Likewise.
11901         * tests/test-snprintf-posix.h (test_function): Likewise.
11902         * tests/test-sprintf-posix.h (test_function): Likewise.
11903         Reported by Ben Pfaff <blp@cs.stanford.edu>.
11904
11905 2009-02-22  Bruno Haible  <bruno@clisp.org>
11906
11907         Implement new clarified decomposition of Hangul syllables.
11908         * lib/uninorm/decomposition.c (uc_decomposition): For Hangul syllables
11909         of type LTV, return only a pairwise decomposition.
11910         * lib/uninorm/canonical-decomposition.c (uc_canonical_decomposition):
11911         Likewise.
11912         * tests/uninorm/test-decomposition.c (main): Updated expected result.
11913         * tests/uninorm/test-canonical-decomposition.c (main): Likewise.
11914         * tests/uninorm/test-compat-decomposition.c (main): Likewise.
11915
11916 2009-02-22  Bruno Haible  <bruno@clisp.org>
11917
11918         * lib/uninorm/u-normalize-internal.h (FUNC): At the end, handle
11919         zero-length results and shrink excess allocated memory.
11920         * tests/uninorm/test-u8-nfc.c (test_u8_nfc): Check empty string result.
11921         * tests/uninorm/test-u8-nfd.c (test_u8_nfd): Likewise.
11922         * tests/uninorm/test-u8-nfkc.c (test_u8_nfkc): Likewise.
11923         * tests/uninorm/test-u8-nfkd.c (test_u8_nfkd): Likewise.
11924         * tests/uninorm/test-u16-nfc.c (test_u16_nfc): Likewise.
11925         * tests/uninorm/test-u16-nfd.c (test_u16_nfd): Likewise.
11926         * tests/uninorm/test-u16-nfkc.c (test_u16_nfkc): Likewise.
11927         * tests/uninorm/test-u16-nfkd.c (test_u16_nfkd): Likewise.
11928         * tests/uninorm/test-u32-nfc.c (test_u32_nfc): Likewise.
11929         * tests/uninorm/test-u32-nfd.c (test_u32_nfd): Likewise.
11930         * tests/uninorm/test-u32-nfkc.c (test_u32_nfkc): Likewise.
11931         * tests/uninorm/test-u32-nfkd.c (test_u32_nfkd): Likewise.
11932
11933 2009-02-21  Bruno Haible  <bruno@clisp.org>
11934
11935         * doc/gnulib.texi: Include safe-alloc.texi earlier.
11936         * doc/safe-alloc.texi: Terminate sentences with a period. Use two
11937         spaces after a period. Put a space between a macro name and its
11938         argument list. Trivial rewordings.
11939         * lib/safe-alloc.c: Include safe-alloc.h right after config.h.
11940         * tests/test-safe-alloc.c: Likewise. Include stdlib.h.
11941         (main): Return 0 explicitly.
11942
11943 2009-02-21  Bruno Haible  <bruno@clisp.org>
11944
11945         Tests for module 'uninorm/filter'.
11946         * tests/uninorm/test-uninorm-filter-nfc.c: New file.
11947         * modules/uninorm/filter-tests: New file.
11948
11949         New module 'uninorm/filter'.
11950         * lib/uninorm.h (uninorm_filter_create, uninorm_filter_write,
11951         uninorm_filter_flush, uninorm_filter_free): New declarations.
11952         * lib/uninorm/uninorm-filter.c: New file.
11953         * modules/uninorm/filter: New file.
11954
11955 2009-02-21  Bruno Haible  <bruno@clisp.org>
11956
11957         Tests for module 'uninorm/nfkc'.
11958         * tests/uninorm/test-nfkc.c: New file.
11959         * tests/uninorm/test-u8-nfkc.c: New file.
11960         * tests/uninorm/test-u16-nfkc.c: New file.
11961         * tests/uninorm/test-u32-nfkc.c: New file.
11962         * tests/uninorm/test-u32-nfkc-big.sh: New file.
11963         * tests/uninorm/test-u32-nfkc-big.c: New file.
11964         * modules/uninorm/nfkc-tests: New file.
11965
11966         New module 'uninorm/nfkc'.
11967         * lib/uninorm/nfkc.c: New file.
11968         * modules/uninorm/nfkc: New file.
11969
11970         Tests for module 'uninorm/nfkd'.
11971         * tests/uninorm/test-nfkd.c: New file.
11972         * tests/uninorm/test-u8-nfkd.c: New file.
11973         * tests/uninorm/test-u16-nfkd.c: New file.
11974         * tests/uninorm/test-u32-nfkd.c: New file.
11975         * tests/uninorm/test-u32-nfkd-big.sh: New file.
11976         * tests/uninorm/test-u32-nfkd-big.c: New file.
11977         * modules/uninorm/nfkd-tests: New file.
11978
11979         New module 'uninorm/nfkd'.
11980         * lib/uninorm/nfkd.c: New file.
11981         * modules/uninorm/nfkd: New file.
11982
11983         Tests for module 'uninorm/nfc'.
11984         * tests/uninorm/test-nfc.c: New file.
11985         * tests/uninorm/test-u8-nfc.c: New file.
11986         * tests/uninorm/test-u16-nfc.c: New file.
11987         * tests/uninorm/test-u32-nfc.c: New file.
11988         * tests/uninorm/test-u32-nfc-big.sh: New file.
11989         * tests/uninorm/test-u32-nfc-big.c: New file.
11990         * modules/uninorm/nfc-tests: New file.
11991
11992         New module 'uninorm/nfc'.
11993         * lib/uninorm/nfc.c: New file.
11994         * modules/uninorm/nfc: New file.
11995
11996         Tests for module 'uninorm/nfd'.
11997         * tests/uninorm/test-nfd.c: New file.
11998         * tests/uninorm/test-u8-nfd.c: New file.
11999         * tests/uninorm/test-u16-nfd.c: New file.
12000         * tests/uninorm/test-u32-nfd.c: New file.
12001         * tests/uninorm/test-u32-nfd-big.sh: New file.
12002         * tests/uninorm/test-u32-nfd-big.c: New file.
12003         * tests/uninorm/test-u32-normalize-big.h: New file.
12004         * tests/uninorm/test-u32-normalize-big.c: New file.
12005         * tests/uninorm/NormalizationTest.txt: New file, created from
12006         Unicode 5.1.0 NormalizationTest.txt.
12007         * modules/uninorm/nfd-tests: New file.
12008
12009         New module 'uninorm/nfd'.
12010         * lib/uninorm/nfd.c: New file.
12011         * modules/uninorm/nfd: New file.
12012
12013         New module 'uninorm/u32-normalize'.
12014         * lib/uninorm/u32-normalize.c: New file.
12015         * modules/uninorm/u32-normalize: New file.
12016
12017         New module 'uninorm/u16-normalize'.
12018         * lib/uninorm/u16-normalize.c: New file.
12019         * modules/uninorm/u16-normalize: New file.
12020
12021         New module 'uninorm/u8-normalize'.
12022         * lib/uninorm/u8-normalize.c: New file.
12023         * lib/uninorm/normalize-internal.h: New file.
12024         * lib/uninorm/u-normalize-internal.h: New file.
12025         * modules/uninorm/u8-normalize: New file.
12026
12027         New module 'uninorm/decompose-internal'.
12028         * lib/uninorm/decompose-internal.c: New file.
12029         * modules/uninorm/decompose-internal: New file.
12030
12031         Tests for module 'uninorm/composition'.
12032         * tests/uninorm/test-composition.c: New file.
12033         * modules/uninorm/composition-tests: New file.
12034
12035         New module 'uninorm/composition'.
12036         * lib/uninorm/composition.c: New file.
12037         * lib/uninorm/composition-table.gperf: New file, generated by
12038         gen-uni-tables.
12039         * modules/uninorm/composition: New file.
12040
12041         Tests for module 'uninorm/compat-decomposition'.
12042         * tests/uninorm/test-compat-decomposition.c: New file.
12043         * modules/uninorm/compat-decomposition-tests: New file.
12044
12045         New module 'uninorm/compat-decomposition'.
12046         * lib/uninorm/decompose-internal.h: New file.
12047         * lib/uninorm/compat-decomposition.c: New file.
12048         * modules/uninorm/compat-decomposition: New file.
12049
12050         Tests for module 'uninorm/canonical-decomposition'.
12051         * tests/uninorm/test-canonical-decomposition.c: New file.
12052         * modules/uninorm/canonical-decomposition-tests: New file.
12053
12054         New module 'uninorm/canonical-decomposition'.
12055         * lib/uninorm/canonical-decomposition.c: New file.
12056         * modules/uninorm/canonical-decomposition: New file.
12057
12058         Tests for module 'uninorm/decomposition'.
12059         * tests/uninorm/test-decomposition.c: New file.
12060         * modules/uninorm/decomposition-tests: New file.
12061
12062         New module 'uninorm/decomposition'.
12063         * lib/uninorm/decomposition.c: New file.
12064         * modules/uninorm/decomposition: New file.
12065
12066         New module 'uninorm/decomposition-table'.
12067         * lib/uninorm/decomposition-table.h: New file.
12068         * lib/uninorm/decomposition-table.c: New file.
12069         * lib/uninorm/decomposition-table1.h: New file, generated by
12070         gen-uni-tables.
12071         * lib/uninorm/decomposition-table2.h: New file, generated by
12072         gen-uni-tables.
12073         * modules/uninorm/decomposition-table: New file.
12074
12075         * lib/gen-uni-tables.c (MAX_DECOMP_LENGTH): New macro.
12076         (UC_DECOMP_*): New enumeration items.
12077         (get_decomposition): New function.
12078         (struct decomp_table): New type.
12079         (output_decomposition, output_decomposition_tables): New functions.
12080         (unicode_composition_exclusions): New variable.
12081         (fill_composition_exclusions, debug_output_composition_tables): New
12082         functions.
12083         (main): Accept one more argument. Invoke fill_composition_exclusions.
12084         Output decomposition and composition tables.
12085
12086         New module 'uninorm/base'.
12087         * lib/uninorm.h: New file.
12088         * lib/unictype.h: Update comment.
12089         * modules/uninorm/base: New file.
12090
12091 2009-02-21  David Lutterkort  <lutter@redhat.com>
12092
12093         Tests for module 'safe-alloc'.
12094         * tests/test-safe-alloc.c: New file.
12095         * modules/safe-alloc-tests: New file.
12096
12097         New module 'safe-alloc'.
12098         * lib/safe-alloc.h: New file.
12099         * lib/safe-alloc.c: New file.
12100         * m4/safe-alloc.m4: New file.
12101         * modules/safe-alloc: New file.
12102         * doc/safe-alloc.texi: New file.
12103         * doc/gnulib.texi: Include it.
12104         * MODULES.html.sh (Memory management functions <stdlib.h>): Add
12105         safe-alloc.
12106
12107 2009-02-18  Bruno Haible  <bruno@clisp.org>
12108
12109         Fix link error on non-glibc systems.
12110         * modules/uniwbrk/ulc-wordbreaks-tests (test_ulc_wordbreaks_LDADD): New
12111         variable.
12112         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
12113
12114 2009-02-18  Jim Meyering  <meyering@redhat.com>
12115
12116         fts: avoid used-uninitialized error due to recent change
12117         * lib/fts.c (fts_read): Guard uses of the new member,
12118         parent->fts_n_dirs_remaining, since it's not relevant for
12119         the parent of a directory specified on the command-line.
12120
12121 2009-02-17  James Youngman  <jay@gnu.org>
12122             Bruno Haible  <bruno@clisp.org>
12123
12124         * m4/include_next.m4: Reformulate comment.
12125
12126 2009-02-16  Jim Meyering  <meyering@redhat.com>
12127
12128         fts: add #if guards so that the fts_lgpl module still builds
12129         * lib/fts.c: Guard just-added hash-table-using parts with
12130         #if GNULIB_FTS, so as not to break builds of the fts_lgpl module.
12131         Reported by Simon Josefsson.
12132
12133 2009-02-15  Bruno Haible  <bruno@clisp.org>
12134
12135         * modules/array-mergesort-tests: New file.
12136         * tests/test-array-mergesort.c: New file.
12137
12138         New module 'array-mergesort'.
12139         * modules/array-mergesort: New file.
12140         * lib/array-mergesort.h: New file.
12141
12142 2009-02-15  Bruno Haible  <bruno@clisp.org>
12143
12144         Fix 2009-02-07 commit.
12145         * lib/gen-uni-tables.c (output_predicate, output_category,
12146         output_combclass, output_bidi_category, output_decimal_digit,
12147         output_digit, output_numeric, output_mirror, output_scripts,
12148         output_ident_category, output_simple_mapping): Fix format directives.
12149         (output_lbp, output_wbp): Don't convert -1 to a size_t implicitly.
12150
12151 2009-02-15  Albert Chin-A-Young  <china@thewrittenword.com>
12152
12153         * m4/include_next.m4: Update comment about IBM C 9.0/10.1 bug, now that
12154         fixes are available from IBM.
12155
12156 2009-02-13  Jim Meyering  <meyering@redhat.com>
12157
12158         fts: arrange not to stat non-directories in more cases
12159         This makes GNU find (when it doesn't need to stat each file)
12160         *much* more efficient at traversing reiserfs file systems.
12161         * lib/fts_.h (struct ftsent) [fts_n_dirs_remaining]: New member.
12162         (struct FTS) [fts_leaf_optimization_works_ht]: Add member.
12163         * lib/fts.c (fts_close): Free ->fts_leaf_optimization_works_ht.
12164         (S_MAGIC_REISERFS, S_MAGIC_PROC): Define.
12165         (leaf_optimization_applies): New function.
12166         (LCO_hash, LCO_compare): New helper functions.
12167         (link_count_optimize_ok): New function.
12168         (fts_stat): Initialize new member (if dir).
12169         (fts_read): Decrement parent's fts_n_dirs_remaining count if
12170         we've just stat'ed a directory.  Skip the stat call when possible.
12171         ---
12172         Note this AFS-related exchange:
12173         http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=143111
12174         and note find's pioctl call in find/fstype.c.
12175         But that is necessary only if you want to enable the
12176         optimization for AFS, and for now, I don't.
12177
12178         fts: move a function definition "up" (no semantic change)
12179         * lib/fts.c (dirent_inode_sort_may_be_useful): Move definition
12180         "up" to precede upcoming use of a related function.
12181
12182 2009-02-11  Jim Meyering  <meyering@redhat.com>
12183
12184         fts: correct internal computation of nlinks (optimization-related)
12185         * lib/fts.c (fts_build): ISSET(FTS_NOSTAT) has no bearing on
12186         whether the current entry is a directory, so don't test it.
12187
12188 2009-02-10  Bruno Haible  <bruno@clisp.org>
12189
12190         Tests for module 'uniwbrk/ulc-wordbreaks'.
12191         * modules/uniwbrk/ulc-wordbreaks-tests: New file.
12192         * tests/uniwbrk/test-ulc-wordbreaks.sh: New file.
12193         * tests/uniwbrk/test-ulc-wordbreaks.c: New file.
12194
12195         Tests for module 'uniwbrk/u32-wordbreaks'.
12196         * modules/uniwbrk/u32-wordbreaks-tests: New file.
12197         * tests/uniwbrk/test-u32-wordbreaks.c: New file.
12198
12199         Tests for module 'uniwbrk/u16-wordbreaks'.
12200         * modules/uniwbrk/u16-wordbreaks-tests: New file.
12201         * tests/uniwbrk/test-u16-wordbreaks.c: New file.
12202
12203         Tests for module 'uniwbrk/u8-wordbreaks'.
12204         * modules/uniwbrk/u8-wordbreaks-tests: New file.
12205         * tests/uniwbrk/test-u8-wordbreaks.c: New file.
12206
12207 2009-02-10  Bruno Haible  <bruno@clisp.org>
12208
12209         * modules/uniwbrk/u8-wordbreaks (Depends-on): Add uniwbrk/wordbreak
12210         property.
12211         * modules/uniwbrk/u16-wordbreaks (Depends-on): Likewise.
12212         * modules/uniwbrk/u32-wordbreaks (Depends-on): Likewise.
12213         * modules/uniwbrk/ulc-wordbreaks (Depends-on): Add localcharset.
12214
12215 2009-02-10  Simon Josefsson  <simon@josefsson.org>
12216
12217         * m4/sockets.m4: Call AC_C_INLINE since sockets.h now can use
12218         inline keywords.  Reported by Bruno Haible <bruno@clisp.org>.
12219
12220 2009-02-10  Bruno Haible  <bruno@clisp.org>
12221
12222         * lib/unilbrk/lbrktables.h: Renamed from lib/unilbrk/tables.h.
12223         * lib/unilbrk/lbrktables.c: Renamed from lib/unilbrk/tables.c.
12224         * modules/unilbrk/tables (Files, Makefile.am, Include): Update.
12225         * lib/unilbrk/u8-possible-linebreaks.c: Update.
12226         * lib/unilbrk/u16-possible-linebreaks.c: Likewise.
12227         * lib/unilbrk/u32-possible-linebreaks.c: Likewise.
12228
12229 2009-02-09  Simon Josefsson  <simon@josefsson.org>
12230
12231         * lib/sockets.h (gl_fd_to_handle): New function.
12232
12233         * tests/test-sockets.c: Call gl_fd_to_handle.
12234
12235 2009-02-09  Bruno Haible  <bruno@clisp.org>
12236
12237         * doc/havelib.texi: Document the conventions on bi-arch systems.
12238
12239 2009-02-08  Bruno Haible  <bruno@clisp.org>
12240
12241         Document the AC_LIB_LINKFLAGS macro.
12242         * doc/havelib.texi: New file, mostly written on 2005-05-24.
12243         * doc/gnulib.texi: Include it.
12244
12245 2009-02-08  Bruno Haible  <bruno@clisp.org>
12246
12247         Fix wrong order of sections, compared to TOC.
12248         * doc/gnulib.texi: Include relocatable-maint.texi after the
12249         "Regular expressions" node, not before.
12250
12251 2009-02-08  Bruno Haible  <bruno@clisp.org>
12252
12253         Tests for module 'unicase/totitle'.
12254         * modules/unicase/totitle-tests: New file.
12255
12256         Tests for module 'unicase/tolower'.
12257         * modules/unicase/tolower-tests: New file.
12258
12259         Tests for module 'unicase/toupper'.
12260         * modules/unicase/toupper-tests: New file.
12261         * tests/unicase/test-mapping-part1.h: New file.
12262         * tests/unicase/test-mapping-part2.h: New file.
12263
12264         New module 'unicase/totitle'.
12265         * modules/unicase/totitle: New file.
12266         * lib/unicase/totitle.c: New file.
12267
12268         New module 'unicase/tolower'.
12269         * modules/unicase/tolower: New file.
12270         * lib/unicase/tolower.c: New file.
12271
12272         New module 'unicase/toupper'.
12273         * modules/unicase/toupper: New file.
12274         * lib/unicase/toupper.c: New file.
12275         * lib/unicase/simple-mapping.h: New file.
12276
12277         * lib/gen-uni-tables.c (output_simple_mapping_test): New function.
12278         (mapping_table): New structure.
12279         (output_simple_mapping): New function.
12280         (main): Invoke output_simple_mapping_test and output_simple_mapping.
12281         * modules/gen-uni-tables (Description): Update.
12282         * lib/unicase/toupper.h: New file, automatically generated by
12283         gen-uni-tables.
12284         * lib/unicase/tolower.h: New file, automatically generated by
12285         gen-uni-tables.
12286         * lib/unicase/totitle.h: New file, automatically generated by
12287         gen-uni-tables.
12288         * tests/unicase/test-uc_toupper.c: New file, automatically generated by
12289         gen-uni-tables.
12290         * tests/unicase/test-uc_tolower.c: New file, automatically generated by
12291         gen-uni-tables.
12292         * tests/unicase/test-uc_totitle.c: New file, automatically generated by
12293         gen-uni-tables.
12294
12295         New module 'unicase/base'.
12296         * modules/unicase/base: New file.
12297         * lib/unicase.h: New file.
12298
12299 2009-02-08  Bruno Haible  <bruno@clisp.org>
12300
12301         New module 'uniwbrk/ulc-wordbreaks'.
12302         * modules/uniwbrk/ulc-wordbreaks: New file.
12303         * lib/uniwbrk/ulc-wordbreaks.c: New file.
12304
12305         New module 'uniwbrk/u32-wordbreaks'.
12306         * modules/uniwbrk/u32-wordbreaks: New file.
12307         * lib/uniwbrk/u32-wordbreaks.c: New file.
12308
12309         New module 'uniwbrk/u16-wordbreaks'.
12310         * modules/uniwbrk/u16-wordbreaks: New file.
12311         * lib/uniwbrk/u16-wordbreaks.c: New file.
12312
12313         New module 'uniwbrk/u8-wordbreaks'.
12314         * modules/uniwbrk/u8-wordbreaks: New file.
12315         * lib/uniwbrk/u8-wordbreaks.c: New file.
12316         * lib/uniwbrk/u-wordbreaks.h: New file.
12317
12318         New module 'uniwbrk/table'.
12319         * modules/uniwbrk/table: New file.
12320         * lib/uniwbrk/wbrktable.h: New file.
12321         * lib/uniwbrk/wbrktable.c: New file.
12322
12323         New module 'uniwbrk/wordbreak-property'.
12324         * modules/uniwbrk/wordbreak-property: New file.
12325         * lib/uniwbrk/wordbreak-property.c: New file.
12326
12327         * lib/gen-uni-tables.c (WBP_*): New enum items.
12328         (get_wbp, debug_output_wbp, debug_output_wbrk_tables): New functions.
12329         (unicode_org_wbp): New variable.
12330         (fill_org_wbp, debug_output_org_wbp, debug_output_org_wbrk_tables):
12331         New functions.
12332         (wbp_table): New structure.
12333         (output_wbp, output_wbrk_tables): New functions.
12334         (main): Accept additional argument. Invoke fill_org_wbp,
12335         debug_output_wbrk_tables, debug_output_org_wbrk_tables,
12336         output_wbrk_tables.
12337         * modules/gen-uni-tables (Description): Update.
12338         * lib/uniwbrk/wbrkprop.h: New file, automatically generated by
12339         gen-uni-tables.
12340
12341         New module 'uniwbrk/base'.
12342         * modules/uniwbrk/base: New file.
12343         * lib/uniwbrk.h: New file.
12344
12345 2009-02-08  Bruno Haible  <bruno@clisp.org>
12346
12347         Update to Unicode 5.1.0.
12348         * lib/gen-uni-tables.c (is_property_alphabetic): Include
12349         U+2185..U+2188.
12350         (is_property_default_ignorable_code_point): Don't include characters
12351         of category Cc or Cs and not-a-characters.
12352         (get_lbp): Assume REVISION_22. Special handling of U+0609, U+060A,
12353         U+0D79, U+109E, U+109F, U+A60C.
12354         * lib/unictype/bidi_of.h: Regenerated.
12355         * lib/unictype/blocks.h: Regenerated.
12356         * lib/unictype/categ_C.h: Regenerated.
12357         * lib/unictype/categ_Cf.h: Regenerated.
12358         * lib/unictype/categ_Cn.h: Regenerated.
12359         * lib/unictype/categ_L.h: Regenerated.
12360         * lib/unictype/categ_Ll.h: Regenerated.
12361         * lib/unictype/categ_Lm.h: Regenerated.
12362         * lib/unictype/categ_Lo.h: Regenerated.
12363         * lib/unictype/categ_Lu.h: Regenerated.
12364         * lib/unictype/categ_M.h: Regenerated.
12365         * lib/unictype/categ_Mc.h: Regenerated.
12366         * lib/unictype/categ_Me.h: Regenerated.
12367         * lib/unictype/categ_Mn.h: Regenerated.
12368         * lib/unictype/categ_N.h: Regenerated.
12369         * lib/unictype/categ_Nd.h: Regenerated.
12370         * lib/unictype/categ_Nl.h: Regenerated.
12371         * lib/unictype/categ_No.h: Regenerated.
12372         * lib/unictype/categ_P.h: Regenerated.
12373         * lib/unictype/categ_Pd.h: Regenerated.
12374         * lib/unictype/categ_Pe.h: Regenerated.
12375         * lib/unictype/categ_Pf.h: Regenerated.
12376         * lib/unictype/categ_Pi.h: Regenerated.
12377         * lib/unictype/categ_Po.h: Regenerated.
12378         * lib/unictype/categ_Ps.h: Regenerated.
12379         * lib/unictype/categ_S.h: Regenerated.
12380         * lib/unictype/categ_Sk.h: Regenerated.
12381         * lib/unictype/categ_Sm.h: Regenerated.
12382         * lib/unictype/categ_So.h: Regenerated.
12383         * lib/unictype/categ_of.h: Regenerated.
12384         * lib/unictype/combining.h: Regenerated.
12385         * lib/unictype/ctype_alnum.h: Regenerated.
12386         * lib/unictype/ctype_alpha.h: Regenerated.
12387         * lib/unictype/ctype_graph.h: Regenerated.
12388         * lib/unictype/ctype_lower.h: Regenerated.
12389         * lib/unictype/ctype_print.h: Regenerated.
12390         * lib/unictype/ctype_punct.h: Regenerated.
12391         * lib/unictype/ctype_upper.h: Regenerated.
12392         * lib/unictype/decdigit.h: Regenerated.
12393         * lib/unictype/digit.h: Regenerated.
12394         * lib/unictype/mirror.h: Regenerated.
12395         * lib/unictype/numeric.h: Regenerated.
12396         * lib/unictype/pr_alphabetic.h: Regenerated.
12397         * lib/unictype/pr_bidi_arabic_digit.h: Regenerated.
12398         * lib/unictype/pr_bidi_arabic_right_to_left.h: Regenerated.
12399         * lib/unictype/pr_bidi_boundary_neutral.h: Regenerated.
12400         * lib/unictype/pr_bidi_eur_num_terminator.h: Regenerated.
12401         * lib/unictype/pr_bidi_left_to_right.h: Regenerated.
12402         * lib/unictype/pr_bidi_non_spacing_mark.h: Regenerated.
12403         * lib/unictype/pr_bidi_other_neutral.h: Regenerated.
12404         * lib/unictype/pr_combining.h: Regenerated.
12405         * lib/unictype/pr_dash.h: Regenerated.
12406         * lib/unictype/pr_decimal_digit.h: Regenerated.
12407         * lib/unictype/pr_default_ignorable_code_point.h: Regenerated.
12408         * lib/unictype/pr_deprecated.h: Regenerated.
12409         * lib/unictype/pr_diacritic.h: Regenerated.
12410         * lib/unictype/pr_extender.h: Regenerated.
12411         * lib/unictype/pr_format_control.h: Regenerated.
12412         * lib/unictype/pr_grapheme_base.h: Regenerated.
12413         * lib/unictype/pr_grapheme_extend.h: Regenerated.
12414         * lib/unictype/pr_grapheme_link.h: Regenerated.
12415         * lib/unictype/pr_id_continue.h: Regenerated.
12416         * lib/unictype/pr_id_start.h: Regenerated.
12417         * lib/unictype/pr_ideographic.h: Regenerated.
12418         * lib/unictype/pr_ignorable_control.h: Regenerated.
12419         * lib/unictype/pr_lowercase.h: Regenerated.
12420         * lib/unictype/pr_math.h: Regenerated.
12421         * lib/unictype/pr_numeric.h: Regenerated.
12422         * lib/unictype/pr_other_alphabetic.h: Regenerated.
12423         * lib/unictype/pr_other_default_ignorable_code_point.h: Regenerated.
12424         * lib/unictype/pr_other_grapheme_extend.h: Regenerated.
12425         * lib/unictype/pr_other_id_continue.h: Regenerated.
12426         * lib/unictype/pr_other_lowercase.h: Regenerated.
12427         * lib/unictype/pr_other_math.h: Regenerated.
12428         * lib/unictype/pr_punctuation.h: Regenerated.
12429         * lib/unictype/pr_sentence_terminal.h: Regenerated.
12430         * lib/unictype/pr_soft_dotted.h: Regenerated.
12431         * lib/unictype/pr_terminal_punctuation.h: Regenerated.
12432         * lib/unictype/pr_unassigned_code_value.h: Regenerated.
12433         * lib/unictype/pr_unified_ideograph.h: Regenerated.
12434         * lib/unictype/pr_uppercase.h: Regenerated.
12435         * lib/unictype/pr_xid_continue.h: Regenerated.
12436         * lib/unictype/pr_xid_start.h: Regenerated.
12437         * lib/unictype/pr_zero_width.h: Regenerated.
12438         * lib/unictype/scripts.h: Regenerated.
12439         * lib/unictype/scripts_byname.gperf: Regenerated.
12440         * lib/unictype/sy_java_ident.h: Regenerated.
12441         * lib/unilbrk/lbrkprop1.h: Regenerated.
12442         * lib/unilbrk/lbrkprop2.h: Regenerated.
12443         * tests/unictype/test-categ_C.c: Regenerated.
12444         * tests/unictype/test-categ_Cf.c: Regenerated.
12445         * tests/unictype/test-categ_Cn.c: Regenerated.
12446         * tests/unictype/test-categ_L.c: Regenerated.
12447         * tests/unictype/test-categ_Ll.c: Regenerated.
12448         * tests/unictype/test-categ_Lm.c: Regenerated.
12449         * tests/unictype/test-categ_Lo.c: Regenerated.
12450         * tests/unictype/test-categ_Lu.c: Regenerated.
12451         * tests/unictype/test-categ_M.c: Regenerated.
12452         * tests/unictype/test-categ_Mc.c: Regenerated.
12453         * tests/unictype/test-categ_Me.c: Regenerated.
12454         * tests/unictype/test-categ_Mn.c: Regenerated.
12455         * tests/unictype/test-categ_N.c: Regenerated.
12456         * tests/unictype/test-categ_Nd.c: Regenerated.
12457         * tests/unictype/test-categ_Nl.c: Regenerated.
12458         * tests/unictype/test-categ_No.c: Regenerated.
12459         * tests/unictype/test-categ_P.c: Regenerated.
12460         * tests/unictype/test-categ_Pd.c: Regenerated.
12461         * tests/unictype/test-categ_Pe.c: Regenerated.
12462         * tests/unictype/test-categ_Pf.c: Regenerated.
12463         * tests/unictype/test-categ_Pi.c: Regenerated.
12464         * tests/unictype/test-categ_Po.c: Regenerated.
12465         * tests/unictype/test-categ_Ps.c: Regenerated.
12466         * tests/unictype/test-categ_S.c: Regenerated.
12467         * tests/unictype/test-categ_Sk.c: Regenerated.
12468         * tests/unictype/test-categ_Sm.c: Regenerated.
12469         * tests/unictype/test-categ_So.c: Regenerated.
12470         * tests/unictype/test-ctype_alnum.c: Regenerated.
12471         * tests/unictype/test-ctype_alpha.c: Regenerated.
12472         * tests/unictype/test-ctype_graph.c: Regenerated.
12473         * tests/unictype/test-ctype_lower.c: Regenerated.
12474         * tests/unictype/test-ctype_print.c: Regenerated.
12475         * tests/unictype/test-ctype_punct.c: Regenerated.
12476         * tests/unictype/test-ctype_upper.c: Regenerated.
12477         * tests/unictype/test-decdigit.h: Regenerated.
12478         * tests/unictype/test-digit.h: Regenerated.
12479         * tests/unictype/test-numeric.h: Regenerated.
12480         * tests/unictype/test-pr_alphabetic.c: Regenerated.
12481         * tests/unictype/test-pr_bidi_arabic_digit.c: Regenerated.
12482         * tests/unictype/test-pr_bidi_arabic_right_to_left.c: Regenerated.
12483         * tests/unictype/test-pr_bidi_boundary_neutral.c: Regenerated.
12484         * tests/unictype/test-pr_bidi_eur_num_terminator.c: Regenerated.
12485         * tests/unictype/test-pr_bidi_left_to_right.c: Regenerated.
12486         * tests/unictype/test-pr_bidi_non_spacing_mark.c: Regenerated.
12487         * tests/unictype/test-pr_bidi_other_neutral.c: Regenerated.
12488         * tests/unictype/test-pr_combining.c: Regenerated.
12489         * tests/unictype/test-pr_dash.c: Regenerated.
12490         * tests/unictype/test-pr_decimal_digit.c: Regenerated.
12491         * tests/unictype/test-pr_default_ignorable_code_point.c: Regenerated.
12492         * tests/unictype/test-pr_deprecated.c: Regenerated.
12493         * tests/unictype/test-pr_diacritic.c: Regenerated.
12494         * tests/unictype/test-pr_extender.c: Regenerated.
12495         * tests/unictype/test-pr_format_control.c: Regenerated.
12496         * tests/unictype/test-pr_grapheme_base.c: Regenerated.
12497         * tests/unictype/test-pr_grapheme_extend.c: Regenerated.
12498         * tests/unictype/test-pr_grapheme_link.c: Regenerated.
12499         * tests/unictype/test-pr_id_continue.c: Regenerated.
12500         * tests/unictype/test-pr_id_start.c: Regenerated.
12501         * tests/unictype/test-pr_ideographic.c: Regenerated.
12502         * tests/unictype/test-pr_ignorable_control.c: Regenerated.
12503         * tests/unictype/test-pr_lowercase.c: Regenerated.
12504         * tests/unictype/test-pr_math.c: Regenerated.
12505         * tests/unictype/test-pr_numeric.c: Regenerated.
12506         * tests/unictype/test-pr_other_alphabetic.c: Regenerated.
12507         * tests/unictype/test-pr_other_default_ignorable_code_point.c:
12508         Regenerated.
12509         * tests/unictype/test-pr_other_grapheme_extend.c: Regenerated.
12510         * tests/unictype/test-pr_other_id_continue.c: Regenerated.
12511         * tests/unictype/test-pr_other_lowercase.c: Regenerated.
12512         * tests/unictype/test-pr_other_math.c: Regenerated.
12513         * tests/unictype/test-pr_punctuation.c: Regenerated.
12514         * tests/unictype/test-pr_sentence_terminal.c: Regenerated.
12515         * tests/unictype/test-pr_soft_dotted.c: Regenerated.
12516         * tests/unictype/test-pr_terminal_punctuation.c: Regenerated.
12517         * tests/unictype/test-pr_unassigned_code_value.c: Regenerated.
12518         * tests/unictype/test-pr_unified_ideograph.c: Regenerated.
12519         * tests/unictype/test-pr_uppercase.c: Regenerated.
12520         * tests/unictype/test-pr_xid_continue.c: Regenerated.
12521         * tests/unictype/test-pr_xid_start.c: Regenerated.
12522         * tests/unictype/test-pr_zero_width.c: Regenerated.
12523
12524         Update to Unicode 5.1.0.
12525         * lib/uniwidth/width.c (nonspacing_table_data): Add U+0487,
12526         U+0616..U+061A, U+0A51, U+0A75, U+0B44, U+0B62..U+0B63, U+0C62..U+0C63,
12527         U+0D44, U+0D62..U+0D63, U+1033..U+1035, U+103A, U+103D..U+103E,
12528         U+105E..U+1060, U+1071..U+1074, U+1082, U+1085..U+1086, U+108D,
12529         U+1B80..U+1B81, U+1BA2..U+1BA5, U+1BA8..U+1BA9, U+1C2C..U+1C33,
12530         U+1C36..U+1C37, U+1DCB..U+1DE6, U+2064, U+20F0, U+2DE0..U+2DFF,
12531         U+A66F..U+A672, U+A67C..U+A67D, U+A8C4, U+A926..U+A92D, U+A947..U+A951,
12532         U+AA29..U+AA2E, U+AA31..U+AA32, U+AA35..U+AA36, U+AA43, U+AA4C,
12533         U+FE24..U+FE26, U+101FD. Remove U+1929..U+192B.
12534         (nonspacing_table_ind): Update.
12535         * tests/uniwidth/test-uc_width2.sh: Update expected result.
12536
12537         Update to Unicode 5.1.0.
12538         * lib/uniname/gen-uninames.lisp (main): Add the range 0x1Fxxx to the
12539         code transform.
12540         * lib/uniname/uniname.c (unicode_character_name,
12541         unicode_name_character): Add the range 0x1Fxxx to the code transform.
12542         * lib/uniname/uninames.h: Regenerated.
12543         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.1.0.
12544
12545 2009-02-07  Bruno Haible  <bruno@clisp.org>
12546
12547         Merge gen-ctype and gen-lbrk into a single program.
12548         * lib/gen-uni-tables.c: New file, incorporating
12549         lib/unictype/gen-ctype.c and lib/unilbrk/gen-lbrk.c.
12550         Add directory prefixes to the names of the generated files.
12551         * lib/unictype/gen-ctype.c: Remove file.
12552         * lib/unilbrk/gen-lbrk.c: Remove file.
12553         * modules/gen-uni-tables: New file.
12554         * modules/unictype/gen-ctype: Remove file.
12555         * modules/unilbrk/gen-lbrk: Remove file.
12556
12557 2009-02-07  Bruno Haible  <bruno@clisp.org>
12558
12559         * lib/unistr.h (u8_strcoll, u16_strcoll, u32_strcoll): New declations.
12560
12561         New module 'unistr/u32-strcoll'.
12562         * modules/unistr/u32-strcoll: New file.
12563         * lib/unistr/u32-strcoll.c: New file.
12564
12565         New module 'unistr/u16-strcoll'.
12566         * modules/unistr/u16-strcoll: New file.
12567         * lib/unistr/u16-strcoll.c: New file.
12568
12569         New module 'unistr/u8-strcoll'.
12570         * modules/unistr/u8-strcoll: New file.
12571         * lib/unistr/u8-strcoll.c: New file.
12572         * lib/unistr/u-strcoll.h: New file.
12573
12574 2009-02-07  Bruno Haible  <bruno@clisp.org>
12575
12576         * test-mbrtowc4.sh (LOCALE_ZH_CN): Fix default value.
12577         * test-mbsnrtowcs4.sh (LOCALE_ZH_CN): Likewise.
12578         * test-mbsrtowcs4.sh (LOCALE_ZH_CN): Likewise.
12579         * test-wcrtomb.sh (LOCALE_ZH_CN): Likewise.
12580         * test-wcsnrtombs4.sh (LOCALE_ZH_CN): Likewise.
12581         * test-wcsrtombs4.sh (LOCALE_ZH_CN): Likewise.
12582
12583 2009-02-07  Bruno Haible  <bruno@clisp.org>
12584
12585         Make 64-bit clean.
12586         * lib/unictype/gen-ctype.c (output_predicate, output_category,
12587         output_combclass, output_bidi_category, output_decimal_digit,
12588         output_digit, output_numeric, output_mirror, output_scripts,
12589         output_ident_category): Use proper width specifier in format strings.
12590
12591 2009-02-07  Bruno Haible  <bruno@clisp.org>
12592
12593         * doc/posix-functions/dirfd.texi: Clarify situation on mingw. Document
12594         failure behaviour.
12595
12596 2009-02-07  Jim Meyering  <meyering@redhat.com>
12597
12598         regex: avoid compilation failure with upcoming gcc-4.4
12599         * lib/regex_internal.h: Revert e48d8b47fb3eee81d341b71c3e006efe9e3433a7
12600         [workaround for PGC prior to 6.1-2].  Otherwise, we'd get this:
12601         "... error: integer overflow in preprocessor expression".
12602
12603 2009-02-05  Ben Pfaff  <blp@gnu.org>
12604
12605         Fix link errors on Windows when close module is used.
12606         * modules/close: Add $(LIB_CLOSE) to Link section.
12607         * m4/close.m4 (gl_REPLACE_CLOSE): Substitute -lws2_32 into
12608         $(LIB_CLOSE) on Windows.
12609
12610 2009-02-05  Jim Meyering  <meyering@redhat.com>
12611
12612         still avoid unused-parameter warnings, but do it cleanly
12613         * lib/fsusage.c (UNUSED_PARAM): Remove definition.
12614         (get_fs_usage): Cast to void instead.
12615         * lib/mountlist.c (UNUSED_PARAM): Remove definition.
12616         (dev_from_mount_options, read_file_system_list): Cast to void.
12617         Prompted by Bruno Haible.
12618
12619 2009-02-04  Jim Meyering  <meyering@redhat.com>
12620
12621         fsusage.c: correct copyright year
12622         * lib/fsusage.c: Reflect year in which the change is pushed into
12623
12624         avoid misc. warnings
12625         * lib/fsusage.c (UNUSED_PARAM): Define.
12626         (get_fs_usage): Mark parameter "disk" as unused.
12627         * lib/getugroups.c (getgrent): Use "void" in prototype.
12628         * lib/mountlist.c: Mark unused parameters.
12629         (read_file_system_list): Declare a local with "const".
12630         * lib/nanosleep.c (getnow): Declare static.
12631         * lib/strftime.c: Include strftime.h, for declaration of nstrftime.
12632
12633         dirfd: set errno upon failure
12634         * lib/dirfd.c: Include <errno.h>.
12635         Set errno to ENOTSUP when returning -1.
12636         * modules/dirfd (Depends-on): Add errno.
12637         Suggested by John Kodis <kodis@comcast.net>.
12638
12639 2009-02-01  Bruno Haible  <bruno@clisp.org>
12640
12641         Don't assume sizeof (long) >= sizeof (void *).
12642         * lib/memcmp.c: Include stdint.h.
12643         (memcmp_bytes): Change argument types to op_t. Change type of srcp1,
12644         srcp2 to 'const byte *'.
12645         (memcmp_common_alignment, memcmp_not_common_alignment): Change argument
12646         types to uintptr_t.
12647         (rpl_memcmp): Change type of srcp1, srcp2 to 'uintptr_t'.
12648         * modules/memcmp (Depends-on): Add stdint.
12649         Reported by Ozkan Sezer <sezeroz@gmail.com>.
12650
12651 2009-01-30  Eric Blake  <ebb9@byu.net>
12652
12653         fix more require-before-expand issues
12654         * m4/pmccabe2html.m4 (gl_PMCCABE2HTML): Require, rather than
12655         expand, AC_PROG_AWK.
12656         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): Use AC_DEFUN_ONCE.
12657
12658 2009-01-28  Eric Blake  <ebb9@byu.net>
12659
12660         version-etc: use consistent URL formatting
12661         * lib/version-etc.c (emit_bug_reporting_address, version_etc_va):
12662         Improve formatting.  Use fputs for string without %.
12663
12664 2009-01-28  Jim Meyering  <meyering@redhat.com>
12665
12666         00gnulib.m4: add m4 quotes in shell comment to avoid autoconf warning
12667         * m4/00gnulib.m4 (AC_DEFUN_ONCE): Add quotes to avoid an
12668         "underquoted definition of NAME" from autoconf-2.59.
12669
12670 2009-01-28  Bruno Haible  <bruno@clisp.org>
12671
12672         * doc/gnulib.texi: Add "Obsolete modules" to index.
12673
12674 2009-01-28  Jim Meyering  <meyering@redhat.com>
12675
12676         useless-if-before-free: recognize more variants
12677         * build-aux/useless-if-before-free: Also recognize e.g.,
12678         if (NULL != p) free (p);
12679
12680 2009-01-27  Mark McLoughlin  <markmc@redhat.com>
12681
12682         test-getaddrinfo: skip (don't fail) this test when there's no network
12683         * tests/test-getaddrinfo.c: Skip test upon failure with EAI_AGAIN,
12684         on the presumption that it means you lack network access.
12685
12686 2009-01-26  Jim Meyering  <meyering@redhat.com>
12687
12688         fflush: avoid warnings on modern systems
12689         * lib/fflush.c (rpl_fflush): Move declarations of locals,
12690         pos and result, into scopes where they're used.
12691
12692 2009-01-26  Eric Blake  <ebb9@byu.net>
12693
12694         Silence warning reintroduced by recent extensions patch.
12695         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS)
12696         (gl_USE_SYSTEM_EXTENSIONS): Use AC_DEFUN_ONCE to silence newer
12697         autoconf.
12698
12699         Backport improved autoconf semantics of AC_DEFUN_ONCE.
12700         * m4/00gnulib.m4: New file.
12701         * gnulib-tool (func_get_filelist): Always use it.
12702         * m4/gnulib-common.m4 (gl_COMMON): Force the file to be used.
12703         Reported by Bruno Haible, with suggestions from Paolo Bonzini.
12704
12705 2009-01-25  Bruno Haible  <bruno@clisp.org>
12706
12707         Make test-quotearg work on MacOS X and AIX.
12708         * tests/test-quotearg.sh: New file.
12709         * tests/locale/fr/LC_MESSAGES/test-quotearg.po: New file.
12710         * tests/locale/fr/LC_MESSAGES/test-quotearg.mo: New file.
12711         * tests/test-quotearg.c: Include <locale.h> and gettext.h. Don't
12712         include <libintl.h>.
12713         (fake_locale): Remove variable.
12714         (gettext, dgettext, dcgettext): Remove functions.
12715         (main): Instead of setting a fake locale, set a real locale. Call
12716         textdomain and bindtextdomain.
12717         * modules/quotearg-tests (Files): Add the new files.
12718         (Depends-on): Add gettext, setenv, unsetenv.
12719         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
12720         (Makefile.am): Add test-quotearg.sh to TESTS, remove test-quotearg.
12721         Augment TESTS_ENVIRONMENT.
12722
12723 2009-01-25  Bruno Haible  <bruno@clisp.org>
12724
12725         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove special code that hid the
12726         fr_FR.ISO8859-1 locale on MacOS X.
12727         * m4/locale-ja.m4 (gt_LOCALE_JA): Remove special code that hid the
12728         ja_JP.eucJP locale on MacOS X.
12729         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Remove special code that hid the
12730         zh_CN.GB18030 locale on MacOS X.
12731
12732 2009-01-25  Bruno Haible  <bruno@clisp.org>
12733
12734         Avoid link errors on MacOS X 10.3.
12735         * lib/mbsrtowcs-state.c (_gl_mbsrtowcs_state): Add initializer.
12736         * lib/wcsrtombs-state.c (_gl_wcsrtombs_state): Likewise.
12737
12738 2009-01-25  Bruno Haible  <bruno@clisp.org>
12739
12740         * lib/pipe.c: On Unix, assume HAVE_POSIX_SPAWN and use posix_spawnp.
12741         * m4/pipe.m4 (gl_PIPE): Remove tests for vfork() based code.
12742         * modules/pipe (Files): Remove m4/posix_spawn.m4.
12743         (Depends-on): Add spawn, posix_spawnp, posix_spawn_file_actions_init,
12744         posix_spawn_file_actions_addclose, posix_spawn_file_actions_adddup2,
12745         posix_spawn_file_actions_addopen, posix_spawn_file_actions_destroy,
12746         posix_spawnattr_init, posix_spawnattr_setsigmask,
12747         posix_spawnattr_setflags, posix_spawnattr_destroy.
12748
12749         * lib/execute.c: On Unix, assume HAVE_POSIX_SPAWN and use posix_spawnp.
12750         * m4/execute.m4 (gl_EXECUTE): Remove tests for vfork() based code.
12751         * modules/execute (Files): Remove m4/posix_spawn.m4.
12752         (Depends-on): Add spawn, posix_spawnp, posix_spawn_file_actions_init,
12753         posix_spawn_file_actions_addopen, posix_spawn_file_actions_destroy,
12754         posix_spawnattr_init, posix_spawnattr_setsigmask,
12755         posix_spawnattr_setflags, posix_spawnattr_destroy.
12756
12757 2009-01-25  Bruno Haible  <bruno@clisp.org>
12758
12759         * lib/glthread/threadlib.c: Include <stdlib.h>.
12760
12761 2009-01-25  Bruno Haible  <bruno@clisp.org>
12762
12763         * lib/glthread/threadlib.c (dummy): New declaration.
12764
12765 2009-01-25  Bruno Haible  <bruno@clisp.org>
12766
12767         * lib/mbrtowc.c (mbrtowc): Distinguish invalid and incomplete
12768         multibyte characters also for the GB18030 encoding. Don't crash when
12769         the encoding is unknown and nstate = 0. Needed on OSF/1 5.1.
12770
12771 2009-01-25  Bruno Haible  <bruno@clisp.org>
12772
12773         Avoid redefining 'struct random_data' on OSF/1 5.1.
12774         * lib/stdlib.in.h: Include <random.h> if it exists.
12775         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether <random.h> exists. Set
12776         HAVE_RANDOM_H. Include <random.h> when testing whether
12777         'struct random_data' exists.
12778         * modules/stdlib (Makefile.am): Substitute HAVE_RANDOM_H.
12779
12780 2009-01-25  Bruno Haible  <bruno@clisp.org>
12781
12782         Don't install charset.alias on MacOS X >= 10.3.
12783         * lib/localcharset.c (DARWIN7): New macro.
12784         (get_charset_aliases): Hardcode the result for Darwin7.
12785         * modules/localcharset (install-exec-local): Don't install
12786         charset.alias on MacOS X >= 10.3, if the file does not yet exist.
12787
12788 2009-01-25  Bruno Haible  <bruno@clisp.org>
12789
12790         Don't install charset.alias on mingw and Cygwin.
12791         * modules/localcharset (install-exec-local): Don't install
12792         charset.alias on mingw and Cygwin, if the file does not yet exist.
12793         The result for these platforms is hardcoded in localcharset.c.
12794
12795 2009-01-25  Bruno Haible  <bruno@clisp.org>
12796
12797         Make it possible again to use AC_GNU_SOURCE together with gnulib.
12798         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_GNU_SOURCE
12799         before requiring AC_USE_SYSTEM_EXTENSIONS.
12800
12801 2009-01-25  Jim Meyering  <meyering@redhat.com>
12802
12803         c-strtod: avoid warnings
12804         * lib/c-strtod.c (C_STRTOD): Cast nptr to (char *) to avoid
12805         "assignment discards qualifiers from pointer target type" warnings.
12806
12807 2009-01-24  Bruno Haible  <bruno@clisp.org>
12808
12809         Add support for non-UTF-8 locales on MacOS X.
12810         * lib/config.charset: Add CP1131, ARMSCII-8, PT154 to the list of
12811         canonical encodings. For Darwin 7 and newer, don't map traditional
12812         encodings to UTF-8.
12813         Reported by Vincent Lefevre <vincent@vinc17.org>
12814         at <http://savannah.gnu.org/bugs/?25235>.
12815
12816 2009-01-24  Bruno Haible  <bruno@clisp.org>
12817
12818         * doc/gnulib.texi (Obsolete modules): New section.
12819         Reported by Mike Frysinger <vapier@gentoo.org>.
12820
12821 2009-01-24  Bruno Haible  <bruno@clisp.org>
12822
12823         * doc/Makefile (%.pdf): Clarify where to find texmf.cnf.
12824         (%.dvi): New rule.
12825
12826 2009-01-24  Bruno Haible  <bruno@clisp.org>
12827
12828         * lib/c-strtod.h (c_strtod, c_strtold): Adjust specification.
12829         Reported by Eric Blake.
12830
12831 2009-01-24  Bruno Haible  <bruno@clisp.org>
12832
12833         * lib/c-stack.c (segv_handler): If !HAVE_XSI_STACK_OVERFLOW_HEURISTIC,
12834         set signo = 0 also if info->si_code <= 0. Needed on HP-UX 11.11.
12835         Reported by Gary V. Vaughan <gary@gnu.org>.
12836
12837 2009-01-24  Bruno Haible  <bruno@clisp.org>
12838
12839         * lib/c-strtod.h (c_strtod, c_strtold): Add specification.
12840
12841 2009-01-23  Bruno Haible  <bruno@clisp.org>
12842
12843         Make c-strtod, c-strtold usable in libraries.
12844         * lib/c-strtod.c: Include string.h instead of xalloc.h.
12845         (C_STRTOD): Call strdup instead of xstrdup.
12846         * modules/c-strtod (Depends-on): Add strdup-posix, remove xalloc.
12847         * modules/c-strtold (Depends-on): Likewise.
12848         * doc/c-strtod.texi: Remove the sentence mentioning xalloc_die.
12849         * NEWS: Mention the change.
12850         Reported by Michael Gold <mgold@ncf.ca>.
12851
12852 2009-01-23  Jim Meyering  <meyering@redhat.com>
12853
12854         c-strtod: when ENDPTR is non-NULL, set *ENDPTR in new failure path
12855         * lib/c-strtod.c (C_STRTOD) [LC_ALL_MASKC]: Ensure that when
12856         ENDPTR is non-NULL, *ENDPTR is set to NPTR upon failure.
12857
12858 2009-01-23  Simon Josefsson  <simon@josefsson.org>
12859
12860         * lib/version-etc.c: Add emit_bug_reporting_address, inspired by
12861         GNU CoreUtils.
12862         * lib/version-etc.h: Add prototype for emit_bug_reporting_address.
12863         * modules/version-etc (Description): Update.
12864
12865 2009-01-22  Bruno Haible  <bruno@clisp.org>
12866
12867         Cache the C locale object.
12868         * lib/c-strtod.c (c_locale_cache): New variable.
12869         (c_locale): New function.
12870         (C_STRTOD): Use it, and don't call freelocale.
12871         * m4/c-strtod.m4 (gl_C_STRTOD, gl_C_STRTOLD): Require AC_C_INLINE.
12872         Suggested by Paolo Bonzini.
12873
12874 2009-01-21  Bruno Haible  <bruno@clisp.org>
12875
12876         * lib/getloadavg.c (getloadavg): Check c_strtod result against error
12877         conditions other than overflow.
12878
12879 2009-01-21  Bruno Haible  <bruno@clisp.org>
12880
12881         * lib/c-strtod.c: Include errno.h.
12882         (C_STRTOD): Check against NULL return from newlocale. Preserve errno
12883         value from STRTOD_L and STRTOD.
12884
12885 2009-01-21  Bruno Haible  <bruno@clisp.org>
12886         and Jim Meyering  <meyering@redhat.com>
12887
12888         nanosleep: skip configure test (fail it) for apple universal builds
12889         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_MULTIARCH. In Apple
12890         universal builds, assume that nanosleep does not work.
12891         * modules/nanosleep (Depends-on): Add multiarch.
12892
12893         mktime: skip configure test (fail it) for apple universal builds
12894         * m4/mktime.m4 (AC_FUNC_MKTIME): Require gl_MULTIARCH. In Apple
12895         universal builds, assume that mktime does not work.
12896         * modules/mktime (Depends-on): Add multiarch.
12897
12898 2009-01-21  Eric Blake  <ebb9@byu.net>
12899
12900         multiarch: avoid expand-before-require warning
12901         * modules/multiarch (configure.ac): Require, rather than expand,
12902         gl_MULTIARCH.
12903         * m4/multiarch.m4 (gl_MULTIARCH_BODY): Merge...
12904         (gl_MULTIARCH): ...into this macro, and use AC_DEFUN_ONCE to
12905         enforce that all clients require it.  Partial reversion of
12906         2008-12-29 patch.
12907
12908         error: avoid expand-before-require warning
12909         * modules/errno (configure.ac): Require, rather than expand,
12910         gl_HEADER_ERRNO_H.
12911         * m4/errno_h.m4 (gl_HEADER_ERRNO_H_BODY): Merge...
12912         (gl_HEADER_ERRNO_H): ...into this macro, and use AC_DEFUN_ONCE to
12913         enforce that all clients require it.
12914
12915         gnulib-tool: avoid warnings from using obsolete AC_GNU_SOURCE
12916         * gnulib-tool (func_dest_tmpfilename, func_create_testdir): Using
12917         obsolete AC_GNU_SOURCE causes out-of-order expansion; avoid it,
12918         and rely solely on gl_USE_SYSTEM_EXTENSIONS.
12919
12920 2009-01-21  Paolo Bonzini  <bonzini@gnu.org>
12921
12922         Revert:
12923         2009-01-20  Paolo Bonzini  <bonzini@gnu.org>
12924
12925         regex: do not depend on obsolete modules.
12926         * modules/regex: Remove memcmp and memmove.
12927
12928 2009-01-20  Bruno Haible  <bruno@clisp.org>
12929
12930         Make the 'link' module link on Windows NT 4.
12931         * lib/link.c (_WIN32_WINNT): Don't define.
12932         (CreateHardLinkFuncType): New type.
12933         (CreateHardLinkFunc, initialized): New variables.
12934         (initialize): New function.
12935         (link): Invoke CreateHardLink indirectly through the function pointer.
12936
12937 2009-01-20  Bruno Haible  <bruno@clisp.org>
12938
12939         Fix compilation failure on mingw.
12940         * tests/test-link.c (main): Don't assume that EOPNOTSUPP exists.
12941
12942 2009-01-20  Michael Gold  <mgold@ncf.ca>  (tiny change)
12943
12944         * doc/c-strtod.texi: Mention a couple of restrictions.
12945
12946 2009-01-20  Jim Meyering  <meyering@redhat.com>
12947
12948         gettimeofday: move more declarations out of functions
12949         * lib/gettimeofday.c: Move extern declarations of tzset and
12950         gmtime out of containing functions.  Prompted by Bruno Haible.
12951
12952 2009-01-20  Paolo Bonzini  <bonzini@gnu.org>
12953
12954         regex: do not depend on obsolete modules.
12955         * modules/regex: Remove memcmp and memmove.
12956
12957 2009-01-19  Bruno Haible  <bruno@clisp.org>
12958
12959         Don't use AC_REQUIRE([AC_C_BIGENDIAN]).
12960         * modules/uniconv/u16-conv-from-enc (configure.ac): Require
12961         gl_BIGENDIAN, not AC_C_BIGENDIAN.
12962         * modules/uniconv/u16-conv-to-enc (configure.ac): Likewise.
12963         * modules/uniconv/u16-strconv-to-enc (configure.ac): Likewise.
12964
12965 2009-01-19  Bruno Haible  <bruno@clisp.org>
12966
12967         * tests/test-link.c: Include <errno.h>.
12968         (main): Exit with code 77 when a hard link cannot be created due to
12969         the file system.
12970         * tests/test-link.sh: Skip test when a hard link cannot be created due
12971         to the file system.
12972         Suggested by Eric Blake.
12973
12974 2009-01-19  Martin Lambers  <marlam@marlam.de>
12975
12976         * modules/link-tests: New file.
12977         * tests/test-link.sh: New file.
12978         * tests/test-link.c: New file.
12979
12980 2009-01-19  Eric Blake  <ebb9@byu.net>
12981
12982         doc: mention another function added in cygwin 1.7.0
12983         * doc/glibc-functions/glob_pattern_p.texi (glob_pattern_p):
12984         Another new function in cygwin 1.7.
12985
12986 2009-01-19  Bruno Haible  <bruno@clisp.org>
12987
12988         Don't use AC_REQUIRE([AC_C_BIGENDIAN]).
12989         * m4/gnulib-common.m4 (gl_BIGENDIAN): New macro.
12990         * m4/exponentl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require
12991         gl_BIGENDIAN, not AC_C_BIGENDIAN.
12992         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Likewise.
12993         * m4/isinf.m4 (gl_ISINFL_WORKS): Likewise.
12994         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Likewise.
12995         * m4/md4.m4 (gl_MD4): Likewise.
12996         * m4/md5.m4 (gl_MD5): Likewise.
12997         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Likewise.
12998         * m4/sha1.m4 (gl_SHA1): Likewise.
12999         * m4/sha256.m4 (gl_SHA256): Likewise.
13000         * m4/sha512.m4 (gl_SHA512): Likewise.
13001
13002 2009-01-19  Bruno Haible  <bruno@clisp.org>
13003
13004         * modules/uniname/uniname-tests (Depends-on): Add progname.
13005         * tests/uniname/test-uninames.c: Include progname.h.
13006         (main): Call set_program_name.
13007
13008         * modules/unistdio/u8-vsprintf-tests (Depends-on): Add progname.
13009         * tests/unistdio/test-u8-vsprintf1.c: Include progname.h.
13010         (main): Call set_program_name.
13011
13012         * modules/unistdio/u8-vsnprintf-tests (Depends-on): Add progname.
13013         * tests/unistdio/test-u8-vsnprintf1.c: Include progname.h.
13014         (main): Call set_program_name.
13015
13016         * modules/unistdio/u16-vsprintf-tests (Depends-on): Add progname.
13017         * tests/unistdio/test-u16-vsprintf1.c: Include progname.h.
13018         (main): Call set_program_name.
13019
13020         * modules/unistdio/u16-vsnprintf-tests (Depends-on): Add progname.
13021         * tests/unistdio/test-u16-vsnprintf1.c: Include progname.h.
13022         (main): Call set_program_name.
13023
13024         * modules/unistdio/u32-vsprintf-tests (Depends-on): Add progname.
13025         * tests/unistdio/test-u32-vsprintf1.c: Include progname.h.
13026         (main): Call set_program_name.
13027
13028         * modules/unistdio/u32-vsnprintf-tests (Depends-on): Add progname.
13029         * tests/unistdio/test-u32-vsnprintf1.c: Include progname.h.
13030         (main): Call set_program_name.
13031
13032         * modules/unistdio/ulc-vsprintf-tests (Depends-on): Add progname.
13033         * tests/unistdio/test-ulc-vsprintf1.c: Include progname.h.
13034         (main): Call set_program_name.
13035
13036         * modules/unistdio/ulc-vsnprintf-tests (Depends-on): Add progname.
13037         * tests/unistdio/test-ulc-vsnprintf1.c: Include progname.h.
13038         (main): Call set_program_name.
13039
13040 2009-01-19  Eric Blake  <ebb9@byu.net>
13041
13042         test-unistd: test previous patch
13043         * tests/test-unistd.c: Test *_FILENO macros.
13044
13045         unistd: guarantee STDIN_FILENO here, for OS/2 EMX
13046         * lib/unistd.in.h (STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO):
13047         Guarantee a definition.
13048         * doc/posix-headers/unistd.texi (unistd.h): Document the bug.
13049         * modules/unistd-safer (Depends-on): Add dependency on unistd.
13050         * lib/c-stack.c (STDERR_FILENO): Rely on <unistd.h>.
13051         * lib/dup-safer.c (STDERR_FILENO): Likewise.
13052         * lib/execute.c (STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO):
13053         Likewise.
13054         * lib/fd-safer.c (STDIN_FILENO, STDERR_FILENO): Likewise.
13055         * lib/fopen-safer.c (STDERR_FILENO): Likewise.
13056         * lib/pipe.c (STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO):
13057         Likewise.
13058         * lib/tmpfile-safer.c (STDERR_FILENO): Likewise.
13059         * tests/test-posix_spawn1.c (STDIN_FILENO, STDOUT_FILENO)
13060         (STDERR_FILENO): Likewise.
13061         * tests/test-posix_spawn2.c (STDIN_FILENO, STDOUT_FILENO)
13062         (STDERR_FILENO): Likewise.
13063         * tests/test-posix_spawn3.c (STDIN_FILENO, STDOUT_FILENO)
13064         (STDERR_FILENO): Likewise.
13065         Reported by Elbert Pol.
13066
13067 2009-01-19  Eric Blake  <ebb9@byu.net>
13068
13069         doc: mention more functions added in cygwin 1.7.0
13070         * doc/posix-functions/abort.texi (abort): Update wording related
13071         to cygwin.
13072         * doc/posix-functions/daylight.texi (daylight): Likewise.
13073         * doc/posix-functions/optarg.texi (optarg): Likewise.
13074         * doc/posix-functions/optarg.texi (opterr): Likewise.
13075         * doc/posix-functions/optarg.texi (optind): Likewise.
13076         * doc/posix-functions/optarg.texi (optopt): Likewise.
13077         * doc/posix-functions/wprintf.texi (wprintf): Cygwin wprintf never
13078         worked in 1.5.x, and was withdrawn in 1.7.
13079         * doc/posix-functions/vwprintf.texi (vwprintf): Likewise.
13080         * doc/posix-functions/fprintf.texi (fprintf): Tighten mention of
13081         cygwin versions.
13082         * doc/posix-functions/perror.texi (perror): Likewise.
13083         * doc/posix-functions/printf.texi (printf): Likewise.
13084         * doc/posix-functions/snprintf.texi (snprintf): Likewise.
13085         * doc/posix-functions/sprintf.texi (sprintf): Likewise.
13086         * doc/posix-functions/vfprintf.texi (vfprintf): Likewise.
13087         * doc/posix-functions/vprintf.texi (vprintf): Likewise.
13088         * doc/posix-functions/vsnprintf.texi (vsnprintf): Likewise.
13089         * doc/posix-functions/vsprintf.texi (vsprintf): Likewise.
13090         * doc/glibc-functions/obstack_printf.texi (obstack_printf):
13091         Likewise.
13092         * doc/glibc-functions/obstack_vprintf.texi (obstack_vprintf):
13093         Likewise.
13094         * doc/glibc-functions/cfmakeraw.texi (cfmakeraw): Cygwin 1.7 adds
13095         this function.
13096         * doc/glibc-functions/in6addr_any.texi (in6addr_any): Likewise.
13097         * doc/glibc-functions/in6addr_loopback.texi (in6addr_loopback):
13098         Likewise.
13099         * doc/glibc-functions/updwtmpx.texi (updwtmpx): Likewise.
13100         * doc/posix-functions/_Exit_C99.texi (_Exit): Likewise.
13101         * doc/posix-functions/confstr.texi (confstr): Likewise.
13102         * doc/posix-functions/dprintf.texi (dprintf): Likewise.
13103         * doc/posix-functions/fgetwc.texi (fgetwc): Likewise.
13104         * doc/posix-functions/fgetws.texi (fgetws): Likewise.
13105         * doc/posix-functions/fputwc.texi (fputwc): Likewise.
13106         * doc/posix-functions/fputws.texi (fputws): Likewise.
13107         * doc/posix-functions/fwide.texi (fwide): Likewise.
13108         * doc/posix-functions/getwc.texi (getwc): Likewise.
13109         * doc/posix-functions/getwchar.texi (getwchar): Likewise.
13110         * doc/posix-functions/putwc.texi (putwc): Likewise.
13111         * doc/posix-functions/putwchar.texi (putwchar): Likewise.
13112         * doc/posix-functions/sigignore.texi (sigignore): Likewise.
13113         * doc/posix-functions/ungetwc.texi (ungetwc): Likewise.
13114         * doc/posix-functions/vdprintf.texi (vdprintf): Likewise.
13115         * doc/posix-functions/wcpcpy.texi (wcpcpy): Likewise.
13116         * doc/posix-functions/wcpncpy.texi (wcpncpy): Likewise.
13117         * doc/posix-functions/wcstol.texi (wcstol): Likewise.
13118         * doc/posix-functions/wcstoll.texi (wcstoll): Likewise.
13119         * doc/posix-functions/wcstoul.texi (wcstoul): Likewise.
13120         * doc/posix-functions/wcstoull.texi (wcstoull): Likewise.
13121         * doc/posix-functions/wcsxfrm.texi (wcsxfrm): Likewise.
13122
13123 2009-01-19  Daniel P. Berrange  <berrange@redhat.com>
13124
13125         ioctl: avoid warning: no previous prototype for 'rpl_ioctl'
13126         * lib/ioctl.c: Include <sys/ioctl.h>.
13127
13128 2009-01-19  Simon Josefsson  <simon@josefsson.org>
13129
13130         * modules/getdate-tests (Depends-on): Add progname.
13131         * tests/test-getdate.c: Use progname module, to avoid link errors
13132         on non-glibc systems.
13133
13134 2009-01-18  Simon Josefsson  <simon@josefsson.org>
13135
13136         * modules/filenamecat-tests (Depends-on): Add progname.
13137         * modules/fstrcmp-tests (Depends-on): Likewise.
13138
13139         * tests/test-filenamecat.c: Use progname module, to avoid link
13140         errors on non-glibc systems.
13141         * tests/test-fstrcmp.c: Likewise.
13142
13143 2009-01-19  Daniel P. Berrange  <berrange@redhat.com>
13144
13145         gettimeofday: avoid warning: nested extern declaration of 'localtime'
13146         * lib/gettimeofday.c: Move extern declaration out of function.
13147
13148 2009-01-18  Bruno Haible  <bruno@clisp.org>
13149
13150         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't test for mblen and mbrlen.
13151         * lib/strftime.c (HAVE_MBLEN, HAVE_MBRLEN): Remove macros.
13152         (MULTIBYTE_IS_FORMAT_SAFE): Define to 1 on all platforms except OSF/1.
13153
13154 2009-01-18  Bruno Haible  <bruno@clisp.org>
13155
13156         * lib/strftime.c (MEMPCPY): Remove unused macro.
13157         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't test for mempcpy.
13158
13159 2009-01-18  Martin Lambers  <marlam@marlam.de>
13160
13161         New module 'link'.
13162         * lib/unistd.in.h (link): New declaration.
13163         * lib/link.c: New file.
13164         * m4/link.m4: New file.
13165         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_LINK,
13166         HAVE_LINK.
13167         * modules/unistd (Makefile.am): Substitute GNULIB_LINK, HAVE_LINK.
13168         * modules/link: New file.
13169         * doc/posix-functions/link.texi: Mention the new module.
13170
13171 2009-01-18  Bruno Haible  <bruno@clisp.org>
13172
13173         * tests/test-avltree_list.c (main): Call set_program_name.
13174         * tests/test-avltree_oset.c (main): Likewise.
13175         * tests/test-obstack-printf.c: Include progname.h.
13176         (main): Call set_program_name.
13177         * tests/test-quotearg.c: Include progname.h.
13178         (main): Call set_program_name.
13179         * tests/test-xmemdup0.c: Include progname.h.
13180         (main): Call set_program_name.
13181
13182 2009-01-18  Bruno Haible  <bruno@clisp.org>
13183
13184         New module 'alphasort'.
13185         * lib/dirent.in.h (alphasort): New declaration.
13186         * lib/alphasort.c: New file, from glibc with modifications.
13187         * m4/alphasort.m4: New file.
13188         * modules/alphasort: New file.
13189         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_ALPHASORT,
13190         HAVE_ALPHASORT.
13191         * modules/dirent (Makefile.am): Substitute GNULIB_ALPHASORT,
13192         HAVE_ALPHASORT.
13193         * doc/posix-functions/alphasort.texi: Mention the new module and the
13194         portability problems.
13195
13196 2009-01-18  Bruno Haible  <bruno@clisp.org>
13197
13198         New module 'scandir'.
13199         * lib/dirent.in.h (scandir): New declaration.
13200         * lib/scandir.c: New file, from glibc with modifications.
13201         * m4/scandir.m4: New file.
13202         * modules/scandir: New file.
13203         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_SCANDIR,
13204         HAVE_SCANDIR.
13205         * modules/dirent (Makefile.am): Substitute GNULIB_SCANDIR,
13206         HAVE_SCANDIR.
13207         * doc/posix-functions/scandir.texi: Mention the new module and the
13208         portability problems.
13209
13210 2009-01-17  Bruno Haible  <bruno@clisp.org>
13211
13212         * gnulib-tool (func_remove_prefix): Escape all dots in the prefix.
13213         Update documentation.
13214         (func_remove_suffix): Escape all dots in the suffix. Update
13215         documentation.
13216         (func_filter_filelist): Update documentation.
13217         Reported by Ralf Wildenhues.
13218
13219 2009-01-17  Bruno Haible  <bruno@clisp.org>
13220
13221         * modules/dprintf-posix-tests: New file.
13222         * tests/test-dprintf-posix.sh: New file.
13223         * tests/test-dprintf-posix.c: New file.
13224
13225         New modules 'dprintf', 'dprintf-posix'.
13226         * lib/stdio.in.h (dprintf): New declaration.
13227         * lib/dprintf.c: New file.
13228         * m4/dprintf.m4: New file.
13229         * m4/dprintf-posix.m4: New file.
13230         * modules/dprintf: New file.
13231         * modules/dprintf-posix: New file.
13232         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_DPRINTF,
13233         HAVE_DPRINTF, REPLACE_DPRINTF.
13234         * modules/stdio (Makefile.am): Substitute also GNULIB_DPRINTF,
13235         HAVE_DPRINTF, REPLACE_DPRINTF.
13236         * doc/posix-functions/dprintf.texi: Mention the new modules.
13237
13238 2009-01-17  Bruno Haible  <bruno@clisp.org>
13239
13240         * modules/vdprintf-posix-tests: New file.
13241         * tests/test-vdprintf-posix.sh: New file.
13242         * tests/test-vdprintf-posix.c: New file.
13243
13244         New modules 'vdprintf', 'vdprintf-posix'.
13245         * lib/stdio.in.h (vdprintf): New declaration.
13246         * lib/vdprintf.c: New file.
13247         * m4/vdprintf.m4: New file.
13248         * m4/vdprintf-posix.m4: New file.
13249         * modules/vdprintf: New file.
13250         * modules/vdprintf-posix: New file.
13251         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_VDPRINTF,
13252         HAVE_VDPRINTF, REPLACE_VDPRINTF.
13253         * modules/stdio (Makefile.am): Substitute also GNULIB_VDPRINTF,
13254         HAVE_VDPRINTF, REPLACE_VDPRINTF.
13255         * doc/posix-functions/vdprintf.texi: Mention the new modules.
13256
13257 2009-01-17  Bruno Haible  <bruno@clisp.org>
13258
13259         Fix replacement of fopen on mingw.
13260         * m4/fopen.m4 (gl_FUNC_FOPEN): Define FOPEN_TRAILING_SLASH_BUG also on
13261         mingw.
13262
13263 2009-01-17  Bruno Haible  <bruno@clisp.org>
13264
13265         Fix compilation error on HP-UX 11.00, present since 2008-09-24.
13266         * lib/fopen.c: Include <sys/types.h> and <sys/types.h>.
13267
13268 2009-01-17  Bruno Haible  <bruno@clisp.org>
13269
13270         Avoid test-fflush2.sh failure on mingw.
13271         * tests/test-fflush2.c: Include binary-io.h.
13272         (main): Put standard input into binary mode.
13273         * modules/fflush-tests (Depends-on): Add binary-io.
13274
13275 2009-01-17  Bruno Haible  <bruno@clisp.org>
13276
13277         * lib/wchar.in.h: In another particular situation, include only the
13278         system's <wchar.h> file.
13279         (_GL_ALREADY_INCLUDING_WCHAR_H): New macro.
13280         Reported by Albert Chin-A-Young <china@thewrittenword.com>
13281         and Thomas Guyot-Sionnest <dermoth@aei.ca>.
13282
13283 2009-01-17  Bruno Haible  <bruno@clisp.org>
13284
13285         Support for stripping executables in --enable-relocatable.
13286         * build-aux/install-reloc: Expect one more argument, or an environment
13287         variable RELOC_STRIP_PROG. If set, strip the destination program and
13288         its wrapper.
13289         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): In INSTALL_PROGRAM_ENV, set
13290         RELOC_STRIP_PROG.
13291         * doc/relocatable-maint.texi (Supporting Relocation): Mention the need
13292         to set RELOCATABLE_STRIP.
13293         * NEWS: Mention the new Makefile requirement.
13294
13295 2009-01-17  Bruno Haible  <bruno@clisp.org>
13296
13297         * build-aux/install-reloc: Remove debugging information left over by
13298         C compiler on MacOS X.
13299
13300 2009-01-17  Bruno Haible  <bruno@clisp.org>
13301
13302         Update use of _NSGetExecutablePath after API change in MacOS X 10.4.
13303         * lib/progreloc.c (find_executable): Fix type of pointer passed to
13304         _NSGetExecutablePath.
13305
13306 2009-01-16  Jim Meyering  <meyering@redhat.com>
13307
13308         strerror: avoid warnings about discarding "const"
13309         * lib/strerror.c (rpl_strerror): Instead of returning a const
13310         string from each and every "case", use a variable, and add a single
13311         cast after the switch.
13312
13313 2009-01-16  Albert Chin-A-Young <china@thewrittenword.com>
13314
13315         * lib/arpa_inet.in.h: Add extern "C" block for C++.
13316
13317 2009-01-16  Bruno Haible  <bruno@clisp.org>
13318
13319         * m4/printf.m4 (gl_SNPRINTF_SIZE1, gl_VSNPRINTF_ZEROSIZE_C99): Use an
13320         array initializer syntax that also works in C++ mode.
13321         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
13322
13323 2009-01-16  Jim Meyering  <meyering@redhat.com>
13324
13325         poll: suppress a warning
13326         * lib/poll.c: Use #pragma GCC diagnostic ignored "-Wtype-limits"
13327         to ignore "...unsigned expression < 0 is always false" warnings.
13328
13329 2009-01-16  Daniel P. Berrange  <berrange@redhat.com>
13330
13331         poll: remove declarations of unused variables
13332         * lib/poll.c (poll) [WIN32_NATIVE]: Remove declarations of unused
13333         sockbuf and optlen.
13334
13335 2009-01-15  Bruno Haible  <bruno@clisp.org>
13336
13337         Make fflush-after-ungetc POSIX compliant on BSD systems.
13338         * lib/fflush.c (clear_ungetc_buffer_preserving_position): New function.
13339         (clear_ungetc_buffer): Implement also for other systems.
13340         (rpl_fflush): On glibc systems, invoke
13341         clear_ungetc_buffer_preserving_position. Otherwise, invoke
13342         clear_ungetc_buffer after fetching the stream's position, not before.
13343
13344 2009-01-15  Bruno Haible  <bruno@clisp.org>
13345
13346         Make fflush-after-ungetc POSIX compliant on glibc systems.
13347         * m4/fflush.m4 (gl_FUNC_FFLUSH): Test also the behaviour of fflush
13348         after ungetc.
13349         * lib/fflush.c (clear_ungetc_buffer): Implement for glibc systems.
13350         (rpl_fflush): On glibc systems, simply call the system's fflush
13351         function after clearing the ungetc buffer.
13352         * lib/fseeko.c (rpl_fseeko): Don't try to lseek past the end of file.
13353         Instead, lseek only to the end of file, then use the system's fseeko
13354         for the rest. On glibc systems, reset the EOF indicator bit.
13355
13356 2009-01-15  Jim Meyering  <meyering@redhat.com>
13357
13358         openmp.m4: revert quote-adding change, for portability to older autoconf
13359         * m4/openmp.m4: Remove the quotes added on 2009-01-14.
13360         This reverts part of 42d1eda5dcce2d68deab7a642e7f29bcd7144a0d.
13361         Simon Josefsson noticed the problem when using autoconf-2.61.
13362
13363 2009-01-15  Bruno Haible  <bruno@clisp.org>
13364
13365         * tests/test-fflush2.sh: Invoke test-fflush2 twice.
13366         * tests/test-fflush2.c (ASSERT): Always fail.
13367         (main): Add two tests for fflush() after ungetc(), taking into account
13368         the Austin Group's clarification.
13369         Suggested by Eric Blake.
13370
13371 2009-01-15  Albert Chin-A-Young  <china@thewrittenword.com>
13372
13373         mktime.m4: remove K&R-style function prototypes
13374         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove K&R-style function prototypes
13375         for the Sun C++ compiler.
13376
13377 2009-01-14  Bruno Haible  <bruno@clisp.org>
13378
13379         * lib/stdint.in.h (_GL_JUST_INCLUDE_SYSTEM_WCHAR_H): New macro, defined
13380         while including <wchar.h>.
13381         * lib/wchar.in.h: In two particular situations on HP-UX, include only
13382         the system's <wchar.h> file.
13383         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
13384
13385 2009-01-14  Bruno Haible  <bruno@clisp.org>
13386
13387         * m4/csharp.m4: Don't mention gettext on the serial number line.
13388         * m4/csharpexec.m4: Likewise.
13389         * m4/eaccess.m4: Likewise.
13390         * m4/javaexec.m4: Likewise.
13391         * m4/sig_atomic_t.m4: Likewise.
13392         * m4/tmpdir.m4: Likewise.
13393         * m4/intldir.m4: Bump gettext version.
13394         * m4/lib-ld.m4: Likewise.
13395
13396 2009-01-14  Bruno Haible  <bruno@clisp.org>
13397
13398         * lib/progname.c (set_program_name): Add more comments.
13399         Reported by Sergey Poznyakoff <gray@gnu.org.ua>.
13400
13401 2009-01-14  Simon Josefsson  <simon@josefsson.org>
13402
13403         * lib/sys_stat.in.h: Include sys/types.h for nlink_t on systems
13404         were sys/stat.h does not define it.
13405
13406 2009-01-14  Jim Meyering  <meyering@redhat.com>
13407
13408         many *.m4 files: improve m4 quoting
13409         99% of this change was performed by running the following commands:
13410         git ls-files | grep '\.m4$' | xargs perl -pi \
13411           -e 's/(AC_\w+\()([^[()]+?)([,)])/$1\[$2]$3/g;' \
13412           -e 's/(AC_\w+\((?:\[[^,]+?\], ){1})([^,[()]+?)([,)])/$1\[$2]$3/g;' \
13413           -e 's/(AC_\w+\((?:\[[^,]+?\], ){2})([^,[()]+?)([,)])/$1\[$2]$3/g;' \
13414           -e 's/(AC_\w+\((?:\[[^,]+?\], ){3})([^,[()]+?)([,)])/$1\[$2]$3/g'
13415         perl -pi -e 's/\[\.\.\.\]/.../' m4/onceonly.m4
13416         The remainder were to add Copyright dates, increment serial numbers,
13417         undo some changes in comments, exclude m4/intl.m4, and add quotes
13418         around the "1" in ",1" where the unusual spacing prohibited the
13419         above regexps from doing the job.  For more details, see
13420         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/16175>.
13421         * m4/acl.m4: Modified.
13422         * m4/afs.m4: Likewise.
13423         * m4/alloca.m4: Likewise.
13424         * m4/argp.m4: Likewise.
13425         * m4/argz.m4: Likewise.
13426         * m4/atexit.m4: Likewise.
13427         * m4/bison-i18n.m4: Likewise.
13428         * m4/bison.m4: Likewise.
13429         * m4/byteswap.m4: Likewise.
13430         * m4/c-stack.m4: Likewise.
13431         * m4/c-strtod.m4: Likewise.
13432         * m4/calloc.m4: Likewise.
13433         * m4/canonicalize-lgpl.m4: Likewise.
13434         * m4/chown.m4: Likewise.
13435         * m4/clock_time.m4: Likewise.
13436         * m4/codeset.m4: Likewise.
13437         * m4/copy-file.m4: Likewise.
13438         * m4/csharp.m4: Likewise.
13439         * m4/csharpcomp.m4: Likewise.
13440         * m4/csharpexec.m4: Likewise.
13441         * m4/d-ino.m4: Likewise.
13442         * m4/d-type.m4: Likewise.
13443         * m4/dirfd.m4: Likewise.
13444         * m4/double-slash-root.m4: Likewise.
13445         * m4/eaccess.m4: Likewise.
13446         * m4/eealloc.m4: Likewise.
13447         * m4/environ.m4: Likewise.
13448         * m4/errno_h.m4: Likewise.
13449         * m4/euidaccess.m4: Likewise.
13450         * m4/execute.m4: Likewise.
13451         * m4/fatal-signal.m4: Likewise.
13452         * m4/fchdir.m4: Likewise.
13453         * m4/fcntl_h.m4: Likewise.
13454         * m4/fileblocks.m4: Likewise.
13455         * m4/filenamecat.m4: Likewise.
13456         * m4/findprog.m4: Likewise.
13457         * m4/flexmember.m4: Likewise.
13458         * m4/fnmatch.m4: Likewise.
13459         * m4/fopen.m4: Likewise.
13460         * m4/fpending.m4: Likewise.
13461         * m4/fprintf-posix.m4: Likewise.
13462         * m4/free.m4: Likewise.
13463         * m4/frexp.m4: Likewise.
13464         * m4/frexpl.m4: Likewise.
13465         * m4/fsusage.m4: Likewise.
13466         * m4/ftruncate.m4: Likewise.
13467         * m4/gc-camellia.m4: Likewise.
13468         * m4/gc-random.m4: Likewise.
13469         * m4/gc.m4: Likewise.
13470         * m4/getaddrinfo.m4: Likewise.
13471         * m4/getcwd-abort-bug.m4: Likewise.
13472         * m4/getcwd-path-max.m4: Likewise.
13473         * m4/getdate.m4: Likewise.
13474         * m4/getdomainname.m4: Likewise.
13475         * m4/getgroups.m4: Likewise.
13476         * m4/gethostname.m4: Likewise.
13477         * m4/gethrxtime.m4: Likewise.
13478         * m4/getline.m4: Likewise.
13479         * m4/getloadavg.m4: Likewise.
13480         * m4/getndelim2.m4: Likewise.
13481         * m4/getpass.m4: Likewise.
13482         * m4/gettext.m4: Likewise.
13483         * m4/gettime.m4: Likewise.
13484         * m4/gettimeofday.m4: Likewise.
13485         * m4/gnulib-common.m4: Likewise.
13486         * m4/group-member.m4: Likewise.
13487         * m4/host-os.m4: Likewise.
13488         * m4/iconv.m4: Likewise.
13489         * m4/iconv_open.m4: Likewise.
13490         * m4/inet_ntop.m4: Likewise.
13491         * m4/inet_pton.m4: Likewise.
13492         * m4/inline.m4: Likewise.
13493         * m4/intldir.m4: Likewise.
13494         * m4/intlmacosx.m4: Likewise.
13495         * m4/intmax.m4: Likewise.
13496         * m4/intmax_t.m4: Likewise.
13497         * m4/inttypes.m4: Likewise.
13498         * m4/inttypes_h.m4: Likewise.
13499         * m4/inttypes-pri.m4: Likewise.
13500         * m4/isapipe.m4: Likewise.
13501         * m4/isnand.m4: Likewise.
13502         * m4/isnanf.m4: Likewise.
13503         * m4/isnanl.m4: Likewise.
13504         * m4/javacomp.m4: Likewise.
13505         * m4/javaexec.m4: Likewise.
13506         * m4/jm-winsz1.m4: Likewise.
13507         * m4/jm-winsz2.m4: Likewise.
13508         * m4/lchown.m4: Likewise.
13509         * m4/lcmessage.m4: Likewise.
13510         * m4/ldexpl.m4: Likewise.
13511         * m4/lib-ld.m4: Likewise.
13512         * m4/lib-link.m4: Likewise.
13513         * m4/libsigsegv.m4: Likewise.
13514         * m4/link-follow.m4: Likewise.
13515         * m4/localcharset.m4: Likewise.
13516         * m4/locale-fr.m4: Likewise.
13517         * m4/locale-ja.m4: Likewise.
13518         * m4/locale-tr.m4: Likewise.
13519         * m4/locale-zh.m4: Likewise.
13520         * m4/lock.m4: Likewise.
13521         * m4/longlong.m4: Likewise.
13522         * m4/ls-mntd-fs.m4: Likewise.
13523         * m4/lstat.m4: Likewise.
13524         * m4/malloc.m4: Likewise.
13525         * m4/mathl.m4: Likewise.
13526         * m4/mbrtowc.m4: Likewise.
13527         * m4/mbstate_t.m4: Likewise.
13528         * m4/mbswidth.m4: Likewise.
13529         * m4/memchr.m4: Likewise.
13530         * m4/memcmp.m4: Likewise.
13531         * m4/memcpy.m4: Likewise.
13532         * m4/memmem.m4: Likewise.
13533         * m4/memmove.m4: Likewise.
13534         * m4/mempcpy.m4: Likewise.
13535         * m4/memrchr.m4: Likewise.
13536         * m4/memset.m4: Likewise.
13537         * m4/minmax.m4: Likewise.
13538         * m4/mkdir-slash.m4: Likewise.
13539         * m4/mkdtemp.m4: Likewise.
13540         * m4/mktime.m4: Likewise.
13541         * m4/mmap-anon.m4: Likewise.
13542         * m4/mountlist.m4: Likewise.
13543         * m4/nanosleep.m4: Likewise.
13544         * m4/nls.m4: Likewise.
13545         * m4/nocrash.m4: Likewise.
13546         * m4/open.m4: Likewise.
13547         * m4/openat.m4: Likewise.
13548         * m4/openmp.m4: Likewise.
13549         * m4/pathmax.m4: Likewise.
13550         * m4/perl.m4: Likewise.
13551         * m4/physmem.m4: Likewise.
13552         * m4/pipe.m4: Likewise.
13553         * m4/po.m4: Likewise.
13554         * m4/poll.m4: Likewise.
13555         * m4/posixtm.m4: Likewise.
13556         * m4/posixver.m4: Likewise.
13557         * m4/printf-frexp.m4: Likewise.
13558         * m4/printf-frexpl.m4: Likewise.
13559         * m4/printf-posix.m4: Likewise.
13560         * m4/printf-posix-rpl.m4: Likewise.
13561         * m4/printf.m4: Likewise.
13562         * m4/progtest.m4: Likewise.
13563         * m4/putenv.m4: Likewise.
13564         * m4/readline.m4: Likewise.
13565         * m4/readlink.m4: Likewise.
13566         * m4/readutmp.m4: Likewise.
13567         * m4/realloc.m4: Likewise.
13568         * m4/regex.m4: Likewise.
13569         * m4/relocatable.m4: Likewise.
13570         * m4/relocatable-lib.m4: Likewise.
13571         * m4/rename-dest-slash.m4: Likewise.
13572         * m4/rename.m4: Likewise.
13573         * m4/rmdir-errno.m4: Likewise.
13574         * m4/rmdir.m4: Likewise.
13575         * m4/roundf.m4: Likewise.
13576         * m4/roundl.m4: Likewise.
13577         * m4/rpmatch.m4: Likewise.
13578         * m4/save-cwd.m4: Likewise.
13579         * m4/selinux-selinux-h.m4: Likewise.
13580         * m4/setenv.m4: Likewise.
13581         * m4/settime.m4: Likewise.
13582         * m4/sig2str.m4: Likewise.
13583         * m4/sig_atomic_t.m4: Likewise.
13584         * m4/signalblocking.m4: Likewise.
13585         * m4/signbit.m4: Likewise.
13586         * m4/sigpipe.m4: Likewise.
13587         * m4/sockets.m4: Likewise.
13588         * m4/sockpfaf.m4: Likewise.
13589         * m4/st_dm_mode.m4: Likewise.
13590         * m4/stat-time.m4: Likewise.
13591         * m4/stdbool.m4: Likewise.
13592         * m4/stdint.m4: Likewise.
13593         * m4/stdint_h.m4: Likewise.
13594         * m4/stpcpy.m4: Likewise.
13595         * m4/stpncpy.m4: Likewise.
13596         * m4/strcase.m4: Likewise.
13597         * m4/strchrnul.m4: Likewise.
13598         * m4/strcspn.m4: Likewise.
13599         * m4/strdup.m4: Likewise.
13600         * m4/strftime.m4: Likewise.
13601         * m4/strndup.m4: Likewise.
13602         * m4/strnlen.m4: Likewise.
13603         * m4/strpbrk.m4: Likewise.
13604         * m4/strptime.m4: Likewise.
13605         * m4/strsep.m4: Likewise.
13606         * m4/strtod.m4: Likewise.
13607         * m4/strtoimax.m4: Likewise.
13608         * m4/strtok_r.m4: Likewise.
13609         * m4/strtol.m4: Likewise.
13610         * m4/strtoll.m4: Likewise.
13611         * m4/strtoul.m4: Likewise.
13612         * m4/strtoull.m4: Likewise.
13613         * m4/strtoumax.m4: Likewise.
13614         * m4/strverscmp.m4: Likewise.
13615         * m4/threadlib.m4: Likewise.
13616         * m4/timegm.m4: Likewise.
13617         * m4/tm_gmtoff.m4: Likewise.
13618         * m4/tmpdir.m4: Likewise.
13619         * m4/tmpfile.m4: Likewise.
13620         * m4/tzset.m4: Likewise.
13621         * m4/uintmax_t.m4: Likewise.
13622         * m4/unlinkdir.m4: Likewise.
13623         * m4/unlocked-io.m4: Likewise.
13624         * m4/uptime.m4: Likewise.
13625         * m4/userspec.m4: Likewise.
13626         * m4/utimbuf.m4: Likewise.
13627         * m4/utime.m4: Likewise.
13628         * m4/utimes-null.m4: Likewise.
13629         * m4/utimes.m4: Likewise.
13630         * m4/vararrays.m4: Likewise.
13631         * m4/vasnprintf.m4: Likewise.
13632         * m4/vfprintf-posix.m4: Likewise.
13633         * m4/vprintf-posix.m4: Likewise.
13634         * m4/wait-process.m4: Likewise.
13635         * m4/wchar_t.m4: Likewise.
13636         * m4/wint_t.m4: Likewise.
13637         * m4/write-any-file.m4: Likewise.
13638         * m4/yield.m4: Likewise.
13639
13640 2009-01-13  Bruno Haible  <bruno@clisp.org>
13641
13642         Avoid test-copy-file.sh failures when ACL support insufficient.
13643         * modules/copy-file-tests (Makefile.am): Pass USE_ACL in
13644         TESTS_ENVIRONMENT.
13645         * tests/test-copy-file.sh: Skip the ACL comparisons if USE_ACL is 0.
13646         Reported by Jim Meyering.
13647
13648 2009-01-13  Bruno Haible  <bruno@clisp.org>
13649
13650         * modules/unistdio/u-printf-args (Files): Add m4/stdint_h.m4 and
13651         m4/inttypes_h.m4, needed by m4/intmax_t.m4.
13652         * modules/unistdio/u8-printf-parse (Files): Likewise.
13653         * modules/unistdio/u32-printf-parse (Files): Likewise.
13654         * modules/unistdio/ulc-printf-parse (Files): Likewise.
13655
13656 2009-01-13  Simon Josefsson  <simon@josefsson.org>
13657
13658         * modules/unistdio/u16-printf-parse (Files): Add m4/stdint_h.m4
13659         and m4/inttypes_h.m4 too.
13660
13661 2009-01-12  Eric Blake  <ebb9@byu.net>
13662
13663         tests: IRIX 6.2 cc can't compile -0.0 into .data
13664         * tests/test-ceill.c (minus_zero): Compute -0.0L at runtime,
13665         rather than at compile-time.
13666         * tests/test-floorl.c (minus_zero): Likewise.
13667         * tests/test-frexpl.c (minus_zero): Likewise.
13668         * tests/test-isnan.c (minus_zerol): Likewise.
13669         * tests/test-isnanl.h (minus_zero): Likewise.
13670         * tests/test-ldexpl.c (minus_zero): Likewise.
13671         * tests/test-roundl.c (minus_zero): Likewise.
13672         * tests/test-signbit.c (minus_zerol): Likewise.
13673         * tests/test-snprintf-posix.h (minus_zerol): Likewise.
13674         * tests/test-sprintf-posix.h (minus_zerol): Likewise.
13675         * tests/test-truncl.c (minus_zero): Likewise.
13676         * tests/test-vasnprintf-posix.c (minus_zerol): Likewise.
13677         * tests/test-vasprintf-posix.c (minus_zerol): Likewise.
13678         Reported by Tom G. Christensen and Nelson H. F. Beebe.
13679
13680 2009-01-09  Paolo Bonzini  <bonzini@gnu.org>
13681
13682         regex: fix glibc bug 9697
13683         * lib/regcomp.c (re_compile_fastmap_iter): Rewrite COMPLEX_BRACKET
13684         handling.
13685
13686 2009-01-09  Paolo Bonzini  <bonzini@gnu.org>
13687
13688         regex: fix glibc bug 697
13689         * lib/regexec.c (prune_impossible_nodes): Handle sifted_states[0]
13690         being NULL also if there are no backreferences.
13691
13692 2009-01-09  Paolo Bonzini  <bonzini@gnu.org>
13693
13694         regex: merge glibc changes
13695         * lib/regcomp.c (re_compile_fastmap_iter): Use __mbrtowc.
13696         * lib/regex_internal.c (build_wcs_buffer, build_wcs_upper_buffer,
13697         re_string_skip_chars, re_string_reconstruct): Likewise.
13698         * lib/regex_internal.h [!_LIBC] (__mbrtowc): New #define.
13699
13700 2009-01-07  Jim Meyering  <meyering@redhat.com>
13701
13702         poll: filter through cppi
13703         * lib/poll.c: Indent cpp directives to reflect nesting.
13704
13705 2009-01-07  Daniel P. Berrange  <berrange@redhat.com>
13706
13707         poll: don't return uninitialized
13708         * lib/poll.c (poll) [WIN32_NATIVE]: Initialize "rc".
13709
13710 2009-01-06  Jeremy Olexa <darkside@gentoo.org>  (tiny change)
13711
13712         avoid compile failure on AIX 6.1
13713         * lib/getloadavg.c [HAVE_LIBPERFSTAT]: Include <sys/protosw.h>.
13714         Details in http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/15465
13715
13716 2009-01-04  Jim Meyering  <meyering@redhat.com>
13717
13718         remove duplicate inclusion of <stdio.h>
13719         * tests/test-fprintf-posix.c: Likewise.
13720         * tests/test-printf-posix.c: Likewise.
13721         * tests/test-snprintf-posix.c: Likewise.
13722         * tests/test-sprintf-posix.c: Likewise.
13723         * tests/test-vasprintf-posix.c: Likewise.
13724         * tests/test-vfprintf-posix.c: Likewise.
13725         * tests/test-vprintf-posix.c: Likewise.
13726         * tests/test-vsnprintf-posix.c: Likewise.
13727         * tests/test-vsprintf-posix.c: Likewise.
13728
13729 2009-01-03  Jim Meyering  <meyering@redhat.com>
13730
13731         gnulib-tool: fix sed-based filtering
13732         * gnulib-tool (func_filter_filelist): Remove extra backslash
13733         in sed_fff_filter definition.
13734
13735 2009-01-02  Jim Meyering  <meyering@redhat.com>
13736
13737         strftime: avoid compilation failure on Solaris 2.6
13738         * modules/strftime (Depends-on): Add mbrlen and mbsinit.
13739         * lib/strftime.c [DO_MULTIBYTE]: Include <wchar.h> unconditionally.
13740         Don't #define mbrlen or mbsinit, since now they're guaranteed to
13741         be available.  Reported by Tom G. Christensen.  Details in
13742         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/16180>.
13743
13744 2009-01-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13745             Bruno Haible  <bruno@clisp.org>
13746
13747         Speed up gnulib-tool by doing more string processing through shell
13748         built-ins.
13749         * gnulib-tool (fast_func_append): New variable.
13750         (func_remove_prefix, func_remove_suffix): New functions.
13751         (fast_func_remove_prefix, fast_func_remove_suffix): New variables.
13752         (func_filter_filelist): New function.
13753         (func_get_dependencies): Use func_remove_suffix instead of sed.
13754         (func_get_automake_snippet): Use func_filter_filelist instead of a
13755         subshell and sed invocation.
13756
13757 2009-01-01  Bruno Haible  <bruno@clisp.org>
13758
13759         Fix a security bug.
13760         * gnulib-tool (func_import, import, update): Don't allow the characters
13761         '"', '$', '`', '\' in macro arguments that become part of commands that
13762         are evaluated.
13763
13764 2009-01-01  Bruno Haible  <bruno@clisp.org>
13765
13766         * gnulib-tool (func_reset_sigpipe): Add more comments.
13767
13768 2009-01-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13769
13770         * gnulib-tool (func_modules_add_dummy, func_emit_lib_Makefile_am,
13771         func_emit_tests_Makefile_am, func_import): Abort loops early if we
13772         already know the answer.
13773
13774 2009-01-01  Jim Meyering  <meyering@redhat.com>
13775
13776         * lib/version-etc.c (version_etc_va): Update copyright year.
13777
13778 2008-12-30  Bruno Haible  <bruno@clisp.org>
13779
13780         * m4/lib-prefix.m4 (AC_LIB_LINKFLAGS_BODY): Don't overwrite
13781         LIB${NAME}_PREFIX when considering the dependencies of lib${name}.
13782         Reported by Charles Wilson <cygwin@cwilson.fastmail.fm>.
13783
13784 2008-12-29  Eric Blake  <ebb9@byu.net>
13785
13786         multiarch: avoid autoconf AC_REQUIRE bug
13787         * m4/multiarch.m4 (gl_MULTIARCH): Split body...
13788         (gl_MULTIARCH_BODY): ...into new macro, to work around bug in Autoconf
13789         2.63 and older.
13790         Reported by Bruno Haible, and analyzed in
13791         http://lists.gnu.org/archive/html/bug-autoconf/2008-12/msg00039.html
13792
13793 2008-12-29  Bruno Haible  <bruno@clisp.org>
13794
13795         * gnulib-tool (func_import): When generating sed-ignore-removed, handle
13796         files in subdirectories correctly.
13797         Reported by Ralf Wildenhues.
13798
13799 2008-12-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13800
13801         * gnulib-tool (func_update_ignorelist): Use 'join - FILE'
13802         rather than 'join FILE -', for Solaris join.
13803
13804 2008-12-29  Bruno Haible  <bruno@clisp.org>
13805
13806         * m4/codeset.m4 (AM_LANGINFO_CODESET): More systematic m4 argument
13807         quoting.
13808         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
13809         * m4/glibc2.m4 (gt_GLIBC2): Likewise.
13810         * m4/glibc21.m4 (gl_GLIBC21): Likewise.
13811         * m4/iconv.m4 (AM_ICONV_LINK, AM_ICONV): Likewise.
13812         * m4/intdiv0.m4 (gt_INTDIV0): Likewise.
13813         * m4/intlmacosx.m4 (gt_INTL_MACOSX): Likewise.
13814         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Likewise.
13815         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Likewise.
13816         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
13817         * m4/lcmessage.m4 (gt_LC_MESSAGES): Likewise.
13818         * m4/nls.m4 (AM_NLS): Likewise.
13819         * m4/po.m4 (AM_PO_SUBDIRS): Likewise.
13820         * m4/printf-posix.m4 (gt_PRINTF_POSIX): Likewise.
13821         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
13822         * m4/size_max.m4 (gl_SIZE_MAX): Likewise.
13823         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Likewise.
13824         * m4/threadlib.m4 (gl_THREADLIB_BODY): Likewise.
13825         * m4/uintmax_t.m4 (gl_AC_TYPE_UINTMAX_T): Likewise.
13826         * m4/visibility.m4 (gl_VISIBILITY): Likewise.
13827         * m4/wchar_t.m4 (gt_TYPE_WCHAR_T): Likewise.
13828         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
13829         * m4/xsize.m4 (gl_XSIZE): Likewise.
13830         Suggested by Jim Meyering.
13831
13832 2008-11-17  Bruce Korb  <bkorb@gnu.org>
13833
13834         * lib/parse-duration.h: non-iso form accepts years, months weeks, too
13835         * lib/parse-duration.c: use a switch instead of cascading if's.
13836
13837 2008-12-29  Eric Blake  <ebb9@byu.net>
13838
13839         wchar.h: supply WEOF on Irix 5.3
13840         * lib/wchar.in.h (wint_t): Also supply WEOF.
13841         * lib/wctype.in.h (wint_t): Likewise.
13842         * doc/posix-headers/wchar.texi (wchar.h): Document the bug.
13843         * doc/posix-headers/wctype.texi (wctype.h): Likewise.
13844         Reported by Tom G. Christensen.
13845
13846 2008-12-26  Bruno Haible  <bruno@clisp.org>
13847
13848         * m4/multiarch.m4 (gl_MULTIARCH): Recognize also the architecture names
13849         i486, i586, i686.
13850
13851 2008-12-26  Bruno Haible  <bruno@clisp.org>
13852
13853         * lib/stdlib.in.h (struct random_data): Fix indentation of comments.
13854
13855 2008-12-26  Bruno Haible  <bruno@clisp.org>
13856
13857         * lib/stdint.in.h: Move the include of <wchar.h> down until after all
13858         the types are defined. Also conditionalize it on __STDC_LIMIT_MACROS,
13859         not __STDC_CONSTANT_MACROS.
13860         Reported by Nelson H. F. Beebe <beebe@math.utah.edu> via Eric Blake.
13861
13862 2008-12-25  Bruno Haible  <bruno@clisp.org>
13863
13864         Add support for universal builds to vasnprintf.
13865         * m4/printf.m4 (gl_PRINTF_ENOMEM): Require gl_MULTIARCH. In Apple
13866         universal builds, guess no.
13867         * modules/vasnprintf-posix (Depends-on): Add multiarch.
13868         * modules/vasprintf-posix (Depends-on): Likewise.
13869         * modules/fprintf-posix (Depends-on): Likewise.
13870         * modules/vfprintf-posix (Depends-on): Likewise.
13871         * modules/snprintf-posix (Depends-on): Likewise.
13872         * modules/vsnprintf-posix (Depends-on): Likewise.
13873         * modules/sprintf-posix (Depends-on): Likewise.
13874         * modules/vsprintf-posix (Depends-on): Likewise.
13875         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
13876         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
13877         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
13878         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
13879         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
13880         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
13881         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
13882
13883         Add support for universal builds to <inttypes.h>.
13884         * lib/inttypes.in.h (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX,
13885         _SCNu64_PREFIX): In Apple
13886         universal builds, define directly, using _LP64.
13887         * m4/inttypes.m4 (gl_INTTYPES_H): In Apple universal builds, set
13888         INT64_MAX_EQ_LONG_MAX and UINT64_MAX_EQ_ULONG_MAX to -1.
13889         * modules/inttypes (Depends-on): Add multiarch.
13890         (Makefile.am): Substitute APPLE_UNIVERSAL_BUILD.
13891
13892         Add support for universal builds to <stdint.h>.
13893         * lib/stdint.in.h (PDFDIFF_MIN, PTRDIFF_MAX, SIZE_MAX): In Apple
13894         universal builds, define directly, using _LP64.
13895         * m4/stdint.m4 (gl_STDINT_TYPE_PROPERTIES): Require gl_MULTIARCH. In
13896         Apple universal builds, don't test for the size and suffix of ptrdiff_t
13897         and size_t.
13898         * modules/stdint (Depends-on): Add multiarch.
13899         (Makefile.am): Substitute APPLE_UNIVERSAL_BUILD.
13900
13901         New module 'multiarch'.
13902         * modules/multiarch: New file.
13903         * m4/multiarch.m4: New file.
13904
13905 2008-12-25  Bruno Haible  <bruno@clisp.org>
13906
13907         * gnulib-tool (func_create_testdir): Avoid failure of mv command.
13908
13909 2008-12-25  Bruno Haible  <bruno@clisp.org>
13910
13911         * modules/btowc (License): Relicense under LGPLv2+.
13912         * modules/mbsinit (License): Likewise.
13913         * modules/mbrtowc (License): Likewise.
13914         * modules/wcrtomb (License): Likewise.
13915         * modules/streq (License): Likewise.
13916         Reported by David Lutterkort <lutter@redhat.com>.
13917
13918 2008-12-23  Bruno Haible  <bruno@clisp.org>
13919
13920         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Fix conditional and comment.
13921
13922 2008-12-23  Bruno Haible  <bruno@clisp.org>
13923
13924         Module getaddrinfo requires linking with $(GETADDRINFO_LIB).
13925         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Put link options into
13926         GETADDRINFO_LIB, not in LIBS.
13927         * modules/getaddrinfo (Link): Set to $(GETADDRINFO_LIB).
13928         * modules/canon-host (Link): Likewise.
13929         * NEWS: Mention the change.
13930         * modules/getaddrinfo-tests (test_getaddrinfo_LDADD): Add the
13931         GETADDRINFO_LIB.
13932
13933 2008-12-22  Bruno Haible  <bruno@clisp.org>
13934
13935         * doc/posix-functions/iswalnum_l.texi: Mention limitation of wchar_t.
13936         * doc/posix-functions/iswalpha_l.texi: Likewise.
13937         * doc/posix-functions/iswblank_l.texi: Likewise.
13938         * doc/posix-functions/iswcntrl_l.texi: Likewise.
13939         * doc/posix-functions/iswctype_l.texi: Likewise.
13940         * doc/posix-functions/iswdigit_l.texi: Likewise.
13941         * doc/posix-functions/iswgraph_l.texi: Likewise.
13942         * doc/posix-functions/iswlower_l.texi: Likewise.
13943         * doc/posix-functions/iswprint_l.texi: Likewise.
13944         * doc/posix-functions/iswpunct_l.texi: Likewise.
13945         * doc/posix-functions/iswspace_l.texi: Likewise.
13946         * doc/posix-functions/iswupper_l.texi: Likewise.
13947         * doc/posix-functions/iswxdigit_l.texi: Likewise.
13948         * doc/posix-functions/mbsnrtowcs.texi: Likewise.
13949         * doc/posix-functions/open_wmemstream.texi: Likewise.
13950         * doc/posix-functions/swscanf.texi: Likewise.
13951         * doc/posix-functions/towctrans_l.texi: Likewise.
13952         * doc/posix-functions/towlower.texi: Likewise.
13953         * doc/posix-functions/towlower_l.texi: Likewise.
13954         * doc/posix-functions/towupper.texi: Likewise.
13955         * doc/posix-functions/towupper_l.texi: Likewise.
13956         * doc/posix-functions/vfwprintf.texi: Likewise.
13957         * doc/posix-functions/vfwscanf.texi: Likewise.
13958         * doc/posix-functions/vswscanf.texi: Likewise.
13959         * doc/posix-functions/vwprintf.texi: Likewise.
13960         * doc/posix-functions/vwscanf.texi: Likewise.
13961         * doc/posix-functions/wcpcpy.texi: Likewise.
13962         * doc/posix-functions/wcpncpy.texi: Likewise.
13963         * doc/posix-functions/wcscasecmp.texi: Likewise.
13964         * doc/posix-functions/wcscasecmp_l.texi: Likewise.
13965         * doc/posix-functions/wcscoll_l.texi: Likewise.
13966         * doc/posix-functions/wcsdup.texi: Likewise.
13967         * doc/posix-functions/wcsncasecmp.texi: Likewise.
13968         * doc/posix-functions/wcsncasecmp_l.texi: Likewise.
13969         * doc/posix-functions/wcsnlen.texi: Likewise.
13970         * doc/posix-functions/wcsnrtombs.texi: Likewise.
13971         * doc/posix-functions/wcsxfrm_l.texi: Likewise.
13972         * doc/posix-functions/wctrans_l.texi: Likewise.
13973         * doc/posix-functions/wctype_l.texi: Likewise.
13974         * doc/glibc-functions/fgetwc_unlocked.texi: Likewise.
13975         * doc/glibc-functions/fgetws_unlocked.texi: Likewise.
13976         * doc/glibc-functions/fputwc_unlocked.texi: Likewise.
13977         * doc/glibc-functions/fputws_unlocked.texi: Likewise.
13978         * doc/glibc-functions/getwc_unlocked.texi: Likewise.
13979         * doc/glibc-functions/getwchar_unlocked.texi: Likewise.
13980         * doc/glibc-functions/putwc_unlocked.texi: Likewise.
13981         * doc/glibc-functions/putwchar_unlocked.texi: Likewise.
13982         * doc/glibc-functions/wcschrnul.texi: Likewise.
13983         * doc/glibc-functions/wcsftime_l.texi: Likewise.
13984         * doc/glibc-functions/wcstod_l.texi: Likewise.
13985         * doc/glibc-functions/wcstof_l.texi: Likewise.
13986         * doc/glibc-functions/wcstol_l.texi: Likewise.
13987         * doc/glibc-functions/wcstold_l.texi: Likewise.
13988         * doc/glibc-functions/wcstoll_l.texi: Likewise.
13989         * doc/glibc-functions/wcstoq.texi: Likewise.
13990         * doc/glibc-functions/wcstoul_l.texi: Likewise.
13991         * doc/glibc-functions/wcstoull_l.texi: Likewise.
13992         * doc/glibc-functions/wcstouq.texi: Likewise.
13993         * doc/glibc-functions/wmempcpy.texi: Likewise.
13994
13995 2008-12-22  Ingo Weinhold  <ingo_weinhold@gmx.de>  (tiny change)
13996             Eric Blake  <ebb9@byu.net>
13997             Paolo Bonzini  <bonzini@gnu.org>
13998             Bruno Haible  <bruno@clisp.org>
13999
14000         Make c-stack work on Haiku.
14001         * lib/c-stack.c (SA_ONSTACK): Define fallback.
14002         (c_stack_action): Use SA_ONSTACK flag.
14003
14004 2008-12-22  Bruno Haible  <bruno@clisp.org>
14005
14006         * m4/locale-fr.m4 (gt_LOCALE_FR_UTF8): Treat Haiku like BeOS.
14007
14008 2008-12-22  Bruno Haible  <bruno@clisp.org>
14009
14010         Work around mbrlen() bugs on AIX, HP-UX, OSF/1, Solaris.
14011         * m4/mbrlen.m4 (gl_FUNC_MBRLEN): Set REPLACE_MBRLEN if mbrtowc is
14012         being overridden.
14013         (gl_MBRLEN_INCOMPLETE_STATE, gl_MBRLEN_RETVAL, gl_MBRLEN_NUL_RETVAL):
14014         New macros.
14015         * lib/wchar.in.h (mbrlen): Override if REPLACE_MBRLEN is set.
14016         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_MBRLEN.
14017         * modules/wchar (Makefile.am): Substitute REPLACE_MBRLEN.
14018         * doc/posix-functions/mbrlen.texi: Mention the various platform bugs.
14019
14020 2008-12-22  Bruno Haible  <bruno@clisp.org>
14021
14022         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE): Remove unused variable
14023         from test code.
14024
14025 2008-12-22  Eric Blake  <ebb9@byu.net>
14026
14027         Avoid gcc warnings on cygwin.
14028         * lib/regex_internal.c (re_string_reconstruct) [!RE_ENABLE_I18N]:
14029         Avoid unused variable.
14030         * lib/regexec.c (check_arrival_add_next_nodes) [!RE_ENABLE_I18N]:
14031         Likewise.
14032
14033 2008-12-22  Bruno Haible  <bruno@clisp.org>
14034
14035         Remove HAVE_MBRTOWC conditionals.
14036         * lib/mbscasecmp.c: Include mbuiter.h unconditionally.
14037         (mbscasecmp): Assume mbrtowc function.
14038         * lib/mbscasestr.c: Include mbuiter.h unconditionally.
14039         (knuth_morris_pratt_multibyte, mbscasestr): Assume mbrtowc function.
14040         * lib/mbschr.c: Include mbuiter.h unconditionally.
14041         (mbschr): Assume mbrtowc function.
14042         * lib/mbscspn.c: Include mbuiter.h unconditionally.
14043         (mbscspn): Assume mbrtowc function.
14044         * lib/mbslen.c: Include mbuiter.h unconditionally.
14045         (mbslen): Assume mbrtowc function.
14046         * lib/mbsncasecmp.c: Include mbuiter.h unconditionally.
14047         (mbsncasecmp): Assume mbrtowc function.
14048         * lib/mbsnlen.c: Include mbiter.h unconditionally.
14049         (mbsnlen): Assume mbrtowc function.
14050         * lib/mbspbrk.c: Include mbuiter.h unconditionally.
14051         (mbspbrk): Assume mbrtowc function.
14052         * lib/mbspcasecmp.c: Include mbuiter.h unconditionally.
14053         (mbspcasecmp): Assume mbrtowc function.
14054         * lib/mbsrchr.c: Include mbuiter.h unconditionally.
14055         (mbsrchr): Assume mbrtowc function.
14056         * lib/mbssep.c: Include mbuiter.h unconditionally.
14057         (mbssep): Assume mbrtowc function.
14058         * lib/mbsspn.c: Include mbuiter.h unconditionally.
14059         (mbsspn): Assume mbrtowc function.
14060         * lib/mbsstr.c: Include mbuiter.h unconditionally.
14061         (knuth_morris_pratt_multibyte, mbsstr): Assume mbrtowc function.
14062         * lib/mbstok_r.c: Include mbuiter.h unconditionally.
14063         (mbstok_r): Assume mbrtowc function.
14064         * lib/propername.c: Include mbuiter.h unconditionally.
14065         (mbsstr_trimmed_wordbounded): Assume mbrtowc function.
14066         * lib/trim.c: Include mbchar.h, mbiter.h uncondtionally.
14067         (trim2): Assume mbrtowc function.
14068         * lib/mbswidth.c (mbsinit): Remove fallback definition.
14069         (mbsnwidth): Assume mbrtowc function.
14070         * modules/mbswidth (Depends-on): Add mbrtowc, mbsinit.
14071         * lib/quotearg.c (MB_CUR_MAX, mbstate_t, mbrtowc, iswprint): Remove
14072         fallback definitions.
14073         * modules/quotearg (Depends-on): Add mbrtowc, mbsinit.
14074
14075 2008-12-22  Bruno Haible  <bruno@clisp.org>
14076
14077         * doc/posix-functions/mbtowc.texi: Mention a glibc bug.
14078
14079 2008-12-22  Paolo Bonzini  <bonzini@gnu.org>
14080
14081         * modules/regex: Request emulations for the mb*/wc* functions we need.
14082         * m4/regex.m4: Don't look for those functions here.
14083         * lib/regex_internal.h: Do not check HAVE_WCRTOMB and HAVE_MBRTOWC.
14084
14085 2008-12-22  Bruno Haible  <bruno@clisp.org>
14086
14087         * modules/fnmatch (Depends-on): Remove duplicated dependency.
14088
14089 2008-12-21  Bruno Haible  <bruno@clisp.org>
14090
14091         Make mbiter.h, mbuiter.h, mbfile.h usable unconditionally.
14092         * modules/mbiter (Depends-on): Add mbrtowc, mbsinit.
14093         (Include): Remove conditionalization.
14094         * modules/mbuiter (Depends-on): Add mbrtowc, mbsinit.
14095         (Include): Remove conditionalization.
14096         * modules/mbfile (Depends-on): Add mbrtowc, mbsinit.
14097         (Include): Remove conditionalization.
14098         * m4/mbiter.m4 (gl_MBITER): Deprecate the use of AC_FUNC_MBRTOWC.
14099         * m4/mbfile.m4 (gl_MBFILE): Likewise.
14100         * NEWS: Mention the change.
14101         Reported by Alan Hourihane <alanh@fairlite.co.uk>
14102         via Sergey Poznyakoff <gray@gnu.org.ua>.
14103
14104 2008-12-21  Bruno Haible  <bruno@clisp.org>
14105
14106         * MODULES.html.sh (Extended multibyte and wide character utilities
14107         <wchar.h>): Add btowc, wctob, mbsinit, mbrlen, mbrtowc, mbsrtowcs,
14108         wcrtomb, wcsrtombs.
14109         (Support for systems lacking POSIX:2008): Add accept, bind, close,
14110         connect, fclose, getpeername, getsockname, getsockopt, hostent, listen,
14111         mbsnrtowcs, posix_spawn*, recv, recvfrom, sched, select, send, sendto,
14112         setsockopt, shutdown, socket, spawn, sys_wait, wcsnrtombs, write.
14113
14114 2008-12-21  Bruno Haible  <bruno@clisp.org>
14115
14116         * MODULES.html.sh: Change section titles to refer to POSIX:2008.
14117
14118 2008-12-21  Bruno Haible  <bruno@clisp.org>
14119
14120         * modules/wcsnrtombs-tests: New file.
14121         * tests/test-wcsnrtombs1.sh: New file.
14122         * tests/test-wcsnrtombs2.sh: New file.
14123         * tests/test-wcsnrtombs3.sh: New file.
14124         * tests/test-wcsnrtombs4.sh: New file.
14125         * tests/test-wcsnrtombs.c: New file.
14126
14127         New module 'wcsnrtombs'.
14128         * lib/wchar.in.h (wcsnrtombs): New declaration.
14129         * lib/wcsnrtombs.c: New file.
14130         * lib/wcsrtombs-state.c: New file.
14131         * lib/wcsrtombs.c: Refer to _gl_wcsrtombs_state.
14132         (internal_state): Remove variable.
14133         * m4/wcsnrtombs.m4: New file.
14134         * m4/wcsrtombs.m4 (gl_FUNC_WCSRTOMBS): Add wcsrtombs-state.c to the
14135         compilation units.
14136         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNRTOMBS,
14137         HAVE_WCSNRTOMBS.
14138         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNRTOMBS,
14139         HAVE_WCSNRTOMBS.
14140         * modules/wcsnrtombs: New file.
14141         * modules/wcsrtombs (Files): Add lib/wcsrtombs-state.c.
14142         * doc/posix-functions/wcsnrtombs.texi: Mention the new module.
14143
14144 2008-12-21  Bruno Haible  <bruno@clisp.org>
14145
14146         * modules/wcsrtombs-tests: New file.
14147         * tests/test-wcsrtombs1.sh: New file.
14148         * tests/test-wcsrtombs2.sh: New file.
14149         * tests/test-wcsrtombs3.sh: New file.
14150         * tests/test-wcsrtombs4.sh: New file.
14151         * tests/test-wcsrtombs.c: New file.
14152
14153         New module 'wcsrtombs'.
14154         * lib/wchar.in.h (wcsrtombs): New declaration.
14155         * lib/wcsrtombs.c: New file.
14156         * m4/wcsrtombs.m4: New file.
14157         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSRTOMBS,
14158         HAVE_WCSRTOMBS, REPLACE_WCSRTOMBS.
14159         * modules/wchar (Makefile.am): Substitute GNULIB_WCSRTOMBS,
14160         HAVE_WCSRTOMBS, REPLACE_WCSRTOMBS.
14161         * modules/wcsrtombs: New file.
14162         * doc/posix-functions/wcsrtombs.texi: Mention the new module and the
14163         bugs.
14164
14165 2008-12-21  Bruno Haible  <bruno@clisp.org>
14166
14167         Work around a wcrtomb() bug on Solaris 10 and OSF/1 5.1.
14168         * lib/wchar.in.h (wcrtomb): Override if REPLACE_WCRTOMB is set.
14169         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Test the return value of wcrtomb
14170         with NULL destination argument in various locales. Set REPLACE_WCRTOMB
14171         if not correct.
14172         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCRTOMB.
14173         * modules/wchar (Makefile.am): Substitute REPLACE_WCRTOMB.
14174         * modules/wcrtomb (Files): Add m4/locale-fr.m4, m4/locale-ja.m4,
14175         m4/locale-zh.m4, m4/codeset.m4.
14176         * doc/posix-functions/wcrtomb.texi: Document the bug.
14177
14178 2008-12-21  Bruno Haible  <bruno@clisp.org>
14179
14180         Work around a btowc() bug on IRIX 6.5.
14181         * lib/wchar.in.h (btowc): Override if REPLACE_BTOWC is set.
14182         * m4/btowc.m4 (gl_FUNC_BTOWC): Test whether btowc(EOF) is correct. Set
14183         REPLACE_WTOBC if not.
14184         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_BTOWC.
14185         * modules/wchar (Makefile.am): Substitute REPLACE_BTOWC.
14186         * doc/posix-functions/btowc.texi: Mention the IRIX bug.
14187
14188 2008-12-21  Bruno Haible  <bruno@clisp.org>
14189
14190         * modules/wcrtomb-tests: New file.
14191         * tests/test-wcrtomb.sh: New file.
14192         * tests/test-wcrtomb.c: New file.
14193
14194         New module 'wcrtomb'.
14195         * lib/wchar.in.h (wcrtomb): New declaration.
14196         * lib/wcrtomb.c: New file.
14197         * m4/wcrtomb.m4: New file.
14198         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCRTOMB,
14199         HAVE_WCRTOMB.
14200         * modules/wchar (Makefile.am): Substitute GNULIB_WCRTOMB,
14201         HAVE_WCRTOMB.
14202         * modules/wcrtomb: New file.
14203         * doc/posix-functions/wcrtomb.texi: Mention the new module.
14204
14205 2008-12-21  Bruno Haible  <bruno@clisp.org>
14206
14207         * modules/mbrtowc (Files): Add m4/codeset.m4, needed by m4/locale-fr.m4.
14208         * modules/mbsrtowcs (Files): Likewise.
14209         * modules/wctob (Files): Likewise.
14210         * modules/c-strcase-tests (Files): Likewise.
14211         * modules/unistdio/u8-vasnprintf-tests (Files): Likewise.
14212         * modules/unistdio/u16-vasnprintf-tests (Files): Likewise.
14213         * modules/unistdio/u32-vasnprintf-tests (Files): Likewise.
14214         * modules/unistdio/ulc-vasnprintf-tests (Files): Likewise.
14215         * modules/vasnprintf-posix-tests (Files): Likewise.
14216
14217 2008-12-21  William Pursell  <bill.pursell@gmail.com>
14218
14219         gitlog-to-changelog: pass all command-line arguments to git-log
14220         * build-aux/gitlog-to-changelog: When producing a ChangeLog,
14221         it is sometimes convenient to filter the commits in various ways.
14222         gitlog-to-changelog only allows --since to specify a start date,
14223         but git-log itself supports many other filtering mechanisms.
14224         At the moment, I want to filter by branch name.  Rather than
14225         adding a --branch option to gitlog-to-changelog, it seems more
14226         flexible to simply pass all options directly to git-log and let
14227         git do the work.  Notice that this effectively makes --since a
14228         redundant option for gitlog-to-changelog, but removing it would
14229         require current usage to change since calls would then require
14230         an additional '--'.
14231
14232 2008-12-21  Bruno Haible  <bruno@clisp.org>
14233
14234         * modules/mbsnrtowcs-tests: New file.
14235         * tests/test-mbsnrtowcs1.sh: New file.
14236         * tests/test-mbsnrtowcs2.sh: New file.
14237         * tests/test-mbsnrtowcs3.sh: New file.
14238         * tests/test-mbsnrtowcs4.sh: New file.
14239         * tests/test-mbsnrtowcs.c: New file.
14240
14241         New module 'mbsnrtowcs'.
14242         * lib/wchar.in.h (mbsnrtowcs): New declaration.
14243         * lib/mbsnrtowcs.c: New file.
14244         * lib/mbsrtowcs-state.c: New file.
14245         * lib/mbsrtowcs.c: Refer to _gl_mbsrtowcs_state.
14246         (internal_state): Remove variable.
14247         * m4/mbsnrtowcs.m4: New file.
14248         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): Add mbsrtowcs-state.c to the
14249         compilation units.
14250         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBSNRTOWCS,
14251         HAVE_MBSNRTOWCS, REPLACE_MBSNRTOWCS.
14252         * modules/wchar (Makefile.am): Substitute GNULIB_MBSNRTOWCS,
14253         HAVE_MBSNRTOWCS, REPLACE_MBSNRTOWCS.
14254         * modules/mbsnrtowcs: New file.
14255         * modules/mbsrtowcs (Files): Add lib/mbsrtowcs-state.c.
14256         * doc/posix-functions/mbsnrtowcs.texi: Mention the new module and a
14257         portability problem.
14258
14259 2008-12-21  Bruno Haible  <bruno@clisp.org>
14260
14261         Work around mbsrtowcs bug.
14262         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): New macro.
14263         (gl_FUNC_MBSRTOWCS): Invoke it.
14264         * modules/mbsrtowcs (Files): Add m4/locale-fr.m4, m4/locale-ja.m4,
14265         m4/locale-zh.m4.
14266         * doc/posix-functions/mbsrtowcs.texi: Document the bug.
14267
14268 2008-12-21  Bruno Haible  <bruno@clisp.org>
14269
14270         * tests/test-mbsrtowcs.c (main): Execute the loop also for unlimited=1.
14271
14272 2008-12-21  Bruno Haible  <bruno@clisp.org>
14273
14274         Update doc for AIX.
14275         * doc/pastposix-functions/wcswcs.texi: Mention that AIX has only a
14276         16-bit wchar_t type.
14277         * doc/posix-functions/btowc.texi: Likewise.
14278         * doc/posix-functions/fgetwc.texi: Likewise.
14279         * doc/posix-functions/fgetws.texi: Likewise.
14280         * doc/posix-functions/fputwc.texi: Likewise.
14281         * doc/posix-functions/fputws.texi: Likewise.
14282         * doc/posix-functions/fwide.texi: Likewise.
14283         * doc/posix-functions/fwprintf.texi: Likewise.
14284         * doc/posix-functions/fwscanf.texi: Likewise.
14285         * doc/posix-functions/getwchar.texi: Likewise.
14286         * doc/posix-functions/getwc.texi: Likewise.
14287         * doc/posix-functions/iswalnum.texi: Likewise.
14288         * doc/posix-functions/iswalpha.texi: Likewise.
14289         * doc/posix-functions/iswblank.texi: Likewise.
14290         * doc/posix-functions/iswcntrl.texi: Likewise.
14291         * doc/posix-functions/iswctype.texi: Likewise.
14292         * doc/posix-functions/iswdigit.texi: Likewise.
14293         * doc/posix-functions/iswgraph.texi: Likewise.
14294         * doc/posix-functions/iswlower.texi: Likewise.
14295         * doc/posix-functions/iswprint.texi: Likewise.
14296         * doc/posix-functions/iswpunct.texi: Likewise.
14297         * doc/posix-functions/iswspace.texi: Likewise.
14298         * doc/posix-functions/iswupper.texi: Likewise.
14299         * doc/posix-functions/iswxdigit.texi: Likewise.
14300         * doc/posix-functions/mbrtowc.texi: Likewise.
14301         * doc/posix-functions/mbsrtowcs.texi: Likewise.
14302         * doc/posix-functions/mbstowcs.texi: Likewise.
14303         * doc/posix-functions/mbtowc.texi: Likewise.
14304         * doc/posix-functions/putwchar.texi: Likewise.
14305         * doc/posix-functions/putwc.texi: Likewise.
14306         * doc/posix-functions/swprintf.texi: Likewise.
14307         * doc/posix-functions/tolower.texi: Likewise.
14308         * doc/posix-functions/toupper.texi: Likewise.
14309         * doc/posix-functions/towctrans.texi: Likewise.
14310         * doc/posix-functions/ungetwc.texi: Likewise.
14311         * doc/posix-functions/vswprintf.texi: Likewise.
14312         * doc/posix-functions/wcrtomb.texi: Likewise.
14313         * doc/posix-functions/wcscat.texi: Likewise.
14314         * doc/posix-functions/wcschr.texi: Likewise.
14315         * doc/posix-functions/wcscmp.texi: Likewise.
14316         * doc/posix-functions/wcscoll.texi: Likewise.
14317         * doc/posix-functions/wcscpy.texi: Likewise.
14318         * doc/posix-functions/wcscspn.texi: Likewise.
14319         * doc/posix-functions/wcsftime.texi: Likewise.
14320         * doc/posix-functions/wcslen.texi: Likewise.
14321         * doc/posix-functions/wcsncat.texi: Likewise.
14322         * doc/posix-functions/wcsncmp.texi: Likewise.
14323         * doc/posix-functions/wcsncpy.texi: Likewise.
14324         * doc/posix-functions/wcspbrk.texi: Likewise.
14325         * doc/posix-functions/wcsrchr.texi: Likewise.
14326         * doc/posix-functions/wcsrtombs.texi: Likewise.
14327         * doc/posix-functions/wcsspn.texi: Likewise.
14328         * doc/posix-functions/wcsstr.texi: Likewise.
14329         * doc/posix-functions/wcstod.texi: Likewise.
14330         * doc/posix-functions/wcstof.texi: Likewise.
14331         * doc/posix-functions/wcstoimax.texi: Likewise.
14332         * doc/posix-functions/wcstok.texi: Likewise.
14333         * doc/posix-functions/wcstold.texi: Likewise.
14334         * doc/posix-functions/wcstoll.texi: Likewise.
14335         * doc/posix-functions/wcstol.texi: Likewise.
14336         * doc/posix-functions/wcstombs.texi: Likewise.
14337         * doc/posix-functions/wcstoull.texi: Likewise.
14338         * doc/posix-functions/wcstoul.texi: Likewise.
14339         * doc/posix-functions/wcstoumax.texi: Likewise.
14340         * doc/posix-functions/wcswidth.texi: Likewise.
14341         * doc/posix-functions/wcsxfrm.texi: Likewise.
14342         * doc/posix-functions/wctob.texi: Likewise.
14343         * doc/posix-functions/wctomb.texi: Likewise.
14344         * doc/posix-functions/wctrans.texi: Likewise.
14345         * doc/posix-functions/wctype.texi: Likewise.
14346         * doc/posix-functions/wcwidth.texi: Likewise.
14347         * doc/posix-functions/wmemchr.texi: Likewise.
14348         * doc/posix-functions/wmemcmp.texi: Likewise.
14349         * doc/posix-functions/wmemcpy.texi: Likewise.
14350         * doc/posix-functions/wmemmove.texi: Likewise.
14351         * doc/posix-functions/wmemset.texi: Likewise.
14352         * doc/posix-functions/wprintf.texi: Likewise.
14353         * doc/posix-functions/wscanf.texi: Likewise.
14354
14355 2008-12-21  Bruno Haible  <bruno@clisp.org>
14356
14357         Update doc for HP-UX 11.11.
14358         * doc/posix-functions/btowc.texi: Clarify that the function is missing
14359         in HP-UX version 11.00, not in all versions of HP-UX 11.
14360         * doc/posix-functions/fwide.texi: Likewise.
14361         * doc/posix-functions/fwprintf.texi: Likewise.
14362         * doc/posix-functions/fwscanf.texi: Likewise.
14363         * doc/posix-functions/inet_ntop.texi: Likewise.
14364         * doc/posix-functions/inet_pton.texi: Likewise.
14365         * doc/posix-functions/mbrlen.texi: Likewise.
14366         * doc/posix-functions/mbrtowc.texi: Likewise.
14367         * doc/posix-functions/mbsinit.texi: Likewise.
14368         * doc/posix-functions/mbsrtowcs.texi: Likewise.
14369         * doc/posix-functions/swprintf.texi: Likewise.
14370         * doc/posix-functions/swscanf.texi: Likewise.
14371         * doc/posix-functions/towctrans.texi: Likewise.
14372         * doc/posix-functions/vfwprintf.texi: Likewise.
14373         * doc/posix-functions/vswprintf.texi: Likewise.
14374         * doc/posix-functions/vwprintf.texi: Likewise.
14375         * doc/posix-functions/wcrtomb.texi: Likewise.
14376         * doc/posix-functions/wcsrtombs.texi: Likewise.
14377         * doc/posix-functions/wcsstr.texi: Likewise.
14378         * doc/posix-functions/wctob.texi: Likewise.
14379         * doc/posix-functions/wctrans.texi: Likewise.
14380         * doc/posix-functions/wmemchr.texi: Likewise.
14381         * doc/posix-functions/wmemcmp.texi: Likewise.
14382         * doc/posix-functions/wmemcpy.texi: Likewise.
14383         * doc/posix-functions/wmemmove.texi: Likewise.
14384         * doc/posix-functions/wmemset.texi: Likewise.
14385         * doc/posix-functions/wprintf.texi: Likewise.
14386         * doc/posix-functions/wscanf.texi: Likewise.
14387
14388 2008-12-21  Bruno Haible  <bruno@clisp.org>
14389
14390         Work around a portability problem.
14391         * tests/test-mbsrtowcs.c (main): Use a temporary conversion state.
14392         * doc/posix-functions/mbsrtowcs.texi: Document the portability problem.
14393
14394 2008-12-20  Bruno Haible  <bruno@clisp.org>
14395
14396         * lib/wchar.in.h (mbsrtowcs): Redefine if REPLACE_MBSRTOWCS is set.
14397         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): Invoke gl_MBSTATE_T_BROKEN. Set
14398         REPLACE_MBSRTOWCS if mbsrtowcs needs to be overridden.
14399         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_MBSRTOWCS.
14400         * modules/wchar (Makefile.am): Substitute REPLACE_MBSRTOWCS.
14401
14402         Work around mbrtowc bugs on AIX, HP-UX, OSF/1, Solaris.
14403         * lib/wchar.in.h (mbstate_t): Redefine also if REPLACE_MBSTATE_T is
14404         set.
14405         (GNULIB_defined_mbstate_t): New macro.
14406         (mbsinit): Redefine if REPLACE_MBSINIT is set.
14407         (mbrtowc): Redefine if REPLACE_MBRTOWC is set.
14408         * lib/mbrtowc.c (rpl_mbrtowc): Add an alternative implementation that
14409         reuses the system's mbrtowc function but works around the bugs.
14410         * m4/mbrtowc.m4 (gl_MBSTATE_T_BROKEN, gl_MBRTOWC_INCOMPLETE_STATE,
14411         gl_MBRTOWC_NULL_ARG, gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL): New
14412         macros.
14413         (gl_FUNC_MBRTOWC): Invoke them. Set REPLACE_MBRTOWC if mbrtowc needs to
14414         be overridden. Optionally define MBRTOWC_NULL_ARG_BUG,
14415         MBRTOWC_RETVAL_BUG, MBRTOWC_NUL_RETVAL_BUG.
14416         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Invoke gl_MBSTATE_T_BROKEN. Set
14417         REPLACE_MBSINIT if mbsinit needs to be overridden.
14418         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_MBSTATE_T,
14419         REPLACE_MBSINIT, REPLACE_MBRTOWC.
14420         * modules/wchar (Makefile.am): Substitute REPLACE_MBSTATE_T,
14421         REPLACE_MBSINIT, REPLACE_MBRTOWC.
14422         * modules/mbrtowc (Files): Add m4/locale-fr.m4, m4/locale-ja.m4,
14423         m4/locale-zh.m4.
14424         (Depends): Add mbsinit.
14425         * modules/mbsinit (Depends): Add mbrtowc.
14426         * doc/posix-functions/mbrtowc.texi: Mention the various bugs.
14427
14428 2008-12-20  Bruno Haible  <bruno@clisp.org>
14429
14430         * tests/test-mbrtowc.c (main): Change sample string in EUC-JP encoding
14431         so that there are no conversion errors on AIX.
14432         * tests/test-mbsrtowcs.c (main): LIkewise.
14433
14434 2008-12-20  Bruno Haible  <bruno@clisp.org>
14435
14436         Work around wctob bug on Solaris <= 9.
14437         * lib/wchar.in.h (wctob): Redefine if REPLACE_WCTOB is set.
14438         * m4/wctob.m4 (gl_FUNC_WCTOB): Test whether wctob works.
14439         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCTOB.
14440         * modules/wchar (Makefile.am): Substitute REPLACE_WCTOB.
14441         * modules/wctob (Files): Add m4/locale-fr.m4.
14442         * doc/posix-functions/wctob.texi: Mention the Solaris bug.
14443
14444 2008-12-20  Bruno Haible  <bruno@clisp.org>
14445
14446         * doc/posix-functions/select.texi: Mention Solaris 2.6 bug with
14447         /dev/null.
14448         * tests/test-select-in.sh: Likewise.
14449         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
14450
14451 2008-12-20  Bruno Haible  <bruno@clisp.org>
14452
14453         Don't pretend that Cygwin has a ja_JP.EUC-JP locale.
14454         * m4/locale-ja.m4 (gt_LOCALE_JA): Add test for MB_CUR_MAX. Needed on
14455         Cygwin 1.5.x.
14456
14457 2008-12-20  Bruno Haible  <bruno@clisp.org>
14458
14459         Ensure mbstate_t is defined on HP-UX 11.11.
14460         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Require
14461         AC_CANONICAL_HOST. On HP-UX, define _XOPEN_SOURCE to 500.
14462         * m4/mbstate_t.m4 (AC_TYPE_MBSTATE_T): Require
14463         AC_USE_SYSTEM_EXTENSIONS.
14464         * modules/fnmatch (Depends-on): Add extensions.
14465         * modules/mbrlen (Depends-on): Likewise.
14466         * modules/mbrtowc (Depends-on): Likewise.
14467         * modules/mbsinit (Depends-on): Likewise.
14468         * modules/mbsrtowcs (Depends-on): Likewise.
14469         * modules/mbswidth (Depends-on): Likewise.
14470         * modules/quotearg (Depends-on): Likewise.
14471         * modules/strftime (Depends-on): Likewise.
14472
14473 2008-12-20  Bruno Haible  <bruno@clisp.org>
14474
14475         Ensure wctob is declared on IRIX 6.5.
14476         * lib/wchar.in.h (wctob): Declare also when HAVE_DECL_WCTOB is 0.
14477         * m4/wctob.m4 (gl_FUNC_WCTOB): Set HAVE_DECL_WCTOB instead of
14478         HAVE_WCTOB. Also test whether <wchar.h> declares wctob.
14479         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize HAVE_DECL_WCTOB instead
14480         of HAVE_WCTOB.
14481         * modules/wchar (Makefile.am): Substitute HAVE_DECL_WCTOB instead of
14482         HAVE_WCTOB.
14483         * doc/posix-functions/wctob.texi: Mention missing declaration on IRIX.
14484
14485 2008-12-19  Bruno Haible  <bruno@clisp.org>
14486
14487         * modules/mbsrtowcs-tests: New file.
14488         * tests/test-mbsrtowcs1.sh: New file.
14489         * tests/test-mbsrtowcs2.sh: New file.
14490         * tests/test-mbsrtowcs3.sh: New file.
14491         * tests/test-mbsrtowcs4.sh: New file.
14492         * tests/test-mbsrtowcs.c: New file.
14493
14494         New module 'mbsrtowcs'.
14495         * lib/wchar.in.h (mbsrtowcs): New declaration.
14496         * lib/mbsrtowcs.c: New file.
14497         * m4/mbsrtowcs.m4: New file.
14498         * modules/mbsrtowcs: New file.
14499         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBSRTOWCS and
14500         HAVE_MBSRTOWCS.
14501         * modules/wchar (Makefile.am): Substitute GNULIB_MBSRTOWCS and
14502         HAVE_MBSRTOWCS.
14503         * doc/posix-functions/mbsrtowcs.texi: Document the new module.
14504
14505 2008-12-19  Bruno Haible  <bruno@clisp.org>
14506
14507         New module 'mbrlen'.
14508         * lib/wchar.in.h (mbrlen): New declaration.
14509         * lib/mbrlen.c: New file.
14510         * m4/mbrlen.m4: New file.
14511         * modules/mbrlen: New file.
14512         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBRLEN and
14513         HAVE_MBRLEN.
14514         * modules/wchar (Makefile.am): Substitute GNULIB_MBRLEN and
14515         HAVE_MBRLEN.
14516         * doc/posix-functions/mbrlen.texi: Document the new module.
14517
14518 2008-12-19  Bruno Haible  <bruno@clisp.org>
14519
14520         * lib/mbrtowc.c: Include verify.h. Verify an assumption.
14521         * modules/mbrtowc (Depends-on): Add verify.
14522         Suggested by Paul Eggert.
14523
14524 2008-12-18  Bruno Haible  <bruno@clisp.org>
14525
14526         * modules/mbsinit-tests: New file.
14527         * tests/test-mbsinit.sh: New file.
14528         * tests/test-mbsinit.c: New file.
14529
14530 2008-12-18  Bruno Haible  <bruno@clisp.org>
14531
14532         * modules/mbrtowc-tests: New file.
14533         * tests/test-mbrtowc1.sh: New file.
14534         * tests/test-mbrtowc2.sh: New file.
14535         * tests/test-mbrtowc3.sh: New file.
14536         * tests/test-mbrtowc4.sh: New file.
14537         * tests/test-mbrtowc.c: New file.
14538
14539         New module 'mbrtowc'.
14540         * lib/wchar.in.h (mbstate_t): Override when the system does not have
14541         mbsinit and mbrtowc.
14542         (mbrtowc): New declaration.
14543         * lib/mbrtowc.c: New file.
14544         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC, gl_PREREQ_MBRTOWC): New macros.
14545         * modules/mbrtowc: New file.
14546         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBRTOWC and
14547         HAVE_MBRTOWC.
14548         * modules/wchar (Makefile.am): Substitute GNULIB_MBRTOWC and
14549         HAVE_MBRTOWC.
14550         * doc/posix-functions/mbrtowc.texi: Document the new module.
14551
14552 2008-12-18  Bruno Haible  <bruno@clisp.org>
14553
14554         New module 'wctob'.
14555         * lib/wchar.in.h (wctob): New declaration.
14556         * lib/wctob.c: New file.
14557         * m4/wctob.m4: New file.
14558         * modules/wctob: New file.
14559         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCTOB and
14560         HAVE_WCTOB.
14561         * modules/wchar (Makefile.am): Substitute GNULIB_WCTOB and HAVE_WCTOB.
14562         * doc/posix-functions/wctob.texi: Document the new module.
14563
14564 2008-12-18  Bruno Haible  <bruno@clisp.org>
14565
14566         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Invoke gl_REPLACE_WCHAR_H.
14567         * m4/btowc.m4 (gl_FUNC_BTOWC): Likewise.
14568
14569 2008-12-18  Simon Josefsson  <simon@josefsson.org>
14570
14571         * lib/flock.c: Use proper #if symbol in check.  Reported by "Tom
14572         G. Christensen" <tgc@jupiterrise.com>.
14573
14574         * lib/flock.c: Need to include errno.h.  Reported by "Tom
14575         G. Christensen" <tgc@jupiterrise.com>.
14576
14577         * lib/flock.c: Need to include string.h.  Reported by "Tom
14578         G. Christensen" <tgc@jupiterrise.com> and Eric Blake
14579         <ebb9@byu.net>.
14580
14581 2008-12-18  Bruno Haible  <bruno@clisp.org>
14582
14583         * m4/locale-ja.m4: New file, from GNU gettext.
14584
14585 2008-12-17  Bruno Haible  <bruno@clisp.org>
14586
14587         * m4/mbrtowc.m4 (AC_FUNC_MBRTOWC): Don't override in autoconf >= 2.60.
14588         Suggested by Eric Blake.
14589
14590 2008-12-17  Bruno Haible  <bruno@clisp.org>
14591
14592         * m4/errno_h.m4 (AC_COMPUTE_INT): Provide fallback definition.
14593
14594 2008-12-17  Bruno Haible  <bruno@clisp.org>
14595
14596         * lib/mbsinit.c: Include verify.h. Verify an assumption.
14597         * modules/mbsinit (Depends-on): Add verify.
14598         Suggested by Paul Eggert.
14599
14600 2008-12-17  Bruno Haible  <bruno@clisp.org>
14601
14602         * m4/mbrtowc.m4 (AC_FUNC_MBRTOWC): Renamed from gl_FUNC_MBRTOWC.
14603         * m4/mbfile.m4 (gl_MBFILE): Use AC_FUNC_MBRTOWC instead of
14604         gl_FUNC_MBRTOWC.
14605         * m4/mbiter.m4 (gl_MBITER): LIkewise.
14606         * m4/mbscasecmp.m4 (gl_PREREQ_MBSCASECMP): Likewise.
14607         * m4/mbscasestr.m4 (gl_PREREQ_MBSCASESTR): Likewise.
14608         * m4/mbschr.m4 (gl_PREREQ_MBSCHR): Likewise.
14609         * m4/mbscspn.m4 (gl_PREREQ_MBSCSPN): Likewise.
14610         * m4/mbslen.m4 (gl_PREREQ_MBSLEN): Likewise.
14611         * m4/mbsncasecmp.m4 (gl_PREREQ_MBSNCASECMP): Likewise.
14612         * m4/mbsnlen.m4 (gl_PREREQ_MBSNLEN): Likewise.
14613         * m4/mbspbrk.m4 (gl_PREREQ_MBSPBRK): Likewise.
14614         * m4/mbspcasecmp.m4 (gl_PREREQ_MBSPCASECMP): Likewise.
14615         * m4/mbsrchr.m4 (gl_PREREQ_MBSRCHR): Likewise.
14616         * m4/mbssep.m4 (gl_PREREQ_MBSSEP): Likewise.
14617         * m4/mbsspn.m4 (gl_PREREQ_MBSSPN): Likewise.
14618         * m4/mbsstr.m4 (gl_PREREQ_MBSSTR): Likewise.
14619         * m4/mbstok_r.m4 (gl_PREREQ_MBSTOK_R): Likewise.
14620         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
14621         * m4/quotearg.m4 (gl_QUOTEARG): Likewise.
14622         * modules/trim (configure.ac): Likewise.
14623
14624 2008-12-17  Bruno Haible  <bruno@clisp.org>
14625
14626         * modules/btowc-tests: New file.
14627         * tests/test-btowc1.sh: New file.
14628         * tests/test-btowc2.sh: New file.
14629         * tests/test-btowc.c: New file.
14630
14631         New module 'btowc'.
14632         * lib/wchar.in.h (btowc): New declaration.
14633         * lib/btowc.c: New file.
14634         * m4/btowc.m4: New file.
14635         * modules/btowc: New file.
14636         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_BTOWC and
14637         HAVE_BTOWC.
14638         * modules/wchar (Makefile.am): Substitute GNULIB_BTOWC and HAVE_BTOWC.
14639         * doc/posix-functions/btowc.texi: Document the new module.
14640
14641 2008-12-17  Bruno Haible  <bruno@clisp.org>
14642
14643         New module 'mbsinit'.
14644         * lib/wchar.in.h (mbsinit): New declaration.
14645         * lib/mbsinit.c: New file.
14646         * m4/mbsinit.m4: New file.
14647         * modules/mbsinit: New file.
14648         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBSINIT and
14649         HAVE_MBSINIT.
14650         * modules/wchar (Makefile.am): Substitute GNULIB_MBSINIT and
14651         HAVE_MBSINIT.
14652         * doc/posix-functions/mbsinit.texi: Document the new module.
14653
14654 2008-12-16  Bruno Haible  <bruno@clisp.org>
14655
14656         * lib/unistd.in.h: Add comment.
14657         * tests/test-environ.c: Don't include <stdlib.h>.
14658
14659 2008-12-16  Bruno Haible  <bruno@clisp.org>
14660
14661         * lib/parse-duration.h (parse_duration): Document return value
14662         convention.
14663         * lib/parse-duration.c: Include specification header first. Add
14664         comments.
14665         (_): Remove macro.
14666         (parse_year_month_day, parse_hour_minute_second): Move side effects
14667         outside of strchr call.
14668         (parse_non_iso8601): Move side effects outside of isspace call.
14669         (parse_duration): Don't test errno is res != BAD_TIME. Remove fprintf
14670         call.
14671
14672 2008-12-16  Bruno Haible  <bruno@clisp.org>
14673
14674         * tests/test-parse-duration.sh: Produce no output when the test
14675         succeeds.
14676
14677 2008-12-16  Bruno Haible  <bruno@clisp.org>
14678
14679         * tests/test-parse-duration.sh: Fix quoting of $tmp and $tmpf
14680         expressions.
14681
14682 2008-12-15  Bruno Haible  <bruno@clisp.org>
14683
14684         * doc/glibc-functions/fgetxattr.texi: Tweak wording.
14685         * doc/glibc-functions/flistxattr.texi: Likewise.
14686         * doc/glibc-functions/fopencookie.texi: Likewise.
14687         * doc/glibc-functions/fremovexattr.texi: Likewise.
14688         * doc/glibc-functions/fsetxattr.texi: Likewise.
14689         * doc/glibc-functions/getxattr.texi: Likewise.
14690         * doc/glibc-functions/lgetxattr.texi: Likewise.
14691         * doc/glibc-functions/listxattr.texi: Likewise.
14692         * doc/glibc-functions/llistxattr.texi: Likewise.
14693         * doc/glibc-functions/lremovexattr.texi: Likewise.
14694         * doc/glibc-functions/lsetxattr.texi: Likewise.
14695         * doc/glibc-functions/removexattr.texi: Likewise.
14696         * doc/glibc-functions/setxattr.texi: Likewise.
14697         * doc/posix-functions/open_memstream.texi: Likewise.
14698
14699 2008-12-15  Eric Blake  <ebb9@byu.net>
14700
14701         Update doc for cygwin 1.7.
14702         * doc/posix-functions/faccessat.texi: Cygwin 1.7 added several new
14703         functions.
14704         * doc/posix-functions/fchmodat.texi: Likewise.
14705         * doc/posix-functions/fchownat.texi: Likewise.
14706         * doc/posix-functions/fdopendir.texi: Likewise.
14707         * doc/posix-functions/fmemopen.texi: Likewise.
14708         * doc/posix-functions/freeaddrinfo.texi: Likewise.
14709         * doc/posix-functions/fstatat.texi: Likewise.
14710         * doc/posix-functions/futimens.texi: Likewise.
14711         * doc/posix-functions/gai_strerror.texi: Likewise.
14712         * doc/posix-functions/getaddrinfo.texi: Likewise.
14713         * doc/posix-functions/getnameinfo.texi: Likewise.
14714         * doc/posix-functions/if_freenameindex.texi: Likewise.
14715         * doc/posix-functions/if_indextoname.texi: Likewise.
14716         * doc/posix-functions/if_nameindex.texi: Likewise.
14717         * doc/posix-functions/if_nametoindex.texi: Likewise.
14718         * doc/posix-functions/insque.texi: Likewise.
14719         * doc/posix-functions/linkat.texi: Likewise.
14720         * doc/posix-functions/llrint.texi: Likewise.
14721         * doc/posix-functions/llrintf.texi: Likewise.
14722         * doc/posix-functions/llrintl.texi: Likewise.
14723         * doc/posix-functions/lockf.texi: Likewise.
14724         * doc/posix-functions/lrintl.texi: Likewise.
14725         * doc/posix-functions/mkdirat.texi: Likewise.
14726         * doc/posix-functions/mkfifoat.texi: Likewise.
14727         * doc/posix-functions/mknodat.texi: Likewise.
14728         * doc/posix-functions/mq_close.texi: Likewise.
14729         * doc/posix-functions/mq_getattr.texi: Likewise.
14730         * doc/posix-functions/mq_notify.texi: Likewise.
14731         * doc/posix-functions/mq_open.texi: Likewise.
14732         * doc/posix-functions/mq_receive.texi: Likewise.
14733         * doc/posix-functions/mq_send.texi: Likewise.
14734         * doc/posix-functions/mq_setattr.texi: Likewise.
14735         * doc/posix-functions/mq_timedreceive.texi: Likewise.
14736         * doc/posix-functions/mq_timedsend.texi: Likewise.
14737         * doc/posix-functions/mq_unlink.texi: Likewise.
14738         * doc/posix-functions/open_memstream.texi: Likewise.
14739         * doc/posix-functions/openat.texi: Likewise.
14740         * doc/posix-functions/posix_fadvise.texi: Likewise.
14741         * doc/posix-functions/posix_fallocate.texi: Likewise.
14742         * doc/posix-functions/posix_madvise.texi: Likewise.
14743         * doc/posix-functions/posix_memalign.texi: Likewise.
14744         * doc/posix-functions/posix_openpt.texi: Likewise.
14745         * doc/posix-functions/readlinkat.texi: Likewise.
14746         * doc/posix-functions/remque.texi: Likewise.
14747         * doc/posix-functions/renameat.texi: Likewise.
14748         * doc/posix-functions/rintl.texi: Likewise.
14749         * doc/posix-functions/sem_unlink.texi: Likewise.
14750         * doc/posix-functions/shm_open.texi: Likewise.
14751         * doc/posix-functions/shm_unlink.texi: Likewise.
14752         * doc/posix-functions/signgam.texi: Likewise.
14753         * doc/posix-functions/sigset.texi: Likewise.
14754         * doc/posix-functions/stpcpy.texi: Likewise.
14755         * doc/posix-functions/stpncpy.texi: Likewise.
14756         * doc/posix-functions/strerror.texi: Likewise.
14757         * doc/posix-functions/strtod.texi: Likewise.
14758         * doc/posix-functions/symlinkat.texi: Likewise.
14759         * doc/posix-functions/unlinkat.texi: Likewise.
14760         * doc/posix-functions/utimensat.texi: Likewise.
14761         * doc/glibc-functions/bindresvport.texi: Likewise.
14762         * doc/glibc-functions/dn_expand.texi: Likewise.
14763         * doc/glibc-functions/exp10.texi: Likewise.
14764         * doc/glibc-functions/exp10f.texi: Likewise.
14765         * doc/glibc-functions/fgetxattr.texi: Likewise.
14766         * doc/glibc-functions/flistxattr.texi: Likewise.
14767         * doc/glibc-functions/fopencookie.texi: Likewise.
14768         * doc/glibc-functions/freeifaddrs.texi: Likewise.
14769         * doc/glibc-functions/fremovexattr.texi: Likewise.
14770         * doc/glibc-functions/fsetxattr.texi: Likewise.
14771         * doc/glibc-functions/getifaddrs.texi: Likewise.
14772         * doc/glibc-functions/getxattr.texi: Likewise.
14773         * doc/glibc-functions/lgetxattr.texi: Likewise.
14774         * doc/glibc-functions/listxattr.texi: Likewise.
14775         * doc/glibc-functions/llistxattr.texi: Likewise.
14776         * doc/glibc-functions/lremovexattr.texi: Likewise.
14777         * doc/glibc-functions/lsetxattr.texi: Likewise.
14778         * doc/glibc-functions/pow10.texi: Likewise.
14779         * doc/glibc-functions/pow10f.texi: Likewise.
14780         * doc/glibc-functions/rcmd_af.texi: Likewise.
14781         * doc/glibc-functions/removexattr.texi: Likewise.
14782         * doc/glibc-functions/res_init.texi: Likewise.
14783         * doc/glibc-functions/res_mkquery.texi: Likewise.
14784         * doc/glibc-functions/res_query.texi: Likewise.
14785         * doc/glibc-functions/res_querydomain.texi: Likewise.
14786         * doc/glibc-functions/res_send.texi: Likewise.
14787         * doc/glibc-functions/rresvport_af.texi: Likewise.
14788         * doc/glibc-functions/setxattr.texi: Likewise.
14789         * doc/glibc-functions/strcasestr.texi: Likewise.
14790
14791 2008-12-15  Bruno Haible  <bruno@clisp.org>
14792
14793         Fix compilation error on OSF/1 4.0.
14794         * lib/sys_select.in.h: When invoked from OSF/1 <sys/types.h> or
14795         <sys/time.h>, simply delegate to the system header.
14796         Reported by Daniel Richard G. <oss@teragram.com>.
14797
14798 2008-12-15  Bruno Haible  <bruno@clisp.org>
14799
14800         * doc/posix-functions/openat.texi: Mention the 'openat' module.
14801         * doc/posix-functions/fchmodat.texi: Likewise.
14802         * doc/posix-functions/fchownat.texi: Likewise.
14803         * doc/posix-functions/fdopendir.texi: Likewise.
14804         * doc/posix-functions/fstatat.texi: Likewise.
14805         * doc/posix-functions/mkdirat.texi: Likewise.
14806         * doc/posix-functions/unlinkat.texi: Likewise.
14807
14808 2008-12-14  Bruno Haible  <bruno@clisp.org>
14809
14810         Update doc for POSIX:2008.
14811         * doc/posix-functions/faccessat.texi: New file.
14812         * doc/posix-functions/fchmodat.texi: New file.
14813         * doc/posix-functions/fchownat.texi: New file.
14814         * doc/posix-functions/fdopendir.texi: New file.
14815         * doc/posix-functions/fstatat.texi: New file.
14816         * doc/posix-functions/futimens.texi: New file.
14817         * doc/posix-functions/linkat.texi: New file.
14818         * doc/posix-functions/mkdirat.texi: New file.
14819         * doc/posix-functions/mkfifoat.texi: New file.
14820         * doc/posix-functions/mknodat.texi: New file.
14821         * doc/posix-functions/open_wmemstream.texi: New file.
14822         * doc/posix-functions/openat.texi: New file.
14823         * doc/posix-functions/psiginfo.texi: New file.
14824         * doc/posix-functions/pthread_mutex_consistent.texi: New file.
14825         * doc/posix-functions/pthread_mutexattr_getrobust.texi: New file.
14826         * doc/posix-functions/pthread_mutexattr_setrobust.texi: New file.
14827         * doc/posix-functions/readlinkat.texi: New file.
14828         * doc/posix-functions/renameat.texi: New file.
14829         * doc/posix-functions/strerror_l.texi: New file.
14830         * doc/posix-functions/symlinkat.texi: New file.
14831         * doc/posix-functions/unlinkat.texi: New file.
14832         * doc/posix-functions/utimensat.texi: New file.
14833         * doc/gnulib.texi (Function Substitutes): Add these subsections.
14834
14835 2008-12-14  Bruno Haible  <bruno@clisp.org>
14836
14837         Update doc for POSIX:2008.
14838         * doc/posix-functions/alphasort.texi: Renamed from
14839         doc/glibc-functions/alphasort.texi.
14840         * doc/posix-functions/dirfd.texi: Renamed from
14841         doc/glibc-functions/dirfd.texi.
14842         * doc/posix-functions/dprintf.texi: Renamed from
14843         doc/glibc-functions/dprintf.texi.
14844         * doc/posix-functions/duplocale.texi: Renamed from
14845         doc/glibc-functions/duplocale.texi.
14846         * doc/posix-functions/fexecve.texi: Renamed from
14847         doc/glibc-functions/fexecve.texi.
14848         * doc/posix-functions/fmemopen.texi: Renamed from
14849         doc/glibc-functions/fmemopen.texi.
14850         * doc/posix-functions/freelocale.texi: Renamed from
14851         doc/glibc-functions/freelocale.texi.
14852         * doc/posix-functions/getdate_err.texi: Renamed from
14853         doc/glibc-functions/getdate_err.texi.
14854         * doc/posix-functions/isalnum_l.texi: Renamed from
14855         doc/glibc-functions/isalnum_l.texi.
14856         * doc/posix-functions/isalpha_l.texi: Renamed from
14857         doc/glibc-functions/isalpha_l.texi.
14858         * doc/posix-functions/isblank_l.texi: Renamed from
14859         doc/glibc-functions/isblank_l.texi.
14860         * doc/posix-functions/iscntrl_l.texi: Renamed from
14861         doc/glibc-functions/iscntrl_l.texi.
14862         * doc/posix-functions/isdigit_l.texi: Renamed from
14863         doc/glibc-functions/isdigit_l.texi.
14864         * doc/posix-functions/isgraph_l.texi: Renamed from
14865         doc/glibc-functions/isgraph_l.texi.
14866         * doc/posix-functions/islower_l.texi: Renamed from
14867         doc/glibc-functions/islower_l.texi.
14868         * doc/posix-functions/isprint_l.texi: Renamed from
14869         doc/glibc-functions/isprint_l.texi.
14870         * doc/posix-functions/ispunct_l.texi: Renamed from
14871         doc/glibc-functions/ispunct_l.texi.
14872         * doc/posix-functions/isspace_l.texi: Renamed from
14873         doc/glibc-functions/isspace_l.texi.
14874         * doc/posix-functions/isupper_l.texi: Renamed from
14875         doc/glibc-functions/isupper_l.texi.
14876         * doc/posix-functions/iswalnum_l.texi: Renamed from
14877         doc/glibc-functions/iswalnum_l.texi.
14878         * doc/posix-functions/iswalpha_l.texi: Renamed from
14879         doc/glibc-functions/iswalpha_l.texi.
14880         * doc/posix-functions/iswblank_l.texi: Renamed from
14881         doc/glibc-functions/iswblank_l.texi.
14882         * doc/posix-functions/iswcntrl_l.texi: Renamed from
14883         doc/glibc-functions/iswcntrl_l.texi.
14884         * doc/posix-functions/iswctype_l.texi: Renamed from
14885         doc/glibc-functions/iswctype_l.texi.
14886         * doc/posix-functions/iswdigit_l.texi: Renamed from
14887         doc/glibc-functions/iswdigit_l.texi.
14888         * doc/posix-functions/iswgraph_l.texi: Renamed from
14889         doc/glibc-functions/iswgraph_l.texi.
14890         * doc/posix-functions/iswlower_l.texi: Renamed from
14891         doc/glibc-functions/iswlower_l.texi.
14892         * doc/posix-functions/iswprint_l.texi: Renamed from
14893         doc/glibc-functions/iswprint_l.texi.
14894         * doc/posix-functions/iswpunct_l.texi: Renamed from
14895         doc/glibc-functions/iswpunct_l.texi.
14896         * doc/posix-functions/iswspace_l.texi: Renamed from
14897         doc/glibc-functions/iswspace_l.texi.
14898         * doc/posix-functions/iswupper_l.texi: Renamed from
14899         doc/glibc-functions/iswupper_l.texi.
14900         * doc/posix-functions/iswxdigit_l.texi: Renamed from
14901         doc/glibc-functions/iswxdigit_l.texi.
14902         * doc/posix-functions/isxdigit_l.texi: Renamed from
14903         doc/glibc-functions/isxdigit_l.texi.
14904         * doc/posix-functions/mbsnrtowcs.texi: Renamed from
14905         doc/glibc-functions/mbsnrtowcs.texi.
14906         * doc/posix-functions/mkdtemp.texi: Renamed from
14907         doc/glibc-functions/mkdtemp.texi.
14908         * doc/posix-functions/newlocale.texi: Renamed from
14909         doc/glibc-functions/newlocale.texi.
14910         * doc/posix-functions/nl_langinfo_l.texi: Renamed from
14911         doc/glibc-functions/nl_langinfo_l.texi.
14912         * doc/posix-functions/open_memstream.texi: Renamed from
14913         doc/glibc-functions/open_memstream.texi.
14914         * doc/posix-functions/opterr.texi: Renamed from
14915         doc/glibc-functions/opterr.texi.
14916         * doc/posix-functions/optind.texi: Renamed from
14917         doc/glibc-functions/optind.texi.
14918         * doc/posix-functions/optopt.texi: Renamed from
14919         doc/glibc-functions/optopt.texi.
14920         * doc/posix-functions/psignal.texi: Renamed from
14921         doc/glibc-functions/psignal.texi.
14922         * doc/posix-functions/scandir.texi: Renamed from
14923         doc/glibc-functions/scandir.texi.
14924         * doc/posix-functions/sched_get_priority_min.texi: Renamed from
14925         doc/glibc-functions/sched_get_priority_min.texi.
14926         * doc/posix-functions/signgam.texi: Renamed from
14927         doc/glibc-functions/signgam.texi.
14928         * doc/posix-functions/stpcpy.texi: Renamed from
14929         doc/glibc-functions/stpcpy.texi.
14930         * doc/posix-functions/stpncpy.texi: Renamed from
14931         doc/glibc-functions/stpncpy.texi.
14932         * doc/posix-functions/strcasecmp_l.texi: Renamed from
14933         doc/glibc-functions/strcasecmp_l.texi.
14934         * doc/posix-functions/strcoll_l.texi: Renamed from
14935         doc/glibc-functions/strcoll_l.texi.
14936         * doc/posix-functions/strfmon_l.texi: Renamed from
14937         doc/glibc-functions/strfmon_l.texi.
14938         * doc/posix-functions/strftime_l.texi: Renamed from
14939         doc/glibc-functions/strftime_l.texi.
14940         * doc/posix-functions/strncasecmp_l.texi: Renamed from
14941         doc/glibc-functions/strncasecmp_l.texi.
14942         * doc/posix-functions/strndup.texi: Renamed from
14943         doc/glibc-functions/strndup.texi.
14944         * doc/posix-functions/strnlen.texi: Renamed from
14945         doc/glibc-functions/strnlen.texi.
14946         * doc/posix-functions/strsignal.texi: Renamed from
14947         doc/glibc-functions/strsignal.texi.
14948         * doc/posix-functions/strxfrm_l.texi: Renamed from
14949         doc/glibc-functions/strxfrm_l.texi.
14950         * doc/posix-functions/timer_gettime.texi: Renamed from
14951         doc/glibc-functions/timer_gettime.texi.
14952         * doc/posix-functions/tolower_l.texi: Renamed from
14953         doc/glibc-functions/tolower_l.texi.
14954         * doc/posix-functions/toupper_l.texi: Renamed from
14955         doc/glibc-functions/toupper_l.texi.
14956         * doc/posix-functions/towctrans_l.texi: Renamed from
14957         doc/glibc-functions/towctrans_l.texi.
14958         * doc/posix-functions/towlower_l.texi: Renamed from
14959         doc/glibc-functions/towlower_l.texi.
14960         * doc/posix-functions/towupper_l.texi: Renamed from
14961         doc/glibc-functions/towupper_l.texi.
14962         * doc/posix-functions/uselocale.texi: Renamed from
14963         doc/glibc-functions/uselocale.texi.
14964         * doc/posix-functions/vdprintf.texi: Renamed from
14965         doc/glibc-functions/vdprintf.texi.
14966         * doc/posix-functions/wcpcpy.texi:
14967         Renamed from doc/glibc-functions/wcpcpy.texi.
14968         * doc/posix-functions/wcpncpy.texi: Renamed from
14969         doc/glibc-functions/wcpncpy.texi.
14970         * doc/posix-functions/wcscasecmp.texi: Renamed from
14971         doc/glibc-functions/wcscasecmp.texi.
14972         * doc/posix-functions/wcscasecmp_l.texi: Renamed from
14973         doc/glibc-functions/wcscasecmp_l.texi.
14974         * doc/posix-functions/wcscoll_l.texi: Renamed from
14975         doc/glibc-functions/wcscoll_l.texi.
14976         * doc/posix-functions/wcsdup.texi: Renamed from
14977         doc/glibc-functions/wcsdup.texi.
14978         * doc/posix-functions/wcsncasecmp.texi: Renamed from
14979         doc/glibc-functions/wcsncasecmp.texi.
14980         * doc/posix-functions/wcsncasecmp_l.texi: Renamed from
14981         doc/glibc-functions/wcsncasecmp_l.texi.
14982         * doc/posix-functions/wcsnlen.texi: Renamed from
14983         doc/glibc-functions/wcsnlen.texi.
14984         * doc/posix-functions/wcsnrtombs.texi: Renamed from
14985         doc/glibc-functions/wcsnrtombs.texi.
14986         * doc/posix-functions/wcsxfrm_l.texi: Renamed from
14987         doc/glibc-functions/wcsxfrm_l.texi.
14988         * doc/posix-functions/wctrans_l.texi: Renamed from
14989         doc/glibc-functions/wctrans_l.texi.
14990         * doc/posix-functions/wctype_l.texi: Renamed from
14991         doc/glibc-functions/wctype_l.texi.
14992         * doc/gnulib.texi (Function Substitutes): Add these subsections.
14993         (Glibc ctype.h, Glibc dirent.h, Glibc getopt.h, Glibc math.h,
14994         Glibc sched.h, Glibc signal.h, Glibc stdio.h, Glibc stdlib.h,
14995         Glibc string.h, Glibc time.h, Glibc unistd.h, Glibc wchar.h): Remove
14996         these subsections.
14997         (Glibc langinfo.h, Glibc locale.h, Glibc monetary.h, Glibc wctype.h):
14998         Remove sections.
14999
15000 2008-12-14  Bruno Haible  <bruno@clisp.org>
15001
15002         Update doc for POSIX:2008.
15003         * doc/posix-functions/*.texi: Update URL of POSIX specification.
15004
15005 2008-12-14  Bruno Haible  <bruno@clisp.org>
15006
15007         Update doc for POSIX:2008.
15008         * doc/pastposix-functions/bcmp.texi: Renamed from
15009         doc/posix-functions/bcmp.texi.
15010         * doc/pastposix-functions/bcopy.texi: Renamed from
15011         doc/posix-functions/bcopy.texi.
15012         * doc/pastposix-functions/bsd_signal.texi: Renamed from
15013         doc/posix-functions/bsd_signal.texi.
15014         * doc/pastposix-functions/bzero.texi: Renamed from
15015         doc/posix-functions/bzero.texi.
15016         * doc/pastposix-functions/ecvt.texi: Renamed from
15017         doc/posix-functions/ecvt.texi.
15018         * doc/pastposix-functions/fcvt.texi: Renamed from
15019         doc/posix-functions/fcvt.texi.
15020         * doc/pastposix-functions/ftime.texi: Renamed from
15021         doc/posix-functions/ftime.texi.
15022         * doc/pastposix-functions/gcvt.texi: Renamed from
15023         doc/posix-functions/gcvt.texi.
15024         * doc/pastposix-functions/getcontext.texi: Renamed from
15025         doc/posix-functions/getcontext.texi.
15026         * doc/pastposix-functions/gethostbyaddr.texi: Renamed from
15027         doc/posix-functions/gethostbyaddr.texi.
15028         * doc/pastposix-functions/gethostbyname.texi: Renamed from
15029         doc/posix-functions/gethostbyname.texi.
15030         * doc/pastposix-functions/getwd.texi: Renamed from
15031         doc/posix-functions/getwd.texi.
15032         * doc/pastposix-functions/h_errno.texi: Renamed from
15033         doc/posix-functions/h_errno.texi.
15034         * doc/pastposix-functions/index.texi: Renamed from
15035         doc/posix-functions/index.texi.
15036         * doc/pastposix-functions/makecontext.texi: Renamed from
15037         doc/posix-functions/makecontext.texi.
15038         * doc/pastposix-functions/mktemp.texi: Renamed from
15039         doc/posix-functions/mktemp.texi.
15040         * doc/pastposix-functions/pthread_attr_getstackaddr.texi: Renamed from
15041         doc/posix-functions/pthread_attr_getstackaddr.texi.
15042         * doc/pastposix-functions/pthread_attr_setstackaddr.texi: Renamed from
15043         doc/posix-functions/pthread_attr_setstackaddr.texi.
15044         * doc/pastposix-functions/rindex.texi: Renamed from
15045         doc/posix-functions/rindex.texi.
15046         * doc/pastposix-functions/scalb.texi: Renamed from
15047         doc/posix-functions/scalb.texi.
15048         * doc/pastposix-functions/setcontext.texi: Renamed from
15049         doc/posix-functions/setcontext.texi.
15050         * doc/pastposix-functions/swapcontext.texi: Renamed from
15051         doc/posix-functions/swapcontext.texi.
15052         * doc/pastposix-functions/ualarm.texi: Renamed from
15053         doc/posix-functions/ualarm.texi.
15054         * doc/pastposix-functions/usleep.texi: Renamed from
15055         doc/posix-functions/usleep.texi.
15056         * doc/pastposix-functions/vfork.texi: Renamed from
15057         doc/posix-functions/vfork.texi.
15058         * doc/pastposix-functions/wcswcs.texi: Renamed from
15059         doc/posix-functions/wcswcs.texi.
15060         * doc/gnulib.texi (Legacy Function Substitutes): New chapter.
15061         (Function Substitutes): Update.
15062
15063 2008-12-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15064
15065         * modules/relocatable-prog-wrapper (Depends-on): Add errno, needed by
15066         m4/strerror.m4.
15067
15068 2008-12-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15069             Bruno Haible  <bruno@clisp.org>
15070
15071         * modules/unilbrk/tables (Depends-on): Add unilbrk/base.
15072
15073 2008-12-13  Bruno Haible  <bruno@clisp.org>
15074
15075         * modules/strtoull (Depends-on): Remove unistd.
15076
15077 2008-12-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15078
15079         * modules/strtoull (Depends-on): Add stdlib.
15080
15081 2008-12-11  Simon Josefsson  <simon@josefsson.org>
15082
15083         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add more warnings.
15084
15085 2008-12-10  Jim Meyering  <meyering@redhat.com>
15086
15087         gl_ASSERT: don't say assertions are disabled when they're not
15088         * m4/assert.m4 (gl_ASSERT): Do not make configure report
15089         "checking whether to enable assertions... no", when they are in
15090         fact enabled.  This is solely a bug in the output of configure.
15091         In spite of saying "no", NDEBUG was not defined in that case.
15092         Also, as noted by Eric Blake, leave assertions enabled upon
15093         --enable-assert=INVALID.
15094
15095 2008-12-10  Bruno Haible  <bruno@clisp.org>
15096
15097         Change MODULES.html to refer to POSIX:2008 where possible.
15098         * MODULES.html.sh (POSIX2008_URL): New variable.
15099         (posix_headers): Remove sys/timeb, ucontext.
15100         (posix2001_headers): New variable.
15101         (posix_functions): Remove bcmp, bcopy, bsd_signal, bzero, ecvt, fcvt,
15102         ftime, gcvt, getcontext, gethostbyaddr, gethostbyname, getwd, h_errno,
15103         index, makecontext, mktemp, pthread_attr_getstackaddr,
15104         pthread_attr_setstackaddr, rindex, scalb, setcontext, swapcontext,
15105         ualarm, usleep, vfork, wcswcs. Add the new POSIX:2008 functions.
15106         (posix2001_functions): New variable.
15107         (func_module): Use URLs to POSIX:2008 where possible and to POSIX:2001
15108         otherwise.
15109
15110 2008-12-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15111
15112         add missing include to parse-duration.c
15113         * lib/parse-duration.c: #include "xalloc.h", for xstrdup.
15114         * modules/parse-duration (Depends-on): Add xalloc.
15115
15116         fix sed script reading maint.mk
15117         * top/maint.mk (MYSELF): New macro, define as $(srcdir)/$(ME).
15118         (syntax-check-rules): Use it.
15119
15120 2008-12-09  Bruno Haible  <bruno@clisp.org>
15121
15122         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS): Add another check, that fails on
15123         MacOS X 10.4/PowerPC.
15124         Reported by Simon Josefsson.
15125
15126 2008-12-08  Jim Meyering  <meyering@redhat.com>
15127
15128         work around mingw's lack of some S_IF definitions
15129         * lib/fts.c (S_IFLNK, S_IFSOCK): Define if not already defined.
15130         Reported by Simon Josefsson.
15131
15132 2008-12-08  Bruno Haible  <bruno@clisp.org>
15133
15134         * m4/signbitl.m4 (gl_SIGNBIT_TEST_PROGRAM): Add a link check of signbit
15135         applied to variables. Needed on MacOS X 10.4/PowerPC.
15136         Reported by Simon Josefsson.
15137
15138 2008-12-08  William Pursell  <bill.pursell@gmail.com>  (tiny change)
15139         and Eric Blake  <ebb9@byu.net>
15140
15141         assert: honor --enable-assert
15142         * m4/assert.m4 (gl_ASSERT): Synchronize with autoconf 2.64, in
15143         order to honor --enable-assert, rather than treating it as a
15144         synonym for --disable-assert.
15145
15146 2008-12-08  Jim Meyering  <meyering@redhat.com>
15147
15148         * lib/posixtm.c: Remove now-useless declaration of mktime.
15149
15150         * build-aux/announce-gen (get_tool_versions): Accept .xz tarballs.
15151
15152 2008-12-07  Bruno Haible  <bruno@clisp.org>
15153
15154         * tests/test-lock.c (test_lock, test_rwlock, test_recursive_lock,
15155         test_once): Mark functions as static.
15156         * tests/test-tls.c (test_tls): Likewise.
15157
15158 2008-12-07  Bruno Haible  <bruno@clisp.org>
15159
15160         * lib/striconveha.h (uniconv_register_autodetect): Renamed from
15161         iconv_register_autodetect.
15162
15163 2008-12-07  Jim Meyering  <meyering@redhat.com>
15164
15165         posixtm.c: avoid a warning
15166         * lib/posixtm.c (posixtime): Don't initialize tm0.
15167         It's no longer needed to placate gcc4's -Wuninitialized,
15168         and the attempt to placate would elicit a new warning.
15169
15170         unicodeio.c: mark unused parameters
15171         * lib/unicodeio.c (exit_failure_callback): Mark unused parameter.
15172         (fallback_failure_callback): Likewise.
15173
15174 2008-12-07  Bruno Haible  <bruno@clisp.org>
15175
15176         * gnulib-tool (func_create_testdir): When building the tests
15177         subdirectory, ignore the modules gnumakefile and maintainer-makefile.
15178         Reported by Simon Josefsson.
15179
15180 2008-12-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15181
15182         * doc/manywarnings.texi, doc/gnulib-intro.texi: Fix typos.
15183
15184 2008-12-06  Bruno Haible  <bruno@clisp.org>
15185
15186         * lib/c-stack.h (c_stack_action): Clarify possible side effects.
15187         Suggested by Eric Blake.
15188
15189 2008-12-06  Bruno Haible  <bruno@clisp.org>
15190
15191         Fix a c-stack test failure on MacOS X.
15192         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Require
15193         AC_CANONICAL_HOST. Define FAULT_YIELDS_SIGBUS. If set, install a signal
15194         handler for SIGBUS as well.
15195         * lib/c-stack.c (c_stack_action): If FAULT_YIELDS_SIGBUS is set,
15196         install a signal handler for SIGBUS as well.
15197         Reported by Bruce Dugan <bld0401@gmail.com> via Eric Blake.
15198
15199 2008-12-06  Bruno Haible  <bruno@clisp.org>
15200
15201         Advocacy documentation.
15202         * doc/gnulib-intro.texi (Benefits): New section.
15203         * doc/gnulib.texi: Update.
15204
15205 2008-12-06  Bruno Haible  <bruno@clisp.org>
15206
15207         Document the 'manywarnings' module.
15208         * doc/manywarnings.texi: New file.
15209         * doc/gnulib.texi: Include it.
15210
15211 2008-12-05  Eric Blake  <ebb9@byu.net>
15212
15213         tests: silence some gcc warnings
15214         * tests/test-getdate.c (LOG) [!DEBUG]: Mark no-op void.
15215         * tests/uniwidth/test-uc_width2.c (finish_interval): Avoid printf
15216         type mismatches.
15217
15218 2008-12-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15219             Bruno Haible  <bruno@clisp.org>
15220
15221         * m4/openmp.m4 (AC_OPENMP): Do not define with Autoconf 2.62 or newer.
15222
15223 2008-11-29  Jim Meyering  <meyering@redhat.com>
15224
15225         unicodeio.c: mark unused parameters
15226         * lib/unicodeio.c (exit_failure_callback): Mark unused parameter.
15227         (fallback_failure_callback): Likewise.
15228
15229         fts: fix a thinko
15230         * lib/fts.c (s_ifmt_shift_bits): Remove function.  Not needed after all.
15231         (set_stat_type): Return S_IF*-valued "type" directly.
15232         Prompted by James Youngman's spotting a related bug.
15233         Confirmed by further testing through find.
15234
15235         fts: provide dirent.d_type via FTSENT.fts_statp, when possible
15236         * lib/fts.c (D_TYPE): Define.
15237         (DT_UNKNOWN, DT_BLK, DT_CHR) [HAVE_STRUCT_DIRENT_D_TYPE]: Define.
15238         (DT_DIR, DT_FIFO, DT_LNK, DT_REG, DT_SOCK): Likewise.
15239         (s_ifmt_shift_bits): New function.
15240         (set_stat_type): New function.
15241         (fts_build): When not calling fts_stat, call set_stat_type
15242         to propagate dirent.d_type info to fts_read caller.
15243         * lib/fts_.h (FTSENT) [FTS_DEFER_STAT]: Mention that
15244         fts_statp->st_mode type information may be valid.
15245
15246 2008-11-28  Simon Josefsson  <simon@josefsson.org>
15247
15248         * lib/sys_time.in.h: Add extern "C" block for C++.  Suggested by
15249         Brian Dessent <brian@dessent.net>.  Reported by Sam Steingold
15250         <sds@gnu.org>.
15251
15252 2008-11-20  Bruno Haible  <bruno@clisp.org>
15253
15254         Attempt to work around an AIX 5.3, 6.1 compiler bug with include_next.
15255         * lib/math.in.h: Use INCLUDE_NEXT_AS_FIRST_DIRECTIVE instead of
15256         INCLUDE_NEXT.
15257         * m4/include_next.m4 (gl_INCLUDE_NEXT): Set also
15258         INCLUDE_NEXT_AS_FIRST_DIRECTIVE.
15259         * modules/math (Makefile.am): Substitute
15260         INCLUDE_NEXT_AS_FIRST_DIRECTIVE instead of INCLUDE_NEXT.
15261         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
15262
15263 2008-11-18  Alexandre Duret-Lutz  <adl@lrde.epita.fr>
15264             Bruno Haible  <bruno@clisp.org>
15265
15266         * lib/stdint.in.h: Define all type macros so that their expansion is
15267         a single typedef'ed token. Fixes a compilation failure in Boost which
15268         does "using ::int8_t;".
15269
15270 2008-11-18  Simon Josefsson  <simon@josefsson.org>
15271
15272         * m4/manywarnings.m4: New file with gl_MANYWARN_COMPLEMENT and
15273         gl_MANYWARN_ALL_GCC.
15274         * m4/warnings.m4: Removed gl_WARN_SUPPORTED and
15275         gl_WARN_COMPLEMENT.  Suggested by Bruno Haible <bruno@clisp.org>.
15276         * modules/manywarnings: New file.
15277         * MODULES.html.sh: Mention manywarnings module.
15278
15279 2008-11-18  Bruno Haible  <bruno@clisp.org>
15280
15281         * doc/gnulib-tool.texi (Unit tests): New section.
15282
15283 2008-11-18  Simon Josefsson  <simon@josefsson.org>
15284
15285         * top/maint.mk (refresh-po): Fix sed regexp to avoid problems with
15286         paths like 'lib/po/foo.po'.
15287
15288 2008-11-17  Simon Josefsson  <simon@josefsson.org>
15289
15290         * m4/warnings.m4: Improve code.  Reported by Ralf Wildenhues
15291         <Ralf.Wildenhues@gmx.de> and Paolo Bonzini <bonzini@gnu.org>.
15292
15293 2008-11-17  Simon Josefsson  <simon@josefsson.org>
15294
15295         * m4/warnings.m4: Use CPPFLAGS to really check whether the
15296         parameter works.
15297
15298 2008-11-17  Simon Josefsson  <simon@josefsson.org>
15299
15300         * m4/warnings.m4: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.
15301
15302 2008-11-17  Bruce Korb  <bkorb@gnu.org>
15303
15304         * modules/parse-duration-tests: New file.
15305         * tests/test-parse-duration.sh: New file.
15306         * tests/test-parse-duration.c: New file.
15307
15308         New module 'parse-duration'.
15309         * lib/parse-duration.h: New file.
15310         * lib/parse-duration.c: New file.
15311         * modules/parse-duration: New file.
15312
15313 2008-11-17  Bruno Haible  <bruno@clisp.org>
15314
15315         * tests/test-select-out.sh: Comment out the first pipe test.
15316         Reported by Simon Josefsson.
15317
15318 2008-11-17  Bruno Haible  <bruno@clisp.org>
15319
15320         * modules/getaddrinfo (Depends-on): Add servent, hostent.
15321         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_SERVENT and
15322         gl_HOSTENT.
15323
15324 2008-11-17  Bruno Haible  <bruno@clisp.org>
15325
15326         * m4/sockets.m4 (gl_SOCKETS): After trying -lsocket, try also
15327         -lnetwork and -lnet. Needed for Haiku and BeOS.
15328
15329 2008-11-16  Bruno Haible  <bruno@clisp.org>
15330
15331         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix indentation.
15332
15333 2008-11-16  Bruno Haible  <bruno@clisp.org>
15334
15335         Avoid test failure on Haiku.
15336         * tests/test-fsync.c: Include <errno.h>.
15337         (main): Don't require that fsync (0) fails.
15338
15339 2008-11-15  Bruno Haible  <bruno@clisp.org>
15340
15341         New module 'hostent'.
15342         * modules/hostent: New file.
15343         * m4/hostent.m4: New file, based on code in m4/getaddrinfo.m4.
15344
15345 2008-11-15  Bruno Haible  <bruno@clisp.org>
15346
15347         New module 'servent'.
15348         * modules/servent: New file.
15349         * m4/servent.m4: New file, based on code in m4/getaddrinfo.m4.
15350
15351 2008-11-15  Bruno Haible  <bruno@clisp.org>
15352
15353         Avoid generating same test program with two different rules.
15354         * modules/frexp-nolibm-tests (Makefile.am): Rename test program from
15355         test-frexp to test-frexp-nolibm.
15356         * modules/frexpl-nolibm-tests (Makefile.am): Rename test program from
15357         test-frexpl to test-frexpl-nolibm.
15358
15359 2008-11-15  Bruno Haible  <bruno@clisp.org>
15360
15361         * modules/frexpl-tests (Makefile.am): Link test-frexpl with
15362         $(FREXPL_LIBM).
15363
15364 2008-11-15  Bruno Haible  <bruno@clisp.org>
15365
15366         * lib/netdb.in.h: Activate the definitions also when the system's
15367         <netdb.h> has 'struct addrinfo'.
15368         * m4/netdb_h.m4 (gl_HEADER_NETDB): Replace netdb.h also when it lacks
15369         EAI_OVERFLOW or AI_NUMERICSERV.
15370         * doc/posix-headers/netdb.texi: Document the problem.
15371
15372 2008-11-15  Bruno Haible  <bruno@clisp.org>
15373
15374         * tests/test-sched.c: Test also the existence of the SCHED_* macros.
15375
15376         Make the 'sched' module work on platforms where <sched.h> exists but
15377         is incomplete (such as Haiku).
15378         * lib/sched.in.h; Include the system's <sched.h> if it exists.
15379         (SCHED_FIFO, SCHED_RR, SCHED_OTHER): New macros.
15380         * m4/sched_h.m4 (gl_SCHED_H): Test whether <sched.h> exists and also
15381         defines SCHED_FIFO, SCHED_RR, SCHED_OTHER. Set HAVE_SCHED_H,
15382         HAVE_STRUCT_SCHED_PARAM.
15383         * modules/sched (Depends-on): Add include_next.
15384         (Makefile.am): Substitute HAVE_SCHED_H, INCLUDE_NEXT,
15385         PRAGMA_SYSTEM_HEADER, NEXT_SCHED_H, HAVE_STRUCT_SCHED_PARAM.
15386         * doc/posix-headers/sched.texi: Document the issue.
15387
15388 2008-11-13  Jim Meyering  <meyering@redhat.com>
15389
15390         test-argp-2: avoid test failure when PACKAGE_BUGREPORT is defined
15391         * tests/test-argp-2.sh: When PACKAGE_BUGREPORT was defined, this
15392         test would fail due to the difference in the Report bugs to ...
15393         line.  The expected address is empty, "<>", while the actual
15394         would contain e.g., "<bug-tar@gnu.org>".  Filter out any address.
15395
15396 2008-11-12  Bruno Haible  <bruno@clisp.org>
15397
15398         lstat: don't compile lstat.c on systems lacking lstat
15399         * m4/lstat.m4 (gl_FUNC_LSTAT): Don't compile lstat.c on systems
15400         which don't have lstat; this is handled by lib/sys_stat.in.h already.
15401         Reported by Daniel P. Berrange via Jim Meyering.
15402
15403 2008-11-12  Jim Meyering  <meyering@redhat.com>
15404
15405         * lib/unicodeio.c (unicode_to_mb): Correct spelling of u8_uctomb.
15406
15407 2008-11-12  Simon Josefsson  <simon@josefsson.org>
15408
15409         * modules/warnings (configure.ac): Do AC_SUBST([WARN_CFLAGS]) here
15410         instead.
15411
15412 2008-11-12  Bruno Haible  <bruno@clisp.org>
15413
15414         * lib/unicodeio.c: Include unistr.h.
15415         (utf8_wctomb): Remove function.
15416         (unicode_to_mb): Use utf8_uctomb instead of utf8_wctomb.
15417
15418 2008-11-12  Simon Josefsson  <simon@josefsson.org>
15419
15420         * m4/warnings.m4 (gl_WARN_INIT): Remove, suggested by Ralf
15421         Wildenhues <Ralf.Wildenhues@gmx.de> and Bruno Haible
15422         <bruno@clisp.org>.
15423         * modules/warnings (configure.ac): Don't call gl_WARN_INIT.
15424
15425 2008-11-12  Simon Josefsson  <simon@josefsson.org>
15426
15427         * doc/warnings.texi: New file, from Bruno Haible <bruno@clisp.org>.
15428         * doc/gnulib.texi: Add section for warnings.
15429
15430 2008-11-11  Bruno Haible  <bruno@clisp.org>
15431
15432         * lib/sockets.h: Add a comment.
15433
15434 2008-11-11  Karl Berry  <karl@gnu.org>
15435
15436         * config/srclist.txt (fdl.texi): add, syncing from gnustandards.
15437
15438 2008-11-11  Eric Blake  <ebb9@byu.net>
15439
15440         fdl.texi: avoid git symlinks
15441         * doc/fdl.texi: Copy, rather than link, fdl-1.3.texi.
15442
15443 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
15444
15445         * m4/warnings.m4 (gl_WARN_ADD): Don't AC_SUBST the empty string.
15446
15447 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
15448
15449         * m4/warnings.m4 (gl_WARN_INIT): Substitute WARN_CFLAGS.
15450         (gl_WARN_ADD): Substitute $2 if literal.
15451
15452 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
15453
15454         * m4/warning.m4: Remove.
15455
15456 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
15457
15458         * m4/warnings.m4: Almost complete rewrite. :-)
15459
15460 2008-11-10  Simon Josefsson  <simon@josefsson.org>
15461
15462         * modules/warnings: New module.
15463         * m4/warnings.m4: New file.
15464         * MODULES.html.sh: Mention warnings module.
15465         With review improvements from Paolo Bonzini <bonzini@gnu.org> and
15466         Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
15467
15468 2008-11-10  Eric Blake  <ebb9@byu.net>
15469
15470         fdl.texi: make a symlink to the latest version
15471         * doc/standards.texi: Revert today's earlier change.
15472         * doc/fdl-1.2.texi: Rename from old fdl.texi...
15473         * doc/fdl.texi: ...and replace this with a symlink to the newer
15474         fdl-1.3.texi.
15475
15476 2008-11-10  Bruno Haible  <bruno@clisp.org>
15477
15478         * tests/test-select-fd.c (main): Accept the result file name as fourth
15479         argument.
15480         * tests/test-select-in.sh: Pass t-select-in.tmp as fourth argument.
15481         * tests/test-select-out.sh: Pass t-select-out.tmp as fourth argument.
15482
15483 2008-11-10  Bruno Haible  <bruno@clisp.org>
15484
15485         * lib/netdb.in.h: Use HAVE_STRUCT_ADDRINFO, HAVE_DECL_GETADDRINFO,
15486         HAVE_DECL_FREEADDRINFO, HAVE_DECL_GAI_STRERROR, HAVE_DECL_GETNAMEINFO
15487         as autoconf-substituted macros.
15488         * m4/netdb_h.m4 (gl_NETDB_H_DEFAULTS): Initialize these variables to 1.
15489         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require
15490         gl_NETDB_H_DEFAULTS. Set these variables.
15491         * modules/netdb (Makefile.am): Substitute these variables.
15492
15493 2008-11-10  Eric Blake  <ebb9@byu.net>
15494
15495         standards.texi: include correct file for FDL 1.3
15496         * doc/standards.texi (GNU Free Documentation License): Change
15497         include file to pull in FDL 1.3, not 1.2.
15498
15499         fdl.texi: revert accidental change to license
15500         * doc/fdl.texi: This is FDL 1.2, not 1.3.
15501
15502 2008-11-10  Bruno Haible  <bruno@clisp.org>
15503
15504         * m4/printf.m4 (gl_PRINTF_ENOMEM): Guess yes on Haiku. Use the
15505         cross-compiling guesses also when the native compile gives no result.
15506
15507 2008-11-10  Bruno Haible  <bruno@clisp.org>
15508
15509         * lib/spawni.c (__spawni): Force variable into the stack.
15510
15511 2008-11-10  Bruno Haible  <bruno@clisp.org>
15512
15513         Add support for Haiku.
15514         * lib/fbufmode.c (fbufmode): Test a symbol that is not only defined on
15515         glibc and BeOS, but also on Haiku.
15516         * lib/fpurge.c (fpurge): Likewise.
15517         * lib/freadable.c (freadable): Likewise.
15518         * lib/freadahead.c (freadahead): Likewise.
15519         * lib/freading.c (freading): Likewise.
15520         * lib/freadptr.c (freadptr): Likewise.
15521         * lib/freadseek.c (freadptrinc): Likewise.
15522         * lib/fseeko.c (rpl_fseeko): Likewise.
15523         * lib/fseterr.c (fseterr): Likewise.
15524         * lib/fwritable.c (fwritable): Likewise.
15525         * lib/fwriting.c (fwriting): Likewise.
15526         Reported by Ingo Weinhold <ingo_weinhold@gmx.de>.
15527
15528 2008-11-10  Ingo Weinhold  <ingo_weinhold@gmx.de>
15529
15530         * lib/config.charset: Treat Haiku like BeOS.
15531
15532 2008-11-10  Ingo Weinhold  <ingo_weinhold@gmx.de>
15533
15534         * lib/binary-io.h (O_BINARY, O_TEXT): Treat Haiku like BeOS.
15535         * lib/fcntl.in.h (O_BINARY, O_TEXT): Likewise.
15536
15537 2008-11-08  Bruno Haible  <bruno@clisp.org>
15538
15539         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Avoid using AC_CHECK_DECL inside
15540         AC_CACHE_CHECK.
15541
15542 2008-11-08  Bruno Haible  <bruno@clisp.org>
15543
15544         * modules/select-tests (configure.ac): Check for unistd.h, sys/wait.h.
15545
15546 2008-11-08  Bruno Haible  <bruno@clisp.org>
15547
15548         * tests/test-select-fd.c: New file.
15549         * tests/test-select-in.sh: New file.
15550         * tests/test-select-out.sh: New file.
15551         * tests/test-select-stdin.c: New file.
15552         * modules/select-tests (Files): Add the new files.
15553         (Depends-on): Add gettimeofday.
15554         (Makefile.am): Add test-select-in.sh, test-select-out.sh to TESTS.
15555         Set TESTS_ENVIRONMENT. Add test-select-fd, test-select-stdin to
15556         check_PROGRAMS. Define test_select_fd_LDADD, test_select_stdin_LDADD.
15557
15558 2008-11-06  Alexander V. Lukyanov  <lav@netis.ru>
15559             Bruno Haible  <bruno@clisp.org>
15560
15561         * lib/sys_stat.in.h: Enclose function definitions in extern "C".
15562
15563 2008-10-12  Giuseppe Scrivano  <gscrivano@gnu.org>
15564
15565         * build-aux/pmccabe2html: Added support for C++ source files.
15566
15567 2008-11-05  Ben Pfaff  <blp@gnu.org>
15568
15569         Fix lib/close.c build on Windows.
15570         * modules/close (Files): Add lib/w32sock.h.
15571
15572 2008-11-05  Joel E. Denny  <jdenny@ces.clemson.edu>
15573
15574         Accept Bison's NEWS format.
15575         * build-aux/announce-gen (print_news_deltas): Tweak
15576         $re_prefix.
15577
15578 2008-11-04  Bruno Haible  <bruno@clisp.org>
15579
15580         * modules/random_r (Maintainer): Add glibc.
15581
15582 2008-11-04  Simon Josefsson  <simon@josefsson.org>
15583
15584         * doc/alloca-opt.texi: Change license to GFDLv1.3+, as suggested
15585         by karl@freefriends.org (Karl Berry).
15586         * doc/alloca.texi: Likewise.
15587         * doc/c-ctype.texi: Likewise.
15588         * doc/c-strcase.texi: Likewise.
15589         * doc/c-strcaseeq.texi: Likewise.
15590         * doc/c-strcasestr.texi: Likewise.
15591         * doc/c-strstr.texi: Likewise.
15592         * doc/c-strtod.texi: Likewise.
15593         * doc/c-strtold.texi: Likewise.
15594         * doc/ctime.texi: Likewise.
15595         * doc/error.texi: Likewise.
15596         * doc/fdl.texi: Likewise.
15597         * doc/gcd.texi: Likewise.
15598         * doc/getdate.texi: Likewise.
15599         * doc/gnulib-intro.texi: Likewise.
15600         * doc/gnulib-tool.texi: Likewise.
15601         * doc/gnulib.texi: Likewise.
15602         * doc/inet_ntoa.texi: Likewise.
15603         * doc/maintain.texi: Likewise.
15604         * doc/make-stds.texi: Likewise.
15605         * doc/quote.texi: Likewise.
15606         * doc/regexprops-generic.texi: Likewise.
15607         * doc/standards.texi: Likewise.
15608         * doc/verify.texi: Likewise.
15609         * doc/visibility.texi: Likewise.
15610         * doc/gnulib.texi (GNU Free Documentation License): Include
15611         fdl-1.3.texi instead of fdl.texi.
15612
15613 2008-11-04  Simon Josefsson  <simon@josefsson.org>
15614
15615         * doc/fdl-1.3.texi: New file, from
15616         <http://www.gnu.org/licenses/fdl-1.3.texi>.
15617         * modules/fdl-1.3: Add.
15618         * MODULES.html.sh: Add fdl-1.3.
15619
15620 2008-11-03  Bruno Haible  <bruno@clisp.org>
15621
15622         Make determination of absolute name of header file work with AIX xlc.
15623         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Require
15624         AC_CANONICAL_HOST. On AIX, use "$CPP -C" rather than "$CPP" for
15625         preprocessing.
15626         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
15627         Reported by Gary V. Vaughan <gary@thewrittenword.com>.
15628
15629 2008-11-03  Simon Josefsson  <simon@josefsson.org>
15630
15631         * top/maint.mk (COVERAGE_CCOPTS): Use --coverage instead of
15632         -fprofile-arcs -ftest-coverage.  Suggested by Ludovic Courtès
15633         <ludo@gnu.org>.
15634
15635 2008-11-02  Bruno Haible  <bruno@clisp.org>
15636
15637         Mark 'strpbrk' obsolete.
15638         * modules/strpbrk (Status, Notice): New sections.
15639         * modules/strtok_r (Depends-on): Add strpbrk.
15640
15641 2008-11-02  Bruno Haible  <bruno@clisp.org>
15642
15643         Mark 'strdup' obsolete.
15644         * modules/strdup (Status, Notice): New sections.
15645         * modules/findprog (Depends-on): Add strdup.
15646         * modules/getaddrinfo (Depends-on): Likewise.
15647         * modules/localename (Depends-on): Likewise.
15648         * modules/relocatable-lib (Depends-on): Likewise.
15649         * modules/relocatable-lib-lgpl (Depends-on): Likewise.
15650         * modules/relocatable-prog (Depends-on): Likewise.
15651         * modules/trim (Depends-on): Likewise.
15652         * modules/unictype/gen-ctype (Depends-on): Likewise.
15653         * modules/unilbrk/gen-lbrk (Depends-on): Likewise.
15654
15655 2008-11-02  Bruno Haible  <bruno@clisp.org>
15656
15657         Mark 'strcspn' obsolete.
15658         * modules/strcspn (Status, Notice): New sections.
15659
15660 2008-11-02  Bruno Haible  <bruno@clisp.org>
15661
15662         Mark 'rmdir' obsolete.
15663         * modules/rmdir (Status, Notice): New sections.
15664         * modules/clean-temp (Depends-on): Add rmdir.
15665         * modules/openat (Depends-on): Likewise.
15666
15667 2008-11-02  Bruno Haible  <bruno@clisp.org>
15668
15669         Mark 'raise' obsolete.
15670         * modules/raise (Status, Notice): New sections.
15671         (Include): Specify <signal.h>.
15672         * modules/stdio (Depends-on): Add raise.
15673         * modules/write (Depends-on): Likewise.
15674
15675 2008-11-02  Bruno Haible  <bruno@clisp.org>
15676
15677         Mark 'memset' obsolete.
15678         * modules/memset (Status, Notice): New sections.
15679
15680 2008-11-02  Bruno Haible  <bruno@clisp.org>
15681
15682         Mark 'memmove' obsolete.
15683         * modules/memmove (Status, Notice): New sections.
15684         * modules/argp (Depends-on): Add memmove.
15685         * modules/argz (Depends-on): Likewise.
15686         * modules/canonicalize (Depends-on): Likewise.
15687         * modules/canonicalize-lgpl (Depends-on): Likewise.
15688         * modules/fts (Depends-on): Likewise.
15689         * modules/getcwd (Depends-on): Likewise.
15690         * modules/human (Depends-on): Likewise.
15691         * modules/regex (Depends-on): Likewise.
15692         * modules/striconveh (Depends-on): Likewise.
15693         * modules/trim (Depends-on): Likewise.
15694         * modules/unistr/u8-move (Depends-on): Likewise.
15695         * modules/unistr/u16-move (Depends-on): Likewise.
15696         * modules/unistr/u32-move (Depends-on): Likewise.
15697
15698 2008-11-02  Bruno Haible  <bruno@clisp.org>
15699
15700         Mark 'memcpy' obsolete.
15701         * modules/memcpy (Status, Notice): New sections.
15702
15703 2008-11-02  Bruno Haible  <bruno@clisp.org>
15704
15705         Mark 'memcmp' obsolete.
15706         * modules/memcmp (Status, Notice): New sections.
15707         * modules/argmatch (Depends-on): Add memchr.
15708         * modules/backupfile (Depends-on): Likewise.
15709         * modules/c-strcasestr (Depends-on): Likewise.
15710         * modules/crypto/des (Depends-on): Likewise.
15711         * modules/csharpcomp (Depends-on): Likewise.
15712         * modules/fnmatch (Depends-on): Likewise.
15713         * modules/git-merge-changelog (Depends-on): Likewise.
15714         * modules/isnand (Depends-on): Likewise.
15715         * modules/isnand-nolibm (Depends-on): Likewise.
15716         * modules/isnanf (Depends-on): Likewise.
15717         * modules/isnanf-nolibm (Depends-on): Likewise.
15718         * modules/isnanl (Depends-on): Likewise.
15719         * modules/isnanl-nolibm (Depends-on): Likewise.
15720         * modules/mbchar (Depends-on): Likewise.
15721         * modules/memcoll (Depends-on): Likewise.
15722         * modules/quotearg (Depends-on): Likewise.
15723         * modules/regex (Depends-on): Likewise.
15724         * modules/relocatable-prog (Depends-on): Likewise.
15725         * modules/same (Depends-on): Likewise.
15726         * modules/signbit (Depends-on): Likewise.
15727         * modules/strcasestr-simple (Depends-on): Likewise.
15728         * modules/unictype/gen-ctype (Depends-on): Likewise.
15729         * modules/unilbrk/gen-lbrk (Depends-on): Likewise.
15730         * modules/uniname/uniname (Depends-on): Likewise.
15731         * modules/unistr/u8-cmp (Depends-on): Likewise.
15732
15733 2008-11-02  Bruno Haible  <bruno@clisp.org>
15734
15735         Mark 'memchr' obsolete.
15736         * modules/memchr (Status, Notice): New sections.
15737         * modules/argp (Depends-on): Add memchr.
15738         * modules/base64 (Depends-on): Likewise.
15739         * modules/c-strcasestr (Depends-on): Likewise.
15740         * modules/chdir-long (Depends-on): Likewise.
15741         * modules/fnmatch (Depends-on): Likewise.
15742         * modules/getsubopt (Depends-on): Likewise.
15743         * modules/git-merge-changelog (Depends-on): Likewise.
15744         * modules/glob (Depends-on): Likewise.
15745         * modules/strcasestr-simple (Depends-on): Likewise.
15746         * modules/strnlen (Depends-on): Likewise.
15747
15748 2008-11-02  Bruno Haible  <bruno@clisp.org>
15749
15750         Mark 'atexit' obsolete.
15751         * modules/atexit (Status, Notice): New sections.
15752         * modules/chdir-long (Depends-on): Add atexit.
15753         * modules/wait-process (Depends-on): Likewise.
15754
15755 2008-11-02  Bruno Haible  <bruno@clisp.org>
15756
15757         * gnulib-tool: New option --with-obsolete.
15758         (func_usage): Document it.
15759         (func_modules_transitive_closure): Drop obsolete dependencies if
15760         incobsolete is not true.
15761         (func_import): Read and save the incobsolete variable to the cache.
15762
15763 2008-11-02  Bruno Haible  <bruno@clisp.org>
15764
15765         * modules/TEMPLATE-EXTENDED: New field 'Status'.
15766         * gnulib-tool: New option --extract-status.
15767         (func_usage): Document it.
15768         (sed_extract_prog): Recognize it.
15769         (func_get_status): New function.
15770
15771 2008-10-30  Simon Josefsson  <simon@josefsson.org>
15772
15773         * modules/sockets (License): Change from LGPL to LGPLv2+.
15774
15775 2008-10-28  Simon Josefsson  <simon@josefsson.org>
15776
15777         * top/maint.mk: Add coverage rules, inspired by scripts in gnupdf.
15778
15779 2008-10-28  Simon Josefsson  <simon@josefsson.org>
15780
15781         * MODULES.html.sh (Support for systems lacking POSIX:2001):
15782         Mention times and sys_times.
15783         * modules/sys_times, modules/sys_times-tests: New modules.
15784         * modules/times, modules/times-tests: Likewise
15785         * m4/sys_times_h.m4: New file.
15786         * lib/sys_times.in.h: Likewise
15787         * lib/times.c: Likewise.
15788         * tests/test-sys_times.c: Likewise.
15789         * tests/test-times.c: Likewise.
15790         * doc/posix-headers/sys_times.texi: Update.
15791         * doc/posix-functions/times.texi: Update.
15792
15793 2008-10-28  Jim Meyering  <meyering@redhat.com>
15794
15795         * modules/tempname (Depends-on): Add lstat.
15796
15797         * modules/lstat (License): Relicense: LGPL -> LGPLv2+.
15798
15799 2008-10-28  Simon Josefsson  <simon@josefsson.org>
15800
15801         * gnulib-tool (func_emit_tests_Makefile_am): Revert last commit.
15802         * modules/argp-tests (test_argp_LDADD): Set EXEEXT here instead,
15803         using idiom used elsewhere in gnulib.
15804
15805 2008-10-27  Jim Meyering  <meyering@redhat.com>
15806
15807         * modules/gethostname (License): Relicense: LGPL -> LGPLv2+.
15808
15809 2008-10-27  Simon Josefsson  <simon@josefsson.org>
15810
15811         * gnulib-tool (func_emit_tests_Makefile_am): Set EXEEXT in
15812         TESTS_ENVIRONMENT, for shell scripts that needs to call built
15813         programs.
15814         * tests/test-argp-2.sh: Use $EXEEXT when needed.
15815
15816 2008-10-27  Simon Josefsson  <simon@josefsson.org>
15817
15818         * lib/sys_stat.in.h (lstat): Fix declaration for mingw.
15819
15820 2008-10-27  Bruno Haible  <bruno@clisp.org>
15821
15822         * tests/test-lstat.c: Include <stdio.h>.
15823
15824 2008-10-27  Simon Josefsson  <simon@josefsson.org>
15825
15826         * modules/lstat-tests: New module.
15827         * tests/test-lstat.c: New file.
15828
15829 2008-10-26  Jim Meyering  <meyering@redhat.com>
15830
15831         * lib/mkdir.c (rpl_mkdir) [_WIN32...]: Mark mode as an unused parameter.
15832
15833 2008-10-26  Simon Josefsson  <simon@josefsson.org>
15834             Bruno Haible  <bruno@clisp.org>
15835
15836         Fix a clash between the type DATADIR on Windows and the macro DATADIR.
15837         * modules/configmake (Include): Add a note that the include must come
15838         after all system headers.
15839         * lib/javaversion.c: Include configmake.h after all other includes.
15840
15841 2008-10-26  Bruno Haible  <bruno@clisp.org>
15842
15843         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Set default of
15844         HAVE_STRUCT_RANDOM_DATA to 1.
15845         (gl_STDLIB_H): Simplify.
15846
15847 2008-10-26  Simon Josefsson  <simon@josefsson.org>
15848
15849         * m4/stdlib_h.m4: Check for struct random_data.  Initialize and
15850         substitute HAVE_STRUCT_RANDOM_DATA.
15851         * lib/stdlib.in.h [!HAVE_STRUCT_RANDOM_DATA]: Provide struct
15852         random_data.
15853         * modules/stdlib (Makefile.am): Substitute
15854         HAVE_STRUCT_RANDOM_DATA.
15855
15856 2008-10-26  Simon Josefsson  <simon@josefsson.org>
15857
15858         * doc/gnulib.texi (@copying): Use GFDLv1.2+.
15859         * doc/gnulib-intro.texi (Copyright): Likewise.
15860
15861 2008-10-26  Simon Josefsson  <simon@josefsson.org>
15862
15863         * doc/gnulib.texi (Header files): C++ fixes, based on Bruno's
15864         findings.
15865
15866 2008-10-25  Ben Pfaff  <blp@cs.stanford.edu>
15867             Bruno Haible  <bruno@clisp.org>
15868
15869         * lib/unistd.in.h: Include <winsock2.h>.
15870         (socket, connect,accept, bind, getpeername, getsockname, getsockopt,
15871         listen, recv, send, recvfrom, sendto, setsockopt, shutdown, select):
15872         Provide dummy declarations.
15873         (gethostname): Override.
15874         * lib/sys_socket.in.h (gethostname): Provide dummy declaration.
15875         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Invoke
15876         gl_PREREQ_SYS_H_WINSOCK2.
15877         * modules/gethostname (Files): Add m4/sys_socket_h.m4.
15878         * doc/posix-functions/gethostname.texi: More details.
15879
15880 2008-10-25  Bruno Haible  <bruno@clisp.org>
15881
15882         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): Require
15883         gl_UNISTD_H_DEFAULTS, gl_SYS_IOCTL_H_DEFAULTS only if they exist.
15884         * modules/sys_socket (Files): Remove m4/unistd_h.m4, m4/sys_ioctl_h.m4.
15885
15886         * lib/sys_socket.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET); Move macro from
15887         here ...
15888         * lib/unistd.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET); ... to here.
15889         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Remove invocation of
15890         gl_UNISTD_H_DEFAULTS.
15891
15892 2008-10-25  Eric Blake  <ebb9@byu.net>
15893
15894         signbit: avoid spurious compiler failure
15895         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Move non-constant
15896         declarations inside function.
15897
15898 2008-10-24  Simon Josefsson  <simon@josefsson.org>
15899             Bruno Haible  <bruno@clisp.org>
15900
15901         * lib/stdlib.in.h (@GNULIB_RANDOM_R@): Include stdint.h.
15902         * modules/random_r (Depends-on): Add stdint.
15903
15904 2008-10-24  Bruno Haible  <bruno@clisp.org>
15905
15906         * modules/intprops (License): Change to LGPLv2+, with approval by Paul
15907         Eggert.
15908         * modules/strerror (License): Likewise.
15909
15910 2008-10-24  Jim Meyering  <meyering@redhat.com>
15911
15912         sys_socket: fix typo that inhibited expansion of @GNULIB_SEND@
15913         * modules/sys_socket (Depends-on) [Depends-on]: Fix typo.
15914
15915 2008-10-24  Eric Blake  <ebb9@byu.net>
15916
15917         getgroups: fix compilation when getgroups is available
15918         * lib/getgroups.c (includes): Include <unistd.h> for getgroups,
15919         but with <config.h> override of getgroups disabled.
15920
15921 2008-10-24  Simon Josefsson  <simon@josefsson.org>
15922
15923         * doc/gnulib.texi (Header files): Add note about C++ problems.
15924         Explained by Bruno Haible <bruno@clisp.org>.
15925
15926 2008-10-23  Bruno Haible  <bruno@clisp.org>
15927
15928         Define a dummy SA_NODEFER macro on Interix.
15929         * lib/signal.in.h (SA_NODEFER): Define fallback.
15930         Reported by Aleksey Cheusov <cheusov@tut.by> via
15931         Thomas Klausner <wiz@netbsd.org> and Eric Blake.
15932
15933 2008-10-23  Bruno Haible  <bruno@clisp.org>
15934
15935         * modules/freadahead (License): Change to LGPLv2+.
15936         Suggested by Simon Josefsson.
15937
15938 2008-10-23  Jim Meyering  <meyering@redhat.com>
15939
15940         random_r: new module
15941         * modules/random_r: New file.
15942         * m4/random_r.m4: New file.
15943         * lib/random_r.c: New file, from glibc.
15944         * modules/random_r-tests: New file.
15945         * tests/test-random_r.c: New file.
15946         * lib/stdlib.in.h (srandom_r, initstate_r, setstate_r, random_r):
15947          Declare.
15948         (RAND_MAX): Define.
15949         * m4/stdlib_h.m4: Define and AC_SUBST GNULIB_RANDOM_R and HAVE_RANDOM_R.
15950         * modules/stdlib: Substitute them, too.
15951         * MODULES.html.sh (Extra functions based on POSIX:2001) [Misc]: Add it.
15952         * doc/glibc-functions/initstate_r.texi: Mention the new module.
15953         * doc/glibc-functions/random_r.texi: Likewise.
15954         * doc/glibc-functions/setstate_r.texi: Likewise.
15955         * doc/glibc-functions/srandom_r.texi: Likewise.
15956         * config/srclist.txt: Mention it.
15957
15958 2008-10-23  David Lutterkort  <lutter@redhat.com>
15959
15960         * modules/selinux-h: Search for LIB_SELINUX and mark it as a
15961         link requirement
15962
15963 2008-10-23  Jim Meyering  <meyering@redhat.com>
15964
15965         selinux-h: mark parameters of stub functions as intentionally unused
15966         * lib/se-selinux.in.h: Mark parameters as _UNUSED_PARAMETER_.
15967         * lib/se-context.in.h: Likewise.
15968
15969 2008-10-22  Simon Josefsson  <simon@josefsson.org>
15970
15971         * lib/sys_socket.in.h (FD_ISSET): Fix warnings under mingw.
15972
15973 2008-10-22  Simon Josefsson  <simon@josefsson.org>
15974
15975         * m4/getgroups.m4: Avoid invoking test with wrong parameters.
15976
15977 2008-10-22  Eric Blake  <ebb9@byu.net>
15978
15979         glthread/thread: avoid compiler warning
15980         * lib/glthread/thread.c (gl_thread_exit_func) [USE_WIN32_THREADS]:
15981         Add unreachable abort to silence compiler.
15982
15983 2008-10-22  Eric Blake  <ebb9@byu.net>
15984
15985         netdb: also supply struct addrinfo for cygwin 1.5.x
15986         * m4/netdb_h.m4 (gl_HEADER_NETDB): Check for incomplete header on
15987         older cygwin.
15988         * lib/netdb.in.h [!HAVE_STRUCT_ADDRINFO]: Also supply contents for
15989         cygwin.
15990         * doc/posix-headers/netdb.texi (netdb.h): Document this.
15991
15992 2008-10-22  Bruno Haible  <bruno@clisp.org>
15993
15994         * users.txt: Update entry about pspp.
15995
15996 2008-10-21  Bruno Haible  <bruno@clisp.org>
15997
15998         Simplification.
15999         * lib/sys_socket.in.h (_gl_close_fd_maybe_socket): Remove declaration.
16000         * lib/close.c (_gl_close_fd_maybe_socket): Make static.
16001
16002         Simplification.
16003         * lib/ioctl.c (ioctl): Don't undefine.
16004         * lib/socket.c (socket): Don't undefine.
16005
16006         Remove unused module indicator macros.
16007         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR): Don't define
16008         GNULIB_$1 as a C macro.
16009
16010         * doc/posix-functions/close.texi: Undo last change.
16011         * doc/posix-functions/ioctl.texi: Merge the two paragraphs about
16012         Windows platforms.
16013
16014 2008-10-21  Bruno Haible  <bruno@clisp.org>
16015
16016         Add gethostname() declaration to <unistd.h>.
16017         * lib/unistd.in.h (gethostname): New declaration.
16018         * lib/gethostname.c: Include <unistd.h>.
16019         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Require
16020         gl_UNISTD_H_DEFAULTS. Set HAVE_GETHOSTNAME.
16021         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETHOSTNAME
16022         and HAVE_GETHOSTNAME.
16023         * modules/gethostname (Depends-on): Add unistd.
16024         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
16025         (Include): Specify <unistd.h>.
16026         * modules/unistd (Makefile.am): Substitute GNULIB_GETHOSTNAME and
16027         HAVE_GETHOSTNAME.
16028         * tests/test-gethostname.c: Include <unistd.h> first.
16029
16030 2008-10-21  Bruno Haible  <bruno@clisp.org>
16031
16032         * modules/poll-tests (Depends-on): Add sys_ioctl, ioctl.
16033         * modules/select-tests (Depends-on): Likewise.
16034         Reported by Simon Josefsson.
16035
16036 2008-10-21  Simon Josefsson  <simon@josefsson.org>
16037
16038         * lib/close.c: Add _gl_close_fd_maybe_socket from winsock.c.
16039         * lib/accept.c: New file, based on winsock.c.
16040         * lib/bind.c: New file, based on winsock.c.
16041         * lib/connect.c: New file, based on winsock.c.
16042         * lib/getpeername.c: New file, based on winsock.c.
16043         * lib/getsockname.c: New file, based on winsock.c.
16044         * lib/getsockopt.c: New file, based on winsock.c.
16045         * lib/ioctl.c: New file, based on winsock.c.
16046         * lib/listen.c: New file, based on winsock.c.
16047         * lib/recv.c: New file, based on winsock.c.
16048         * lib/recvfrom.c: New file, based on winsock.c.
16049         * lib/send.c: New file, based on winsock.c.
16050         * lib/sendto.c: New file, based on winsock.c.
16051         * lib/setsockopt.c: New file, based on winsock.c.
16052         * lib/shutdown.c: New file, based on winsock.c.
16053         * lib/socket.c: New file, based on winsock.c.
16054         * lib/w32sock.h: New file, based on winsock.c.
16055         * lib/winsock.c: Remove file.
16056         * modules/accept: Likewise.
16057         * modules/bind: Likewise.
16058         * modules/connect: Likewise.
16059         * modules/getpeername: Likewise.
16060         * modules/getsockname: Likewise.
16061         * modules/getsockopt: Likewise.
16062         * modules/ioctl: Likewise.
16063         * modules/listen: Likewise.
16064         * modules/recv: Likewise.
16065         * modules/recvfrom: Likewise.
16066         * modules/send: Likewise.
16067         * modules/sendto: Likewise.
16068         * modules/setsockopt: Likewise.
16069         * modules/shutdown: Likewise.
16070         * modules/socket: Use socket.c instead of winsock.c.
16071         * modules/sys_socket: Remove (unneeded?) dependency on winsock.c.
16072         * doc/posix-functions/accept.texi: Doc fix.
16073         * doc/posix-functions/bind.texi: Doc fix.
16074         * doc/posix-functions/close.texi: Doc fix.
16075         * doc/posix-functions/connect.texi: Doc fix.
16076         * doc/posix-functions/getpeername.texi: Doc fix.
16077         * doc/posix-functions/getsockname.texi: Doc fix.
16078         * doc/posix-functions/getsockopt.texi: Doc fix.
16079         * doc/posix-functions/ioctl.texi: Doc fix.
16080         * doc/posix-functions/listen.texi: Doc fix.
16081         * doc/posix-functions/recv.texi: Doc fix.
16082         * doc/posix-functions/recvfrom.texi: Doc fix.
16083         * doc/posix-functions/send.texi: Doc fix.
16084         * doc/posix-functions/sendto.texi: Doc fix.
16085         * doc/posix-functions/setsockopt.texi: Doc fix.
16086         * doc/posix-functions/shutdown.texi: Doc fix.
16087         * doc/posix-functions/socket.texi: Doc fix.
16088
16089 2008-10-20  Bruno Haible  <bruno@clisp.org>
16090
16091         Take into account the role of SIGABRT_COMPAT on Windows 2008.
16092         * lib/sigprocmask.c (SIGABRT_COMPAT, SIGABRT_COMPAT_MASK): New macros.
16093         (sigismember, sigaddset, sigdelset, sigfillset, rpl_signal): Handle it
16094         as an alias for SIGABRT.
16095         * lib/sigaction.c (SIGABRT_COMPAT): New macro.
16096         (sigaction): Map it to SIGABRT.
16097         Reported by Ramiro Polla <ramiro.polla@gmail.com> via Eric Blake.
16098
16099 2008-10-20  Bruno Haible  <bruno@clisp.org>
16100
16101         * lib/fts.c: Don't include lstat.h.
16102         * lib/openat.c: Include <sys/stat.h> instead of lstat.h.
16103
16104         Move the lstat() declaration to <sys/stat.h>.
16105         * lib/lstat.h: Remove file.
16106         * lib/sys_stat.in.h: Add special invocation convention.
16107         (lstat): New declaration.
16108         * lib/lstat.c (orig_lstat): New function.
16109         (rpl_lstat): Use orig_lstat instead of lstat.
16110         * m4/lstat.m4 (gl_FUNC_LSTAT): Require gl_SYS_STAT_H_DEFAULTS and
16111         AC_C_INLINE. Set REPLACE_LSTAT.
16112         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_LSTAT
16113         and REPLACE_LSTAT.
16114         * modules/lstat (Files): Remove lib/lstat.h.
16115         (configure.ac): Invoke gl_SYS_STAT_MODULE_INDICATOR.
16116         (Include): Specify <sys/stat.h> instead of lstat.h.
16117         * modules/sys_stat (Makefile.am): Substitute GNULIB_LSTAT and
16118         REPLACE_LSTAT.
16119         * NEWS: Mention the change.
16120
16121 2008-10-20  Bruno Haible  <bruno@clisp.org>
16122
16123         * modules/posix_spawn-tests: New file.
16124         * tests/test-posix_spawn3.c: New file.
16125
16126 2008-10-20  Bruno Haible  <bruno@clisp.org>
16127
16128         * modules/posix_spawnp-tests (Depends-on): Add sys_wait.
16129         * tests/test-posix_spawn1.c (WTERMSIG, WCOREDUMP, WEXITSTATUS,
16130         WIFSIGNALED, WIFEXITED, WIFSTOPPED): Remove fallback definitions.
16131         * tests/test-posix_spawn2.c (WTERMSIG, WCOREDUMP, WEXITSTATUS,
16132         WIFSIGNALED, WIFEXITED, WIFSTOPPED): Likewise.
16133
16134 2008-10-20  Bruno Haible  <bruno@clisp.org>
16135
16136         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Test against another bug
16137         of posix_spawn on AIX 5.3.
16138
16139 2008-10-20  Bruno Haible  <bruno@clisp.org>
16140
16141         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Make the check on MacOS X.
16142
16143 2008-10-20  Bruno Haible  <bruno@clisp.org>
16144
16145         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Use AC_LANG_SOURCE instead
16146         of AC_LANG_PROGRAM.
16147
16148 2008-10-20  Simon Josefsson  <simon@josefsson.org>
16149
16150         * lib/netdb.in.h: Don't define GNU specific constants until they
16151         are supported or needed.  Reported by Bruno Haible
16152         <bruno@clisp.org>.
16153
16154 2008-10-20  Simon Josefsson  <simon@josefsson.org>
16155
16156         * lib/canon-host.c: Include netdb.h instead of getaddrinfo.h.
16157
16158 2008-10-20  Simon Josefsson  <simon@josefsson.org>
16159
16160         * lib/getaddrinfo.h: Remove file.
16161         * modules/getaddrinfo: Reflect move from getaddrinfo.h to netdb.h.
16162         * m4/getaddrinfo.m4: Call gl_HEADER_NETDB.  Don't check for netdb.h.
16163         * lib/netdb.in.h: Add declarations from getaddrinfo.h.
16164         * m4/netdb_h.m4: Initialize GNULIB_GETADDRINFO to 0.
16165         * modules/netdb: Substitute GNULIB_GETADDRINFO.
16166         * lib/getaddrinfo.c: Include netdb.h instead of getaddrinfo.h.
16167         * tests/test-getaddrinfo.c: Likewise.
16168         * lib/gai_strerror.c: Likewise.  Also drop HAVE_NETDB_H check.
16169         * NEWS: Mention change.
16170
16171 2008-10-19  Bruno Haible  <bruno@clisp.org>
16172
16173         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Remove unneeded code.
16174
16175 2008-10-19  Bruno Haible  <bruno@clisp.org>
16176
16177         * lib/wait-process.c: Include simply <sys/wait.h>.
16178         (waitpid, WTERMSIG, WCOREDUMP, WEXITSTATUS, WIFSIGNALED, WIFEXITED,
16179         WIFSTOPPED): Remove fallback definitions.
16180         * modules/wait-process (Depends-on): Add sys_wait.
16181
16182         New module 'sys_wait'.
16183         * modules/sys_wait: New file.
16184         * lib/sys_wait.in.h: New file, partially copied from
16185         lib/wait-process.c.
16186         * m4/sys_wait_h.m4: New file.
16187         * doc/posix-headers/sys_wait.texi: Mention the new module.
16188
16189 2008-10-19  Bruno Haible  <bruno@clisp.org>
16190
16191         * m4/wait-process.m4 (gl_WAIT_PROCESS): Remove test for unistd.h.
16192
16193 2008-10-19  Bruno Haible  <bruno@clisp.org>
16194
16195         Assume that waitpid() fills an 'int' status, not a 'union wait'.
16196         * lib/wait-process.c (WAIT_T): Remove type.
16197         (WTERMSIG, WCOREDUMP, WEXITSTATUS): Define fallbacks using bit masks.
16198         (wait_subprocess): Update.
16199
16200 2008-10-19  Bruno Haible  <bruno@clisp.org>
16201
16202         New module 'atoll'.
16203         * modules/atoll: New file.
16204         * lib/stdlib.in.h (atoll): New declaration.
16205         * lib/atoll.c: New file, from glibc with modifications.
16206         * m4/atoll.m4: New file.
16207         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_ATOLL,
16208         HAVE_ATOLL.
16209         * modules/stdlib (Makefile.am): Substitute GNULIB_ATOLL, HAVE_ATOLL.
16210         * doc/posix-functions/atoll.texi: Mention the new module.
16211
16212 2008-10-19  Bruno Haible  <bruno@clisp.org>
16213
16214         Add strtoull() declaration to <stdlib.h>.
16215         * lib/stdlib.in.h (strtoull): New declaration.
16216         * m4/strtoull.m4 (gl_FUNC_STRTOLL): Require gl_STDLIB_H_DEFAULTS.
16217         Set HAVE_STRTOULL.
16218         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOULL,
16219         HAVE_STRTOULL.
16220         * modules/strtoull (Depends-on): Add stdlib.
16221         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
16222         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOULL,
16223         HAVE_STRTOULL.
16224
16225 2008-10-19  Bruno Haible  <bruno@clisp.org>
16226
16227         Add strtoll() declaration to <stdlib.h>.
16228         * lib/stdlib.in.h (strtoll): New declaration.
16229         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Require gl_STDLIB_H_DEFAULTS.
16230         Set HAVE_STRTOLL.
16231         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOLL,
16232         HAVE_STRTOLL.
16233         * modules/strtoll (Depends-on): Add stdlib.
16234         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
16235         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOLL, HAVE_STRTOLL.
16236
16237 2008-10-19  Bruno Haible  <bruno@clisp.org>
16238
16239         * modules/bcopy (Depends-on): Add strings.
16240         (Include): Specify <strings.h>.
16241
16242 2008-10-19  Bruno Haible  <bruno@clisp.org>
16243
16244         * doc/posix-functions/atexit.texi: Update doc regarding mingw.
16245
16246 2008-10-19  Bruno Haible  <bruno@clisp.org>
16247
16248         * lib/openat-die.c (openat_save_fail, openat_restore_fail): Rename
16249         the parameter from 'errno' to 'errnum'. Fixes a compilation error on
16250         mingw.
16251
16252 2008-10-19  Bruno Haible  <bruno@clisp.org>
16253
16254         * lib/atanl.c: Don't include isnanl.h.
16255         * lib/cosl.c: Likewise.
16256         * lib/ldexpl.c: Likewise.
16257         * lib/logl.c: Likewise.
16258         * lib/sinl.c: Likewise.
16259         * lib/sqrtl.c: Likewise.
16260         * lib/tanl.c: Likewise.
16261
16262         Move the isnanf(), isnand(), isnanl() declarations to <math.h>.
16263         * lib/isnanf.h: Remove file.
16264         * lib/isnand.h: Remove file.
16265         * lib/isnanl.h: Remove file.
16266         * lib/math.in.h: Include the contents of lib/isnanf.h, lib/isnand.h,
16267         lib/isnanl.h. Use HAVE_ISNANF, HAVE_ISNAND, HAVE_ISNANL as substituted
16268         macros.
16269         * m4/isnanf.m4 (gl_FUNC_ISNANF): Require gl_MATH_H_DEFAULTS. Set
16270         HAVE_ISNANF, don't define it as a C macro.
16271         * m4/isnand.m4 (gl_FUNC_ISNAND): Require gl_MATH_H_DEFAULTS. Set
16272         HAVE_ISNAND, don't define it as a C macro.
16273         * m4/isnanl.m4 (gl_FUNC_ISNANL): Require gl_MATH_H_DEFAULTS. Set
16274         HAVE_ISNANL, don't define it as a C macro.
16275         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_ISNAN[FDL] and
16276         HAVE_ISNAN[FDL].
16277         * modules/isnanf (Files): Remove lib/isnanf.h.
16278         (Depends-on): Add math.
16279         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
16280         (Include): Specify <math.h> instead of isnanf.h.
16281         * modules/isnand (Files): Remove lib/isnand.h.
16282         (Depends-on): Add math.
16283         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
16284         (Include): Specify <math.h> instead of isnand.h.
16285         * modules/isnanl (Files): Remove lib/isnanl.h.
16286         (Depends-on): Add math.
16287         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
16288         (Include): Specify <math.h> instead of isnanl.h.
16289         * modules/math (Makefile.am): Substitute GNULIB_ISNAN[FDL] and
16290         HAVE_ISNAN[FDL].
16291         * tests/test-isnanf.c: Include <math.h> instead of isnanf.h.
16292         * tests/test-isnand.c: Include <math.h> instead of isnand.h.
16293         * tests/test-isnanl.c: Include <math.h> instead of isnanl.h.
16294         * NEWS: Mention the change.
16295
16296 2008-10-18  Bruno Haible  <bruno@clisp.org>
16297
16298         Add getusershell(), setusershell(), endusershell() declarations to
16299         <unistd.h>.
16300         * lib/unistd.in.h (getusershell, setusershell, endusershell): New
16301         declarations.
16302         * lib/getusershell.c: Include unistd.h.
16303         * m4/getusershell.m4 (gl_FUNC_GETUSERSHELL): Require
16304         gl_UNISTD_H_DEFAULTS and AC_USE_SYSTEM_EXTENSIONS. Set
16305         HAVE_GETUSERSHELL.
16306         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETUSERSHELL
16307         and HAVE_GETUSERSHELL.
16308         * modules/getusershell (Depends-on): Add unistd, extensions.
16309         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
16310         (Include): Specify <unistd.h>.
16311         * modules/unistd (Makefile.am): Substitute GNULIB_GETUSERSHELL and
16312         HAVE_GETUSERSHELL.
16313
16314 2008-10-18  Bruno Haible  <bruno@clisp.org>
16315
16316         Add a getloadavg() declaration to <stdlib.h>.
16317         * lib/stdlib.in.h; Include <sys/loadavg.h> when needed for the
16318         getloadavg declaration.
16319         (getloadavg): New declaration.
16320         * lib/getloadavg.c: Include <stdlib.h> first.
16321         * m4/getloadavg.m4 (gl_GETLOADAVG): Require gl_STDLIB_H_DEFAULTS and
16322         AC_USE_SYSTEM_EXTENSIONS. Test whether sys/loadavg.h exists. Set
16323         HAVE_SYS_LOADAVG_H and HAVE_DECL_GETLOADAVG.
16324         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_GETLOADAVG,
16325         HAVE_SYS_LOADAVG_H, HAVE_DECL_GETLOADAVG.
16326         * modules/getloadavg (Depends-on): Add stdlib, extensions.
16327         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
16328         (Include): Specify <stdlib.h>.
16329         * modules/stdlib (Makefile.am): Substitute GNULIB_GETLOADAVG,
16330         HAVE_SYS_LOADAVG_H, HAVE_DECL_GETLOADAVG.
16331
16332 2008-10-18  Bruno Haible  <bruno@clisp.org>
16333
16334         * lib/dirchownmod.c: Don't include lchmod.h.
16335
16336         Move the lchmod() declaration to <sys/stat.h>.
16337         * lib/lchmod.h: Remove file.
16338         * lib/sys_stat.in.h: Add placeholder for GL_LINK_WARNING.
16339         (lchmod): New declaration, moved here from lib/lchown.h.
16340         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Require gl_SYS_STAT_H_DEFAULTS and
16341         AC_USE_SYSTEM_EXTENSIONS. Set HAVE_LCHMOD.
16342         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_LCHMOD
16343         and HAVE_LCHMOD.
16344         * modules/lchmod (Files): Remove lib/lchmod.h.
16345         (Depends-on): Add sys_stat, extensions.
16346         (configure.ac): Invoke gl_SYS_STAT_MODULE_INDICATOR.
16347         (Include): Specify <sys/stat.h> instead of lchmod.h.
16348         * modules/sys_stat (Depends-on): Add link-warning.
16349         (Makefile.am): Substitute GNULIB_LCHMOD, HAVE_LCHMOD, and the
16350         definition of GL_LINK_WARNING.
16351         * NEWS: Mention the change.
16352
16353 2008-10-18  Bruno Haible  <bruno@clisp.org>
16354
16355         * lib/fchdir.c: Don't include dirfd.h.
16356         * lib/fts.c: Likewise.
16357         * lib/getcwd.c: Likewise.
16358         * lib/glob.c: Likewise.
16359
16360         Move the dirfd() declaration to <dirent.h>.
16361         * lib/dirfd.h: Remove file.
16362         * lib/dirent.in.h: Add placeholder for GL_LINK_WARNING.
16363         (dirfd): New declaration.
16364         * lib/dirfd.c: Include <dirent.h> instead of dirfd.h.
16365         * m4/dirfd.m4 (gl_FUNC_DIRFD): Require gl_DIRENT_H_DEFAULTS and
16366         AC_USE_SYSTEM_EXTENSIONS. Invoke gl_REPLACE_DIRENT_H. Set
16367         HAVE_DECL_DIRFD.
16368         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_DIRFD and
16369         HAVE_DECL_DIRFD.
16370         * modules/dirfd (Files): Remove lib/dirfd.h.
16371         (Depends-on): Add dirent, extensions.
16372         (configure.ac): Invoke gl_DIRENT_MODULE_INDICATOR.
16373         (Include): Specify <dirent.h> instead of dirfd.h.
16374         * modules/dirent (Depends-on): Add link-warning.
16375         (Makefile.am): Substitute GNULIB_DIRFD, HAVE_DECL_DIRFD, and
16376         definition of GL_LINK_WARNING.
16377         * NEWS: Mention the change.
16378
16379 2008-10-18  Bruno Haible  <bruno@clisp.org>
16380
16381         Move the euidaccess() declaration to <unistd.h>.
16382         * lib/euidaccess.h: Remove file.
16383         * lib/unistd.in.h (euidaccess): New declaration.
16384         * lib/euidaccess.c: Don't include euidaccess.h.
16385         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Require gl_UNISTD_H_DEFAULTS.
16386         Don't check whether euidaccess is declared. Set HAVE_EUIDACCESS.
16387         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_EUIDACCESS
16388         and HAVE_EUIDACCESS.
16389         * modules/euidaccess (Files): Remove lib/euidaccess.h.
16390         (Depends-on): Add unistd.
16391         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
16392         (Include): Specify <unistd.h> instead of euidaccess.h.
16393         * modules/unistd (Makefile.am): Substitute GNULIB_EUIDACCESS and
16394         HAVE_EUIDACCESS.
16395         * NEWS: Mention the change.
16396
16397 2008-10-18  Bruno Haible  <bruno@clisp.org>
16398
16399         * lib/xgetdomainname.c: Include <unistd.h> instead of getdomainname.h.
16400
16401         Move the getdomainname() declaration to <unistd.h>.
16402         * lib/getdomainname.h: Remove file.
16403         * lib/unistd.in.h (getdomainname): New declaration.
16404         * lib/getdomainname.c: Include <unistd.h> instead of getdomainname.h.
16405         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Require
16406         gl_UNISTD_H_DEFAULTS and AC_USE_SYSTEM_EXTENSIONS. Set
16407         HAVE_GETDOMAINNAME.
16408         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
16409         GNULIB_GETDOMAINNAME and HAVE_GETDOMAINNAME.
16410         * modules/getdomainname (Files): Remove lib/getdomainname.h.
16411         (Depends-on): Add unistd, extensions.
16412         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
16413         (Includes): Specify <unistd.h> instead of getdomainname.h.
16414         * modules/unistd (Makefile.am): Substitute GNULIB_GETDOMAINNAME and
16415         HAVE_GETDOMAINNAME.
16416         * NEWS: Mention the change.
16417
16418 2008-10-18  Bruno Haible  <bruno@clisp.org>
16419
16420         * modules/dirent: New file.
16421         * m4/dirent_h.m4: New file.
16422         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_DIRENT_H_DEFAULTS.
16423         Invoke gl_REPLACE_DIRENT_H. Don't assign DIRENT_H directly.
16424         * modules/fchdir (Files): Remove lib/dirent.in.h.
16425         (Depends-on): Add dirent.
16426         (Makefile.am): Move rules to modules/dirent.
16427         * doc/posix-headers/dirent.texi: Mention the new module.
16428
16429 2008-10-18  Bruno Haible  <bruno@clisp.org>
16430
16431         Avoid -Wunused-parameter warnings in public gnulib header files.
16432         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define _UNUSED_PARAMETER_ as a
16433         macro.
16434         * lib/unistr.h (u32_mbtouc_unsafe, u32_mbtouc): Use it.
16435
16436 2008-10-18  Bruno Haible  <bruno@clisp.org>
16437
16438         * doc/glibc-functions/dirfd.texi: Mention the module 'dirfd'.
16439         * doc/glibc-functions/error.texi: Mention the module 'error'.
16440         * doc/glibc-functions/euidaccess.texi: Mention the module 'euidaccess'.
16441         * doc/glibc-functions/getdomainname.texi: Mention the module
16442         'getdomainname'.
16443         * doc/glibc-functions/getloadavg.texi: Mention the module 'getloadavg'.
16444         * doc/glibc-functions/getpagesize.texi: Mention the module
16445         'getpagesize'.
16446         * doc/glibc-functions/getusershell.texi: Mention the module
16447         'getusershell'.
16448         * doc/glibc-functions/isnanl.texi: Mention the module 'isnanl'.
16449         * doc/glibc-functions/lchmod.texi: Mention the module 'lchmod'.
16450         * doc/glibc-functions/mempcpy.texi: Mention the module 'mempcpy'.
16451         * doc/glibc-functions/memrchr.texi: Mention the module 'memrchr'.
16452         * doc/glibc-functions/mkdtemp.texi: Mention the module 'mkdtemp'.
16453         * doc/glibc-functions/rpmatch.texi: Mention the module 'rpmatch'.
16454         * doc/glibc-functions/stpcpy.texi: Mention the module 'stpcpy'.
16455         * doc/glibc-functions/stpncpy.texi: Mention the module 'stpncpy'.
16456         * doc/glibc-functions/strchrnul.texi: Mention the module 'strchrnul'.
16457         * doc/glibc-functions/strndup.texi: Mention the module 'strndup'.
16458         * doc/glibc-functions/strnlen.texi: Mention the module 'strnlen'.
16459         * doc/glibc-functions/strsep.texi: Mention the module 'strsep'.
16460         * doc/glibc-functions/timegm.texi: Mention the module 'timegm'.
16461         * doc/glibc-functions/vasprintf.texi: Mention the module 'vasprintf'.
16462
16463 2008-10-17  Bruno Haible  <bruno@clisp.org>
16464
16465         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): On platforms other than
16466         HP-UX and IRIX, use -0.0L.
16467         * tests/test-ceill.c (minus_zero): Likewise.
16468         * tests/test-floorl.c (minus_zero): Likewise.
16469         * tests/test-frexpl.c (minus_zero): Likewise.
16470         * tests/test-isnan.c (minus_zerol): Likewise.
16471         * tests/test-isnanl.h (minus_zero): Likewise.
16472         * tests/test-ldexpl.c (minus_zero): Likewise.
16473         * tests/test-roundl.c (minus_zero): Likewise.
16474         * tests/test-signbit.c (minus_zerol): Likewise.
16475         * tests/test-snprintf-posix.h (minus_zerol): Likewise.
16476         * tests/test-sprintf-posix.h (minus_zerol): Likewise.
16477         * tests/test-truncl.c (minus_zero): Likewise.
16478         * tests/test-vasnprintf-posix.c (minus_zerol): Likewise.
16479         * tests/test-vasprintf-posix.c (minus_zerol): Likewise.
16480         Reported by Markus Armbruster <armbru@redhat.com> via Jim Meyering
16481         and by Nelson H. F. Beebe <beebe@math.utah.edu> via Eric Blake.
16482
16483 2008-10-17  Bruno Haible  <bruno@clisp.org>
16484
16485         Avoid gcc warnings because of #pragma GCC system_header on older gcc.
16486         * lib/arpa_inet.in.h: Encloses reference to PRAGMA_SYSTEM_HEADER so
16487         that it gets activated only for gcc >= 3.0.
16488         * lib/dirent.in.h: Likewise.
16489         * lib/errno.in.h: Likewise.
16490         * lib/fcntl.in.h: Likewise.
16491         * lib/float.in.h: Likewise.
16492         * lib/iconv.in.h: Likewise.
16493         * lib/inttypes.in.h: Likewise.
16494         * lib/locale.in.h: Likewise.
16495         * lib/math.in.h: Likewise.
16496         * lib/netdb.in.h: Likewise.
16497         * lib/netinet_in.in.h: Likewise.
16498         * lib/search.in.h: Likewise.
16499         * lib/signal.in.h: Likewise.
16500         * lib/spawn.in.h: Likewise.
16501         * lib/stdarg.in.h: Likewise.
16502         * lib/stdint.in.h: Likewise.
16503         * lib/stdio.in.h: Likewise.
16504         * lib/stdlib.in.h: Likewise.
16505         * lib/string.in.h: Likewise.
16506         * lib/strings.in.h: Likewise.
16507         * lib/sys_file.in.h: Likewise.
16508         * lib/sys_ioctl.in.h: Likewise.
16509         * lib/sys_select.in.h: Likewise.
16510         * lib/sys_socket.in.h: Likewise.
16511         * lib/sys_stat.in.h: Likewise.
16512         * lib/sys_time.in.h: Likewise.
16513         * lib/sysexits.in.h: Likewise.
16514         * lib/time.in.h: Likewise.
16515         * lib/unistd.in.h: Likewise.
16516         * lib/wchar.in.h: Likewise.
16517         * lib/wctype.in.h: Likewise.
16518         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
16519
16520 2008-10-17  Jim Meyering  <meyering@redhat.com>
16521
16522         ignore-value: don't depend on inline module
16523         * modules/ignore-value (Depends-on): Remove 'inline'.
16524         (configure.ac): Instead, add AC_REQUIRE([AC_C_INLINE]) here.
16525         Suggestion from Bruno Haible.
16526
16527 2008-10-17  Bruno Haible  <bruno@clisp.org>
16528
16529         New implementation of condition variables for Win32.
16530         * lib/glthread/cond.h (struct gl_waitqueue_link): New type.
16531         (gl_linked_waitqueue_t): New type.
16532         (gl_cond_t): Use it.
16533         * lib/glthread/cond.c (struct gl_waitqueue_element): New type.
16534         (gl_waitqueue_init, gl_waitqueue_add, gl_waitqueue_remove,
16535         gl_waitqueue_notify_first, gl_waitqueue_notify_all): New functions.
16536         (glthread_cond_init_func, glthread_cond_wait_func,
16537         glthread_cond_timedwait_func, glthread_cond_signal_func,
16538         glthread_cond_broadcast_func, glthread_cond_destroy_func):
16539         Reimplemented on the basis of gl_linked_waitqueue_t.
16540         * lib/glthread/lock.h (gl_carray_waitqueue_t): Renamed from
16541         gl_waitqueue_t.
16542         (gl_rwlock_t): Update.
16543         * lib/glthread/lock.c (gl_waitqueue_t): Alias to gl_carray_waitqueue_t.
16544
16545 2008-10-17  Simon Josefsson  <simon@josefsson.org>
16546
16547         * modules/recvfrom (Depends-on): Add dependency on getpeername.
16548         Reported by Yoann Vandoorselaere <yoann@prelude-ids.org>.
16549
16550 2008-10-17  Jim Meyering  <meyering@redhat.com>
16551
16552         ignore-value: new module
16553         * modules/ignore-value: New file.
16554         * lib/ignore-value.h: New file.
16555         * MODULES.html.sh (Compiler warning management): New section,
16556         just for this module.  More to come.
16557
16558 2008-10-16  Paul Eggert  <eggert@cs.ucla.edu>
16559
16560         open-safer.c: avoid 'signed and unsigned in conditional...' warning
16561         * lib/open-safer.c (open_safer): Use an "if/else" statement in place
16562         of the ternary operator.  Reported by Reuben Thomas <rrt@sc3d.org>.
16563
16564 2008-10-16  Jim Meyering  <meyering@redhat.com>
16565
16566         openat-die.c: avoid 'no previous prototype' warning
16567         * lib/openat-die.c: Include "openat.h".
16568         Reported by Reuben Thomas <rrt@sc3d.org>.
16569
16570 2008-10-16  Simon Josefsson  <simon@josefsson.org>
16571
16572         * m4/netdb_h.m4: Assume that if netdb.h exists, it works.
16573         * lib/netdb.in.h: Fix typo.
16574         Reported by Bruno Haible  <bruno@clisp.org>
16575
16576         * lib/netdb.in.h: Include sys/socket.h for platforms without
16577         netdb.h, to get structures like hostent on MinGW.
16578         * modules/netdb (Depends-on): Add sys_socket.
16579
16580 2008-10-15  Simon Josefsson  <simon@josefsson.org>
16581
16582         * modules/netdb, modules/netdb-tests: New file.
16583         * m4/netdb_h.m4: New file.
16584         * lib/netdb.in.h: Add, currently just an empty file pending
16585         definitions.
16586         * tests/test-netdb.c: New file.
16587         * doc/posix-headers/netdb.texi: Mention that we replace it if
16588         needed.
16589         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
16590         netdb.
16591
16592 2008-10-15  Simon Josefsson  <simon@josefsson.org>
16593
16594         * doc/gnulib.texi (Getaddrinfo and WINVER): Sync documentation
16595         with code.
16596
16597 2008-10-13  Bruno Haible  <bruno@clisp.org>
16598
16599         * lib/glthread/cond.c (glthread_cond_wait_func,
16600         glthread_cond_timedwait_func): Add a comment.
16601
16602 2008-10-13  Yoann Vandoorselaere  <yoann@prelude-ids.org>
16603
16604         * tests/test-poll.c: Include <sys/ioctl.h>, for ioctl().
16605         * tests/test-select.c: Likewise,
16606
16607 2008-10-13  Bruno Haible  <bruno@clisp.org>
16608
16609         * lib/glthread/cond.c (glthread_cond_wait_func,
16610         glthread_cond_timedwait_func): Fix variable name.
16611         Reported by Yoann Vandoorselaere <yoann@prelude-ids.org>.
16612
16613 2008-10-13  Paolo Bonzini  <bonzini@gnu.org>
16614
16615         fix getaddrinfo emulation for systems with struct sockaddr.sa_len
16616         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Detect
16617         struct sockaddr.sa_len.
16618         * lib/getaddrinfo.c (getaddrinfo): Set it if appropriate.
16619
16620 2008-10-13  Simon Josefsson  <simon@josefsson.org>
16621
16622         * build-aux/pmccabe2html: Add css and css_url parameters.
16623
16624 2008-10-12  Bruno Haible  <bruno@clisp.org>
16625
16626         * tests/test-sameacls.c (main) [AIX]: Clear type argument before
16627         calling aclx_get.
16628         Reported by Rainer Tammer <tammer@tammer.net>.
16629
16630 2008-10-12  Bruno Haible  <bruno@clisp.org>
16631
16632         Use msvcrt aware primitives for creation/termination of Win32 threads.
16633         * lib/glthread/thread.c: Include <process.h>.
16634         (glthread_create_func): Use _beginthreadex instead of CreateThread.
16635         (wrapper_func): Update signature.
16636         (gl_thread_exit_func): Use _endthreadex instead of EndThread.
16637
16638 2008-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
16639             Bruno Haible  <bruno@clisp.org>
16640
16641         Provide a Win32 implementation of the 'cond' module.
16642         * lib/glthread/cond.h [USE_WIN32]: New implementation.
16643         * lib/glthread/cond.c (glthread_cond_init_func,
16644         glthread_cond_wait_func, glthread_cond_timedwait_func,
16645         glthread_cond_signal_func, glthread_cond_broadcast_func,
16646         glthread_cond_destroy_func) [USE_WIN32]: New functions.
16647         * modules/cond (Dependencies): Add gettimeofday.
16648
16649 2008-10-11  Bruno Haible  <bruno@clisp.org>
16650
16651         Make sleep work on older versions of mingw.
16652         * m4/sleep.m4 (gl_FUNC_SLEEP): Test whether 'sleep' is declared, not
16653         only whether it exists.
16654         * doc/posix-functions/sleep.texi: Mention the problem with older
16655         versions of mingw.
16656
16657 2008-10-11  Bruno Haible  <bruno@clisp.org>
16658
16659         New module 'shutdown'.
16660         * modules/shutdown: New file.
16661         * lib/sys_socket.in.h (shutdown): New declaration.
16662         * lib/winsock.c (shutdown): New function.
16663         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Initialize
16664         GNULIB_SHUTDOWN.
16665         * modules/sys_socket (Makefile.am): Substitute GNULIB_SHUTDOWN.
16666         * doc/posix-functions/shutdown.texi: Document the new module.
16667
16668 2008-10-11  Jim Meyering  <meyering@redhat.com>
16669
16670         * lib/fclose.c: Fix typo in comment: s/close/fclose/.
16671
16672 2008-10-11  Bruno Haible  <bruno@clisp.org>
16673
16674         New module 'fclose'.
16675         * modules/fclose: New file.
16676         * lib/stdio.in.h (fclose): New declaration.
16677         * lib/fclose.c: New file.
16678         * m4/fclose.m4: New file.
16679         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_FCLOSE,
16680         REPLACE_FCLOSE.
16681         * m4/close.m4 (gl_REPLACE_CLOSE): Invoke gl_REPLACE_FCLOSE.
16682         * modules/stdio (Makefile.am): Substitute GNULIB_FCLOSE,
16683         REPLACE_FCLOSE.
16684         * modules/close (Depends-on): fclose.
16685         * doc/posix-functions/fclose.texi: Mention the problem on Windows.
16686
16687 2008-10-11  Bruno Haible  <bruno@clisp.org>
16688
16689         * lib/winsock.c (_gl_close_fd_maybe_socket): If closesocket fails,
16690         set errno and don't call _close.
16691
16692 2008-10-10  Bruno Haible  <bruno@clisp.org>
16693
16694         * lib/copy-acl.c (qcopy_acl) [CYGWIN]: Call chmod before setting the
16695         ACL, not afterwards. Fixes test failure on Cygwin.
16696
16697 2008-10-09  Ben Pfaff  <blp@gnu.org>
16698
16699         * build-aux/announce-gen: Fix gnulib version related part of usage
16700         message.  Die with a useful error message if no tarballs are
16701         found.
16702
16703 2008-10-10  Jim Meyering  <meyering@redhat.com>
16704
16705         bootstrap: use git's --depth=N option only if it's supported
16706         * build-aux/bootstrap: Work with git-1.4.4.4, which does not
16707         recognize the --depth option.  Reported by Pádraig Brady.
16708
16709 2008-10-09  Bruno Haible  <bruno@clisp.org>
16710
16711         New module 'ioctl'.
16712         * modules/ioctl: New file.
16713         * lib/sys_socket.in.h (ioctl): Remove declaration.
16714         * lib/winsock.c: Include <sys/ioctl.h>.
16715         (rpl_ioctl): Define only of the gnulib module 'ioctl' is present.
16716         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): Require
16717         gl_SYS_IOCTL_H_DEFAULTS. Set also SYS_IOCTL_H_HAVE_WINSOCK2_H.
16718         * modules/sys_socket (Files): Add m4/sys_ioctl_h.m4.
16719         * doc/posix-functions/ioctl.texi: Mention the new module.
16720
16721 2008-10-09  Bruno Haible  <bruno@clisp.org>
16722
16723         New module 'sys_ioctl'.
16724         * lib/sys_ioctl.in.h: New file.
16725         * m4/sys_ioctl_h.m4: New file.
16726         * modules/sys_ioctl: New file.
16727         * doc/glibc-headers/sys_ioctl.texi: Mention the new module.
16728
16729 2008-10-09  Bruno Haible  <bruno@clisp.org>
16730
16731         * lib/sys_socket.in.h (ioctl): Make signature POSIX compliant.
16732         * lib/winsock.c: Include <stdarg.h>.
16733         (rpl_ioctl): Change to second argument 'int' and then varargs.
16734
16735 2008-10-09  Bruno Haible  <bruno@clisp.org>
16736
16737         * m4/close.m4 (gl_FUNC_CLOSE): Arrange to replace the close() function
16738         when the sys_socket module is present and the system has <winsock2.h>.
16739
16740 2008-10-09  Bruno Haible  <bruno@clisp.org>
16741
16742         * doc/posix-functions/close.texi: Mention module 'close' instead of
16743         module 'sys_socket'.
16744
16745 2008-10-09  Bruno Haible  <bruno@clisp.org>
16746
16747         * doc/glibc-headers/sys_ioctl.texi: New file.
16748         * doc/gnulib.texi: Include it.
16749
16750 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
16751             Bruno Haible  <bruno@clisp.org>
16752
16753         Combine the two replacements of 'close'.
16754         * lib/sys_socket.in.h (close): Define to a reminder to include
16755         <unistd.h>.
16756         (_gl_close_fd_maybe_socket): New declaration.
16757         (HAVE__GL_CLOSE_FD_MAYBE_SOCKET): New macro.
16758         * lib/winsock.c (close): Remove undefinition.
16759         (_gl_close_fd_maybe_socket): Renamed from rpl_close. Define only when
16760         needed for the gnulib module 'close'.
16761         * lib/unistd.in.h (close): If the gnulib module 'close' is not used,
16762         define to an error symbol or to a warning, if suitable.
16763         * lib/close.c: Include <sys/socket.h>.
16764         (rpl_close): Invoke _gl_close_fd_maybe_socket when gnulib defines it.
16765         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): Set also
16766         UNISTD_H_HAVE_WINSOCK2_H.
16767         (gl_SYS_SOCKET_H_DEFAULTS): Require gl_UNISTD_H_DEFAULTS.
16768         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
16769         UNISTD_H_HAVE_WINSOCK2_H.
16770         * modules/sys_socket (Files): Add m4/unistd_h.m4.
16771         (configure.ac): Set a module indicator.
16772         (Makefile.am): Substitute GNULIB_CLOSE.
16773         * modules/unistd (Makefile.am): Substitute UNISTD_H_HAVE_WINSOCK2_H.
16774         * modules/poll-tests (Depends-on): Add close.
16775         * modules/select-tests (Depends-on): Likewise.
16776
16777 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
16778             Bruno Haible  <bruno@clisp.org>
16779
16780         New module 'close'.
16781         * modules/close: New file.
16782         * lib/unistd.in.h (close): Move declaration out of the
16783         FCHDIR_REPLACEMENT scope.
16784         (_gl_unregister_fd): New declaration.
16785         * lib/close.c: New file.
16786         * lib/fchdir.c (rpl_close): Remove function.
16787         * m4/close.m4: New file.
16788         * m4/fchdir.m4 (gl_FUNC_FCHDIR): When replacing fchdir, also replace
16789         close.
16790         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_CLOSE and
16791         REPLACE_CLOSE.
16792         * modules/unistd (Makefile.am): Substitute GNULIB_CLOSE and
16793         REPLACE_CLOSE.
16794         * modules/fchdir (Depends-on): Add close.
16795
16796 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
16797             Bruno Haible  <bruno@clisp.org>
16798
16799         * lib/fcntl.in.h (open): Simplify conditionals.
16800         (_gl_register_fd): New declaration.
16801         * lib/fchdir.c (rpl_open): Remove function.
16802         * lib/open.c: When FCHDIR_REPLACEMENT is defined, compile the file
16803         also.
16804         (open): When FCHDIR_REPLACEMENT is defined, invoke _gl_register_fd.
16805         * m4/fchdir.m4 (gl_FUNC_FCHDIR): When replacing fchdir, also replace
16806         open.
16807
16808 2008-10-09  Jim Meyering  <meyering@redhat.com>
16809
16810         GNUmakefile: use the more name-space-friendly "_version"
16811         * top/GNUmakefile (_dummy): Update.
16812         (_version): Rename from "version".
16813
16814 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
16815             Bruno Haible  <bruno@clisp.org>
16816
16817         * lib/fchdir.c (_gl_unregister_fd): New functions, extracted from
16818         rpl_close.
16819         (_gl_register_fd): New function, extracted from rpl_open.
16820         (rpl_close, rpl_closedir): Use _gl_unregister_fd.
16821         (rpl_open, rpl_opendir): Use _gl_register_fd.
16822
16823 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
16824
16825         Fix organization of 'open' replacement.
16826         * m4/open.m4 (gl_REPLACE_OPEN): New macro.
16827         (gl_FUNC_OPEN): Use it.
16828         (gl_PREREQ_OPEN): Add a : to make the body non-empty.
16829
16830 2008-10-08  Bruno Haible  <bruno@clisp.org>
16831
16832         * modules/getdate-tests (test_getdata_LDADD): Add LIBINTL.
16833
16834 2008-10-08  Simon Josefsson  <simon@josefsson.org>
16835
16836         * m4/sys_socket_h.m4: Don't AC_LIBOBJ(winsock).  The file is
16837         AC_LIBOBJ'ed by each gnulib module that needs it (e.g., socket,
16838         listen).
16839
16840 2008-10-08  Eric Blake  <ebb9@byu.net>
16841
16842         GNUmakefile: add 'make version' target
16843         * top/GNUmakefile (_curr-ver): Split version update rules...
16844         (version): ...into a target.
16845
16846 2008-10-07  Bruno Haible  <bruno@clisp.org>
16847
16848         Use a more portable replacement expression for -0.0L.
16849         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Use -LDBL_MIN * LDBL_MIN
16850         instead of -0.0L. Fix m4 quotation.
16851
16852         * tests/test-signbit.c: Include <float.h>.
16853         (minus_zero): New variable.
16854         (test_signbitl): Use minus_zero instead of -zero.
16855         * modules/signbit-tests (Depends-on): Add float.
16856
16857         * tests/test-ceill.c: Include <float.h>.
16858         (zero): Remove variable.
16859         (minus_zero): New variable.
16860         (main): Use minus_zero instead of -zero.
16861         * modules/ceill-tests (Depends-on): Add float.
16862
16863         * tests/test-floorl.c: Include <float.h>.
16864         (zero): Remove variable.
16865         (minus_zero): New variable.
16866         (main): Use minus_zero instead of -zero.
16867         * modules/floorl-tests (Depends-on): Add float.
16868
16869         * tests/test-roundl.c: Include <float.h>.
16870         (zero): Remove variable.
16871         (minus_zero): New variable.
16872         (main): Use minus_zero instead of -zero.
16873         * modules/roundl-tests (Depends-on): Add float.
16874
16875         * tests/test-truncl.c: Include <float.h>.
16876         (zero): Remove variable.
16877         (minus_zero): New variable.
16878         (main): Use minus_zero instead of -zero.
16879         * modules/truncl-tests (Depends-on): Add float.
16880
16881         * tests/test-frexpl.c (zero): Remove variable.
16882         (minus_zero): New variable.
16883         (main): Use minus_zero instead of -zero.
16884         * modules/frexpl-tests (Depends-on): Add float.
16885
16886         * tests/test-isnan.c (zerol): Remove variable.
16887         (minus_zerol): New variable.
16888         (test_long_double): Use minus_zerol instead of -zerol.
16889         * modules/isnan-tests (Depends-on): Add float.
16890
16891         * tests/test-isnanl.h (zero): Remove variable.
16892         (minus_zero): New variable.
16893         (main): Use minus_zero instead of -zero.
16894         * modules/isnanl-nolibm-tests (Depends-on): Add float.
16895         * modules/isnanl-tests (Depends-on): Add float.
16896
16897         * tests/test-ldexpl.c (zero): Remove variable.
16898         (minus_zero): New variable.
16899         (main): Use minus_zero instead of -zero.
16900         * modules/ldexpl-tests (Depends-on): Add float.
16901
16902         * tests/test-snprintf-posix.h (zerol): Remove variable.
16903         (minus_zerol): New variable.
16904         (test_function): Use minus_zerol instead of -zerol.
16905         * modules/snprintf-posix-tests (Depends-on): Add float.
16906         * modules/vsnprintf-posix-tests (Depends-on): Add float.
16907
16908         * tests/test-sprintf-posix.h (zerol): Remove variable.
16909         (minus_zerol): New variable.
16910         (test_function): Use minus_zerol instead of -zerol.
16911         * modules/sprintf-posix-tests (Depends-on): Add float.
16912         * modules/vsprintf-posix-tests (Depends-on): Add float.
16913
16914         * tests/test-vasnprintf-posix.c (zerol): Remove variable.
16915         (minus_zerol): New variable.
16916         (test_function): Use minus_zerol instead of -zerol.
16917         * modules/vasnprintf-posix-tests (Depends-on): Add float.
16918
16919         * tests/test-vasprintf-posix.c (zerol): Remove variable.
16920         (minus_zerol): New variable.
16921         (test_function): Use minus_zerol instead of -zerol.
16922         * modules/vasprintf-posix-tests (Depends-on): Add float.
16923
16924 2008-10-07  Simon Josefsson  <simon@josefsson.org>
16925
16926         * MODULES.html.sh (Support for building documentation): Mention
16927         pmccabe2html.  Sort entries.
16928
16929         Add pmccabe2html module, from gnupdf.
16930         * build-aux/pmccabe.css: New file.
16931         * build-aux/pmccabe2html: New file.
16932         * m4/pmccabe2html.m4: New file.
16933         * modules/pmccabe2html: New file.
16934
16935 2008-10-07  Richard W.M. Jones <rjones@redhat.com>
16936
16937         flock: new module
16938         * MODULES.html.sh: Add to list of modules.
16939         * lib/flock.c: flock implementation for Windows and Unix systems
16940         which have fcntl.
16941         * doc/glibc-functions/flock.texi: Update documentation.
16942         * lib/sys_file.in.h: <sys/file.h> header file.
16943         * m4/flock.m4: M4 macros.
16944         * m4/sys_file_h.m4: M4 macros for replacement sys/file.h.
16945         * modules/flock: flock module.
16946         * modules/flock-tests: flock tests module.
16947         * modules/sys_file: sys/file.h module.
16948         * tests/test-flock.c: test suite for flock.
16949
16950 2008-10-06  Jim Meyering  <meyering@redhat.com>
16951
16952         bootstrap: check for LT_INIT more portably still ;-)
16953         * build-aux/bootstrap: Don't rely on \>, since it's not portable.
16954         Spotted by Bruno Haible.
16955
16956 2008-10-06  Eric Blake  <ebb9@byu.net>
16957
16958         test-signbit: avoid tripping Irix cc bug on -0.0L
16959         * tests/test-signbit.c (minus_zerol): Delete, and replace with
16960         '-zerol'.  This may break on HP-UX/hppa, but at least makes the
16961         entire testsuite consistent and avoids an Irix 6.2 bug.
16962
16963 2008-10-05  Bruno Haible  <bruno@clisp.org>
16964             Jim Meyering  <jim@meyering.net>
16965
16966         Add an option for ignoring EPIPE during close_stdout.
16967         * lib/closeout.h: Include <stdbool.h>.
16968         (close_stdout_set_ignore_EPIPE): New declaration.
16969         * lib/closeout.c: Include <stdbool.h>.
16970         (ignore_EPIPE): New variable.
16971         (close_stdout_set_ignore_EPIPE): New function.
16972         (close_stdout): Ignore EPIPE error if ignore_EPIPE is set.
16973         * lib/close-stream.c (close_stream): Mention the possible EPIPE
16974         failure.
16975         * modules/closeout (Depends-on): Add stdbool.
16976
16977 2008-10-05  Bruno Haible  <bruno@clisp.org>
16978
16979         * modules/accept: New file.
16980         * modules/bind: New file.
16981         * modules/connect: New file.
16982         * modules/getpeername: New file.
16983         * modules/getsockname: New file.
16984         * modules/getsockopt: New file.
16985         * modules/listen: New file.
16986         * modules/recv: New file.
16987         * modules/recvfrom: New file.
16988         * modules/send: New file.
16989         * modules/sendto: New file.
16990         * modules/setsockopt: New file.
16991         * modules/socket: New file.
16992         * lib/sys_socket.in.h: Include the GL_LINK_WARNING definition.
16993         (socket, connect, accept, bind, getpeername, getsockname, getsockopt,
16994         listen, recv, send, recvfrom, sendto, setsockopt): Declare only when
16995         the particular module is requested. Add a link warning when the
16996         particular module is not requested.
16997         * lib/winsock.c (rpl_socket, rpl_connect, rpl_accept, rpl_bind,
16998         rpl_getpeername, rpl_getsockname, rpl_getsockopt, rpl_listen, rpl_recv,
16999         rpl_send, rpl_recvfrom, rpl_sendto, rpl_setsockopt): Define only when
17000         the particular module is requested.
17001         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR,
17002         gl_SYS_SOCKET_H_DEFAULTS): New macros.
17003         (gl_HEADER_SYS_SOCKET): Require gl_SYS_SOCKET_H_DEFAULTS.
17004         * modules/sys_socket (Depends-on): Add link-warning.
17005         (Makeifle.am): Substitute GNULIB_SOCKET, GNULIB_CONNECT, GNULIB_ACCEPT,
17006         GNULIB_BIND, GNULIB_GETPEERNAME, GNULIB_GETSOCKNAME, GNULIB_GETSOCKOPT,
17007         GNULIB_LISTEN, GNULIB_RECV, GNULIB_SEND, GNULIB_RECVFROM,
17008         GNULIB_SENDTO, GNULIB_SETSOCKOPT, and the definition of
17009         GL_LINK_WARNING.
17010         * doc/posix-functions/accept.texi: Mention the new module 'accept'.
17011         * doc/posix-functions/bind.texi: Mention the new module 'bind'.
17012         * doc/posix-functions/connect.texi: Mention the new module 'connect'.
17013         * doc/posix-functions/getpeername.texi: Mention the new module
17014         'getpeername'.
17015         * doc/posix-functions/getsockname.texi: Mention the new module
17016         'getsockname'.
17017         * doc/posix-functions/getsockopt.texi: Mention the new module
17018         'getsockopt'.
17019         * doc/posix-functions/listen.texi: Mention the new module 'listen'.
17020         * doc/posix-functions/recv.texi: Mention the new module 'recv'.
17021         * doc/posix-functions/recvfrom.texi: Mention the new module 'recvfrom'.
17022         * doc/posix-functions/send.texi: Mention the new module 'send'.
17023         * doc/posix-functions/sendto.texi: Mention the new module 'sendto'.
17024         * doc/posix-functions/setsockopt.texi: Mention the new module
17025         'setsockopt'.
17026         * doc/posix-functions/socket.texi: Mention the new module 'socket'.
17027         * modules/poll-tests (Depends-on): Add socket, bind, getsockopt,
17028         listen, connect, accept.
17029         * modules/select-tests (Depends-on): Likewise.
17030
17031 2008-10-05  Bruno Haible  <bruno@clisp.org>
17032
17033         * lib/winsock.c (strerror): Remove unused #undef.
17034         (rpl_close): Remove unused local variable.
17035
17036         * modules/sys_socket (Depends-on); Add errno.
17037
17038 2008-10-05  Bruno Haible  <bruno@clisp.org>
17039
17040         * lib/sys_select.in.h: Include the GL_LINK_WARNING definition.
17041         (select): Add a link warning when the 'select' module is not used.
17042         * modules/sys_select (Depends-on): Add link-warning.
17043         (Makefile.am): Substitute the definition of GL_LINK_WARNING.
17044         Suggested by Paolo Bonzini.
17045
17046 2008-10-05  Jim Meyering  <meyering@redhat.com>
17047
17048         bootstrap: check for LT_INIT more portably
17049         * build-aux/bootstrap: Avoid using grep -E, since it's not
17050         portable enough.  Suggestion from Bruno Haible.
17051
17052 2008-10-05  Bruno Haible  <bruno@clisp.org>
17053
17054         * doc/posix-headers/sys_select.texi: Mention 'struct timeval' problem
17055         as being fixed by gnulib.
17056
17057 2008-10-05  Bruno Haible  <bruno@clisp.org>
17058
17059         * modules/select-tests: New file, mostly copied from
17060         modules/sys_select-tests.
17061         * tests/test-select.c: New file, mostly copied from
17062         tests/test-sys_select.c.
17063         * tests/test-sys_select.c: Move most of the code to tests/test-select.c.
17064         * modules/sys_select-tests (Depends-on): Remove all dependencies.
17065         (Makefile.am): Remove test_sys_select_LDADD.
17066
17067         * lib/sys_select.in.h (select): If GNULIB_SELECT is not set, define it
17068         to an undefined symbol, for an error message.
17069         * m4/sys_select_h.m4 (gl_SYS_SELECT_MODULE_INDICATOR): New macro.
17070         (gl_SYS_SELECT_H_DEFAULTS): New macro.
17071         (gl_HEADER_SYS_SELECT): Require it. Don't require compilation of
17072         winsock-select.c here.
17073         * modules/sys_select (Files): Remove lib/winsock-select.c.
17074         (Depends-on): Remove alloca.
17075         (Makefile.am): Substitute GNULIB_SELECT.
17076         * modules/select: New file.
17077         * doc/posix-functions/select.texi: Update.
17078
17079 2008-10-05  Bruno Haible  <bruno@clisp.org>
17080
17081         * lib/spawn_faction_addclose.c (__sysconf): Use getdtablesize always.
17082         * lib/spawn_faction_adddup2.c (__sysconf): Likewise.
17083         * lib/spawn_faction_addopen.c (__sysconf): Likewise.
17084         * modules/posix_spawn_file_actions_addclose (Depends-on): Add
17085         getdtablesize.
17086         * modules/posix_spawn_file_actions_adddup2 (Depends-on): Likewise.
17087         * modules/posix_spawn_file_actions_addopen (Depends-on): Likewise.
17088
17089 2008-10-05  Bruno Haible  <bruno@clisp.org>
17090
17091         * modules/getdtablesize-tests: New file.
17092         * tests/test-getdtablesize.c: New file.
17093
17094         New module 'getdtablesize'.
17095         * lib/unistd.in.h (getdtablesize): New declaration.
17096         * lib/getdtablesize.c: New file.
17097         * m4/getdtablesize.m4: New file.
17098         * modules/getdtablesize: New file.
17099         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
17100         GNULIB_GETDTABLESIZE, HAVE_GETDTABLESIZE.
17101         * modules/unistd (Makefile.am): Substitute GNULIB_GETDTABLESIZE,
17102         HAVE_GETDTABLESIZE.
17103         * doc/glibc-functions/getdtablesize.texi: Mention the new module.
17104
17105 2008-10-05  Bruno Haible  <bruno@clisp.org>
17106
17107         * modules/sched (Makefile.am): Fix typo.
17108         Reported by Simon Josefsson.
17109
17110 2008-10-05  Jim Meyering  <meyering@redhat.com>
17111
17112         bootstrap: check for LT_INIT, too
17113         * build-aux/bootstrap: Both AC_PROG_LIBTOOL and AM_PROG_LIBTOOL
17114         are deprecated.  Suggestion from Ralf Wildenhues.
17115
17116 2008-10-05  Bruno Haible  <bruno@clisp.org>
17117
17118         * lib/spawn.in.h (POSIX_SPAWN_*): Use the system's values, rather than
17119         overriding them by ours.
17120         (POSIX_SPAWN_USEVFORK): Use the next free bit position.
17121
17122 2008-10-05  Jim Meyering  <meyering@redhat.com>
17123
17124         bootstrap: check for AC_PROG_LIBTOOL as well as AM_PROG_LIBTOOL
17125         * build-aux/bootstrap: Check for AC_PROG_LIBTOOL, as well as the
17126         obsolete AM_PROG_LIBTOOL.  Spotted by Debarshi Ray <rishi@gnu.org>.
17127
17128 2008-10-04  Bruno Haible  <bruno@clisp.org>
17129
17130         * modules/dup2 (License): Change to LGPLv2+.
17131         * modules/sleep (License): Likewise.
17132         * modules/perror (License): Likewise.
17133         * modules/fopen (License): Change to LGPLv2+, with approval by Eric
17134         Blake.
17135         * modules/signal (License): Likewise.
17136         * modules/sigprocmask (License): Likewise.
17137         * modules/raise (License): Change to LGPLv2+, with approval by Jim
17138         Meyering.
17139
17140 2008-10-04  Bruno Haible  <bruno@clisp.org>
17141
17142         * lib/spawn.in.h (POSIX_SPAWN_*): Undefine before redefining.
17143         Reported by Rainer Tammer <tammer@tammer.net>.
17144
17145 2008-10-03  Paolo Bonzini  <bonzini@gnu.org>
17146             Bruno Haible  <bruno@clisp.org>
17147
17148         * lib/errno.in.h (EWOULDBLOCK) [win32]: Define to EAGAIN.
17149         * lib/winsock.c (set_winsock_errno): Map WSAEWOULDBLOCK to EWOULDBLOCK.
17150         * lib/strerror.c (rpl_strerror): Remove error string for EWOULDBLOCK.
17151
17152 2008-10-03  Kamil Dudka  <kdudka@redhat.com>
17153
17154         filevercmp: new module
17155         * lib/filevercmp.h: New function filevercmp comparing version strings.
17156         * lib/filevercmp.c: Implementation of filevercmp function.
17157         * modules/filevercmp: Module metadata.
17158         * tests/test-filevercmp.c: Unit test for new module.
17159         * modules/filevercmp-tests: Unit test metadata.
17160         * MODULES.html.sh: Add filevercmp module.
17161
17162 2008-10-03  Bruno Haible  <bruno@clisp.org>
17163
17164         * lib/c-ctype.h: Add comment.
17165         Reported by Jim Meyering.
17166
17167 2008-10-02  Bruno Haible  <bruno@clisp.org>
17168
17169         * modules/posix_spawn-internal (Depends-on): Add 'open'.
17170
17171 2008-10-02  Paolo Bonzini  <bonzini@gnu.org>
17172
17173         * build-aux/bootstrap: Allow renaming bootstrap, and change the
17174         name of bootstrap.conf accordingly.
17175
17176 2008-10-02  Paolo Bonzini  <bonzini@gnu.org>
17177
17178         * build-aux/bootstrap: Install git-merge-changelog configuration
17179         items into .gitconfig if needed.
17180
17181 2008-10-02  Paolo Bonzini  <bonzini@gnu.org>
17182
17183         * build-aux/bootstrap: Recognize `gnulib' being a submodule in a
17184         git repository, and initialize/update it accordingly.
17185
17186 2008-10-02  Richard W.M. Jones  <rjones@redhat.com>
17187
17188         * modules/fsync-tests: New file.
17189         * tests/test-fsync.c: New file.
17190
17191         New module 'fsync'.
17192         * lib/fsync.c: New file.
17193         * m4/fsync.m4: New file.
17194         * modules/fsync: New file.
17195         * lib/unistd.in.h (fsync): New declaration.
17196         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Define and AC_SUBST both
17197         GNULIB_FSYNC and HAVE_FSYNC.
17198         * modules/unistd: Substitute GNULIB_FSYNC and HAVE_FSYNC.
17199         * MODULES.html.sh (posix_functions): Add fsync.
17200         * doc/posix-functions/fsync.texi: Mention the new module.
17201
17202 2008-10-02  Jim Meyering  <meyering@redhat.com>
17203
17204         fts.c: sync with similar code from coreutils' remove.c
17205         * lib/fts.c (dirent_inode_sort_may_be_useful): Merge from coreutils.
17206         Guard also with "#if defined __linux__", since for now at least,
17207         this code is Linux-kernel-specific.
17208
17209 2008-10-02  Jim Meyering  <meyering@redhat.com>
17210
17211         fts: bug fixes
17212         * lib/fts.c: Remove unnecessary "defined" in cpp directive.
17213         Include <sys/vfs.h>, not <sys/statfs.h>.
17214
17215         * m4/fts.m4 (gl_FUNC_FTS_CORE): Fix typo s/vfs/vfs.h/.
17216         Include <sys/vfs.h>, not <sys/statfs.h>.
17217
17218 2008-10-01  Bruno Haible  <bruno@clisp.org>
17219
17220         Avoid the broken posix_spawn function on AIX 5.3 and 6.1.
17221         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): New macro.
17222         (gl_POSIX_SPAWN_BODY): Invoke it. Set REPLACE_POSIX_SPAWN if needed.
17223         * doc/posix-functions/posix_spawn.texi: Mention the AIX bugs.
17224         * doc/posix-functions/posix_spawnp.texi: Likewise.
17225         * m4/execute.m4 (gl_EXECUTE): Invoke gl_POSIX_SPAWN_WORKS, to check
17226         whether posix_spawn actually works.
17227         * m4/pipe.m4 (gl_PIPE): Likewise.
17228         * modules/execute (Files): Add m4/posix_spawn.m4.
17229         * modules/pipe (Files): Add m4/posix_spawn.m4.
17230         Reported and analyzed by Rainer Tammer <tammer@tammer.net>.
17231
17232 2008-10-01  Jim Meyering  <meyering@redhat.com>
17233
17234         remove trailing spaces
17235         * NEWS: Likewise.
17236         * lib/poll.c (poll): Likewise.
17237         * lib/sys_socket.in.h (SHUT_RDWR): Likewise.
17238         * lib/winsock.c (rpl_close): Likewise.
17239         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Likewise.
17240         * modules/yield: Likewise.
17241         * tests/test-poll.c (connect_to_socket, poll1): Likewise.
17242         * tests/test-sys_select.c (connect_to_socket): Likewise.
17243
17244         fts.c: adjust a new interface to be more generally useful
17245         * lib/fts.c (dirent_inode_sort_may_be_useful): Take an FD parameter.
17246         (fts_build): Adjust caller.
17247
17248 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17249
17250         * modules/cond-tests: New file.
17251         * tests/test-cond.c: New file.
17252
17253 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17254             Bruno Haible  <bruno@clisp.org>
17255
17256         * modules/cond (Dependencies): Add errno, time.
17257         * lib/glthread/cond.h: Include <time.h>.
17258         (gl_cond_define, gl_cond_define_initialized): Use the same definition
17259         across platforms.
17260
17261 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17262             Bruno Haible  <bruno@clisp.org>
17263
17264         * m4/thread.m4 (gl_THREAD): Fix detection of pthread_atfork function.
17265
17266 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17267             Bruno Haible  <bruno@clisp.org>
17268
17269         * modules/tls-tests (Depends-on): Add thread, yield.
17270         (configure.ac): Remove all checks.
17271         (test_tls_LDADD): Use YIELD_LIB instead of LIBSCHED.
17272         * tests/test-tls.c (gl_thread_t, gl_thread_join, gl_thread_yield,
17273         gl_thread_self): Remove definitions. Include glthread/thread.h and
17274         glthread/yield.h instead.
17275         (test_tls): Pass an additional NULL argument to gl_thread_join.
17276
17277 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17278             Bruno Haible  <bruno@clisp.org>
17279
17280         * modules/lock-tests (Depends-on): Add thread, yield.
17281         (configure.ac): Remove all checks.
17282         (test_lock_LDADD): Use YIELD_LIB instead of LIBSCHED.
17283         * tests/test-lock.c (gl_thread_t, gl_thread_join, gl_thread_yield,
17284         gl_thread_self): Remove definitions. Include glthread/thread.h and
17285         glthread/yield.h instead.
17286         (test_lock, test_rwlock, test_recursive_lock, test_once): Pass an
17287         additional NULL argument to gl_thread_join.
17288
17289 2008-09-30  Bruno Haible  <bruno@clisp.org>
17290
17291         Fix the Win32 implementation of the 'thread' module.
17292         * lib/glthread/thread.h [USE_WIN32_THREADS] (gl_thread_t): Change to a
17293         pointer type.
17294         (gl_thread_self): Invoke gl_thread_self_func.
17295         (gl_thread_self_func): New declaration.
17296         * lib/glthread/thread.c [USE_WIN32_THREADS] (self_key): New variable.
17297         (do_init_self_key, init_self_key): New functions.
17298         (struct gl_thread_struct): Renamed from 'struct thread_extra'.
17299         Remove some fields.
17300         (running_threads, running_lock): Remove variables.
17301         (get_current_thread_handle): New function.
17302         (gl_thread_self_func, wrapper_func, glthread_create_func,
17303         glthread_join_func, gl_thread_exit_func): Largely rewritten and
17304         simplified.
17305
17306 2008-09-30  Bruno Haible  <bruno@clisp.org>
17307
17308         * lib/winsock-select.c (win32_poll_handle): Add shortcut for regular
17309         files.
17310
17311 2008-09-30  Jim Meyering  <meyering@redhat.com>
17312
17313         fts.m4: correct the test for statfs.f_type
17314         * m4/fts.m4 (gl_FUNC_FTS_CORE): Include <sys/statfs.h>
17315         when checking for statfs.f_type.
17316
17317 2008-09-15  Simon Josefsson  <simon@josefsson.org>
17318
17319         tests: avoid some compiler warnings
17320         * tests/test-memchr.c (main): Pass NULL indirectly.
17321         * tests/test-getdate.c (main): Remove unused variable 'ret'.
17322
17323 2008-09-29  OndÅ™ej Vašík  <ovasik@redhat.com>
17324
17325         getdate.y: disallow countable dayshifts like "4 yesterday ago"
17326         * lib/getdate.y (relative_time_table) [tDAY_SHIFT]: New type for
17327         exactly specified dayshifts.
17328         (dayshift): New rule.
17329         (rel): Add dayshift.
17330         (relative_time_table) [tomorrow, yesterday, today, now]:
17331         Use tDAY_SHIFT in place of tDAY_UNIT.
17332         * tests/test-getdate.c: Add tests for now-disallowed countable
17333         dayshifts, e.g., "4 yesterday ago".
17334
17335 2008-09-29  Bruno Haible  <bruno@clisp.org>
17336
17337         * tests/test-posix_spawn1.c: Renamed from tests/test-posix_spawn.c.
17338         * tests/test-posix_spawn1.in.sh: Renamed from
17339         tests/test-posix_spawn.in.sh.
17340         * tests/test-posix_spawn2.c: New file.
17341         * tests/test-posix_spawn2.in.sh: New file.
17342         * modules/posix_spawnp-tests (Files): Update.
17343         (Makefile.am): Update. Add test-posix_spawn2 to the tests.
17344
17345 2008-09-29  Bruno Haible  <bruno@clisp.org>
17346
17347         Propagate effects of putenv/setenv/unsetenv to child processes.
17348         * lib/execute.c (execute): Use spawnvpe instead of spawnvp.
17349         * lib/pipe.c (create_pipe): Likewise.
17350
17351 2008-09-29  Bruno Haible  <bruno@clisp.org>
17352
17353         Enable use of shell scripts as executables in mingw.
17354         * lib/execute.c (execute): When spawnv fails with error ENOEXEC,
17355         run the program as a shell script.
17356         * lib/pipe.c (create_pipe): Likewise.
17357         * lib/w32spawn.h (prepare_spawn): Add a hidden element in front of the
17358         resulting array.
17359
17360 2008-09-29  Eric Blake  <ebb9@byu.net>
17361
17362         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): Fix typo.
17363
17364 2008-08-24  Paolo Bonzini  <bonzini@gnu.org>
17365
17366         * doc/posix-functions/accept.texi: Update mingw problems.
17367         * doc/posix-functions/bind.texi: Update mingw problems.
17368         * doc/posix-functions/close.texi: Update mingw problems.
17369         * doc/posix-functions/connect.texi: Update mingw problems.
17370         * doc/posix-functions/getpeername.texi: Update mingw problems.
17371         * doc/posix-functions/getsockname.texi: Update mingw problems.
17372         * doc/posix-functions/getsockopt.texi: Update mingw problems.
17373         * doc/posix-functions/ioctl.texi: Update mingw problems.
17374         * doc/posix-functions/listen.texi: Update mingw problems.
17375         * doc/posix-functions/recv.texi: Update mingw problems.
17376         * doc/posix-functions/recvfrom.texi: Update mingw problems.
17377         * doc/posix-functions/select.texi: Update mingw problems.
17378         * doc/posix-functions/send.texi: Update mingw problems.
17379         * doc/posix-functions/sendto.texi: Update mingw problems.
17380         * doc/posix-functions/setsockopt.texi: Update mingw problems.
17381         * doc/posix-functions/socket.texi: Update mingw problems.
17382
17383 2008-09-29  Paolo Bonzini  <bonzini@gnu.org>
17384             Bruno Haible  <bruno@clisp.org>
17385
17386         * lib/sys_select.in.h: Include sys/time.h.
17387         * m4/sys_select.h.m4: Test that struct timeval is fully defined.
17388         * modules/sys_select: Depend on sys_time.
17389         * tests/test-sys_select.c: Test that sys/select.h defines struct
17390         timeval fully.
17391
17392 2008-09-29  Bruno Haible  <bruno@clisp.org>
17393
17394         * lib/sys_socket.in.h: Wrap the definitions in 'extern "C"'.
17395         * lib/sys_select.in.h: Likewise.
17396
17397 2008-09-29  Bruno Haible  <bruno@clisp.org>
17398
17399         * lib/winsock.c (rpl_close, rpl_socket): Remove unused variables.
17400
17401 2008-09-29  Bruno Haible  <bruno@clisp.org>
17402
17403         * m4/sockets.m4 (gl_SOCKETS): Check also for the need to use -lsocket.
17404         Set LIBSOCKET instead of augmenting LIBS.
17405         * modules/sockets (Link): New section.
17406         * modules/sockets-tests (test_sockets_LDADD): New variable.
17407         * modules/sys_select-tests (test_sys_select_LDADD): New variable.
17408         * modules/poll-tests (test_poll_LDADD): New variable.
17409         * NEWS: Document the change.
17410
17411 2008-09-29  Bruno Haible  <bruno@clisp.org>
17412
17413         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): New macro.
17414         * m4/inet_ntop.m4 (gl_INET_NTOP): Invoke it instead of assigning
17415         ARPA_INET_H directly.
17416         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
17417
17418 2008-09-28  Bruno Haible  <bruno@clisp.org>
17419
17420         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): New macro, extracted
17421         from gl_HEADER_SYS_SOCKET.
17422         (gl_HEADER_SYS_SOCKET): Invoke it.
17423         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
17424
17425 2008-09-28  Bruno Haible  <bruno@clisp.org>
17426
17427         * doc/posix-headers/sys_select.texi: Mention 'struct timeval' problem.
17428         * tests/test-sys_select.c: Include <sys/time.h>, for struct timeval.
17429         Needed on OSF/1 4.0.
17430
17431 2008-09-28  Bruno Haible  <bruno@clisp.org>
17432
17433         Override open more carefully.
17434         * lib/open.c (orig_open): New function.
17435         (rpl_open): Use orig_open instead of open.
17436         * lib/fcntl.in.h: Add special invocation convention.
17437         * m4/open.m4 (gl_PREREQ_OPEN): New macro.
17438         (gl_FUNC_OPEN): Invoke it.
17439
17440         Override freopen more carefully.
17441         * lib/freopen.c (orig_freopen): New function.
17442         (rpl_freopen): Use orig_freopen instead of freopen.
17443         * m4/freopen.m4 (gl_PREREQ_FREOPEN): New macro.
17444         (gl_FUNC_FREOPEN): Invoke it.
17445
17446         Override fopen more carefully.
17447         * lib/fopen.c (orig_fopen): New function.
17448         (rpl_fopen): Use orig_fopen instead of fopen.
17449         * m4/fopen.m4 (gl_PREREQ_FOPEN): New macro.
17450         (gl_FUNC_FOPEN): Invoke it.
17451         Needed on AIX. Reported by Rainer Tammer <tammer@tammer.net>.
17452
17453 2008-09-28  Bruno Haible  <bruno@clisp.org>
17454
17455         * lib/pipe.h (create_pipe_out, create_pipe_bidi): Add comment about
17456         SIGPIPE.
17457
17458 2008-09-28  Bruno Haible  <bruno@clisp.org>
17459
17460         * tests/test-sigaction.c (handler, main): Disable the check whether
17461         SA_RESETHAND has reverted the installed handler to SIG_DFL. Needed on
17462         glibc systems with LinuxThreads.
17463
17464 2008-09-28  Bruno Haible  <bruno@clisp.org>
17465
17466         * doc/posix-functions/freopen.texi: Mention the trailing slash problem.
17467
17468         * lib/stdio.in.h (fopen, freopen): Undefine before redefining. Needed
17469         with AIX xlc.
17470         * lib/fcntl.in.h (open): Likewise.
17471         Reported by Rainer Tammer <tammer@tammer.net>.
17472
17473 2008-09-28  Bruno Haible  <bruno@clisp.org>
17474
17475         * modules/posix_spawnp-tests: New file.
17476         * tests/test-posix_spawn.c: New file.
17477         * tests/test-posix_spawn.in.sh: New file.
17478
17479         New module 'posix_spawnp'.
17480         * modules/posix_spawnp: New file.
17481         * lib/spawnp.c: New file, from GNU libc with modifications.
17482         * doc/posix-functions/posix_spawnp.texi: Mention the new module.
17483
17484         New module 'posix_spawn'.
17485         * modules/posix_spawn: New file.
17486         * lib/spawn.c: New file, from GNU libc with modifications.
17487         * doc/posix-functions/posix_spawn.texi: Mention the new module.
17488
17489         New module 'posix_spawnattr_destroy'.
17490         * modules/posix_spawnattr_destroy: New file.
17491         * lib/spawnattr_destroy.c: New file, from GNU libc with modifications.
17492         * doc/posix-functions/posix_spawnattr_destroy.texi: Mention the new
17493         module.
17494
17495         New module 'posix_spawnattr_setsigmask'.
17496         * modules/posix_spawnattr_setsigmask: New file.
17497         * lib/spawnattr_setsigmask.c: New file, from GNU libc with
17498         modifications.
17499         * doc/posix-functions/posix_spawnattr_setsigmask.texi: Mention the
17500         new module.
17501
17502         New module 'posix_spawnattr_getsigmask'.
17503         * modules/posix_spawnattr_getsigmask: New file.
17504         * lib/spawnattr_getsigmask.c: New file, from GNU libc with
17505         modifications.
17506         * doc/posix-functions/posix_spawnattr_getsigmask.texi: Mention the
17507         new module.
17508
17509         New module 'posix_spawnattr_setsigdefault'.
17510         * modules/posix_spawnattr_setsigdefault: New file.
17511         * lib/spawnattr_setdefault.c: New file, from GNU libc with
17512         modifications.
17513         * doc/posix-functions/posix_spawnattr_setsigdefault.texi: Mention the
17514         new module.
17515
17516         New module 'posix_spawnattr_getsigdefault'.
17517         * modules/posix_spawnattr_getsigdefault: New file.
17518         * lib/spawnattr_getdefault.c: New file, from GNU libc with
17519         modifications.
17520         * doc/posix-functions/posix_spawnattr_getsigdefault.texi: Mention the
17521         new module.
17522
17523         New module 'posix_spawnattr_setschedpolicy'.
17524         * modules/posix_spawnattr_setschedpolicy: New file.
17525         * lib/spawnattr_setschedpolicy.c: New file, from GNU libc with
17526         modifications.
17527         * doc/posix-functions/posix_spawnattr_setschedpolicy.texi: Mention the
17528         new module.
17529
17530         New module 'posix_spawnattr_getschedpolicy'.
17531         * modules/posix_spawnattr_getschedpolicy: New file.
17532         * lib/spawnattr_getschedpolicy.c: New file, from GNU libc with
17533         modifications.
17534         * doc/posix-functions/posix_spawnattr_getschedpolicy.texi: Mention the
17535         new module.
17536
17537         New module 'posix_spawnattr_setschedparam'.
17538         * modules/posix_spawnattr_setschedparam: New file.
17539         * lib/spawnattr_setschedparam.c: New file, from GNU libc with
17540         modifications.
17541         * doc/posix-functions/posix_spawnattr_setschedparam.texi: Mention the
17542         new module.
17543
17544         New module 'posix_spawnattr_getschedparam'.
17545         * modules/posix_spawnattr_getschedparam: New file.
17546         * lib/spawnattr_getschedparam.c: New file, from GNU libc with
17547         modifications.
17548         * doc/posix-functions/posix_spawnattr_getschedparam.texi: Mention the
17549         new module.
17550
17551         New module 'posix_spawnattr_setpgroup'.
17552         * modules/posix_spawnattr_setpgroup: New file.
17553         * lib/spawnattr_setpgroup.c: New file, from GNU libc with
17554         modifications.
17555         * doc/posix-functions/posix_spawnattr_setpgroup.texi: Mention the new
17556         module.
17557
17558         New module 'posix_spawnattr_getpgroup'.
17559         * modules/posix_spawnattr_getpgroup: New file.
17560         * lib/spawnattr_getpgroup.c: New file, from GNU libc with
17561         modifications.
17562         * doc/posix-functions/posix_spawnattr_getpgroup.texi: Mention the new
17563         module.
17564
17565         New module 'posix_spawnattr_setflags'.
17566         * modules/posix_spawnattr_setflags: New file.
17567         * lib/spawnattr_setflags.c: New file, from GNU libc with modifications.
17568         * doc/posix-functions/posix_spawnattr_setflags.texi: Mention the new
17569         module.
17570
17571         New module 'posix_spawnattr_getflags'.
17572         * modules/posix_spawnattr_getflags: New file.
17573         * lib/spawnattr_getflags.c: New file, from GNU libc with modifications.
17574         * doc/posix-functions/posix_spawnattr_getflags.texi: Mention the new
17575         module.
17576
17577         New module 'posix_spawnattr_init'.
17578         * modules/posix_spawnattr_init: New file.
17579         * lib/spawnattr_init.c: New file, from GNU libc with modifications.
17580         * doc/posix-functions/posix_spawnattr_init.texi: Mention the new
17581         module.
17582
17583         New module 'posix_spawn_file_actions_destroy'.
17584         * modules/posix_spawn_file_actions_destroy: New file.
17585         * lib/spawn_faction_destroy.c: New file, from GNU libc with
17586         modifications.
17587         * doc/posix-functions/posix_spawn_file_actions_destroy.texi: Mention
17588         the new module.
17589
17590         New module 'posix_spawn_file_actions_addopen'.
17591         * modules/posix_spawn_file_actions_addopen: New file.
17592         * lib/spawn_faction_addopen.c: New file, from GNU libc with
17593         modifications.
17594         * doc/posix-functions/posix_spawn_file_actions_addopen.texi: Mention
17595         the new module.
17596
17597         New module 'posix_spawn_file_actions_adddup2'.
17598         * modules/posix_spawn_file_actions_adddup2: New file.
17599         * lib/spawn_faction_adddup2.c: New file, from GNU libc with
17600         modifications.
17601         * doc/posix-functions/posix_spawn_file_actions_adddup2.texi: Mention
17602         the new module.
17603
17604         New module 'posix_spawn_file_actions_addclose'.
17605         * modules/posix_spawn_file_actions_addclose: New file.
17606         * lib/spawn_faction_addclose.c: New file, from GNU libc with
17607         modifications.
17608         * doc/posix-functions/posix_spawn_file_actions_addclose.texi: Mention
17609         the new module.
17610
17611         New module 'posix_spawn_file_actions_init'.
17612         * modules/posix_spawn_file_actions_init: New file.
17613         * lib/spawn_faction_init.c: New file, from GNU libc with modifications.
17614         * doc/posix-functions/posix_spawn_file_actions_init.texi: Mention the
17615         new module.
17616
17617         New module 'posix_spawn-internal'.
17618         * modules/posix_spawn-internal: New file.
17619         * lib/spawn_int.h: New file, from GNU libc with modifications.
17620         * lib/spawni.c: New file, from GNU libc with modifications.
17621         * m4/posix_spawn.m4: New file.
17622
17623         New module 'spawn'.
17624         * modules/spawn: New file.
17625         * lib/spawn.in.h: New file, from GNU libc with modifications.
17626         * m4/spawn_h.m4: New file.
17627         * doc/posix-headers/spawn.texi: Mention the new module.
17628
17629 2008-09-28  Bruno Haible  <bruno@clisp.org>
17630
17631         * modules/sched-tests: New file.
17632         * tests/test-sched.c: New file.
17633
17634         New module 'sched'.
17635         * modules/sched: New file.
17636         * lib/sched.in.h: New file.
17637         * m4/sched_h.m4: New file.
17638         * doc/posix-headers/sched.texi: Mention the new module.
17639
17640 2008-09-27  Eric Blake  <ebb9@byu.net>
17641
17642         Fix previous patch, and tweak references to $0.
17643         * posix-modules: Call func_gnulib_dir before using $gnulib_dir.
17644         (func_version, func_gnulib_dir): Don't call this program
17645         gnulib-tool.
17646         (func_gnulib_dir, func_tmpdir, func_fatal_error): Avoid shell bugs
17647         with using $0 in function.
17648         * gnulib-tool (func_gnulib_dir, func_tmpdir): Likewise.
17649         (func_fatal_error): Reuse the name the user invoked us with.
17650
17651 2008-09-27  Bruno Haible  <bruno@clisp.org>
17652
17653         * m4/iconv_h.m4 (gl_REPLACE_ICONV_H): New macro.
17654         (gl_ICONV_H_DEFAULTS): Initialize ICONV_H here...
17655         (gl_ICONV_H): Not here.
17656         * m4/iconv_open.m4 (gl_REPLACE_ICONV_OPEN): Invoke gl_REPLACE_ICONV_H
17657         instead of assigning ICONV_H directly.
17658
17659         * m4/wchar.m4 (gl_REPLACE_WCHAR_H): New macro.
17660         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Invoke it instead of assigning
17661         WCHAR_H directly.
17662
17663 2008-09-27  Bruno Haible  <bruno@clisp.org>
17664
17665         * lib/arpa_inet.in.h: Include the GL_LINK_WARNING anchor.
17666         * modules/arpa_inet (Depends-on): Add link-warning.
17667         (Makefile.am): Insert the definition of GL_LINK-WARNING.
17668         * modules/unistd (Makefile.am): Likewise.
17669
17670 2008-09-26  Bruno Haible  <bruno@clisp.org>
17671
17672         * posix-modules (cvsdatestamp, last_checkin_date, version): Remove
17673         variables.
17674         (func_version): Essentially copied from gnulib-tool.
17675         (func_exit, func_gnulib_dir, func_tmpdir, func_fatal_error,
17676         func_readlink): Copied from gnulib-tool.
17677
17678 2008-09-26  Bruno Haible  <bruno@clisp.org>
17679
17680         * gnulib-tool (func_version): Change directory to $gnulib_dir before
17681         invoking git-version-gen.
17682
17683 2008-09-26  Bruno Haible  <bruno@clisp.org>
17684
17685         * posix-modules: Update to directory names changed on 2008-01-19.
17686         Remove commas in output before splitting into words. No more need to
17687         avoid 'ftruncate' since 2007-02-19.
17688
17689 2008-09-26  Bruno Haible  <bruno@clisp.org>
17690
17691         * doc/posix-headers/errno.texi: Remove mention of module 'EOVERFLOW'.
17692
17693 2008-09-26  Bruno Haible  <bruno@clisp.org>
17694
17695         * lib/fwriteerror.c (do_fwriteerror): Ignore error EPIPE.
17696         * modules/fwriteerror (Depends-on): Add errno.
17697
17698 2008-09-26  Bruno Haible  <bruno@clisp.org>
17699
17700         * tests/test-vc-list-files-git.sh: Explain reason for skipping test.
17701         * tests/test-vc-list-files-cvs.sh: Likewise.
17702
17703 2008-09-26  Bruno Haible  <bruno@clisp.org>
17704
17705         * doc/posix-headers/sys_resource.texi: Reorder items.
17706
17707 2008-09-26  Jim Meyering  <meyering@redhat.com>
17708
17709         fts: tweak inode comparison function
17710         * lib/fts.c (fts_compare_ino): Sort on increasing, not decreasing
17711         inode numbers, as documented.
17712
17713         fts: sort dirent entries on inode number before traversing
17714         This avoids a quadratic, seek-related performance penalty when
17715         operating on a directory containing many entries (measurable at 10k;
17716         3.5 hours at 2 million entries with a cold cache) on certain types
17717         of file systems, including ext3 and ext4, but not tmpfs.
17718         * lib/fts.c (DT_MUST_BE, NOT_AN_INODE_NUMBER, D_INO): Define.
17719         (FTS_INODE_SORT_DIR_ENTRIES_THRESHOLD): Define if not defined.
17720         (S_MAGIC_TMPFS, S_MAGIC_NFS): Define.
17721         (fs_handles_readdir_ordered_dirents_efficiently): New function.
17722         (dirent_inode_sort_may_be_useful, fts_compare_ino): Likewise.
17723         (fts_build): Set the stat.st_ino member from D_INO.
17724         If it is likely to be useful, sort dirent entries on inode number.
17725
17726         * m4/fts.m4 (gl_FUNC_FTS_CORE): Check for fstatfs, sys/vfs.h,
17727         and the struct statfs.f_type member.
17728         * modules/fts (Depends-on): Add d-ino.
17729
17730 2008-09-26  Bruno Haible  <bruno@clisp.org>
17731
17732         * modules/sigpipe-die (Depends-on): Add sigpipe.
17733
17734         * lib/stdio.in.h (fprintf, vfprintf, printf, vprintf, fputc, putc,
17735         putchar, fputs, puts, fwrite): Replace when REPLACE_STDIO_WRITE_FUNCS
17736         and GNULIB_STDIO_H_SIGPIPE are set.
17737         * lib/stdio-write.c: New file.
17738         * m4/stdio_h.m4 (gl_STDIO_H): Set GNULIB_FPRINTF, GNULIB_PRINTF,
17739         GNULIB_VFPRINTF, GNULIB_VPRINTF, GNULIB_FPUTC, GNULIB_PUTC,
17740         GNULIB_PUTCHAR, GNULIB_FPUTS, GNULIB_PUTS, GNULIB_FWRITE,
17741         REPLACE_STDIO_WRITE_FUNCS.
17742         (gl_STDIO_H_DEFAULTS): Initialize GNULIB_FPRINTF, GNULIB_PRINTF,
17743         GNULIB_VFPRINTF, GNULIB_VPRINTF, GNULIB_FPUTC, GNULIB_PUTC,
17744         GNULIB_PUTCHAR, GNULIB_FPUTS, GNULIB_PUTS, GNULIB_FWRITE,
17745         GNULIB_STDIO_H_SIGPIPE, REPLACE_STDIO_WRITE_FUNCS.
17746         * modules/stdio (Files): Add lib/stdio-write.c.
17747         (Makefile.am): Substitute GNULIB_FPRINTF, GNULIB_PRINTF,
17748         GNULIB_VFPRINTF, GNULIB_VPRINTF, GNULIB_FPUTC, GNULIB_PUTC,
17749         GNULIB_PUTCHAR, GNULIB_FPUTS, GNULIB_PUTS, GNULIB_FWRITE,
17750         GNULIB_STDIO_H_SIGPIPE, REPLACE_STDIO_WRITE_FUNCS.
17751         * m4/fprintf-posix.m4 (gl_REPLACE_FPRINTF): Define
17752         REPLACE_FPRINTF_POSIX.
17753         * m4/printf-posix-rpl.m4 (gl_REPLACE_PRINTF): Define
17754         REPLACE_PRINTF_POSIX.
17755         * m4/vfprintf-posix.m4 (gl_REPLACE_VFPRINTF): Define
17756         REPLACE_VFPRINTF_POSIX.
17757         * m4/vprintf-posix.m4 (gl_REPLACE_VPRINTF): Define
17758         REPLACE_VPRINTF_POSIX.
17759         * doc/posix-functions/fprintf.texi: Mention the sigpipe module and the
17760         SIGPIPE issue.
17761         * doc/posix-functions/fputc.texi: Likewise.
17762         * doc/posix-functions/fputs.texi: Likewise.
17763         * doc/posix-functions/fwrite.texi: Likewise.
17764         * doc/posix-functions/printf.texi: Likewise.
17765         * doc/posix-functions/putc.texi: Likewise.
17766         * doc/posix-functions/putchar.texi: Likewise.
17767         * doc/posix-functions/puts.texi: Likewise.
17768         * doc/posix-functions/vfprintf.texi: Likewise.
17769         * doc/posix-functions/vprintf.texi: Likewise.
17770
17771         * modules/safe-write (Depends-on): Add write.
17772
17773         * modules/sigpipe-tests: New file.
17774         * tests/test-sigpipe.c: New file.
17775         * tests/test-sigpipe.sh: New file.
17776
17777         * modules/write: New file.
17778         * lib/unistd.in.h: Include <sys/types.h>.
17779         (write): New declaration.
17780         * lib/write.c: New file.
17781         * m4/write.m4: New file.
17782         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
17783         GNULIB_UNISTD_H_SIGPIPE, GNULIB_WRITE, REPLACE_WRITE.
17784         * modules/unistd (Makefile.am): Substitute GNULIB_UNISTD_H_SIGPIPE,
17785         GNULIB_WRITE, REPLACE_WRITE.
17786         * doc/posix-functions/write.texi: Mention the write, sigpipe modules
17787         and the SIGPIPE issue.
17788
17789         * lib/signal.in.h (SIGPIPE): Define to a replacement value.
17790         (raise): New declaration.
17791         * lib/sigprocmask.c (SIGPIPE_handler): New variable.
17792         (ext_signal): New function.
17793         (rpl_raise): New function.
17794         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Initialize
17795         GNULIB_SIGNAL_H_SIGPIPE.
17796         * modules/signal (Makefile.am): Substitute GNULIB_SIGNAL_H_SIGPIPE.
17797         * doc/posix-headers/signal.texi: Mention the SIGPIPE issue.
17798
17799         * modules/sigpipe: New file.
17800         * m4/sigpipe.m4: New file.
17801
17802 2008-09-25  Derek Price  <derek@ximbiot.com>
17803             Bruno Haible  <bruno@clisp.org>
17804
17805         * gnulib-tool (func_import): Report all license incompatibilities, not
17806         just the first one.
17807
17808 2008-09-25  Bruno Haible  <bruno@clisp.org>
17809
17810         * gnulib-tool (func_import): When computing the edits, consider not
17811         only the Makefile.ams that exist but also those that will be generated.
17812
17813 2008-09-25  Simon Josefsson  <simon@josefsson.org>
17814
17815         * modules/sys_select-tests (Depends-on): Remove sys_select itself,
17816         fixes gnulib-tool --test warning about duplicate dependency.
17817
17818 2008-09-25  Bruno Haible  <bruno@clisp.org>
17819
17820         * gnulib-tool: Don't ask the user to perform edits in the generated
17821         Makefile.ams.
17822         (func_emit_lib_Makefile_am): Emit empty SUBDIRS. Execute edits that
17823         apply to the Makefile.am being generated.
17824         (func_emit_tests_Makefile_am): Execute edits that apply to the
17825         Makefile.am being generated.
17826         (func_import): Setup list of Makefile.am edits before emitting the
17827         Makefile.ams, not at the end.
17828         (func_create_testdir): Update.
17829         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
17830
17831 2008-09-25  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17832
17833         * gnulib-tool (func_import): Store the --tests-base option in the
17834         comment in gnulib-cache.m4.
17835
17836 2008-09-24  Paolo Bonzini  <bonzini@gnu.org>
17837
17838         * NEWS: Document increased portability that sys_select now provides.
17839
17840         * lib/sys_select.in.h: Install select wrapper.
17841         * lib/sys_socket.in.h: Use more descriptive name when there is no
17842         select wrapper.
17843         * lib/winsock-select.c: New.
17844         * m4/sys_select_h.m4: Compile lib/winsock-select.c if WinSock is used.
17845         Require gl_HEADER_SYS_SOCKET.
17846         * modules/sys_select: Depend on alloca, add lib/winsock-select.c.
17847         * modules/sys_select-tests: Copy dependencies from modules/poll-tests.
17848         * tests/test-sys_select.c: Add functional tests.
17849
17850 2008-09-24  Eric Blake  <ebb9@byu.net>
17851
17852         open, fopen: close fd leak in last patch
17853         * lib/open.c (rpl_open): Close fd before returning error.
17854         * lib/fopen.c (rpl_fopen): Close fd before returning error.
17855         * doc/posix-functions/open.texi (open): Document that Irix also
17856         has the bug.
17857         * doc/posix-functions/fopen.texi (fopen): Likewise.
17858         Reported by Paolo Bonzini.
17859
17860 2008-09-24  Bruno Haible  <bruno@clisp.org>
17861
17862         Ensure that a filename ending in a slash cannot be used to access a
17863         non-directory.
17864         * lib/open.c (rpl_open): When the filename ends in a slash, use fstat()
17865         to check whether it's really a directory.
17866         * lib/fopen.c: Include fcntl.h, unistd.h.
17867         (rpl_fopen): When the filename ends in a slash, use open(), fstat(),
17868         and fdopen().
17869         * modules/fopen (Depends-on): Add unistd.
17870         * tests/test-open.c (main): Try to open "/dev/null/" as a directory.
17871         * tests/test-fopen.c (main): Likewise.
17872         * doc/posix-functions/open.texi: Mention the HP-UX, Solaris bug.
17873         * doc/posix-functions/fopen.texi: Likewise.
17874         Reported by Eric Blake.
17875
17876 2008-09-23  Eric Blake  <ebb9@byu.net>
17877
17878         c-stack: avoid compiler optimizations when provoking overflow
17879         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Make
17880         recursion harder to optimize, to ensure a stack overflow occurs.
17881         * tests/test-c-stack.c (recurse): Likewise.
17882         Borrowed from libsigsegv.
17883
17884         c-stack: work around Irix sigaltstack bug
17885         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Check
17886         whether sigaltstack uses wrong end of stack_t (copied in part from
17887         libsigsegv).
17888         * lib/c-stack.c (c_stack_action) [!HAVE_LIBSIGSEGV]: Work around
17889         Irix bug, without requiring an over-allocation.
17890         * doc/posix-functions/sigaltstack.texi (sigaltstack): Document the
17891         bug.
17892
17893         fopen: document mingw bug on directories
17894         * doc/posix-functions/fopen.texi (fopen): Mention mingw bug for
17895         not allowing a stream visiting a directory, even though reading
17896         from such a stream is not portable.
17897
17898 2008-09-23  Paolo Bonzini  <bonzini@gnu.org>
17899
17900         * lib/poll.c: Rewrite.
17901         * modules/poll: Depend on alloca.
17902
17903 2008-09-23  Paolo Bonzini  <bonzini@gnu.org>
17904
17905         * lib/sys_socket.in.h: Do not implement rpl_setsockopt here,
17906         instead define prototypes for a full set of wrappers.  Ensure
17907         that Cygwin does not use the compatibility code, which is only
17908         for MinGW.
17909         * lib/winsock.c: New.
17910         * m4/sys_socket_h.m4: Compile lib/winsock.c if WinSock is being used.
17911         * modules/sys_socket: Add lib/winsock.c.
17912
17913         * modules/poll-tests: Add errno and perror.
17914         * tests/test-poll.c: Use ioctl, not ioctlsocket.
17915
17916 2008-09-23  Paolo Bonzini  <bonzini@gnu.org>
17917
17918         * tests/test-poll.c: Downgrade minimum needed Winsock version.
17919
17920 2008-09-23  Bruno Haible  <bruno@clisp.org>
17921
17922         * doc/posix-functions/*: Add info about functions missing on IRIX 5.3.
17923         * doc/glibc-functions/*: Likewise.
17924
17925 2008-09-23  Simon Josefsson  <simon@josefsson.org>
17926
17927         * tests/test-perror.sh (tmpfiles): Cleanup temporary files on
17928         success.
17929
17930 2008-09-22  Eric Blake  <ebb9@byu.net>
17931             Bruno Haible  <bruno@clisp.org>
17932
17933         vasnprintf: fix x86/glibc regression on printf("%La", 0.0L)
17934         * lib/vasnprintf.c (VASNPRINTF): Support 0.0 on platforms that
17935         supply %A but mishandle pseudo-NaN.
17936         Reported by Simon Josefsson.
17937
17938 2008-09-21  Bruno Haible  <bruno@clisp.org>
17939
17940         * tests/test-lock.c (main): Tweak skip message.
17941         * tests/test-tls.c (main): Likewise.
17942
17943 2008-09-21  Bruno Haible  <bruno@clisp.org>
17944
17945         * m4/sigaction.m4 (gl_SIGACTION): Remove unnecessary AC_SUBST. Check
17946         whether 'struct sigaction' has sa_sigaction here...
17947         (gl_PREREQ_SIG_HANDLER_H): ... not here.
17948         (gl_PREREQ_SIGACTION): Remove unnecessary AC_SUBST.
17949
17950 2008-09-21  Bruno Haible  <bruno@clisp.org>
17951
17952         * MODULES.html.sh (Support for obsolete systems lacking ANSI C 89): New
17953         section.
17954         (Support for systems lacking ANSI C 89): Move stdlib, exit, strtol,
17955         strtoul, memchr, memcmp, memcpy, memmove, memset, strcspn, strpbrk to
17956         the new section.
17957         (Support for obsolete systems lacking POSIX:2001): New section.
17958         (String handling <string.h>): Move strdup to the new section.
17959         Suggested by Simon Josefsson and Paolo Bonzini.
17960
17961 2008-09-21  Bruno Haible  <bruno@clisp.org>
17962
17963         * tests/test-vasnprintf-posix.c (test_function): Allow 3-digit
17964         exponents in %e and %g results on 'long double'. Needed for mingw's
17965         improved *printf functions.
17966         * tests/test-vasprintf-posix.c (test_function): Likewise.
17967         * tests/test-snprintf-posix.h (test_function): Likewise.
17968         * tests/test-sprintf-posix.h (test_function): Likewise.
17969         Reported by Eric Blake.
17970
17971 2008-09-21  Bruno Haible  <bruno@clisp.org>
17972
17973         * tests/test-snprintf-posix.h (test_function): Remove useless ASSERTs.
17974         * tests/test-sprintf-posix.h (test_function): Likewise.
17975
17976 2008-09-21  Bruno Haible  <bruno@clisp.org>
17977
17978         * modules/getpass (Depends-on): Add strdup-posix.
17979
17980         New module 'strdup-posix'.
17981         * modules/strdup-posix: New file.
17982         * m4/strdup.m4 (gl_FUNC_STRDUP_POSIX): New macro.
17983         * lib/string.in.h (strdup): Replace if REPLACE_STRDUP is 1.
17984         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
17985         REPLACE_STRDUP.
17986         * modules/string (Makefile.am): Substitute REPLACE_STRDUP.
17987         * doc/posix-functions/strdup.texi: Mention module strdup-posix.
17988         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
17989         strdup-posix.
17990
17991         * modules/strdup (Depends-on): Remove malloc-posix.
17992
17993 2008-09-20  Bruno Haible  <bruno@clisp.org>
17994
17995         * lib/fstrcmp.c: Add data about branch probabilities, from Ralf
17996         Wildenhues.
17997
17998 2008-09-20  Bruno Haible  <bruno@clisp.org>
17999
18000         Ensure that wint_t gets defined on IRIX 5.3.
18001         * lib/wchar.in.h (wint_t): Define if not defined by the system.
18002         * lib/wctype.in.h (wint_t): Likewise.
18003         (__wctype_wint_t): Remove type.
18004         (isw*): Use wint_t instead of __wctype_wint_t.
18005         * m4/wchar.m4 (gl_WCHAR_H): Invoke gt_TYPE_WINT_T and set HAVE_WINT_T.
18006         * modules/wchar (Files): Add m4/wint_t.m4.
18007         (Makefile.am): Substitute HAVE_WINT_T.
18008         * tests/test-wchar.c: Check that wchar_t and wint_t are defined.
18009         * tests/test-wctype.c: Check that wint_t is defined.
18010         * doc/posix-headers/wchar.texi: Mention the IRIX 5 problem.
18011         * doc/posix-headers/wctype.texi: Likewise.
18012         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
18013
18014 2008-09-18  Bruno Haible  <bruno@clisp.org>
18015
18016         * gnulib-tool (func_exit): Update comment.
18017
18018 2008-09-18  Simon Josefsson  <simon@josefsson.org>
18019
18020         * modules/getaddrinfo (Depends-on): Remove strdup, this module
18021         assumes strdup exists and does not depend on strdup to return
18022         ENOMEM on out of memory conditions.
18023
18024 2008-09-18  Bruno Haible  <bruno@clisp.org>
18025
18026         * lib/vasnprintf.c (VASNPRINTF): When printing Â±0.0L in
18027         NEED_PRINTF_INFINITE_LONG_DOUBLE case with 'e' format, always use two
18028         digits for the exponent.
18029
18030 2008-09-18  Jim Meyering  <meyering@redhat.com>
18031             Bruno Haible  <bruno@clisp.org>
18032
18033         * lib/vasnprintf.c (decimal_point_char): Define also if
18034         NEED_PRINTF_INFINITE_LONG_DOUBLE.
18035
18036 2008-09-16  Bruno Haible  <bruno@clisp.org>
18037         and Eric Blake  <ebb9@byu.net>
18038
18039         vasnprintf: support Irix 5.3
18040         * lib/vasnprintf.c (VASNPRINTF): Also handle -0.0L on platforms
18041         that mishandle long double infinity.
18042         Reported by Tom G. Christensen.
18043
18044 2008-09-16  Bruno Haible  <bruno@clisp.org>
18045
18046         * doc/glibc-functions/scandir.texi: Mention the function is missing on
18047         Solaris 9.
18048         * doc/glibc-functions/alphasort.texi: Likewise.
18049         Reported by Michael Haubenwallner <michael.haubenwallner@salomon.at>.
18050
18051 2008-09-16  Jim Meyering  <meyering@redhat.com>
18052
18053         posix-shell.m4: reject opensolaris's "sh (AT&T Research) 1993-12-28 s+"
18054         * m4/posix-shell.m4 (gl_POSIX_SHELL): Reject a shell that lets
18055         a umask modification leak out of a subshell.  Otherwise, the
18056         opensolaris /bin/sh would be accepted and thus cause unwarranted
18057         failures in the coreutils test suite.
18058
18059 2008-09-16  Paolo Bonzini  <bonzini@gnu.org>
18060
18061         * tests/test-poll.c (connect_to_socket): Allow non-blocking connect
18062         to succeed.
18063
18064 2008-09-16  Jim Meyering  <meyering@redhat.com>
18065
18066         avoid spurious test failure when library is built without ACL support
18067         * m4/acl.m4 (USE_ACL): Define as a shell variable, too, for...
18068         * modules/acl-tests (Makefile.am) [TESTS_ENVIRONMENT]: Add USE_ACL.
18069         * tests/test-file-has-acl.sh: Skip if USE_ACL == 0.
18070         * tests/test-copy-acl.sh: Likewise.
18071
18072 2008-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
18073
18074         * lib/fstrcmp.c (fstrcmp_bounded): Use a second, less quick upper bound
18075         based on character occurrence counts.
18076
18077 2008-09-15  Eric Blake  <ebb9@byu.net>
18078
18079         tests: avoid some compiler warnings
18080         * tests/test-memchr.c (main): Pass NULL indirectly.
18081         * tests/test-closein.c (main): Avoid unused variable.
18082
18083 2008-09-15  Bruno Haible  <bruno@clisp.org>
18084
18085         * m4/errno_h.m4 (gl_HEADER_ERRNO_H_BODY): Test for all the macros that
18086         are missing on OpenBSD 4.0 individually.
18087         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
18088
18089 2008-09-15  Bruno Haible  <bruno@clisp.org>
18090
18091         * doc/posix-headers/errno.texi: Mention the Cygwin problem.
18092         * doc/posix-functions/strerror.texi: Mention also Cygwin.
18093         * doc/posix-functions/perror.texi: Likewise.
18094         * m4/errno_h.m4 (gl_HEADER_ERRNO_H_BODY): Test also whether ECANCELED
18095         is missing.
18096         Reported by Eric Blake.
18097
18098         * lib/errno.in.h: Use replacement values >= 2000.
18099         Reported by Eric Blake.
18100
18101 2008-09-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
18102
18103         * lib/fstrcmp.c (EXTRA_CONTEXT_FIELDS): Add field 'edit_count_limit'.
18104         (EARLY_ABORT): Return true when the edit_count has grown too beyond the
18105         limit.
18106         (fstrcmp_bounded): Initialize the edit_count_limit. Return 0 when
18107         compareseq was aborted.
18108
18109 2008-09-14  Bruno Haible  <bruno@clisp.org>
18110
18111         * lib/fstrcmp.c (EXTRA_CONTEXT_FIELDS): Combine xvec_edit_count and
18112         yvec_edit_count.
18113         (NOTE_DELETE, NOTE_INSERT): Increment the combined edit count.
18114         (fstrcmp_bounded): Simplify result computation accordingly.
18115
18116 2008-09-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
18117
18118         * lib/fstrcmp.h (fstrcmp_bounded): New declaration.
18119         (fstrcmp): Define in terms of fstrcmp_bounded.
18120         * lib/fstrcmp.c (fstrcmp_bounded): Renamed from fstrcmp. Add
18121         lower_bound argument.
18122         Return quickly if the result is certainly < lower_bound.
18123         * tests/test-fstrcmp.c (check_fstrcmp): Test also fstrcmp_bounded.
18124
18125 2008-09-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
18126
18127         * lib/diffseq.h (EARLY_ABORT): New macro.
18128         (compareseq): Change return type to bool. Return true when EARLY_ABORT
18129         evaluates to true.
18130
18131 2008-09-14  Bruno Haible  <bruno@clisp.org>
18132
18133         * modules/perror-tests: New file.
18134         * tests/test-perror.sh: New file.
18135         * tests/test-perror.c: New file.
18136
18137         New module 'perror'.
18138         * lib/stdio.in.h (perror): New declaration.
18139         * lib/perror.c: New file.
18140         * m4/perror.m4: New file.
18141         * modules/perror: New file.
18142         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add perror.
18143         * doc/posix-functions/perror.texi: Mention the perror module.
18144         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_PERROR,
18145         REPLACE_PERROR.
18146         * modules/stdio (Makefile.am): Substitute GNULIB_PERROR,
18147         REPLACE_PERROR.
18148
18149 2008-09-14  Bruno Haible  <bruno@clisp.org>
18150
18151         * modules/stdio (Makefile.am): Reorder to match the order in
18152         lib/stdio.in.h.
18153         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
18154
18155 2008-09-13  Bruno Haible  <bruno@clisp.org>
18156
18157         * lib/sys_socket.in.h (EINPROGRESS, ...): Remove definitions.
18158
18159 2008-09-13  Bruno Haible  <bruno@clisp.org>
18160
18161         Extend strerror to cover the added errno values.
18162         * lib/strerror.c: Include errno.h and winsock2.h if it exists.
18163         (rpl_strerror): Provide error messages for the added errno values and
18164         for the WSA* values.
18165         * m4/strerror.m4 (gl_FUNC_STRERROR): Test REPLACE_STRERROR.
18166         (gl_FUNC_STRERROR_SEPARATE): If errno.h is replaced, always replace
18167         strerror.
18168         (gl_PREREQ_STRERROR): Test whether winsock2.h exists.
18169         * modules/strerror (Depends-on): Add errno.
18170         * doc/posix-functions/strerror.texi: Document the change.
18171         * tests/test-strerror.c (main): Check also the string for ETIMEDOUT
18172         and EOVERFLOW.
18173
18174 2008-09-13  Bruno Haible  <bruno@clisp.org>
18175
18176         * modules/EOVERFLOW: Remove file.
18177         * m4/eoverflow.m4: Remove file.
18178         * modules/EOVERFLOW-tests: Remove file.
18179         * tests/test-EOVERFLOW.c: Remove file.
18180         * modules/fprintf-posix (Depends-on): Replace EOVERFLOW with errno.
18181         * modules/ftell (Depends-on): Likewise.
18182         * modules/getdelim (Depends-on): Likewise.
18183         * modules/getugroups (Depends-on): Likewise.
18184         * modules/poll (Depends-on): Likewise.
18185         * modules/snprintf (Depends-on): Likewise.
18186         * modules/sprintf-posix (Depends-on): Likewise.
18187         * modules/vasnprintf (Depends-on): Likewise.
18188         * modules/vasprintf (Depends-on): Likewise.
18189         * modules/vfprintf-posix (Depends-on): Likewise.
18190         * modules/vsnprintf (Depends-on): Likewise.
18191         * modules/vsprintf-posix (Depends-on): Likewise.
18192         * modules/xvasprintf (Depends-on): Likewise.
18193         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
18194         * modules/unistdio/u8-vasprintf (Depends-on): Likewise.
18195         * modules/unistdio/u8-vsnprintf (Depends-on): Likewise.
18196         * modules/unistdio/u8-vsprintf (Depends-on): Likewise.
18197         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
18198         * modules/unistdio/u8-u8-vasprintf (Depends-on): Likewise.
18199         * modules/unistdio/u8-u8-vsnprintf (Depends-on): Likewise.
18200         * modules/unistdio/u8-u8-vsprintf (Depends-on): Likewise.
18201         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
18202         * modules/unistdio/u16-u16-vasprintf (Depends-on): Likewise.
18203         * modules/unistdio/u16-u16-vsnprintf (Depends-on): Likewise.
18204         * modules/unistdio/u16-u16-vsprintf (Depends-on): Likewise.
18205         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
18206         * modules/unistdio/u16-vasprintf (Depends-on): Likewise.
18207         * modules/unistdio/u16-vsnprintf (Depends-on): Likewise.
18208         * modules/unistdio/u16-vsprintf (Depends-on): Likewise.
18209         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
18210         * modules/unistdio/u32-vasprintf (Depends-on): Likewise.
18211         * modules/unistdio/u32-vsnprintf (Depends-on): Likewise.
18212         * modules/unistdio/u32-vsprintf (Depends-on): Likewise.
18213         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
18214         * modules/unistdio/u32-u32-vasprintf (Depends-on): Likewise.
18215         * modules/unistdio/u32-u32-vsnprintf (Depends-on): Likewise.
18216         * modules/unistdio/u32-u32-vsprintf (Depends-on): Likewise.
18217         * modules/unistdio/ulc-fprintf (Depends-on): Likewise.
18218         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
18219         * modules/unistdio/ulc-vasprintf (Depends-on): Likewise.
18220         * modules/unistdio/ulc-vfprintf (Depends-on): Likewise.
18221         * modules/unistdio/ulc-vsnprintf (Depends-on): Likewise.
18222         * modules/unistdio/ulc-vsprintf (Depends-on): Likewise.
18223         * MODULES.html.sh: Remove EOVERFLOW.
18224         * NEWS: Mention the change.
18225
18226 2008-09-13  Bruno Haible  <bruno@clisp.org>
18227
18228         * modules/errno-tests: New file.
18229         * tests/test-errno.c: New file, incorporating tests/test-EOVERFLOW.c.
18230
18231         * lib/errno.in.h: New file.
18232         * m4/errno_h.m4: New file, borrowing from m4/eoverflow.m4.
18233         * modules/errno: New file.
18234         * doc/posix-headers/errno.texi: Update documentation.
18235         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add errno.
18236
18237 2008-09-13  Bruno Haible  <bruno@clisp.org>
18238
18239         * tests/test-poll.c: Use #if for native Windows, rather than testing
18240         __MSVCRT__.
18241
18242 2008-09-13  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
18243             Bruno Haible  <bruno@clisp.org>
18244
18245         * lib/glob.c: Don't include <pwd.h> on native Windows.
18246         (WINDOWS32): New macro.
18247         (glob) [WINDOW32]: Provide a reasonable replacement for getenv("HOME").
18248
18249 2008-09-13  Bruno Haible  <bruno@clisp.org>
18250
18251         * lib/glthread/cond.h [USE_SOLARIS_THREADS]
18252         (ETIMEDOUT): Remove macro.
18253         (glthread_cond_timedwait_multithreaded): New declaration.
18254         (glthread_cond_timedwait): Use it.
18255         * lib/glthread/cond.c [USE_SOLARIS_THREADS]
18256         (glthread_cond_timedwait_multithreaded): New function.
18257
18258 2008-09-12  Paolo Bonzini  <bonzini@gnu.org>
18259
18260         * modules/poll-tests: Do not check for io.h.
18261         * tests/test-poll.c: Check for __MSVCRT__ instead.
18262
18263 2008-09-12  Paolo Bonzini  <bonzini@gnu.org>
18264
18265         * lib/sys_socket.in.h (EINPROGRESS): Define for Winsock case.
18266         * modules/poll-tests: Add inet_pton, stdbool, sockets.
18267         * tests/test-poll.c: Use them.  Use _pipe on Windows.
18268
18269 2008-09-12  Paolo Bonzini  <bonzini@gnu.org>
18270
18271         * modules/poll-tests: New.
18272         * tests/test-poll.c: New.
18273
18274 2008-09-12  Eric Blake  <ebb9@byu.net>
18275
18276         frexp: test for NetBSD failure on -0.0
18277         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Enhance test, since some, but
18278         not all, bugs from NetBSD 3.0 have been fixed.
18279         * doc/posix-functions/frexp.texi (frexp): Document bug.
18280         Reported by Thomas Klausner.
18281
18282         signbit: work around bug of HP-UX 10.20 cc with -0.0 literal
18283         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Rewrite test to avoid
18284         literal -0.0.
18285         Reported by Jonathan C. Patschke <jp@centtech.com>.
18286
18287 2008-09-11  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
18288
18289         * lib/glthread/cond.h: Use dummy implementation also if
18290         USE_WIN32_THREADS.
18291
18292 2008-09-11  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
18293
18294         * modules/fnmatch-posix (License): Change to LGPLv2+.
18295         * modules/fnmatch-gnu (License): Likewise.
18296
18297 2008-09-11  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
18298
18299         * lib/poll.c (poll): Fix polling unconnected server sockets on WIN32.
18300
18301 2008-09-11  Jim Meyering  <meyering@redhat.com>
18302
18303         * users.txt: Add gtk-vnc.
18304
18305 2008-09-08  Simon Josefsson  <simon@josefsson.org>
18306
18307         * tests/test-bitrotate.c: Test 8/16-bit rotates with 0 and maximum
18308         rotate amounts.
18309
18310         * lib/bitrotate.h: Doc fix, mention that N can be wider than minimally
18311         required for 16-bit and 8-bit rotates.
18312         * lib/bitrotate.h (rotl64, rotr64, rotl32, rotl32, rotl16, rotr16,
18313         rotl8, rotr8): Use UINT64_MAX, UINT32_MAX, UINT16_MAX, and
18314         UINT8_MAX instead of hard-coded constants.
18315         Suggested by Paul Eggert.
18316
18317 2008-09-07  Bruno Haible  <bruno@clisp.org>
18318
18319         * tests/test-striconveh.c (main): Check behaviour when converting from
18320         UTF-7.
18321
18322         Make striconveh work better with stateful encodings.
18323         * lib/striconveh.c (iconv_carefully, iconv_carefully_1): Don't assume
18324         that iconv does not increment the inptr when returning -1/EINVAL.
18325
18326 2008-09-07  Bruno Haible  <bruno@clisp.org>
18327
18328         * build-aux/config.rpath: Update according to libtool-2.2.6.
18329         * build-aux/config.libpath: Likewise.
18330
18331 2008-09-06  Bruno Haible  <bruno@clisp.org>
18332
18333         * lib/freadahead.c (freadahead): Add conditional for SLOW_BUT_NO_HACKS.
18334         * lib/freadptr.c (freadptr): Likewise.
18335         * lib/freadseek.c (freadptrinc): Likewise.
18336         Reported by Simon Josefsson.
18337
18338 2008-09-06  Bruno Haible  <bruno@clisp.org>
18339
18340         * modules/freadptr (License): Change to LGPLv2+.
18341         * modules/freadseek (License): Likewise.
18342         Suggested by Eric Blake.
18343
18344         * modules/memchr2 (License): Change to LGPLv2+.
18345         Approved by Eric Blake.
18346
18347 2008-09-04  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
18348             Bruno Haible  <bruno@clisp.org>
18349
18350         Make gnulib-tool work with native 'sed' on AIX.
18351         * gnulib-tool (sed_noop): New variable.
18352         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am, func_import,
18353         func_add_or_update, func_create_testdir): Use it to initialize sed
18354         script variables.
18355         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
18356
18357 2008-09-04  Albert Chin  <bug-gnulib@mlists.thewrittenword.com>
18358             Bruno Haible  <bruno@clisp.org>
18359
18360         * m4/include_next.m4 (gl_INCLUDE_NEXT): Add check whether #include_next
18361         also works after #include directives.
18362
18363 2008-09-04  OndÅ™ej Vašík  <ovasik@redhat.com>
18364
18365         getdate.y: reject an out-of-range timezone value
18366         * lib/getdate.y (time_zone_hhmm): Reject any TZ offset that is outside
18367         the range [-24...+24].  When specified with only one or two digits,
18368         * tests/test-getdate.c: Tests for the fix.
18369         * doc/getdate.texi: Document this change.
18370
18371 2008-09-03  Bruno Haible  <bruno@clisp.org>
18372
18373         * doc/glibc-functions/strverscmp.texi: Mention the strverscmp module.
18374
18375 2008-09-02  Simon Josefsson  <simon@josefsson.org>
18376
18377         * lib/bitrotate.h (rotl64, rotr64): Add.  Suggested by Bruce Korb
18378         <bruce.korb@gmail.com> with ideas from Ben Pfaff
18379         <blp@cs.stanford.edu>, Bruno Haible <bruno@clisp.org> and Eric
18380         Blake <ebb9@byu.net>.
18381
18382         * tests/test-bitrotate.c: Add more test vectors.
18383
18384 2008-09-02  Eric Blake  <ebb9@byu.net>
18385
18386         vasnprintf-posix: handle large precision via %.*d
18387         * lib/vasnprintf.c (VASNPRINTF): Don't pass precision to snprintf
18388         when handling it ourselves.
18389         * tests/test-vasnprintf-posix.c (test_function): Add test.
18390         * tests/test-snprintf-posix.h (test_function): Likewise.
18391         * tests/test-sprintf-posix.h (test_function): Likewise.
18392         * tests/test-vasprintf-posix.c (test_function): Likewise.
18393         Reported by Alain Guibert.
18394
18395 2008-09-01  Eric Blake  <ebb9@byu.net>
18396
18397         c-stack: make configure-time check more robust
18398         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Check for
18399         successful sigaction call.
18400         Reported by Tom G. Christensen.
18401
18402 2008-09-01  Bruno Haible  <bruno@clisp.org>
18403
18404         New module 'findprog-lgpl'.
18405         * modules/findprog-lgpl: New file.
18406         * lib/findprog-lgpl.c: New file.
18407         * lib/findprog.c: Compile nothing in findprog.c if findprog-lgpl.c is
18408         also compiled. Consider the possibly defined symbol IN_FINDPROG_LGPL
18409         to decide whether to use strdup or xstrdup, concatenated_filename or
18410         xconcatenated_filename.
18411
18412 2008-09-01  Bruno Haible  <bruno@clisp.org>
18413
18414         Split module 'concat-filename' into 'concat-filename' (LGPL) and
18415         'xconcat-filename' (GPL).
18416         * modules/concat-filename (Depends-on): Add malloc-posix, remove xalloc.
18417         (License): Change to LGPLv2+.
18418         * modules/xconcat-filename: New file.
18419         * lib/concat-filename.h (concatenated_filename): Change specification.
18420         (xconcatenated_filename): New declaration.
18421         * lib/concat-filename.c: Include errno.h, stdlib.h, not xalloc.h.
18422         (concatenated_filename): Use malloc instead of xalloc. Handle out-of-
18423         memory situations.
18424         * lib/xconcat-filename.c: New file.
18425         * NEWS: Mention the change.
18426         * lib/findprog.c: Include concat-filename.h, not filename.h.
18427         (find_in_path): Use xconcatenated_filename instead of
18428         concatenated_filename.
18429         * lib/javacomp.c: Include concat-filename.h, not filename.h.
18430         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
18431         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
18432         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
18433         is_oldgcj_14_13_usable, is_javac_usable): Use xconcatenated_filename
18434         instead of concatenated_filename.
18435         * lib/javaexec.c: Include concat-filename.h, not filename.h.
18436         (execute_java_class): Use xconcatenated_filename instead of
18437         concatenated_filename.
18438         * modules/findprog (Depends-on): Add xconcat-filename, remove filename.
18439         * modules/javacomp (Depends-on): Likewise.
18440         * modules/javaexec (Depends-on): Likewise.
18441
18442 2008-09-01  Bruno Haible  <bruno@clisp.org>
18443
18444         Split module 'filename' into 'filename' and 'concat-filename'.
18445         * modules/filename: Keep only lib/filename.h.
18446         (License): Change to LGPLv2+.
18447         * modules/concat-filename: New file, extracted from modules/filename.
18448         * lib/filename.h (concatenated_filename): Remove declaration.
18449         * lib/concat-filename.h: New file, extracted from lib/filename.h.
18450         * lib/concat-filename.c: Include concat-filename.h.
18451         * NEWS: Mention the change.
18452
18453 2008-09-01  Simon Josefsson  <simon@josefsson.org>
18454
18455         * lib/bitrotate.h (rotl8, rotr8): Add.
18456
18457         * modules/bitrotate (configure.ac): Need
18458         AC_REQUIRE([AC_C_INLINE]).
18459         (Description): Mention stdint.h.  Reported by Bruno Haible
18460         <bruno@clisp.org>.
18461
18462         * lib/bitrotate.h (rotr16, rotl16): Fix mask value.  Reported by
18463         Paolo Bonzini <bonzini@gnu.org>.
18464
18465 2008-08-31  Bruno Haible  <bruno@clisp.org>
18466
18467         Assume Solaris specific bi-arch conventions on Solaris systems.
18468         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): On Solaris in 64-bit
18469         mode, set acl_libdirstem to lib/64. Also set acl_libdirstem2.
18470         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): If acl_libdirstem does not
18471         work, try acl_libdirstem2 as fallback. Otherwise treat acl_libdirstem2
18472         like acl_libdirstem.
18473         (AC_LIB_LINKFLAGS_FROM_LIBS): Treat acl_libdirstem2 like
18474         acl_libdirstem.
18475         * NEWS: Mention the change.
18476         Reported by Ben Taylor <bentaylor.solx86@gmail.com>.
18477
18478 2008-08-31  Jim Meyering  <meyering@redhat.com>
18479
18480         * lib/strftime.h: Add comments describing the two added arguments.
18481
18482         remove duplicate #include directives
18483         * lib/chdir-long.c [TEST_CHDIR]: Remove duplicate #include <stdio.h>.
18484         * lib/putenv.c: Remove duplicate #include <stdlib.h>.
18485
18486 2008-08-31  Bruno Haible  <bruno@clisp.org>
18487
18488         New module 'sigpipe-die'.
18489         * modules/sigpipe-die: New file.
18490         * lib/sigpipe-die.h: New file.
18491         * lib/sigpipe-die.c: New file.
18492         * MODULES.html.sh (Signal handling): Add sigpipe-die.
18493
18494 2008-08-31  Bruno Haible  <bruno@clisp.org>
18495
18496         Don't override previously installed signal handlers.
18497         * lib/fatal-signal.c (saved_sigactions): New variable.
18498         (uninstall_handlers): Reset the signal to the saved handler, not
18499         to SIG_DFL (except when ignored).
18500         (install_handlers): Save the previous handlers.
18501
18502 2008-08-30  Bruno Haible  <bruno@clisp.org>
18503
18504         * gnulib-tool (func_reset_sigpipe): New function.
18505         (func_get_automake_snippet, func_modules_transitive_closure,
18506         func_import): Invoke it before a join command that reads from stdin,
18507         to avoid "echo: write error: Broken pipe" error messages on stderr.
18508         Reported by Sam Steingold <sds@gnu.org>.
18509
18510 2008-08-30  Bruno Haible  <bruno@clisp.org>
18511
18512         * m4/fopen.m4 (gl_FUNC_FOPEN): Test against bug with trailing slash.
18513         Code copied from m4/open.m4.
18514         * lib/fopen.c (rpl_fopen): Return NULL if the mode specifies write
18515         access and the filename ends in a slash. Code copied from lib/open.c.
18516         * doc/posix-functions/fopen.texi: Document bug with trailing slash.
18517         * tests/test-fopen.c (main): Check against bug with trailing slash.
18518
18519 2008-08-29  Bruno Haible  <bruno@clisp.org>
18520
18521         Avoid some "gcc -pedantic" warnings.
18522         * m4/include_next.m4 (gl_INCLUDE_NEXT): Set also PRAGMA_SYSTEM_HEADER.
18523         * lib/arpa_inet.in.h: Use PRAGMA_SYSTEM_HEADER.
18524         * lib/dirent.in.h: Likewise.
18525         * lib/fcntl.in.h: Likewise.
18526         * lib/float.in.h: Likewise.
18527         * lib/iconv.in.h: Likewise.
18528         * lib/inttypes.in.h: Likewise.
18529         * lib/locale.in.h: Likewise.
18530         * lib/math.in.h: Likewise.
18531         * lib/netinet_in.in.h: Likewise.
18532         * lib/search.in.h: Likewise.
18533         * lib/signal.in.h: Likewise.
18534         * lib/stdarg.in.h: Likewise.
18535         * lib/stdint.in.h: Likewise.
18536         * lib/stdio.in.h: Likewise.
18537         * lib/stdlib.in.h: Likewise.
18538         * lib/string.in.h: Likewise.
18539         * lib/strings.in.h: Likewise.
18540         * lib/sys_select.in.h: Likewise.
18541         * lib/sys_socket.in.h: Likewise.
18542         * lib/sys_stat.in.h: Likewise.
18543         * lib/sys_time.in.h: Likewise.
18544         * lib/sysexits.in.h: Likewise.
18545         * lib/time.in.h: Likewise.
18546         * lib/unistd.in.h: Likewise.
18547         * lib/wchar.in.h: Likewise.
18548         * lib/wctype.in.h: Likewise.
18549         * modules/arpa_inet (Makefile.am): Also substitute PRAGMA_SYSTEM_HEADER.
18550         * modules/fchdir (Makefile.am): Likewise.
18551         * modules/fcntl (Makefile.am): Likewise.
18552         * modules/float (Makefile.am): Likewise.
18553         * modules/iconv_open (Makefile.am): Likewise.
18554         * modules/inttypes (Makefile.am): Likewise.
18555         * modules/locale (Makefile.am): Likewise.
18556         * modules/math (Makefile.am): Likewise.
18557         * modules/netinet_in (Makefile.am): Likewise.
18558         * modules/search (Makefile.am): Likewise.
18559         * modules/signal (Makefile.am): Likewise.
18560         * modules/stdarg (Makefile.am): Likewise.
18561         * modules/stdint (Makefile.am): Likewise.
18562         * modules/stdio (Makefile.am): Likewise.
18563         * modules/stdlib (Makefile.am): Likewise.
18564         * modules/string (Makefile.am): Likewise.
18565         * modules/strings (Makefile.am): Likewise.
18566         * modules/sys_select (Makefile.am): Likewise.
18567         * modules/sys_socket (Makefile.am): Likewise.
18568         * modules/sys_stat (Makefile.am): Likewise.
18569         * modules/sys_time (Makefile.am): Likewise.
18570         * modules/sysexits (Makefile.am): Likewise.
18571         * modules/time (Makefile.am): Likewise.
18572         * modules/unistd (Makefile.am): Likewise.
18573         * modules/wchar (Makefile.am): Likewise.
18574         * modules/wctype (Makefile.am): Likewise.
18575         Reported by Reuben Thomas <rrt@sc3d.org>.
18576
18577 2008-08-29  Bruno Haible  <bruno@clisp.org>
18578
18579         * m4/include_next.m4 (gl_INCLUDE_NEXT): Don't define HAVE_INCLUDE_NEXT
18580         any more.
18581
18582 2008-08-29  Simon Josefsson  <simon@josefsson.org>
18583
18584         * MODULES.html.sh (Misc): Add bitrotate.
18585
18586         * modules/bitrotate: New file.
18587
18588         * lib/bitrotate.h: New file.
18589
18590         * modules/bitrotate-tests: New file.
18591
18592         * tests/test-bitrotate.c: New file.
18593
18594         * modules/crypto/gc-arctwo, modules/crypto/arctwo: Add dependency
18595         on the bitrotate module.
18596
18597         * lib/arctwo.c: Use new bitrotate module.
18598
18599 2008-08-29  Jim Meyering  <meyering@redhat.com>
18600
18601         bootstrap: merge changes from coreutils
18602         * build-aux/bootstrap (cp_mark_as_generated): Preserve perms
18603         of copied files.  Remove a kludge, now that this is fixed.
18604         * build-aux/bootstrap: Fix unportable expr usage. (by Ralf Wildenhues)
18605         * build-aux/bootstrap: Remove $bt and $bt2 also when not using gettext.
18606         * build-aux/bootstrap: Remove coreutils-specific SUBDIRS-related code.
18607
18608 2008-08-29  Bruno Haible  <bruno@clisp.org>
18609
18610         * MODULES.html.sh: Remove --cvs-urls option.
18611
18612 2008-08-28  Jose E. Marchesi  <jemarch@gnu.org>  (tiny change)
18613
18614         maint.mk: adjust to file name change
18615         * top/maint.mk: s/Makefile.cfg/cfg.mk/.
18616
18617 2008-08-28  Jim Meyering  <meyering@redhat.com>
18618
18619         * modules/getndelim2 (License): Relicense to LGPLv2+.
18620         Approved by Richard Stallman for the version of 1995, and by
18621         Paul Eggert, Bruno Haible, Eric Blake for their contributions.
18622
18623 2008-08-27  Paolo Bonzini  <bonzini@gnu.org>
18624
18625         * lib/getdelim.c (flockfile, funlockfile): Make all of them
18626         dummy if one is not available.  Do not touch them if
18627         USE_UNLOCKED_IO, instead letting unlocked-io.h do that.
18628         (getc_maybe_unlocked): New.
18629         * m4/getdelim.m4 (gl_PREREQ_GETDELIM): Check for getc_unlocked.
18630
18631 2008-08-26  Eric Blake  <ebb9@byu.net>
18632
18633         doc/INSTALL: resync from autoconf
18634         * doc/Makefile (INSTALL, INSTALL.ISO, INSTALL.UTF-8): Simplify.
18635         (INSTALL_PRELUDE): Delete; this is done more efficiently by
18636         moving...
18637         * install.texi [!autoconf]: ...here.  Resync from autoconf.
18638         * INSTALL: Regenerate.
18639         * INSTALL.ISO: New file.
18640         * INSTALL.UTF-8: Likewise.
18641
18642 2008-08-26  Jim Meyering  <meyering@redhat.com>
18643
18644         GNUmakefile: cfg.mk definitions override default autoreconf-rerun policy
18645         * top/GNUmakefile (_is-dist-target, _is-install-target): Make
18646         these definitions conditional, so that they may be overridden, too.
18647
18648 2008-08-26  Bruno Haible  <bruno@clisp.org>
18649
18650         Generate INSTALL file variants with prettier quotes.
18651         * doc/Makefile (INSTALL_PRELUDE): New macro.
18652         (INSTALL): Use it.
18653         (INSTALL.ISO, INSTALL.UTF-8): New rules.
18654
18655 2008-08-26  Bruno Haible  <bruno@clisp.org>
18656
18657         Run makeinfo in an English locale.
18658         * doc/Makefile (MAKEINFO): New variable.
18659
18660 2008-08-26  Bruno Haible  <bruno@clisp.org>
18661
18662         * doc/Makefile (INSTALL): Use --no-validate instead of --no-warn.
18663         Suggested by Eric Blake.
18664
18665 2008-08-25  Bruno Haible  <bruno@clisp.org>
18666
18667         * doc/Makefile (INSTALL): Generate with @firstparagraphindent set.
18668
18669 2008-08-25  Eric Blake  <ebb9@byu.net>
18670
18671         c-stack: test that stack overflow can be caught
18672         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Also check
18673         that platform allows handling stack overflow; at least OS/2 EMX
18674         has sigaltstack, but crashes before transferring control to
18675         handler on stack overflow.
18676         * lib/c-stack.c [HAVE_SIGALTSTACK]: Adjust conditions to also
18677         check for HAVE_STACK_OVERFLOW_HANDLING.
18678         Reported by Elbert Pol.
18679
18680 2008-08-25  Bruno Haible  <bruno@clisp.org>
18681
18682         * doc/posix-functions/strftime.texi: Fix description of strftime
18683         module.
18684
18685 2008-08-24  Bruno Haible  <bruno@clisp.org>
18686
18687         * tests/uniwidth/test-uc_width2.c: New file.
18688         * tests/uniwidth/test-uc_width2.sh: New file.
18689         * modules/uniwidth/width-tests (Files): Add the new files.
18690         (TESTS): Add uniwidth/test-uc_width2.sh.
18691         (TESTS_ENVIRONMENT): New variable.
18692         (check_PROGRAMS): Add test-uc_width2.
18693         (test_uc_width2_SOURCES): New variable.
18694
18695         Fix uc_width(0x00AB) bug, introduced on 2007-07-08.
18696         * lib/uniwidth/width.c (nonspacing_table_data): Set bit for 0x00AD,
18697         not 0x00AB.
18698         Reported by Alexander V. Lukyanov <lav@netis.ru>.
18699
18700 2008-08-22  Eric Blake  <ebb9@byu.net>
18701
18702         test-lock, test-tls: mention why a test is skipped
18703         * tests/test-lock.c (main) [!USE_*_THREADS]: Print why test is
18704         skipped.
18705         * tests/test-tls.c (main) [!USE_*_THREADS]: Likewise.
18706
18707         count-one-bits: relax license
18708         * modules/count-one-bits (License): Relicense to LGPLv2+.
18709         Suggested by Ludovic Courtès, approved by Ben Pfaff.
18710
18711 2008-08-22  Andreas Schwab  <schwab@suse.de>
18712
18713         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX):
18714         Remove spurious space in assignment.
18715
18716 2008-08-21  Simon Josefsson  <simon@josefsson.org>
18717
18718         * m4/autobuild.m4: Use TZ=UTC0 instead of TZ=UTC.  Reported by
18719         Paul Eggert <eggert@CS.UCLA.EDU>.
18720
18721 2008-08-20  Paolo Bonzini  <bonzini@gnu.org>
18722
18723         * modules/gettext: Add m4/threadlib.m4.
18724
18725 2008-08-19  Eric Blake  <ebb9@byu.net>
18726
18727         test-c-stack: fix compilation failure on FreeBSD 5.0
18728         * tests/test-c-stack.c [HAVE_SETRLIMIT]: Include prerequisite
18729         headers before <sys/resource.h>.
18730         * doc/posix-headers/sys_resource.texi (sys/resource.h): Document
18731         the bug.
18732         Reported by Nelson H. F. Beebe.
18733
18734         strverscmp: migrate from "strverscmp.h" to <string.h>
18735         * modules/string (Makefile.am): Add new hooks.
18736         * modules/strverscmp (Files): Remove strverscmp.h.
18737         (Depends-on): Add string.
18738         (configure.ac): Add indicator.
18739         (Include): Mention new header.
18740         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Provide new
18741         defaults.
18742         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP): Inform string module of
18743         results.
18744         * lib/strverscmp.h: Delete.
18745         * lib/string.in.h (strverscmp): Provide declaration, when needed.
18746         * tests/test-strverscmp.c (includes): Adjust client.
18747         * lib/check-version.c (includes): Likewise.
18748         * NEWS: Document the change.
18749
18750         strverscmp: add unit test
18751         * modules/strverscmp-tests: New file.
18752         * tests/test-strverscmp.c: Likewise.
18753
18754 2008-08-19  Simon Josefsson  <simon@josefsson.org>
18755
18756         * lib/gc-gnulib.c: Indentation cleanup.  Add some comments
18757         regarding Windows crypto stuff, from Mono.
18758
18759 2008-08-19  Adam Strzelecki <ono@java.pl>  (tiny change)
18760
18761         * lib/gc-gnulib.c: Use CRYPT_VERIFY_CONTEXT.  Try to use Intel CSP
18762         if present, for intel RND.  Return error on failures.
18763
18764 2008-08-18  Ben Pfaff  <blp@gnu.org>
18765
18766         gitlog-to-changelog: give better diagnostic for failed pipe-open
18767         * build-aux/gitlog-to-changelog: Improve error message: suggest
18768         that the version of Git may be too old.
18769
18770 2008-08-18  Simon Josefsson  <simon@josefsson.org>
18771
18772         * m4/autobuild.m4: Use TZ=UTC to avoid time zone complexity.  Use
18773         ISO 8601 format.  Suggested by Greg Troxel <gdt@ir.bbn.com>.
18774
18775 2008-08-18  Bruno Haible  <bruno@clisp.org>
18776
18777         * lib/glthread/thread.h [USE_SOLARIS_THREADS]: Use thread_in_use(), not
18778         pthread_in_use().
18779
18780 2008-08-18  Bruno Haible  <bruno@clisp.org>
18781
18782         * lib/glthread/threadlib.c: Include <pthread.h>.
18783
18784 2008-08-18  Bruno Haible  <bruno@clisp.org>
18785
18786         * lib/glthread/lock.h [USE_SOLARIS_THREADS]: Fix
18787         glthread_recursive_lock_* macros.
18788         * lib/glthread/lock.c (glthread_recursive_lock_destroy_multithreaded):
18789         Fix syntax error.
18790
18791 2008-08-18  Bruno Haible  <bruno@clisp.org>
18792
18793         * lib/glthread/thread.c: Avoid forcing a context switch right after
18794         thread creation.
18795
18796 2008-08-17  Bruno Haible  <bruno@clisp.org>
18797
18798         * lib/glthread/thread.c: New file, based on code from tests/test-lock.c.
18799         * lib/glthread/thread.h: Provide Win32 specific implementation.
18800         * modules/thread (Files): Add lib/glthread/thread.c.
18801         (Depends-on): Add lock.
18802         (Makefile.am): Add glthread/thread.c to lib_SOURCES.
18803
18804 2008-08-17  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
18805
18806         New module 'yield'.
18807         * modules/yield: New file.
18808         * lib/glthread/yield.h: New file.
18809         * m4/yield.m4: New file.
18810         * MODULES.html.sh (Multithreading): Add yield.
18811
18812 2008-08-17  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
18813
18814         New module 'thread'.
18815         * modules/thread: New file.
18816         * lib/glthread/thread.h: New file.
18817         * m4/thread.m4: New file.
18818         * MODULES.html.sh (Multithreading): Add thread.
18819
18820 2008-08-17  Bruno Haible  <bruno@clisp.org>
18821
18822         * lib/glthread/lock.h: Include <stdlib.h> always.
18823         * lib/glthread/tls.h: Likewise.
18824         * lib/glthread/cond.h: Likewise.
18825
18826 2008-08-17  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
18827
18828         New module 'cond'.
18829         * modules/cond: New file.
18830         * lib/glthread/cond.h: New file.
18831         * lib/glthread/cond.c: New file.
18832         * m4/cond.m4: New file.
18833         * MODULES.html.sh (Multithreading): Add cond.
18834
18835 2008-08-16  Eric Blake  <ebb9@byu.net>
18836
18837         c-stack: fix regression on Irix 5.3 from 2008-06-21
18838         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Move check for
18839         sa_sigaction...
18840         * m4/sigaction.m4 (gl_PREREQ_SIG_HANDLER_H): ...here.
18841         (gl_PREREQ_SIGACTION): Depend on sig-handler.h prereq's.
18842         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Set the default.
18843         * modules/signal (Makefile.am): Use the value.
18844         * lib/signal.in.h (sa_sigaction) [HAVE_SIGACTION
18845         && !HAVE_STRUCT_SIGACTION_SA_SIGACTION]: Define.
18846         * doc/posix-headers/signal.texi (signal.h): Document this
18847         portability issue.
18848         * doc/posix-functions/sigaction.texi (sigaction): Likewise.
18849         Reported by Tom G. Christensen.
18850
18851 2008-08-17  Bruno Haible  <bruno@clisp.org>
18852
18853         New module 'threadlib'.
18854         * modules/threadlib: New file.
18855         * lib/glthread/threadlib.c: New file, extracted from
18856         lib/glthread/lock.c.
18857         * lib/glthread/lock.c (dummy_thread_func, glthread_in_use): Remove
18858         functions.
18859         * m4/threadlib.m4: New file, from m4/lock.m4, renaming gl_LOCK to
18860         gl_THREADLIB and gl_LOCK_EARLY to gl_THREADLIB_EARLY.
18861         * m4/lock.m4 (gl_LOCK_EARLY, gl_LOCK_EARLY_BODY, gl_LOCK_BODY): Remove
18862         macros.
18863         (gl_LOCK): Just require gl_THREADLIB and perform checks for lock.h.
18864         (gl_DISABLE_THREADS): Remove macro.
18865         * modules/lock (Files): Remove build-aux/config.rpath.
18866         (Depends-on): Remove havelib. Add threadlib.
18867         (configure.ac-early): Remove section.
18868         * m4/tls.m4 (gl_TLS): Require gl_THREADLIB instead of gl_LOCK.
18869         * modules/tls (Depends-on): Remove lock. Add threadlib.
18870         (Link): New section, copied from threadlib.
18871         * MODULES.html.sh (Multithreading): Add threadlib.
18872
18873 2008-08-14  Bruno Haible  <bruno@clisp.org>
18874
18875         * lib/glthread/lock.h (glthread_lock_lock, glthread_lock_unlock,
18876         glthread_lock_destroy, glthread_rwlock_rdlock, glthread_rwlock_wrlock,
18877         glthread_rwlock_unlock, glthread_rwlock_destroy,
18878         glthread_recursive_lock_lock, glthread_recursive_lock_unlock,
18879         glthread_recursive_lock_destroy): Define as macros always.
18880         * lib/glthread/lock.c (glthread_lock_lock_func): Renamed from
18881         glthread_lock_lock.
18882         (glthread_lock_unlock_func): Renamed from glthread_lock_unlock.
18883         (glthread_lock_destroy_func): Renamed from glthread_lock_destroy.
18884         (glthread_rwlock_rdlock_func): Renamed from glthread_rwlock_rdlock.
18885         (glthread_rwlock_wrlock_func): Renamed from glthread_rwlock_wrlock.
18886         (glthread_rwlock_unlock_func): Renamed from glthread_rwlock_unlock.
18887         (glthread_rwlock_destroy_func): Renamed from glthread_rwlock_destroy.
18888         (glthread_recursive_lock_lock_func): Renamed from
18889         glthread_recursive_lock_lock.
18890         (glthread_recursive_lock_unlock_func): Renamed from
18891         glthread_recursive_lock_unlock.
18892         (glthread_recursive_lock_destroy_func): Renamed from
18893         glthread_recursive_lock_destroy.
18894
18895 2008-08-14  Bruno Haible  <bruno@clisp.org>
18896
18897         * lib/glthread/lock.h: Renamed from lib/lock.h.
18898         * lib/glthread/lock.c: Renamed from lib/lock.c. Update includes.
18899         * lib/glthread/tls.h: Renamed from lib/tls.h.
18900         * lib/glthread/tls.c: Renamed from lib/tls.c. Update includes.
18901         * lib/fstrcmp.c: Update includes.
18902         * lib/strsignal.c: Update includes.
18903         * modules/lock (Files, Makefile.am): Update.
18904         (Include): Change to "glthread/lock.h".
18905         * modules/tls (Files, Makefile.am): Update.
18906         (Include): Change to "glthread/tls.h".
18907         * tests/test-lock.c: Update includes.
18908         * tests/test-tls.c: Update includes.
18909         * NEWS: Mention the renamed header files.
18910
18911 2008-08-11  Jim Meyering  <meyering@redhat.com>
18912
18913         * lib/fts_.h: Fix grammar (insert a missing "is") in a comment.
18914
18915 2008-08-11  Eric Blake  <ebb9@byu.net>
18916
18917         test-c-stack: avoid C99-ism
18918         * tests/test-c-stack.c (main): Fix whitespace, move declaration
18919         before statement.
18920         Reported by Alain Guibert.
18921
18922 2008-08-10  Jim Meyering  <meyering@redhat.com>
18923
18924         ensure that return value of uinttostr et al are not ignored
18925         * lib/inttostr.h (__GNUC_PREREQ): Define.
18926         (__attribute_warn_unused_result__): Define.
18927         (offtostr, imaxtostr, umaxtostr, uinttostr): Apply the attribute.
18928
18929 2008-08-07  Paolo Bonzini  <bonzini@gnu.org>
18930
18931         * lib/lock.c (glthread_recursive_lock_init_multithreaded)
18932         [!PTHREAD_RECURSIVE_MUTEX_INITIALIZER]: Fix typo.
18933
18934 2008-08-07  Jim Meyering  <meyering@redhat.com>
18935
18936         * m4/inet_pton.m4: Fix typo in comment: s/inet_ntop/inet_pton/.
18937
18938         * modules/mkstemp (License): Relicense under LGPLv2+.
18939         * modules/tempname (License): Likewise.
18940
18941 2008-08-06  Bruno Haible  <bruno@clisp.org>
18942
18943         * lib/poll.c (poll): Further micro-optimization.
18944
18945 2008-08-06  Jim Meyering  <meyering@redhat.com>
18946
18947         inet_pton.c: use locale-independent tolower
18948         * lib/inet_pton.c: Include <c-ctype.h> rather than <ctype.h>.
18949         (inet_pton6): Use c_tolower rather than tolower.
18950         * modules/inet_pton (Depends-on): Add c-ctype.
18951
18952 2008-08-06  Paolo Bonzini  <bonzini@gnu.org>
18953
18954         * lib/poll.c (poll): Avoid division when timeout is 0, cache
18955         _SC_OPEN_MAX, avoid repeated access to errno.  Check for nfd < 0.
18956
18957 2008-08-06  Jim Meyering  <meyering@redhat.com>
18958
18959         * modules/inet_pton (License): Relicense under LGPLv2+.
18960
18961 2008-08-03  Bruno Haible  <bruno@clisp.org>
18962
18963         Additional non-aborting API for lock and tls.
18964         * lib/lock.h: Include <errno.h>.
18965         (glthread_lock_init): New macro/function.
18966         (gl_lock_init): Define as wrapper around glthread_lock_init.
18967         (glthread_lock_lock): New macro/function.
18968         (gl_lock_lock): Define as wrapper around glthread_lock_lock.
18969         (glthread_lock_unlock): New macro/function.
18970         (gl_lock_unlock): Define as wrapper around glthread_lock_unlock.
18971         (glthread_lock_destroy): New macro/function.
18972         (gl_lock_destroy): Define as wrapper around glthread_lock_destroy.
18973         (glthread_rwlock_init): New macro/function.
18974         (gl_rwlock_init): Define as wrapper around glthread_rwlock_init.
18975         (glthread_rwlock_rdlock): New macro/function.
18976         (gl_rwlock_rdlock): Define as wrapper around glthread_rwlock_rdlock.
18977         (glthread_rwlock_wrlock): New macro/function.
18978         (gl_rwlock_wrlock): Define as wrapper around glthread_rwlock_wrlock.
18979         (glthread_rwlock_unlock): New macro/function.
18980         (gl_rwlock_unlock): Define as wrapper around glthread_rwlock_unlock.
18981         (glthread_rwlock_destroy): New macro/function.
18982         (gl_rwlock_destroy): Define as wrapper around glthread_rwlock_destroy.
18983         (glthread_recursive_lock_init): New macro/function.
18984         (gl_recursive_lock_init): Define as wrapper around
18985         glthread_recursive_lock_init.
18986         (glthread_recursive_lock_lock): New macro/function.
18987         (gl_recursive_lock_lock): Define as wrapper around
18988         glthread_recursive_lock_lock.
18989         (glthread_recursive_lock_unlock): New macro/function.
18990         (gl_recursive_lock_unlock): Define as wrapper around
18991         glthread_recursive_lock_unlock.
18992         (glthread_recursive_lock_destroy): New macro/function.
18993         (gl_recursive_lock_destroy): Define as wrapper around
18994         glthread_recursive_lock_destroy.
18995         (glthread_once): New macro/function.
18996         (gl_once): Define as wrapper around glthread_once.
18997         Update function declarations.
18998         * lib/lock.c (glthread_rwlock_init_multithreaded): Renamed from
18999         glthread_rwlock_init. Return error code.
19000         (glthread_rwlock_rdlock_multithreaded): Renamed from
19001         glthread_rwlock_rdlock. Return error code.
19002         (glthread_rwlock_wrlock_multithreaded): Renamed from
19003         glthread_rwlock_wrlock. Return error code.
19004         (glthread_rwlock_unlock_multithreaded): Renamed from
19005         glthread_rwlock_unlock. Return error code.
19006         (glthread_rwlock_destroy_multithreaded): Renamed from
19007         glthread_rwlock_destroy. Return error code.
19008         (glthread_recursive_lock_init_multithreaded): Renamed from
19009         glthread_recursive_lock_init. Return error code.
19010         (glthread_recursive_lock_lock_multithreaded): Renamed from
19011         glthread_recursive_lock_lock. Return error code.
19012         (glthread_recursive_lock_unlock_multithreaded): Renamed from
19013         glthread_recursive_lock_unlock. Return error code.
19014         (glthread_recursive_lock_destroy_multithreaded): Renamed from
19015         glthread_recursive_lock_destroy. Return error code.
19016         (glthread_once_call): Make static.
19017         (glthread_once_multithreaded): Renamed from glthread_once.
19018         * lib/tls.h: Include <errno.h>.
19019         (glthread_tls_key_init): New macro/function.
19020         (gl_tls_key_init): Define as wrapper around glthread_tls_key_init.
19021         (glthread_tls_set): New macro/function.
19022         (gl_tls_set): Define as wrapper around glthread_tls_set.
19023         (glthread_tls_key_destroy): New macro/function.
19024         (gl_tls_key_destroy): Define as wrapper around glthread_tls_key_destroy.
19025         Update function declarations.
19026         * lib/tls.c (glthread_tls_get_multithreaded): Renamed from
19027         glthread_tls_get.
19028         Suggested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
19029
19030 2008-08-04  Eric Blake  <ebb9@byu.net>
19031
19032         gnumakefile: use space, not TAB, outside of targets
19033         * top/GNUmakefile (_dummy): Fix whitespace error in prior edit.
19034
19035 2008-08-02  Jim Meyering  <meyering@redhat.com>
19036
19037         getdate.y: avoid locale-dependent date parsing failure
19038         In Turkish locales, getdate would fail to recognize keywords
19039         containing a lowercase "i".  The solution is not to rely on
19040         locale-sensitive case-conversion.
19041         * lib/getdate.y: Include <c-ctype.h> rather than <ctype.h>.
19042         (lookup_word): Use c_toupper in place of toupper.
19043         (yylex, get_date): Use c_ prefixed variants of isspace and isalpha, too.
19044         Reported by Vefa Bicakci <bicave@superonline.com> in
19045         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/14184>.
19046         * modules/getdate (Depends-on): Add c-ctype.
19047
19048 2008-08-02  Bruno Haible  <bruno@clisp.org>
19049
19050         * gnulib-tool (func_import): When updating or creating a .gitignore
19051         file, prepend each added line with a slash, and ignore leading slashes
19052         from the existing lines.
19053         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
19054
19055 2008-08-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
19056
19057         Portability fix for GNU make 3.79.1.
19058         * top/GNUmakefile: Avoid 'else COND', which older GNU make
19059         versions do not understand.
19060
19061 2008-08-01  Bruno Haible  <bruno@clisp.org>
19062
19063         Work around bug of HP-UX 10.20 cc with -0.0 literal.
19064         * tests/test-isnanf.h (zero): New variable.
19065         (main): Avoid literal -0.0f.
19066         * tests/test-isnand.h (zero): New variable.
19067         (main): Avoid literal -0.0.
19068         * tests/test-isnanl.h (zero): New variable.
19069         (main): Avoid literal -0.0L.
19070         * tests/test-isnan.c (zerof, zerod, zerol): New variables.
19071         (test_float, test_double, test_long_double): Avoid literals -0.0f,
19072         -0.0, -0.0L.
19073         * tests/test-signbit.c (test_signbitf): Avoid literal -0.0f.
19074         (test_signbitd): Avoid literal -0.0.
19075         (test_signbitl): Avoid literal -0.0L.
19076         * tests/test-ceilf1.c (zero): New variable.
19077         (main): Avoid literal -0.0f.
19078         * tests/test-ceill.c (zero): New variable.
19079         (main): Avoid literal -0.0L.
19080         * tests/test-floorf1.c (zero): New variable.
19081         (main): Avoid literal -0.0f.
19082         * tests/test-floorl.c (zero): New variable.
19083         (main): Avoid literal -0.0L.
19084         * tests/test-roundf1.c (zero): New variable.
19085         (main): Avoid literal -0.0f.
19086         * tests/test-round1.c (zero): New variable.
19087         (main): Avoid literal -0.0.
19088         * tests/test-roundl.c (zero): New variable.
19089         (main): Avoid literal -0.0L.
19090         * tests/test-truncf1.c (zero): New variable.
19091         (main): Avoid literal -0.0f.
19092         * tests/test-trunc1.c (zero): New variable.
19093         (main): Avoid literal -0.0.
19094         * tests/test-truncl.c (zero): New variable.
19095         (main): Avoid literal -0.0L.
19096         * tests/test-frexp.c (zero): New variable.
19097         (main): Avoid literal -0.0.
19098         * tests/test-frexpl.c (zero): New variable.
19099         (main): Avoid literal -0.0L.
19100         * tests/test-ldexpl.c (zero): New variable.
19101         (main): Avoid literal -0.0L.
19102         * tests/test-snprintf-posix.h (have_minus_zero): Avoid literal -0.0.
19103         (zerod, zerol): New variables.
19104         (test_function): Avoid literals -0.0, -0.0L.
19105         * tests/test-sprintf-posix.h (have_minus_zero): Avoid literal -0.0.
19106         (zerod, zerol): New variables.
19107         (test_function): Avoid literals -0.0, -0.0L.
19108         * tests/test-vasnprintf-posix.c (have_minus_zero): Avoid literal -0.0.
19109         (zerod, zerol): New variables.
19110         (test_function): Avoid literals -0.0, -0.0L.
19111         * tests/test-vasprintf-posix.c (have_minus_zero): Avoid literal -0.0.
19112         (zerod, zerol): New variables.
19113         (test_function): Avoid literals -0.0, -0.0L.
19114         * tests/test-strtod.c (zero): New variable.
19115         (main): Avoid literal -0.0.
19116         Reported by Jonathan C. Patschke <jp@centtech.com>.
19117
19118 2008-07-31  Jim Meyering  <meyering@redhat.com>
19119
19120         sha256.h: correct definition of SHA224_DIGEST_SIZE
19121         * lib/sha256.h (SHA224_DIGEST_SIZE): Define to 28, not 24.
19122         Reported by Paulie Pena IV <paulie4@gmail.com>.
19123         Define as 224 / 8, rather than as a literal.
19124         (SHA256_DIGEST_SIZE): Define as 256/8 rather than equivalent literal.
19125         * lib/sha512.h (SHA384_DIGEST_SIZE): Likewise, define as equiv: 384/8.
19126         (SHA512_DIGEST_SIZE): Likewise, define as equivalent quotient: 512/8.
19127
19128 2008-07-31  Bruno Haible  <bruno@clisp.org>
19129
19130         * lib/regex_internal.h (BITSET_WORD_BITS): Make first conditional work
19131         on HP-UX 10.20 with "cc -Ae". Fix second conditional.
19132         Reported by Jonathan Patschke <jp@centtech.com>.
19133
19134 2008-07-31  Bruno Haible  <bruno@clisp.org>
19135
19136         * gnulib-tool (func_import): Make change from 2008-06-23 more robust.
19137         Reported by Paolo Bonzini <bonzini@gnu.org>.
19138
19139 2008-07-30  Eric Blake  <ebb9@byu.net>
19140
19141         test-strtod: allow compilation without -lm
19142         * tests/test-strtod.c (main): Avoid link dependence on fabs.
19143         Reported by Dennis Clarke <blastwave@gmail.com>.
19144
19145 2008-07-28  Jim Meyering  <meyering@redhat.com>
19146
19147         bootstrap: work also when there are no .po files in po/
19148         * build-aux/bootstrap (update_po_files): Complete the change
19149         that I began in bc960df8c789c878f1c1c54a28a3c2648dead8d9.
19150
19151 2008-07-27  Jim Meyering  <meyering@redhat.com>
19152
19153         * users.txt: Add zile.
19154
19155 2008-07-26  Ben Pfaff  <blp@gnu.org>
19156
19157         Add missing dependencies on new m4/exponent[fdl].m4 files.
19158         * modules/isnanf-nolibm: Add m4/exponentf.m4.
19159         * modules/isnand-nolibm: Add m4/exponentd.m4.
19160         * modules/isnanl-nolibm: Add m4/exponentl.m4.
19161         * modules/signbit-tests: Use m4/exponent[fdl].m4 instead of
19162         m4/isnan[fdl].m4, because the macros actually used moved.
19163         Reported by Jim Meyering.
19164
19165 2008-07-14  Ben Pfaff  <blp@gnu.org>
19166
19167         Add isinf module.
19168         * lib/isinf.c: New file.
19169         * lib/math.in.h: Define isinf macro if we have decided to replace
19170         it.
19171         * m4/isinf.m4: New file.
19172         * m4/math_h.m4: Initialize and substitute variables for isinf
19173         module.
19174         * modules/isinf: New file.
19175         * modules/isinf-tests: New file.
19176         * modules/math: Add substitutions for new module.
19177         * tests/test-isinf.c: New file.
19178         * doc/posix-functions/isinf.texi: Mention new module.
19179         * MODULES.html.sh: Mention new module.
19180
19181 2008-07-14  Ben Pfaff  <blp@gnu.org>
19182
19183         Factor out some macros for use by additional modules.
19184         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Move into new file
19185         exponentf.m4.
19186         * m4/isnand.m4 (gl_DOUBLE_EXPONENT_LOCATION): Move into new file
19187         exponentd.m4.
19188         * m4/isnanl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Move into new
19189         file exponentl.m4.
19190         * m4/exponentf.m4: New file.
19191         * m4/exponentd.m4: New file.
19192         * m4/exponentl.m4: New file.
19193         * modules/isnanf: Use new file m4/exponentf.m4.
19194         * modules/isnand: Use new file m4/exponentd.m4.
19195         * modules/isnanl: Use new file m4/exponentl.m4.
19196
19197 2008-07-23  Ulrich Drepper  <drepper@redhat.com>
19198
19199         mktime.c: normalize tp->tm_isdst value to -1/0/1.
19200         * lib/mktime.c (__mktime_internal): Normalize tp->tm_isdst value.
19201         Reported by Michael Ringe <Michael.Ringe@gmx.de> in
19202         <http://sourceware.org/bugzilla/show_bug.cgi?id=6723>.
19203
19204         * lib/canonicalize-lgpl.c (__realpath): Avoid buffer overflow after
19205         readlink on platforms without PATH_MAX.
19206
19207 2008-07-21  Eric Blake  <ebb9@byu.net>
19208
19209         Warn, not fail, on stale version.
19210         * top/GNUmakefile (_curr-ver): Tone down previous patch.
19211
19212         Don't allow installation with stale devel version number.
19213         * top/GNUmakefile (_is-install-target): New macro.
19214         (_curr-ver): Forbid installation with stale version number.
19215
19216 2008-07-20  Bruno Haible  <bruno@clisp.org>
19217
19218         * modules/c-stack-tests (Makefile.am): Add LIBSIGSEGV to
19219         TESTS_ENVIRONMENT.
19220         * tests/test-c-stack2.sh: React differently if LIBSIGSEGV is in use.
19221
19222 2008-07-20  Bruno Haible  <bruno@clisp.org>
19223
19224         * lib/c-stack.h (c_stack_action): Add documentation.
19225         * lib/c-stack.c (c_stack_action): Remove incomplete documentation.
19226
19227 2008-07-20  Bruno Haible  <bruno@clisp.org>
19228
19229         * modules/canonicalize-lgpl (License): Relicense under LGPLv2+.
19230         * modules/readlink (License): Likewise.
19231
19232 2008-07-17  Eric Blake  <ebb9@byu.net>
19233
19234         * modules/c-stack (Link): Fix typo.
19235
19236         Make c-stack use libsigsegv, when available.
19237         * modules/c-stack (Depends-on): Add libsigsegv.
19238         * modules/c-stack-tests (Makefile.am): Link with libsigsegv, if
19239         needed.
19240         * lib/c-stack.c (SIGSTKSZ): Define fallback.
19241         (segv_handler, overflow_handler, c_stack_action)
19242         [HAVE_LIBSIGSEGV && !HAVE_XSI_STACK_OVERFLOW_HEURISTIC]: Add new
19243         implementation when libsigsegv is available, but only when using
19244         the library is necessary.
19245         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Add
19246         comment, explaining why XSI check fails on Linux.
19247         (gl_PREREQ_C_STACK): Supply LIBCSTACK, LTLIBCSTACK.
19248         * tests/test-c-stack2.sh: Tweak skip message.
19249         * NEWS: Document new link-time requirements.
19250
19251 2008-07-16  Eric Blake  <ebb9@byu.net>
19252
19253         c-stack: Expose false positives when not using libsigsegv.
19254         * modules/c-stack-tests (Files): Expand test.
19255         * tests/test-c-stack.c (main): Add means to conditionally trigger
19256         non-overflow SIGSEGV.
19257         * tests/test-c-stack2.sh: New file.
19258
19259 2008-07-14  Bruno Haible  <bruno@clisp.org>
19260
19261         * m4/libsigsegv.m4: Remove unneeded AC_PREREQ.
19262         Reported by Eric Blake.
19263
19264 2008-07-14  Sam Steingold  <sds@gnu.org>
19265             Bruno Haible  <bruno@clisp.org>
19266
19267         New module libsigsegv.
19268         * modules/libsigsegv: New file.
19269         * m4/libsigsegv.m4: New file, from GNU clisp sigsegv.m4 with
19270         modifications.
19271         * MODULES.html.sh (Signal handling): New section.
19272
19273 2008-07-14  Bruno Haible  <bruno@clisp.org>
19274
19275         * modules/unictype/ctype-* (Description): Add the word "function".
19276         Improves the resulting doc in MODULES.html.
19277
19278 2008-07-12  Ben Pfaff  <blp@gnu.org>
19279
19280         Add longlong module.
19281         * modules/longlong: New file.
19282
19283 2008-07-12  Bruno Haible  <bruno@clisp.org>
19284
19285         * m4/isnan.m4 (gl_ISNAN): When the replacement is used, set ISNAN_LIBM
19286         to empty.
19287
19288 2008-07-10  Ben Pfaff  <blp@gnu.org>
19289
19290         Add isnan module.
19291         * doc/posix-functions/isnan.texi: Mention new module.
19292         * lib/math.in.h: Define isnan macro if we have decided to replace
19293         it.
19294         * m4/isnan.m4: New file.
19295         * m4/isnanl.m4 (gl_FUNC_ISNANL): Factor out some code into new
19296         macro gl_BUILD_ISNANL so that isnan.m4 can use that functionality
19297         also.
19298         (gl_FUNC_ISNANL_NO_LIBM): Factor out same code, to reduce
19299         redundancy.
19300         * m4/math_h.m4: Initialize and substitute variables for isnan
19301         module.
19302         * modules/isnan: New file.
19303         * modules/isnan-tests: New file.
19304         * modules/math: Add substitutions for new module.
19305         * tests/test-isnan.c: New file.
19306         * MODULES.html.sh: Mention new module.
19307
19308 2008-07-10  Ben Pfaff  <blp@gnu.org>
19309
19310         Add isnanf module.
19311         * lib/isnanf.m4: New file.
19312         * m4/isnanf.m4 (gl_FUNC_ISNANF): New macro.
19313         (gl_HAVE_ISNANF_IN_LIBM): New macro.
19314         (gl_BUILD_ISNANF): New macro used by gl_FUNC_ISNANF,
19315         gl_FUNC_ISNANF_NO_LIBM, and gl_FUNC_ISNAN.
19316         * modules/isnanf: New file.
19317         * modules/isnanf-tests: New file.
19318         * modules/isnanf-nolibm-tests: Add tests/test-isnanf.h to list of
19319         files.
19320         * tests/test-isnanf-nolibm.c: factored most of its contents into
19321         new file tests/test-isnanf.h.
19322         * tests/test-isnanf.h: New file.
19323         * tests/test-isnanf.c: New file.
19324         * MODULES.html.sh: Mention new module.
19325         * doc/glibc-functions/isnanf.texi: Mention new module.
19326
19327 2008-07-10  Ben Pfaff  <blp@gnu.org>
19328
19329         Add isnand module.
19330         * lib/isnand.h: New file.
19331         * m4/isnand.m4 (gl_FUNC_ISNAND): New macro.
19332         (gl_FUNC_ISNAND_NO_LIBM): Split partially into new macro
19333         gl_HAVE_ISNAND_NO_LIBM so that gl_FUNC_ISNAND can use that
19334         functionality also.
19335         (gl_BUILD_ISNAND): New macro used by gl_FUNC_ISNAND,
19336         gl_FUNC_ISNAND_NO_LIBM, and gl_FUNC_ISNAN.
19337         (gl_HAVE_ISNAND_IN_LIBM): New macro.
19338         * modules/isnand: New file.
19339         * modules/isnand-tests: New file.
19340         * modules/isnand-nolibm-tests: Add tests/test-isnand.h to list of
19341         files.
19342         * tests/test-isnand-nolibm.c: factored most of its contents into
19343         new file tests/test-isnand.h.
19344         * tests/test-isnand.h: New file.
19345         * tests/test-isnand.c: New file.
19346         * MODULES.html.sh: Mention new module.
19347
19348 2008-07-10  Ben Pfaff  <blp@gnu.org>
19349
19350         * lib/isnanf.h: Rename lib/isnanf-nolibm.h.
19351         * lib/isnand.h: Rename lib/isnand-nolibm.h.
19352         * tests/test-isnanf.c: Rename tests/test-isnanf-nolibm.c.
19353         * tests/test-isnand.c: Rename tests/test-isnand-nolibm.c.
19354         * modules/isnanf-nolibm: Update references to renamed files.
19355         * modules/isnand-nolibm: Likewise.
19356         * modules/isnanf-nolibm-tests: Likewise.
19357         * modules/isnand-nolibm-tests: Likewise.
19358         * lib/frexp.c: Likewise.
19359         * lib/isfinite.c: Likewise.
19360         * lib/signbitd.c: Likewise.
19361         * lib/signbitf.c: Likewise.
19362         * lib/vasnprintf.c: Likewise.
19363         * tests/test-ceilf1.c: Likewise.
19364         * tests/test-ceilf2.c: Likewise.
19365         * tests/test-floorf1.c: Likewise.
19366         * tests/test-floorf2.c: Likewise.
19367         * tests/test-frexp.c: Likewise.
19368         * tests/test-round1.c: Likewise.
19369         * tests/test-round2.c: Likewise.
19370         * tests/test-roundf1.c: Likewise.
19371         * tests/test-strtod.c: Likewise.
19372         * tests/test-trunc1.c: Likewise.
19373         * tests/test-trunc2.c: Likewise.
19374         * tests/test-truncf1.c: Likewise.
19375         * tests/test-truncf2.c: Likewise.
19376         * NEWS: Mention the renamed header files.
19377
19378 2008-07-11  Jim Meyering  <meyering@redhat.com>
19379
19380         vc-list-files: make the last-resort awk code more portable
19381         * build-aux/vc-list-files: Don't rely on awk's "sub" command.
19382         /bin/awk from OpenSolaris 11's SUNWesu version 2008.03.22.10.56
19383         does not support it.
19384
19385 2008-07-10  Eric Blake  <ebb9@byu.net>
19386
19387         Work with tar's bootstrap.
19388         * gnulib-tool (func_emit_initmacro_end): Use m4_defn in the case
19389         where LIBSOURCES_DIR contains .#bootmp but must not be treated as
19390         an m4 comment.
19391
19392 2008-07-09  Jim Meyering  <meyering@redhat.com>
19393
19394         posix-shell.m4: fix typo that made this test malfunction
19395         * m4/posix-shell.m4: Remove capitalization in variable name.
19396
19397 2008-07-08  Bruno Haible  <bruno@clisp.org>
19398
19399         * m4/onceonly.m4: Update comments.
19400         Reported by Ben Pfaff <blp@cs.stanford.edu>.
19401
19402 2008-07-04  Jim Meyering  <meyering@redhat.com>
19403
19404         * users.txt: Add vc-dwim.
19405         (bison, coreutils): Use the gitweb URL.
19406
19407 2008-07-03  Jim Meyering  <meyering@redhat.com>
19408
19409         * users.txt: Add libffcall.  From Sam Steingold.
19410
19411 2008-07-03  OndÅ™ej Vašík  <ovasik@redhat.com>
19412
19413         getdate.y: do not ignore TZ with relative day, month or year offset
19414         * lib/getdate.y (get_date): Move the tz-handling block to follow the
19415         relative-date-handling, since otherwise, the latter would clobber the
19416         sole output (an updated Start value) of the tz-handling block.
19417         * tests/test-getdate.c: Tests for the fix
19418
19419 2008-07-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
19420
19421         Recognize 'foo_LIBRARIES += libgnu.a'.
19422         * gnulib-tool (func_emit_lib_Makefile_am): Recognize if a
19423         makefile snippet has already specified an installation location,
19424         also using '+='.
19425
19426 2008-07-02  OndÅ™ej Vašík  <ovasik@redhat.com>
19427
19428         getdate.y: factor out common actions
19429         * lib/getdate.y (apply_relative_time, set_hhmmss): New functions.
19430         Use them in place of open-coded actions.
19431
19432 2008-07-01  Simon Josefsson  <simon@josefsson.org>
19433
19434         Add self-test for getdate module.
19435         * modules/getdate-tests: New file.
19436         * tests/test-getdate.c: New file.
19437
19438 2008-06-29  Bruno Haible  <bruno@clisp.org>
19439
19440         * gnulib-tool (func_import): Put gnulib-comp.m4 into .cvsignore or
19441         .gitignore.
19442         Reported by Sylvain Beucler <beuc@beuc.net>.
19443
19444 2008-06-29  Bruno Haible  <bruno@clisp.org>
19445
19446         * doc/gnulib-tool.texi (VCS Issues): Mention --no-vc-files option.
19447         * m4/gnulib-tool.m4: Update to match current gnulib-tool.
19448
19449 2008-06-29  Bruno Haible  <bruno@clisp.org>
19450
19451         * gnulib-tool (func_import): Recommend to put gnulib-cache.m4 into
19452         EXTRA_DIST.
19453         Reported by Sylvain Beucler <beuc@beuc.net>.
19454
19455 2008-06-26  Jim Meyering  <meyering@redhat.com>
19456
19457         make several modules depend on the "open" module
19458         This provides slightly increased consistency when opening-for-write
19459         the name of a non-directory spelled with a trailing slash.
19460         * modules/chdir-safer: Likewise.
19461         * modules/chown: Likewise.
19462         * modules/clean-temp: Likewise.
19463         * modules/copy-file: Likewise.
19464         * modules/fchdir: Likewise.
19465         * modules/fcntl-safer: Likewise.
19466         * modules/pipe: Likewise.
19467         * modules/utime: Likewise.
19468         Prompted by Eric Blake and Bruno Haible.
19469
19470 2008-06-24  Andreas Schwab  <schwab@suse.de>
19471
19472         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Don't test whether compound
19473         literals can be used as initializers for global variables.
19474
19475 2008-06-23  Eric Blake  <ebb9@byu.net>
19476
19477         Make gnulib-cache.m4 easier to diff.
19478         * gnulib-tool (func_import): Allow newlines when reading cached
19479         gl_MODULES, and generate newlines when creating gnulib-cache.m4.
19480
19481 2008-06-23  Bruno Haible  <bruno@clisp.org>
19482
19483         * m4/signalblocking.m4 (gl_PREREQ_SIG_HANDLER_H): Remove macro.
19484         (gl_PREREQ_SIGPROCMASK): Don't invoke it.
19485         * m4/sigaction.m4 (gl_PREREQ_SIG_HANDLER_H): New macro, moved here from
19486         m4/signalblocking.m4.
19487         (gl_PREREQ_SIGACTION): Don't invoke it.
19488         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Invoke
19489         gl_PREREQ_SIG_HANDLER_H.
19490         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Likewise.
19491         Don't check for sigaction here.
19492
19493 2008-06-23  Bruno Haible  <bruno@clisp.org>
19494
19495         * lib/fatal-signal.c (fatal_signal_handler): Update comment.
19496         (install_handlers): Don't set the SA_RESETHAND flag.
19497
19498 2008-06-23  Bruno Haible  <bruno@clisp.org>
19499
19500         * m4/sigaction.m4: Comment fixes.
19501         * lib/signal.in.h: Likewise.
19502
19503 2008-06-23  Eric Blake  <ebb9@byu.net>
19504
19505         Fix typo.
19506         * tests/test-sigaction.c (MASK_SA_FLAGS): Add missing operator.
19507
19508         Avoid SA_ namespace.
19509         * tests/test-sigaction.c (MASK_SA_FLAGS): Rename from SA_MASK.
19510         Reported by Ralf Wildenhues.
19511
19512         Avoid test failure due to SA_RESTORER.
19513         * tests/test-sigaction.c (SA_MASK): New macro.
19514         (main): Avoid failing due to extension flags being set.
19515         Reported by Jim Meyering.
19516
19517         Revert use of sig-handler.h in sigprocmask.c.
19518         * modules/sigprocmask (Files): Don't rely on sig-handler.h, since
19519         it requires the existence of struct sigaction.
19520         * lib/sigprocmask.c (handler_t): Restore typedef.
19521         (rpl_signal, old_handlers): Use local type.
19522
19523 2008-06-22  Bruno Haible  <bruno@clisp.org>
19524
19525         * tests/test-stdint.c: Disable the INTMAX_MAX preprocessor test
19526         conditionally.
19527         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
19528
19529 2008-06-22  Bruno Haible  <bruno@clisp.org>
19530
19531         * doc/posix-functions/siginterrupt.texi: Move note.
19532
19533         * lib/signal.in.h (SA_RESTART): New macro.
19534         * lib/sigaction.c: Update comment.
19535
19536         * m4/sigaction.m4 (gl_SIGACTION): Require gl_SIGNAL_H_DEFAULTS.
19537
19538         * m4/signalblocking.m4 (gl_PREREQ_SIG_HANDLER_H): New macro.
19539         (gl_PREREQ_SIGPROCMASK): Invoke it.
19540         * m4/sigaction.m4 (gl_PREREQ_SIGACTION): Likewise.
19541
19542         * lib/nanosleep.c (rpl_nanosleep): Setup newact only when it is needed.
19543
19544         * lib/sigprocmask.c: Update a comment.
19545
19546 2008-06-21  Eric Blake  <ebb9@byu.net>
19547
19548         Use sigaction module rather than signal().
19549         * modules/c-stack (Depends-on): Add sigaction.
19550         * modules/fatal-signal (Depends-on): Likewise.
19551         * modules/nanosleep (Depends-on): Likewise.
19552         * modules/sigprocmask (Files): Add sig-handler.h.
19553         * modules/sigaction (Files): Likewise.
19554         * lib/sig-handler.h (get_handler): New file, suggested by Paul
19555         Eggert.
19556         * lib/c-stack.c (SIGACTION_WORKS): Simplify conditions.
19557         (c_stack_action) [!SIGACTION_WORKS]: Use sigaction, not signal.
19558         * lib/fatal-signal.c (uninstall_handlers, install_handlers)
19559         (init_fatal_signals): Likewise.
19560         * lib/nanosleep.c (rpl_nanosleep): Likewise.
19561         (siginterrupt): Delete fallback.
19562         * lib/sigprocmask.c (handler_t, old_handlers): Use sa_handler_t
19563         instead.
19564         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Drop check for
19565         siginterrupt.
19566
19567         New module sigaction, for mingw.
19568         * modules/sigaction: New module...
19569         * modules/sigaction-tests: ...and its test.
19570         * m4/sigaction.m4: New file.
19571         * lib/sigaction.c: Likewise.
19572         * tests/test-sigaction.c: Likewise.
19573         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Add sigaction variables.
19574         * modules/signal (Makefile.am): Likewise.
19575         * lib/signal.in.h (!@HAVE_SIGACTION@): Define replacements when
19576         needed.
19577         * doc/posix-headers/signal.texi (signal.h): Mention provided
19578         types.
19579         * doc/posix-functions/siginterrupt.texi (siginterrupt): Mention
19580         that sigaction is preferable.
19581         * doc/posix-functions/sigaction.texi (sigaction): Mention new
19582         module.
19583         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
19584         sigaction.
19585
19586         Improve robustness of sigprocmask by overriding signal.
19587         * lib/signal.in.h (rpl_signal): Override signal when sigprocmask
19588         is in use.
19589         * lib/sigprocmask.c (blocked_handler): Reinstall block handler.
19590         (SIGKILL, SIGSTOP): Provide fallbacks.
19591         (rpl_signal): Implement.
19592         (old_handlers, blocked_set): Mark volatile, since sigprocmask and
19593         signal can be called inside handlers.
19594
19595         Fix nanosleep module on mingw.
19596         * modules/nanosleep (Depends-on): Add sys_select.
19597         * lib/nanosleep.c (HAVE_SYS_SELECT_H): Rely on gnulib module.
19598
19599         Fix licensing of sigprocmask.
19600         * modules/raise (License): Relicense as LGPL.
19601
19602 2008-06-21  Bruno Haible  <bruno@clisp.org>
19603
19604         * lib/propername.c (proper_name_utf8): Don't use the transliterated
19605         result if it contains question marks.
19606         Reported by Michael Geng <linux@michaelgeng.de>.
19607
19608 2008-06-19  Bruno Haible  <bruno@clisp.org>
19609
19610         Fix CVS-ism.
19611         * doc/gnulib.texi: Include updated-stamp.texi.
19612         * doc/Makefile (GNULIB_TEXI_FILES): New variable.
19613         (updated-stamp.texi): New rule.
19614         (gnulib.info): Depend on it.
19615         * doc/.gitignore: Add updated-stamp.texi.
19616         Based on a patch by Thien-Thi Nguyen <ttn@gnuvola.org>.
19617
19618 2008-06-19  Bruno Haible  <bruno@clisp.org>
19619
19620         * doc/Makefile (gnulib.info): Update and simplify dependencies.
19621         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
19622
19623 2008-06-19  Eric Blake  <ebb9@byu.net>
19624
19625         Fix VPATH 'make dist' with GNU make and non-VCS tarball.
19626         * top/GNUmakefile (_curr-ver): Don't use $(srcdir) unnecessarily.
19627         Reported by Stepan Kasal.
19628
19629 2008-06-18  Bruno Haible  <bruno@clisp.org>
19630
19631         * lib/fatal-signal.c (init_fatal_signals): Add comment.
19632         Reported by Eric Blake.
19633
19634 2008-06-18  Eric Blake  <ebb9@byu.net>
19635
19636         Work around cygwin 1.5.25 strsignal bug.
19637         * tests/test-strsignal.c: Allow for const char *.
19638         * doc/glibc-functions/strsignal.texi (strsignal): Document the bug.
19639
19640 2008-06-18  Simon Josefsson  <simon@josefsson.org>
19641
19642         * users.txt: Update URL to article and add author/date
19643         information.
19644
19645 2008-06-17  Bruno Haible  <bruno@clisp.org>
19646
19647         New macro gl_DISABLE_THREADS.
19648         * m4/lock.m4 (gl_LOCK_EARLY_BODY): Use value gl_use_threads_default
19649         if the user did not pass --enable-threads or --disable-threads option.
19650         (gl_DISABLE_THREADS): New macro.
19651         Reported by Eric Blake <ebb9@byu.net>.
19652
19653 2008-06-17  Bruno Haible  <bruno@clisp.org>
19654
19655         * lib/tls.h (gl_tls_key_init): Evaluate the destructor argument also
19656         when the macro ignores it.
19657         Based on a patch by Eric Blake <ebb9@byu.net>.
19658
19659 2008-06-17  Bruno Haible  <bruno@clisp.org>
19660
19661         * modules/tls (License): Change to LGPLv2+.
19662         Reported by Eric Blake.
19663
19664 2008-06-17  Eric Blake  <ebb9@byu.net>
19665
19666         Simplify c-stack prerequisites.
19667         * lib/c-stack.c (includes): Remove unused <sys/resource.h>.
19668         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Posix 200x
19669         no longer requires <ucontext.h> to exist.  Optimize setrlimit
19670         check.
19671         (gl_PREREQ_C_STACK): Remove check for unused getcontext and
19672         <sys/resource.h>.
19673
19674         Move c-stack test into testsuite.
19675         * modules/c-stack-tests: New file.
19676         * lib/c-stack.c [DEBUG]: Move test program...
19677         * tests/test-c-stack.c: ...into this new file.  Skip rather than
19678         fail test if sigaltstack is lacking.
19679         * tests/test-c-stack.sh: New driver file.
19680
19681 2008-06-16  Eric Blake  <ebb9@byu.net>
19682
19683         Use raise module consistently.
19684         * modules/fatal-signal (Depends-on): Add raise.
19685         * modules/sigprocmask (Depends-on): Likewise.
19686         * lib/fatal-signal.c (fatal_signal_handler): Rely on raise.
19687         * lib/sigprocmask.c (sigprocmask): Likewise.
19688         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Likewise.
19689         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Likewise.
19690
19691         Fix compliance bug in sigpending.
19692         * lib/sigprocmask.c (sigpending): Return pending array via
19693         parameter, not return value.
19694
19695 2008-06-14  Eric Blake  <ebb9@byu.net>
19696
19697         Improve obstack-printf test code.
19698         * tests/test-obstack-printf.c (test_function): Fix comment, and
19699         simplify usage of obstack_* in macros.  Add a test for coverage.
19700         Reported by Bruno Haible.
19701
19702 2008-06-14  Bruno Haible  <bruno@clisp.org>
19703
19704         * lib/obstack_printf.c (obstack_vprintf): Define the stack-allocated
19705         array size as a constant, not as a const variable.
19706         * m4/obstack-printf.m4 (gl_FUNC_OBSTACK_PRINTF): Require
19707         AC_USE_SYSTEM_EXTENSIONS.
19708         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX): Likewise.
19709         Test whether the obstack_printf function actually exists.
19710         * modules/obstack-printf (Depends-on): Add extensions.
19711         (Include): Remove obstack.h.
19712         * modules/obstack-printf-posix (Depends-on): Add extensions.
19713         (Include): Remove obstack.h.
19714
19715 2008-06-13  Eric Blake  <ebb9@byu.net>
19716
19717         Add obstack-printf and obstack-printf-posix modules.
19718         * modules/obstack-printf: New file.
19719         * modules/obstack-printf-posix: Likewise.
19720         * MODULES.html.sh (Misc): Mention them.
19721         * doc/glibc-functions/obstack_printf.texi (obstack_printf):
19722         Likewise.
19723         * doc/glibc-functions/obstack_vprintf.texi (obstack_vprintf):
19724         Likewise.
19725         * modules/stdio (Makefile.am): Accomodate new modules.
19726         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
19727         * lib/stdio.in.h (rpl_obstack_printf, rpl_obstack_vprintf):
19728         Declare.
19729         * lib/obstack_printf.c (obstack_printf, obstack_vprintf): New
19730         functions.
19731         * m4/obstack-printf.m4 (gl_OBSTACK_PRINTF)
19732         (gl_REPLACE_OBSTACK_PRINTF): New macros
19733         * m4/obstack-printf-posix.m4 (gl_OBSTACK_PRINTF_POSIX): Likewise.
19734         * tests/test-obstack-printf.c: New file.
19735         * modules/obstack-printf-tests: Likewise.
19736         * modules/obstack-printf-posix-tests: Likewise.
19737
19738 2008-06-11  Bruno Haible  <bruno@clisp.org>
19739
19740         * m4/open.m4 (gl_FUNC_OPEN): Add test against trailing slash bug.
19741         * lib/open.c: Include errno.h.
19742         (open): Fail when attempting to write to a file that has a trailing
19743         slash.
19744         * tests/test-open.c (main): Test against trailing slash bug.
19745         * doc/posix-functions/open.texi: Mention the trailing slash bug.
19746
19747 2008-06-10  Bruno Haible  <bruno@clisp.org>
19748
19749         * tests/test-vc-list-files-git.sh: Make double use of 'exit'. Needed
19750         for $? to work inside the trap command, with various /bin/sh-s.
19751         * tests/test-vc-list-files-cvs.sh: Likewise.
19752
19753 2008-06-10  Bruno Haible  <bruno@clisp.org>
19754
19755         * lib/acl-internal.h: Don't include gettext.h here.
19756         * lib/set-mode-acl.c: Include gettext.h here.
19757         * lib/copy-acl.c: Likewise.
19758
19759 2008-06-10  Bruno Haible  <bruno@clisp.org>
19760
19761         * lib/wait-process.h (wait_subprocess): Add termsigp argument.
19762         * lib/wait-process.c (wait_subprocess): Likewise.
19763         * lib/execute.h (execute): Add termsigp argument.
19764         * lib/execute.c (execute): Likewise.
19765         * lib/csharpcomp.c (compile_csharp_using_pnet,
19766         compile_csharp_using_mono, compile_csharp_using_sscli): Update.
19767         * lib/csharpexec.c (execute_csharp_using_pnet,
19768         execute_csharp_using_mono, execute_csharp_using_sscli): Update.
19769         * lib/javacomp.c (compile_using_envjavac, compile_using_gcj,
19770         compile_using_javac, compile_using_jikes, is_envjavac_gcj,
19771         is_envjavac_gcj43, is_gcj_present, is_gcj_43, is_javac_present,
19772         is_jikes_present): Update.
19773         * lib/javaexec.c (execute_java_class): Update.
19774         * lib/javaversion.c (execute_and_read_line): Update.
19775         * NEWS: Document the changes.
19776         Reported by Eric Blake.
19777
19778 2008-06-10  Eric Blake  <ebb9@byu.net>
19779
19780         Add missing include.
19781         * tests/test-strstr.c (includes): Add <signal.h>.
19782         * tests/test-strcasestr.c (includes): Likewise.
19783         * tests/test-memmem.c (includes): Likewise.
19784
19785 2008-06-10  Bruno Haible  <bruno@clisp.org>
19786
19787         * lib/wait-process.c (wait_subprocess): Add an assertion.
19788
19789 2008-06-10  Bruno Haible  <bruno@clisp.org>
19790
19791         * lib/wait-process.c (wait_subprocess): Try to fix waitid() based code.
19792
19793 2008-06-10  Bruno Haible  <bruno@clisp.org>
19794
19795         * tests/test-memmem.c (main): Reset SIGALRM to default handling before
19796         using alarm().
19797         * tests/test-strcasestr.c (main): Likewise.
19798         * tests/test-strstr.c (main): Likewise.
19799
19800 2008-06-09  Bruno Haible  <bruno@clisp.org>
19801
19802         Work around the Solaris 10 ACE ACLs ABI change.
19803         * lib/acl-internal.h (acl_nontrivial, acl_ace_nontrivial): Don't
19804         declare if ACL_NO_TRIVIAL is present.
19805         (ACE_ACCESS_ALLOWED_ACE_TYPE, ACE_ACCESS_DENIED_ACE_TYPE,
19806         NEW_ACE_OWNER, NEW_ACE_GROUP, NEW_ACE_IDENTIFIER_GROUP, ACE_EVERYONE,
19807         NEW_ACE_READ_DATA, NEW_ACE_WRITE_DATA, NEW_ACE_EXECUTE): New macros.
19808         * lib/file-has-acl.c (acl_nontrivial, acl_ace_nontrivial): Don't
19809         define if ACL_NO_TRIVIAL is present.
19810         (acl_ace_nontrivial): Detect whether the old or new ABI is in use,
19811         and use the current ABI.
19812         (file_has_acl): Use same #if condition as elsewhere.
19813         * lib/set-mode-acl.c (qset_acl): Detect whether the old or new ABI is
19814         in use, and use the current ABI.
19815         * doc/acl-resources.txt: More doc about newer Solaris 10 versions.
19816         Reported by Jim Meyering.
19817
19818 2008-06-09  Eric Blake  <ebb9@byu.net>
19819
19820         Work around environments that (stupidly) ignore SIGALRM.
19821         * m4/strstr.m4 (gl_FUNC_STRSTR): Reset SIGALRM to default handling
19822         before using alarm().
19823         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
19824         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
19825         Reported by Ian Beckwith <ianb@erislabs.net>.
19826
19827         Produce autobuild blurb earlier in log.
19828         * modules/autobuild (configure.ac-early): Move AB_INIT here.
19829
19830 2008-06-09  Jim Meyering  <meyering@redhat.com>
19831         and OndÅ™ej Vašík  <ovasik@redhat.com>
19832
19833         utimens.c: correct kernel bug work-around
19834         OndÅ™ej Vašík found that the invalid return value of 280 indicates
19835         failure, not success, and the kernel bug we're trying to work
19836         around affects not just the utimensat call, but also the fallback
19837         futimens call.
19838         * lib/utimens.c (gl_futimens) [HAVE_UTIMENSAT]: Simulate failure,
19839         not success.
19840         [HAVE_FUTIMENS]: Use the same work-around, here.
19841
19842 2008-06-09  Jim Meyering  <meyering@redhat.com>
19843
19844         add more guards around definition of ACE_-related code
19845         * lib/file-has-acl.c (acl_ace_nontrivial): Define only if
19846         ALLOW and ACE_OWNER are also defined.
19847
19848 2008-06-08  Bruno Haible  <bruno@clisp.org>
19849
19850         * lib/acl-internal.h: Add me as co-author.
19851         * lib/file-has-acl.c: Likewise.
19852         * lib/set-mode-acl.c: Likewise.
19853         * lib/copy-acl.c: Likewise.
19854
19855 2008-06-08  Bruno Haible  <bruno@clisp.org>
19856
19857         Add support for AIX ACLs.
19858         * lib/acl-internal.h (acl_nontrivial): New declaration.
19859         * lib/file-has-acl.c (acl_nontrivial): New function.
19860         (file_has_acl): Add implementation using AIX 4 ACL API.
19861         * lib/set-mode-acl.c (qset_acl): Likewise.
19862         * lib/copy-acl.c (qcopy_acl): Likewise.
19863
19864 2008-06-08  Bruno Haible  <bruno@clisp.org>
19865
19866         Add support for HP-UX ACLs.
19867         * lib/acl-internal.h (acl_nontrivial): New declaration.
19868         * lib/file-has-acl.c (acl_nontrivial): New function.
19869         (file_has_acl): Add implementation using HP-UX 11 ACL API.
19870         * lib/set-mode-acl.c (qset_acl): Likewise.
19871         * lib/copy-acl.c (qcopy_acl): Likewise.
19872
19873 2008-06-08  Bruno Haible  <bruno@clisp.org>
19874
19875         Add support for Cygwin ACLs.
19876         * lib/acl-internal.h (MODE_INSIDE_ACL): New macro for Solaris-like API.
19877         * lib/set-mode-acl.c (qset_acl) [!MODE_INSIDE_ACL]: Don't optimize away
19878         the chmod_or_fchmod call.
19879         * lib/copy-acl.c (qcopy_acl) [!MODE_INSIDE_ACL]: Likewise.
19880
19881 2008-06-08  Bruno Haible  <bruno@clisp.org>
19882
19883         Fix bug with setuid modes in Solaris 10+ code.
19884         * lib/set-mode-acl.c (qset_acl): Call chmod_or_fchmod when acl_set
19885         succeeded, when the mode contains some special bits.
19886
19887 2008-06-08  Bruno Haible  <bruno@clisp.org>
19888
19889         Add support for Solaris 7..10 ACLs.
19890         * lib/acl-internal.h (acl_nontrivial, acl_ace_nontrivial): New
19891         declarations.
19892         * lib/file-has-acl.c (acl_nontrivial, acl_ace_nontrivial): New
19893         functions.
19894         (file_has_acl): Add implementation using Solaris 7..10 ACL API.
19895         * lib/set-mode-acl.c (qset_acl): Likewise.
19896         * lib/copy-acl.c (qcopy_acl): Likewise.
19897
19898 2008-06-08  Bruno Haible  <bruno@clisp.org>
19899
19900         * lib/acl-internal.h (acl_extended_nontrivial) [MacOS X]: New
19901         declaration.
19902         * lib/file-has-acl.c (acl_extended_nontrivial) [MacOS X]: New function.
19903         (acl_access_nontrivial): Remove MacOS X case.
19904         (file_has_acl): Use acl_extended_nontrivial.
19905         * lib/copy-acl.c (qcopy_acl): Likewise.
19906
19907 2008-06-08  Bruno Haible  <bruno@clisp.org>
19908
19909         * lib/set-mode-acl.c (qset_acl): Trivial code simplifications.
19910
19911 2008-06-08  Jim Meyering  <meyering@redhat.com>
19912
19913         * modules/acl (Maintainer): Add Bruno Haible.
19914
19915 2008-06-07  Bruno Haible  <bruno@clisp.org>
19916
19917         Improve support for Tru64 ACLs.
19918         * lib/file-has-acl.c (file_has_acl): Don't test the ACL_TYPE_DEFAULT
19919         ACL on OSF/1.
19920
19921 2008-06-07  Bruno Haible  <bruno@clisp.org>
19922
19923         Add support for MacOS X ACLs.
19924         * lib/file-has-acl.c (file_has_acl): Use ACL_TYPE_EXTENDED instead of
19925         ACL_TYPE_ACCESS and ACL_TYPE_DEFAULT.
19926         * lib/set-mode-acl.c (qset_acl): Likewise.
19927         * lib/copy-acl.c (qcopy_acl): Likewise.
19928
19929 2008-06-07  Bruno Haible  <bruno@clisp.org>
19930
19931         Fix memory leak introduced on 2008-05-22.
19932         * lib/set-mode-acl.c (qset_acl) [!MODE_INSIDE_ACL]: Free ACLs after
19933         use.
19934
19935 2008-06-07  Bruno Haible  <bruno@clisp.org>
19936
19937         * lib/set-mode-acl.c (qset_acl): Use acl_init(), not acl_from_text(),
19938         to construct an empty ACL.
19939
19940 2008-06-07  Bruno Haible  <bruno@clisp.org>
19941
19942         * lib/set-mode-acl.c (chmod_or_fchmod): Document return value
19943         precisely.
19944         * lib/copy-acl.c (qcopy_acl): Trivial code simplifications.
19945
19946 2008-06-07  Bruno Haible  <bruno@clisp.org>
19947
19948         * lib/copy-acl.c (qcopy_acl): Make the #if branches independent.
19949         * lib/set-mode-acl.c (qset_acl): Choose better local variable names.
19950
19951 2008-06-07  Bruno Haible  <bruno@clisp.org>
19952
19953         * doc/posix-functions/_setjmp.texi: Explain the use of this function
19954         regardless of POSIX.
19955         * doc/posix-functions/_longjmp.texi: Likewise.
19956         * doc/posix-functions/setjmp.texi: Mention HP-UX as not counting as a
19957         SystemV platform in this case.
19958
19959 2008-06-06  Eric Blake  <ebb9@byu.net>
19960
19961         Document abort() bugs.
19962         * doc/posix-functions/abort.texi (abort): Mention anomalies.
19963
19964         * doc/posix-functions/setjmp.texi (setjmp): Mingw has setjmp.
19965         * doc/posix-functions/sigsetjmp.texi (sigsetjmp): Cygwin has
19966         sigsetjmp.
19967         * doc/posix-functions/siglongjmp.texi (siglongjmp): Cygwin has
19968         siglongjmp, but only as a macro.
19969         * doc/posix-functions/_longjmp.texi (_longjmp): Mention that this
19970         is obsolete.
19971         * doc/posix-functions/_setjmp.texi (_setjmp): Likewise.
19972
19973         Tweak documentation to cover cygwin argz bugs.
19974         * m4/argz.m4 (gl_FUNC_ARGZ): Mention date of last known cygwin
19975         argz bug fix; no code change needed since no cygwin releases
19976         occurred between the last fix and the bug being tested.
19977         * doc/glibc-functions/argz_add.texi (argz_add): Document the argz
19978         module and recently fixed cygwin bugs.
19979         * doc/glibc-functions/argz_add_sep.texi (argz_add_sep): Likewise.
19980         * doc/glibc-functions/argz_append.texi (argz_append): Likewise.
19981         * doc/glibc-functions/argz_count.texi (argz_count): Likewise.
19982         * doc/glibc-functions/argz_create.texi (argz_create): Likewise.
19983         * doc/glibc-functions/argz_create_sep.texi (argz_create_sep):
19984         Likewise.
19985         * doc/glibc-functions/argz_delete.texi (argz_delete): Likewise.
19986         * doc/glibc-functions/argz_extract.texi (argz_extract): Likewise.
19987         * doc/glibc-functions/argz_insert.texi (argz_insert): Likewise.
19988         * doc/glibc-functions/argz_next.texi (argz_next): Likewise.
19989         * doc/glibc-functions/argz_replace.texi (argz_replace): Likewise.
19990         * doc/glibc-functions/argz_stringify.texi (argz_stringify):
19991         Likewise.
19992
19993         Avoid gcc warning on cygwin.
19994         * lib/copy-acl.c (qcopy_acl) [!HAVE_ACL_GET_FILE &&
19995         !ACL_NO_TRIVIAL]: Avoid unused variable.
19996
19997 2008-06-05  Eric Blake  <ebb9@byu.net>
19998
19999         Be tolerant of UNKNOWN version in gnulib-tool test dir.
20000         * top/GNUmakefile (_dummy): Warn rather than reconfigure if
20001         git-version-gen fails to come up with a version.
20002         Reported by Simon Josefsson.
20003
20004 2008-06-05  Jim Meyering  <meyering@redhat.com>
20005             Paul Eggert  <eggert@cs.ucla.edu>
20006
20007         utimens.c: work around a probable Linux kernel bug
20008         * lib/utimens.c (gl_futimens) [HAVE_UTIMENSAT]: Work around what
20009         appears to be a kernel bug that causes utimensat to return 280
20010         instead of 0, indicating success.
20011
20012 2008-06-04  Bruno Haible  <bruno@clisp.org>
20013
20014         * lib/copy-acl.c (qcopy_acl): Call qset_acl, not set_acl. Fixes
20015         2008-06-01 commit.
20016
20017 2008-06-04  Bruno Haible  <bruno@clisp.org>
20018
20019         * lib/acl-internal.h (acl_access_nontrivial): New declaration.
20020         * lib/file-has-acl.c (acl_access_nontrivial): New function.
20021         (file_has_acl): Use it. Save errno afterwards.
20022         * lib/copy-acl.c (qcopy_acl): Use acl_access_nontrivial.
20023
20024 2008-06-03  Bruno Haible  <bruno@clisp.org>
20025
20026         * lib/file-has-acl.c (file_has_acl): Put Solaris 10 code after POSIX-
20027         draft code. Simplify #ifs.
20028         * lib/set-mode-acl.c (qset_acl): Don't test for symlink if !USE_ACL.
20029         Put Solaris code after POSIX-draft code. Fix comments regarding
20030         Solaris 10, HP-UX. Mention Cygwin.
20031         * lib/copy-acl.c (qcopy_acl): Simplify #ifs.
20032
20033 2008-06-03  Eric Blake  <ebb9@byu.net>
20034
20035         Provide fallback for older kernels.
20036         * lib/utimens.c (gl_futimens) [HAVE_UTIMENSAT, HAVE_FUTIMENS]:
20037         Provide runtime fallback if kernel lacks support.
20038         Reported by Mike Frysinger.
20039
20040 2008-06-02  Bruno Haible  <bruno@clisp.org>
20041
20042         * lib/acl-internal.h (ACL_NOT_WELL_SUPPORTED): Include EOPNOTSUPP if
20043         it exists.
20044
20045 2008-06-02  Bruno Haible  <bruno@clisp.org>
20046
20047         * lib/acl_entries.c (acl_entries): Rewrite to use acl_get_entry.
20048         * lib/copy-acl.c (qcopy_acl): Update comment.
20049
20050 2008-06-02  Bruno Haible  <bruno@clisp.org>
20051
20052         * lib/acl-entries.h: Enclose most definitions in #ifs for POSIX-draft
20053         like ACL APIs.
20054
20055 2008-06-02  Bruno Haible  <bruno@clisp.org>
20056
20057         * tests/test-file-has-acl.sh: Use different code for Cygwin.
20058         * tests/test-set-mode-acl.sh: Likewise.
20059         * tests/test-copy-acl.sh: Likewise.
20060         * tests/test-copy-file.sh: Likewise.
20061
20062 2008-06-02  Bruno Haible  <bruno@clisp.org>
20063
20064         * tests/test-file-has-acl.sh: Remove unused code.
20065
20066 2008-06-01  Bruno Haible  <bruno@clisp.org>
20067
20068         * lib/copy-acl.c (qcopy_acl): New function, extracted from copy_acl.
20069         (copy_acl): Just a wrapper around qcopy_acl that emits the error
20070         messages.
20071         * lib/set-mode-acl.c (qset_acl): Document return value precisely.
20072
20073 2008-06-01  Bruno Haible  <bruno@clisp.org>
20074
20075         * m4/acl.m4 (gl_FUNC_ACL): Separate the POSIX-like and the Solaris
20076         tests. Test for libpacl, needed for OSF/1. Test for extended ACLs,
20077         needed for MacOS X. Test for HP-UX API. Test for newer and older AIX
20078         APIs.
20079         * modules/acl-tests (configure.ac): Remove tests now contained in
20080         m4/acl.m4.
20081
20082 2008-06-02  Jim Meyering  <meyering@redhat.com>
20083
20084         announce-gen: use a better key-server host name
20085         * build-aux/announce-gen (main): Recommend keys.gnupg.net, since
20086         it may be more consistently reliable.  Suggested by Werner Koch
20087         in <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/13717>.
20088
20089 2008-06-01  Bruno Haible  <bruno@clisp.org>
20090
20091         * lib/stdio-impl.h (fp_ub): Use fp_. Needed for DragonFly BSD.
20092         Reported by Voroskoi Andras <voroskoi@gmail.com>.
20093
20094 2008-06-01  Voroskoi Andras  <voroskoi@gmail.com>  (tiny change)
20095
20096         * lib/stdio-impl.h [__DragonFly__]: Fix typo.
20097
20098 2008-06-01  Bruno Haible  <bruno@clisp.org>
20099
20100         New ACL tests.
20101         * tests/test-file-has-acl.sh: New file.
20102         * tests/test-file-has-acl.c: New file.
20103         * tests/test-set-mode-acl.sh: New file.
20104         * tests/test-set-mode-acl.c: New file.
20105         * tests/test-copy-acl.sh: New file, based on tests/test-copy-file.sh.
20106         * tests/test-copy-acl.c: New file.
20107         * modules/acl-tests: New file, based on modules/copy-file-tests.
20108         * modules/copy-file-tests (Files): Remove tests/test-sameacls.c.
20109         (Depends-on): Add acl-tests.
20110         (configure.ac): Remove checks.
20111         (Makefile.am): Don't create test-sameacls program here any more.
20112
20113 2008-06-01  Bruno Haible  <bruno@clisp.org>
20114
20115         * tests/test-copy-file.sh: Portability fixes for Solaris, HP-UX, IRIX.
20116         * tests/test-sameacls.c: Include progname.h.
20117         (main): Invoke set_program_name. Portability fixes for MacOS X,
20118         Solaris, HP-UX.
20119
20120 2008-06-01  Bruno Haible  <bruno@clisp.org>
20121
20122         * lib/freadahead.c (freadahead) [__DragonFly__]: Use the __sreadahead
20123         function.
20124         Reported by VOROSKOI Andras <voroskoi@gmail.com>.
20125
20126 2008-06-01  Bruno Haible  <bruno@clisp.org>
20127
20128         * modules/rpmatch (Depends-on): Add strdup.
20129
20130 2008-06-01  Bruno Haible  <bruno@clisp.org>
20131
20132         * lib/pipe.c: Include unistd-safer.h.
20133         (create_pipe): Ensure the returned file descriptors are not in {0,1,2}.
20134         * modules/pipe (Depends-on): Add unistd-safer.
20135
20136 2008-05-30  Simon Josefsson  <simon@josefsson.org>
20137
20138         * modules/autobuild (configure.ac): Call AB_INIT.
20139
20140 2008-05-30  Simon Josefsson  <simon@josefsson.org>
20141
20142         * tests/test-getaddrinfo.c: Don't print debug messages by default.
20143         Suggested by Bruno Haible <bruno@clisp.org>.
20144
20145 2008-05-30  Simon Josefsson  <simon@josefsson.org>
20146
20147         * tests/test-base64.c: Cast size_t to unsigned long when invoking
20148         printf.  Use %lu instead of %d.  Reported by Bruno Haible
20149         <bruno@clisp.org>.
20150
20151 2008-05-29  Eric Blake  <ebb9@byu.net>
20152
20153         Prefer new POSIX 200x interfaces over futimesat.
20154         * m4/utimens.m4 (gl_UTIMENS): Check for futimens, utimensat.
20155         * lib/utimens.c (gl_futimens): Use them for nanosecond resolution
20156         when available.
20157         [HAVE_BUGGY_NFS_TIME_STAMPS]: Allow C89 compilation.
20158
20159 2008-05-28  Bruno Haible  <bruno@clisp.org>
20160
20161         * modules/stpcpy (License): Change to LGPLv2+.
20162         Requested by David Lutterkort <dlutter@redhat.com>.
20163
20164 2008-05-27  Bruno Haible  <bruno@clisp.org>
20165
20166         * lib/localename.c (SUBLANG_TIBETAN_BHUTAN): Force value 2. Needed for
20167         current mingw.
20168         Reported by Jose E. Marchesi <jemarch@gnu.org>.
20169
20170 2008-05-27  Bruno Haible  <bruno@clisp.org>
20171
20172         * modules/iconv_open (Link): New section, from module 'iconv'.
20173         * modules/striconv (Link): Likewise.
20174         * modules/striconveh (Link): Likewise.
20175         * modules/xstriconv (Link): Likewise.
20176         * modules/unicodeio (Link): Likewise.
20177         * modules/propername (Link): Likewise.
20178         Reported by Jim Meyering.
20179
20180 2008-05-26  Jim Meyering  <meyering@redhat.com>
20181
20182         sha256: do not artificially restrict buffer length to be < 2^32
20183         * lib/sha256.h (struct sha256_ctx) [buflen]: Change type from
20184         uint32_t to size_t.
20185         * lib/sha256.c (sha256_conclude_ctx): Change type of a local
20186         to match.
20187
20188         avoid unaligned access errors, e.g., on sparc
20189         * lib/sha512.c (sha512_conclude_ctx): Use set_uint64 rather than
20190         direct access through a possibly-unaligned uint64* pointer.
20191         * lib/sha256.c (sha256_conclude_ctx): Use set_uint32 rather than
20192         direct access through a possibly-unaligned uint32* pointer.
20193         Prompted by this patch from Tom "spot" Callaway:
20194         http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/13638
20195
20196         sha512.c: fix typo in comment
20197         * lib/sha512.c (sha512_conclude_ctx): Length is 128-bit, not 64-bit.
20198
20199 2008-05-25  Bruno Haible  <bruno@clisp.org>
20200
20201         * lib/set-mode-acl.c: Renamed from lib/acl.c.
20202         * modules/acl (Files): Add lib/set-mode-acl.c, remove lib/acl.c.
20203         (Makefile.am): Update lib_SOURCES.
20204
20205 2008-05-25  Bruno Haible  <bruno@clisp.org>
20206
20207         * m4/acl.m4 (gl_FUNC_ACL): Don't set LIB_ACL_TRIVIAL.
20208
20209 2008-05-25  Jim Meyering  <meyering@redhat.com>
20210
20211         useless-if-before-free: freed expr may have white-space differences
20212         * build-aux/useless-if-before-free: Recognize cases in which the
20213         freed expression differs from the tested one in embedded white
20214         space, e.g., if (p[i + 1]) free(p[i+1]).  Correct thinko in prev:
20215         $1 was used, so we can't make any regexp shy.  Improved tests now
20216         detect this.
20217
20218         useless-if-before-free: accept white space in the expression.
20219         * build-aux/useless-if-before-free: For now, any white space
20220         in the expression must be identical in the free argument.
20221
20222         useless-if-before-free: efficiency tweak
20223         * build-aux/useless-if-before-free: Make the expression-matching
20224         regexp "shy".
20225         Make the *outer* regexp shy, not the expr-matching one.
20226
20227         update code-in-comment to accept cast of free arg
20228         * build-aux/useless-if-before-free: Update regexp.
20229
20230 2008-05-25  Bruno Haible  <bruno@clisp.org>
20231
20232         * tests/test-sameacls.c: Renamed from tests/test-copy-file-sameacls.c.
20233         * modules/copy-file-tests (Files, Makefile.am): Update.
20234         * tests/test-copy-file.c (func_test_copy): Update.
20235
20236 2008-05-24  Andreas Färber  <andreas.faerber@web.de>  (tiny change)
20237
20238         * lib/stdbool.in.h [__HAIKU__]: Disable __BEOS__ workarounds.
20239
20240 2008-05-23  Bruno Haible  <bruno@clisp.org>
20241
20242         Improve support for ACLs on OSF/1.
20243         * lib/acl.c (qset_acl): For OSF/1, use a string that ends in a comma.
20244         Remove fallback for unknown flavors of ACLs.
20245
20246 2008-05-22  Bruno Haible  <bruno@clisp.org>
20247
20248         Add support for ACLs on OSF/1.
20249         * lib/acl-internal.h (acl_get_fd, acl_set_fd): New inline function
20250         replacements.
20251         (acl_free_text): New macro fallback.
20252         * lib/acl_entries.c (acl_entries): Use acl_free_text instead of
20253         acl_free.
20254         * m4/acl.m4 (gl_FUNC_ACL): Look also in libpacl library. Test for
20255         acl_free_text function. Require AC_C_INLINE.
20256
20257 2008-05-22  Bruno Haible  <bruno@clisp.org>
20258
20259         Make copy_acl work on MacOS X 10.5.
20260         * lib/acl-internal.h (MODE_INSIDE_ACL): New macro.
20261         (ACL_NOT_WELL_SUPPORTED): On MacOS X, also handle ENOENT.
20262         * lib/acl.c (qset_acl): Add different code branch for !MODE_INSIDE_ACL.
20263         If MODE_INSIDE_ACL, don't assume that every system has the same text
20264         representation for ACLs as FreeBSD.
20265         * lib/copy-acl.c (copy_acl): Add support for platforms with
20266         !MODE_INSIDE_ACL.
20267         * lib/file-has-acl.c (file_has_acl): Likewise.
20268         * m4/acl.m4 (gl_FUNC_ACL): Test for some functions that are witness of
20269         FreeBSD, MacOS X, or IRIX, respectively.
20270
20271 2008-05-22  Bruno Haible  <bruno@clisp.org>
20272
20273         * lib/acl.h: Don't include <sys/acl.h>.
20274         (GETACLCNT): Move fallback to lib/acl-internal.h.
20275         * lib/acl-internal.h: Include <sys/acl.h> here.
20276         (GETACLCNT): New macro fallback, moved here from lib/acl.h.
20277
20278 2008-05-22  Bruno Haible  <bruno@clisp.org>
20279
20280         Split off copy_acl function to separate file.
20281         * lib/copy-acl.c: New file, extracted from lib/acl.c.
20282         * lib/acl.c (copy_acl): Moved function to separate file.
20283         * m4/acl.m4 (gl_FUNC_ACL): Remove unconditional AC_LIBOBJs.
20284         * modules/acl (Files): Add lib/copy-acl.c.
20285         (Makefiles.am): Augment lib_SOURCES.
20286
20287 2008-05-22  Bruno Haible  <bruno@clisp.org>
20288
20289         * modules/copy-file-tests: New file.
20290         * tests/test-copy-file.sh: New file.
20291         * tests/test-copy-file.c: New file.
20292         * tests/test-copy-file-sameacls.c: New file.
20293
20294 2008-05-22  Eric Blake  <ebb9@byu.net>
20295
20296         Avoid gcc warning.
20297         * tests/test-memcmp.c (main): Pass NULL indirectly.
20298
20299 2008-05-21  Bruno Haible  <bruno@clisp.org>
20300
20301         Add reference doc about ACLs.
20302         * doc/acl-resources.txt: New file.
20303         * doc/acl-cygwin.txt: New file.
20304
20305 2008-05-21  Bruno Haible  <bruno@clisp.org>
20306
20307         Avoid one more warning from gcc.
20308         * lib/vasnprintf.c (IF_LINT): Update comments.
20309         (VASNPRINTF): Use it also for the 'prefix' array initializer.
20310
20311 2008-05-21  Jim Meyering  <meyering@redhat.com>
20312
20313         avoid a warning from gcc
20314         * lib/vasnprintf.c (IF_LINT): Define.
20315         (scale10_round_decimal_long_double):
20316         Use it to avoid a "may be used uninitialized" warning.
20317         (scale10_round_decimal_double): Likewise.
20318
20319 2008-05-21  Simon Josefsson  <simon@josefsson.org>
20320
20321         * m4/memcmp.m4: When cross-compiling, assume memcmp works if it is
20322         declared.
20323
20324 2008-05-20  Bruno Haible  <bruno@clisp.org>
20325
20326         * tests/test-memcmp.c (main): Test also the sign of the result. Test
20327         against two known bugs; code taken from autoconf's AC_FUNC_MEMCMP.
20328
20329 2008-05-20  Simon Josefsson  <simon@josefsson.org>
20330
20331         * modules/memcmp-tests: New file.
20332         * tests/test-memcmp.c: New file.
20333
20334 2008-05-19  Bruno Haible  <bruno@clisp.org>
20335
20336         * modules/propername (Notice, configure.ac): Put quoted "..." into
20337         --keyword option.
20338         * lib/propername.h: Update comments accordingly.
20339         Reported by Eric Blake.
20340
20341 2008-05-19  Martin Lambers  <marlam@marlam.de>  (tiny change)
20342
20343         * modules/getpass-gnu (Depends-on): Add fseeko.
20344
20345 2008-05-19  Simon Josefsson  <simon@josefsson.org>
20346
20347         * modules/base64-tests: New file.
20348
20349 2008-05-19  Bo Borgerson <gigabo@gmail.com>
20350
20351         * lib/base64.c (base64_decode_ctx): If a decode context structure
20352         was passed in use it to ignore newlines.  If a context structure
20353         was _not_ passed in, continue to treat newlines as garbage (this
20354         is the historical behavior).  Formerly base64_decode.
20355         (base64_decode_alloc_ctx): Formerly base64_decode_alloc.  Now
20356         takes a decode context structure.
20357         * lib/base64.h (base64_decode): Macro for four-argument calls.
20358         (base64_decode_alloc): Likewise.
20359         * lib/base64.c (base64_decode_ctx): If a decode context structure
20360         was passed in use it to ignore newlines.  If a context structure
20361         was _not_ passed in, continue to treat newlines as garbage (this
20362         is the historical behavior).  Formerly base64_decode.
20363         (base64_decode_alloc_ctx): Formerly base64_decode_alloc.  Now
20364         takes a decode context structure.
20365         * lib/base64.h (base64_decode): Macro for four-argument calls.
20366         (base64_decode_alloc): Likewise.
20367
20368 2008-05-19  Jim Meyering  <meyering@redhat.com>
20369
20370         avoid a warning from gcc
20371         * lib/trim.c (IF_LINT): Define.
20372         (trim2): Use it to avoid a "may be used uninitialized" warning.
20373
20374         Fix doc typo.
20375         * doc/glibc-functions/getpass.texi (getpass): s/PATH_MAX/PASS_MAX/.
20376
20377 2008-05-19  Bruno Haible  <bruno@clisp.org>
20378
20379         * doc/glibc-functions/getpass.texi: Document limits of other
20380         implementations.
20381
20382 2008-05-19  Simon Josefsson  <simon@josefsson.org>
20383             Bruno Haible <bruno@clisp.org>
20384
20385         * doc/glibc-functions/getpass.texi: Document gnulib implementation.
20386
20387 2008-05-18  Bruno Haible  <bruno@clisp.org>
20388
20389         * modules/propername: New file, from GNU gettext.
20390         * lib/propername.h: New file, from GNU gettext.
20391         * lib/propername.c: New file, from GNU gettext.
20392         * MODULES.html.sh (Internationalization functions): Add propername.
20393
20394 2008-05-16  Jim Meyering  <meyering@redhat.com>
20395             Bruno Haible  <bruno@clisp.org>
20396
20397         Avoid some warnings from "gcc -Wshadow".
20398         * lib/vasnprintf.c (exp, remainder): Define to different identifiers.
20399
20400 2008-05-15  Eric Blake  <ebb9@byu.net>
20401
20402         Extend previous patch to cygwin 1.7.0.
20403         * m4/memmem.m4 (gl_FUNC_MEMMEM): When cross-compiling, assume a
20404         fast implementation in cygwin >= 1.7.0.
20405         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
20406         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
20407
20408 2008-05-15  Bruno Haible  <bruno@clisp.org>
20409
20410         * m4/memmem.m4 (gl_FUNC_MEMMEM): When cross-compiling, assume a fast
20411         implementation in glibc >= 2.9.
20412         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
20413         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
20414
20415 2008-05-15  Bruno Haible  <bruno@clisp.org>
20416
20417         * MODULES.html.sh (Internationalization functions): Remove linebreak.
20418         (Unicode string functions): Add unilbrk/*.
20419         Reported by Karl Berry.
20420
20421 2008-05-15  Eric Blake  <ebb9@byu.net>
20422
20423         Fix violation of <stdbool.h> replacement in regex.
20424         * lib/regcomp.c (re_compile_internal): Avoid implicit cast to bool.
20425         * lib/regexec.c (re_search_internal): Likewise.
20426         Reported by Heinrich Mislik <Heinrich.Mislik@univie.ac.at>.
20427
20428 2008-05-15  Jim Meyering  <meyering@redhat.com>
20429
20430         avoid distracting test output when git or cvs is not found
20431         * tests/test-vc-list-files-cvs.sh: Suppress 'init' error output.
20432         * tests/test-vc-list-files-git.sh: Likewise.
20433
20434 2008-05-15  Eric Blake  <ebb9@byu.net>
20435
20436         Glibc finally accepted the memmem speedup code, bugzilla #5514.
20437         * doc/glibc-functions/memmem.texi (memmem): Mention last broken
20438         glibc version.
20439         * doc/glibc-functions/strcasestr.texi (strcasestr): Likewise.
20440         * doc/posix-functions/strstr.texi (strstr): Likewise.
20441         * lib/str-two-way.h (MAX): Sychronize with glibc.
20442
20443 2008-05-15  Paolo Bonzini  <bonzini@gnu.org>
20444
20445         * lib/regcomp.c (optimize_utf8): Add a note on why we test
20446         opr.ctx_type.
20447         (calc_first): Initialize constraint field.
20448         (duplicate_node_closure): Use it instead of special casing ANCHORS.
20449         Fix grammar.
20450         (duplicate_node): Merge constraint field for all node types.
20451         (calc_eclosure_iter): Look at constraint field for all node types.
20452         * lib/regex_internal.c (create_cd_newstate): Don't look at
20453         opr.ctx_type.
20454
20455 2008-05-14  Bruno Haible  <bruno@clisp.org>
20456
20457         Help GCC to do better code generation.
20458         * lib/eealloc.h (eemalloc) [GCC >= 3]: Declare with attribute 'malloc'.
20459         * lib/pagealign_alloc.h (pagealign_alloc, pagealign_xalloc): Likewise.
20460         * lib/xalloc.h (ATTRIBUTE_MALLOC): New macro.
20461         (xmalloc, xzalloc, xcalloc, xmemdup, xstrdup, xnmalloc, xcharalloc):
20462         Declare with attribute 'malloc' if supported.
20463
20464 2008-05-14  Lasse Collin  <lasse.collin@tukaani.org>
20465
20466         use "echo STR|wc -c" rather than unportable "expr length STR"
20467         * build-aux/mktempd (mktempd): Vendor-supplied expr from at least
20468         OpenBSD 4.3 and Solaris 10 do not honor expr's "length" function.
20469
20470 2008-05-14  Jim Meyering  <meyering@redhat.com>
20471
20472         use dd ibs=$n count=1 ... rather than less-portable head -c$n
20473         * build-aux/mktempd (rand_bytes): head's -cN option is not accepted
20474         by Solaris 10's /bin/head or by the one from HP-UX 11.x.
20475         Reported in http://sourceforge.net/forum/message.php?msg_id=4960334
20476         via Collin Lasse.
20477
20478 2008-05-14  Eric Blake  <ebb9@byu.net>
20479
20480         Avoid quadratic growth in gl_LIBSOURCES.
20481         * gnulib-tool (func_emit_initmacro_done): s/\(m4_append\)_uniq/\1/.
20482         Suggested by Bruno Haible.
20483
20484         Test xmemdup0.
20485         * modules/xmemdup0-tests: New file.
20486         * tests/test-xmemdup0.c: Likewise.
20487
20488 2008-05-13  Eric Blake  <ebb9@byu.net>
20489
20490         Split xmemdup0 into its own module.
20491         * modules/xmemdup0: New file.
20492         * lib/xmemdup0.h: Likewise.
20493         * lib/xmemdup0.c: Likewise.
20494         * MODULES.html.sh (Memory management functions): Add xmemdup0.
20495         * lib/xalloc.h (xmemdup0): Remove.
20496         * lib/xmalloc.c (xmemdup0): Likewise.
20497
20498 2008-05-13  Eric Blake  <ebb9@byu.net>
20499             Bruno Haible  <bruno@clisp.org>
20500
20501         Reduce number of forks required during autoconf.
20502         * gnulib-tool (func_emit_initmacro_start): Prepare gl_LIBSOURCES_LIST
20503         and gl_LIBSOURCES_DIR.
20504         (func_emit_initmacro_end): Use them here in a single m4_syscmd...
20505         (func_emit_initmacro_done) <gl_LIBSOURCES>: ...rather than in one
20506         m4_syscmd per file.
20507         <m4_foreach_w>: Move...
20508         * m4/gnulib-common.m4 (m4_foreach_w): ...here.
20509
20510 2008-05-13  Eric Blake  <ebb9@byu.net>
20511
20512         * gnulib-tool: Fix various comment typos.
20513
20514 2008-05-12  Bruno Haible  <bruno@clisp.org>
20515
20516         Tailor the linebreaking algorithm.
20517         * lib/unilbrk/tables.c (unilbrk_table): Change (IS,AL) entry.
20518
20519 2008-05-12  Bruno Haible  <bruno@clisp.org>
20520
20521         Update to Unicode 5.0.0.
20522         * lib/unilbrk/tables.h (LBP_*): Add LBP_WJ, LBP_H2, LBP_H3, LBP_JL,
20523         LBP_JV, LBP_JT. Redistribute values.
20524         (unilbrk_table): Change size.
20525         * lib/unilbrk/tables.c (unilbrk_table): Change size. Update to match
20526         Unicode TR#14 rev. 22.
20527         * lib/unilbrk/gen-lbrk.c (LBP_*): Add LBP_WJ, LBP_H2, LBP_H3, LBP_JL,
20528         LBP_JV, LBP_JT. Redistribute values.
20529         (get_lbp): Update to match Unicode TR#14 rev. 21/22 and Unicode 5.0.0.
20530         (debug_output_lbp, fill_org_lbp, debug_output_org_lbp, output_lbp):
20531         Update.
20532         * lib/unilbrk/lbrkprop1.h: Regenerated.
20533         * lib/unilbrk/lbrkprop2.h: Regenerated.
20534         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks):
20535         Change handling of LBP_CM after LBP_ZW. Update for new value of LBP_BK.
20536         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
20537         Likewise.
20538         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
20539         Likewise.
20540         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Update expected
20541         result.
20542         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
20543         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
20544         * tests/unilbrk/test-ulc-possible-linebreaks.c (main): Likewise.
20545         * tests/unilbrk/test-u8-width-linebreaks.c (main): Likewise.
20546         * tests/unilbrk/test-u16-width-linebreaks.c (main): Likewise.
20547         * tests/unilbrk/test-u32-width-linebreaks.c (main): Likewise.
20548
20549 2008-05-11  Bruno Haible  <bruno@clisp.org>
20550
20551         * lib/unilbrk/gen-lbrk.c (output_lbp): Fix whitespace.
20552
20553 2008-05-11  Bruno Haible  <bruno@clisp.org>
20554
20555         * lib/unilbrk/gen-lbrk.c: New file, from GNU gettext (gen-lbrkprop.c).
20556         * modules/unilbrk/gen-lbrk: New file.
20557
20558 2008-05-11  Bruno Haible  <bruno@clisp.org>
20559
20560         * m4/sha256.m4 (gl_SHA256): Require AC_C_INLINE.
20561         * m4/sha512.m4 (gl_SHA512): Likewise.
20562
20563 2008-05-11  Jim Meyering  <meyering@redhat.com>
20564
20565         New modules: crypto/sha256, crypto/sha512 (from coreutils)
20566         * modules/crypto/sha256: New file.
20567         * modules/crypto/sha512: Likewise.
20568         * lib/sha256.c: Likewise.
20569         * lib/sha256.h: Likewise.
20570         * lib/sha512.c: Likewise.
20571         * lib/sha512.h: Likewise.
20572         * lib/u64.h: Likewise.
20573         * m4/sha256.m4: Likewise.
20574         * m4/sha512.m4: Likewise.
20575         * MODULES.html.sh (Cryptographic computations (low-level)): List them.
20576
20577 2008-05-10  Bruno Haible  <bruno@clisp.org>
20578
20579         * MODULES.html.sh (Environment variables <stdlib.h>): Add unsetenv.
20580         (Input/Output <stdio.h>): Add xprintf.
20581         (Signal handling <signal.h>): Add strsignal.
20582         (Cryptographic computations (high-level)): Add crypto/gc-camellia.
20583         (Core language properties): Add func.
20584         (Mathematics <math.h>): Add ceil, floor, frexp-nolibm.
20585         (Support for systems lacking POSIX:2001): Add environ, EOVERFLOW,
20586         strings.
20587         (Enhancements for POSIX:2001 functions): Add iconv_open-utf.
20588         (Input/output): New section.
20589         (File system functions): Add openat-die, stat-macros.
20590         (Networking functions): Add sockets.
20591         (Unicode string functions): Add unictype/*.
20592         (Support for building libraries and executables): Add gperf.
20593         (Support for building documentation): Add agpl-3.0.
20594         (Misc): Add nocrash.
20595
20596 2008-05-10  Bruno Haible  <bruno@clisp.org>
20597
20598         * modules/unictype/gen-ctype: New file.
20599
20600 2008-05-10  Jim Meyering  <meyering@redhat.com>
20601
20602         Make chdir-safer.c more efficient on a system with no symlinks.
20603         * lib/chdir-safer.c (chdir_no_follow): Skip lstat and fstat calls
20604         also if ELOOP is zero.  Suggested by Bruno Haible.
20605
20606         Make chdir-safer.c slightly safer.
20607         * lib/chdir-safer.c (chdir_no_follow): Test HAVE_WORKING_O_NOFOLLOW,
20608         not O_NOFOLLOW, in case the latter is nonzero and open ignores it.
20609
20610         Avoid compile failure on systems without ELOOP (like mingw).
20611         * lib/chdir-safer.c (ELOOP): Define if not already defined.
20612         Reported by Bruno Haible.
20613
20614 2008-05-10  Bruno Haible  <bruno@clisp.org>
20615
20616         * lib/unilbrk/ulc-common.c: Include c-strcaseeq.h instead of streq.h.
20617         (is_utf8_encoding): Use a case-insensitive comparison.
20618         * modules/unilbrk/ulc-common (Depends-on): Add c-strcaseeq. Remove
20619         streq.
20620
20621 2008-05-10  Bruno Haible  <bruno@clisp.org>
20622
20623         * lib/unilbrk/ulc-common.c: Don't include <stdlib.h>.
20624         (iconv_string_length, iconv_string_keeping_offsets): Remove functions.
20625         * lib/unilbrk/ulc-common.h (iconv_string_length,
20626         iconv_string_keeping_offsets): Remove declarations.
20627         * lib/unilbrk/ulc-possible-linebreaks.c: Include <string.h>, uniconv.h.
20628         Don't include <iconv.h>, streq.h, xsize.h.
20629         (ulc_possible_linebreaks): Use u8_conv_from_encoding for doing the
20630         conversion.
20631         * lib/unilbrk/ulc-width-linebreaks.c: Include uniconv.h. Don't include
20632         <iconv.h>, streq.h, xsize.h.
20633         (ulc_width_linebreaks): Use u8_conv_from_encoding for doing the
20634         conversion.
20635         * modules/unilbrk/ulc-common (Depends-on): Remove iconv.
20636         * modules/unilbrk/ulc-possible-linebreaks (Depends-on): Add
20637         uniconv/u8-conv-from-enc. Remove iconv_open, streq, xsize.
20638         * modules/unilbrk/ulc-width-linebreaks (Depends-on): Likewise.
20639
20640 2008-05-10  Bruno Haible  <bruno@clisp.org>
20641
20642         * modules/unilbrk/ulc-width-linebreaks-tests: New file.
20643         * tests/unilbrk/test-ulc-width-linebreaks.c: New file.
20644
20645         * modules/unilbrk/u32-width-linebreaks-tests: New file.
20646         * tests/unilbrk/test-u32-width-linebreaks.c: New file.
20647
20648         * modules/unilbrk/u16-width-linebreaks-tests: New file.
20649         * tests/unilbrk/test-u16-width-linebreaks.c: New file.
20650
20651         * modules/unilbrk/u8-width-linebreaks-tests: New file.
20652         * tests/unilbrk/test-u8-width-linebreaks.c: New file.
20653
20654         * modules/unilbrk/ulc-possible-linebreaks-tests: New file.
20655         * tests/unilbrk/test-ulc-possible-linebreaks.c: New file.
20656
20657         * modules/unilbrk/u32-possible-linebreaks-tests: New file.
20658         * tests/unilbrk/test-u32-possible-linebreaks.c: New file.
20659
20660         * modules/unilbrk/u16-possible-linebreaks-tests: New file.
20661         * tests/unilbrk/test-u16-possible-linebreaks.c: New file.
20662
20663         * modules/unilbrk/u8-possible-linebreaks-tests: New file.
20664         * tests/unilbrk/test-u8-possible-linebreaks.c: New file.
20665
20666 2008-05-10  Bruno Haible  <bruno@clisp.org>
20667
20668         Split up 'linebreak' module.
20669         * lib/unilbrk.h: New file, based on lib/linebreak.h.
20670         * lib/unilbrk/lbrkprop1.h: New file, extracted from lib/lbrkprop.h.
20671         * lib/unilbrk/lbrkprop2.h: New file, renamed from lib/lbrkprop.h with
20672         modifications.
20673         * lib/unilbrk/tables.h: New file, extracted from lib/linebreak.c.
20674         * lib/unilbrk/tables.c: New file, extracted from lib/linebreak.c.
20675         * lib/unilbrk/u8-possible-linebreaks.c: New file, extracted from
20676         lib/linebreak.c.
20677         * lib/unilbrk/u16-possible-linebreaks.c: New file, extracted from
20678         lib/linebreak.c.
20679         * lib/unilbrk/u32-possible-linebreaks.c: New file, extracted from
20680         lib/linebreak.c.
20681         * lib/unilbrk/ulc-common.h: New file, extracted from lib/linebreak.c.
20682         * lib/unilbrk/ulc-common.c: New file, extracted from lib/linebreak.c.
20683         * lib/unilbrk/ulc-possible-linebreaks.c: New file, extracted from
20684         lib/linebreak.c.
20685         * lib/unilbrk/u8-width-linebreaks.c: New file, extracted from
20686         lib/linebreak.c.
20687         * lib/unilbrk/u16-width-linebreaks.c: New file, extracted from
20688         lib/linebreak.c.
20689         * lib/unilbrk/u32-width-linebreaks.c: New file, extracted from
20690         lib/linebreak.c.
20691         * lib/unilbrk/ulc-width-linebreaks.c: New file, extracted from
20692         lib/linebreak.c.
20693         * modules/unilbrk/base: New file.
20694         * modules/unilbrk/tables: New file.
20695         * modules/unilbrk/u8-possible-linebreaks: New file.
20696         * modules/unilbrk/u16-possible-linebreaks: New file.
20697         * modules/unilbrk/u32-possible-linebreaks: New file.
20698         * modules/unilbrk/ulc-common: New file.
20699         * modules/unilbrk/ulc-possible-linebreaks: New file.
20700         * modules/unilbrk/u8-width-linebreaks: New file.
20701         * modules/unilbrk/u16-width-linebreaks: New file.
20702         * modules/unilbrk/u32-width-linebreaks: New file.
20703         * modules/unilbrk/ulc-width-linebreaks: New file.
20704         * lib/linebreak.h: Remove file.
20705         * lib/linebreak.c: Remove file.
20706         * m4/linebreak.m4: Remove file.
20707         * modules/linebreak: Remove file.
20708         * NEWS: Mention the changes.
20709
20710 2008-05-09  Eric Blake  <ebb9@byu.net>
20711
20712         Add xmemdup0.
20713         * lib/xalloc.h (xmemdup0): New prototype and C++ typesafe
20714         implementation.
20715         * lib/xmalloc.c (xmemdup0): New C implementation.
20716
20717 2008-05-08  Bruno Haible  <bruno@clisp.org>
20718
20719         * m4/wctype.m4 (gl_WCTYPE_H): Correct indentation.
20720
20721 2008-05-07  Eric Blake  <ebb9@byu.net>
20722
20723         Support cross-compilation of <wctype.h>.
20724         * m4/wctype.m4 (gl_WCTYPE_H): Fix improper nesting in
20725         AC_CACHE_CHECK.
20726
20727 2008-05-06  Soren Hansen  <soren@ubuntu.com>  (tiny change)
20728
20729         * build-aux/vc-list-files: Add support for bzr.
20730
20731 2008-05-03  Jim Meyering  <meyering@redhat.com>
20732
20733         avoid failed assertion with tight malloc
20734         * tests/test-getndelim2.c: Correct an off-by-one assertion.
20735
20736 2008-05-03  Simon Josefsson  <simon@josefsson.org>
20737
20738         * m4/inet_pton.m4: Set HAVE_DECL_INET_PTON to 0 when declarations
20739         are needed from arpa/inet.h.
20740         * m4/inet_ntop.m4: Likewise, for HAVE_DECL_INET_NTOP.
20741         Reported by Bruno Haible.
20742
20743 2008-05-02  Jim Meyering  <meyering@redhat.com>
20744
20745         avoid compilation error on FreeBSD 6
20746         * tests/test-getaddrinfo.c [!defined EAI_NODATA] (EAI_NODATA): Define.
20747
20748 2008-05-01  Jim Meyering  <meyering@redhat.com>
20749
20750         useless-if-before-free: correct --help's exit status description
20751         * build-aux/useless-if-before-free (usage): Like grep, exit 0
20752         for one or more matches, etc.  Reported by Bruno Haible.
20753
20754         vc-list-files: make the stand-alone gnulib test work
20755         * modules/vc-list-files-tests (configure.ac):
20756         Define and AC_SUBST abs_aux_dir.
20757         (Makefile.am) [TESTS_ENVIRONMENT]: Rather than passing
20758         $(abs_top_srcdir) to each script and having each of them
20759         duplicate the work of setting PATH, set PATH here, using
20760         the new variable, abs_aux_dir instead.
20761         * tests/test-vc-list-files-cvs.sh: Don't set PATH here.
20762         * tests/test-vc-list-files-git.sh: Likewise.
20763         Reported by Bruno Haible.
20764
20765 2008-05-01  Bruno Haible  <bruno@clisp.org>
20766
20767         * lib/getndelim2.c (getndelim2): Fix newsize computation during
20768         reallocation. Rename 'done' to 'found_delimiter'.
20769
20770 2008-05-01  Jim Meyering  <meyering@redhat.com>
20771
20772         vc-list-files: accommodate /bin/sh like the one from Solaris 10
20773         * build-aux/vc-list-files: Use `...`, not $(...).
20774
20775 2008-04-30  Jim Meyering  <meyering@redhat.com>
20776
20777         add tests for vc-list-files
20778         * modules/vc-list-files-tests: New module.
20779         * tests/test-vc-list-files-cvs.sh: New file.
20780         * tests/test-vc-list-files-git.sh: New file.
20781
20782         avoid a warning from gcc
20783         * lib/getndelim2.c (IF_LINT): Define.
20784         (getndelim2): Use it to avoid a "may be used uninitialized" warning.
20785
20786         vc-list-files: work properly with build-aux/cvsu, too
20787         * build-aux/vc-list-files: Hoist the "./"-removing code to apply
20788         to all cvs-based clauses.
20789
20790         vc-list-files: work properly in the CVS+awk case, too
20791         * build-aux/vc-list-files: In the CVS+awk case, remove "./" prefix.
20792
20793         vc-list-files: avoid use of ${*-*} that fails when /bin/sh is dash
20794         * build-aux/vc-list-files: Simplify ${*-*} to $dir, since we no longer
20795         take more than one file argument, so .  Add quotes, just in case $dir
20796         ever contains a shell meta-character.  Prompted by Soren Hansen in
20797         <http://thread.gmane.org/gmane.comp.emulators.libvirt/6221/focus=6240>.
20798
20799 2008-04-29  Eric Blake  <ebb9@byu.net>
20800
20801         Optimize getndelim2 to use block operations when possible.
20802         * modules/getndelim2 (Depends-on): Add stdbool, freadptr,
20803         freadseek, and memchr2.
20804         * lib/getndelim2.c (getndelim2): Use them for block reads.
20805
20806 2008-04-29  Bruno Haible  <bruno@clisp.org>
20807
20808         * m4/inet_ntop.m4 (gl_INET_NTOP): Require gl_USE_SYSTEM_EXTENSIONS.
20809         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
20810         * modules/inet_ntop (Depends-on): Add extensions.
20811         * modules/inet_pton (Depends-on): Likewise.
20812         Reported by Simon Josefsson.
20813
20814 2008-04-29  Jim Meyering  <meyering@redhat.com>
20815
20816         When the is more than one match in a block, match all of them.
20817         * build-aux/useless-if-before-free: Iterate through each block
20818         until there are no more matches.
20819
20820         Fix broken useless-if-before-free script.
20821         * build-aux/useless-if-before-free: Fix typo: missing "?" after
20822         the expression to match cast of argument to free-like function.
20823
20824 2008-04-29  Eric Blake  <ebb9@byu.net>
20825
20826         Use new header.
20827         * lib/getaddrinfo.c (includes): s/"inet_ntop.h"/<arpa/inet.h>/.
20828
20829 2008-04-29  Jim Meyering  <meyering@redhat.com>
20830
20831         Avoid test segfault on x86_64 due to lack of inet_ntop declaration.
20832         * tests/test-getaddrinfo.c: Include <arpa/inet.h>, now guaranteed
20833         by gnulib to exist and to declare e.g., inet_ntop.
20834         Don't include "inet_ntop.h", now removed.
20835
20836         * m4/arpa_inet_h.m4: Remove trailing blanks.
20837
20838 2008-04-29  Eric Blake  <ebb9@byu.net>
20839
20840         Silence valgrind on safe reads beyond potential array bounds.
20841         * lib/rawmemchr.valgrind: New file.
20842         * lib/strchrnul.valgrind: Likewise.
20843         * modules/rawmemchr (Files): Distribute new file.
20844         * modules/strchrnul (Files): Likewise.
20845         Suggested by Bruno Haible.
20846
20847 2008-04-29  Bruno Haible  <bruno@clisp.org>
20848
20849         * lib/arpa_inet.in.h: Include system's <arpa/inet.h> if it exists.
20850         (inet_ntop, inet_pton): Change portability warning's wording.
20851         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Set HAVE_ARPA_INET_H.
20852         Invoke gl_CHECK_NEXT_HEADERS.
20853         (gl_ARPA_INET_H_DEFAULTS): Initialize ARPA_INET_H.
20854         * m4/inet_ntop.m4 (gl_INET_NTOP): Require gl_ARPA_INET_H_DEFAULTS and
20855         set ARPA_INET_H.
20856         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
20857         * modules/arpa_inet (Description): No longer only for systems that
20858         lack it.
20859         (Depends-on): Add include_next.
20860         (Makeile.am): Substitute INCLUDE_NEXT, NEXT_ARPA_INET_H,
20861         HAVE_ARPA_INET_H.
20862
20863 2008-04-29  Jim Meyering  <meyering@redhat.com>
20864
20865         * modules/mkdir (License): Re-license as LGPLv2+.
20866
20867 2008-04-29  Bruno Haible  <bruno@clisp.org>
20868
20869         * modules/rawmemchr (Maintainer): Set to Eric.
20870         * modules/strchrnul (Maintainer): Likewise.
20871
20872 2008-04-29  Simon Josefsson  <simon@josefsson.org>
20873
20874         * m4/arpa_inet_h.m4 (gl_ARPA_INET_H_DEFAULTS): Set
20875         HAVE_DECL_INET_NTOP and HAVE_DECL_INET_PTON.
20876
20877         * modules/arpa_inet (arpa/inet.h): Use them.
20878
20879 2008-04-28  Eric Blake  <ebb9@byu.net>
20880
20881         Test getndelim2.
20882         * modules/getndelim2-tests: New file.
20883         * tests/test-getndelim2.c: Likewise.
20884         * lib/getndelim2.c (getndelim2): Never return 0.  Lock the
20885         stream.
20886         * m4/getndelim2.m4 (gl_GETNDELIM2): Check for lock functions.
20887
20888         * MODULES.html.sh: Document new module.
20889
20890 2008-04-20  Bruno Haible  <bruno@clisp.org>
20891
20892         * lib/c-stack.c (die): Use raise.
20893         * modules/c-stack (Depends-on): Add raise.
20894
20895 2008-04-28  Bruno Haible  <bruno@clisp.org>
20896
20897         Expect rpmatch to be declared.
20898         * lib/yesno.c (rpmatch): Remove declaration.
20899
20900         Declare rpmatch.
20901         * lib/stdlib.in.h (rpmatch): New declaration.
20902         * lib/rpmatch.c: Include <stdlib.h> first.
20903         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Require AC_USE_SYSTEM_EXTENSIONS and
20904         gl_STDLIB_H_DEFAULTS. Set HAVE_RPMATCH.
20905         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_RPMATCH,
20906         HAVE_RPMATCH.
20907         * modules/rpmatch (Depends-on): Add stdlib, extensions.
20908         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
20909         (Include): Set to <stdlib.h>.
20910         * modules/stdlib (Makefile.am): Substitute GNULIB_RPMATCH and
20911         HAVE_RPMATCH.
20912         * NEWS: Document the change.
20913
20914 2008-04-28  Bruno Haible  <bruno@clisp.org>
20915
20916         Change rpmatch to use nl_langinfo when appropriate.
20917         * lib/rpmatch.c: Include stdbool.h, string.h, langinfo.h.
20918         (N_): New macro.
20919         (localized_pattern): New function/macro.
20920         (try): Remove match, nomatch arguments. Copy the pattern into safe
20921         memory before caching it.
20922         (rpmatch): Use localized_pattern. Add translator comments.
20923         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Test for nl_langinfo and YESEXPR.
20924         Suggested by Eric Blake.
20925         * modules/rpmatch (Depends-on): Add stdbool.
20926
20927 2008-04-28  Eric Blake  <ebb9@byu.net>
20928
20929         Add rawmemchr module, matching glibc.
20930         * modules/string (Makefile.am): New indicator.
20931         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set it.
20932         * lib/string.in.h (rawmemchr): Declare when appropriate.
20933         * modules/rawmemchr: New file.
20934         * m4/rawmemchr.m4: Likewise.
20935         * lib/rawmemchr.c: Likewise.
20936         * modules/rawmemchr-tests: Likewise.
20937         * tests/test-rawmemchr.c: Likewise.
20938         * doc/glibc-functions/rawmemchr.texi (rawmemchr): Document
20939         module.
20940         * modules/strchrnul (Depends-on): Add rawmemchr.
20941         * lib/strchrnul.c (strchrnul): Optimize a corner case.
20942
20943         Whitespace cleanup.
20944         * tests/test-strchrnul.c: Reindent.
20945         * lib/strchrnul.c: Likewise.
20946
20947         Optimize and test strchrnul.
20948         * lib/strchrnul.c (strchrnul): Rewrite to do parallel search.
20949         * modules/strchrnul-tests: New file.
20950         * tests/test-strchrnul.c: Likewise.
20951
20952         Remove intprops dependency.
20953         * modules/memchr (Depends-on): Remove intprops.
20954         * modules/memrchr (Depends-on): Likewise.
20955         * modules/memchr2 (Depends-on): Likewise.
20956         * lib/memchr.c (__memchr): Hand-inline the TYPE_MAXIMUM check.
20957         * lib/memrchr.c (__memrchr): Likewise.
20958         * lib/memrchr2.c (memchr2): Likewise.
20959         Reported by Simon Josefsson.
20960
20961 2008-04-28  Simon Josefsson  <simon@josefsson.org>
20962
20963         * m4/sys_socket_h.m4: Move AC_REQUIRE([AC_C_INLINE]) to top.
20964         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
20965
20966 2008-04-28  Simon Josefsson  <simon@josefsson.org>
20967
20968         * lib/inet_ntop.h, lib/inet_pton.h: Remove files.
20969
20970         * lib/inet_ntop.c: Include arpa/inet.h instead of inet_ntop.h.
20971
20972         * lib/inet_pton.c: Include arpa/inet.h instead of inet_pton.h.
20973
20974         * lib/arpa_inet.in.h [@GNULIB_INET_NTOP@]: Inline inet_ntop.h
20975         declarations.
20976         [@GNULIB_INET_PTON@]: Inline inet_pton.h declarations.
20977
20978         * m4/inet_pton.m4: Don't check for header files.
20979
20980         * m4/inet_ntop.m4: Don't check for header files.
20981
20982 2008-04-28  Simon Josefsson  <simon@josefsson.org>
20983
20984         * m4/sys_socket_h.m4: Require AC_C_INLINE when necessary.
20985         * lib/sys_socket.in.h (setsockopt): Use proper win32 tests (don't
20986         trigger for cygwin).
20987         Reported by Bruno Haible  <bruno@clisp.org>.
20988
20989 2008-04-28  Bruno Haible  <bruno@clisp.org>
20990
20991         * doc/posix-functions/strdup.texi: Mention mingw problem.
20992
20993 2008-04-27  Bruno Haible  <bruno@clisp.org>
20994
20995         * modules/stat-time-tests (Depends-on): Add sleep.
20996         * tests/test-stat-time.c (force_unlink): New function.
20997         (cleanup): Use it.
20998         (test_mtime): Remove the ctime related tests.
20999         (test_ctime): New function, containing the ctime related tests.
21000         (main): Call test_ctime, except on native Windows platforms.
21001
21002 2008-04-27  Bruno Haible  <bruno@clisp.org>
21003
21004         * lib/rpmatch.c (rpmatch): Add some comments.
21005         Reported by James Youngman <jay@gnu.org>.
21006
21007 2008-04-27  Bruno Haible  <bruno@clisp.org>
21008
21009         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Also test the behaviour on
21010         quiet NaNs.
21011
21012 2008-04-27  Bruno Haible  <bruno@clisp.org>
21013
21014         Make test-yesno.sh work on mingw.
21015         * tests/test-yesno.sh: Postprocess the output to convert CR/LF to LF.
21016         * tests/test-yesno.c: Include yesno.h first. Include binary-io.h.
21017         (main): Set stdin to binary mode.
21018         * modules/yesno-tests (Depends-on): Add binary-io.
21019
21020 2008-04-27  Bruno Haible  <bruno@clisp.org>
21021
21022         Fix 'isfinite' on x86, x86_64, ia64 platforms.
21023         * tests/test-isfinite.c (test_isfinitel): Also test the behavior on
21024         argument that lie outside the IEEE 854 domain.
21025         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): New macro.
21026         (gl_ISFINITE): Use it.
21027         * doc/posix-functions/isfinite.texi: Document the fixed bugs.
21028
21029 2008-04-27  Bruno Haible  <bruno@clisp.org>
21030
21031         Allow local renaming in config.h.
21032         * lib/memrchr.c (memrchr): Don't undefine outside libc.
21033
21034 2008-04-27  Bruno Haible  <bruno@clisp.org>
21035
21036         * lib/memchr.c (__memchr): Change type of 'i'.
21037         * lib/memchr2.c (memchr2): Likewise.
21038
21039 2008-04-26  Eric Blake  <ebb9@byu.net>
21040         and Bruno Haible  <bruno@clisp.org>
21041
21042         Optimize and test memrchr.
21043         * modules/memrchr (Depends-on): Add intprops.
21044         * lib/memrchr.c (__memrchr): Avoid false positives in loop.
21045         * modules/memrchr-tests: New file.
21046         * tests/test-memrchr.c: New file.
21047
21048 2008-04-26  Bruno Haible  <bruno@clisp.org>
21049
21050         Add tentative support for DragonFly BSD.
21051         * lib/stdio-impl.h: Add macros for DragonFly BSD.
21052         * lib/fbufmode.c (fbufmode): Update conditionals. Use fp_ instead of
21053         fp.
21054         * lib/fflush.c (clear_ungetc_buffer, disable_seek_optimization,
21055         restore_seek_optimization, update_fpos_cache, rpl_fflush: Likewise.
21056         * lib/fpurge.c (fpurge): Likewise.
21057         * lib/freadable.c (freaadable): Likewise.
21058         * lib/freadahead.c (freadahead): Likewise.
21059         * lib/freading.c (freading): Likewise.
21060         * lib/freadptr.c (freadptr): Likewise.
21061         * lib/freadseek.c (freadptrinc): Likewise.
21062         * lib/fseeko.c (fseeko): Likewise.
21063         * lib/fseterr.c (fseterr): Likewise.
21064         * lib/fwritable.c (fwritable): Likewise.
21065         * lib/fwriting.c (fwriting): Likewise.
21066
21067 2008-04-26  Bruno Haible  <bruno@clisp.org>
21068
21069         * lib/stdio-impl.h: New file.
21070         * lib/fbufmode.c: Include stdio-impl.h.
21071         (fbufmode): Use fp_, remove redundant #defines.
21072         * lib/fflush.c: Include stdio-impl.h.
21073         (clear_ungetc_buffer): Remove redundant #defines.
21074         * lib/fpurge.c: Include stdio-impl.h.
21075         (fpurge): Remove redundant #defines.
21076         * lib/freadable.c: Include stdio-impl.h.
21077         (freadable): Remove redundant #defines.
21078         * lib/freadahead.c: Include stdio-impl.h.
21079         (freadahead): Remove redundant #defines.
21080         * lib/freading.c: Include stdio-impl.h.
21081         (freading): Remove redundant #defines.
21082         * lib/freadptr.c: Include stdio-impl.h.
21083         (freadptr): Remove redundant #defines.
21084         * lib/freadseek.c: Include stdio-impl.h.
21085         (freadptrinc): Remove redundant #defines.
21086         * lib/fseeko.c: Include stdio-impl.h.
21087         (rpl_fseeko): Remove redundant #defines.
21088         * lib/fseterr.c: Include stdio-impl.h.
21089         (fseterr): Remove redundant #defines.
21090         * lib/fwritable.c: Include stdio-impl.h.
21091         (fwritable: Remove redundant #defines.
21092         * lib/fwriting.c: Include stdio-impl.h.
21093         (fwriting): Remove redundant #defines.
21094         * modules/fbufmode (Files): Add lib/stdio-impl.h.
21095         * modules/fflush (Files): Likewise.
21096         * modules/fpurge (Files): Likewise.
21097         * modules/freadable (Files): Likewise.
21098         * modules/freadahead (Files): Likewise.
21099         * modules/freading (Files): Likewise.
21100         * modules/freadptr (Files): Likewise.
21101         * modules/freadseek (Files): Likewise.
21102         * modules/fseeko (Files): Likewise.
21103         * modules/fseterr (Files): Likewise.
21104         * modules/fwritable (Files): Likewise.
21105         * modules/fwriting (Files): Likewise.
21106
21107 2008-04-26  Bruno Haible  <bruno@clisp.org>
21108
21109         * lib/fflush.c (clear_ungetc_buffer, disable_seek_optimization,
21110         restore_seek_optimization, update_fpos_cache): New functions, extracted
21111         from rpl_fflush.
21112         (rpl_fflush): Use them.
21113         * m4/fflush.m4 (gl_PREREQ_FFLUSH): New macro.
21114         (gl_REPLACE_FFLUSH): Use it.
21115
21116 2008-04-26  Bruno Haible  <bruno@clisp.org>
21117
21118         * tests/test-xstrtol.sh: Work around limitation of an old 'tr' program
21119         on Solaris.
21120         * tests/test-xstrtoimax.sh: Likewise.
21121         * tests/test-xstrtoumax.sh: Likewise.
21122         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
21123
21124 2008-04-26  Bruno Haible  <bruno@clisp.org>
21125
21126         * modules/memchr-tests: New file.
21127         * tests/test-memchr.c; New file, based on tests/test-memchr2.c.
21128
21129 2008-04-26  Eric Blake  <ebb9@byu.net>
21130             Bruno Haible  <bruno@clisp.org>
21131
21132         * lib/memchr.c: Include intprops.h.
21133         (__memchr): Optimize parallel detection of matching bytes. Rename local
21134         variables. Add explanatory comments.
21135
21136 2008-04-26  Bruno Haible  <bruno@clisp.org>
21137
21138         Fix module 'memchr', broken since 2000-10-28.
21139         * lib/memchr.c: Outside glibc, define memchr, not __memchr.
21140
21141 2008-04-26  Bruno Haible  <bruno@clisp.org>
21142
21143         * lib/memchr2.c (memchr2): Rename local variables. Add explanatory
21144         comments.
21145
21146 2008-04-25  Eric Blake  <ebb9@byu.net>
21147
21148         Use native fstatat on cygwin 1.7.0.
21149         * m4/openat.m4 (gl_FUNC_OPENAT): Make sure lstat check is made
21150         first.
21151
21152 2008-04-23  Eric Blake  <ebb9@byu.net>
21153
21154         Improve memchr2 performance.
21155         * lib/memchr2.c (memchr2): Further optimize parallel detection of
21156         NUL bytes.
21157         * modules/memchr2 (Depends-on): Use intprops.h.
21158
21159 2008-04-23  Simon Josefsson  <simon@josefsson.org>
21160
21161         * lib/sys_socket.in.h (setsockopt): Be more type safe by declaring
21162         an inline function instead of a CPP macro.  Patch by Ben Pfaff
21163         <blp@cs.stanford.edu>.
21164
21165 2008-04-23  Simon Josefsson  <simon@josefsson.org>
21166
21167         * lib/arpa_inet.in.h: New file.
21168
21169         * modules/arpa_inet (Files): Add lib/arpa_inet.in.h.
21170         (Makefile.am): Sed in substitute header file.
21171
21172         * m4/arpa_inet_h.m4: Add gl_ARPA_INET_H_DEFAULTS and
21173         gl_ARPA_INET_MODULE_INDICATOR.  Use them.
21174
21175         * modules/inet_ntop (configure.ac): Use
21176         gl_ARPA_INET_MODULE_INDICATOR.
21177
21178         * modules/inet_pton (configure.ac): Use
21179         gl_ARPA_INET_MODULE_INDICATOR.
21180
21181 2008-04-22  Jim Meyering  <meyering@redhat.com>
21182
21183         * modules/verify (License): Re-license as LGPLv2+.
21184
21185 2008-04-22  Simon Josefsson  <simon@josefsson.org>
21186
21187         * lib/sys_socket.in.h: Define setsockopt macro to cast fourth
21188         parameter to void* as per POSIX standard (MinGW uses char*).
21189
21190 2008-04-21  Bruno Haible  <bruno@clisp.org>
21191
21192         * lib/wctype.in.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
21193         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
21194         Define to replacements if REPLACE_ISWCNTRL is 1.
21195         * m4/wctype.m4 (gl_WCTYPE_H): Test whether the isw* functions work.
21196         If not, set WCTYPE_H to nonempty and REPLACE_ISWCNTRL to 1.
21197         * modules/wctype (Makefile.am): Substitute REPLACE_ISWCNTRL.
21198         * doc/posix-functions/iswalnum.texi: Mention the 'wctype' module and
21199         what it fixes.
21200         * doc/posix-functions/iswalpha.texi: Likewise.
21201         * doc/posix-functions/iswblank.texi: Likewise.
21202         * doc/posix-functions/iswcntrl.texi: Likewise.
21203         * doc/posix-functions/iswdigit.texi: Likewise.
21204         * doc/posix-functions/iswgraph.texi: Likewise.
21205         * doc/posix-functions/iswlower.texi: Likewise.
21206         * doc/posix-functions/iswprint.texi: Likewise.
21207         * doc/posix-functions/iswpunct.texi: Likewise.
21208         * doc/posix-functions/iswspace.texi: Likewise.
21209         * doc/posix-functions/iswupper.texi: Likewise.
21210         * doc/posix-functions/iswxdigit.texi: Likewise.
21211         Reported by Alain Guibert.
21212
21213 2008-04-21  Bruno Haible  <bruno@clisp.org>
21214
21215         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Fix typo in last commit.
21216         Patch by Alain Guibert.
21217
21218 2008-04-21  Bruno Haible  <bruno@clisp.org>
21219
21220         Fix test failures on mingw.
21221         * tests/test-xstrtol.c (print_no_progname): New function.
21222         (main): Install it in error_print_progname hook.
21223         * tests/test-xstrtol.sh: Convert CR/LF to NL in output.
21224         * tests/test-xstrtoimax.sh: Likewise.
21225         * tests/test-xstrtoumax.sh: Likewise.
21226
21227 2008-04-21  Bruno Haible  <bruno@clisp.org>
21228
21229         Fix test failure on mingw.
21230         * tests/test-argp-2.sh (func_compare): Remove CRs from sed's output.
21231
21232 2008-04-21  Bruno Haible  <bruno@clisp.org>
21233
21234         * lib/localename.c (SUBLANG_TIBETAN_PRC, SUBLANG_TIBETAN_BHUTAN):
21235         Actually assign a value.
21236
21237 2008-04-20  Bruno Haible  <bruno@clisp.org>
21238
21239         Fix conflict between modules 'canonicalize' and 'canonicalize-lgpl',
21240         take 2.
21241         * lib/canonicalize.c (canonicalize_file_name): Elide if the
21242         'canonicalize-lgpl' module is also used.
21243         * lib/canonicalize-lgpl.c: Undo last change.
21244         * modules/canonicalize-lgpl (configure.ac): Invoke gl_MODULE_INDICATOR.
21245
21246 2008-04-20  Bruno Haible  <bruno@clisp.org>
21247
21248         * lib/mkdir.c (mkdir): Undefine after the includes, not right after
21249         config.h. Provide _mkdir based fallback for mingw.
21250         * lib/sys_stat.in.h (mkdir): Define through an 'extern' declaration
21251         if REPLACE_MKDIR is 1. Otherwise, test for mingw directly.
21252         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Require
21253         gl_SYS_STAT_H_DEFAULTS. When doing the replacement, set REPLACE_MKDIR
21254         rather than defining mkdir in config.h.
21255         * m4/sys_stat_h.m4 (gl_SYS_STAT_MODULE_INDICATOR): New macro.
21256         (gl_SYS_STAT_H_DEFAULTS): New macro.
21257         (gl_HEADER_SYS_STAT_H): Require it. Don't set HAVE_DECL_MKDIR and
21258         HAVE_IO_H any more.
21259         * modules/sys_stat (Makefile.am): Substitute REPLACE_MKDIR instead of
21260         HAVE_DECL_MKDIR and HAVE_IO_H.
21261
21262 2008-04-20  Bruno Haible  <bruno@clisp.org>
21263
21264         * lib/isapipe.c: Port to native Windows platforms.
21265
21266 2008-04-20  Bruno Haible  <bruno@clisp.org>
21267
21268         * lib/gc-gnulib.c: Include <windows.h> before <wincrypt.h>.
21269
21270 2008-04-21  Eric Blake  <ebb9@byu.net>
21271
21272         Work around preprocessors that don't handle UINTMAX_MAX.
21273         * lib/memchr2.c (memchr2): Avoid embedded #if.
21274         Reported by Alain Guibert, fix suggested by Bruno Haible.
21275
21276 2008-04-21  Simon Josefsson  <simon@josefsson.org>
21277
21278         * doc/posix-functions/strftime.texi (strftime): Explain better
21279         Windows incompatibility.  Suggested by Micah Cowan
21280         <micah@cowan.name>.
21281
21282 2008-04-20  Bruno Haible  <bruno@clisp.org>
21283
21284         * modules/uniconv/u32-conv-to-enc (Depends-on): Add unistr/u32-mblen,
21285         unistr/u8-mblen.
21286
21287 2008-04-20  Bruno Haible  <bruno@clisp.org>
21288
21289         Fix test failure on platforms with non-GNU iconv.
21290         * lib/uniconv/u16-conv-to-enc.c (u16_to_u8_lenient): New function.
21291         (U_TO_U8): Use it, rather than u16_to_u8.
21292         * lib/uniconv/u-conv-to-enc.h (FUNC): Allow an incomplete sequence of
21293         units at the end of the input string.
21294         * modules/uniconv/u16-conv-to-enc (Depends-on): Update.
21295
21296 2008-04-20  Bruno Haible  <bruno@clisp.org>
21297
21298         * tests/uniconv/test-u8-conv-to-enc.c (main): Accept result == NULL
21299         when the resulting length is 0.
21300         * tests/uniconv/test-u16-conv-to-enc.c (main): Likewise.
21301
21302 2008-04-20  Bruno Haible  <bruno@clisp.org>
21303
21304         * m4/roundf.m4 (gl_FUNC_ROUNDF): Add test whether roundf actually
21305         works.
21306         * doc/posix-functions/roundf.texi: Mention roundf bug on mingw.
21307
21308 2008-04-20  Bruno Haible  <bruno@clisp.org>
21309
21310         * tests/test-tsearch.c (main): Don't use initstate if it is missing.
21311         * modules/tsearch-tests (configure.ac): Test for initstate function.
21312
21313 2008-04-20  Bruno Haible  <bruno@clisp.org>
21314
21315         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Also provided a substitute
21316         for nlink_t if missing.
21317         * tests/test-sys_stat.c: Check the existence of the nlink_t type.
21318
21319 2008-04-19  Bruno Haible  <bruno@clisp.org>
21320
21321         Work around snprintf bug on Linux libc5.
21322         * m4/printf.m4 (gl_SNPRINTF_SIZE1): New macro.
21323         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
21324         gl_SNPRINTF_SIZE1.
21325         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
21326         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Likewise. Replace snprintf if
21327         that test failed.
21328         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Likewise.
21329         * lib/vasnprintf.c (USE_SNPRINTF): Set to 0 on Linux libc5 systems.
21330         * modules/snprintf (Files): Add m4/printf.m4.
21331         * modules/vsnprintf (Files): Likewise.
21332         * doc/posix-functions/snprintf.texi: Document Linux libc5 problem.
21333         * doc/posix-functions/vsnprintf.texi: Likewise.
21334
21335 2008-04-19  Bruno Haible  <bruno@clisp.org>
21336
21337         * lib/vasnprintf.c (floorlog10l, floorlog10): Reduce maximum error
21338         from 0.0058 to less than 10^-7.
21339
21340 2008-04-19  Bruno Haible  <bruno@clisp.org>
21341
21342         Fix rounding when a precision is given.
21343         * lib/vasnprintf.c (is_borderline): New function.
21344         (VASNPRINTF): For %e and %g, consider replacing the digits 10....0 with
21345         9...9x.
21346         * tests/test-vasnprintf-posix.c (test_function): Test rounding with %f,
21347         %e, %g.
21348         * tests/test-vasprintf-posix.c (test_function): Likewise.
21349         * tests/test-snprintf-posix.h (test_function): Likewise.
21350         * tests/test-sprintf-posix.h (test_function): Likewise.
21351         * tests/test-fprintf-posix.h (test_function): Test rounding with %f.
21352         * tests/test-printf-posix.h (test_function): Likewise.
21353         * tests/test-printf-posix.output: Update.
21354         Reported by John Darrington <john@darrington.wattle.id.au> via
21355         Ben Pfaff <blp@cs.stanford.edu>.
21356
21357 2008-04-18  Simon Josefsson  <simon@josefsson.org>
21358
21359         * doc/posix-functions/strftime.texi (strftime): Clarify platform.
21360         Suggested by Bruno Haible <bruno@clisp.org>.
21361
21362 2008-04-17  Bruno Haible  <bruno@clisp.org>
21363
21364         * lib/lock.h (gl_lock_destroy, gl_rwlock_destroy,
21365         gl_recursive_lock_destroy): Provide no-op definitions for the dummy
21366         implementation.
21367         Patch by Bruce Merry <bmerry@gmail.com>.
21368
21369 2008-04-17  Simon Josefsson  <simon@josefsson.org>
21370
21371         * doc/posix-functions/strftime.texi (strftime): Mention that %e
21372         doesn't work under Windows.
21373
21374 2008-04-16  Bruno Haible  <bruno@clisp.org>
21375
21376         * lib/localename.c (LANG_MAORI, LANG_QUECHUA, LANG_SOTHO, LANG_UIGHUR):
21377         New macros.
21378         (SUBLANG_BOSNIAN_BOSNIA_HERZEGOVINA_LATIN,
21379         SUBLANG_BOSNIAN_BOSNIA_HERZEGOVINA_CYRILLIC,
21380         SUBLANG_CROATIAN_CROATIA, SUBLANG_CROATIAN_BOSNIA_HERZEGOVINA_LATIN,
21381         SUBLANG_MONGOLIAN_CYRILLIC_MONGOLIA, SUBLANG_MONGOLIAN_PRC,
21382         SUBLANG_QUECHUA_BOLIVIA, SUBLANG_QUECHUA_ECUADOR, SUBLANG_QUECHUA_PERU,
21383         SUBLANG_RUSSIAN_RUSSIA, SUBLANG_RUSSIAN_MOLDAVIA, SUBLANG_SPANISH_US,
21384         SUBLANG_TIBETAN_PRC, SUBLANG_TIBETAN_BHUTAN, SUBLANG_UIGHUR_PRC): New
21385         macros.
21386         (gl_locale_name_from_win32_LANGID): Refine code for Croatian/Bosnian,
21387         Mongolian, Russian, Spanish, Tibetan. Add code for Maori, Quechua,
21388         Northern Sotho, Uighur.
21389
21390 2008-04-16  Bruno Haible  <bruno@clisp.org>
21391
21392         * lib/localename.c (SUBLANG_SINDHI_INDIA): New macro.
21393         (SUBLANG_SINDHI_PAKISTAN): Change value from 1 to 2.
21394         (gl_locale_name_from_win32_LANGID): Fix code for Sindhi.
21395         Reported by Daniel Bergström <daniel@octocode.com>.
21396
21397 2007-12-25  KJK::Hyperion  <hackbunny@reactos.com>
21398             Bruno Haible  <bruno@clisp.org>
21399
21400         * lib/localename.c (gl_locale_name_canonicalize) [WIN32_NATIVE]: New
21401         function.
21402         (gl_locale_name_from_win32_LANGID, gl_locale_name_from_win32_LCID):
21403         New functions, mostly extracted from gl_locale_name_default.
21404         (gl_locale_name_default): Use gl_locale_name_from_win32_LCID.
21405
21406 2008-04-16  Eric Blake  <ebb9@byu.net>
21407
21408         Adjust strtod detection to catch glibc 2.7 bug.
21409         * m4/strtod.m4 (gl_FUNC_STRTOD): Test "nan()" behavior.
21410         Reported by John Gatewood Ham.
21411
21412 2008-04-16  Bruno Haible  <bruno@clisp.org>
21413
21414         Add tentative support for Linux libc5.
21415         * lib/fbufmode.c (fbufmode) [__GNU_LIBRARY__==1]: Reuse glibc2 code.
21416         * lib/fpurge.c (fpurge): Likewise.
21417         * lib/freadable.c (freadable): Likewise.
21418         * lib/freadahead.c (freadahead): Likewise.
21419         * lib/freading.c (freading): Likewise.
21420         * lib/freadptr.c (freadptr): Likewise.
21421         * lib/freadseek.c (freadptrinc): Likewise.
21422         * lib/fseeko.c (rpl_fseeko): Likewise.
21423         * lib/fseterr.c (fseterr): Likewise.
21424         * lib/fwritable.c (fwritable): Likewise.
21425         * lib/fwriting.c (fwriting): Likewise.
21426         Reported by Alain Guibert <alguibert+bts@free.fr>.
21427
21428 2008-04-15  Bruno Haible  <bruno@clisp.org>
21429
21430         * modules/mathl (configure.ac): Define module indicator.
21431
21432 2008-04-15  Bruno Haible  <bruno@clisp.org>
21433
21434         * lib/logl.c (logl): Remove unused variables.
21435
21436 2008-04-15  Bruno Haible  <bruno@clisp.org>
21437
21438         * lib/uniconv/u-conv-to-enc.h (FUNC): Fix return value when U_TO_U8
21439         fails.
21440
21441 2008-04-15  Bruno Haible  <bruno@clisp.org>
21442
21443         * lib/trim.c (trim2): Fix argument of isspace() macro.
21444
21445 2008-04-15  Paolo Bonzini  <bonzini@gnu.org>
21446
21447         * lib/tanl.c (kernel_tanl): Rename flag to invert, initialize it
21448         to 0.
21449         * lib/trigl.c (ieee754_rem_pio2l): Fix range checks.
21450
21451 2008-04-14  Bruno Haible  <bruno@clisp.org>
21452
21453         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Fix underquoting of
21454         AC_LANG_PROGRAM argument.
21455         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Likewise.
21456         * m4/gethrxtime.m4 (gl_ARITHMETIC_HRTIME_T): Likewise.
21457         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Likewise.
21458         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
21459         * m4/math_h.m4 (gl_MATH_H): Likewise.
21460         * m4/mbstate_t.m4 (AC_TYPE_MBSTATE_T): Likewise.
21461         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
21462         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
21463         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Likewise.
21464         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
21465         * m4/regex.m4 (gl_REGEX): Likewise.
21466         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Likewise.
21467         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET): Likewise.
21468         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
21469         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): Likewise.
21470         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
21471         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
21472         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
21473         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
21474
21475 2008-04-14  Jim Meyering  <meyering@redhat.com>
21476
21477         test-strtod: fix typos: s/abs/fabs/
21478         * tests/test-strtod.c (main): Use fabs, not narrowing-to-int "abs".
21479
21480 2008-04-13  Bruno Haible  <bruno@clisp.org>
21481
21482         Fix conflict between modules 'canonicalize' and 'canonicalize-lgpl'.
21483         * lib/canonicalize-lgpl.c: Elide the contents if the 'canonicalize'
21484         module is also used and while not building the reloc-wrapper.
21485
21486 2008-04-13  Bruno Haible  <bruno@clisp.org>
21487
21488         * tests/test-getaddrinfo.c (simple): Ignore EAI_NODATA error.
21489
21490 2008-04-13  Bruno Haible  <bruno@clisp.org>
21491
21492         Fix AIX compilation failure introduced on 2008-04-02.
21493         * tests/test-frexp.c (exp): Undefine before redefining.
21494         * tests/test-frexpl.c (exp): Likewise.
21495
21496 2008-04-13  Bruno Haible  <bruno@clisp.org>
21497
21498         Work around a HP-UX stdio bug.
21499         * tests/test-ftell.c (main): Disable the fseek/ftell test on HP-UX.
21500         * tests/test-ftello.c (main): Likewise.
21501         * doc/posix-functions/ftell.texi: Mention HP-UX bug.
21502         * doc/posix-functions/ftello.texi: Likewise.
21503
21504 2008-04-13  Bruno Haible  <bruno@clisp.org>
21505
21506         Make test-signbit pass on HP-UX/hppa.
21507         * tests/test-signbit.c (minus_zerol): New variable.
21508         (test_signbitl): Use it.
21509
21510 2008-04-13  Bruno Haible  <bruno@clisp.org>
21511
21512         Make truncl work on OSF/1 4.0.
21513         * m4/truncl.m4 (gl_FUNC_TRUNCL): Test whether truncl actually works.
21514         Set REPLACE_TRUNCL, not HAVE_DECL_TRUNCL.
21515         * lib/math.in.h (truncl): Test REPLACE_TRUNCL, not HAVE_DECL_TRUNCL.
21516         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_TRUNCL, not
21517         HAVE_DECL_TRUNCL.
21518         * modules/math (Makefile.am): Substitute REPLACE_TRUNCL, not
21519         HAVE_DECL_TRUNCL.
21520         * doc/posix-functions/truncl.texi: Document the OSF/1 4.0 problem.
21521
21522 2008-04-13  Bruno Haible  <bruno@clisp.org>
21523
21524         * lib/unictype.h: Remove trailing comma from enumeration definitions.
21525
21526 2008-04-13  Bruno Haible  <bruno@clisp.org>
21527
21528         * lib/count-one-bits.h (COUNT_ONE_BITS): Rewrite verification
21529         expression, so as to avoid HP-UX 11 cc compiler bug.
21530
21531 2008-04-13  Bruno Haible  <bruno@clisp.org>
21532
21533         * m4/regex.m4 (gl_PREREQ_REGEX): Also check for <libintl.h>.
21534
21535 2008-04-13  Bruno Haible  <bruno@clisp.org>
21536
21537         * lib/git-merge-changelog.c: Remove empty declaration outside of
21538         functions.
21539
21540 2008-04-13  Bruno Haible  <bruno@clisp.org>
21541
21542         * modules/quotearg-tests (Makefile.am): Define test_quotearg_LDADD.
21543
21544 2008-04-13  Bruno Haible  <bruno@clisp.org>
21545
21546         * doc/posix-headers/sys_socket.texi: Document the problem on EMX.
21547         * lib/sys_socket.in.h (SHUT_RD, SHUT_WR, SHUT_RDWR): Define if missing.
21548         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Replace <sys/socket.h>
21549         also if it exists but lacks definitions of the SHUT_* macros.
21550         * modules/sys_socket (Description): Update.
21551         Reported by Elbert Pol <e.pol@chello.nl>.
21552
21553 2008-04-13  Bruno Haible  <bruno@clisp.org>
21554
21555         * lib/localcharset.c (OS2): Don't redefine if already defined.
21556         Reported by Elbert Pol <e.pol@chello.nl>.
21557
21558 2008-04-13  Bruno Haible  <bruno@clisp.org>
21559
21560         * lib/binary-io.h [__EMX__]: Include <io.h>.
21561         Reported by Elbert Pol <e.pol@chello.nl>.
21562
21563 2008-04-12  Bruno Haible  <bruno@clisp.org>
21564
21565         * lib/fpucw.h: Enable the definitions also for x86_64.
21566         Needed for NetBSD/x86_64.
21567         Reported by Thomas Klausner <tk@giga.or.at>.
21568
21569 2008-04-12  Bruno Haible  <bruno@clisp.org>
21570
21571         * tests/test-strtod.c: Include isnand.h.
21572         (main): Use isnand instead of isnan.
21573         Reported by Jim Meyering.
21574
21575 2008-04-12  Bruno Haible  <bruno@clisp.org>
21576
21577         * m4/isnanf.m4 (gl_ISNANF_WORKS): Add a test for a special NaN.
21578         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
21579
21580 2008-04-12  Jim Meyering  <meyering@redhat.com>
21581
21582         * m4/math_h.m4 (gl_MATH_H): Fix typos.
21583
21584 2008-04-12  Bruno Haible  <bruno@clisp.org>
21585
21586         * lib/freadptr.c (freadptr) [__EMX__]: Fix wrong assertion.
21587         Reported by Elbert Pol <e.pol@chello.nl>.
21588
21589 2008-04-12  Eric Blake  <ebb9@byu.net>
21590
21591         Work around Solaris 10 math.h bug.
21592         * m4/math_h.m4 (gl_MATH_H): Check for bug.
21593         (gl_MATH_H_DEFAULTS): Set up default.
21594         * modules/math (Makefile.am): Replace new indicators.
21595         * lib/math.in.h (NAN, HUGE_VAL): Provide replacements.
21596         * tests/test-math.c (main): Test this.
21597         * m4/strtod.m4 (gl_FUNC_STRTOD): Don't rely on HUGE_VAL.
21598         * doc/posix-headers/math.texi (math.h): Mention bug.
21599         Reported by Nelson H. F. Beebe and Jim Meyering.
21600
21601 2008-04-11  Bruno Haible  <bruno@clisp.org>
21602
21603         Adapt to future versions of Apple GCC.
21604         * lib/argp-fmtstream.h (ARGP_FS_EI): Don't test __GNUC_GNU_INLINE__.
21605         Reported by Peter O'Gorman <peter@pogma.com>.
21606
21607 2008-04-11  Bruno Haible  <bruno@clisp.org>
21608
21609         * tests/test-getaddrinfo.c (simple): Ignore EAI_NONAME error.
21610
21611 2008-04-11  Bruno Haible  <bruno@clisp.org>
21612
21613         * modules/strsignal-tests (Makefile.am): Define test_strsignal_LDADD.
21614
21615         * modules/getaddrinfo-tests (Makefile.am): Define
21616         test_getaddrinfo_LDADD.
21617
21618 2008-04-11  Bruno Haible  <bruno@clisp.org>
21619
21620         * lib/strsignal.c (_sys_siglist): Don't declare if already declared.
21621         (init): Fix syntax error.
21622         * m4/strsignal.m4 (gl_PREREQ_STRSIGNAL): Check whether _sys_siglist
21623         is declared.
21624
21625 2008-04-11  Bruno Haible  <bruno@clisp.org>
21626
21627         * lib/glob.c: Include <stdbool.h>. Needed at least with IRIX cc.
21628         * modules/glob (Depends-on): Add stdbool.
21629
21630 2008-04-11  Bruno Haible  <bruno@clisp.org>
21631
21632         * lib/trim.c: Include <string.h>.
21633
21634 2008-04-11  Eric Blake  <ebb9@byu.net>
21635
21636         Avoid compile failure on OS/2.
21637         * lib/regex_internal.h (internal_function): Disable optimization
21638         on OS/2 (__EMX__), where it caused compiler error.
21639         Reported by Elbert Pol.
21640
21641 2008-04-11  Bruno Haible  <bruno@clisp.org>
21642
21643         Flush the standard error stream before aborting. Needed on mingw.
21644         * tests/test-argmatch.c (ASSERT): Call fflush(stderr) before abort().
21645         * tests/test-array_list.c (ASSERT): Likewise.
21646         * tests/test-array_oset.c (ASSERT): Likewise.
21647         * tests/test-avltree_list.c (ASSERT): Likewise.
21648         * tests/test-avltree_oset.c (ASSERT): Likewise.
21649         * tests/test-avltreehash_list.c (ASSERT): Likewise.
21650         * tests/test-binary-io.c (ASSERT): Likewise.
21651         * tests/test-byteswap.c (ASSERT): Likewise.
21652         * tests/test-c-ctype.c (ASSERT): Likewise.
21653         * tests/test-c-strcasecmp.c (ASSERT): Likewise.
21654         * tests/test-c-strcasestr.c (ASSERT): Likewise.
21655         * tests/test-c-strncasecmp.c (ASSERT): Likewise.
21656         * tests/test-c-strstr.c (ASSERT): Likewise.
21657         * tests/test-canonicalize-lgpl.c (ASSERT): Likewise.
21658         * tests/test-canonicalize.c (ASSERT): Likewise.
21659         * tests/test-carray_list.c (ASSERT): Likewise.
21660         * tests/test-ceilf1.c (ASSERT): Likewise.
21661         * tests/test-ceilf2.c (ASSERT): Likewise.
21662         * tests/test-ceill.c (ASSERT): Likewise.
21663         * tests/test-count-one-bits.c (ASSERT): Likewise.
21664         * tests/test-fbufmode.c (ASSERT): Likewise.
21665         * tests/test-fflush2.c (ASSERT): Likewise.
21666         * tests/test-floorf1.c (ASSERT): Likewise.
21667         * tests/test-floorf2.c (ASSERT): Likewise.
21668         * tests/test-floorl.c (ASSERT): Likewise.
21669         * tests/test-fopen.c (ASSERT): Likewise.
21670         * tests/test-fpending.c (ASSERT): Likewise.
21671         * tests/test-fprintf-posix.c (ASSERT): Likewise.
21672         * tests/test-fpurge.c (ASSERT): Likewise.
21673         * tests/test-freadable.c (ASSERT): Likewise.
21674         * tests/test-freadahead.c (ASSERT): Likewise.
21675         * tests/test-freading.c (ASSERT): Likewise.
21676         * tests/test-freadptr.c (ASSERT): Likewise.
21677         * tests/test-freadptr2.c (ASSERT): Likewise.
21678         * tests/test-freadseek.c (ASSERT): Likewise.
21679         * tests/test-freopen.c (ASSERT): Likewise.
21680         * tests/test-frexp.c (ASSERT): Likewise.
21681         * tests/test-frexpl.c (ASSERT): Likewise.
21682         * tests/test-fseek.c (ASSERT): Likewise.
21683         * tests/test-fseeko.c (ASSERT): Likewise.
21684         * tests/test-fstrcmp.c (ASSERT): Likewise.
21685         * tests/test-ftell.c (ASSERT): Likewise.
21686         * tests/test-ftello.c (ASSERT): Likewise.
21687         * tests/test-func.c (ASSERT): Likewise.
21688         * tests/test-fwritable.c (ASSERT): Likewise.
21689         * tests/test-fwriting.c (ASSERT): Likewise.
21690         * tests/test-getdelim.c (ASSERT): Likewise.
21691         * tests/test-getline.c (ASSERT): Likewise.
21692         * tests/test-i-ring.c (ASSERT): Likewise.
21693         * tests/test-iconv-utf.c (ASSERT): Likewise.
21694         * tests/test-iconv.c (ASSERT): Likewise.
21695         * tests/test-isfinite.c (ASSERT): Likewise.
21696         * tests/test-isnand.c (ASSERT): Likewise.
21697         * tests/test-isnanf.c (ASSERT): Likewise.
21698         * tests/test-isnanl.h (ASSERT): Likewise.
21699         * tests/test-ldexpl.c (ASSERT): Likewise.
21700         * tests/test-linked_list.c (ASSERT): Likewise.
21701         * tests/test-linkedhash_list.c (ASSERT): Likewise.
21702         * tests/test-localename.c (ASSERT): Likewise.
21703         * tests/test-lseek.c (ASSERT): Likewise.
21704         * tests/test-mbscasecmp.c (ASSERT): Likewise.
21705         * tests/test-mbscasestr1.c (ASSERT): Likewise.
21706         * tests/test-mbscasestr2.c (ASSERT): Likewise.
21707         * tests/test-mbscasestr3.c (ASSERT): Likewise.
21708         * tests/test-mbscasestr4.c (ASSERT): Likewise.
21709         * tests/test-mbschr.c (ASSERT): Likewise.
21710         * tests/test-mbscspn.c (ASSERT): Likewise.
21711         * tests/test-mbsncasecmp.c (ASSERT): Likewise.
21712         * tests/test-mbspbrk.c (ASSERT): Likewise.
21713         * tests/test-mbspcasecmp.c (ASSERT): Likewise.
21714         * tests/test-mbsrchr.c (ASSERT): Likewise.
21715         * tests/test-mbsspn.c (ASSERT): Likewise.
21716         * tests/test-mbsstr1.c (ASSERT): Likewise.
21717         * tests/test-mbsstr2.c (ASSERT): Likewise.
21718         * tests/test-mbsstr3.c (ASSERT): Likewise.
21719         * tests/test-memchr2.c (ASSERT): Likewise.
21720         * tests/test-memmem.c (ASSERT): Likewise.
21721         * tests/test-open.c (ASSERT): Likewise.
21722         * tests/test-printf-frexp.c (ASSERT): Likewise.
21723         * tests/test-printf-frexpl.c (ASSERT): Likewise.
21724         * tests/test-printf-posix.c (ASSERT): Likewise.
21725         * tests/test-quotearg.c (ASSERT): Likewise.
21726         * tests/test-rbtree_list.c (ASSERT): Likewise.
21727         * tests/test-rbtree_oset.c (ASSERT): Likewise.
21728         * tests/test-rbtreehash_list.c (ASSERT): Likewise.
21729         * tests/test-round1.c (ASSERT): Likewise.
21730         * tests/test-roundf1.c (ASSERT): Likewise.
21731         * tests/test-roundl.c (ASSERT): Likewise.
21732         * tests/test-signbit.c (ASSERT): Likewise.
21733         * tests/test-sleep.c (ASSERT): Likewise.
21734         * tests/test-snprintf-posix.c (ASSERT): Likewise.
21735         * tests/test-snprintf.c (ASSERT): Likewise.
21736         * tests/test-sprintf-posix.c (ASSERT): Likewise.
21737         * tests/test-stat-time.c (ASSERT): Likewise.
21738         * tests/test-strcasestr.c (ASSERT): Likewise.
21739         * tests/test-strerror.c (ASSERT): Likewise.
21740         * tests/test-striconv.c (ASSERT): Likewise.
21741         * tests/test-striconveh.c (ASSERT): Likewise.
21742         * tests/test-striconveha.c (ASSERT): Likewise.
21743         * tests/test-strsignal.c (ASSERT): Likewise.
21744         * tests/test-strstr.c (ASSERT): Likewise.
21745         * tests/test-strtod.c (ASSERT): Likewise.
21746         * tests/test-trunc1.c (ASSERT): Likewise.
21747         * tests/test-trunc2.c (ASSERT): Likewise.
21748         * tests/test-truncf1.c (ASSERT): Likewise.
21749         * tests/test-truncf2.c (ASSERT): Likewise.
21750         * tests/test-truncl.c (ASSERT): Likewise.
21751         * tests/test-vasnprintf-posix.c (ASSERT): Likewise.
21752         * tests/test-vasnprintf-posix2.c (ASSERT): Likewise.
21753         * tests/test-vasnprintf.c (ASSERT): Likewise.
21754         * tests/test-vasprintf-posix.c (ASSERT): Likewise.
21755         * tests/test-vasprintf.c (ASSERT): Likewise.
21756         * tests/test-vfprintf-posix.c (ASSERT): Likewise.
21757         * tests/test-vprintf-posix.c (ASSERT): Likewise.
21758         * tests/test-vsnprintf-posix.c (ASSERT): Likewise.
21759         * tests/test-vsnprintf.c (ASSERT): Likewise.
21760         * tests/test-vsprintf-posix.c (ASSERT): Likewise.
21761         * tests/test-wcwidth.c (ASSERT): Likewise.
21762         * tests/test-xfprintf-posix.c (ASSERT): Likewise.
21763         * tests/test-xprintf-posix.c (ASSERT): Likewise.
21764         * tests/test-xvasprintf.c (ASSERT): Likewise.
21765         * tests/uniconv/test-u16-conv-from-enc.c (ASSERT): Likewise.
21766         * tests/uniconv/test-u16-conv-to-enc.c (ASSERT): Likewise.
21767         * tests/uniconv/test-u16-strconv-from-enc.c (ASSERT): Likewise.
21768         * tests/uniconv/test-u16-strconv-to-enc.c (ASSERT): Likewise.
21769         * tests/uniconv/test-u32-conv-from-enc.c (ASSERT): Likewise.
21770         * tests/uniconv/test-u32-conv-to-enc.c (ASSERT): Likewise.
21771         * tests/uniconv/test-u32-strconv-from-enc.c (ASSERT): Likewise.
21772         * tests/uniconv/test-u32-strconv-to-enc.c (ASSERT): Likewise.
21773         * tests/uniconv/test-u8-conv-from-enc.c (ASSERT): Likewise.
21774         * tests/uniconv/test-u8-conv-to-enc.c (ASSERT): Likewise.
21775         * tests/uniconv/test-u8-strconv-from-enc.c (ASSERT): Likewise.
21776         * tests/uniconv/test-u8-strconv-to-enc.c (ASSERT): Likewise.
21777         * tests/unictype/test-bidi_byname.c (ASSERT): Likewise.
21778         * tests/unictype/test-bidi_name.c (ASSERT): Likewise.
21779         * tests/unictype/test-bidi_of.c (ASSERT): Likewise.
21780         * tests/unictype/test-bidi_test.c (ASSERT): Likewise.
21781         * tests/unictype/test-block_list.c (ASSERT): Likewise.
21782         * tests/unictype/test-block_of.c (ASSERT): Likewise.
21783         * tests/unictype/test-block_test.c (ASSERT): Likewise.
21784         * tests/unictype/test-categ_and.c (ASSERT): Likewise.
21785         * tests/unictype/test-categ_and_not.c (ASSERT): Likewise.
21786         * tests/unictype/test-categ_byname.c (ASSERT): Likewise.
21787         * tests/unictype/test-categ_name.c (ASSERT): Likewise.
21788         * tests/unictype/test-categ_none.c (ASSERT): Likewise.
21789         * tests/unictype/test-categ_of.c (ASSERT): Likewise.
21790         * tests/unictype/test-categ_or.c (ASSERT): Likewise.
21791         * tests/unictype/test-categ_test_withtable.c (ASSERT): Likewise.
21792         * tests/unictype/test-combining.c (ASSERT): Likewise.
21793         * tests/unictype/test-decdigit.c (ASSERT): Likewise.
21794         * tests/unictype/test-digit.c (ASSERT): Likewise.
21795         * tests/unictype/test-mirror.c (ASSERT): Likewise.
21796         * tests/unictype/test-numeric.c (ASSERT): Likewise.
21797         * tests/unictype/test-pr_byname.c (ASSERT): Likewise.
21798         * tests/unictype/test-pr_test.c (ASSERT): Likewise.
21799         * tests/unictype/test-predicate-part1.h (ASSERT): Likewise.
21800         * tests/unictype/test-scripts.c (ASSERT): Likewise.
21801         * tests/unictype/test-sy_c_ident.c (ASSERT): Likewise.
21802         * tests/unictype/test-sy_java_ident.c (ASSERT): Likewise.
21803         * tests/unistdio/test-u16-asnprintf1.c (ASSERT): Likewise.
21804         * tests/unistdio/test-u16-vasnprintf1.c (ASSERT): Likewise.
21805         * tests/unistdio/test-u16-vasnprintf2.c (ASSERT): Likewise.
21806         * tests/unistdio/test-u16-vasnprintf3.c (ASSERT): Likewise.
21807         * tests/unistdio/test-u16-vasprintf1.c (ASSERT): Likewise.
21808         * tests/unistdio/test-u16-vsnprintf1.c (ASSERT): Likewise.
21809         * tests/unistdio/test-u16-vsprintf1.c (ASSERT): Likewise.
21810         * tests/unistdio/test-u32-asnprintf1.c (ASSERT): Likewise.
21811         * tests/unistdio/test-u32-vasnprintf1.c (ASSERT): Likewise.
21812         * tests/unistdio/test-u32-vasnprintf2.c (ASSERT): Likewise.
21813         * tests/unistdio/test-u32-vasnprintf3.c (ASSERT): Likewise.
21814         * tests/unistdio/test-u32-vasprintf1.c (ASSERT): Likewise.
21815         * tests/unistdio/test-u32-vsnprintf1.c (ASSERT): Likewise.
21816         * tests/unistdio/test-u32-vsprintf1.c (ASSERT): Likewise.
21817         * tests/unistdio/test-u8-asnprintf1.c (ASSERT): Likewise.
21818         * tests/unistdio/test-u8-vasnprintf1.c (ASSERT): Likewise.
21819         * tests/unistdio/test-u8-vasnprintf2.c (ASSERT): Likewise.
21820         * tests/unistdio/test-u8-vasnprintf3.c (ASSERT): Likewise.
21821         * tests/unistdio/test-u8-vasprintf1.c (ASSERT): Likewise.
21822         * tests/unistdio/test-u8-vsnprintf1.c (ASSERT): Likewise.
21823         * tests/unistdio/test-u8-vsprintf1.c (ASSERT): Likewise.
21824         * tests/unistdio/test-ulc-asnprintf1.c (ASSERT): Likewise.
21825         * tests/unistdio/test-ulc-vasnprintf1.c (ASSERT): Likewise.
21826         * tests/unistdio/test-ulc-vasnprintf2.c (ASSERT): Likewise.
21827         * tests/unistdio/test-ulc-vasnprintf3.c (ASSERT): Likewise.
21828         * tests/unistdio/test-ulc-vasprintf1.c (ASSERT): Likewise.
21829         * tests/unistdio/test-ulc-vsnprintf1.c (ASSERT): Likewise.
21830         * tests/unistdio/test-ulc-vsprintf1.c (ASSERT): Likewise.
21831         * tests/uniwidth/test-u16-strwidth.c (ASSERT): Likewise.
21832         * tests/uniwidth/test-u16-width.c (ASSERT): Likewise.
21833         * tests/uniwidth/test-u32-strwidth.c (ASSERT): Likewise.
21834         * tests/uniwidth/test-u32-width.c (ASSERT): Likewise.
21835         * tests/uniwidth/test-u8-strwidth.c (ASSERT): Likewise.
21836         * tests/uniwidth/test-u8-width.c (ASSERT): Likewise.
21837         * tests/uniwidth/test-uc_width.c (ASSERT): Likewise.
21838         Reported by Eric Blake.
21839
21840 2008-04-11  Bruno Haible  <bruno@clisp.org>
21841
21842         * lib/wchar.in.h: Tweak comment.
21843
21844 2008-04-11  Bruno Haible  <bruno@clisp.org>
21845
21846         Fix __GNUC_STDC_INLINE__ predefine with Apple GCC on MacOS X 10.5.
21847         * gnulib-tool (func_emit_initmacro_start): Emit an invocation of
21848         gl_COMMON.
21849         * m4/gnulib-common.m4 (gl_COMMON, gl_COMMON_BODY): New macros.
21850
21851 2008-04-11  Bruno Haible  <bruno@clisp.org>
21852
21853         * modules/git-merge-changelog (git_merge_changelog_LDADD): Add LIBINTL.
21854
21855 2008-04-11  Simon Josefsson  <simon@josefsson.org>
21856
21857         * lib/gc-gnulib.c: On Windows, use CryptGenRandom from CSP instead
21858         of attempting to use non-existing /dev/*random.  Based on patch
21859         from Adam Strzelecki <ono@java.pl> in
21860         <http://lists.gnu.org/archive/html/help-gsasl/2008-02/msg00000.html>.
21861
21862 2008-04-08  Bruno Haible  <bruno@clisp.org>
21863
21864         Add tentative support for emx+gcc.
21865         * lib/fbufmode.c (fbufmode) [__EMX__]: Add conditional code.
21866         * lib/fpurge.c (fpurge): Likewise.
21867         * lib/freadable.c (freadable): Likewise.
21868         * lib/freadahead.c (freadahead): Likewise.
21869         * lib/freading.c (freading): Likewise.
21870         * lib/freadptr.c (freadptr): Likewise.
21871         * lib/freadseek.c (freadptrinc): Likewise.
21872         * lib/fseeko.c (rpl_fseeko): Likewise.
21873         * lib/fseterr.c (fseterr): Likewise.
21874         * lib/fwritable.c (fwritable): Likewise.
21875         * lib/fwriting.c (fwriting): Likewise.
21876         * m4/fpending.m4 (gl_FUNC_FPENDING): Add a variant for emx+gcc.
21877
21878 2008-04-09  Eric Blake  <ebb9@byu.net>
21879
21880         Avoid some autoconf warnings.
21881         * m4/regex.m4 (gl_REGEX): s/AC_HELP_STRING/AS_HELP_STRING/.
21882         * m4/acl.m4 (gl_FUNC_ACL): Likewise.
21883         * m4/afs.m4 (gl_AFS): Likewise.
21884         * m4/gc-random.m4 (gl_GC_RANDOM): Likewise.
21885         * m4/include_next.m4 (gl_INCLUDE_NEXT): s/AC_FOREACH/m4_foreach_w/.
21886         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
21887         * m4/stdint.m4 (gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED)
21888         (gl_INTEGER_TYPE_SUFFIX): Likewise.
21889         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE)
21890         (AC_CHECK_DECLS_ONCE): Likewise.
21891         Rename file...
21892         * m4/onceonly.m4: ...to this, and delete 2.54 variant, now that
21893         gnulib-tool requires autoconf 2.59 or better.
21894         * gnulib-tool (func_get_filelist): s/\(onceonly\)_2_57.m4/\1.m4/.
21895
21896 2008-04-08  Eric Blake  <ebb9@byu.net>
21897
21898         Use 'git describe --match' if present (added in git 1.5.5).
21899         * build-aux/git-version-gen: Limit result to tags that match 'v*'
21900         if possible.
21901
21902 2008-04-08  Bruno Haible  <bruno@clisp.org>
21903
21904         Add tentative support for OpenServer.
21905         * lib/fbufmode.c (fbufmode): Add conditional define for _flag, _base,
21906         _ptr, _cnt.
21907         * lib/fpurge.c (fpurge): Likewise.
21908         * lib/freadable.c (freadable): Likewise.
21909         * lib/freadahead.c (freadahead): Likewise.
21910         * lib/freading.c (freading): Likewise.
21911         * lib/freadptr.c (freadptr): Likewise.
21912         * lib/freadseek.c (freadptrinc): Likewise.
21913         * lib/fseeko.c (rpl_fseeko): Likewise.
21914         * lib/fseterr.c (fseterr): Likewise.
21915         * lib/fwritable.c (fwritable): Likewise.
21916         * lib/fwriting.c (fwriting): Likewise.
21917         Reported by Roger Cornelius <rac@tenzing.org> and
21918         Brian K. White <brian@aljex.com>.
21919
21920 2008-04-06  Jim Meyering  <meyering@redhat.com>
21921
21922         * gnulib-tool (func_add_or_update): s/backuped/backed up/ in diagnostic
21923
21924 2008-04-06  Bruno Haible  <bruno@clisp.org>
21925
21926         Avoid possible error with non-ASCII bytes in UTF-8 locales.
21927         * tests/test-fprintf-posix.sh: Use "LC_ALL=C tr" instead of "tr".
21928         * tests/test-printf-posix.sh: Likewise.
21929         * tests/test-vfprintf-posix.sh: Likewise.
21930         * tests/test-vprintf-posix.sh: Likewise.
21931         * tests/test-xprintf-posix.sh: Likewise.
21932
21933 2008-04-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
21934
21935         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT): Fix quoting,
21936         hide error from 'ls', needed on OS/2.
21937         Report by Elbert Pol <elbert.pol@gmail.com>.
21938
21939 2008-04-04  Eric Blake  <ebb9@byu.net>
21940
21941         Make test-fseeko.c failures meaningful.
21942         * tests/test-fseeko.c: Print line number on failure.
21943         * tests/test-fseek.c: Likewise.
21944         Reported by Nelson H. F. Beebe.
21945
21946         Improve strtod bug detection check.
21947         * m4/strtod.m4 (gl_FUNC_STRTOD): Also check for hex-float parsing,
21948         required for Solaris 10.
21949         Reported by Bob Friesenhahn and Nelson H. F. Beebe.
21950
21951 2008-04-04  Bruno Haible  <bruno@clisp.org>
21952
21953         * modules/relocatable-prog-wrapper (Files): Add m4/environ.m4. Needed
21954         by m4/setenv.m4.
21955
21956 2008-04-03  Eric Blake  <ebb9@byu.net>
21957
21958         Ensure sane .version contents.
21959         * top/GNUmakefile (_dummy): Also delete .version when rebuilding
21960         version string.
21961         * build-aux/git-version-gen: Improve documentation.
21962
21963         Make GNU make output nicer.
21964         * top/GNUmakefile [!_have-Makefile]: Add dependency on
21965         MAKECMDGOALS to enforce message for all command line targets.  Set
21966         srcdir for use in maint.mk.
21967
21968         Another maintainer tweak.
21969         * top/GNUmakefile (_is-dist-target): Allow maintainer-distcheck as
21970         a target that regenerates version.
21971
21972 2008-04-03  Jim Meyering  <meyering@redhat.com>
21973
21974         vc-list-files: don't cause coreutils "make po-check" failure
21975         * build-aux/vc-list-files: Skip postprocessing when $2 is '.'
21976
21977 2008-04-03  Eric Blake  <ebb9@byu.net>
21978
21979         Allow VPATH usage of vc-list-files.
21980         * build-aux/vc-list-files (scriptversion): Add timestamp.
21981         (options): Add --help, --version, -C.
21982         (CVS): Support installed cvsu.
21983
21984 2008-04-02  Bruno Haible  <bruno@clisp.org>
21985
21986         Avoid some "statement with no effect" warnings from gcc.
21987         * tests/test-wctype.c (main): Explicitly ignore unused values.
21988         Reported by Jim Meyering.
21989
21990 2008-04-02  Jim Meyering  <meyering@redhat.com>
21991
21992         Avoid some warnings from "gcc -Wshadow".
21993         * tests/test-frexp.c (exp): Define to a different identifier.
21994         * tests/test-frexpl.c (exp): Likewise.
21995
21996 2008-04-03  Jim Meyering  <meyering@redhat.com>
21997
21998         bootstrap: remove dangling *.[ch] symlinks from lib
21999         * build-aux/bootstrap [dangling symlink removal]: Move find's
22000         -depth option to precede all others, to avoid a warning.
22001         Remove *.[ch] files too, and from "$source_base" (usually lib/).
22002
22003 2008-04-02  Bruno Haible  <bruno@clisp.org>
22004
22005         Avoid some warnings from "gcc -Wshadow".
22006         * tests/tests-vfprintf-posix.c (my_fprintf): Move after test_function.
22007         * tests/tests-vprintf-posix.c (my_printf): Move after test_function.
22008         * tests/tests-vsnprintf-posix.c (my_snprintf): Move after test_function.
22009         * tests/tests-vsprintf-posix.c (my_sprintf): Move after test_function.
22010         Reported by Jim Meyering.
22011
22012 2008-04-01  Bruno Haible  <bruno@clisp.org>
22013
22014         Fix test to work on IRIX 6.5 with cc.
22015         * tests/test-math.c (numeric_equal): New function.
22016         (main): Use it.
22017
22018 2008-04-01  Bruno Haible  <bruno@clisp.org>
22019
22020         * doc/posix-headers/math.texi: Refine documentation of NAN problem.
22021
22022 2008-04-01  Bruno Haible  <bruno@clisp.org>
22023
22024         * tests/test-vasnprintf-posix.c: Include nan.h instead of <math.h>.
22025         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
22026         * modules/vasnprintf-posix-tests (Files): Add tests/nan.h.
22027         (Depends-on): Remove math.
22028
22029         * tests/test-vasprintf-posix.c: Include nan.h instead of <math.h>.
22030         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
22031         * modules/vasprintf-posix-tests (Files): Add tests/nan.h.
22032         (Depends-on): Remove math.
22033
22034         * tests/test-snprintf-posix.h: Include nan.h instead of <math.h>.
22035         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
22036         * modules/snprintf-posix-tests (Files): Add tests/nan.h.
22037         (Depends-on): Remove math.
22038         * modules/vsnprintf-posix-tests (Files): Add tests/nan.h.
22039         (Depends-on): Remove math.
22040
22041         * tests/test-sprintf-posix.h: Include nan.h instead of <math.h>.
22042         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
22043         * modules/sprintf-posix-tests (Files): Add tests/nan.h.
22044         (Depends-on): Remove math.
22045         * modules/vsprintf-posix-tests (Files): Add tests/nan.h.
22046         (Depends-on): Remove math.
22047
22048         * tests/test-round1.c: Include nan.h.
22049         (main): Use NaNd instead of NAN.
22050         * modules/round-tests (Files): Add tests/nan.h.
22051
22052         * tests/test-trunc1.c: Include nan.h.
22053         (main): Use NaNd instead of NAN.
22054         * modules/trunc-tests (Files): Add tests/nan.h.
22055
22056         * tests/test-roundf1.c: Include nan.h.
22057         (main): Use NaNf instead of NAN.
22058         * modules/roundf-tests (Files): Add tests/nan.h.
22059
22060         * tests/test-truncf1.c: Include nan.h.
22061         (main): Use NaNf instead of NAN.
22062         * modules/truncf-tests (Files): Add tests/nan.h.
22063
22064         * tests/test-ceilf1.c: Include nan.h.
22065         (main): Use NaNf instead of NAN.
22066         * modules/ceilf-tests (Files): Add tests/nan.h.
22067
22068         * tests/test-floorf1.c: Include nan.h.
22069         (main): Use NaNf instead of NAN.
22070         * modules/floorf-tests (Files): Add tests/nan.h.
22071
22072         * tests/test-isnanf.c: Include nan.h instead of <math.h>.
22073         (main): Use NaNf instead of NAN.
22074         * modules/isnanf-nolibm-tests (Files): Add tests/nan.h.
22075
22076         * tests/test-isnand.c: Include nan.h instead of <math.h>.
22077         (main): Use NaNd instead of NAN.
22078         * modules/isnand-nolibm-tests (Files): Add tests/nan.h.
22079
22080         * tests/test-frexp.c: Include nan.h.
22081         (main): Use NaNd instead of NAN.
22082         * modules/frexp-tests (Files): Add tests/nan.h.
22083
22084         * lib/isnan.c: Don't include <math.h>.
22085         (FUNC): Don't use NAN macro.
22086         * modules/isnand-nolibm (Depends-on): Remove math.
22087         * modules/isnanf-nolibm (Depends-on): Remove math.
22088         * modules/isnanl (Depends-on): Remove math.
22089         * modules/isnanl-nolibm (Depends-on): Remove math.
22090
22091         * tests/nan.h: New file.
22092
22093 2008-04-01  Eric Blake  <ebb9@byu.net>
22094
22095         Fix typos.
22096         * tests/test-strtod.c (main): s/FLT_/DBL_/ for minimum and epsilon
22097         values to be the right type.
22098
22099         For now, cater to gnulib strtod inaccuracies.
22100         * tests/test-strtod.c (main): Allow 1-ulp error on expected
22101         fractional results.  While not as nice from a QoI perspective, it
22102         is a quicker patch than correctly implementing decimal to binary
22103         rounding.
22104
22105 2008-03-31  Eric Blake  <ebb9@byu.net>
22106
22107         Guarantee a definition of NAN.
22108         * lib/math.in.h (NAN): Define if missing.
22109         * tests/test-math.c (main): Test it.
22110         * doc/posix-headers/math.texi (math.h): Document this.
22111         * lib/isnan.c (rpl_isnand): Use it.
22112         * tests/test-ceilf1.c (NaN): Delete, and use NAN instead.
22113         * tests/test-floorf1.c (NaN): Likewise.
22114         * tests/test-frexp.c (NaN): Likewise.
22115         * tests/test-isnand.c (NaN): Likewise.
22116         * tests/test-isnanf.c (NaN): Likewise.
22117         * tests/test-round1.c (NaN): Likewise.
22118         * tests/test-roundf1.c (NaN): Likewise.
22119         * tests/test-snprintf-posix.h (NaN): Likewise.
22120         * tests/test-sprintf-posix.h (NaN): Likewise.
22121         * tests/test-trunc1.c (NaN): Likewise.
22122         * tests/test-truncf1.c (NaN): Likewise.
22123         * tests/test-vasnprintf-posix.c (NaN): Likewise.
22124         * tests/test-vasprintf-posix.c (NaN): Likewise.
22125         * modules/isnand-nolibm (Depends-on): Add math.
22126         * modules/isnanf-nolibm (Depends-on): Likewise.
22127         * modules/isnanl (Depends-on): Likewise.
22128         * modules/isnanl-nolibm (Depends-on): Likewise.
22129         * modules/snprintf-posix-tests (Depends-on): Likewise.
22130         * modules/sprintf-posix-tests (Depends-on): Likewise.
22131         * modules/vsnprintf-posix-tests (Depends-on): Likewise.
22132         * modules/vsprintf-posix-tests (Depends-on): Likewise.
22133         * modules/vasnprintf-posix-tests (Depends-on): Likewise.
22134         * modules/vasprintf-posix-tests (Depends-on): Likewise.
22135
22136 2008-03-31  Bruno Haible  <bruno@clisp.org>
22137
22138         * tests/test-strtod.c (main): Update results for OSF/1 platforms.
22139         * doc/posix-functions/strtod.texi: Likewise.
22140
22141 2008-03-31  Bruno Haible  <bruno@clisp.org>
22142
22143         * tests/test-strtod.c (main): Don't use C99 syntax.
22144
22145 2008-03-31  Bruno Haible  <bruno@clisp.org>
22146
22147         * tests/test-strtod.c (main): Don't test NAN macro. Needed for Solaris.
22148         Reported by Eric Blake.
22149
22150 2008-03-31  Jim Meyering  <meyering@redhat.com>
22151
22152         Don't compare actual signbit return values.
22153         * tests/test-strtod.c (main): Rather, compare only their
22154         zero/non-zero nature.
22155
22156 2008-03-31  Eric Blake  <ebb9@byu.net>
22157
22158         More strtod documentation.
22159         * doc/posix-functions/strtod.texi (strtod): Interpret more test
22160         failures as distinct bugs.
22161
22162 2008-03-30  Paul Eggert  <eggert@cs.ucla.edu>
22163
22164         * lib/wchar.in.h [defined __need_mbstate_t]: Just include <wchar.h>.
22165         Problem reported by Erik Benada in
22166         <http://lists.gnu.org/archive/html/bug-gnulib/2008-03/msg00249.html>.
22167
22168 2008-03-30  Bruno Haible  <bruno@clisp.org>
22169
22170         * tests/test-strtod.c: Add comments about which assertion fails on which
22171         platform.
22172         * doc/posix-functions/strtod.texi: Add info about many more platforms.
22173
22174 2008-03-30  Eric Blake  <ebb9@byu.net>
22175
22176         Test signbit behavior on zeros.
22177         * tests/test-signbit.c (test_signbitf): Add tests for zero.
22178         (test_signbitd, test_signbitl): Likewise.
22179
22180         More strtod touchups.
22181         * tests/test-strtod.c (main): Ignore tests for signbit on NaN, and
22182         sign of negative underflow, for now.  Use .5, not .1.
22183         * doc/posix-functions/strtod.texi (strtod): Mention these
22184         limitations.
22185         Reported by Jim Meyering.
22186
22187 2008-03-30  Bruno Haible  <bruno@clisp.org>
22188
22189         * lib/striconveh.h (mem_iconveh, str_iconveh): Optimize the conversion
22190         from UTF-8 to UTF-8//TRANSLIT in the same way as from UTF-8 to UTF-8.
22191
22192 2008-03-30  Bruno Haible  <bruno@clisp.org>
22193
22194         Avoid failure when attempting to return empty iconv results on some
22195         platforms.
22196         * lib/striconveh.c (mem_cd_iconveh_internal): In the final memory
22197         allocation, don't report ENOMEM when the resulting string is empty.
22198
22199 2008-03-30  Bruno Haible  <bruno@clisp.org>
22200
22201         Fix buffer overrun.
22202         * lib/vasnprintf.c (VASNPRINTF): If !USE_SNPRINTF && pad_ourselves:
22203         Don't consider the width for tmp_length. Check count against tmp_length
22204         before doing the padding. Ensure enough allocation during padding.
22205
22206 2008-03-30  Eric Blake  <ebb9@byu.net>
22207
22208         strtod touchups.
22209         * lib/strtod.c (strtod): Avoid compiler warnings.
22210         Reported by Jim Meyering.
22211
22212 2008-03-30  Bruno Haible  <bruno@clisp.org>
22213
22214         * lib/unistdio/u-vsprintf.h (EOVERFLOW): Remove fallback.
22215         * modules/unistdio/ulc-vsprintf (Depends-on): Add EOVERFLOW.
22216         * modules/unistdio/u8-vsprintf (Depends-on): Add EOVERFLOW.
22217         * modules/unistdio/u8-u8-vsprintf (Depends-on): Add EOVERFLOW.
22218         * modules/unistdio/u16-vsprintf (Depends-on): Add EOVERFLOW.
22219         * modules/unistdio/u16-u16-vsprintf (Depends-on): Add EOVERFLOW.
22220         * modules/unistdio/u32-vsprintf (Depends-on): Add EOVERFLOW.
22221         * modules/unistdio/u32-u32-vsprintf (Depends-on): Add EOVERFLOW.
22222
22223         * lib/unistdio/u-vsnprintf.h (EOVERFLOW): Remove fallback.
22224         * modules/unistdio/ulc-vsnprintf (Depends-on): Add EOVERFLOW.
22225         * modules/unistdio/u8-vsnprintf (Depends-on): Add EOVERFLOW.
22226         * modules/unistdio/u8-u8-vsnprintf (Depends-on): Add EOVERFLOW.
22227         * modules/unistdio/u16-vsnprintf (Depends-on): Add EOVERFLOW.
22228         * modules/unistdio/u16-u16-vsnprintf (Depends-on): Add EOVERFLOW.
22229         * modules/unistdio/u32-vsnprintf (Depends-on): Add EOVERFLOW.
22230         * modules/unistdio/u32-u32-vsnprintf (Depends-on): Add EOVERFLOW.
22231
22232         * lib/unistdio/u-vasprintf.h (EOVERFLOW): Remove fallback.
22233         * modules/unistdio/ulc-vasprintf (Depends-on): Add EOVERFLOW.
22234         * modules/unistdio/u8-vasprintf (Depends-on): Add EOVERFLOW.
22235         * modules/unistdio/u8-u8-vasprintf (Depends-on): Add EOVERFLOW.
22236         * modules/unistdio/u16-vasprintf (Depends-on): Add EOVERFLOW.
22237         * modules/unistdio/u16-u16-vasprintf (Depends-on): Add EOVERFLOW.
22238         * modules/unistdio/u32-vasprintf (Depends-on): Add EOVERFLOW.
22239         * modules/unistdio/u32-u32-vasprintf (Depends-on): Add EOVERFLOW.
22240
22241         * lib/unistdio/ulc-vfprintf.c (EOVERFLOW): Remove fallback.
22242         * modules/unistdio/ulc-vfprintf (Depends-on): Add EOVERFLOW.
22243
22244         * lib/unistdio/ulc-fprintf.c (EOVERFLOW): Remove fallback.
22245         * modules/unistdio/ulc-fprintf (Depends-on): Add EOVERFLOW.
22246
22247         * lib/xvasprintf.c (EOVERFLOW): Remove fallback.
22248         * modules/xvasprintf (Depends-on): Add EOVERFLOW.
22249
22250         * lib/vsprintf.c (EOVERFLOW): Remove fallback.
22251         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Drop gl_EOVERFLOW.
22252         * modules/vsprintf-posix (Depends-on): Add EOVERFLOW.
22253
22254         * lib/vsnprintf.c (EOVERFLOW): Remove fallback.
22255         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Drop gl_EOVERFLOW.
22256         * modules/vsnprintf (Depends-on): Add EOVERFLOW.
22257
22258         * lib/vfprintf.c (EOVERFLOW): Remove fallback.
22259         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Drop gl_EOVERFLOW.
22260         * modules/vfprintf-posix (Depends-on): Add EOVERFLOW.
22261
22262         * lib/vasprintf.c (EOVERFLOW): Remove fallback.
22263         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Drop gl_EOVERFLOW.
22264         * modules/vasprintf (Depends-on): Add EOVERFLOW.
22265
22266         * lib/vasnprintf.c (EOVERFLOW): Remove fallback.
22267         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Drop gl_EOVERFLOW.
22268         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Drop gl_EOVERFLOW.
22269         * modules/vasnprintf (Files): Remove m4/eoverflow.m4.
22270         (Depends-on): Add EOVERFLOW.
22271         * modules/unistdio/ulc-vasnprintf (Files): Remove m4/eoverflow.m4.
22272         (Depends-on): Add EOVERFLOW.
22273         * modules/unistdio/u8-vasnprintf (Files): Remove m4/eoverflow.m4.
22274         (Depends-on): Add EOVERFLOW.
22275         * modules/unistdio/u8-u8-vasnprintf (Files): Remove m4/eoverflow.m4.
22276         (Depends-on): Add EOVERFLOW.
22277         * modules/unistdio/u16-vasnprintf (Files): Remove m4/eoverflow.m4.
22278         (Depends-on): Add EOVERFLOW.
22279         * modules/unistdio/u16-u16-vasnprintf (Files): Remove m4/eoverflow.m4.
22280         (Depends-on): Add EOVERFLOW.
22281         * modules/unistdio/u32-vasnprintf (Files): Remove m4/eoverflow.m4.
22282         (Depends-on): Add EOVERFLOW.
22283         * modules/unistdio/u32-u32-vasnprintf (Files): Remove m4/eoverflow.m4.
22284         (Depends-on): Add EOVERFLOW.
22285
22286         * lib/sprintf.c (EOVERFLOW): Remove fallback.
22287         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Drop gl_EOVERFLOW.
22288         * modules/sprintf-posix (Depends-on): Add EOVERFLOW.
22289
22290         * lib/snprintf.c (EOVERFLOW): Remove fallback.
22291         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Drop gl_EOVERFLOW.
22292         * modules/snprintf (Depends-on): Add EOVERFLOW.
22293
22294         * lib/poll.c (EOVERFLOW): Remove fallback.
22295         * modules/poll (Depends-on): Add EOVERFLOW.
22296
22297         * lib/getugroups.c (EOVERFLOW): Remove fallback.
22298         * modules/getugroups (Depends-on): Add EOVERFLOW.
22299
22300         * lib/getdelim.c (EOVERFLOW): Remove fallback.
22301         * modules/getdelim (Depends-on): Add EOVERFLOW.
22302
22303         * lib/ftell.c (EOVERFLOW): Remove fallback.
22304         * modules/ftell (Depends-on): Add EOVERFLOW.
22305
22306         * lib/fprintf.c (EOVERFLOW): Remove fallback.
22307         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Drop gl_EOVERFLOW.
22308         * modules/fprintf-posix (Depends-on): Add EOVERFLOW.
22309
22310         * lib/c-stack.c (EOVERFLOW): Remove unused fallback.
22311
22312         * modules/EOVERFLOW-tests: New file.
22313         * tests/test-EOVERFLOW.c: New file.
22314
22315         * modules/EOVERFLOW: New file.
22316         * doc/posix-headers/errno.texi: Mention EOVERFLOW portability problem.
22317
22318 2008-03-30  Bruno Haible  <bruno@clisp.org>
22319
22320         Fix bug introduced on 2007-06-10.
22321         * lib/vasnprintf.c (VASNPRINTF): When performing zero-padding, use
22322         spaces instead of 0 digits for 's' also when ENABLE_UNISTDIO.
22323
22324 2008-03-30  Bruno Haible  <bruno@clisp.org>
22325
22326         Improve freadseek's efficiency after ungetc.
22327         * lib/freadseek.c: Include freadahead.h.
22328         (freadptrinc): New function, extracted from freadseek.
22329         (freadseek): Use it in a loop. Use freadahead to determine the number
22330         of loop iterations.
22331         * modules/freadseek (Depends-on): Add freadahead.
22332         (configure.ac): Require AC_C_INLINE.
22333
22334 2008-03-30  Bruno Haible  <bruno@clisp.org>
22335
22336         * lib/freadseek.c (freadseek): Don't ignore the return value of
22337         freadptr.
22338
22339 2008-03-29  Eric Blake  <ebb9@byu.net>
22340
22341         Add hex float support.
22342         * modules/strtod (Depends-on): Add c-ctype.
22343         (Link): Mention POW_LIB.
22344         * lib/strtod.c (strtod): Recognize hex floats.  Don't allow
22345         whitespace between 'e' and exponent.
22346         * tests/test-strtod.c (main): Enable hex float tests.
22347         * doc/posix-functions/strtod.texi (strtod): Document what gnulib
22348         now provides.
22349
22350         Document various strtod bugs, with some fixes.
22351         * doc/posix-functions/strtod.texi (strtod): Document bugs with
22352         "-0x", "inf", "nan", and hex constants.
22353         * doc/posix-functions/atof.texi (atof): Likewise.
22354         * modules/stdlib (Makefile.am): Support strtod.
22355         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
22356         * m4/strtod.m4 (gl_FUNC_STRTOD): Fit in stdlib framework, and
22357         detect additional strtod bugs.
22358         * lib/stdlib.in.h (rpl_strtod): Add declarations.
22359         * lib/strtod.c (strtod): Return -0.0 on negative underflow.  Use
22360         bool where appropriate.  Parse 'inf' and 'nan'.
22361         * tests/test-strtod.c: New file.
22362         * modules/strtod (Depends-on): Add stdbool, stdlib.
22363         (configure.ac): Turn on module indicator.
22364         * modules/strtod-tests: New module.
22365
22366 2008-03-29  Eric Blake  <ebb9@byu.net>
22367
22368         Fix ftell on mingw.
22369         * lib/ftell.c (EOVERFLOW): Define if the system lacks it.
22370         * modules/ftell-tests (Depends-on): Add binary-io.
22371         * modules/ftello-tests (Depends-on): Likewise.
22372         * tests/test-ftell.c (main): Enhance test to cover behavior after
22373         ungetc.  Enforce binary mode.
22374         * tests/test-ftello.c (main): Likewise.
22375
22376         Pass test-freadseek on cygwin.
22377         * modules/freadseek (Depends-on): Use freadptr, not freadahead.
22378         * lib/freadseek.c (freadseek): Don't increment beyond bounds of
22379         ungetc buffer.
22380
22381         * tests/test-fflush2.c (main): Fix typo.
22382
22383 2008-03-29  Bruno Haible  <bruno@clisp.org>
22384
22385         * tests/test-fflush2.c (main): Temporarily disable the contents of
22386         this test.
22387         * m4/fflush.m4 (gl_FUNC_FFLUSH): Add a TODO.
22388         Reported by Eric Blake.
22389
22390 2008-03-28  Simon Josefsson  <simon@josefsson.org>
22391
22392         * lib/gc.h (enum Gc_hash): Add GC_SHA224.
22393         (GC_SHA224_DIGEST_SIZE): Add.
22394
22395         * lib/gc-libgcrypt.c (gc_hash_open): Handle SHA-224.
22396         (gc_hash_digest_length): Likewise.
22397         (gc_hash_buffer): Likewise.
22398
22399 2008-03-25  Bruno Haible  <bruno@clisp.org>
22400
22401         * doc/gnulib-tool.texi (gettextize and autopoint): Explain in more
22402         detail which gettext release to use.
22403         Reported by Simon Josefsson.
22404
22405 2008-03-26  Jim Meyering  <meyering@redhat.com>
22406
22407         gnumakefile: remove file from $(top_builddir), not from $(top_srcdir)
22408         * modules/gnumakefile (clean-GNUmakefile): Also, use
22409         test ... && ... || : syntax rather than if-then ... fi.
22410
22411         gnumakefile: Don't double-quote-expand $(VPATH) value.
22412         * modules/gnumakefile (clean-GNUmakefile): Use single quotes.
22413
22414 2008-03-24  Eric Blake  <ebb9@byu.net>
22415
22416         Alter GNUmakefile to install into top directory.
22417         * modules/maintainer-makefile: Split, and add dependency...
22418         * modules/gnumakefile: to this new module.
22419         * build-aux/GNUmakefile: Move...
22420         * top/GNUmakefile: ...here.
22421         * build-aux/maint.mk: Move...
22422         * top/maint.mk: ...here.
22423         * MODULES.html.sh (Support for maintaining...): Document new
22424         module.
22425
22426 2008-03-23  Bruno Haible  <bruno@clisp.org>
22427
22428         * gnulib-tool: New options --vc-files, --no-vc-files.
22429         (func_usage): Document them.
22430         (vc_files): New variable.
22431         (func_import): Consider vc_files.
22432         (func_create_testdir): Set vc_files to empty.
22433         Suggested by Jim Meyering and Karl Berry.
22434
22435 2008-03-23  Bruno Haible  <bruno@clisp.org>
22436
22437         Fix regex compilation error on HP-UX 11.
22438         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_TYPE_MBSTATE_T.
22439         * modules/regex (Files): Add m4/mbstate_t.m4.
22440         Reported by Ton Voon <ton.voon@altinity.com>.
22441
22442 2008-03-23  Bruno Haible  <bruno@clisp.org>
22443
22444         * doc/gnulib-tool.texi (gettextize and autopoint): New section.
22445
22446 2008-03-23  Eric Blake  <ebb9@byu.net>
22447             Bruno Haible  <bruno@clisp.org>
22448
22449         Install files from top/ in the destination directory.
22450         * gnulib-tool (func_get_automake_snippet): Synthesize an EXTRA_DIST
22451         augmentation also for the files from top/.
22452         (func_import, func_create_testdir): Rewrite file names:
22453         top/filename -> filename.
22454
22455 2008-03-23  Bruno Haible  <bruno@clisp.org>
22456
22457         Tweak "gnulib --version" output.
22458         * gnulib-tool (func_version): Replace "-dirty" suffix with "-modified".
22459
22460 2008-03-23  Bruno Haible  <bruno@clisp.org>
22461
22462         Tweak "gnulib --version" output.
22463         * gnulib-tool (func_version): Use date of last commit to ChangeLog,
22464         rather than contents of ChangeLog, when possible.
22465
22466 2008-03-21  Eric Blake  <ebb9@byu.net>
22467
22468         More --version tweaks.
22469         * gnulib-tool (func_version): Obey GNU Coding Standards.  Output
22470         date of last ChangeLog entry.
22471
22472 2008-03-21  Jim Meyering  <meyering@redhat.com>
22473
22474         * build-aux/GNUmakefile (_have-git-version-gen): Split long line.
22475
22476 2008-03-20  Eric Blake  <ebb9@byu.net>
22477
22478         VPATH fix.
22479         * build-aux/GNUmakefile (_have_git-version-gen): Look in correct dir.
22480
22481 2008-03-20  Simon Josefsson  <simon@josefsson.org>
22482
22483         * build-aux/GNUmakefile: Make git-version-gen optional.  Add
22484         _build-aux variable.  Suggested by Eric Blake <ebb9@byu.net>.
22485
22486 2008-03-20  Eric Blake  <ebb9@byu.net>
22487
22488         Sync GNUmakefile with coreutils.
22489         * build-aux/GNUmakefile (have-Makefile): Rename...
22490         (_have-Makefile): ...to this, for namespace consideration.
22491         (GNUmakefile.cfg): Include, if present.
22492         (_autoreconf): Define a default.
22493         (_is-dist-target): New rule for rebuilds to pick up intra-release
22494         version.
22495         (maint-cfg.mk): Rename...
22496         (cfg.mk): ...to this.
22497
22498 2008-03-18  Jim Meyering  <meyering@redhat.com>
22499
22500         New script and module: mktempd
22501         * MODULES.html.sh (maint+release support): Add mktempd.
22502         * build-aux/mktempd: New file.
22503         * modules/mktempd: New file.
22504
22505 2008-03-15  Jim Meyering  <meyering@redhat.com>
22506
22507         Undo last change.
22508         * lib/sha1.c, lib/md5.c: 63 != ~63.
22509         Reported by Andreas Schwab.
22510
22511         sha1.c, md5.c: Hoist a redundant expression.
22512         * lib/sha1.c (sha1_process_bytes): AND-off the low bits in
22513         "ctx->buflen" only once, before calling *_process_block.
22514         * lib/md5.c (md5_process_bytes): Likewise.
22515
22516 2008-03-14  Eric Blake  <ebb9@byu.net>
22517
22518         Bump copyright year in files generated by gnulib-tool.
22519         * gnulib-tool (func_emit_copyright_notice): Extract copyright from
22520         gnulib-tool, rather than hard-coding it.
22521
22522         Fix 'gnulib-tool --version' output to work with git.
22523         * gnulib-tool (func_gnulib_dir): New function, extracted from...
22524         (startup): ...here.
22525         (func_version): Use it to invoke git-version-gen, rather than
22526         relying on CVS keyword expansion.  Modernize wording.
22527         (cvsdatestamp, last_checkin_date, version): Kill unused
22528         variables.
22529
22530 2008-03-12  Jim Meyering  <meyering@redhat.com>
22531
22532         Recognize optional cast of the argument to free.
22533         * build-aux/useless-if-before-free: Update regexps.
22534
22535         * build-aux/bootstrap (gnulib_tool): Remove trailing blanks.
22536
22537 2008-03-11  Bruno Haible  <bruno@clisp.org>
22538
22539         Extend AC_LIB_LINKFLAGS to the situation of several libraries provided
22540         by a single package.
22541         * m4/lib-link.m4 (AC_LIB_FROMPACKAGE): New macro.
22542         (AC_LIB_LINKFLAGS_BODY): Use the information stored by
22543         AC_LIB_FROMPACKAGE. Use AC_ARG_WITH instead of AC_LIB_ARG_WITH.
22544         Reported by Sam Steingold <sds@gnu.org>.
22545
22546 2008-03-12  Sergey Poznyakoff  <gray@gnu.org.ua>
22547
22548         * build-aux/bootstrap (version_controlled_file): Adapt for SVN
22549         repositories.
22550
22551 2008-03-11  Bruno Haible  <bruno@clisp.org>
22552
22553         Avoid conflicts between local macro definitions.
22554         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
22555         AC_LIB_LINKFLAGS_BODY): Use pushdef/popdef instead of define/undefine.
22556
22557 2008-03-10  Peter O'Gorman  <bug-gnulib@mlists.thewrittenword.com>
22558             Bruno Haible  <bruno@clisp.org>
22559
22560         Make va_copy work with some version of xlc on AIX 5.1.
22561         * lib/stdarg.in.h: New file.
22562         * m4/stdarg.m4 (gl_STDARG_H): Initialize STDARG_H and NEXT_STDARG_H.
22563         On AIX, use a <stdarg.h> file substitute.
22564         * modules/stdarg (Files): Add lib/stdarg.in.h.
22565         (Depends-on): Add include_next.
22566         (Makefile.am): Build a stdarg.h substitute if requested.
22567         * doc/posix-functions/va_copy.texi: Document the platforms lacking it.
22568
22569 2008-03-10  Bruno Haible  <bruno@clisp.org>
22570
22571         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Document a restriction.
22572         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
22573         Reported by Peter O'Gorman <bug-gnulib@mlists.thewrittenword.com>.
22574
22575 2008-03-10  Bruno Haible  <bruno@clisp.org>
22576
22577         * modules/stdlib (Depends-on): Add include_next, remove
22578         absolute-header.
22579
22580 2008-03-09  Bruno Haible  <bruno@clisp.org>
22581
22582         * lib/freadahead.h (freadahead): Document more precisely.
22583         * lib/freadahead.c (freadahead): When an ungetc is in effect, return
22584         the sum of both buffer sizes.
22585         * tests/test-freadahead.c (main): Also test behaviour after ungetc.
22586         * NEWS: Document the change.
22587
22588 2008-03-09  Bruno Haible  <bruno@clisp.org>
22589
22590         Extend freadptr to return also the buffer size.
22591         * lib/freadptr.h (freadptr): Add sizep argument.
22592         * lib/freadptr.c: Include freadptr.h, not freadahead.h.
22593         (freadptr): Add sizep argument. Determine buffer size like freadahead
22594         does.
22595         * tests/test-freadptr.c: Don't include freadahead.h.
22596         (main): Adapt for new calling convention of freadptr.
22597         * tests/test-freadptr2.c: New file, based on tests/test-freadahead.c.
22598         * tests/test-freadptr2.sh: New file, based on tests/test-freadahead.sh.
22599         * modules/freadptr-tests (Files): Add tests/test-freadptr2.c,
22600         tests/test-freadptr2.sh.
22601         (Depends): Remove freadahead.
22602         (TESTS): Add test-freadptr2.sh.
22603         (check_PROGRAMS): Add test-freadptr2.
22604
22605 2008-03-09  Bruno Haible  <bruno@clisp.org>
22606
22607         * doc/Makefile (%.pdf): Explain how to remedy the save_size error.
22608         Report and solution by Simon Josefsson.
22609
22610 2008-03-06  Bruno Haible  <bruno@clisp.org>
22611
22612         Make fflush after ungetc work on BSD platforms.
22613         * lib/fflush.c (rpl_fflush): Discard ungetc buffer if possible.
22614         * tests/test-fflush2.c: New file.
22615         * tests/test-fflush2.sh: New file.
22616         * modules/fflush-tests (Files): Add tests/test-fflush2.sh,
22617         tests/test-fflush2.c.
22618         (Makefile.am): Build test-fflush2 and run test-fflush2.sh.
22619         * doc/posix-functions/fflush.texi: Document fflush after ungetc bug.
22620
22621 2008-03-06  Eric Blake  <ebb9@byu.net>
22622
22623         Likewise for ftello.
22624         * modules/ftello (Dependencies): Add extensions.
22625         * m4/ftello.m4 (gl_FUNC_FTELLO): Require AC_USE_SYSTEM_EXTENSIONS.
22626
22627 2008-03-06  Bruno Haible  <bruno@clisp.org>
22628
22629         * modules/fseeko (Dependencies): Add extensions.
22630         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Require AC_USE_SYSTEM_EXTENSIONS.
22631         Needed on glibc systems.
22632
22633 2008-03-06  Bruno Haible  <bruno@clisp.org>
22634
22635         * doc/gnulib-tool.texi (@nosuchmodulenote): Avoid line break inside
22636         email address.
22637         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
22638
22639 2008-03-06  Bruno Haible  <bruno@clisp.org>
22640
22641         * users.txt: Add libgnupdf.
22642
22643 2008-03-06  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
22644
22645         * doc/gnulib-tool.texi (@nosuchmodulenote): New macro.
22646         (Header File Substitutes, Function Substitutes,
22647         Glibc Header File Substitutes, Glibc Function Substitutes): Use it.
22648         (Build robot for gnulib): Fix typo.
22649
22650 2008-03-06  Bruno Haible  <bruno@clisp.org>
22651
22652         * doc/gnulib-tool.texi (VCS Issues): Small updates.
22653         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
22654
22655 2008-03-06  Bruno Haible  <bruno@clisp.org>
22656
22657         * doc/func.texi: New file, extracted from doc/gnulib.texi.
22658         * doc/gnulib.texi: Include it.
22659
22660 2008-03-06  Simon Josefsson  <simon@josefsson.org>
22661
22662         * modules/func (License): Change license to unlimited; there was
22663         no LGPL parts in the module anyway.
22664
22665 2008-03-06  Simon Josefsson  <simon@josefsson.org>
22666
22667         * modules/__func__: Renamed to modules/func.
22668         * modules/__func__-tests: Renamed to modules/func-tests.
22669         * tests/test-__func__.c: Renamed to tests/test-func.c.
22670         * m4/__func__.m4: Renamed to m4/func.m4.
22671         * doc/gnulib.texi (__func__): Section renamed to func.
22672         Suggested by Eric Blake <ebb9@byu.net>.
22673
22674 2008-03-06  Simon Josefsson  <simon@josefsson.org>
22675
22676         * doc/gnulib.texi (__func__): Use C99 terminology when talking
22677         about __func__.  Make example self-contained.  Suggested by Eric
22678         Blake <ebb9@byu.net>.
22679
22680         * tests/test-__func__.c (main): Avoid extraneous () around __func.
22681         Suggested by Eric Blake <ebb9@byu.net>.
22682
22683 2008-03-06  Simon Josefsson  <simon@josefsson.org>
22684
22685         * modules/__func__: New file.
22686         * modules/__func__-tests: New file.
22687         * tests/test-__func__.c: New file.
22688         * m4/__func__.m4: New file.
22689         * doc/gnulib.texi (__func__): Document __func__ module.
22690
22691 2008-03-05  Simon Josefsson  <simon@josefsson.org>
22692
22693         * modules/byteswap (License): Re-license as LGPLv2+.
22694
22695 2008-03-05  Simon Josefsson  <simon@josefsson.org>
22696
22697         * doc/Makefile: Add pdf target.
22698
22699 2008-03-05  Simon Josefsson  <simon@josefsson.org>
22700
22701         * modules/inline (License): Use 'unlimited', since there are only
22702         *.m4 files in this module.
22703
22704 2008-03-03  John E. Malmberg  <wb8tyw@qsl.net>  (tiny change)
22705             Bruno Haible  <bruno@clisp.org>
22706
22707         Add support for HP C 7.1 on OpenVMS 8.3.
22708         * lib/alloca.in.h (alloca): Define as alias for DEC C on VMS.
22709
22710 2008-03-03  John E. Malmberg  <wb8tyw@qsl.net>  (tiny change)
22711
22712         Update VMS specifics.
22713         * lib/getopt.c [VMS]: Remove include of unixlib.h.
22714
22715 2008-03-02  Jim Meyering  <meyering@redhat.com>
22716
22717         Remove the last dependency on the "free" module.
22718         * m4/readutmp.m4 (gl_READUTMP): Don't require gl_FUNC_FREE.
22719         Reported by Bob Proulx.
22720
22721         * lib/getdelim.c (getdelim): Don't leak memory upon failed realloc.
22722
22723         Remove useless "if" tests before free.  Deprecate "free" module.
22724         * doc/posix-functions/free.texi: Mention that this
22725         module is no longer useful.
22726         * modules/free (Notice): Say this module is obsolete.
22727         * modules/readutmp (Depends-on): Remove free.
22728         * lib/save-cwd.c (free_cwd): Remove useless "if" before free.
22729         * lib/putenv.c (putenv): Likewise.
22730         * lib/gc-gnulib.c (gc_cipher_close): Likewise.
22731         * lib/getaddrinfo.c (freeaddrinfo): Likewise.
22732         * tests/test-c-strcasestr.c (main): Likewise.
22733         * tests/test-c-strstr.c (main): Likewise.
22734         * tests/test-mbscasestr1.c (main): Likewise.
22735         * tests/test-mbscasestr2.c (main): Likewise.
22736         * tests/test-mbsstr1.c (main): Likewise.
22737         * tests/test-mbsstr2.c (main): Likewise.
22738         * tests/test-memmem.c (main): Likewise.
22739         * tests/test-strcasestr.c (main): Likewise.
22740         * tests/test-striconv.c (main): Likewise.
22741         * tests/test-striconveh.c (main): Likewise.
22742         * tests/test-striconveha.c (main): Likewise.
22743         * tests/test-strstr.c (main): Likewise.
22744
22745         * build-aux/git-version-gen: Adjust a comment and the Usage string.
22746
22747         bootstrap: sync from coreutils again
22748         * build-aux/bootstrap: Remove dangling m4/*.m4 symlinks.
22749
22750 2008-03-01  Jim Meyering  <meyering@redhat.com>
22751
22752         bootstrap: sync from coreutils
22753         * build-aux/bootstrap (update_po_files): Copy a .po file into place
22754         also when the target doesn't exist.
22755
22756 2008-03-01  Eric Blake  <ebb9@byu.net>
22757
22758         Fix bugs in last patch.
22759         * lib/memchr2.c (memchr2): Fix typo.
22760         * tests/test-memchr2.c: Test previous bug, and don't use GNU
22761         extension.
22762         Reported by Bruce Korb.
22763
22764         New module 'memchr2'.
22765         * modules/memchr2: New file.
22766         * modules/memchr2-tests: Likewise.
22767         * lib/memchr2.h: Likewise.
22768         * lib/memchr2.c: Likewise, based on memchr.c.
22769         * tests/test-memchr2.c: New test.
22770         * MODULES.html.sh (String handling): Add memchr2.
22771
22772 2008-02-29  Bruno Haible  <bruno@clisp.org>
22773
22774         * modules/freadseek-tests: New file.
22775         * tests/test-freadseek.sh: New file.
22776         * tests/test-freadseek.c: New file.
22777
22778         New module 'freadseek'.
22779         * modules/freadseek: New file.
22780         * lib/freadseek.h: New file.
22781         * lib/freadseek.c: New file.
22782         * MODULES.html.sh (File stream based Input/Output): Add freadseek.
22783
22784 2008-02-29  Sergey Poznyakoff  <gray@gnu.org.ua>
22785
22786         * users.txt: Add anubis, cpio, mailfromd, mailutils, radius,
22787         wydawca.
22788
22789         * m4/argp.m4 (gl_ARGP): Use AC_TRY_LINK to test if
22790         program_invocation_name and program_invocation_short_name are
22791         present.
22792
22793 2008-02-28  Bruno Haible  <bruno@clisp.org>
22794
22795         * tests/test-freadptr.c: Add a test for behaviour after ungetc.
22796         * tests/test-freadptr.sh: Also test non-seekable stdin.
22797
22798 2008-02-28  Sergey Poznyakoff  <gray@gnu.org.ua>
22799
22800         * build-aux/bootstrap (source_base, m4_base)
22801         (doc_base, tests_base): New variables.
22802         (gnulib_tool_options): Do not hardcode base directories, use
22803         the above variables instead.
22804
22805 2008-02-28  Atsushi SAKAI  <sakaia@jp.fujitsu.com>
22806
22807         * lib/xsize.h: Fix typo in comment: s/tupe/type/.
22808
22809 2008-02-28  Bruno Haible  <bruno@clisp.org>
22810
22811         * modules/freadptr-tests: New file.
22812         * tests/test-freadptr.sh: New file.
22813         * tests/test-freadptr.c: New file.
22814
22815         New module 'freadptr'.
22816         * modules/freadptr: New file.
22817         * lib/freadptr.h: New file.
22818         * lib/freadptr.c: New file.
22819         * MODULES.html.sh (File stream based Input/Output): Add freadptr.
22820
22821 2008-02-26  Karl Berry  <karl@freefriends.org>
22822
22823         Sync from Libtool:
22824         * libltdl/argz.c (argz_add, argz_count): New functions.
22825         * libltdl/argz.in.h: Declare them.
22826         Report by Juan Manuel Guerrero <juan.guerrero@gmx.de>.
22827
22828 2008-02-22  Bruno Haible  <bruno@clisp.org>
22829
22830         * m4/time_r.m4 (gl_TIME_R): Also check that localtime_r's return type
22831         is a pointer type.  Needed for HP-UX 10.
22832         * doc/posix-functions/localtime_r.texi: Mention HP-UX 10.
22833         * doc/posix-functions/gmtime_r.texi: Likewise.
22834         Reported by Peter O'Gorman <bug-gnulib@mlists.thewrittenword.com>.
22835
22836 2008-02-24  Bruno Haible  <bruno@clisp.org>
22837
22838         * modules/environ-tests: New file.
22839         * tests/test-environ.c: New file.
22840
22841         New module 'environ'.
22842         * modules/environ: New file.
22843         * lib/unistd.in.h (environ): New declaration.
22844         * m4/environ.m4: New file.
22845         (gt_CHECK_VAR_DECL): Moved here from m4/setenv.m4. Undefine gt_cv_var
22846         after use.
22847         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_ENVIRON and
22848         HAVE_DECL_ENVIRON.
22849         * modules/unistd (Makefile.am): Substitute also GNULIB_ENVIRON and
22850         HAVE_DECL_ENVIRON.
22851         * doc/posix-functions/environ.texi: Mention module 'environ'. Remove
22852         wrong claim that 'environ' is missing on some systems.
22853         * modules/execute (Depends-on): Add environ.
22854         * lib/execute.c (environ): Remove fallback declaration.
22855         * modules/pipe (Depends-on): Add environ.
22856         * lib/pipe.c (environ): Remove fallback declaration.
22857         * modules/setenv (Depends-on): Add environ.
22858         * lib/setenv.c (environ): Remove fallback declaration.
22859         * modules/unsetenv (Depends-on): Add environ.
22860         * lib/unsetenv.c (environ): Remove fallback declaration.
22861         * m4/setenv.m4 (gt_CHECK_VAR_DECL): Remove macro. Moved to
22862         m4/environ.m4.
22863         (gl_PREREQ_SETENV): Require gl_ENVIRON instead of testing for environ.
22864         (gl_PREREQ_UNSETENV): Likewise.
22865
22866 2008-02-24  Bruno Haible  <bruno@clisp.org>
22867
22868         * doc/posix-functions/environ.texi: Document the MacOS X problem.
22869
22870 2008-02-20  Bob Proulx  <bob@proulx.com>
22871
22872         Enable use of older two part flavor 'git describe'.
22873         * build-aux/git-version-gen: If using the older two part flavor of
22874         git version then recreate the third part now present in the
22875         newer three part flavor of git describe.
22876
22877 2008-02-20  Martin Buchholz  <martin@xemacs.org>  (tiny change)
22878
22879         * lib/fts.c (fts_build): Typo correction to comment.
22880
22881 2008-02-17  Bruno Haible  <bruno@clisp.org>
22882
22883         * lib/git-merge-changelog.c (main) [split_merged_entry]: Avoid
22884         generating no-op conflicts.
22885
22886 2008-02-17  Bruno Haible  <bruno@clisp.org>
22887
22888         Speed up by 10%.
22889         * lib/git-merge-changelog.c (main): Use the iterator to iterate through
22890         result_entries, rather than an index-based loop.
22891
22892 2008-02-17  Bruno Haible  <bruno@clisp.org>
22893
22894         Speed up by 25%.
22895         * lib/git-merge-changelog.c (struct entry): New fields 'hashcode',
22896         'hashcode_cached'.
22897         (entry_create): New function.
22898         (entry_hashcode): Use the cached hashcode if possible.
22899         (read_changelog_file, try_split_merged_entry): Use entry_create.
22900
22901 2008-02-17  Bruno Haible  <bruno@clisp.org>
22902
22903         Speed up from O(n^2) to O(n) for long ChangeLog files.
22904         * lib/git-merge-changelog.c: Include gl_rbtreehash_list.h.
22905         (read_changelog_file): Change implementation of entries_reversed list
22906         to rbtreehash.
22907         * modules/git-merge-changelog (Depends-on): Add rbtreehash-list.
22908
22909 2008-02-17  Bruno Haible  <bruno@clisp.org>
22910
22911         New option --split-merged-entry.
22912         * lib/git-merge-changelog.c (FSTRCMP_STRICTER_THRESHOLD): New macro.
22913         (find_paragraph_end, try_split_merged_entry): New functions.
22914         (long_options): Add option --split-merged-entry.
22915         (usage): Document option --split-merged-entry.
22916         (main): Implement option --split-merged-entry.
22917         Reported by Eric Blake.
22918
22919 2008-02-17  Bruno Haible  <bruno@clisp.org>
22920
22921         * lib/git-merge-changelog.c: Include c-strstr.h.
22922         (main): Support the "git pull --rebase" situation.
22923         * modules/git-merge-changelog (Depends-on): Add c-strstr.
22924         Reported by Eric Blake.
22925
22926 2008-02-16  Eric Blake  <ebb9@byu.net>
22927
22928         Avoid doubling \ in common case of "c-maybe" quoting style.
22929         * lib/quotearg.c (quotearg_buffer_restyled): Don't escape \ when
22930         eliding outer quotes.
22931         * lib/quotearg.h: Document this.
22932         * tests/test-quotearg.c (result_strings, inputs, results_g)
22933         (flag_results, locale_results): Test it by adding a new string to
22934         each test group.
22935         (compare_strings): Test new string.
22936
22937 2008-02-13  Eric Blake  <ebb9@byu.net>
22938
22939         Avoid trigraph quoting in default output.
22940         * lib/quotearg.h (enum quoting_flags): Add QA_SPLIT_TRIGRAPHS.
22941         * lib/quotearg.c (quotearg_buffer_restyled): Don't quote trigraphs
22942         unless explicitly requested.
22943         * tests/test-quotearg.c (flag_results, main): Add additional tests.
22944
22945 2008-02-13  Lasse Collin  <lasse.collin@tukaani.org>
22946
22947         Don't rely on signed integer overflowing to negative value.
22948         * lib/getugroups.c (getugroups): Include <limits.h>.
22949         Instead, compare against INT_MAX, and increment only if the test passes.
22950
22951 2008-02-13  Jim Meyering  <meyering@redhat.com>
22952         and Eric Blake  <ebb9@byu.net>
22953
22954         Avoid shadowing warning and compile errors on Linux.
22955         * tests/test-quotearg.c [ENABLE_NLS]: Disable <libintl.h>
22956         forwarding macros on Linux.
22957         (dcgettext): Define a stub, for Linux.
22958         (results_g, main): Avoid warnings.
22959
22960 2008-02-12  Eric Blake  <ebb9@byu.net>
22961
22962         Silence warning in last patch.
22963         * lib/quotearg.c (quotearg_buffer_restyled): Add missing const.
22964
22965         Quotearg part 4: add tests, fix c-maybe colon quoting.
22966         * lib/quotearg.h: Improve documentation.
22967         * lib/quotearg.c (quotearg_buffer_restyled): Don't add extra
22968         escapes when adding outer quotes.  When quoting trigraphs, use
22969         valid C notation.  When quoting NUL, omit extra characters if next
22970         character is not digit.  Alter prototype.
22971         (quotearg_buffer, quotearg_alloc_mem, quotearg_n_options): Adjust
22972         callers.
22973         * modules/quotearg-tests: New module.
22974         * tests/test-quotearg.c: New test.
22975
22976 2008-02-07  Eric Blake  <ebb9@byu.net>
22977
22978         Quotearg part 3: add flag to control outer quote elision.
22979         * lib/quotearg.h (c_maybe_quoting_style): New style.
22980         (enum quoting_flags): Better documentation of flags.
22981         * lib/quotearg.c (quoting_style_args, quoting_style_vals): Add
22982         c-maybe style.
22983         (quotearg_buffer_restyled): Handle new flag to elide outer
22984         quotes.
22985
22986         Quotearg part 2: add flag that can control NUL elision.
22987         * lib/quotearg.h (set_quoting_flags): New prototype.
22988         * lib/quotearg.c (struct quoting_options): Add flag field.
22989         (set_quoting_flags): New function.
22990         (quotearg_buffer_restyled): Add flags parameter.
22991         (quotearg_alloc_mem): Set the flag if length cannot be returned.
22992         (quotearg_n_options): Set the flag, since length cannot be
22993         returned.
22994         (quoting_options_from_style): Default flags correctly.
22995
22996         Quotearg part 1: more wrappers, restore quotearg_char state.
22997         * lib/quotearg.h (quotearg_alloc_mem, quotearg_n_mem)
22998         (quotearg_mem, quotearg_style_mem, quotearg_char_mem)
22999         (quotearg_colon_mem): New wrappers.
23000         * lib/quotearg.c (quotearg_alloc, quotearg_char): Rewrite...
23001         (quotearg_alloc_mem, quotearg_char_mem): ...in terms of these new
23002         functions.
23003         (quotearg_n_mem, quotearg_mem, quotearg_style_mem)
23004         (quotearg_colon_mem): New functions.
23005
23006 2008-02-11  Bruno Haible  <bruno@clisp.org>
23007
23008         * modules/git-merge-changelog (Makefile.am): Don't use -L and -l for a
23009         library in the current directory: it does not work with parallel make.
23010         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
23011
23012 2008-02-11  Bruno Haible  <bruno@clisp.org>
23013
23014         * .gitattributes: New file.
23015
23016 2008-02-11  Jim Meyering  <meyering@redhat.com>
23017
23018         useless-if-before-free: Fix reversed exit values.
23019         * build-aux/useless-if-before-free: Use correct values
23020         for EXIT_MATCH and EXIT_NO_MATCH.
23021
23022         * build-aux/useless-if-before-free: Close stdout carefully.
23023
23024 2008-02-10  Bruno Haible  <bruno@clisp.org>
23025
23026         New module 'git-merge-changelog'.
23027         * modules/git-merge-changelog: New file.
23028         * lib/git-merge-changelog.c: New file.
23029
23030 2008-02-10  Jim Meyering  <meyering@redhat.com>
23031
23032         useless-if-before-free: New option: --list (-l).
23033
23034         useless-if-before-free: Don't exit immediately upon open failure.
23035         * build-aux/useless-if-before-free: Exit 2 for errors.
23036         Upon failure to open a file, don't exit immediately.
23037         Rather, just warn and continue with any remaining files.
23038
23039 2008-02-10  Bruno Haible  <bruno@clisp.org>
23040
23041         New abstract list operation 'node_set_value'.
23042         * lib/gl_list.h (gl_list_node_set_value): New function.
23043         (struct gl_list_implementation): New field node_set_value.
23044         * lib/gl_list.c (gl_list_node_set_value): New function.
23045         * lib/gl_array_list.c (gl_array_node_set_value): New function.
23046         (gl_array_list_implementation): Update.
23047         * lib/gl_carray_list.c (gl_carray_node_set_value): New function.
23048         (gl_carray_list_implementation): Update.
23049         * lib/gl_anylinked_list2.h (gl_linked_node_set_value): New function.
23050         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
23051         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
23052         * lib/gl_anytree_list2.h (gl_tree_node_set_value): New function.
23053         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
23054         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
23055         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
23056         Update.
23057         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
23058         * lib/gl_sublist.c (gl_sublist_node_set_value): New function.
23059         (gl_sublist_list_implementation): Update.
23060
23061 2008-02-10  Bruno Haible  <bruno@clisp.org>
23062
23063         * lib/diffseq.h: Write "ELEMENT const" instead of "const ELEMENT".
23064         Needed when ELEMENT is #defined to 'some_type *'.
23065
23066 2008-02-10  Jim Meyering  <meyering@redhat.com>
23067
23068         New script and module: useless-if-before-free
23069         * MODULES.html.sh (maint+release support): Add useless-if-before-free.
23070         * build-aux/useless-if-before-free: New file.
23071         * modules/useless-if-before-free: New file.
23072
23073         * build-aux/gitlog-to-changelog: Use committer date, not author date.
23074
23075         xstrtol_error: Fix typo.
23076         * lib/xstrtol-error.c (xstrtol_error): The parameter was unused:
23077         s/exit_failure/exit_status/.
23078
23079 2008-02-09  Jim Meyering  <meyering@redhat.com>
23080
23081         New script and module: gitlog-to-changelog
23082         * MODULES.html.sh (maint+release support): Add gitlog-to-changelog.
23083         * modules/gitlog-to-changelog: New file.
23084         * build-aux/gitlog-to-changelog: New file.
23085
23086 2008-02-08  Jim Meyering  <meyering@redhat.com>
23087
23088         Avoid two "parameter unused" warnings.
23089         * lib/stat-time.h (get_stat_birthtime_ns, get_stat_birthtime):
23090         Mark "st" as used.
23091
23092         Use "git COMMAND", not "git-COMMAND".
23093         * build-aux/bootstrap (version_controlled_file): s/git-rm/git-rm/.
23094         * build-aux/announce-gen (get_tool_versions): Correct a diagnostic.
23095         * build-aux/git-version-gen: Use "git status", not "git-status".
23096
23097 2008-02-07  Bruno Haible  <bruno@clisp.org>
23098
23099         * lib/vasnprintf.c (VASNPRINTF): Don't use %n on native Woe32 systems.
23100         Avoids a crash on Windows Vista.
23101         Reported by Adam Strzelecki <ono@java.pl> via
23102         Simon Josefsson <simon@josefsson.org>.
23103
23104 2008-02-06  Bruno Haible  <bruno@clisp.org>
23105
23106         Fix *printf behaviour regarding the left-adjust flag on HP-UX 10.20.
23107         * m4/printf.m4 (gl_PRINTF_FLAG_LEFTADJUST): New macro.
23108         * lib/vasnprintf.c (VASNPRINTF): Handle NEED_PRINTF_FLAG_LEFTADJUST.
23109         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_LEFTADJUST): New macro.
23110         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
23111         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
23112         gl_PRINTF_FLAG_LEFTADJUST and test its result. Invoke
23113         gl_PREREQ_VASNPRINTF_FLAG_LEFTADJUST.
23114         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
23115         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
23116         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
23117         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
23118         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
23119         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
23120         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
23121         * tests/test-vasnprintf-posix.c (test_function): Add testcases for the
23122         left-adjust flag.
23123         * tests/test-snprintf-posix.h (test_function): Likewise.
23124         * tests/test-sprintf-posix.h (test_function): Likewise.
23125         * tests/test-vasprintf-posix.c (test_function): Likewise.
23126         * doc/posix-functions/fprintf.texi: Update.
23127         * doc/posix-functions/printf.texi: Update.
23128         * doc/posix-functions/snprintf.texi: Update.
23129         * doc/posix-functions/sprintf.texi: Update.
23130         * doc/posix-functions/vfprintf.texi: Update.
23131         * doc/posix-functions/vprintf.texi: Update.
23132         * doc/posix-functions/vsnprintf.texi: Update.
23133         * doc/posix-functions/vsprintf.texi: Update.
23134         Reported by Peter Fales <psfales@alcatel-lucent.com>.
23135
23136 2008-02-06  Bruno Haible  <bruno@clisp.org>
23137
23138         Fix bug introduced on 2008-01-26.
23139         * lib/isnan.c (FUNC): Set to rpl_isnand, not rpl_isnan.
23140
23141 2008-02-06  Bruno Haible  <bruno@clisp.org>
23142
23143         Fix bug introduced on 2007-06-10.
23144         * lib/vasnprintf.c (VASNPRINTF): Perform zero-padding also if
23145         !NEED_PRINTF_FLAG_ZERO.
23146
23147 2008-02-05  Peter O'Gorman <pogma@thewrittenword.com>
23148
23149         getloadavg: use libperfstat on AIX5
23150         * lib/getloadavg.c, m4/getloadavg.m4 [aix]: Use libperfstat
23151
23152 2008-02-03  Bruno Haible  <bruno@clisp.org>
23153
23154         * lib/diffseq.h: Add comments about required #includes.
23155         Reported by Michael Biggs <gnulib@doubleplum.net>.
23156
23157 2008-02-01  Bruno Haible  <bruno@clisp.org>
23158
23159         * users.txt: Add gnuit.
23160
23161 2008-01-31  Bruno Haible  <bruno@clisp.org>
23162
23163         * lib/md4.c (set_uint32): Mark as inline.
23164         * lib/md5.c (set_uint32): Likewise.
23165         * lib/sha1.c (set_uint32): Likewise.
23166         * m4/md4.m4 (gl_MD4): Require AC_C_INLINE.
23167         * m4/md5.m4 (gl_MD5): Likewise.
23168         * m4/sha1.m4 (gl_SHA1): Likewise.
23169
23170 2008-01-31  Jim Meyering  <meyering@redhat.com>
23171
23172         Use "sizeof VAR", rather than a literal "4".
23173         * lib/md5.c (md5_read_ctx): Use sizeof ctx->A, not 4.
23174         * lib/md4.c (md4_read_ctx): Likewise.
23175         * lib/sha1.c (sha1_read_ctx): Likewise.
23176
23177 2008-01-31  Simon Josefsson  <simon@josefsson.org>
23178
23179         * tests/test-sha1.c: New file, based on test-md5.c.
23180
23181         * modules/crypto/sha1-tests: New file.
23182
23183 2008-01-31  Simon Josefsson  <simon@josefsson.org>
23184
23185         * lib/sha1.h (SHA1_DIGEST_SIZE): Define.
23186
23187 2008-01-31  Jim Meyering  <meyering@redhat.com>
23188
23189         Prefer "sizeof v" over the equivalent "4".
23190         * lib/md4.c (set_uint32): Use "sizeof v" as memcpy length, not 4.
23191         * lib/md5.c (set_uint32): Likewise.
23192         * lib/sha1.c (set_uint32): Likewise.
23193
23194 2008-01-31  Simon Josefsson  <simon@josefsson.org>
23195
23196         * lib/sha1.c (set_uint32): Mark function as static.
23197
23198 2008-01-31  Simon Josefsson  <simon@josefsson.org>
23199
23200         md2: clarify comments to say that alignment is not required.
23201         * lib/md2.h: Remove warning about alignment in comment.
23202         * lib/md2.c (md2_read_ctx, md2_finish_ctx): Doc fix, alignment has
23203         never been required.
23204
23205 2008-01-31  Simon Josefsson  <simon@josefsson.org>
23206
23207         md4: adapt alignment constraint fix from sha1.
23208         * lib/md4.c (set_uint32): New function, from sha1.c
23209         (md4_read_ctx): Use it.
23210         (md4_finish_ctx): Doc fix.
23211         * lib/md4.h: Doc fix.
23212
23213 2008-01-31  Simon Josefsson  <simon@josefsson.org>
23214
23215         md5: adapt alignment constraint fix from sha1.
23216         * lib/md5.c (set_uint32): New function, from sha1.c
23217         (md5_read_ctx): Use it.
23218         (md5_finish_ctx): Doc fix.
23219         * lib/md5.h: Doc fix.
23220
23221 2008-01-30  Peter Palfrader  <weasel@debian.org>
23222
23223         sha1: remove the result buffer alignment constraint
23224         * lib/sha1.c (set_uint32): New function.
23225         (sha1_read_ctx): Rewrite to remove the result buffer alignment
23226         constraint.
23227         (sha1_finish_ctx): Remove comment warning about alignment constraint.
23228         * lib/sha1.h: Likewise.
23229
23230 2008-01-30  Andreas Schwab  <schwab@suse.de>
23231             Bruno Haible  <bruno@clisp.org>
23232
23233         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Include <float.h> and ensure a
23234         correct definition of LDBL_MIN_EXP.
23235
23236 2008-01-30  Karl Berry  <karl@gnu.org>
23237
23238         * config/srclist-update: try to preserve x bit on updates.
23239         * config/srclistvars.sh: update for karl.
23240
23241 2008-01-29  Jim Meyering  <meyering@redhat.com>
23242
23243         vasnprintf.c: Avoid warning about unused label
23244         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Guard the
23245         "overflow" label definition and associated code with the
23246         same cpp condition that guards the sole use of that label.
23247
23248 2008-01-26  Bruno Haible  <bruno@clisp.org>
23249
23250         * m4/isnanl.m4 (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM,
23251         gl_FUNC_ISNANL_WORKS): Test the GCC >= 4.0 built-in.
23252         * lib/isnanl.h (isnanl): Use the GCC >= 4.0 built-in.
23253         * lib/isnanl-nolibm.h (isnanl): Likewise.
23254         Reported by Paul Eggert <eggert@cs.ucla.edu>.
23255
23256 2008-01-26  Bruno Haible  <bruno@clisp.org>
23257
23258         * m4/isnand.m4 (gl_FUNC_ISNAND_NO_LIBM): Test the GCC >= 4.0 built-in.
23259         * lib/isnand.h (isnand): Use the GCC >= 4.0 built-in.
23260
23261 2008-01-26  Bruno Haible  <bruno@clisp.org>
23262
23263         * m4/isnanf.m4 (gl_HAVE_ISNANF_NO_LIBM, gl_ISNANF_WORKS): Test the
23264         GCC >= 4.0 built-in.
23265         * lib/isnanf.h (isnanf): Use the GCC >= 4.0 built-in.
23266
23267 2008-01-26  Bruno Haible  <bruno@clisp.org>
23268
23269         Rename isnan, applicable to 'double' only, to isnand.
23270         * modules/isnand-nolibm: Renamed from modules/isnan-nolibm.
23271         (Files): Add lib/isnand.h, lib/isnand.c. Remove lib/isnan.h.
23272         (configure.ac): Update.
23273         (Include): Replace "isnan.h" with "isnand.h".
23274         * m4/isnand.m4: Renamed from m4/isnan.m4.
23275         (gl_FUNC_ISNAND_NO_LIBM): Renamed from gl_FUNC_ISNAN_NO_LIBM. Set
23276         HAVE_ISNAND_IN_LIBC instead of HAVE_ISNAN_IN_LIBC. Build isnand.c
23277         instead of isnan.c.
23278         * lib/isnand.h: Renamed from lib/isnan.h. Test HAVE_ISNAND_IN_LIBC
23279         instead of HAVE_ISNAN_IN_LIBC.
23280         (isnand): Renamed from isnan.
23281         * lib/isnand.c: New file.
23282         * modules/isnand-nolibm-tests: Renamed from modules/isnan-nolibm-tests.
23283         (Files): Add tests/test-isnand.c. Remove tests/test-isnan.c.
23284         (Makefile.am): Update.
23285         * tests/test-isnand.c: Renamed from tests/test-isnan.c.
23286         Include isnand.h instead of isnan.h.
23287         (main): Test isnand instead of isnan.
23288         * modules/fprintf-posix (Depends-on): Add isnand-nolibm, remove
23289         isnan-nolibm.
23290         * modules/frexp (Depends-on): Likewise.
23291         * modules/frexp-tests (Depends-on): Likewise.
23292         * modules/frexp-nolibm (Depends-on): Likewise.
23293         * modules/frexp-nolibm-tests (Depends-on): Likewise.
23294         * modules/isfinite (Depends-on): Likewise.
23295         * modules/round-tests (Depends-on): Likewise.
23296         * modules/signbit (Depends-on): Likewise.
23297         * modules/signbit-tests (Depends-on): Likewise.
23298         * modules/snprintf-posix (Depends-on): Likewise.
23299         * modules/sprintf-posix (Depends-on): Likewise.
23300         * modules/trunc-tests (Depends-on): Likewise.
23301         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
23302         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
23303         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
23304         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
23305         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
23306         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
23307         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
23308         * modules/vasnprintf-posix (Depends-on): Likewise.
23309         * modules/vasprintf-posix (Depends-on): Likewise.
23310         * modules/vfprintf-posix (Depends-on): Likewise.
23311         * modules/vsnprintf-posix (Depends-on): Likewise.
23312         * modules/vsprintf-posix (Depends-on): Likewise.
23313         * lib/frexp.c: Include isnand.h instead of isnan.h.
23314         (ISNAN): Set to isnand instead of isnan.
23315         * lib/isfinite.c: Include isnand.h instead of isnan.h.
23316         (gl_isfinited): Use isnand instead of isnan.
23317         * lib/signbitd.c: Include isnand.h instead of isnan.h.
23318         (gl_signbitd): Use isnand instead of isnan.
23319         * lib/vasnprintf.c: Include isnand.h instead of isnan.h.
23320         (is_infinite_or_zero, VASNPRINTF): Use isnand instead of isnan.
23321         * tests/test-frexp.c: Include isnand.h instead of isnan.h.
23322         (main): Use isnand instead of isnan.
23323         * tests/test-round1.c: Include isnand.h.
23324         (main): Use isnand instead of isnan.
23325         * tests/test-round2.c: Include isnand.h instead of isnan.h.
23326         (ISNAN): Set to isnand instead of isnan.
23327         * tests/test-trunc1.c: Include isnand.h.
23328         (main): Use isnand instead of isnan.
23329         * tests/test-trunc2.c: Include isnand.h instead of isnan.h.
23330         (equal): Use isnand instead of isnan.
23331         * MODULES.html.sh (Mathematics <math.h>): Replace isnan-nolibm with
23332         isnand-nolibm.
23333         * NEWS: Mention the change.
23334
23335 2008-01-25  Paul Eggert  <eggert@cs.ucla.edu>
23336             Bruno Haible  <bruno@clisp.org>
23337
23338         * m4/signbit.m4 (gl_SIGNBIT): Require a macro definition. Test whether
23339         the GCC builtins for signbits are present and set
23340         REPLACE_SIGNBIT_USING_GCC if so.
23341         * lib/math.in.h (signbit): Define using GCC builtins if
23342         REPLACE_SIGNBIT_USING_GCC is set.
23343         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize
23344         REPLACE_SIGNBIT_USING_GCC.
23345         * modules/math (Makefile.am): Substitute REPLACE_SIGNBIT_USING_GCC.
23346
23347 2008-01-25  Jim Meyering  <meyering@redhat.com>
23348
23349         Prefer <config.h> over "config.h".  See autoconf doc for explanation.
23350         * lib/poll.c: Include <config.h>, not "config.h".
23351         * tests/test-getaddrinfo.c: Likewise.
23352
23353 2008-01-25  Simon Josefsson  <simon@josefsson.org>
23354
23355         * modules/sockets-tests: New file.
23356
23357 2008-01-24  Simon Josefsson  <simon@josefsson.org>
23358
23359         * modules/sockets: New module, can be used to call WSA_Startup and
23360         WSA_Cleanup when needed.
23361
23362         * lib/sockets.h, lib/sockets.c: New files.
23363
23364         * m4/sockets.m4: New file.
23365
23366         * tests/test-sockets.c: New file.
23367
23368 2008-01-19  Bruno Haible  <bruno@clisp.org>
23369
23370         * doc/posix-headers: Renamed from doc/headers.
23371         * doc/posix-functions: Renamed from doc/functions.
23372         * doc/gnulib.texi: Update.
23373
23374 2008-01-19  Bruno Haible  <bruno@clisp.org>
23375
23376         * doc/glibc-functions/strcasestr.texi: Include contents of
23377         doc/functions/strcasestr.texi, fixing the list of platforms.
23378         * doc/functions/strcasestr.texi: Remove file.
23379
23380 2008-01-19  Bruno Haible  <bruno@clisp.org>
23381
23382         * doc/glibc-functions/memmem.texi: Include contents of
23383         doc/functions/memmem.texi.
23384         * doc/functions/memmem.texi: Remove file.
23385
23386 2008-01-18  Bruno Haible  <bruno@clisp.org>
23387
23388         * doc/glibc-functions/*.texi: New files.
23389         * doc/gnulib.texi (Glibc Function Substitutes): Completely rewritten
23390         to use the new files.
23391
23392 2008-01-17  Bruno Haible  <bruno@clisp.org>
23393
23394         * tests/test-gethostname.c (main): Fix printf statement.
23395
23396 2008-01-17  Simon Josefsson  <simon@josefsson.org>
23397
23398         * modules/gethostname-tests: New file.
23399
23400         * tests/test-gethostname.c: New file.
23401
23402 2008-01-17  Simon Josefsson  <simon@josefsson.org>
23403
23404         * lib/gethostname.c: Include string.h unconditionally, strncpy is
23405         used by the UNAME case.  Reported by Bruno Haible
23406         <bruno@clisp.org>.
23407
23408 2008-01-17  Eric Blake  <ebb9@byu.net>
23409
23410         Convert c-strcasestr to be more efficient.
23411         * modules/c-strcasestr (Files): Use Two-Way, not KMP.
23412         (Depends-on): Add c-strcase, remove malloca, strnlen.
23413         * tests/test-c-strcasestr.c (main): Enhance test.
23414         * lib/c-strcasestr.c (c_strcasestr): Rewrite to new algorithm.
23415
23416 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
23417
23418         * build-aux/bootstrap (MSGID_BUGS_ADDRESS): New overridable variable.
23419         Use it in creating po/Makevars.
23420
23421 2008-01-15  Simon Josefsson  <simon@josefsson.org>
23422
23423         * lib/gc-libgcrypt.c (gc_init): Disable secure memory by default.
23424         Applications that requires it should initialize libgcrypt
23425         manually.
23426
23427 2008-01-16  Simon Josefsson  <simon@josefsson.org>
23428
23429         * lib/gethostname.c [!HAVE_UNAME]: Need string.h for strcpy.
23430
23431 2008-01-15  Paul Eggert  <eggert@cs.ucla.edu>
23432
23433         Fix problem with getdate on mingw32 reported by Simon Josefsson
23434         in <http://lists.gnu.org/archive/html/bug-gnulib/2008-01/msg00192.html>.
23435         * lib/getdate.y (get_date): Check "HAVE_DECL_TZNAME", not "defined
23436         tzname", when deciding whether to declare tzname.
23437         * lib/strftime.c (tzname): Likewise.
23438
23439 2008-01-15  Bruno Haible  <bruno@clisp.org>
23440
23441         Work around a MacOS X 10.5 bug in frexpl().
23442         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Also check denormalized numbers.
23443         * doc/functions/frexpl.texi: Document the bug.
23444         Reported by Elias Pipping <pipping@gentoo.org>.
23445
23446 2008-01-14  Eric Blake  <ebb9@byu.net>
23447
23448         Touch up previous patch.
23449         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Fix typo.
23450         * doc/functions/strcasestr.texi (strcasestr): Document OpenBSD bug.
23451
23452         Convert strcasestr module to use Two-Way algorithm.
23453         * modules/strcasestr-simple: New module, based on the old
23454         strcasestr, but with Two-Way rather than KMP.
23455         * modules/strcasestr (Depends-on): Change to strcasestr-simple.
23456         * lib/string.in.h (rpl_strcasestr): Declare.
23457         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Check for linear
23458         performance.
23459         * lib/strcasestr.c (strcasestr): Simplify, and avoid malloc.
23460         * modules/string (Makefile.am): Support strcasestr.
23461         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
23462         * modules/strcasestr-tests (Depends-on): Check for alarm.
23463         * tests/test-strcasestr.c: Augment test.
23464         * lib/str-two-way.h: Clean up stray macro.
23465         * NEWS: Document new module.
23466         * MODULES.html.sh (string handling): Likewise.
23467         * doc/functions/strcasestr.texi: New file.
23468         * doc/gnulib.texi (Function Substitutes): New node.  Move memmem
23469         here, since it is not a POSIX function.
23470
23471 2008-01-14  Colin Watson  <cjwatson@debian.org>
23472             Bruno Haible  <bruno@clisp.org>
23473
23474         * m4/strsignal.m4 (gl_FUNC_STRSIGNAL): Also check whether strsignal
23475         works fine; if not, set REPLACE_STRSIGNAL.
23476         (gl_PREREQ_STRSIGNAL): Require AC_DECL_SYS_SIGLIST.
23477         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
23478         REPLACE_STRSIGNAL.
23479         * lib/string.in.h (strsignal): Consider REPLACE_STRSIGNAL.
23480         * modules/string (Makefile.am): Substitute REPLACE_STRSIGNAL.
23481         * tests/test-strsignal.c (main): Check out-of-range signal numbers.
23482
23483 2008-01-14  Bruno Haible  <bruno@clisp.org>
23484
23485         * modules/strsignal (Include): Change to <string.h>.
23486
23487 2008-01-14  Colin Watson  <cjwatson@debian.org>
23488
23489         * modules/argp (Notice): Add a notice recommending to change
23490         XGETTEXT_OPTIONS.
23491         (configure.ac): Invoke AM_XGETTEXT_OPTION if it exists.
23492
23493 2008-01-13  Colin Watson  <cjwatson@debian.org>
23494
23495         * modules/strsignal-tests: New file.
23496         * tests/test-strsignal.c: New file.
23497
23498         * lib/strsignal.c: New file, from glibc with modifications.
23499         * lib/siglist.h: New file, from glibc with modifications.
23500         * lib/string.in.h (strsignal): New declaration.
23501         * m4/strsignal.m4: New file.
23502         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
23503         GNULIB_STRSIGNAL and HAVE_DECL_STRSIGNAL.
23504         * modules/strsignal: New file.
23505         * modules/string (Makefile.am): Substitute GNULIB_STRSIGNAL and
23506         HAVE_DECL_STRSIGNAL.
23507
23508 2008-01-13  Bruno Haible  <bruno@clisp.org>
23509
23510         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check that the
23511         locale encoding is not ASCII. Needed for OpenBSD 4.0.
23512         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
23513         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
23514
23515 2008-01-13  Bruno Haible  <bruno@clisp.org>
23516
23517         * lib/argp-fmtstream.h (__attribute__): Don't redefine if
23518         __STRICT_ANSI__ is set: it's not needed by any version of gcc.
23519         * lib/argp.h (__attribute__): Likewise.
23520         * lib/c-stack.c (__attribute__): Likewise.
23521         * lib/error.h (__attribute__): Likewise.
23522         * lib/fts.c (__attribute__): Likewise.
23523         * lib/openat.h (__attribute__): Likewise.
23524         * lib/stdio.in.h (__attribute__): Likewise.
23525         * lib/string.in.h (__attribute__): Likewise.
23526         * lib/utimens.c (__attribute__): Likewise.
23527         * lib/vasnprintf.h (__attribute__): Likewise.
23528         * lib/xalloc.h (__attribute__): Likewise.
23529         * lib/xprintf.h (__attribute__): Likewise.
23530         * lib/xstrtol.h (__attribute__): Likewise.
23531         * lib/xvasprintf.h (__attribute__): Likewise.
23532
23533 2008-01-12  Bruno Haible  <bruno@clisp.org>
23534
23535         * doc/gnulib.texi (Glibc Header File Substitutes): New chapter.
23536         * doc/glibc-headers/a.out.texi: New file.
23537         * doc/glibc-headers/aliases.texi: New file.
23538         * doc/glibc-headers/alloca.texi: New file.
23539         * doc/glibc-headers/ar.texi: New file.
23540         * doc/glibc-headers/argp.texi: New file.
23541         * doc/glibc-headers/argz.texi: New file.
23542         * doc/glibc-headers/byteswap.texi: New file.
23543         * doc/glibc-headers/crypt.texi: New file.
23544         * doc/glibc-headers/endian.texi: New file.
23545         * doc/glibc-headers/envz.texi: New file.
23546         * doc/glibc-headers/err.texi: New file.
23547         * doc/glibc-headers/error.texi: New file.
23548         * doc/glibc-headers/execinfo.texi: New file.
23549         * doc/glibc-headers/fpu_control.texi: New file.
23550         * doc/glibc-headers/fstab.texi: New file.
23551         * doc/glibc-headers/fts.texi: New file.
23552         * doc/glibc-headers/getopt.texi: New file.
23553         * doc/glibc-headers/ieee754.texi: New file.
23554         * doc/glibc-headers/ifaddrs.texi: New file.
23555         * doc/glibc-headers/libintl.texi: New file.
23556         * doc/glibc-headers/mcheck.texi: New file.
23557         * doc/glibc-headers/mntent.texi: New file.
23558         * doc/glibc-headers/obstack.texi: New file.
23559         * doc/glibc-headers/paths.texi: New file.
23560         * doc/glibc-headers/printf.texi: New file.
23561         * doc/glibc-headers/pty.texi: New file.
23562         * doc/glibc-headers/resolv.texi: New file.
23563         * doc/glibc-headers/shadow.texi: New file.
23564         * doc/glibc-headers/sysexits.texi: New file.
23565         * doc/glibc-headers/ttyent.texi: New file.
23566
23567 2008-01-12  Jim Meyering  <meyering@redhat.com>
23568
23569         announce-gen: emit Gnulib's git-based version string.
23570         * build-aux/announce-gen: Remove option: --gnulib-snapshot-time-stamp=S.
23571         New option --gnulib-version=V, where V is expected to be
23572         the output of running git describe in the gnulib directory.
23573         (get_tool_versions): Request feedback on xdelta.  I suspect it's
23574         not useful, and plan to stop publishing an xdelta file with each
23575         coreutils release.
23576
23577         * build-aux/announce-gen: Also check for lzma-compressed files.
23578
23579 2008-01-11  Bruno Haible  <bruno@clisp.org>
23580
23581         * tests/test-memmem.c (main): Increase maximum allowed time.
23582         * tests/test-strstr.c (main): Likewise.
23583
23584 2008-01-11  Bruno Haible  <bruno@clisp.org>
23585
23586         * doc/functions/memmem.texi: Add more precisions about platforms.
23587         * doc/functions/strstr.texi: Likewise.
23588
23589 2008-01-10  Eric Blake  <ebb9@byu.net>
23590
23591         * m4/strstr.m4: Delete cruft from copy-n-paste.
23592         Reported by Bruno Haible.
23593
23594 2008-01-10  Bruno Haible  <bruno@clisp.org>
23595
23596         Make c-strstr rely on strstr.
23597         * lib/c-strstr.c: Don't include str-kmp.h.
23598         (c_strstr): Define in terms of strstr.
23599         * modules/c-strstr (Files): Remove lib/str-kmp.h.
23600         (Depends-on): Remove stdbool, malloca, strnlen. Add strstr.
23601
23602 2008-01-10  Bruno Haible  <bruno@clisp.org>
23603
23604         * doc/gnulib.texi (String Functions in C Locale): New section.
23605         * doc/c-ctype.texi: New file.
23606         * doc/c-strcase.texi: New file.
23607         * doc/c-strcaseeq.texi: New file.
23608         * doc/c-strcasestr.texi: New file.
23609         * doc/c-strstr.texi: New file.
23610         * doc/c-strtod.texi: New file.
23611         * doc/c-strtold.texi: New file.
23612
23613 2008-01-10  Eric Blake  <ebb9@byu.net>
23614
23615         * lib/relocatable.h: Fix a comment.
23616
23617 2008-01-10  Eric Blake  <ebb9@byu.net>
23618
23619         Share two-way algorithm.
23620         * lib/str-two-way.h: New file, merged from...
23621         * lib/memmem.c: ...here...
23622         * lib/strstr.c: ...and here.
23623         * modules/memmem (Files): Use it.
23624         * modules/strstr (Files): Likewise.
23625
23626         Avoid quadratic strstr implementations.
23627         * lib/strstr.c: New file.
23628         * m4/strstr.m4: Likewise.
23629         * modules/strstr: Likewise.
23630         * modules/strstr-tests: Likewise.
23631         * tests/test-strstr.c: Likewise.
23632         * lib/string.in.h (rpl_strstr): Declare.
23633         (memmem) [GNULIB_POSIXCHECK]: Document speed issue.
23634         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Support strstr.
23635         * modules/string (Makefile.am): Likewise.
23636         * MODULES.html.sh (string handling): Mention new module.
23637         * doc/functions/strstr.texi (strstr): Document the bug.
23638
23639 2008-01-10  Bruno Haible  <bruno@clisp.org>
23640
23641         * lib/relocatable.h (relocate): State whether result is freshly
23642         allocated or not.
23643         * lib/relocatable.c (relocate): Return a freshly allocated string
23644         instead of a pointer to a privately held string.
23645         Reported by Sylvain Beucler <beuc@gnu.org>.
23646
23647 2008-01-10  Colin Watson  <cjwatson@debian.org>
23648
23649         * lib/canonicalize-lgpl.c [!_LIBC]: Fix typo in #if directive:
23650         s/S_ISNLK/S_ISLNK/.
23651
23652 2008-01-09  Bruno Haible  <bruno@clisp.org>
23653
23654         * doc/functions/memmem.texi: Use the same structure as snprintf.texi
23655         and other files.
23656         * m4/memmem.m4 (gl_FUNC_MEMMEM): Say "guessing no" instead of "no"
23657         if it's only a guess.
23658         * modules/memmem: Simplify by depending on memmem-simple.
23659
23660 2008-01-09  Bruno Haible  <bruno@clisp.org>
23661
23662         Work around OpenBSD 4.0 tdelete() bug.
23663         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Also check tdelete's return value.
23664         * lib/search.in.h: If REPLACE_TSEARCH is 1, define tsearch etc. as
23665         macros and don't redefine the enum values.
23666         * m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Initialize REPLACE_TSEARCH.
23667         * modules/search (Makefile.am): Also substitute REPLACE_TSEARCH.
23668         * doc/functions/tdelete.texi: Document the OpenBSD 4.0 bug.
23669
23670 2008-01-09  Bruno Haible  <bruno@clisp.org>
23671
23672         * tests/test-wcwidth.c: Include <string.h> and localcharset.h.
23673         (main): Don't perform the tests if setlocale did not install a UTF-8
23674         locale. Needed on OpenBSD 4.0.
23675         * modules/wcwidth-tests (Depends-on): Add localcharset.
23676
23677 2008-01-09  Paul Eggert  <eggert@cs.ucla.edu>
23678
23679         gl_FUNC_ALLOCA no longer defines HAVE_ALLOCA_H unconditionally.
23680         See <http://lists.gnu.org/archive/html/bug-gnulib/2007-12/msg00149.html>.
23681         * NEWS: announce this.
23682         * m4/alloca.m4 (gl_FUNC_ALLOCA): Don't define HAVE_ALLOCA_H.
23683
23684 2008-01-09  Simon Josefsson  <simon@josefsson.org>
23685         and Eric Blake  <ebb9@byu.net>
23686
23687         Add memmem-simple module.
23688         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): New macro.
23689         (gl_FUNC_MEMMEM): Separate performance from presence checks.
23690         * modules/memmem-simple: New file.
23691         * modules/memmem (Description): Tweak.
23692         * MODULES.html.sh (string handling): Mention new module.
23693         * doc/functions/memmem.texi (memmem): Distinguish which flaws are
23694         addressed by memmem-simple.
23695         * NEWS: Document the difference.
23696
23697 2008-01-09  Eric Blake  <ebb9@byu.net>
23698
23699         Give gcc some memmem optimization hints.
23700         * lib/string.in.h (memmem, memrchr, strchrnul, strnlen, strpbrk)
23701         (strcasestr): Declare as pure.
23702         * modules/memmem (Maintainer): Claim my implementation.
23703
23704 2008-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
23705
23706         Support AIX 6.1 and higher.
23707         * build-aux/config.libpath: Likewise.
23708         * build-aux/config.rpath: Likewise.
23709
23710 2008-01-08  Jim Meyering  <meyering@redhat.com>
23711             Bruno Haible  <bruno@clisp.org>
23712
23713         * lib/printf-parse.c (PRINTF_PARSE): Handle a size specifier "q"
23714         on MacOS X and a size specifier "I64" on mingw. Needed for PRIdMAX.
23715         Reported by Peter Fales in
23716         <http://lists.gnu.org/archive/html/bug-coreutils/2007-12/msg00148.html>.
23717
23718 2008-01-08  Bruno Haible  <bruno@clisp.org>
23719
23720         * modules/unictype/category-of (Depends-on): Add
23721         unictype/category-none.
23722         * modules/unictype/category-and-tests (Depends-on): Add
23723         unictype/category-{L,N,Lu,Nd}.
23724         * modules/unictype/category-and-not-tests (Depends-on): Likewise.
23725         * modules/unictype/category-or-tests (Depends-on): Add
23726         unictype/category-{L,N}.
23727         * modules/unictype/category-name-tests (Depends-on): Add
23728         unictype/category-{Z,Nl}.
23729         Reported by Simon Josefsson.
23730
23731 2008-01-08  Bruno Haible  <bruno@clisp.org>
23732
23733         * lib/str-kmp.h (knuth_morris_pratt_unibyte): Document the calling
23734         convention better.
23735         * lib/mbsstr.c (knuth_morris_pratt_multibyte): Likewise.
23736         * lib/mbscasestr.c (knuth_morris_pratt_multibyte): Likewise.
23737         Reported by Peter Miller <millerp@canb.auug.org.au>.
23738
23739 2008-01-08  Eric Blake  <ebb9@byu.net>
23740
23741         Rewrite memmem to guarantee linear complexity without malloc.
23742         * lib/memmem.c (memmem): Use Two-Way rather than
23743         Knuth-Morris-Pratt, to allow O(1) space usage.
23744         (critical_factorization, two_way_short_needle)
23745         (two_way_long_needle): New functions.
23746         (knuth_morris_pratt): Delete.
23747         * modules/memmem (Depends-on): No longer need malloca or stdbool.
23748         Add stdint.
23749         * tests/test-memmem.c (main): Add tests for periodic needle and
23750         sublinear performance.
23751         * doc/functions/memmem.texi (memmem): Document other deficiencies
23752         in cygwin and older glibc.
23753
23754 2008-01-08  Bruno Haible  <bruno@clisp.org>
23755
23756         * modules/memmem-tests (Makefile.am): Remove TESTS_ENVIRONMENT
23757         augmentation.
23758
23759 2008-01-08  Mike Frysinger  <vapier@gentoo.org>
23760
23761         Add a configure time option: --disable-acl.
23762         * m4/acl.m4 (gl_FUNC_ACL): Wrap all ACL logic in a call to
23763         AC_ARG_ENABLE(acl).
23764
23765 2008-01-06  Simon Josefsson  <simon@josefsson.org>
23766
23767         * tests/test-localename.c: Don't include obsolete "setenv.h".
23768
23769         * modules/localename-tests (Depends-on): Need unsetenv.
23770
23771 2008-01-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
23772
23773         * DEPENDENCIES: Require Texinfo version 4.6 or newer.
23774
23775 2008-01-06  Colin Watson  <cjwatson@debian.org>
23776
23777         * users.txt: Add man-db.
23778
23779 2008-01-07  Bruno Haible  <bruno@clisp.org>
23780
23781         * doc/gnulib-intro.texi (Library vs Reusable Code): Restore the
23782         previous section name.
23783
23784 2008-01-07  Bruno Haible  <bruno@clisp.org>
23785
23786         * lib/progname.c (set_program_name): Don't strip off a leading
23787         "lt-" prefix outside a .libs directory.
23788         Suggested by Paul Eggert.
23789
23790 2008-01-01  Sylvain Beucler  <beuc@gnu.org>
23791             Bruno Haible  <bruno@clisp.org>
23792
23793         Improve memory cleanup in 'relocatable' module.
23794         * lib/relocatable.h (compute_curr_prefix): Change return type to
23795         'char *'.
23796         * lib/relocatable.c (compute_curr_prefix): Change return type to
23797         'char *'. Free curr_installdir after use.
23798         (relocate): Free curr_prefix_better after use.
23799         * lib/progreloc.c (prepare_relocate): Free curr_prefix after use.
23800
23801 2008-01-01  Bruno Haible  <bruno@clisp.org>
23802
23803         * tests/test-wcwidth.c (main): Relax test of U+2060. Avoids a test
23804         failure on older glibc systems.
23805         Reported by Peter Fales <psfales@alcatel-lucent.com>.
23806
23807 2008-01-05  Eric Blake  <ebb9@byu.net>
23808
23809         Avoid quadratic system memmem.
23810         * m4/memmem.m4 (gl_FUNC_MEMMEM): Check for quadratic memmem.
23811         Reported by Ralf Wildenhues.
23812
23813         Fix memmem test for mingw.
23814         * modules/memmem-tests (configure.ac): Check for alarm.
23815         * tests/test-memmem.c (main): Avoid alarm on platforms that lack
23816         it.
23817         * doc/functions/memmem.texi: New file.
23818         * doc/gnulib.texi (Function Substitutes): Add memmem.
23819         Reported by Bruno Haible.
23820
23821 2008-01-04  Bruno Haible  <bruno@clisp.org>
23822
23823         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP):
23824         Require gl_HEADER_STRINGS_H_DEFAULTS, not
23825         gl_HEADER_STRING_H_DEFAULTS.
23826
23827 2008-01-04  Eric Blake  <ebb9@byu.net>
23828
23829         Shorten duration of memmem test.
23830         * tests/test-memmem.c (main): Use alarm to declare failure if test
23831         is taking too long.
23832         Reported by Ralf Wildenhues.
23833
23834 2007-12-21  Simon Josefsson  <simon@josefsson.org>
23835
23836         * modules/relocatable-prog-wrapper (Depends-on): Add intprops and
23837         string, needed by strerror.
23838
23839 2008-01-03  Colin Watson  <cjwatson@debian.org>
23840             Bruno Haible  <bruno@clisp.org>
23841
23842         * doc/gnulib-tool.texi (Localization): New section.
23843
23844 2008-01-02  Bruno Haible  <bruno@clisp.org>
23845
23846         * lib/memmem.c (knuth_morris_pratt, memmem): Change all 'char *'
23847         variables to 'unsigned char *' type.
23848         Reported by Paul Eggert.
23849
23850 2008-01-02  Jim Meyering  <jim@meyering.net>
23851
23852         * lib/version-etc.c (COPYRIGHT_YEAR): Increase for new year.
23853
23854 2007-12-31  Jim Meyering  <jim@meyering.net>
23855
23856         Avoid use of private FTS type name.
23857         * lib/fts.c (fts_sort): Use FTSENT rather than "struct _ftsent".
23858
23859 2007-12-30  Karl Berry  <karl@gnu.org>
23860
23861         * doc/gnulib.texi (Library vs. Reusable Code): remove period, to
23862         work around defect in Texinfo and/or the standalone Info browser.
23863
23864 2007-12-30  Bruno Haible  <bruno@clisp.org>
23865
23866         Unify 5 copies of the KMP code.
23867         * lib/str-kmp.h: New file.
23868         * lib/c-strcasestr.c: Include str-kmp.h.
23869         (knuth_morris_pratt): Remove function.
23870         (c_strcasestr): Update.
23871         * lib/c-strstr.c: Include str-kmp.h.
23872         (knuth_morris_pratt): Remove function.
23873         (c_strcasestr): Update.
23874         * lib/mbscasestr.c: Include str-kmp.h.
23875         (knuth_morris_pratt_unibyte): Remove function.
23876         * lib/mbsstr.c: Include str-kmp.h.
23877         (knuth_morris_pratt_unibyte): Remove function.
23878         * lib/strcasestr.c: Include str-kmp.h.
23879         (knuth_morris_pratt): Remove function.
23880         (strcasestr): Update.
23881         * modules/c-strcasestr (Files): Add lib/str-kmp.h.
23882         * modules/c-strstr (Files): Likewise.
23883         * modules/mbscasestr (Files): Likewise.
23884         * modules/mbsstr (Files): Likewise.
23885         * modules/strcasestr (Files): Likewise.
23886         Suggested by Paul Eggert.
23887
23888 2007-12-30  Bruno Haible  <bruno@clisp.org>
23889
23890         * lib/xmalloca.c (xmmalloca): Don't define if HAVE_ALLOCA is not
23891         defined.
23892
23893 2007-12-30  Bruno Haible  <bruno@clisp.org>
23894
23895         * lib/xmalloca.h: Include xalloc.h.
23896         (xnmalloca): New macro.
23897
23898 2007-12-30  Bruno Haible  <bruno@clisp.org>
23899
23900         * lib/malloca.h (nmalloca): New macro.
23901         * lib/c-strcasestr.c (knuth_morris_pratt): Use it.
23902         * lib/c-strstr.c (knuth_morris_pratt): Likewise.
23903         * lib/mbscasestr.c (knuth_morris_pratt_unibyte,
23904         knuth_morris_pratt_multibyte): Likewise.
23905         * lib/mbsstr.c (knuth_morris_pratt_unibyte,
23906         knuth_morris_pratt_multibyte): Likewise.
23907         * lib/memmem.c (knuth_morris_pratt): Likewise.
23908         * lib/strcasestr.c (knuth_morris_pratt): Likewise.
23909
23910 2007-12-25  Bruno Haible  <bruno@clisp.org>
23911
23912         Fixup after 2007-10-17 commit. Ensure that 'glob' stays under LGPLv2+.
23913         * lib/glob.c: Don't include openat.h.
23914         (link_exists2_p): Add back the code that deals with the
23915         !GLOB_ALTDIRFUNC case.
23916         (link_exists_p) [!_LIBC && !HAVE_FSTATAT]: Just call link_exists2_p and
23917         let it do the filename concatenation.
23918         * m4/glob.m4 (gl_PREREQ_GLOB): Add check for fstatat.
23919         * modules/glob (Depends-on): Remove openat.
23920
23921 2007-12-31  Bruno Haible  <bruno@clisp.org>
23922
23923         * modules/dirfd (License): Change to LGPLv2+.
23924         Approved by Jim Meyering.
23925
23926 2007-12-29  Paul Eggert  <eggert@cs.ucla.edu>
23927
23928         * lib/memmem.c (knuth_morris_pratt): Check for size_t overflow
23929         when multiplying M by sizeof (size_t).
23930
23931 2007-12-10  Martin Lambers  <marlam@marlam.de>
23932
23933         Override getpagesize on mingw.
23934         * lib/getpagesize.c: New file.
23935         * m4/getpagesize.m4 (gl_FUNC_GETPAGESIZE): Enable replacement on mingw.
23936         * modules/getpagesize (Files): Add lib/getpagesize.c.
23937         * lib/unistd.in.h (getpagesize): Declare if we are using a replacement.
23938         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
23939         REPLACE_GETPAGESIZE.
23940         * modules/unistd (Makefile.am): Substitute REPLACE_GETPAGESIZE.
23941
23942 2007-12-25  Bruno Haible  <bruno@clisp.org>
23943
23944         * modules/localcharset (Notice): New field.
23945         (configure.ac): Define LOCALCHARSET_TESTS_ENVIRONMENT.
23946         Suggested by Ben Pfaff <blp@cs.stanford.edu>.
23947
23948 2007-12-25  Paul Eggert  <eggert@cs.ucla.edu>
23949             Bruno Haible  <bruno@clisp.org>
23950
23951         Avoid using the syntax symbol() in formatted documentation.
23952         * MODULES.html.sh (func_module): When replacing symbol() with a
23953         hyperlink, remove the parentheses. Show an error if some remain.
23954         Recognize and render the '...' syntax.
23955         * doc/alloca-opt.texi: Remove parentheses from symbol reference.
23956         Rework. Add paragraph about GCC's inlining.
23957         * doc/alloca.texi: Likewise.
23958         * doc/error.texi: Remove parentheses from symbol reference.
23959         * doc/gnulib-intro.texi: Likewise.
23960         * doc/gnulib.texi (alloca, alloca-opt): New nodes.
23961         * modules/fnmatch (Description): Reword to say "the ... function".
23962         * modules/full-read (Description): Likewise.
23963         * modules/full-write (Description): Likewise.
23964         * modules/safe-read (Description): Likewise.
23965         * modules/safe-write (Description): Likewise.
23966         * modules/strchrnul (Description): Likewise.
23967         * modules/trim (Description): Likewise.
23968         * modules/error (Description): Remove parentheses from symbol
23969         references.
23970         * modules/verror (Description): Likewise.
23971         Reported by Karl Berry.
23972
23973 2007-12-25  Bruno Haible  <bruno@clisp.org>
23974
23975         Fixup after 2007-10-16 commit.
23976         * lib/glob.c (glob_in_dir): Don't use ISO C99 syntax.
23977
23978 2007-12-24  Bruno Haible  <bruno@clisp.org>
23979
23980         Make --enable-relocatable work with DESTDIR.
23981         * build-aux/install-reloc: Accept another argument 'destdir'. Use it
23982         to compute installdir from destprog.
23983         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): In INSTALL_PROGRAM_ENV,
23984         also set the RELOC_DESTDIR variable.
23985         Reported by Ð›ÐµÐ²Ð°ÑˆÐµÐ² Ð˜Ð²Ð°Ð½ <octagram@bluebottle.com>.
23986
23987 2007-12-24  Bruno Haible  <bruno@clisp.org>
23988
23989         Fix link error due to xalloc_die().
23990         * lib/progreloc.c: When NO_XMALLOC is defined, use areadlink instead
23991         of xreadlink.
23992         * lib/relocwrapper.c: Update comments.
23993         * build-aux/install-reloc: Remove xreadlink.c from file list.
23994         * modules/relocatable-prog-wrapper (Files): Remove xreadlink.h and
23995         xreadlink.c.
23996         Reported by Ð›ÐµÐ²Ð°ÑˆÐµÐ² Ð˜Ð²Ð°Ð½ <octagram@bluebottle.com>.
23997
23998 2007-12-24  Bruno Haible  <bruno@clisp.org>
23999
24000         Split setenv module into setenv and unsetenv. Get rid of setenv.h.
24001         * lib/setenv.h: Remove file.
24002         * lib/stdlib.in.h (setenv, unsetenv): New declarations, moved here from
24003         lib/setenv.h.
24004         * modules/setenv (Files): Remove lib/setenv.h, lib/unsetenv.c.
24005         (Depends-on): Add stdlib.
24006         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR. Don't invoke
24007         gl_FUNC_UNSETENV.
24008         (Include): Replace setenv.h with <stdlib.h>.
24009         * modules/unsetenv: New file.
24010         * lib/setenv.c: Include <stdlib.h> first, after alloca.h.
24011         * lib/unsetenv.c: Include <stdlib.h> first.
24012         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_SETENV_SEPARATE): Require
24013         gl_STDLIB_H_DEFAULTS. Conditionally set HAVE_SETENV to 0.
24014         (gl_FUNC_UNSETENV): Require gl_STDLIB_H_DEFAULTS. Conditionally set
24015         HAVE_UNSETENV to 0. Set VOID_UNSETENV as an AC_SUBSTed variable.
24016         * modules/stdlib (Makefile.am): Substitute also GNULIB_SETENV,
24017         HAVE_SETENV, GNULIB_UNSETENV, HAVE_UNSETENV, VOID_UNSETENV.
24018         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_SETENV,
24019         HAVE_SETENV, GNULIB_UNSETENV, HAVE_UNSETENV, VOID_UNSETENV.
24020         * doc/functions/unsetenv.texi: Update.
24021         * modules/xsetenv (Depends-on): Add unsetenv.
24022         * modules/getdate (Depends-on): Likewise.
24023         * lib/xsetenv.h: Include <stdlib.h> instead of setenv.h.
24024         * lib/xsetenv.c: Don't include setenv.h.
24025         * lib/getdate.y: Likewise.
24026         * lib/relocwrapper.c: Likewise.
24027         * modules/relocatable-prog-wrapper (Files): Remove lib/setenv.h.
24028         (Depends-on): Add stdlib.
24029         * NEWS: Mention the changes.
24030         Reported by Ð›ÐµÐ²Ð°ÑˆÐµÐ² Ð˜Ð²Ð°Ð½ <octagram@bluebottle.com>.
24031
24032 2007-12-23  Bruno Haible  <bruno@clisp.org>
24033
24034         * lib/memmem.c (memmem): Use lowercase variable names. Tab
24035         indentation.
24036
24037 2007-12-23  Bruno Haible  <bruno@clisp.org>
24038
24039         * lib/c-strcasestr.c: Add more comments.
24040         * lib/c-strstr.c: Likewise.
24041         * lib/mbscasestr.c: Likewise.
24042         * lib/mbsstr.c: Likewise.
24043         * lib/strcasestr.c: Likewise.
24044         * lib/memmem.c: Likewise.
24045
24046 2007-12-23  Bruno Haible  <bruno@clisp.org>
24047
24048         * tests/test-memmem.c: Include <string.h> first.
24049
24050 2007-12-22  Bruno Haible  <bruno@clisp.org>
24051
24052         * gnulib-tool (func_create_testdir): Change $auxdir while generating
24053         the contents of $testsbase.
24054         Reported by Ralf Wildenhues.
24055
24056 2007-12-22  Bruno Haible  <bruno@clisp.org>
24057
24058         * gnulib-tool (func_emit_tests_Makefile_am): Replace local_ldadd with
24059         two variables local_ldadd_before, local_ldadd_last.
24060
24061 2007-12-20  Eric Blake  <ebb9@byu.net>
24062
24063         Work around circular library issue when cross-compiling.
24064         * lib/progname.c (set_program_name): Use strncmp, not memcmp, so
24065         that progname.o does not need to pull in rpl_memcmp.
24066
24067 2007-12-19  Eric Blake  <ebb9@byu.net>
24068
24069         Fix memmem to avoid O(n^2) worst-case complexity.
24070         * lib/memmem.c (knuth_morris_pratt): New function.
24071         (memmem): Use it if first few naive iterations fail.
24072         * m4/memmem.m4 (gl_FUNC_MEMMEM): Detect cygwin bug.
24073         * modules/memcmp (License): Set to LGPLv2+, not LGPL.
24074         * modules/memchr (License): Likewise.
24075         * modules/memmem (Depends-on): Add memcmp, memchr, stdbool, and
24076         malloca.
24077         * tests/test-memmem.c: Rewrite, borrowing ideas from
24078         test-mbsstr1.c; the old version wouldn't even compile!
24079         * modules/memmem-tests: New file.
24080         * lib/string.in.h (rpl_memmem): Add declaration.
24081         * modules/string (Makefile.am): Substitute REPLACE_MEMMEM.
24082         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Default for
24083         REPLACE_MEMMEM.
24084
24085 2007-12-18  Paul Eggert  <eggert@cs.ucla.edu>
24086
24087         Fix problem with _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H on VMS.
24088         * lib/stdint.in.h (_GL_JUST_INCLUDE_SYSTEM_INTTYPES_H): Define
24089         before any system include files, and undef after them all.  This
24090         should fix a problem on VMS reported by John E. Malmberg in
24091         <http://lists.gnu.org/archive/html/bug-gnulib/2007-12/msg00118.html>.
24092
24093 2007-12-17  Eric Blake  <ebb9@byu.net>
24094
24095         Revert addition of verify, for BSD/OS.
24096         * lib/fseeko.c [!HAVE_FSEEKO]: Allow off_t > long, even though it
24097         can't handle large files, for the sake of obsolete platforms.
24098         * modules/fseeko (Depends-on): Remove verify.
24099         * doc/functions/fseeko.texi (fseeko): Document BSD/OS limitation.
24100         * doc/functions/ftello.texi (ftello): Likewise.
24101         * doc/functions/fgetpos.texi (fgetpos): Likewise.
24102         Reported by Larry Jones.
24103
24104 2007-12-17  Petr Salinger  <Petr.Salinger@seznam.cz>
24105
24106         getcwd.c: Use a more readable witness: HAVE_OPENAT_SUPPORT
24107         * lib/getcwd.c: Define and use HAVE_OPENAT_SUPPORT, in place of AT_FDCWD.
24108
24109 2007-12-17  Jim Meyering  <meyering@redhat.com>
24110
24111         Port to GNU/kFreeBSD - FreeBSD kernel + GNU libc,
24112         which has no openat syscall, yet <fcntl.h> does define AT_FDCWD.
24113         * lib/getcwd.c: Undef AT_FDCWD if there is no openat function.
24114         * modules/getcwd (Depends-on): Add openat.
24115         Reported by Petr Salinger.
24116
24117 2007-12-17  Bruno Haible  <bruno@clisp.org>
24118
24119         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Use GL_NOCRASH to
24120         avoid a segmentation fault of the configure test on x86_64 systems.
24121
24122 2007-12-15  Jim Meyering  <meyering@redhat.com>
24123
24124         * build-aux/gnupload (GPG): Don't hard-code absolute name of gpg binary.
24125
24126 2007-12-13  Eric Blake  <ebb9@byu.net>
24127
24128         Another fseek test.
24129         * tests/test-fseek.c (main): Also test ungetc handling.
24130         * tests/test-fseeko.c (main): Likewise.
24131         * modules/fseeko (Depends-on): Add verify.
24132         * lib/fseeko.c [!HAVE_FSEEKO]: Verify that off_t is not too
24133         large.
24134         Reported by Larry Jones.
24135
24136         Fix fseeko on mingw.
24137         * lib/fseeko.c (rpl_fseeko) [_IOERR]: Reset EOF flag on successful
24138         seek.
24139
24140         Beef up fseek tests.
24141         * tests/test-fseek.c (main): Also test eof handling.
24142         * tests/test-fseeko.c (main): Likewise.
24143         Reported by Larry Jones.
24144
24145 2007-12-13  Larry Jones  <lawrence.jones@siemens.com>  (tiny change)
24146
24147         Fix fseeko on BSD-based platforms.
24148         * lib/fseeko.c (rpl_fseeko) [__sferror]: Reset EOF flag on
24149         successful seek.
24150
24151 2007-12-12  Eric Blake  <ebb9@byu.net>
24152
24153         Allow circular dependency of separate libtests.a
24154         * gnulib-tool (func_emit_tests_Makefile_am): Add AM_LIBTOOLFLAGS
24155         when use_libtests.
24156
24157 2007-12-11  Eric Blake  <ebb9@byu.net>
24158
24159         Fix bug with -0.0L in previous patch.
24160         * lib/isnan.c (rpl_isnanl): Make robust to -0.0L and pad bits.
24161         * tests/test-isnan.c (main): Also test on zeroes.
24162         * tests/test-isnanf.c (main): Likewise.
24163         * tests/test-isnanl.h (main): Likewise.
24164
24165         Detect pseudo-denormals on x86 even when cross-compiling.
24166         * lib/isnan.c (rpl_isnanl) [!KNOWN_EXPBIT0_LOCATION
24167         && USE_LONG_DOUBLE && x86]: Add one more check to filter out
24168         invalid bit patterns that happen to satisfy ==.
24169
24170         Avoid link failures with separate libtests.a.
24171         * gnulib-tool (func_emit_tests_Makefile_am): Also list local_ldadd
24172         last, to satisfy circular dependencies.
24173
24174 2007-12-11  Eric Blake  <ebb9@byu.net>
24175         and Bruno Haible  <bruno@clisp.org>
24176
24177         Fix OpenBSD 4.0 <float.h> handling of long double.
24178         * m4/float_h.m4 (gl_FLOAT_H): Also claim OpenBSD is broken.
24179         * lib/float.in.h [__OpenBSD__]: Add fixes for OpenBSD.
24180         * doc/headers/float.texi (float.h): Document OpenBSD bug.
24181
24182 2007-12-11  Jim Meyering  <meyering@redhat.com>
24183
24184         * users.txt: Add libvirt.
24185
24186         Support versions of autoconf prior to 2.59c.
24187         * gnulib-tool (func_emit_initmacro_done): Define m4_foreach_w
24188         if it is not already defined.
24189
24190 2007-12-09  Bruno Haible  <bruno@clisp.org>
24191
24192         Let 'gnulib-tool --import' collect sources needed for the tests in
24193         tests/ rather than in lib/.
24194         * gnulib-tool (func_emit_tests_Makefile_am): Accept use_libtests
24195         argument. If true, add rules to generate libtests.a, and put libtests.a
24196         into $(LDADD). Consider source files in subdirectories and set
24197         uses_subdirs.
24198         (func_emit_initmacro_start, func_emit_initmacro_end,
24199         func_emit_initmacro_done): Pass all arguments explicitly.
24200         (func_import): Determine two module lists main_modules,
24201         testsrelated_modules. Determine use_libtests. Determine two variables
24202         sed_transform_main_lib_file, sed_transform_testsrelated_lib_file
24203         instead of just sed_transform_lib_file. Determine two variables
24204         main_files and testsrelated_files. Compute 'files' as the union of
24205         both. Adjust sed_rewrite_old_files, sed_rewrite_new_files,
24206         func_add_or_update. In the generated gnulib-comp.m4, collect the
24207         object files for tests/ in different variables than those for lib/.
24208         Substitute LIBTESTS_LIBDEPS.
24209         (func_create_testdir): Combine the uses_subdirs results from
24210         func_emit_lib_Makefile_am and from func_emit_tests_Makefile_am.
24211
24212 2007-12-09  Bruno Haible  <bruno@clisp.org>
24213
24214         * gnulib-tool (func_emit_tests_Makefile_am): Expand references to
24215         the build-aux directory.
24216
24217 2007-12-09  Bruno Haible  <bruno@clisp.org>
24218
24219         * gnulib-tool (func_emit_tests_Makefile_am): Remove redundant code
24220         introduced on 2006-09-09.
24221
24222 2007-12-07  Jim Meyering  <meyering@redhat.com>
24223
24224         Let these macros work also with autoconf-2.59.
24225         * m4/getline.m4 (gl_FUNC_GETLINE): Require only autoconf-2.59.  2.60
24226         is not needed, since gnulib now permits use of AC_CHECK_DECLS_ONCE.
24227         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
24228
24229 2007-12-06  Jim Meyering  <meyering@redhat.com>
24230
24231         Avoid a configure-time syntax error in gl_FUNC_ACL.
24232         * m4/acl.m4 (gl_FUNC_ACL): Be careful to check for the acl_trivial
24233         function in each branch, before testing the cache variable.
24234
24235 2007-12-04  Eric Blake  <ebb9@byu.net>
24236
24237         Make scripts executable.
24238         * build-aux/config.guess: Add execute permissions.
24239         * build-aux/config.sub: Likewise.
24240         * build-aux/gendocs.sh: Likewise.
24241
24242         Fix frexp on mingw.
24243         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Detect mingw bug when
24244         cross-compiling.
24245         * doc/functions/frexp.texi (frexp): Document the bug.
24246
24247         Make cygwin fseeko check more reliable.
24248         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET) [__CYGWIN__]: Use cygwin
24249         version numbers, rather than unrelated feature check.
24250         * doc/functions/fseeko.texi (fseeko): Tweak failure report.
24251         * doc/functions/ftello.texi (ftello): Likewise.
24252         Reported by Bruno Haible.
24253
24254         * m4/strerror.m4: Bump version number.
24255
24256 2007-12-03  Bruno Haible  <bruno@clisp.org>
24257
24258         * doc/functions/mprotect.texi: Mention the mingw problem.
24259
24260 2007-12-03  Eric Blake  <ebb9@byu.net>
24261
24262         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): Ensure
24263         REPLACE_STRERROR is initialized before this macro.
24264
24265 2007-12-03  Paul Eggert  <eggert@cs.ucla.edu>
24266
24267         Add support for Solaris 10 ACLs.  Also, ACLs are Gnulib, not Autoconf.
24268         * modules/acl (configure.ac): Rename AC_FUNC_ACL to gl_FUNC_ACL.
24269         * m4/acl.m4 (gl_FUNC_ACL): Renamed from AC_FUNC_ACL.  On Solaris,
24270         put -lsec in even for programs other than 'ls'.  This fixes a problem
24271         for gettext reported by Bruno Haible in
24272         <http://lists.gnu.org/archive/html/bug-gnulib/2007-12/msg00007.html>.
24273         * lib/acl.c (copy_acl, qset_acl) [USE_ACL && defined ACL_NO_TRIVIAL]:
24274         Add support for Solaris 10.  This isn't efficient, but should get the
24275         job done for now.
24276
24277 2007-12-03  James Youngman  <jay@gnu.org>
24278
24279         * doc/regexprops-generic.texi: change "an close-group" to "a
24280         close-group" and "illegal" to "not allowed".
24281
24282 2007-11-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
24283
24284         * lib/unictype/pr_byname.c: Include unictype/pr_byname.h instead of
24285         pr_byname.h. Needed for the rare case when the maintainer has done
24286         "make maintainer-clean" in the source directory and then attempts a
24287         build outside the source directory.
24288         * lib/unictype/scripts.c: Include unictype/scripts_byname.h instead of
24289         scripts_byname.h.
24290
24291 2007-12-02  Martin Lambers <marlam@marlam.de>
24292             Bruno Haible  <bruno@clisp.org>
24293
24294         * lib/getpagesize.h: Remove file.
24295         * lib/unistd.in.h: Include declaration of getpagesize here.
24296         * m4/getpagesize.m4 (gl_FUNC_GETPAGESIZE): Renamed from gl_GETPAGESIZE.
24297         Invoke gl_UNISTD_H_DEFAULTS. Set HAVE_GETPAGESIZE, HAVE_OS_H,
24298         HAVE_SYS_PARAM_H.
24299         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETPAGESIZE,
24300         HAVE_GETPAGESIZE, HAVE_OS_H, HAVE_SYS_PARAM_H.
24301         * modules/getpagesize (Files): Remove lib/getpagesize.h.
24302         (Depends-on): Add unistd.
24303         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
24304         (Include): Use <unistd.h> instead of getpagesize.h.
24305         * modules/unistd (Makefile.am): Substitute also GNULIB_GETPAGESIZE,
24306         HAVE_GETPAGESIZE, HAVE_OS_H, HAVE_SYS_PARAM_H.
24307         * m4/pagealign_alloc.m4 (gl_PREREQ_PAGEALIGN_ALLOC): Remove
24308         gl_GETPAGESIZE invocation, already handled by module dependency.
24309         * lib/pagealign_alloc.c: Don't include getpagesize.h.
24310
24311 2007-12-02  Bruno Haible  <bruno@clisp.org>
24312
24313         * modules/strings-tests: New file.
24314         * tests/test-strings.c: New file.
24315
24316         Move declarations of str{,n}casecmp from <string.h> to <strings.h>.
24317         * lib/strings.in.h: New file.
24318         * lib/string.in.h (strcasecmp, strncasecmp): Remove declarations.
24319         * m4/strings_h.m4: New file.
24320         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Remove initialization
24321         of HAVE_STRCASECMP, HAVE_DECL_STRNCASECMP.
24322         * modules/strings: New file.
24323         * modules/string (Makefile.am): Update.
24324         * modules/strcase (Include): Mention <strings.h>, not <string.h>.
24325         Reported by Karl Berry.
24326
24327 2007-12-01  Eric Blake  <ebb9@byu.net>
24328
24329         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET) [__CYGWIN__]: Rewrite to
24330         accomodate fix in cygwin 1.5.25.
24331
24332 2007-12-01  Jim Meyering  <meyering@redhat.com>
24333
24334         Fix a bug that inhibited much of the utf8-optimization in regcomp.c.
24335         * lib/regcomp.c (optimize_utf8): Fix a typo, s/idx/ctx_type/,
24336         that would inhibit utf8-optimization of a regexp containing line-
24337         or buffer-anchors, e.g., `^', `$'.
24338
24339 2007-11-30  Bruno Haible  <bruno@clisp.org>
24340
24341         * lib/lock.h (gl_recursive_lock_init) [PTHREAD &&
24342         PTHREAD_RECURSIVE_MUTEX_INITIALIZER]: Call
24343         glthread_recursive_lock_init.
24344         * lib/lock.c (glthread_recursive_lock_init)
24345         [PTHREAD_RECURSIVE_MUTEX_INITIALIZER]: New function.
24346         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
24347
24348 2007-11-28  Paul Eggert  <eggert@cs.ucla.edu>
24349
24350         New function qset_acl, like set_acl but with syscall semantics.
24351         * lib/acl.h (qset_acl): New decl.
24352         * lib/acl.c (qset_acl): New function.
24353         (set_acl): Use new function.  Use more-consistent diagnostics.
24354
24355 2007-11-28  Jim Meyering  <meyering@redhat.com>
24356
24357         * modules/physmem (License): Change from GPL to LGPLv2+.
24358
24359 2007-11-26  Bruno Haible  <bruno@clisp.org>
24360
24361         * lib/vasnprintf.c (decode_long_double): Don't abort if the
24362         'long double' type has excess precision.
24363         Reported by Jim Meyering in
24364         <http://lists.gnu.org/archive/html/bug-gnulib/2007-11/msg00120.html>.
24365
24366 2007-11-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
24367
24368         * doc/fdl.texi, doc/gpl-3.0.texi, doc/lgpl-3.0.texi:
24369         Sync from <http://gnu.org/licenses>.
24370         * modules/agpl-3.0, doc/agpl-3.0.texi: New module,
24371         with license text from same location.
24372         * doc/maintain.texi, doc/standards.texi:  Sync from
24373         <http://savannah.gnu.org/projects/gnustandards>.
24374
24375 2007-11-22  OndÅ™ej Vašík  <ovasik@redhat.com>
24376         and Jim Meyering  <meyering@redhat.com>
24377
24378         Adjust getdate' grammar to accept a slightly more regular language.
24379         E.g., accept "YYYYMMDD +N days" as well as "YYYYMMDD N days".
24380         Before, the former was rejected.
24381         * lib/getdate.y (digits_to_date_time): New function, factored
24382         out of ...
24383         (number): ...here.  Just call digits_to_date_time.
24384         (hybrid): New non-terminal to handle an <unsigned number,
24385         signed relative offset> sequence consistently.
24386
24387 2007-11-18  Jim Meyering  <meyering@redhat.com>
24388
24389         Pull my changes from coreutils:
24390         bootstrap: fix typo to enable use of $gnulib_tool_option_extras.
24391         * build-aux/bootstrap (gnulib_tool_options): Add a space before the
24392         use of $gnulib_tool_option_extras, so that it's separated from the
24393         preceding argument.
24394
24395         Fix bootstrap failure to handle files like lib/uniwidth/cjk.h.
24396         * build-aux/bootstrap (cp_mark_as_generated): Create any required
24397         parent destination directories before copying a file into place.
24398
24399 2007-11-18  Sergey Poznyakoff  <gray@gnu.org.ua>
24400
24401         bootstrap: work also with 4-argument variant of AC_INIT
24402         * build-aux/bootstrap (gnulib_extra_files): Adjust sed command.
24403
24404 2007-11-16  Paul Eggert  <eggert@cs.ucla.edu>
24405
24406         Port test-getaddrinfo to Solaris.
24407         Problem reported by Bruno Haible in
24408         <http://lists.gnu.org/archive/html/bug-gnulib/2007-03/msg00171.html>.
24409         * tests/test-getaddrinfo.c (simple): Add a comment asking for an
24410         explanation of setting 'hints'.
24411         Don't reject an implementation merely because it returns EAI_SERVICE.
24412         (EAI_SERVICE): Define to 0 if not defined.
24413
24414 2007-11-15  Paul Eggert  <eggert@cs.ucla.edu>
24415
24416         The license of gnu-make and posix-shell is now "GPLed build tool".
24417         * modules/gnu-make (License): Likewise.
24418         * modules/posix-shell (License): Likewise.
24419
24420         New module posix-shell, for determining a POSIX shell
24421         or perhaps something that is close enough to a POSIX shell.
24422         * m4/posix-shell.m4: New file.
24423         * modules/posix-shell: New file.
24424
24425         * MODULES.html.sh: Mention new module.
24426
24427         New module gnu-make, for determining whether we're using GNU Make.
24428         * m4/gnu-make.m4: New file.
24429         * modules/gnu-make: New file.
24430         * MODULES.html.sh: Mention new module.
24431
24432 2007-11-14  Jim Meyering  <meyering@redhat.com>
24433
24434         Define a sometimes-link-required function using ARGMATCH_DIE_DECL.
24435         * tests/test-argmatch.c (ARGMATCH_DIE_DECL): When defined,
24436         use this macro to create a function _definition_.
24437         Remove useless "#undef ARGMATCH_DIE".
24438
24439 2007-11-14  Bruno Haible  <bruno@clisp.org>
24440
24441         * lib/config.charset: Update for OpenBSD 4.1.
24442         Reported and helped by Ben Pfaff <blp@cs.stanford.edu>.
24443
24444 2007-11-12  Paul Eggert  <eggert@cs.ucla.edu>
24445
24446         Document 64-bit #if problems in stdint.texi.
24447         * doc/headers/stdint.texi (stdint.h): Mention problems with
24448         64-bit-#if, and how to work around them.
24449
24450         Don't insist on 'long long int' support in the preprocessor.  It
24451         breaks too many things.  For example, PRIdMAX still uses a 'long
24452         long int' format with the latest Sun compiler, even though
24453         HAVE_LONG_LONG_INT isn't defined due to that compiler's
24454         preprocessor problem.  This causes the latest coreutils to dump
24455         core on Solaris 10 sparc with the Sun C compiler.
24456         Instead, fix the 2007-10-16 problem in a different way, by evaluating
24457         the troublesome expressions at configure-time, not at #if-time.
24458         * m4/longlong.m4 (_AC_TYPE_LONG_LONG_SNIPPET): Don't test the
24459         preprocessor.
24460         * m4/inttypes.m4 (gl_INTTYPES_H): Move the #if checks into
24461         compile-time C checks, done at 'configure'-time.
24462         (gl_INTTYPES_CHECK_LONG_LONG_INT_CONDITION): New macro.
24463         * modules/inttypes (Makefile): Substitute the new symbols that
24464         gl_INTTYPES_H now generates.
24465         * lib/inttypes.in.h: Don't use constants wider than 'long' in #if.
24466
24467 2007-11-12  Bruno Haible  <bruno@clisp.org>
24468
24469         Tests for Unicode character classification functions.
24470
24471         * modules/unictype/bidicategory-byname-tests: New file.
24472         * modules/unictype/bidicategory-name-tests: New file.
24473         * modules/unictype/bidicategory-of-tests: New file.
24474         * modules/unictype/bidicategory-test-tests: New file.
24475         * modules/unictype/block-list-tests: New file.
24476         * modules/unictype/block-of-tests: New file.
24477         * modules/unictype/block-test-tests: New file.
24478         * modules/unictype/category-C-tests: New file.
24479         * modules/unictype/category-Cc-tests: New file.
24480         * modules/unictype/category-Cf-tests: New file.
24481         * modules/unictype/category-Cn-tests: New file.
24482         * modules/unictype/category-Co-tests: New file.
24483         * modules/unictype/category-Cs-tests: New file.
24484         * modules/unictype/category-L-tests: New file.
24485         * modules/unictype/category-Ll-tests: New file.
24486         * modules/unictype/category-Lm-tests: New file.
24487         * modules/unictype/category-Lo-tests: New file.
24488         * modules/unictype/category-Lt-tests: New file.
24489         * modules/unictype/category-Lu-tests: New file.
24490         * modules/unictype/category-M-tests: New file.
24491         * modules/unictype/category-Mc-tests: New file.
24492         * modules/unictype/category-Me-tests: New file.
24493         * modules/unictype/category-Mn-tests: New file.
24494         * modules/unictype/category-N-tests: New file.
24495         * modules/unictype/category-Nd-tests: New file.
24496         * modules/unictype/category-Nl-tests: New file.
24497         * modules/unictype/category-No-tests: New file.
24498         * modules/unictype/category-P-tests: New file.
24499         * modules/unictype/category-Pc-tests: New file.
24500         * modules/unictype/category-Pd-tests: New file.
24501         * modules/unictype/category-Pe-tests: New file.
24502         * modules/unictype/category-Pf-tests: New file.
24503         * modules/unictype/category-Pi-tests: New file.
24504         * modules/unictype/category-Po-tests: New file.
24505         * modules/unictype/category-Ps-tests: New file.
24506         * modules/unictype/category-S-tests: New file.
24507         * modules/unictype/category-Sc-tests: New file.
24508         * modules/unictype/category-Sk-tests: New file.
24509         * modules/unictype/category-Sm-tests: New file.
24510         * modules/unictype/category-So-tests: New file.
24511         * modules/unictype/category-Z-tests: New file.
24512         * modules/unictype/category-Zl-tests: New file.
24513         * modules/unictype/category-Zp-tests: New file.
24514         * modules/unictype/category-Zs-tests: New file.
24515         * modules/unictype/category-and-not-tests: New file.
24516         * modules/unictype/category-and-tests: New file.
24517         * modules/unictype/category-byname-tests: New file.
24518         * modules/unictype/category-name-tests: New file.
24519         * modules/unictype/category-none-tests: New file.
24520         * modules/unictype/category-of-tests: New file.
24521         * modules/unictype/category-or-tests: New file.
24522         * modules/unictype/category-test-withtable-tests: New file.
24523         * modules/unictype/combining-class-tests: New file.
24524         * modules/unictype/ctype-alnum-tests: New file.
24525         * modules/unictype/ctype-alpha-tests: New file.
24526         * modules/unictype/ctype-blank-tests: New file.
24527         * modules/unictype/ctype-cntrl-tests: New file.
24528         * modules/unictype/ctype-digit-tests: New file.
24529         * modules/unictype/ctype-graph-tests: New file.
24530         * modules/unictype/ctype-lower-tests: New file.
24531         * modules/unictype/ctype-print-tests: New file.
24532         * modules/unictype/ctype-punct-tests: New file.
24533         * modules/unictype/ctype-space-tests: New file.
24534         * modules/unictype/ctype-upper-tests: New file.
24535         * modules/unictype/ctype-xdigit-tests: New file.
24536         * modules/unictype/decimal-digit-tests: New file.
24537         * modules/unictype/digit-tests: New file.
24538         * modules/unictype/mirror-tests: New file.
24539         * modules/unictype/numeric-tests: New file.
24540         * modules/unictype/property-alphabetic-tests: New file.
24541         * modules/unictype/property-ascii-hex-digit-tests: New file.
24542         * modules/unictype/property-bidi-arabic-digit-tests: New file.
24543         * modules/unictype/property-bidi-arabic-right-to-left-tests: New file.
24544         * modules/unictype/property-bidi-block-separator-tests: New file.
24545         * modules/unictype/property-bidi-boundary-neutral-tests: New file.
24546         * modules/unictype/property-bidi-common-separator-tests: New file.
24547         * modules/unictype/property-bidi-control-tests: New file.
24548         * modules/unictype/property-bidi-embedding-or-override-tests: New file.
24549         * modules/unictype/property-bidi-eur-num-separator-tests: New file.
24550         * modules/unictype/property-bidi-eur-num-terminator-tests: New file.
24551         * modules/unictype/property-bidi-european-digit-tests: New file.
24552         * modules/unictype/property-bidi-hebrew-right-to-left-tests: New file.
24553         * modules/unictype/property-bidi-left-to-right-tests: New file.
24554         * modules/unictype/property-bidi-non-spacing-mark-tests: New file.
24555         * modules/unictype/property-bidi-other-neutral-tests: New file.
24556         * modules/unictype/property-bidi-pdf-tests: New file.
24557         * modules/unictype/property-bidi-segment-separator-tests: New file.
24558         * modules/unictype/property-bidi-whitespace-tests: New file.
24559         * modules/unictype/property-byname-tests: New file.
24560         * modules/unictype/property-combining-tests: New file.
24561         * modules/unictype/property-composite-tests: New file.
24562         * modules/unictype/property-currency-symbol-tests: New file.
24563         * modules/unictype/property-dash-tests: New file.
24564         * modules/unictype/property-decimal-digit-tests: New file.
24565         * modules/unictype/property-default-ignorable-code-point-tests: New file.
24566         * modules/unictype/property-deprecated-tests: New file.
24567         * modules/unictype/property-diacritic-tests: New file.
24568         * modules/unictype/property-extender-tests: New file.
24569         * modules/unictype/property-format-control-tests: New file.
24570         * modules/unictype/property-grapheme-base-tests: New file.
24571         * modules/unictype/property-grapheme-extend-tests: New file.
24572         * modules/unictype/property-grapheme-link-tests: New file.
24573         * modules/unictype/property-hex-digit-tests: New file.
24574         * modules/unictype/property-hyphen-tests: New file.
24575         * modules/unictype/property-id-continue-tests: New file.
24576         * modules/unictype/property-id-start-tests: New file.
24577         * modules/unictype/property-ideographic-tests: New file.
24578         * modules/unictype/property-ids-binary-operator-tests: New file.
24579         * modules/unictype/property-ids-trinary-operator-tests: New file.
24580         * modules/unictype/property-ignorable-control-tests: New file.
24581         * modules/unictype/property-iso-control-tests: New file.
24582         * modules/unictype/property-join-control-tests: New file.
24583         * modules/unictype/property-left-of-pair-tests: New file.
24584         * modules/unictype/property-line-separator-tests: New file.
24585         * modules/unictype/property-logical-order-exception-tests: New file.
24586         * modules/unictype/property-lowercase-tests: New file.
24587         * modules/unictype/property-math-tests: New file.
24588         * modules/unictype/property-non-break-tests: New file.
24589         * modules/unictype/property-not-a-character-tests: New file.
24590         * modules/unictype/property-numeric-tests: New file.
24591         * modules/unictype/property-other-alphabetic-tests: New file.
24592         * modules/unictype/property-other-default-ignorable-code-point-tests: New file.
24593         * modules/unictype/property-other-grapheme-extend-tests: New file.
24594         * modules/unictype/property-other-id-continue-tests: New file.
24595         * modules/unictype/property-other-id-start-tests: New file.
24596         * modules/unictype/property-other-lowercase-tests: New file.
24597         * modules/unictype/property-other-math-tests: New file.
24598         * modules/unictype/property-other-uppercase-tests: New file.
24599         * modules/unictype/property-paired-punctuation-tests: New file.
24600         * modules/unictype/property-paragraph-separator-tests: New file.
24601         * modules/unictype/property-pattern-syntax-tests: New file.
24602         * modules/unictype/property-pattern-white-space-tests: New file.
24603         * modules/unictype/property-private-use-tests: New file.
24604         * modules/unictype/property-punctuation-tests: New file.
24605         * modules/unictype/property-quotation-mark-tests: New file.
24606         * modules/unictype/property-radical-tests: New file.
24607         * modules/unictype/property-sentence-terminal-tests: New file.
24608         * modules/unictype/property-soft-dotted-tests: New file.
24609         * modules/unictype/property-space-tests: New file.
24610         * modules/unictype/property-terminal-punctuation-tests: New file.
24611         * modules/unictype/property-test-tests: New file.
24612         * modules/unictype/property-titlecase-tests: New file.
24613         * modules/unictype/property-unassigned-code-value-tests: New file.
24614         * modules/unictype/property-unified-ideograph-tests: New file.
24615         * modules/unictype/property-uppercase-tests: New file.
24616         * modules/unictype/property-variation-selector-tests: New file.
24617         * modules/unictype/property-white-space-tests: New file.
24618         * modules/unictype/property-xid-continue-tests: New file.
24619         * modules/unictype/property-xid-start-tests: New file.
24620         * modules/unictype/property-zero-width-tests: New file.
24621         * modules/unictype/scripts-tests: New file.
24622         * modules/unictype/syntax-c-ident-tests: New file.
24623         * modules/unictype/syntax-c-whitespace-tests: New file.
24624         * modules/unictype/syntax-java-ident-tests: New file.
24625         * modules/unictype/syntax-java-whitespace-tests: New file.
24626         * tests/unictype/test-bidi_byname.c: New file.
24627         * tests/unictype/test-bidi_name.c: New file.
24628         * tests/unictype/test-bidi_of.c: New file.
24629         * tests/unictype/test-bidi_test.c: New file.
24630         * tests/unictype/test-block_list.c: New file.
24631         * tests/unictype/test-block_of.c: New file.
24632         * tests/unictype/test-block_test.c: New file.
24633         * tests/unictype/test-categ_and.c: New file.
24634         * tests/unictype/test-categ_and_not.c: New file.
24635         * tests/unictype/test-categ_byname.c: New file.
24636         * tests/unictype/test-categ_name.c: New file.
24637         * tests/unictype/test-categ_none.c: New file.
24638         * tests/unictype/test-categ_of.c: New file.
24639         * tests/unictype/test-categ_or.c: New file.
24640         * tests/unictype/test-categ_test_withtable.c: New file.
24641         * tests/unictype/test-combining.c: New file.
24642         * tests/unictype/test-decdigit.c: New file.
24643         * tests/unictype/test-digit.c: New file.
24644         * tests/unictype/test-mirror.c: New file.
24645         * tests/unictype/test-numeric.c: New file.
24646         * tests/unictype/test-pr_byname.c: New file.
24647         * tests/unictype/test-pr_test.c: New file.
24648         * tests/unictype/test-predicate-part1.h: New file.
24649         * tests/unictype/test-predicate-part2.h: New file.
24650         * tests/unictype/test-scripts.c: New file.
24651         * tests/unictype/test-sy_c_ident.c: New file.
24652         * tests/unictype/test-sy_java_ident.c: New file.
24653
24654         * tests/unictype/test-categ_C.c: New file, generated by gen-ctype.c
24655         for Unicode 5.0.0.
24656         * tests/unictype/test-categ_Cc.c: Likewise.
24657         * tests/unictype/test-categ_Cf.c: Likewise.
24658         * tests/unictype/test-categ_Cn.c: Likewise.
24659         * tests/unictype/test-categ_Co.c: Likewise.
24660         * tests/unictype/test-categ_Cs.c: Likewise.
24661         * tests/unictype/test-categ_L.c: Likewise.
24662         * tests/unictype/test-categ_Ll.c: Likewise.
24663         * tests/unictype/test-categ_Lm.c: Likewise.
24664         * tests/unictype/test-categ_Lo.c: Likewise.
24665         * tests/unictype/test-categ_Lt.c: Likewise.
24666         * tests/unictype/test-categ_Lu.c: Likewise.
24667         * tests/unictype/test-categ_M.c: Likewise.
24668         * tests/unictype/test-categ_Mc.c: Likewise.
24669         * tests/unictype/test-categ_Me.c: Likewise.
24670         * tests/unictype/test-categ_Mn.c: Likewise.
24671         * tests/unictype/test-categ_N.c: Likewise.
24672         * tests/unictype/test-categ_Nd.c: Likewise.
24673         * tests/unictype/test-categ_Nl.c: Likewise.
24674         * tests/unictype/test-categ_No.c: Likewise.
24675         * tests/unictype/test-categ_P.c: Likewise.
24676         * tests/unictype/test-categ_Pc.c: Likewise.
24677         * tests/unictype/test-categ_Pd.c: Likewise.
24678         * tests/unictype/test-categ_Pe.c: Likewise.
24679         * tests/unictype/test-categ_Pf.c: Likewise.
24680         * tests/unictype/test-categ_Pi.c: Likewise.
24681         * tests/unictype/test-categ_Po.c: Likewise.
24682         * tests/unictype/test-categ_Ps.c: Likewise.
24683         * tests/unictype/test-categ_S.c: Likewise.
24684         * tests/unictype/test-categ_Sc.c: Likewise.
24685         * tests/unictype/test-categ_Sk.c: Likewise.
24686         * tests/unictype/test-categ_Sm.c: Likewise.
24687         * tests/unictype/test-categ_So.c: Likewise.
24688         * tests/unictype/test-categ_Z.c: Likewise.
24689         * tests/unictype/test-categ_Zl.c: Likewise.
24690         * tests/unictype/test-categ_Zp.c: Likewise.
24691         * tests/unictype/test-categ_Zs.c: Likewise.
24692         * tests/unictype/test-ctype_alnum.c: Likewise.
24693         * tests/unictype/test-ctype_alpha.c: Likewise.
24694         * tests/unictype/test-ctype_blank.c: Likewise.
24695         * tests/unictype/test-ctype_cntrl.c: Likewise.
24696         * tests/unictype/test-ctype_digit.c: Likewise.
24697         * tests/unictype/test-ctype_graph.c: Likewise.
24698         * tests/unictype/test-ctype_lower.c: Likewise.
24699         * tests/unictype/test-ctype_print.c: Likewise.
24700         * tests/unictype/test-ctype_punct.c: Likewise.
24701         * tests/unictype/test-ctype_space.c: Likewise.
24702         * tests/unictype/test-ctype_upper.c: Likewise.
24703         * tests/unictype/test-ctype_xdigit.c: Likewise.
24704         * tests/unictype/test-decdigit.h: Likewise.
24705         * tests/unictype/test-digit.h: Likewise.
24706         * tests/unictype/test-numeric.h: Likewise.
24707         * tests/unictype/test-pr_alphabetic.c: Likewise.
24708         * tests/unictype/test-pr_ascii_hex_digit.c: Likewise.
24709         * tests/unictype/test-pr_bidi_arabic_digit.c: Likewise.
24710         * tests/unictype/test-pr_bidi_arabic_right_to_left.c: Likewise.
24711         * tests/unictype/test-pr_bidi_block_separator.c: Likewise.
24712         * tests/unictype/test-pr_bidi_boundary_neutral.c: Likewise.
24713         * tests/unictype/test-pr_bidi_common_separator.c: Likewise.
24714         * tests/unictype/test-pr_bidi_control.c: Likewise.
24715         * tests/unictype/test-pr_bidi_embedding_or_override.c: Likewise.
24716         * tests/unictype/test-pr_bidi_eur_num_separator.c: Likewise.
24717         * tests/unictype/test-pr_bidi_eur_num_terminator.c: Likewise.
24718         * tests/unictype/test-pr_bidi_european_digit.c: Likewise.
24719         * tests/unictype/test-pr_bidi_hebrew_right_to_left.c: Likewise.
24720         * tests/unictype/test-pr_bidi_left_to_right.c: Likewise.
24721         * tests/unictype/test-pr_bidi_non_spacing_mark.c: Likewise.
24722         * tests/unictype/test-pr_bidi_other_neutral.c: Likewise.
24723         * tests/unictype/test-pr_bidi_pdf.c: Likewise.
24724         * tests/unictype/test-pr_bidi_segment_separator.c: Likewise.
24725         * tests/unictype/test-pr_bidi_whitespace.c: Likewise.
24726         * tests/unictype/test-pr_combining.c: Likewise.
24727         * tests/unictype/test-pr_composite.c: Likewise.
24728         * tests/unictype/test-pr_currency_symbol.c: Likewise.
24729         * tests/unictype/test-pr_dash.c: Likewise.
24730         * tests/unictype/test-pr_decimal_digit.c: Likewise.
24731         * tests/unictype/test-pr_default_ignorable_code_point.c: Likewise.
24732         * tests/unictype/test-pr_deprecated.c: Likewise.
24733         * tests/unictype/test-pr_diacritic.c: Likewise.
24734         * tests/unictype/test-pr_extender.c: Likewise.
24735         * tests/unictype/test-pr_format_control.c: Likewise.
24736         * tests/unictype/test-pr_grapheme_base.c: Likewise.
24737         * tests/unictype/test-pr_grapheme_extend.c: Likewise.
24738         * tests/unictype/test-pr_grapheme_link.c: Likewise.
24739         * tests/unictype/test-pr_hex_digit.c: Likewise.
24740         * tests/unictype/test-pr_hyphen.c: Likewise.
24741         * tests/unictype/test-pr_id_continue.c: Likewise.
24742         * tests/unictype/test-pr_id_start.c: Likewise.
24743         * tests/unictype/test-pr_ideographic.c: Likewise.
24744         * tests/unictype/test-pr_ids_binary_operator.c: Likewise.
24745         * tests/unictype/test-pr_ids_trinary_operator.c: Likewise.
24746         * tests/unictype/test-pr_ignorable_control.c: Likewise.
24747         * tests/unictype/test-pr_iso_control.c: Likewise.
24748         * tests/unictype/test-pr_join_control.c: Likewise.
24749         * tests/unictype/test-pr_left_of_pair.c: Likewise.
24750         * tests/unictype/test-pr_line_separator.c: Likewise.
24751         * tests/unictype/test-pr_logical_order_exception.c: Likewise.
24752         * tests/unictype/test-pr_lowercase.c: Likewise.
24753         * tests/unictype/test-pr_math.c: Likewise.
24754         * tests/unictype/test-pr_non_break.c: Likewise.
24755         * tests/unictype/test-pr_not_a_character.c: Likewise.
24756         * tests/unictype/test-pr_numeric.c: Likewise.
24757         * tests/unictype/test-pr_other_alphabetic.c: Likewise.
24758         * tests/unictype/test-pr_other_default_ignorable_code_point.c: Likewise.
24759         * tests/unictype/test-pr_other_grapheme_extend.c: Likewise.
24760         * tests/unictype/test-pr_other_id_continue.c: Likewise.
24761         * tests/unictype/test-pr_other_id_start.c: Likewise.
24762         * tests/unictype/test-pr_other_lowercase.c: Likewise.
24763         * tests/unictype/test-pr_other_math.c: Likewise.
24764         * tests/unictype/test-pr_other_uppercase.c: Likewise.
24765         * tests/unictype/test-pr_paired_punctuation.c: Likewise.
24766         * tests/unictype/test-pr_paragraph_separator.c: Likewise.
24767         * tests/unictype/test-pr_pattern_syntax.c: Likewise.
24768         * tests/unictype/test-pr_pattern_white_space.c: Likewise.
24769         * tests/unictype/test-pr_private_use.c: Likewise.
24770         * tests/unictype/test-pr_punctuation.c: Likewise.
24771         * tests/unictype/test-pr_quotation_mark.c: Likewise.
24772         * tests/unictype/test-pr_radical.c: Likewise.
24773         * tests/unictype/test-pr_sentence_terminal.c: Likewise.
24774         * tests/unictype/test-pr_soft_dotted.c: Likewise.
24775         * tests/unictype/test-pr_space.c: Likewise.
24776         * tests/unictype/test-pr_terminal_punctuation.c: Likewise.
24777         * tests/unictype/test-pr_titlecase.c: Likewise.
24778         * tests/unictype/test-pr_unassigned_code_value.c: Likewise.
24779         * tests/unictype/test-pr_unified_ideograph.c: Likewise.
24780         * tests/unictype/test-pr_uppercase.c: Likewise.
24781         * tests/unictype/test-pr_variation_selector.c: Likewise.
24782         * tests/unictype/test-pr_white_space.c: Likewise.
24783         * tests/unictype/test-pr_xid_continue.c: Likewise.
24784         * tests/unictype/test-pr_xid_start.c: Likewise.
24785         * tests/unictype/test-pr_zero_width.c: Likewise.
24786         * tests/unictype/test-sy_c_whitespace.c: Likewise.
24787         * tests/unictype/test-sy_java_whitespace.c: Likewise.
24788
24789 2007-11-12  Bruno Haible  <bruno@clisp.org>
24790
24791         Unicode character classification functions.
24792         * lib/unictype.h: New file.
24793         * modules/unictype/base: New file.
24794         * modules/unictype/category-L: New file.
24795         * modules/unictype/category-Lu: New file.
24796         * modules/unictype/category-Ll: New file.
24797         * modules/unictype/category-Lt: New file.
24798         * modules/unictype/category-Lm: New file.
24799         * modules/unictype/category-Lo: New file.
24800         * modules/unictype/category-M: New file.
24801         * modules/unictype/category-Mn: New file.
24802         * modules/unictype/category-Mc: New file.
24803         * modules/unictype/category-Me: New file.
24804         * modules/unictype/category-N: New file.
24805         * modules/unictype/category-Nd: New file.
24806         * modules/unictype/category-Nl: New file.
24807         * modules/unictype/category-No: New file.
24808         * modules/unictype/category-P: New file.
24809         * modules/unictype/category-Pc: New file.
24810         * modules/unictype/category-Pd: New file.
24811         * modules/unictype/category-Ps: New file.
24812         * modules/unictype/category-Pe: New file.
24813         * modules/unictype/category-Pi: New file.
24814         * modules/unictype/category-Pf: New file.
24815         * modules/unictype/category-Po: New file.
24816         * modules/unictype/category-S: New file.
24817         * modules/unictype/category-Sm: New file.
24818         * modules/unictype/category-Sc: New file.
24819         * modules/unictype/category-Sk: New file.
24820         * modules/unictype/category-So: New file.
24821         * modules/unictype/category-Z: New file.
24822         * modules/unictype/category-Zs: New file.
24823         * modules/unictype/category-Zl: New file.
24824         * modules/unictype/category-Zp: New file.
24825         * modules/unictype/category-C: New file.
24826         * modules/unictype/category-Cc: New file.
24827         * modules/unictype/category-Cf: New file.
24828         * modules/unictype/category-Cs: New file.
24829         * modules/unictype/category-Co: New file.
24830         * modules/unictype/category-Cn: New file.
24831         * modules/unictype/category-or: New file.
24832         * modules/unictype/category-of: New file.
24833         * modules/unictype/category-test: New file.
24834         * modules/unictype/category-test-withtable: New file.
24835         * modules/unictype/category-byname: New file.
24836         * modules/unictype/category-none: New file.
24837         * modules/unictype/category-and: New file.
24838         * modules/unictype/category-and-not: New file.
24839         * modules/unictype/category-name: New file.
24840         * modules/unictype/combining-class: New file.
24841         * modules/unictype/category-all: New file.
24842         * modules/unictype/bidicategory-all: New file.
24843         * modules/unictype/bidicategory-byname: New file.
24844         * modules/unictype/bidicategory-name: New file.
24845         * modules/unictype/bidicategory-of: New file.
24846         * modules/unictype/bidicategory-test: New file.
24847         * modules/unictype/decimal-digit: New file.
24848         * modules/unictype/digit: New file.
24849         * modules/unictype/numeric: New file.
24850         * modules/unictype/mirror: New file.
24851         * modules/unictype/property-white-space: New file.
24852         * modules/unictype/property-alphabetic: New file.
24853         * modules/unictype/property-other-alphabetic: New file.
24854         * modules/unictype/property-not-a-character: New file.
24855         * modules/unictype/property-default-ignorable-code-point: New file.
24856         * modules/unictype/property-other-default-ignorable-code-point: New
24857         file.
24858         * modules/unictype/property-deprecated: New file.
24859         * modules/unictype/property-logical-order-exception: New file.
24860         * modules/unictype/property-variation-selector: New file.
24861         * modules/unictype/property-private-use: New file.
24862         * modules/unictype/property-unassigned-code-value: New file.
24863         * modules/unictype/property-uppercase: New file.
24864         * modules/unictype/property-other-uppercase: New file.
24865         * modules/unictype/property-lowercase: New file.
24866         * modules/unictype/property-other-lowercase: New file.
24867         * modules/unictype/property-titlecase: New file.
24868         * modules/unictype/property-soft-dotted: New file.
24869         * modules/unictype/property-id-start: New file.
24870         * modules/unictype/property-other-id-start: New file.
24871         * modules/unictype/property-id-continue: New file.
24872         * modules/unictype/property-other-id-continue: New file.
24873         * modules/unictype/property-xid-start: New file.
24874         * modules/unictype/property-xid-continue: New file.
24875         * modules/unictype/property-pattern-white-space: New file.
24876         * modules/unictype/property-pattern-syntax: New file.
24877         * modules/unictype/property-join-control: New file.
24878         * modules/unictype/property-grapheme-base: New file.
24879         * modules/unictype/property-grapheme-extend: New file.
24880         * modules/unictype/property-other-grapheme-extend: New file.
24881         * modules/unictype/property-grapheme-link: New file.
24882         * modules/unictype/property-bidi-control: New file.
24883         * modules/unictype/property-bidi-left-to-right: New file.
24884         * modules/unictype/property-bidi-hebrew-right-to-left: New file.
24885         * modules/unictype/property-bidi-arabic-right-to-left: New file.
24886         * modules/unictype/property-bidi-european-digit: New file.
24887         * modules/unictype/property-bidi-eur-num-separator: New file.
24888         * modules/unictype/property-bidi-eur-num-terminator: New file.
24889         * modules/unictype/property-bidi-arabic-digit: New file.
24890         * modules/unictype/property-bidi-common-separator: New file.
24891         * modules/unictype/property-bidi-block-separator: New file.
24892         * modules/unictype/property-bidi-segment-separator: New file.
24893         * modules/unictype/property-bidi-whitespace: New file.
24894         * modules/unictype/property-bidi-non-spacing-mark: New file.
24895         * modules/unictype/property-bidi-boundary-neutral: New file.
24896         * modules/unictype/property-bidi-pdf: New file.
24897         * modules/unictype/property-bidi-embedding-or-override: New file.
24898         * modules/unictype/property-bidi-other-neutral: New file.
24899         * modules/unictype/property-hex-digit: New file.
24900         * modules/unictype/property-ascii-hex-digit: New file.
24901         * modules/unictype/property-ideographic: New file.
24902         * modules/unictype/property-unified-ideograph: New file.
24903         * modules/unictype/property-radical: New file.
24904         * modules/unictype/property-ids-binary-operator: New file.
24905         * modules/unictype/property-ids-trinary-operator: New file.
24906         * modules/unictype/property-zero-width: New file.
24907         * modules/unictype/property-space: New file.
24908         * modules/unictype/property-non-break: New file.
24909         * modules/unictype/property-iso-control: New file.
24910         * modules/unictype/property-format-control: New file.
24911         * modules/unictype/property-dash: New file.
24912         * modules/unictype/property-hyphen: New file.
24913         * modules/unictype/property-punctuation: New file.
24914         * modules/unictype/property-line-separator: New file.
24915         * modules/unictype/property-paragraph-separator: New file.
24916         * modules/unictype/property-quotation-mark: New file.
24917         * modules/unictype/property-sentence-terminal: New file.
24918         * modules/unictype/property-terminal-punctuation: New file.
24919         * modules/unictype/property-currency-symbol: New file.
24920         * modules/unictype/property-math: New file.
24921         * modules/unictype/property-other-math: New file.
24922         * modules/unictype/property-paired-punctuation: New file.
24923         * modules/unictype/property-left-of-pair: New file.
24924         * modules/unictype/property-combining: New file.
24925         * modules/unictype/property-composite: New file.
24926         * modules/unictype/property-decimal-digit: New file.
24927         * modules/unictype/property-numeric: New file.
24928         * modules/unictype/property-diacritic: New file.
24929         * modules/unictype/property-extender: New file.
24930         * modules/unictype/property-ignorable-control: New file.
24931         * modules/unictype/property-test: New file.
24932         * modules/unictype/property-byname: New file.
24933         * modules/unictype/property-all: New file.
24934         * modules/unictype/scripts: New file.
24935         * modules/unictype/scripts-all: New file.
24936         * modules/unictype/block-of: New file.
24937         * modules/unictype/block-test: New file.
24938         * modules/unictype/block-list: New file.
24939         * modules/unictype/block-all: New file.
24940         * modules/unictype/syntax-c-whitespace: New file.
24941         * modules/unictype/syntax-java-whitespace: New file.
24942         * modules/unictype/syntax-c-ident: New file.
24943         * modules/unictype/syntax-java-ident: New file.
24944         * modules/unictype/ctype-alnum: New file.
24945         * modules/unictype/ctype-alpha: New file.
24946         * modules/unictype/ctype-cntrl: New file.
24947         * modules/unictype/ctype-digit: New file.
24948         * modules/unictype/ctype-graph: New file.
24949         * modules/unictype/ctype-lower: New file.
24950         * modules/unictype/ctype-print: New file.
24951         * modules/unictype/ctype-punct: New file.
24952         * modules/unictype/ctype-space: New file.
24953         * modules/unictype/ctype-upper: New file.
24954         * modules/unictype/ctype-xdigit: New file.
24955         * modules/unictype/ctype-blank: New file.
24956         * lib/unictype/bidi_byname.c: New file.
24957         * lib/unictype/bidi_name.c: New file.
24958         * lib/unictype/bidi_of.c: New file.
24959         * lib/unictype/bidi_test.c: New file.
24960         * lib/unictype/bitmap.h: New file.
24961         * lib/unictype/block_test.c: New file.
24962         * lib/unictype/blocks.c: New file.
24963         * lib/unictype/categ_C.c: New file.
24964         * lib/unictype/categ_Cc.c: New file.
24965         * lib/unictype/categ_Cf.c: New file.
24966         * lib/unictype/categ_Cn.c: New file.
24967         * lib/unictype/categ_Co.c: New file.
24968         * lib/unictype/categ_Cs.c: New file.
24969         * lib/unictype/categ_L.c: New file.
24970         * lib/unictype/categ_Ll.c: New file.
24971         * lib/unictype/categ_Lm.c: New file.
24972         * lib/unictype/categ_Lo.c: New file.
24973         * lib/unictype/categ_Lt.c: New file.
24974         * lib/unictype/categ_Lu.c: New file.
24975         * lib/unictype/categ_M.c: New file.
24976         * lib/unictype/categ_Mc.c: New file.
24977         * lib/unictype/categ_Me.c: New file.
24978         * lib/unictype/categ_Mn.c: New file.
24979         * lib/unictype/categ_N.c: New file.
24980         * lib/unictype/categ_Nd.c: New file.
24981         * lib/unictype/categ_Nl.c: New file.
24982         * lib/unictype/categ_No.c: New file.
24983         * lib/unictype/categ_P.c: New file.
24984         * lib/unictype/categ_Pc.c: New file.
24985         * lib/unictype/categ_Pd.c: New file.
24986         * lib/unictype/categ_Pe.c: New file.
24987         * lib/unictype/categ_Pf.c: New file.
24988         * lib/unictype/categ_Pi.c: New file.
24989         * lib/unictype/categ_Po.c: New file.
24990         * lib/unictype/categ_Ps.c: New file.
24991         * lib/unictype/categ_S.c: New file.
24992         * lib/unictype/categ_Sc.c: New file.
24993         * lib/unictype/categ_Sk.c: New file.
24994         * lib/unictype/categ_Sm.c: New file.
24995         * lib/unictype/categ_So.c: New file.
24996         * lib/unictype/categ_Z.c: New file.
24997         * lib/unictype/categ_Zl.c: New file.
24998         * lib/unictype/categ_Zp.c: New file.
24999         * lib/unictype/categ_Zs.c: New file.
25000         * lib/unictype/categ_and.c: New file.
25001         * lib/unictype/categ_and_not.c: New file.
25002         * lib/unictype/categ_byname.c: New file.
25003         * lib/unictype/categ_name.c: New file.
25004         * lib/unictype/categ_none.c: New file.
25005         * lib/unictype/categ_of.c: New file.
25006         * lib/unictype/categ_or.c: New file.
25007         * lib/unictype/categ_test.c: New file.
25008         * lib/unictype/combining.c: New file.
25009         * lib/unictype/ctype_alnum.c: New file.
25010         * lib/unictype/ctype_alpha.c: New file.
25011         * lib/unictype/ctype_blank.c: New file.
25012         * lib/unictype/ctype_cntrl.c: New file.
25013         * lib/unictype/ctype_digit.c: New file.
25014         * lib/unictype/ctype_graph.c: New file.
25015         * lib/unictype/ctype_lower.c: New file.
25016         * lib/unictype/ctype_print.c: New file.
25017         * lib/unictype/ctype_punct.c: New file.
25018         * lib/unictype/ctype_space.c: New file.
25019         * lib/unictype/ctype_upper.c: New file.
25020         * lib/unictype/ctype_xdigit.c: New file.
25021         * lib/unictype/decdigit.c: New file.
25022         * lib/unictype/digit.c: New file.
25023         * lib/unictype/identsyntaxmap.h: New file.
25024         * lib/unictype/mirror.c: New file.
25025         * lib/unictype/numeric.c: New file.
25026         * lib/unictype/pr_alphabetic.c: New file.
25027         * lib/unictype/pr_ascii_hex_digit.c: New file.
25028         * lib/unictype/pr_bidi_arabic_digit.c: New file.
25029         * lib/unictype/pr_bidi_arabic_right_to_left.c: New file.
25030         * lib/unictype/pr_bidi_block_separator.c: New file.
25031         * lib/unictype/pr_bidi_boundary_neutral.c: New file.
25032         * lib/unictype/pr_bidi_common_separator.c: New file.
25033         * lib/unictype/pr_bidi_control.c: New file.
25034         * lib/unictype/pr_bidi_embedding_or_override.c: New file.
25035         * lib/unictype/pr_bidi_eur_num_separator.c: New file.
25036         * lib/unictype/pr_bidi_eur_num_terminator.c: New file.
25037         * lib/unictype/pr_bidi_european_digit.c: New file.
25038         * lib/unictype/pr_bidi_hebrew_right_to_left.c: New file.
25039         * lib/unictype/pr_bidi_left_to_right.c: New file.
25040         * lib/unictype/pr_bidi_non_spacing_mark.c: New file.
25041         * lib/unictype/pr_bidi_other_neutral.c: New file.
25042         * lib/unictype/pr_bidi_pdf.c: New file.
25043         * lib/unictype/pr_bidi_segment_separator.c: New file.
25044         * lib/unictype/pr_bidi_whitespace.c: New file.
25045         * lib/unictype/pr_byname.c: New file.
25046         * lib/unictype/pr_byname.gperf: New file.
25047         * lib/unictype/pr_combining.c: New file.
25048         * lib/unictype/pr_composite.c: New file.
25049         * lib/unictype/pr_currency_symbol.c: New file.
25050         * lib/unictype/pr_dash.c: New file.
25051         * lib/unictype/pr_decimal_digit.c: New file.
25052         * lib/unictype/pr_default_ignorable_code_point.c: New file.
25053         * lib/unictype/pr_deprecated.c: New file.
25054         * lib/unictype/pr_diacritic.c: New file.
25055         * lib/unictype/pr_extender.c: New file.
25056         * lib/unictype/pr_format_control.c: New file.
25057         * lib/unictype/pr_grapheme_base.c: New file.
25058         * lib/unictype/pr_grapheme_extend.c: New file.
25059         * lib/unictype/pr_grapheme_link.c: New file.
25060         * lib/unictype/pr_hex_digit.c: New file.
25061         * lib/unictype/pr_hyphen.c: New file.
25062         * lib/unictype/pr_id_continue.c: New file.
25063         * lib/unictype/pr_id_start.c: New file.
25064         * lib/unictype/pr_ideographic.c: New file.
25065         * lib/unictype/pr_ids_binary_operator.c: New file.
25066         * lib/unictype/pr_ids_trinary_operator.c: New file.
25067         * lib/unictype/pr_ignorable_control.c: New file.
25068         * lib/unictype/pr_iso_control.c: New file.
25069         * lib/unictype/pr_join_control.c: New file.
25070         * lib/unictype/pr_left_of_pair.c: New file.
25071         * lib/unictype/pr_line_separator.c: New file.
25072         * lib/unictype/pr_logical_order_exception.c: New file.
25073         * lib/unictype/pr_lowercase.c: New file.
25074         * lib/unictype/pr_math.c: New file.
25075         * lib/unictype/pr_non_break.c: New file.
25076         * lib/unictype/pr_not_a_character.c: New file.
25077         * lib/unictype/pr_numeric.c: New file.
25078         * lib/unictype/pr_other_alphabetic.c: New file.
25079         * lib/unictype/pr_other_default_ignorable_code_point.c: New file.
25080         * lib/unictype/pr_other_grapheme_extend.c: New file.
25081         * lib/unictype/pr_other_id_continue.c: New file.
25082         * lib/unictype/pr_other_id_start.c: New file.
25083         * lib/unictype/pr_other_lowercase.c: New file.
25084         * lib/unictype/pr_other_math.c: New file.
25085         * lib/unictype/pr_other_uppercase.c: New file.
25086         * lib/unictype/pr_paired_punctuation.c: New file.
25087         * lib/unictype/pr_paragraph_separator.c: New file.
25088         * lib/unictype/pr_pattern_syntax.c: New file.
25089         * lib/unictype/pr_pattern_white_space.c: New file.
25090         * lib/unictype/pr_private_use.c: New file.
25091         * lib/unictype/pr_punctuation.c: New file.
25092         * lib/unictype/pr_quotation_mark.c: New file.
25093         * lib/unictype/pr_radical.c: New file.
25094         * lib/unictype/pr_sentence_terminal.c: New file.
25095         * lib/unictype/pr_soft_dotted.c: New file.
25096         * lib/unictype/pr_space.c: New file.
25097         * lib/unictype/pr_terminal_punctuation.c: New file.
25098         * lib/unictype/pr_test.c: New file.
25099         * lib/unictype/pr_titlecase.c: New file.
25100         * lib/unictype/pr_unassigned_code_value.c: New file.
25101         * lib/unictype/pr_unified_ideograph.c: New file.
25102         * lib/unictype/pr_uppercase.c: New file.
25103         * lib/unictype/pr_variation_selector.c: New file.
25104         * lib/unictype/pr_white_space.c: New file.
25105         * lib/unictype/pr_xid_continue.c: New file.
25106         * lib/unictype/pr_xid_start.c: New file.
25107         * lib/unictype/pr_zero_width.c: New file.
25108         * lib/unictype/scripts.c: New file.
25109         * lib/unictype/sy_c_ident.c: New file.
25110         * lib/unictype/sy_c_whitespace.c: New file.
25111         * lib/unictype/sy_java_ident.c: New file.
25112         * lib/unictype/sy_java_whitespace.c: New file.
25113
25114         * lib/unictype/bidi_of.h: New file, generated by gen-ctype.c for
25115         Unicode 5.0.0.
25116         * lib/unictype/blocks.h: Likewise.
25117         * lib/unictype/categ_C.h: Likewise.
25118         * lib/unictype/categ_Cc.h: Likewise.
25119         * lib/unictype/categ_Cf.h: Likewise.
25120         * lib/unictype/categ_Cn.h: Likewise.
25121         * lib/unictype/categ_Co.h: Likewise.
25122         * lib/unictype/categ_Cs.h: Likewise.
25123         * lib/unictype/categ_L.h: Likewise.
25124         * lib/unictype/categ_Ll.h: Likewise.
25125         * lib/unictype/categ_Lm.h: Likewise.
25126         * lib/unictype/categ_Lo.h: Likewise.
25127         * lib/unictype/categ_Lt.h: Likewise.
25128         * lib/unictype/categ_Lu.h: Likewise.
25129         * lib/unictype/categ_M.h: Likewise.
25130         * lib/unictype/categ_Mc.h: Likewise.
25131         * lib/unictype/categ_Me.h: Likewise.
25132         * lib/unictype/categ_Mn.h: Likewise.
25133         * lib/unictype/categ_N.h: Likewise.
25134         * lib/unictype/categ_Nd.h: Likewise.
25135         * lib/unictype/categ_Nl.h: Likewise.
25136         * lib/unictype/categ_No.h: Likewise.
25137         * lib/unictype/categ_P.h: Likewise.
25138         * lib/unictype/categ_Pc.h: Likewise.
25139         * lib/unictype/categ_Pd.h: Likewise.
25140         * lib/unictype/categ_Pe.h: Likewise.
25141         * lib/unictype/categ_Pf.h: Likewise.
25142         * lib/unictype/categ_Pi.h: Likewise.
25143         * lib/unictype/categ_Po.h: Likewise.
25144         * lib/unictype/categ_Ps.h: Likewise.
25145         * lib/unictype/categ_S.h: Likewise.
25146         * lib/unictype/categ_Sc.h: Likewise.
25147         * lib/unictype/categ_Sk.h: Likewise.
25148         * lib/unictype/categ_Sm.h: Likewise.
25149         * lib/unictype/categ_So.h: Likewise.
25150         * lib/unictype/categ_Z.h: Likewise.
25151         * lib/unictype/categ_Zl.h: Likewise.
25152         * lib/unictype/categ_Zp.h: Likewise.
25153         * lib/unictype/categ_Zs.h: Likewise.
25154         * lib/unictype/categ_of.h: Likewise.
25155         * lib/unictype/combining.h: Likewise.
25156         * lib/unictype/ctype_alnum.h: Likewise.
25157         * lib/unictype/ctype_alpha.h: Likewise.
25158         * lib/unictype/ctype_blank.h: Likewise.
25159         * lib/unictype/ctype_cntrl.h: Likewise.
25160         * lib/unictype/ctype_digit.h: Likewise.
25161         * lib/unictype/ctype_graph.h: Likewise.
25162         * lib/unictype/ctype_lower.h: Likewise.
25163         * lib/unictype/ctype_print.h: Likewise.
25164         * lib/unictype/ctype_punct.h: Likewise.
25165         * lib/unictype/ctype_space.h: Likewise.
25166         * lib/unictype/ctype_upper.h: Likewise.
25167         * lib/unictype/ctype_xdigit.h: Likewise.
25168         * lib/unictype/decdigit.h: Likewise.
25169         * lib/unictype/digit.h: Likewise.
25170         * lib/unictype/mirror.h: Likewise.
25171         * lib/unictype/numeric.h: Likewise.
25172         * lib/unictype/pr_alphabetic.h: Likewise.
25173         * lib/unictype/pr_ascii_hex_digit.h: Likewise.
25174         * lib/unictype/pr_bidi_arabic_digit.h: Likewise.
25175         * lib/unictype/pr_bidi_arabic_right_to_left.h: Likewise.
25176         * lib/unictype/pr_bidi_block_separator.h: Likewise.
25177         * lib/unictype/pr_bidi_boundary_neutral.h: Likewise.
25178         * lib/unictype/pr_bidi_common_separator.h: Likewise.
25179         * lib/unictype/pr_bidi_control.h: Likewise.
25180         * lib/unictype/pr_bidi_embedding_or_override.h: Likewise.
25181         * lib/unictype/pr_bidi_eur_num_separator.h: Likewise.
25182         * lib/unictype/pr_bidi_eur_num_terminator.h: Likewise.
25183         * lib/unictype/pr_bidi_european_digit.h: Likewise.
25184         * lib/unictype/pr_bidi_hebrew_right_to_left.h: Likewise.
25185         * lib/unictype/pr_bidi_left_to_right.h: Likewise.
25186         * lib/unictype/pr_bidi_non_spacing_mark.h: Likewise.
25187         * lib/unictype/pr_bidi_other_neutral.h: Likewise.
25188         * lib/unictype/pr_bidi_pdf.h: Likewise.
25189         * lib/unictype/pr_bidi_segment_separator.h: Likewise.
25190         * lib/unictype/pr_bidi_whitespace.h: Likewise.
25191         * lib/unictype/pr_combining.h: Likewise.
25192         * lib/unictype/pr_composite.h: Likewise.
25193         * lib/unictype/pr_currency_symbol.h: Likewise.
25194         * lib/unictype/pr_dash.h: Likewise.
25195         * lib/unictype/pr_decimal_digit.h: Likewise.
25196         * lib/unictype/pr_default_ignorable_code_point.h: Likewise.
25197         * lib/unictype/pr_deprecated.h: Likewise.
25198         * lib/unictype/pr_diacritic.h: Likewise.
25199         * lib/unictype/pr_extender.h: Likewise.
25200         * lib/unictype/pr_format_control.h: Likewise.
25201         * lib/unictype/pr_grapheme_base.h: Likewise.
25202         * lib/unictype/pr_grapheme_extend.h: Likewise.
25203         * lib/unictype/pr_grapheme_link.h: Likewise.
25204         * lib/unictype/pr_hex_digit.h: Likewise.
25205         * lib/unictype/pr_hyphen.h: Likewise.
25206         * lib/unictype/pr_id_continue.h: Likewise.
25207         * lib/unictype/pr_id_start.h: Likewise.
25208         * lib/unictype/pr_ideographic.h: Likewise.
25209         * lib/unictype/pr_ids_binary_operator.h: Likewise.
25210         * lib/unictype/pr_ids_trinary_operator.h: Likewise.
25211         * lib/unictype/pr_ignorable_control.h: Likewise.
25212         * lib/unictype/pr_iso_control.h: Likewise.
25213         * lib/unictype/pr_join_control.h: Likewise.
25214         * lib/unictype/pr_left_of_pair.h: Likewise.
25215         * lib/unictype/pr_line_separator.h: Likewise.
25216         * lib/unictype/pr_logical_order_exception.h: Likewise.
25217         * lib/unictype/pr_lowercase.h: Likewise.
25218         * lib/unictype/pr_math.h: Likewise.
25219         * lib/unictype/pr_non_break.h: Likewise.
25220         * lib/unictype/pr_not_a_character.h: Likewise.
25221         * lib/unictype/pr_numeric.h: Likewise.
25222         * lib/unictype/pr_other_alphabetic.h: Likewise.
25223         * lib/unictype/pr_other_default_ignorable_code_point.h: Likewise.
25224         * lib/unictype/pr_other_grapheme_extend.h: Likewise.
25225         * lib/unictype/pr_other_id_continue.h: Likewise.
25226         * lib/unictype/pr_other_id_start.h: Likewise.
25227         * lib/unictype/pr_other_lowercase.h: Likewise.
25228         * lib/unictype/pr_other_math.h: Likewise.
25229         * lib/unictype/pr_other_uppercase.h: Likewise.
25230         * lib/unictype/pr_paired_punctuation.h: Likewise.
25231         * lib/unictype/pr_paragraph_separator.h: Likewise.
25232         * lib/unictype/pr_pattern_syntax.h: Likewise.
25233         * lib/unictype/pr_pattern_white_space.h: Likewise.
25234         * lib/unictype/pr_private_use.h: Likewise.
25235         * lib/unictype/pr_punctuation.h: Likewise.
25236         * lib/unictype/pr_quotation_mark.h: Likewise.
25237         * lib/unictype/pr_radical.h: Likewise.
25238         * lib/unictype/pr_sentence_terminal.h: Likewise.
25239         * lib/unictype/pr_soft_dotted.h: Likewise.
25240         * lib/unictype/pr_space.h: Likewise.
25241         * lib/unictype/pr_terminal_punctuation.h: Likewise.
25242         * lib/unictype/pr_titlecase.h: Likewise.
25243         * lib/unictype/pr_unassigned_code_value.h: Likewise.
25244         * lib/unictype/pr_unified_ideograph.h: Likewise.
25245         * lib/unictype/pr_uppercase.h: Likewise.
25246         * lib/unictype/pr_variation_selector.h: Likewise.
25247         * lib/unictype/pr_white_space.h: Likewise.
25248         * lib/unictype/pr_xid_continue.h: Likewise.
25249         * lib/unictype/pr_xid_start.h: Likewise.
25250         * lib/unictype/pr_zero_width.h: Likewise.
25251         * lib/unictype/scripts.h: Likewise.
25252         * lib/unictype/scripts_byname.gperf: Likewise.
25253         * lib/unictype/sy_c_ident.h: Likewise.
25254         * lib/unictype/sy_c_whitespace.h: Likewise.
25255         * lib/unictype/sy_java_ident.h: Likewise.
25256         * lib/unictype/sy_java_whitespace.h: Likewise.
25257
25258         * lib/unictype/Makefile: New file.
25259         * lib/unictype/gen-ctype.c: New file, based on gen-unicode-ctype.c in
25260         glibc.
25261         * lib/unictype/3level.h: New file, copied from glibc.
25262         * lib/unictype/3levelbit.h: New file.
25263
25264 2007-11-11  Bruno Haible  <bruno@clisp.org>
25265
25266         * modules/gperf: New file.
25267         * modules/iconv_open (Depends-on): Add it.
25268         (Makefile.am): Remove the GPERF definition.
25269
25270 2007-11-11  Bruno Haible  <bruno@clisp.org>
25271
25272         * m4/round.m4 (gl_FUNC_ROUND): Test against NetBSD 3.0 bug.
25273         * doc/functions/round.texi: Mention the NetBSD 3.0 bug.
25274
25275 2007-11-11  Bruno Haible  <bruno@clisp.org>
25276
25277         * tests/test-argmatch.c (ARGMATCH_DIE): Undefine.
25278         (usage): Remove function.
25279
25280 2007-11-11  Bruno Haible  <bruno@clisp.org>
25281
25282         * m4/roundf.m4 (gl_FUNC_ROUNDF): Use gl_FUNC_FLOORF_LIBS and
25283         gl_FUNC_CEILF_LIBS.
25284         * m4/round.m4 (gl_FUNC_ROUND): Use gl_FUNC_FLOOR_LIBS and
25285         gl_FUNC_CEIL_LIBS.
25286         * m4/roundl.m4 (gl_FUNC_ROUNDL): Use gl_FUNC_FLOORL_LIBS and
25287         gl_FUNC_CEILL_LIBS.
25288         * modules/roundf (Files): Add m4/floorf.m4, m4/ceilf.m4.
25289         * modules/round (Files): Add m4/floor.m4, m4/ceil.m4.
25290         * modules/roundl (Files): Add m4/floorl.m4, m4/ceill.m4.
25291
25292 2007-11-11  Bruno Haible  <bruno@clisp.org>
25293
25294         * m4/roundf.m4 (gl_FUNC_ROUNDF): Handle the case that floorf and
25295         roundf were declared but do not exist on functions.
25296         * m4/roundl.m4 (gl_FUNC_ROUNDL): Handle the case that floorl and
25297         roundl were declared but do not exist on functions.
25298         * lib/round.c (HAVE_FLOOR_AND_CEIL): Use HAVE_FLOORF_AND_CEILF and
25299         HAVE_FLOORL_AND_CEILL, respectively.
25300         Needed for Sun C on Solaris 10.
25301
25302 2007-11-11  Bruno Haible  <bruno@clisp.org>
25303
25304         * m4/roundf.m4 (gl_FUNC_ROUNDF): Set REPLACE_ROUNDF instead of
25305         HAVE_DECL_ROUNDF. Remove redundant AC_SUBST.
25306         * m4/round.m4 (gl_FUNC_ROUND): Set REPLACE_ROUND instead of
25307         HAVE_DECL_ROUND. Remove redundant AC_SUBST.
25308         * m4/roundl.m4 (gl_FUNC_ROUNDL): Set REPLACE_ROUNDL instead of
25309         HAVE_DECL_ROUNDL. Remove redundant AC_SUBST.
25310         * lib/math.in.h (roundf): Use REPLACE_ROUNDF instead of
25311         HAVE_DECL_ROUNDF.
25312         (round): Use REPLACE_ROUND instead of HAVE_DECL_ROUND.
25313         (roundl): Use REPLACE_ROUNDL instead of HAVE_DECL_ROUNDL.
25314         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_ROUND* instead
25315         of HAVE_DECL_ROUND*.
25316         * modules/math (Makefile.am): Update.
25317
25318 2007-11-10  Bruno Haible  <bruno@clisp.org>
25319
25320         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Use same check for
25321         ptrdiff_t as m4/intl.m4.
25322
25323 2007-11-10  Jim Meyering  <meyering@redhat.com>
25324
25325         Avoid link failure for the argmatch test.
25326         * tests/test-argmatch.c (usage): Define function to avoid a link
25327         failure: argmatch_die requires a usage function.
25328
25329 2007-11-09  Bruno Haible  <bruno@clisp.org>
25330
25331         * doc/functions/snprintf.texi: Mention BeOS deficiency.
25332         * doc/functions/vsnprintf.texi: Likewise.
25333         * lib/vasnprintf.c (VASNPRINTF): Ensure that we never call snprintf
25334         with a size argument < 2.
25335
25336 2007-11-09  Bruno Haible  <bruno@clisp.org>
25337
25338         * lib/vasnprintf.c (VASNPRINTF): Increase reallocation of snprintf
25339         buffer. Fixes an inefficiency introduced on 2007-11-03.
25340
25341 2007-11-09  Bruno Haible  <bruno@clisp.org>
25342
25343         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8) [BeOS]: Make this test return
25344         none instead of tr_TR. Fixes a failure of test-c-strcasecmp.c.
25345
25346 2007-11-08  Jim Meyering  <meyering@redhat.com>
25347
25348         Change cache variable name prefix "jm_" to "gl_" everywhere.
25349         * m4/d-type.m4, m4/jm-winsz1.m4, m4/jm-winsz2.m4, m4/link-follow.m4:
25350         * m4/putenv.m4, m4/strtoimax.m4, m4/strtoumax.m4, m4/unlink-busy.m4:
25351         * m4/uptime.m4: s/gl_/jm_/
25352
25353 2007-11-07  Bruno Haible  <bruno@clisp.org>
25354
25355         Update to GNU gettext 0.17.
25356         * m4/intl.m4: Update to GNU gettext 0.17.
25357         * m4/po.m4: Likewise.
25358         * modules/gettext (Files): Remove m4/ulonglong.m4.
25359         (configure.ac): Require gettext infrastructure from version 0.17.
25360
25361 2007-11-06  Bruno Haible  <bruno@clisp.org>
25362
25363         * lib/fbufmode.c (fbufmode) [QNX]: Use numerical values for flags; the
25364         symbolic values are not defined in a public header.
25365         * lib/freadable.c (freadable) [QNX]: Likewise.
25366         * lib/freadahead.c (freadahead) [QNX]: Likewise.
25367         * lib/freading.c (freading) [QNX]: Likewise.
25368         * lib/fseterr.c (fseterr) [QNX]: Likewise.
25369         * lib/fwritable.c (fwritable) [QNX]: Likewise.
25370         * lib/fwriting.c (fwriting) [QNX]: Likewise.
25371         * lib/fpurge.c (fpurge) [QNX]: Likewise. Add a return statement.
25372         Reported by Alain Magloire.
25373
25374         * m4/fpending.m4 (gl_FUNC_FPENDING): Add a variant for QNX.
25375
25376 2007-11-05  Bruno Haible  <bruno@clisp.org>
25377
25378         * lib/vasnprintf.c (VASNPRINTF): Expand the NEED_PRINTF_DIRECTIVE_A
25379         code when NEED_PRINTF_LONG_DOUBLE or NEED_PRINTF_DOUBLE is set.
25380         Needed on Cygwin, where !NEED_PRINTF_DIRECTIVE_A && NEED_PRINTF_DOUBLE.
25381         Reported by Eric Blake.
25382
25383 2007-10-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
25384             Bruno Haible  <bruno@clisp.org>
25385
25386         * modules/malloc (configure.ac): Define GNULIB_MALLOC_GNU always.
25387         * modules/realloc (configure.ac): Define GNULIB_REALLOC_GNU always.
25388         * lib/realloc.c (SYSTEM_MALLOC_GLIBC_COMPATIBLE): New macro.
25389         (malloc): Undefine also before including <stdlib.h>.
25390         (rpl_realloc): Turn malloc(0) into malloc(1) if necessary.
25391         Needed on OSF/1 4.0.
25392
25393 2007-11-05  Jim Meyering  <meyering@redhat.com>
25394
25395         git-version-gen: sync from coreutils.
25396         * build-aux/git-version-gen: Add comments.
25397         Change the first '-' to '.' in the snapshot version string,
25398         e.g., 6.9-377-08144 -> 6.9.377-08144
25399         Remove first parameter.
25400         Don't declare a version "-dirty" merely because a time
25401         stamp has changed.
25402
25403 2007-11-04  Bruno Haible  <bruno@clisp.org>
25404
25405         * lib/lock.h: Protect all macro definitions containing an 'if'
25406         statement through a "do { ... } while (0)".
25407         * lib/tls.h: Likewise.
25408
25409 2007-11-04  Bruno Haible  <bruno@clisp.org>
25410
25411         * lib/vasnprintf.c (DCHAR_IS_TCHAR, DCHAR_CPY): Undefine at the end.
25412
25413 2007-11-04  Bruno Haible  <bruno@clisp.org>
25414
25415         * m4/printf.m4 (gl_PRINTF_ENOMEM): Use GL_NOCRASH.
25416         * modules/fprintf-posix (Depends-on): Add nocrash.
25417         * modules/snprintf-posix (Depends-on): Likewise.
25418         * modules/sprintf-posix (Depends-on): Likewise.
25419         * modules/vasnprintf-posix (Depends-on): Likewise.
25420         * modules/vasprintf-posix (Depends-on): Likewise.
25421         * modules/vfprintf-posix (Depends-on): Likewise.
25422         * modules/vsnprintf-posix (Depends-on): Likewise.
25423         * modules/vsprintf-posix (Depends-on): Likewise.
25424         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
25425         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
25426         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
25427         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
25428         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
25429         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
25430         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
25431
25432 2007-11-04  Bruno Haible  <bruno@clisp.org>
25433
25434         * modules/nocrash: New file.
25435         * m4/nocrash.m4: New file, taken from GNU clisp. Code taken from
25436         GNU libsigsegv, with permission of GNU libsigsegv's copyright holders.
25437
25438 2007-11-04  Bruno Haible  <bruno@clisp.org>
25439
25440         * tests/test-vasnprintf-posix.c (test_function): Add some tests of
25441         precision handling.
25442         * tests/test-vasprintf-posix.c (test_function): Likewise.
25443         * tests/test-snprintf-posix.h (test_function): Likewise.
25444         * tests/test-sprintf-posix.h (test_function): Likewise.
25445
25446         Fix *printf behaviour for large precisions on mingw and BeOS.
25447         * m4/printf.m4 (gl_PRINTF_PRECISION): New macro.
25448         * lib/vasnprintf.c (VASNPRINTF): Handle NEED_PRINTF_UNBOUNDED_PRECISION.
25449         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_PRECISION): New macro.
25450         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
25451         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
25452         gl_PRINTF_PRECISION and test its result. Invoke
25453         gl_PREREQ_VASNPRINTF_PRECISION.
25454         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
25455         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
25456         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
25457         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
25458         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
25459         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
25460         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
25461         * doc/functions/fprintf.texi: Update.
25462         * doc/functions/printf.texi: Update.
25463         * doc/functions/snprintf.texi: Update.
25464         * doc/functions/sprintf.texi: Update.
25465         * doc/functions/vfprintf.texi: Update.
25466         * doc/functions/vprintf.texi: Update.
25467         * doc/functions/vsnprintf.texi: Update.
25468         * doc/functions/vsprintf.texi: Update.
25469
25470 2007-11-04  Bruno Haible  <bruno@clisp.org>
25471
25472         * lib/vasnprintf.c (scale10_round_decimal_decoded): Fix shift loop.
25473
25474 2007-11-04  Bruno Haible  <bruno@clisp.org>
25475
25476         * modules/relocatable-prog (Files): Add m4/lib-ld.m4.
25477         Reported by Sylvain Beucler <beuc@gnu.org>.
25478
25479 2007-11-03  Bruno Haible  <bruno@clisp.org>
25480
25481         * tests/test-fprintf-posix2.sh: New file.
25482         * tests/test-fprintf-posix2.c: New file.
25483         * modules/fprintf-posix-tests (Files): Add them.
25484         (TESTS): Add test-fprintf-posix2.sh.
25485         (configure.ac): Check for getrlimit and setrlimit.
25486         (check_PROGRAMS): Add test-fprintf-posix2.
25487
25488         * tests/test-printf-posix2.sh: New file.
25489         * tests/test-printf-posix2.c: New file.
25490         * modules/printf-posix-tests (Files): Add them.
25491         (TESTS): Add test-printf-posix2.sh.
25492         (configure.ac): Check for getrlimit and setrlimit.
25493         (check_PROGRAMS): Add test-printf-posix2.
25494
25495         Fix *printf behaviour in out-of-memory situations on MacOS X and *BSD.
25496         * m4/printf.m4 (gl_PRINTF_ENOMEM): New macro.
25497         * lib/vasnprintf.c: Implement NEED_PRINTF_DOUBLE.
25498         (decode_double): New function, copied from decode_long_double.
25499         (scale10_round_decimal_decoded): New function, extracted from
25500         scale10_round_decimal_long_double.
25501         (scale10_round_decimal_long_double): Use it.
25502         (scale10_round_decimal_double): New function.
25503         (floorlog10): New function.
25504         (VASNPRINTF): Handle NEED_PRINTF_DOUBLE case.
25505         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_ENOMEM): New macro.
25506         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
25507         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
25508         gl_PRINTF_ENOMEM and test its result. Invoke
25509         gl_PREREQ_VASNPRINTF_ENOMEM.
25510         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
25511         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
25512         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
25513         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
25514         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
25515         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
25516         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
25517         * modules/fprintf-posix (Depends-on): Add frexp-nolibm.
25518         * modules/snprintf-posix (Depends-on): Likewise.
25519         * modules/sprintf-posix (Depends-on): Likewise.
25520         * modules/vasnprintf-posix (Depends-on): Likewise.
25521         * modules/vasprintf-posix (Depends-on): Likewise.
25522         * modules/vfprintf-posix (Depends-on): Likewise.
25523         * modules/vsnprintf-posix (Depends-on): Likewise.
25524         * modules/vsprintf-posix (Depends-on): Likewise.
25525         * doc/functions/fprintf.texi: Update.
25526         * doc/functions/printf.texi: Update.
25527         * doc/functions/snprintf.texi: Update.
25528         * doc/functions/sprintf.texi: Update.
25529         * doc/functions/vfprintf.texi: Update.
25530         * doc/functions/vprintf.texi: Update.
25531         * doc/functions/vsnprintf.texi: Update.
25532         * doc/functions/vsprintf.texi: Update.
25533
25534 2007-11-03  Bruno Haible  <bruno@clisp.org>
25535
25536         * modules/frexp-nolibm-tests: New file.
25537
25538         * modules/frexp-nolibm: New file.
25539         * m4/frexp.m4 (gl_FUNC_FREXP_NO_LIBM): New macro.
25540
25541 2007-11-03  Bruno Haible  <bruno@clisp.org>
25542
25543         * lib/vasnprintf.c (VASNPRINTF): Don't assume that snprintf's return
25544         value is C99 compliant.
25545         Needed for OSF/1 5.1.
25546
25547 2007-11-03  Bruno Haible  <bruno@clisp.org>
25548
25549         Fix out-of-memory handling of vasnprintf.
25550         * lib/printf-parse.c: Include <errno.h>.
25551         (PRINTF_PARSE): When failing, set errno to EINVAL or ENOMEM.
25552         * lib/vasnprintf.c (VASNPRINTF): When PRINTF_PARSE fails, assume errno
25553         is already set.
25554
25555 2007-11-02  Eric Blake  <ebb9@byu.net>
25556
25557         Fix tests on cygwin.
25558         * modules/xprintf-posix-tests (Makefile.am): Link against -lintl.
25559
25560 2007-11-01  Bruno Haible  <bruno@clisp.org>
25561
25562         * lib/stdlib.in.h (putenv): Remove the "not POSIX compliant everywhere"
25563         warning.
25564         * doc/functions/putenv.texi: Clarify that the 'putenv' module is not
25565         needed for POSIX compatibility.
25566
25567 2007-11-01  Paul Eggert  <eggert@cs.ucla.edu>
25568
25569         * m4/putenv.m4 (gl_FUNC_PUTENV): Also mention that we're checking
25570         for compatibility with GNU.
25571
25572 2007-11-01  Bruno Haible  <bruno@clisp.org>
25573
25574         * lib/putenv.c: Include <stdlib.h>. Remove rpl_putenv declaration.
25575         (putenv): Renamed from rpl_putenv. Change argument type from
25576         'const char *' to 'char *'.
25577         * m4/putenv.m4 (gl_FUNC_PUTENV): Require gl_STDLIB_H_DEFAULTS. Instead
25578         of defining putenv in config.h, just set REPLACE_PUTENV.
25579         * modules/putenv (Depends-on): Add stdlib.
25580         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
25581         (Include): Use <stdlib.h>.
25582         * lib/stdlib.in.h (putenv): New declaration.
25583         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_PUTENV and
25584         REPLACE_PUTENV.
25585         * modules/stdlib (Makefile.am): Substitute GNULIB_PUTENV and
25586         REPLACE_PUTENV.
25587         Needed for MacOS X 10.5.0.
25588         Reported by Peter O'Gorman <peter@pogma.com>.
25589
25590 2007-11-01  Jim Meyering  <meyering@redhat.com>
25591
25592         Treat an empty date string exactly like "0".
25593         * lib/getdate.y (get_date): Once any isspace or TZ= prefix is consumed,
25594         if the remaining date string (to be parsed) is empty, use "0".
25595         Reported by Mischa Molhoek and discussed in this thread:
25596         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/11726>.
25597
25598 2007-10-31  Bruno Haible  <bruno@clisp.org>
25599
25600         * m4/intmax_t.m4 (gl_AC_TYPE_INTMAX_T, gt_AC_TYPE_INTMAX_T): Use
25601         AC_TYPE_LONG_LONG_INT instead of gl_AC_TYPE_LONG_LONG.
25602         * m4/uintmax_t.m4 (gl_AC_TYPE_UINTMAX_T): Use
25603         AC_TYPE_UNSIGNED_LONG_LONG_INT instead of gl_AC_TYPE_UNSIGNED_LONG_LONG.
25604         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Remove macro.
25605         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG): Remove macro.
25606
25607 2007-10-31  Bruno Haible  <bruno@clisp.org>
25608
25609         * m4/longlong.m4 (_AC_TYPE_LONG_LONG_SNIPPET): New macro, extracted
25610         from AC_TYPE_LONG_LONG_INT and AC_TYPE_UNSIGNED_LONG_LONG_INT.
25611         (AC_TYPE_LONG_LONG_INT): Use it.
25612         (AC_TYPE_UNSIGNED_LONG_LONG_INT): Moved here from m4/ulonglong.m4. Use
25613         it as well.
25614         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Remove macro; moved
25615         to m4/longlong.m4.
25616         * modules/stdint (Files): Remove m4/ulonglong.m4.
25617         * modules/strtoull (Files): Use m4/longlong.m4 instead of
25618         m4/ulonglong.m4.
25619         * modules/strtoumax (Files): Likewise.
25620
25621 2007-10-30  Bruno Haible  <bruno@clisp.org>
25622
25623         * modules/xvasprintf-posix: New file.
25624         Suggested by Eric Blake.
25625
25626 2007-10-30  Bruno Haible  <bruno@clisp.org>
25627
25628         * modules/xprintf-posix-tests: New file.
25629         * tests/test-xprintf-posix.sh: New file.
25630         * tests/test-xprintf-posix.c: New file.
25631         * tests/test-xfprintf-posix.c: New file.
25632
25633         * modules/xprintf-posix: New file.
25634
25635 2007-10-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
25636
25637         * modules/fbufmode-tests (MOSTLYCLEANFILES): Remove temp files.
25638         * modules/freadable-tests (MOSTLYCLEANFILES): Likewise.
25639         * modules/fwritable-tests (MOSTLYCLEANFILES): Likewise.
25640
25641 2007-10-29  Bruno Haible  <bruno@clisp.org>
25642
25643         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): Rename the cache variable to
25644         contain the special marker '_cv_'.
25645         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): Likewise.
25646         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): Likewise.
25647         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): Likewise.
25648         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): Likewise.
25649         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): Likewise.
25650         Reported by Ralf Wildenhues.
25651
25652 2007-10-29  Bruno Haible  <bruno@clisp.org>
25653
25654         * gnulib-tool (func_import): When --lgpl is not specified, set
25655         sed_transform_lib_file to convert LGPL and GPLv2+ copyright headers to
25656         GPLv3.
25657         Reported by Simon Josefsson.
25658
25659 2007-10-28  Bruno Haible  <bruno@clisp.org>
25660
25661         * lib/math.in.h: Test REPLACE_ISFINITE instead of HAVE_DECL_ISFINITE.
25662         * m4/isfinite.m4 (gl_ISFINITE): Initialize REPLACE_ISFINITE instead of
25663         HAVE_DECL_ISFINITE.
25664         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Update.
25665         * modules/math (Makefile.am): Substitute REPLACE_ISFINITE instead of
25666         HAVE_DECL_ISFINITE.
25667
25668 2007-10-28  Bruno Haible  <bruno@clisp.org>
25669
25670         * lib/stdint.in.h (_STDINT_MAX): Subtract 1 from an unused signed
25671         integer shift in the signed case. Fixes warnings with OSF/1 5.1 cc.
25672
25673 2007-10-28  Bruno Haible  <bruno@clisp.org>
25674
25675         Fix link errors with Sun C 5.0 on Solaris 10.
25676         * m4/floorf.m4 (gl_FUNC_FLOORF): Consider also the case that the
25677         function is declared but not present in the compiler's libm.
25678         * m4/floorl.m4 (gl_FUNC_FLOORL): Likewise.
25679         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
25680         * m4/ceill.m4 (gl_FUNC_CEILL: Likewise.
25681         * lib/math.in.h: Test REPLACE_CEILF instead of HAVE_DECL_CEILF.
25682         Test REPLACE_CEILL instead of HAVE_DECL_CEILL.
25683         Test REPLACE_FLOORF instead of HAVE_DECL_FLOORF.
25684         Test REPLACE_FLOORL instead of HAVE_DECL_FLOORL.
25685         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Update.
25686         * modules/math (Makefile.am): Substitute REPLACE_CEILF instead of
25687         HAVE_DECL_CEILF, REPLACE_CEILL instead of HAVE_DECL_CEILL,
25688         REPLACE_FLOORF instead of HAVE_DECL_FLOORF, REPLACE_FLOORL instead of
25689         HAVE_DECL_FLOORL.
25690
25691 2007-10-28  Bruno Haible  <bruno@clisp.org>
25692
25693         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): New macro, extracted from
25694         gl_FUNC_FLOORL. Cache the result.
25695         (gl_FUNC_FLOORL): Use it.
25696         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): New macro, extracted from
25697         gl_FUNC_CEILL. Cache the result.
25698         (gl_FUNC_CEILL): Use it.
25699
25700         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): New macro, extracted from
25701         gl_FUNC_FLOOR. Cache the result.
25702         (gl_FUNC_FLOOR): Use it.
25703         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): New macro, extracted from
25704         gl_FUNC_CEIL. Cache the result.
25705         (gl_FUNC_CEIL): Use it.
25706
25707         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): New macro, extracted from
25708         gl_FUNC_FLOORF. Cache the result.
25709         (gl_FUNC_FLOORF): Use it.
25710         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): New macro, extracted from
25711         gl_FUNC_CEILF. Cache the result.
25712         (gl_FUNC_CEILF): Use it.
25713
25714 2007-10-28  Bruno Haible  <bruno@clisp.org>
25715
25716         * gnulib-tool: Allow specifying the LGPL version number through
25717         --lgpl=2 or --lgpl=3.
25718         (func_usage): Document --lgpl with argument.
25719         Handle --lgpl=... arguments.
25720         (func_import): Recognize also gl_LGPL calls with an argument. When
25721         --lgpl=2 is used and the module's license is just LGPL, report an
25722         error. Set sed_transform_lib_file according to the lgpl variable. In
25723         the generated files, use --lgpl or gl_LGPL invocations with argument,
25724         if necessary.
25725         * doc/gnulib-intro.texi (Copyright): Explain how to get modules under
25726         an LGPv2+ license.
25727         * doc/gnulib-tool.texi (Modified imports): Update explanation of
25728         gl_LGPL macro.
25729
25730 2007-10-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
25731             Bruno Haible  <bruno@clisp.org>
25732
25733         * lib/unistr.h (u8_uctomb_aux): Declare also if !HAVE_INLINE.
25734         (u16_uctomb_aux): Likewise.
25735         * lib/unistr/u8-uctomb-aux.c (u8_uctomb_aux): Define also if
25736         !HAVE_INLINE.
25737         * lib/unistr/u16-uctomb-aux.c (u16_uctomb_aux): Likewise
25738
25739 2007-10-28  Bruno Haible  <bruno@clisp.org>
25740
25741         * modules/error: Add a notice recommending to change XGETTEXT_OPTIONS.
25742         Invoke AM_GETTEXT_OPTION if it exists.
25743         * modules/vasprintf: Likewise.
25744         * modules/verror: Likewise.
25745         * modules/xprintf: Likewise.
25746         * modules/xvasprintf: Likewise.
25747
25748 2007-10-27  Ben Pfaff  <blp@gnu.org>
25749
25750         * lib/math.in.h: Define isfinite macro and prototypes for
25751         gl_isfinitef, gl_isfinited, gl_isfinitel if we are providing
25752         implementations.
25753         * m4/math_h.m4: New substitutions for isfinite module.
25754         * lib/isfinite.c: New file.
25755         * m4/isfinite.m4: New file.
25756         * modules/math: Replace isfinite-related @VARS@ in math.in.h.
25757         * modules/isfinite: New file.
25758         * modules/isfinite-tests: New file.
25759         * tests/tests-isfinite.c: New file.
25760         * doc/functions/isfinite.texi: Mention isfinite module.
25761         * MODULES.html.sh: Mention new module.
25762
25763 2007-10-27  Ben Pfaff  <blp@gnu.org>
25764
25765         Ralf Wildenhues reported that Tru64 4.0D declares the round
25766         functions but does not have definitions.
25767         * m4/check-math-lib.m4 (gl_CHECK_MATH_LIB): If the target function
25768         cannot be found in any library, set the output variable to
25769         "missing" instead of "".
25770         * m4/round.m4: Also use our substitute if we cannot find round in
25771         any library, even if it is declared.
25772         * m4/roundf.m4: Likewise for roundf.
25773         * m4/roundl.m4: Likewise for roundl.
25774         * lib/math.in.h: Undefine roundf, round, roundl before defining
25775         their replacements, to allow for hypothetical systems where these
25776         may be defined as macros but not available in libraries.
25777
25778 2007-10-27  Bruno Haible  <bruno@clisp.org>
25779
25780         * doc/gnulib.texi: Invoke @firstparagraphindent.
25781         * doc/gnulib-tool.texi (Simple update): Mention possible incompatible
25782         changes in gnulib.
25783         (Source changes): New section.
25784
25785 2007-10-26  Bruno Haible  <bruno@clisp.org>
25786
25787         * m4/gnulib-common.m4 (AC_C_RESTRICT): New overriding definition,
25788         borrowed from autoconf.
25789
25790 2007-10-26  Bruno Haible  <bruno@clisp.org>
25791
25792         * lib/strerror.c (rpl_strerror): Return "Unknown error ..." also if
25793         strerror returned the empty string. Needed on HP-UX 11.00.
25794
25795 2007-10-24  Micah Cowan  <micah@cowan.name>
25796
25797         Remove vestiges of cvs-gnulib-checkout process.  Now we use git.
25798         * build-aux/bootstrap: Remove support for now-unnecessary option,
25799         --cvs-user, and envvars CVS_USER, CVS_RSH.
25800
25801 2007-10-24  Jim Meyering  <meyering@redhat.com>
25802
25803         Avoid diagnostics from sha1sum when there is no cached checksum.
25804         * build-aux/bootstrap (update_po_files): Skip the sha1sum check
25805         if the po.s1 file hasn't been created yet.
25806
25807         * build-aux/bootstrap: Sync from coreutils:
25808         2007-10-24  Jim Meyering  <meyering@redhat.com>
25809         Get gnulib from the git repository, not from an obsolete cvs one.
25810         * build-aux/bootstrap: Suggestion from Micah Cowan.
25811         2007-10-04  Jim Meyering  <jim@meyering.net>
25812         * build-aux/bootstrap (slurp): Adapt to _.h -> .in.h name change.
25813         (update_po_files): Work also when there are no .po files in po/.
25814
25815 2007-10-24  Paul Eggert  <eggert@cs.ucla.edu>
25816
25817         * README: Append ".git" to git and cg examples.
25818         Problem reported by Benoit Sigoure.
25819
25820 2007-10-23  Micah Cowan  <micah@cowan.name>
25821
25822         * users.txt: Add wget.
25823
25824 2007-10-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
25825
25826         Fix linking of some unistdio tests on FreeBSD.
25827         * modules/unistdio/u16-vsnprintf-tests
25828         (test_u16_vsprintf1_LDADD): Add @LIBINTL@.
25829         * modules/unistdio/u16-vsprintf-tests
25830         (test_u16_vsnprintf1_LDADD): Likewise.
25831         * modules/unistdio/u32-vsnprintf-tests
25832         (test_u32_vsnprintf1_LDADD): Likewise.
25833         * modules/unistdio/u32-vsprintf-tests
25834         (test_u32_vsprintf1_LDADD): Likewise.
25835         * modules/unistdio/u8-vsnprintf-tests
25836         (test_u8_vsnprintf1_LDADD): Likewise.
25837         * modules/unistdio/u8-vsprintf-tests
25838         (test_u8_vsprintf1_LDADD): Likewise.
25839         * modules/unistdio/ulc-vsnprintf-tests
25840         (test_ulc_vsnprintf1_LDADD): Likewise.
25841         * modules/unistdio/ulc-vsprintf-tests
25842         (test_ulc_vsprintf1_LDADD): Likewise.
25843
25844         Fix linking of some uniconv tests on FreeBSD.
25845         * modules/uniconv/u16-conv-from-enc-tests
25846         (test_u16_conv_from_enc_LDADD): Link $(LDADD) before @LIBICONV@.
25847         * modules/uniconv/u16-conv-to-enc-tests
25848         (test_u16_conv_to_enc_LDADD): Likewise.
25849         * modules/uniconv/u16-strconv-from-enc-tests
25850         (test_u16_strconv_from_enc_LDADD): Likewise.
25851         * modules/uniconv/u16-strconv-to-enc-tests
25852         (test_u16_strconv_to_enc_LDADD): Likewise.
25853         * modules/uniconv/u32-conv-from-enc-tests
25854         (test_u32_conv_from_enc_LDADD): Likewise.
25855         * modules/uniconv/u32-conv-to-enc-tests
25856         (test_u32_conv_to_enc_LDADD): Likewise.
25857         * modules/uniconv/u32-strconv-from-enc-tests
25858         (test_u32_strconv_from_enc_LDADD): Likewise.
25859         * modules/uniconv/u32-strconv-to-enc-tests
25860         (test_u32_strconv_to_enc_LDADD): Likewise.
25861         * modules/uniconv/u8-conv-from-enc-tests
25862         (test_u8_conv_from_enc_LDADD): Likewise.
25863         * modules/uniconv/u8-conv-to-enc-tests
25864         (test_u8_conv_to_enc_LDADD): Likewise.
25865         * modules/uniconv/u8-strconv-from-enc-tests
25866         (test_u8_strconv_from_enc_LDADD): Likewise.
25867         * modules/uniconv/u8-strconv-to-enc-tests
25868         (test_u8_strconv_to_enc_LDADD): Likewise.
25869
25870 2007-10-22  Bruno Haible  <bruno@clisp.org>
25871
25872         * lib/stdint.in.h: Add check that intmax_t and uintmax_t have the same
25873         size.
25874
25875 2007-10-22  Eric Blake  <ebb9@byu.net>
25876
25877         Tweak x*printf documentation.
25878         * lib/xprintf.c (xprintf, xvprintf, xfprintf, xvfprintf): Adjust
25879         variable name and comments.
25880         Suggested by Bruno Haible.
25881
25882 2007-10-22  Bruno Haible  <bruno@clisp.org>
25883
25884         * lib/acl.c (copy_acl): Fix file name in comment.
25885
25886 2007-10-22  Paul Eggert  <eggert@cs.ucla.edu>
25887
25888         Fix Tru64 problem with stdbool.h.
25889         * lib/stdbool.in.h (false, true):
25890         [! (defined __cplusplus || defined __BEOS__) && !defined __GNUC__]:
25891         Don't declare as an enum in this situation; it runs afoul of Tru64.
25892         Problem reported by Steven M. Schweda in
25893         <http://lists.gnu.org/archive/html/bug-autoconf/2007-10/msg00019.html>.
25894
25895 2007-10-22  Eric Blake  <ebb9@byu.net>
25896
25897         Also wrap vf?printf.
25898         * lib/xprintf.h (xvprintf, xvfprintf): New declarations.
25899         * lib/xprintf.c (xprintf, xfprintf): Work for C89.
25900         (xvprintf, xvfprintf): New functions.
25901
25902 2007-10-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
25903
25904         * modules/fstrcmp-tests (test_fstrcmp_LDADD): New, add
25905         @LIBINTL@ for FreeBSD 6.2, $(LIBTHREAD) for AIX 4.3.3.
25906
25907         * lib/uniconv/u16-conv-to-enc.c (U_MBLEN): Define.
25908         * lib/uniconv/u32-conv-to-enc.c (U_MBLEN): Likewise.
25909
25910 2007-10-22  Paul Eggert  <eggert@cs.ucla.edu>
25911
25912         * lib/acl.c (copy_acl): Adjust to IRIX 6.5.  Problem reported
25913         by Bruno Haible.
25914
25915 2007-10-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
25916
25917         * lib/getloadavg.c
25918         [defined (__osf__) && (defined (__alpha) || defined (__alpha__)]:
25919         Undef `sys' after including sys/table.h, for Tru64 4.0D.
25920
25921         * tests/test-i-ring.c: Work for C89.
25922
25923 2007-10-22  Bruno Haible  <bruno@clisp.org>
25924
25925         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Use -1ull, not
25926         -1u, in preprocessor expression, so that we don't test for the bug
25927         in HP-UX 11.00 cpp.  Testing for this bug caused problems; see
25928         <http://lists.gnu.org/archive/html/bug-gnulib/2007-10/msg00329.html>.
25929
25930 2007-10-22  Eric Blake  <ebb9@byu.net>
25931
25932         * tests/test-yesno.sh: Silence stderr during test.
25933
25934 2007-10-22  Simon Josefsson  <simon@josefsson.org>
25935
25936         * modules/crypto/gc-camellia: New file.
25937
25938         * m4/gc-camellia.m4: New file.
25939
25940         * lib/gc-libgcrypt.c (gc_cipher_open): Support Camellia.
25941
25942         * lib/gc.h (enum Gc_cipher): Add GC_CAMELLIA128, GC_CAMELLIA256.
25943
25944 2007-10-22  Simon Josefsson  <simon@josefsson.org>
25945
25946         * build-aux/maint.mk (gzip_rsyncable): Don't fail if gzip sends
25947         --help to stdout.  Reported by sms@antinode.org (Steven
25948         M. Schweda).
25949
25950 2007-10-22  Simon Josefsson  <simon@josefsson.org>
25951
25952         * users.txt: Fix link to libksba.
25953
25954 2007-10-21  Ben Pfaff  <blp@gnu.org>
25955
25956         * modules/roundf-tests: Add dependency on floorf, ceilf to allow
25957         round.c roundf implementation that depends on floorf and ceilf to
25958         be tested unconditionally.
25959
25960 2007-10-21  Ben Pfaff  <blp@gnu.org>
25961
25962         * m4/check-libm-func.m4: Removed.
25963         * m4/check-math-lib.m4: New file.
25964         * m4/round.m4: Rewrite to use gl_CHECK_MATH_LIB.
25965         * m4/roundf.m4: Ditto, and fix lack of HAVE_DECL_ROUNDF
25966         definition and lack of AC_LIBOBJ([roundf]).
25967         * m4/roundl.m4: Ditto, and similarly for roundl.
25968         * modules/round: Reference new m4 file.
25969         * modules/roundf: Ditto.
25970         * modules/roundl: Ditto.
25971         * tests/test-round2.c (main): Use ROUND instead of round.
25972         Bug report from Bruno Haible.
25973
25974 2007-10-21  Bruno Haible  <bruno@clisp.org>
25975
25976         * lib/printf-parse.c: Don't assume <stdint.h> exists in IN_LIBASPRINTF
25977         context.
25978
25979 2007-10-21  Bruno Haible  <bruno@clisp.org>
25980
25981         * tests/test-wcwidth.c (main): Allow negative result for some control
25982         characters.
25983
25984         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Check also the width of U+200B.
25985         Needed on OSF/1 5.1.
25986
25987 2007-10-21  Bruno Haible  <bruno@clisp.org>
25988
25989         * tests/test-floorf1.c: Include isnanf.h.
25990         (main): Use isnanf() instead of isnan().
25991         * tests/test-ceilf1.c: Include isnanf.h.
25992         (main): Use isnanf() instead of isnan().
25993         * tests/test-truncf1.c: Include isnanf.h.
25994         (main): Use isnanf() instead of isnan().
25995         * tests/test-roundf1.c: Include isnanf.h.
25996         (main): Use isnanf() instead of isnan().
25997
25998 2007-10-21  Eric Blake  <ebb9@byu.net>
25999
26000         * users.txt: Update URL for m4.
26001
26002 2007-10-21  Bruno Haible  <bruno@clisp.org>
26003
26004         * users.txt: Add clisp. Update URLs to Simon Josefsson's projects.
26005
26006 2007-10-21  Bruno Haible  <bruno@clisp.org>
26007
26008         * gnulib-tool (func_create_megatestdir): Determine the cvsdate from
26009         Git's management files if the CVS files are not present.
26010
26011 2007-10-20  Bruno Haible  <bruno@clisp.org>
26012
26013         * lib/count-one-bits.h (COUNT_ONE_BITS): Use the builtin also for
26014         gcc-3.4.x.
26015
26016 2007-10-20  Ben Pfaff  <blp@gnu.org>
26017
26018         * lib/math.in.h: Declare round, roundf, roundl if we are providing
26019         implementations.
26020         * m4/math_h.m4: New substitutions for round, roundf, roundl modules.
26021         * lib/round.c: New file.
26022         * lib/roundf.c: New file.
26023         * lib/roundl.c: New file.
26024         * m4/round.m4: New file.
26025         * m4/roundf.m4: New file.
26026         * m4/roundl.m4: New file.
26027         * m4/check-libm-func-m4: New file.
26028         * modules/math: Replace round, roundf, roundl related @VARS@ in
26029         math.in.h.
26030         * modules/round: New file.
26031         * modules/round-tests: New file.
26032         * modules/roundf: New file.
26033         * modules/roundf-tests: New file.
26034         * modules/roundl: New file.
26035         * modules/roundl-tests: New file.
26036         * tests/test-round1.c: New file.
26037         * tests/test-round2.c: New file.
26038         * tests/test-roundf1.c: New file.
26039         * tests/test-roundf2.c: New file.
26040         * tests/test-roundl.c: New file.
26041         * doc/functions/round.texi: Mention round module.
26042         * doc/functions/roundf.texi: Mention roundf module.
26043         * doc/functions/roundl.texi: Mention roundl module.
26044         * MODULES.html.sh: Mention new modules.
26045         Thanks to Bruno Haible for suggestions.
26046
26047 2007-10-20  Jim Meyering  <meyering@redhat.com>
26048
26049         * lib/xprintf.c: Include <config.h> unconditionally.
26050
26051         Change xprintf's license to GPL.
26052         * modules/xprintf (License): s/LGPL/GPL/, since this module
26053         depends on modules (exit and exitfail) which are GPL.
26054         Suggestion from Bruno Haible.
26055
26056         xprintf fixes.
26057         * lib/xprintf.c (xprintf, xfprintf): Use va_end.
26058         Use a clearer diagnostic.
26059         Patch from Bruno Haible.
26060
26061 2007-10-20  Bruno Haible  <bruno@clisp.org>
26062
26063         * lib/vasnprintf.c (VASNPRINTF): Don't report overflow if the available
26064         length is INT_MAX and sizeof (DCHAR_T) > sizeof (TCHAR_T).
26065         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
26066
26067 2007-10-20  Bruno Haible  <bruno@clisp.org>
26068
26069         * tests/test-floorf2.c (correct_result_p): Don't rely on excess
26070         precision in the comparison result > x - 1 or similar.
26071         * tests/test-ceilf2.c (correct_result_p): Likewise.
26072         * tests/test-truncf2.c (correct_result_p): Likewise.
26073         * tests/test-trunc2.c (correct_result_p): Likewise.
26074         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
26075
26076 2007-10-20  Bruno Haible  <bruno@clisp.org>
26077
26078         * modules/ceil: New file.
26079         * m4/ceil.m4: New file.
26080         * doc/functions/ceil.texi: Mention the 'ceil' module.
26081
26082 2007-10-20  Bruno Haible  <bruno@clisp.org>
26083
26084         * modules/floor: New file.
26085         * m4/floor.m4: New file.
26086         * doc/functions/floor.texi: Mention the 'floor' module.
26087
26088 2007-10-20  Bruno Haible  <bruno@clisp.org>
26089
26090         * modules/ceilf-tests (Depends-on): Add fprintf-posix. Needed for use
26091         of %a.
26092         * modules/floorf-tests (Depends-on): Likewise.
26093         * modules/truncf-tests (Depends-on): Likewise.
26094         * modules/trunc-tests (Depends-on): Likewise.
26095         Reported by Ben Pfaff.
26096
26097 2007-10-19  Jim Meyering  <meyering@redhat.com>
26098
26099         * lib/xprintf.c (xprintf, xfprintf): Test err < 0, not just "err".
26100         Don't bother testing specific errno values.  Just test ferror.
26101
26102         New module: xprintf
26103         * modules/xprintf, lib/xprintf.c, lib/xprintf.h: New files.
26104
26105 2007-10-19  Bruno Haible  <bruno@clisp.org>
26106
26107         * modules/csharpexec (Makefile.am): Use @FOO@ syntax instead of $(FOO)
26108         syntax.
26109         * modules/javaexec (Makefile.am): Likewise.
26110         * modules/relocatable-prog (Makefile.am): Likewise.
26111         Suggested by Jim Meyering.
26112
26113 2007-10-18  Bruno Haible  <bruno@clisp.org>
26114
26115         * lib/vasnprintf.c (VASNPRINTF): Don't use %n on glibc >= 2.3 systems.
26116         Reported by Jim Meyering.
26117
26118 2007-10-18  Eric Blake  <ebb9@byu.net>
26119
26120         * modules/filenamecat-tests (Makefile.am): Link against -lintl.
26121
26122 2007-10-18  Bruno Haible  <bruno@clisp.org>
26123
26124         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N, gl_SNPRINTF_DIRECTIVE_N): Put
26125         the format string into writable memory. Needed in Fortify conditions.
26126
26127 2007-10-18  Colin Watson <cjwatson@debian.org>  (tiny change)
26128             Bruno Haible  <bruno@clisp.org>
26129
26130         * lib/trim.c: Include config.h unconditionally. Include trim.h always.
26131         Include ctype.h always. Include stdlib.h, not mbuiter.h, for MB_CUR_MAX.
26132         * modules/trim (Depends-on): Add mbchar.
26133         (configure.ac): Add gl_FUNC_MBRTOWC.
26134         (Makefile.am): Augment lib_SOURCES.
26135
26136 2007-10-17  Paul Eggert  <eggert@cs.ucla.edu>
26137
26138         Modify glob.c to use fstatat and dirfd, to simplify it.
26139         Suggested by Eric Blake.
26140         * lib/glob.c (__fxstatat64) [!_LIBC]: New macro.
26141         Don't include <stdbool.h>; not used.
26142         (link_exists2_p, glob_in_dir) [!_LIBC]: No longer a special case.
26143         (link_exists_p): Simplify implementation, since we can now assume
26144         dirfd and fstatat.
26145         * modules/glob (Depends-on): Add dirfd, openat.  Remove stdbool.
26146
26147 2007-10-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
26148
26149         * gnulib-tool (func_get_dependencies): Fix sed script to
26150         match only tests.
26151
26152 2007-10-17  Bruno Haible  <bruno@clisp.org>
26153
26154         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): On Cygwin, don't
26155         allow locale names without encoding suffix.
26156         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
26157         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
26158
26159 2007-10-16  Bruno Haible  <bruno@clisp.org>
26160
26161         * lib/getcwd.c (__getcwd): Define with explicit rpl_ prefix.
26162         * lib/getgroups.c (getgroups): Likewise.
26163         * lib/gettimeofday.c (localtime, gmtime, tzset): Likewise.
26164
26165 2007-10-16  Bruno Haible  <bruno@clisp.org>
26166
26167         * modules/absolute-header (License): Change from LGPL to LGPLv2+.
26168         * modules/malloc-posix (License): Likewise.
26169         * modules/realloc-posix (License): Likewise.
26170         * modules/calloc-posix (License): Likewise.
26171         * modules/intprops (License): Change from GPL to LGPL, with
26172         Paul Eggert's approval.
26173
26174 2007-10-16  Paul Eggert  <eggert@cs.ucla.edu>
26175
26176         Merge glibc changes into lib/glob.c.
26177
26178         * lib/glob.c (glob_in_dir): Sync with glibc/posix/glob.c, dated
26179         2007-10-15 04:59:03 UTC.  Here are the changes:
26180
26181         2007-10-14  Ulrich Drepper  <drepper@redhat.com>
26182
26183         * lib/glob.c: Reimplement link_exists_p to use fstatat64.
26184
26185         * lib/glob.c: Add some branch prediction throughout.
26186
26187         2007-10-07  Ulrich Drepper  <drepper@redhat.com>
26188
26189         [BZ #5103]
26190         * lib/glob.c (glob): Recognize patterns starting \/.
26191
26192         2007-02-14  Jakub Jelinek  <jakub@redhat.com>
26193
26194         [BZ #3996]
26195         * lib/glob.c (attribute_hidden): Define if not defined.
26196         (glob): Unescape dirname, filename or username when needed and not
26197         GLOB_NOESCAPE.  Handle \/ correctly.  Handle GLOB_MARK if filename
26198         is NULL.  Handle unescaped [ in pattern without closing ].
26199         Don't pass GLOB_CHECK down to recursive glob for directories.
26200         (__glob_pattern_type): New function.
26201         (__glob_pattern_p): Implement using __glob_pattern_type.
26202         (glob_in_dir): Handle GLOB_NOCHECK patterns containing no meta
26203         characters and backslashes if not GLOB_NOESCAPE or unterminated [.
26204         Remove unreachable code.
26205
26206         2006-09-30  Ulrich Drepper  <drepper@redhat.com>
26207
26208         * lib/glob.c (glob_in_dir): Add some comments and asserts to
26209         explain why there are no leaks.
26210
26211         2006-09-25  Jakub Jelinek  <jakub@redhat.com>
26212
26213         [BZ #3253]
26214         * lib/glob.c (glob_in_dir): Don't alloca one struct globlink at a
26215         time, rather allocate increasingly bigger arrays of pointers, if
26216         possible with alloca, if too large with malloc.
26217
26218 2007-10-16  Paul Eggert  <eggert@cs.ucla.edu>
26219
26220         Check for 64-bit int errors in HP-UX 10.20 preprocessor.
26221         Problem reported by H.Merijn Brand in
26222         <http://lists.gnu.org/archive/html/bug-tar/2007-10/msg00018.html>.
26223         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Check preprocessor too.
26224         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
26225
26226 2007-10-15  Bruno Haible  <bruno@clisp.org>
26227
26228         * lib/fchdir.c (close, open, closedir, opendir, dup, dup2): Define
26229         with explicit rpl_ prefix.
26230         * lib/fopen.c (fopen): Likewise.
26231         * lib/freopen.c (freopen): Likewise.
26232         * lib/iconv.c (iconv): Likewise.
26233         * lib/iconv_close.c (iconv_close): Likewise.
26234
26235 2007-10-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
26236
26237         * m4/iconv_open (gl_FUNC_ICONV_OPEN_UTF): Fix cache variable name.
26238
26239 2007-10-15  Bruno Haible  <bruno@clisp.org>
26240
26241         * m4/getaddrinfo.m4 (gl_GETADDRINFO, gl_PREREQ_GETADDRINFO): Use
26242         <stddef.h> instead of <stdlib.h> since we only need NULL.
26243         Reported by Ben Pfaff <blp@cs.stanford.edu>.
26244
26245 2007-10-15  Bruno Haible  <bruno@clisp.org>
26246
26247         * doc/gnulib-tool.texi (Initial import): Swap order of -I directives.
26248         Replace paragraph talking about LIBOBJS.
26249         Reported by Colin Watson <cjwatson@debian.org>.
26250
26251 2007-10-15  Bruno Haible  <bruno@clisp.org>
26252
26253         * m4/getaddrinfo.m4 (gl_GETADDRINFO, gl_PREREQ_GETADDRINFO): Include
26254         <stdlib.h> before using NULL.
26255
26256 2007-10-15  Simon Josefsson  <simon@josefsson.org>
26257
26258         * m4/getaddrinfo.m4: Use NULL rather than 0 for pointers.
26259         Reported by Albert Chin <china@thewrittenword.com>.
26260
26261 2007-10-14  Bruno Haible  <bruno@clisp.org>
26262
26263         * modules/iconv_open-utf-tests: New file.
26264         * tests/test-iconv-utf.c: New file.
26265
26266         Enhance iconv_open to support UTF-16BE, UTF-16LE, UTF-32BE, UTF-32LE.
26267         * modules/iconv_open-utf: New file.
26268         * lib/iconv.in.h (_ICONV_UTF8_UTF*, _ICONV_UTF*_UTF8): New macros.
26269         (iconv, iconv_close): New declarations.
26270         * lib/iconv_open.c: Include c-strcase.h. Don't require ICONV_FLAVOR to
26271         be defined.
26272         (iconv_open): Add special handling of conversion between UTF-8 and
26273         UTF-{16,32}{BE,LE}.
26274         * lib/iconv.c: New file, incorporating code from GNU libiconv 1.11.
26275         * lib/iconv_close.c: New file.
26276         * m4/iconv_open.m4 (gl_REPLACE_ICONV_OPEN): New macro, extracted from
26277         gl_FUNC_ICONV_OPEN.
26278         (gl_FUNC_ICONV_OPEN): Use it.
26279         (gl_FUNC_ICONV_OPEN_UTF): New macro.
26280         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS): Initialize also REPLACE_ICONV
26281         and REPLACE_ICONV_UTF.
26282         * modules/iconv_open (Depends-on): Add c-strcase.
26283         (Makefile.am): Substitute also REPLACE_ICONV, REPLACE_ICONV_UTF,
26284         ICONV_CONST.
26285         * doc/functions/iconv_open.texi: Mention the iconv_open-utf module.
26286
26287 2007-10-13  Albert Chin  <china@thewrittenword.com>
26288             Bruno Haible  <bruno@clisp.org>
26289
26290         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Perform the test for getaddrinfo
26291         through a link check that includes <netdb.h>. Needed for OSF/1 5.1.
26292
26293 2007-10-13  Bruno Haible  <bruno@clisp.org>
26294
26295         * lib/argp-fmtstream.h (ARGP_FS_EI): If __GNUC_STDC_INLINE__ is
26296         defined, use the ISO C99 inline semantics.
26297         * lib/argp.h (ARGP_EI): Likewise.
26298
26299 2007-10-13  Bruno Haible  <bruno@clisp.org>
26300
26301         Handle 'inline' change in gcc 4.3.0.
26302         * lib/argp-fmtstream.h (argp_fmtstream_putc, argp_fmtstream_puts,
26303         argp_fmtstream_write, argp_fmtstream_set_lmargin,
26304         argp_fmtstream_set_rmargin, argp_fmtstream_set_wmargin,
26305         argp_fmtstream_point): Disable 'extern' declaration if the function
26306         definition is going to be provided inline.
26307         (ARGP_FS_EI): If __GNUC_STDC_INLINE__ is defined, use the GNU C inline
26308         semantics, not the ISO C99 inline semantics.
26309         * lib/argp.h (argp_usage, _option_is_short, _option_is_end): Disable
26310         'extern' declaration if the function definition is going to be provided
26311         inline.
26312         (ARGP_EI): Don't assume GNU C. If __GNUC_STDC_INLINE__ is defined, use
26313         the GNU C inline semantics, not the ISO C99 inline semantics. With
26314         GCC 4.2, avoid a warning.
26315
26316 2007-10-13  Bruno Haible  <bruno@clisp.org>
26317
26318         * lib/freading.h (freading): Enable the use of __freading for
26319         glibc >= 2.7.
26320         * lib/freading.c (freading): Likewise.
26321
26322 2007-10-12  Paul Eggert  <eggert@cs.ucla.edu>
26323
26324         * lib/argp-fmtstream.h (ARGP_FS_EI): Work around GCC 4.2.1 diagnostic
26325         "warning: C99 inline functions are not supported; using GNU89".
26326
26327 2007-10-12  Bruno Haible  <bruno@clisp.org>
26328
26329         * lib/ceil.c (FUNC): Avoid rounding errors for values near a power
26330         of 2.
26331         * tests/test-ceilf2.c: New file.
26332         * modules/ceilf-tests: (Files, Depends-on, Makefile.am): Add new test.
26333
26334         * tests/test-ceilf1.c: Renamed from tests/test-ceilf.c.
26335         * modules/ceilf-tests: Update.
26336
26337 2007-10-12  Bruno Haible  <bruno@clisp.org>
26338
26339         * lib/floor.c (FUNC): Avoid rounding errors for values near a power
26340         of 2.
26341         * tests/test-floorf2.c: New file.
26342         * modules/floorf-tests: (Files, Depends-on, Makefile.am): Add new test.
26343
26344         * tests/test-floorf1.c: Renamed from tests/test-floorf.c.
26345         * modules/floorf-tests: Update.
26346
26347 2007-10-12  Bruno Haible  <bruno@clisp.org>
26348
26349         * tests/test-trunc2.c: New file.
26350         * modules/trunc-tests: (Files, Depends-on, Makefile.am): Add new test.
26351
26352         * tests/test-trunc1.c: Renamed from tests/test-trunc.c.
26353         * modules/trunc-tests: Update.
26354
26355 2007-10-12  Bruno Haible  <bruno@clisp.org>
26356
26357         * lib/trunc.c (FUNC): Avoid rounding errors for values near a power
26358         of 2.
26359         * tests/test-truncf2.c: New file.
26360         * modules/truncf-tests: (Files, Depends-on, Makefile.am): Add new test.
26361
26362         * tests/test-truncf1.c: Renamed from tests/test-truncf.c.
26363         * modules/truncf-tests: Update.
26364
26365 2007-10-11  Eric Blake  <ebb9@byu.net>
26366
26367         Don't claim strerror is broken on Interix.
26368         * doc/functions/strerror.texi (strerror): Known broken systems are
26369         now Solaris 8, and not Interix.
26370         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): No longer filter out
26371         Interix on cross-compile.
26372         Reported by Martin Koeppe in
26373         http://lists.gnu.org/archive/html/bug-gnulib/2007-10/msg00005.html.
26374
26375 2007-10-11  Bruno Haible  <bruno@clisp.org>
26376
26377         * modules/i-ring-tests: New file.
26378         * tests/test-i-ring.c: Renamed from lib/i-ring-test.c. Use ASSERT
26379         instead of assert.
26380
26381 2007-10-11  Bruno Haible  <bruno@clisp.org>
26382
26383         * modules/filenamecat-tests: New file.
26384         * tests/test-filenamecat.c: New file, extracted from lib/filenamecat.c.
26385         * lib/filenamecat.c: Remove test code.
26386
26387 2007-10-11  Paul Eggert  <eggert@cs.ucla.edu>
26388
26389         Simplify and modernize strerror substitute, partly to fix Solaris 8 bug.
26390
26391         * lib/strerror.c: Include <string.h> always, to test interface,
26392         and to remove the need for the dummy.
26393         Include intprops.h to compute width instead of doing it ourselves
26394         and missing a CHAR_BIT declaration, which broke tar 1.19 on Solaris 8.
26395         (strerror): Define it to return NULL if there's no system strerror.
26396         (rpl_strerror): Use INT_STRLEN_BOUND to compute bound.
26397         Omit !HAVE_STRERROR code.  We don't need to worry about supporting
26398         ancient pre-strerror Unix systems well any more.  Saying "unknown
26399         system error" is enough.
26400         * lib/string.in.h (strerror): Simplify the ifdef to reflect the
26401         simpler strerror.c implementation.
26402         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE, gl_PREREQ_STDERROR):
26403         Simplify the tests to reflect the simpler strerror implementation.
26404         * modules/strerror (Depends-on): Add intprops.
26405
26406 2007-10-09  Eric Blake  <ebb9@byu.net>
26407
26408         Silence test-fpending.
26409         * modules/fpending-tests (Files): Add wrapper script.
26410         * tests/test-fpending.sh: New file.
26411
26412 2007-10-09  Bruno Haible  <bruno@clisp.org>
26413
26414         * MODULES.html.sh (func_module): Don't create a hyperlink for
26415         function names like 'printf_frexp'.
26416         (Misc): Add crc, memxor.
26417         (Characteristics of floating types): New section.
26418         (Mathematics): Add ceilf, ceill, floorf, floorl, frexpl-nolibm,
26419         isnanf-nolibm, signbit, trunc, truncf, truncl.
26420         (Enhancements for ISO C 99 functions): New subsection Input/output.
26421         (Support for systems lacking POSIX:2001): Add arpa_inet, calloc-posix,
26422         fcntl, fopen, freopen, fseek, fseeko, ftell, ftello, iconv_open,
26423         locale, malloc-posix, netinet_in, open, realloc-posix, signal, sleep.
26424         (Compatibility checks for POSIX:2001 functions): Add clock-time.
26425         (Enhancements for POSIX:2001 functions): Add chdir-long.
26426         (File system functions): Add areadlink, chdir-safer, read-file.
26427         Remove cycle-check.
26428         (File system as inode set): New section.
26429         (Date and time): Add gethrxtime.
26430         (Multithreading): Add openmp.
26431         (Internationalization functions): Add localename.
26432         (Unicode string functions): Add unistr/u*-mbsnlen.
26433         (Support for maintaining and releasing projects): Add git-version-gen.
26434         (Lone files): Remove directories.
26435
26436 2007-10-08  Ben Pfaff  <blp@gnu.org>
26437
26438         * lib/xmalloca.h: Fix typo in comment.
26439
26440 2007-10-08  Paul Eggert  <eggert@cs.ucla.edu>
26441
26442         * lib/xnanosleep.c (xnanosleep): Don't assume GCC 4.3.0 behavior
26443         when avoiding problems with integer overflow.  Use a portable test
26444         instead.
26445
26446 2007-10-08  Simon Josefsson  <simon@josefsson.org>
26447
26448         * modules/dummy (License): Change to LGPLv2+.
26449         * modules/float (License): Likewise
26450         * modules/realloc (License): Likewise
26451         * modules/stdlib (License): Likewise
26452
26453 2007-10-07  Bruno Haible  <bruno@clisp.org>
26454
26455         * trunc.c (TWO_MANT_DIG): Change type to DOUBLE.
26456         * floor.c (TWO_MANT_DIG): Likewise.
26457         * ceil.c (TWO_MANT_DIG): Likewise.
26458         Reported by Ben Pfaff.
26459
26460 2007-10-07  Bruno Haible  <bruno@clisp.org>
26461
26462         Avoid gcc warnings "declaration of 'exp' shadows a global declaration".
26463         * lib/math.in.h (frexp, frexpl): Change parameter name to 'expptr'.
26464         * lib/frexp.c (FUNC): Likewise.
26465         * lib/printf-frexp.h (printf_frexp): Likewise.
26466         * lib/printf-frexpl.h (printf_frexpl): Likewise.
26467         * lib/printf-frexp.c (FUNC): Likewise.
26468         Suggested by Jim Meyering.
26469
26470 2007-10-07  Jim Meyering  <meyering@redhat.com>
26471
26472         Make xnanosleep's integer overflow test more robust.
26473         * lib/xnanosleep.c (xnanosleep): Declare a temporary to be "volatile",
26474         so that gcc-4.3.0 doesn't optimize away this test for overflow.
26475
26476 2007-10-07  Bruno Haible  <bruno@clisp.org>
26477
26478         * NEWS: Mention the license change.
26479
26480         * doc/gnulib-intro.texi (Copyright): Update the meaning of the license
26481         abbreviations in the modules files.
26482
26483         Change copyright notice from GPLv2+ to GPLv3+.
26484         * README: Change copyright notice.
26485         * MODULES.html.sh: Likewise.
26486         * build-aux/bootstrap.conf: Likewise.
26487         * build-aux/config.libpath: Likewise.
26488         * build-aux/csharpcomp.sh.in: Likewise.
26489         * build-aux/csharpexec.sh.in: Likewise.
26490         * build-aux/install-reloc: Likewise.
26491         * build-aux/javacomp.sh.in: Likewise.
26492         * build-aux/javaexec.sh.in: Likewise.
26493         * build-aux/ldd.sh.in: Likewise.
26494         * build-aux/reloc-ldflags: Likewise.
26495         * build-aux/relocatable.sh.in: Likewise.
26496         * build-aux/x-to-1.in: Likewise.
26497         * check-module: Likewise.
26498         * config/srclistvars.sh: Likewise.
26499         * gnulib-tool: Likewise.
26500         * lib/acl-internal.h: Likewise.
26501         * lib/acl.c: Likewise.
26502         * lib/acl.h: Likewise.
26503         * lib/acl_entries.c: Likewise.
26504         * lib/areadlink-with-size.c: Likewise.
26505         * lib/areadlink.c: Likewise.
26506         * lib/areadlink.h: Likewise.
26507         * lib/argmatch.c: Likewise.
26508         * lib/argmatch.h: Likewise.
26509         * lib/argp-ba.c: Likewise.
26510         * lib/argp-eexst.c: Likewise.
26511         * lib/argp-fmtstream.c: Likewise.
26512         * lib/argp-fmtstream.h: Likewise.
26513         * lib/argp-fs-xinl.c: Likewise.
26514         * lib/argp-help.c: Likewise.
26515         * lib/argp-namefrob.h: Likewise.
26516         * lib/argp-parse.c: Likewise.
26517         * lib/argp-pin.c: Likewise.
26518         * lib/argp-pv.c: Likewise.
26519         * lib/argp-pvh.c: Likewise.
26520         * lib/argp-xinl.c: Likewise.
26521         * lib/argp.h: Likewise.
26522         * lib/at-func.c: Likewise.
26523         * lib/atanl.c: Likewise.
26524         * lib/backupfile.c: Likewise.
26525         * lib/backupfile.h: Likewise.
26526         * lib/basename.c: Likewise.
26527         * lib/binary-io.h: Likewise.
26528         * lib/byteswap.in.h: Likewise.
26529         * lib/c-stack.c: Likewise.
26530         * lib/c-stack.h: Likewise.
26531         * lib/c-strcasestr.c: Likewise.
26532         * lib/c-strcasestr.h: Likewise.
26533         * lib/c-strstr.c: Likewise.
26534         * lib/c-strstr.h: Likewise.
26535         * lib/c-strtod.c: Likewise.
26536         * lib/calloc.c: Likewise.
26537         * lib/canon-host.c: Likewise.
26538         * lib/canon-host.h: Likewise.
26539         * lib/canonicalize-lgpl.c: Likewise.
26540         * lib/canonicalize.c: Likewise.
26541         * lib/canonicalize.h: Likewise.
26542         * lib/ceil.c: Likewise.
26543         * lib/ceilf.c: Likewise.
26544         * lib/ceill.c: Likewise.
26545         * lib/chdir-long.c: Likewise.
26546         * lib/chdir-long.h: Likewise.
26547         * lib/chdir-safer.c: Likewise.
26548         * lib/chdir-safer.h: Likewise.
26549         * lib/chown.c: Likewise.
26550         * lib/classpath.c: Likewise.
26551         * lib/classpath.h: Likewise.
26552         * lib/clean-temp.c: Likewise.
26553         * lib/clean-temp.h: Likewise.
26554         * lib/cloexec.c: Likewise.
26555         * lib/close-stream.c: Likewise.
26556         * lib/closein.c: Likewise.
26557         * lib/closein.h: Likewise.
26558         * lib/closeout.c: Likewise.
26559         * lib/closeout.h: Likewise.
26560         * lib/concat-filename.c: Likewise.
26561         * lib/copy-file.c: Likewise.
26562         * lib/copy-file.h: Likewise.
26563         * lib/count-one-bits.h: Likewise.
26564         * lib/crc.c: Likewise.
26565         * lib/crc.h: Likewise.
26566         * lib/creat-safer.c: Likewise.
26567         * lib/csharpcomp.c: Likewise.
26568         * lib/csharpcomp.h: Likewise.
26569         * lib/csharpexec.c: Likewise.
26570         * lib/csharpexec.h: Likewise.
26571         * lib/cycle-check.c: Likewise.
26572         * lib/cycle-check.h: Likewise.
26573         * lib/diacrit.c: Likewise.
26574         * lib/diacrit.h: Likewise.
26575         * lib/diffseq.h: Likewise.
26576         * lib/dirchownmod.c: Likewise.
26577         * lib/dirent.in.h: Likewise.
26578         * lib/dirfd.c: Likewise.
26579         * lib/dirfd.h: Likewise.
26580         * lib/dirname.c: Likewise.
26581         * lib/dirname.h: Likewise.
26582         * lib/dummy.c: Likewise.
26583         * lib/dup-safer.c: Likewise.
26584         * lib/dup2.c: Likewise.
26585         * lib/eealloc.h: Likewise.
26586         * lib/error.c: Likewise.
26587         * lib/error.h: Likewise.
26588         * lib/euidaccess.c: Likewise.
26589         * lib/exclude.c: Likewise.
26590         * lib/exclude.h: Likewise.
26591         * lib/execute.c: Likewise.
26592         * lib/execute.h: Likewise.
26593         * lib/exitfail.c: Likewise.
26594         * lib/exitfail.h: Likewise.
26595         * lib/expl.c: Likewise.
26596         * lib/fatal-signal.c: Likewise.
26597         * lib/fatal-signal.h: Likewise.
26598         * lib/fbufmode.c: Likewise.
26599         * lib/fbufmode.h: Likewise.
26600         * lib/fchdir.c: Likewise.
26601         * lib/fchmodat.c: Likewise.
26602         * lib/fchownat.c: Likewise.
26603         * lib/fcntl--.h: Likewise.
26604         * lib/fcntl-safer.h: Likewise.
26605         * lib/fcntl.in.h: Likewise.
26606         * lib/fd-safer.c: Likewise.
26607         * lib/fflush.c: Likewise.
26608         * lib/file-has-acl.c: Likewise.
26609         * lib/file-set.c: Likewise.
26610         * lib/file-type.c: Likewise.
26611         * lib/file-type.h: Likewise.
26612         * lib/fileblocks.c: Likewise.
26613         * lib/filemode.c: Likewise.
26614         * lib/filemode.h: Likewise.
26615         * lib/filename.h: Likewise.
26616         * lib/filenamecat.c: Likewise.
26617         * lib/filenamecat.h: Likewise.
26618         * lib/findprog.c: Likewise.
26619         * lib/findprog.h: Likewise.
26620         * lib/float.in.h: Likewise.
26621         * lib/floor.c: Likewise.
26622         * lib/floorf.c: Likewise.
26623         * lib/floorl.c: Likewise.
26624         * lib/fopen-safer.c: Likewise.
26625         * lib/fopen.c: Likewise.
26626         * lib/fpending.c: Likewise.
26627         * lib/fpending.h: Likewise.
26628         * lib/fprintf.c: Likewise.
26629         * lib/fprintftime.h: Likewise.
26630         * lib/fpucw.h: Likewise.
26631         * lib/fpurge.c: Likewise.
26632         * lib/fpurge.h: Likewise.
26633         * lib/freadable.c: Likewise.
26634         * lib/freadable.h: Likewise.
26635         * lib/freadahead.c: Likewise.
26636         * lib/freadahead.h: Likewise.
26637         * lib/freading.c: Likewise.
26638         * lib/freading.h: Likewise.
26639         * lib/free.c: Likewise.
26640         * lib/freopen.c: Likewise.
26641         * lib/frexp.c: Likewise.
26642         * lib/frexpl.c: Likewise.
26643         * lib/fseek.c: Likewise.
26644         * lib/fseterr.c: Likewise.
26645         * lib/fseterr.h: Likewise.
26646         * lib/fstatat.c: Likewise.
26647         * lib/fstrcmp.c: Likewise.
26648         * lib/fstrcmp.h: Likewise.
26649         * lib/fsusage.c: Likewise.
26650         * lib/fsusage.h: Likewise.
26651         * lib/ftell.c: Likewise.
26652         * lib/ftello.c: Likewise.
26653         * lib/fts-cycle.c: Likewise.
26654         * lib/fts.c: Likewise.
26655         * lib/fts_.h: Likewise.
26656         * lib/full-read.c: Likewise.
26657         * lib/full-read.h: Likewise.
26658         * lib/full-write.c: Likewise.
26659         * lib/full-write.h: Likewise.
26660         * lib/fwritable.c: Likewise.
26661         * lib/fwritable.h: Likewise.
26662         * lib/fwriteerror.c: Likewise.
26663         * lib/fwriteerror.h: Likewise.
26664         * lib/fwriting.c: Likewise.
26665         * lib/fwriting.h: Likewise.
26666         * lib/gcd.c: Likewise.
26667         * lib/gcd.h: Likewise.
26668         * lib/getcwd.c: Likewise.
26669         * lib/getdate.h: Likewise.
26670         * lib/getdate.y: Likewise.
26671         * lib/getdomainname.c: Likewise.
26672         * lib/getdomainname.h: Likewise.
26673         * lib/getgroups.c: Likewise.
26674         * lib/gethostname.c: Likewise.
26675         * lib/gethrxtime.c: Likewise.
26676         * lib/gethrxtime.h: Likewise.
26677         * lib/getloadavg.c: Likewise.
26678         * lib/getndelim2.c: Likewise.
26679         * lib/getndelim2.h: Likewise.
26680         * lib/getnline.c: Likewise.
26681         * lib/getnline.h: Likewise.
26682         * lib/getopt.c: Likewise.
26683         * lib/getopt.in.h: Likewise.
26684         * lib/getopt1.c: Likewise.
26685         * lib/getopt_int.h: Likewise.
26686         * lib/getpagesize.h: Likewise.
26687         * lib/getsubopt.c: Likewise.
26688         * lib/gettime.c: Likewise.
26689         * lib/getugroups.c: Likewise.
26690         * lib/getugroups.h: Likewise.
26691         * lib/getusershell.c: Likewise.
26692         * lib/gl_anyavltree_list1.h: Likewise.
26693         * lib/gl_anyavltree_list2.h: Likewise.
26694         * lib/gl_anyhash_list1.h: Likewise.
26695         * lib/gl_anyhash_list2.h: Likewise.
26696         * lib/gl_anylinked_list1.h: Likewise.
26697         * lib/gl_anylinked_list2.h: Likewise.
26698         * lib/gl_anyrbtree_list1.h: Likewise.
26699         * lib/gl_anyrbtree_list2.h: Likewise.
26700         * lib/gl_anytree_list1.h: Likewise.
26701         * lib/gl_anytree_list2.h: Likewise.
26702         * lib/gl_anytree_oset.h: Likewise.
26703         * lib/gl_anytreehash_list1.h: Likewise.
26704         * lib/gl_anytreehash_list2.h: Likewise.
26705         * lib/gl_array_list.c: Likewise.
26706         * lib/gl_array_list.h: Likewise.
26707         * lib/gl_array_oset.c: Likewise.
26708         * lib/gl_array_oset.h: Likewise.
26709         * lib/gl_avltree_list.c: Likewise.
26710         * lib/gl_avltree_list.h: Likewise.
26711         * lib/gl_avltree_oset.c: Likewise.
26712         * lib/gl_avltree_oset.h: Likewise.
26713         * lib/gl_avltreehash_list.c: Likewise.
26714         * lib/gl_avltreehash_list.h: Likewise.
26715         * lib/gl_carray_list.c: Likewise.
26716         * lib/gl_carray_list.h: Likewise.
26717         * lib/gl_linked_list.c: Likewise.
26718         * lib/gl_linked_list.h: Likewise.
26719         * lib/gl_linkedhash_list.c: Likewise.
26720         * lib/gl_linkedhash_list.h: Likewise.
26721         * lib/gl_list.c: Likewise.
26722         * lib/gl_list.h: Likewise.
26723         * lib/gl_oset.c: Likewise.
26724         * lib/gl_oset.h: Likewise.
26725         * lib/gl_rbtree_list.c: Likewise.
26726         * lib/gl_rbtree_list.h: Likewise.
26727         * lib/gl_rbtree_oset.c: Likewise.
26728         * lib/gl_rbtree_oset.h: Likewise.
26729         * lib/gl_rbtreehash_list.c: Likewise.
26730         * lib/gl_rbtreehash_list.h: Likewise.
26731         * lib/gl_sublist.c: Likewise.
26732         * lib/gl_sublist.h: Likewise.
26733         * lib/group-member.c: Likewise.
26734         * lib/group-member.h: Likewise.
26735         * lib/hard-locale.c: Likewise.
26736         * lib/hard-locale.h: Likewise.
26737         * lib/hash-pjw.c: Likewise.
26738         * lib/hash-pjw.h: Likewise.
26739         * lib/hash-triple.c: Likewise.
26740         * lib/hash.c: Likewise.
26741         * lib/hash.h: Likewise.
26742         * lib/human.c: Likewise.
26743         * lib/human.h: Likewise.
26744         * lib/i-ring.c: Likewise.
26745         * lib/i-ring.h: Likewise.
26746         * lib/idcache.c: Likewise.
26747         * lib/imaxabs.c: Likewise.
26748         * lib/imaxdiv.c: Likewise.
26749         * lib/inet_pton.c: Likewise.
26750         * lib/inet_pton.h: Likewise.
26751         * lib/intprops.h: Likewise.
26752         * lib/inttostr.c: Likewise.
26753         * lib/inttostr.h: Likewise.
26754         * lib/inttypes.in.h: Likewise.
26755         * lib/isapipe.c: Likewise.
26756         * lib/isdir.c: Likewise.
26757         * lib/isnan.c: Likewise.
26758         * lib/isnan.h: Likewise.
26759         * lib/isnanf.c: Likewise.
26760         * lib/isnanf.h: Likewise.
26761         * lib/isnanl-nolibm.h: Likewise.
26762         * lib/isnanl.c: Likewise.
26763         * lib/isnanl.h: Likewise.
26764         * lib/javacomp.c: Likewise.
26765         * lib/javacomp.h: Likewise.
26766         * lib/javaexec.c: Likewise.
26767         * lib/javaexec.h: Likewise.
26768         * lib/javaversion.c: Likewise.
26769         * lib/javaversion.h: Likewise.
26770         * lib/javaversion.java: Likewise.
26771         * lib/lbrkprop.h: Likewise.
26772         * lib/lchmod.h: Likewise.
26773         * lib/lchown.c: Likewise.
26774         * lib/ldexpl.c: Likewise.
26775         * lib/linebreak.c: Likewise.
26776         * lib/linebreak.h: Likewise.
26777         * lib/linebuffer.c: Likewise.
26778         * lib/linebuffer.h: Likewise.
26779         * lib/locale.in.h: Likewise.
26780         * lib/logl.c: Likewise.
26781         * lib/long-options.c: Likewise.
26782         * lib/long-options.h: Likewise.
26783         * lib/lstat.c: Likewise.
26784         * lib/lstat.h: Likewise.
26785         * lib/math.in.h: Likewise.
26786         * lib/mbchar.c: Likewise.
26787         * lib/mbchar.h: Likewise.
26788         * lib/mbfile.h: Likewise.
26789         * lib/mbiter.h: Likewise.
26790         * lib/mbscasecmp.c: Likewise.
26791         * lib/mbscasestr.c: Likewise.
26792         * lib/mbschr.c: Likewise.
26793         * lib/mbscspn.c: Likewise.
26794         * lib/mbslen.c: Likewise.
26795         * lib/mbsncasecmp.c: Likewise.
26796         * lib/mbsnlen.c: Likewise.
26797         * lib/mbspbrk.c: Likewise.
26798         * lib/mbspcasecmp.c: Likewise.
26799         * lib/mbsrchr.c: Likewise.
26800         * lib/mbssep.c: Likewise.
26801         * lib/mbsspn.c: Likewise.
26802         * lib/mbsstr.c: Likewise.
26803         * lib/mbstok_r.c: Likewise.
26804         * lib/mbswidth.c: Likewise.
26805         * lib/mbswidth.h: Likewise.
26806         * lib/mbuiter.h: Likewise.
26807         * lib/memcasecmp.c: Likewise.
26808         * lib/memcasecmp.h: Likewise.
26809         * lib/memchr.c: Likewise.
26810         * lib/memcmp.c: Likewise.
26811         * lib/memcoll.c: Likewise.
26812         * lib/memcoll.h: Likewise.
26813         * lib/memcpy.c: Likewise.
26814         * lib/memrchr.c: Likewise.
26815         * lib/mkancesdirs.c: Likewise.
26816         * lib/mkdir-p.c: Likewise.
26817         * lib/mkdir-p.h: Likewise.
26818         * lib/mkdir.c: Likewise.
26819         * lib/mkdirat.c: Likewise.
26820         * lib/mkdtemp.c: Likewise.
26821         * lib/mkstemp-safer.c: Likewise.
26822         * lib/mkstemp.c: Likewise.
26823         * lib/modechange.c: Likewise.
26824         * lib/modechange.h: Likewise.
26825         * lib/mountlist.c: Likewise.
26826         * lib/mountlist.h: Likewise.
26827         * lib/mpsort.c: Likewise.
26828         * lib/nanosleep.c: Likewise.
26829         * lib/obstack.c: Likewise.
26830         * lib/obstack.h: Likewise.
26831         * lib/open-safer.c: Likewise.
26832         * lib/open.c: Likewise.
26833         * lib/openat-die.c: Likewise.
26834         * lib/openat-priv.h: Likewise.
26835         * lib/openat-proc.c: Likewise.
26836         * lib/openat.c: Likewise.
26837         * lib/openat.h: Likewise.
26838         * lib/pagealign_alloc.c: Likewise.
26839         * lib/pagealign_alloc.h: Likewise.
26840         * lib/physmem.c: Likewise.
26841         * lib/physmem.h: Likewise.
26842         * lib/pipe-safer.c: Likewise.
26843         * lib/pipe.c: Likewise.
26844         * lib/pipe.h: Likewise.
26845         * lib/posixtm.c: Likewise.
26846         * lib/posixtm.h: Likewise.
26847         * lib/posixver.c: Likewise.
26848         * lib/printf-frexp.c: Likewise.
26849         * lib/printf-frexp.h: Likewise.
26850         * lib/printf-frexpl.c: Likewise.
26851         * lib/printf-frexpl.h: Likewise.
26852         * lib/printf.c: Likewise.
26853         * lib/progname.c: Likewise.
26854         * lib/progname.h: Likewise.
26855         * lib/progreloc.c: Likewise.
26856         * lib/putenv.c: Likewise.
26857         * lib/quote.c: Likewise.
26858         * lib/quote.h: Likewise.
26859         * lib/quotearg.c: Likewise.
26860         * lib/quotearg.h: Likewise.
26861         * lib/raise.c: Likewise.
26862         * lib/readline.c: Likewise.
26863         * lib/readline.h: Likewise.
26864         * lib/readlink.c: Likewise.
26865         * lib/readtokens.c: Likewise.
26866         * lib/readtokens.h: Likewise.
26867         * lib/readtokens0.c: Likewise.
26868         * lib/readtokens0.h: Likewise.
26869         * lib/readutmp.c: Likewise.
26870         * lib/readutmp.h: Likewise.
26871         * lib/realloc.c: Likewise.
26872         * lib/relocwrapper.c: Likewise.
26873         * lib/rename-dest-slash.c: Likewise.
26874         * lib/rename.c: Likewise.
26875         * lib/rmdir.c: Likewise.
26876         * lib/rpmatch.c: Likewise.
26877         * lib/safe-read.c: Likewise.
26878         * lib/safe-read.h: Likewise.
26879         * lib/safe-write.c: Likewise.
26880         * lib/safe-write.h: Likewise.
26881         * lib/same-inode.h: Likewise.
26882         * lib/same.c: Likewise.
26883         * lib/same.h: Likewise.
26884         * lib/save-cwd.c: Likewise.
26885         * lib/save-cwd.h: Likewise.
26886         * lib/savedir.c: Likewise.
26887         * lib/savedir.h: Likewise.
26888         * lib/savewd.c: Likewise.
26889         * lib/savewd.h: Likewise.
26890         * lib/search.in.h: Likewise.
26891         * lib/setenv.c: Likewise.
26892         * lib/setenv.h: Likewise.
26893         * lib/settime.c: Likewise.
26894         * lib/sh-quote.c: Likewise.
26895         * lib/sh-quote.h: Likewise.
26896         * lib/sig2str.c: Likewise.
26897         * lib/sig2str.h: Likewise.
26898         * lib/signal.in.h: Likewise.
26899         * lib/signbitd.c: Likewise.
26900         * lib/signbitf.c: Likewise.
26901         * lib/signbitl.c: Likewise.
26902         * lib/sigprocmask.c: Likewise.
26903         * lib/sincosl.c: Likewise.
26904         * lib/sleep.c: Likewise.
26905         * lib/sprintf.c: Likewise.
26906         * lib/sqrtl.c: Likewise.
26907         * lib/stat-time.h: Likewise.
26908         * lib/stdio--.h: Likewise.
26909         * lib/stdio-safer.h: Likewise.
26910         * lib/stdlib--.h: Likewise.
26911         * lib/stdlib-safer.h: Likewise.
26912         * lib/stdlib.in.h: Likewise.
26913         * lib/stpcpy.c: Likewise.
26914         * lib/stpncpy.c: Likewise.
26915         * lib/strchrnul.c: Likewise.
26916         * lib/strcspn.c: Likewise.
26917         * lib/strerror.c: Likewise.
26918         * lib/strftime.c: Likewise.
26919         * lib/strftime.h: Likewise.
26920         * lib/striconveh.c: Likewise.
26921         * lib/striconveh.h: Likewise.
26922         * lib/striconveha.c: Likewise.
26923         * lib/striconveha.h: Likewise.
26924         * lib/stripslash.c: Likewise.
26925         * lib/strnlen1.c: Likewise.
26926         * lib/strnlen1.h: Likewise.
26927         * lib/strtod.c: Likewise.
26928         * lib/strtoimax.c: Likewise.
26929         * lib/strtok_r.c: Likewise.
26930         * lib/strtol.c: Likewise.
26931         * lib/strtoll.c: Likewise.
26932         * lib/strtoul.c: Likewise.
26933         * lib/strtoull.c: Likewise.
26934         * lib/sysexits.in.h: Likewise.
26935         * lib/tempname.c: Likewise.
26936         * lib/tempname.h: Likewise.
26937         * lib/timespec.h: Likewise.
26938         * lib/tls.c: Likewise.
26939         * lib/tls.h: Likewise.
26940         * lib/tmpdir.c: Likewise.
26941         * lib/tmpdir.h: Likewise.
26942         * lib/tmpfile-safer.c: Likewise.
26943         * lib/tmpfile.c: Likewise.
26944         * lib/trigl.c: Likewise.
26945         * lib/trigl.h: Likewise.
26946         * lib/trim.c: Likewise.
26947         * lib/trim.h: Likewise.
26948         * lib/trunc.c: Likewise.
26949         * lib/truncf.c: Likewise.
26950         * lib/truncl.c: Likewise.
26951         * lib/tsearch.c: Likewise.
26952         * lib/unicodeio.c: Likewise.
26953         * lib/unicodeio.h: Likewise.
26954         * lib/unistd--.h: Likewise.
26955         * lib/unistd-safer.h: Likewise.
26956         * lib/unistdio/ulc-fprintf.c: Likewise.
26957         * lib/unistdio/ulc-vfprintf.c: Likewise.
26958         * lib/unlinkdir.c: Likewise.
26959         * lib/unlinkdir.h: Likewise.
26960         * lib/unlocked-io.h: Likewise.
26961         * lib/unsetenv.c: Likewise.
26962         * lib/userspec.c: Likewise.
26963         * lib/utime.c: Likewise.
26964         * lib/utimecmp.c: Likewise.
26965         * lib/utimecmp.h: Likewise.
26966         * lib/utimens.c: Likewise.
26967         * lib/verify.h: Likewise.
26968         * lib/verror.c: Likewise.
26969         * lib/verror.h: Likewise.
26970         * lib/version-etc-fsf.c: Likewise.
26971         * lib/version-etc.c: Likewise.
26972         * lib/version-etc.h: Likewise.
26973         * lib/vfprintf.c: Likewise.
26974         * lib/vprintf.c: Likewise.
26975         * lib/vsprintf.c: Likewise.
26976         * lib/w32spawn.h: Likewise.
26977         * lib/wait-process.c: Likewise.
26978         * lib/wait-process.h: Likewise.
26979         * lib/wcwidth.c: Likewise.
26980         * lib/write-any-file.c: Likewise.
26981         * lib/xalloc-die.c: Likewise.
26982         * lib/xalloc.h: Likewise.
26983         * lib/xasprintf.c: Likewise.
26984         * lib/xgetcwd.c: Likewise.
26985         * lib/xgetcwd.h: Likewise.
26986         * lib/xgetdomainname.c: Likewise.
26987         * lib/xgetdomainname.h: Likewise.
26988         * lib/xgethostname.c: Likewise.
26989         * lib/xmalloc.c: Likewise.
26990         * lib/xmalloca.c: Likewise.
26991         * lib/xmalloca.h: Likewise.
26992         * lib/xmemcoll.c: Likewise.
26993         * lib/xnanosleep.c: Likewise.
26994         * lib/xreadlink.c: Likewise.
26995         * lib/xreadlink.h: Likewise.
26996         * lib/xsetenv.c: Likewise.
26997         * lib/xsetenv.h: Likewise.
26998         * lib/xstriconv.c: Likewise.
26999         * lib/xstriconv.h: Likewise.
27000         * lib/xstrndup.c: Likewise.
27001         * lib/xstrndup.h: Likewise.
27002         * lib/xstrtod.c: Likewise.
27003         * lib/xstrtod.h: Likewise.
27004         * lib/xstrtol-error.c: Likewise.
27005         * lib/xstrtol.c: Likewise.
27006         * lib/xstrtol.h: Likewise.
27007         * lib/xtime.h: Likewise.
27008         * lib/xvasprintf.c: Likewise.
27009         * lib/xvasprintf.h: Likewise.
27010         * lib/yesno.c: Likewise.
27011         * lib/yesno.h: Likewise.
27012         * posix-modules: Likewise.
27013         * tests/test-alloca-opt.c: Likewise.
27014         * tests/test-arcfour.c: Likewise.
27015         * tests/test-arctwo.c: Likewise.
27016         * tests/test-argmatch.c: Likewise.
27017         * tests/test-argp-2.sh: Likewise.
27018         * tests/test-argp.c: Likewise.
27019         * tests/test-arpa_inet.c: Likewise.
27020         * tests/test-array_list.c: Likewise.
27021         * tests/test-array_oset.c: Likewise.
27022         * tests/test-atexit.c: Likewise.
27023         * tests/test-avltree_list.c: Likewise.
27024         * tests/test-avltree_oset.c: Likewise.
27025         * tests/test-avltreehash_list.c: Likewise.
27026         * tests/test-base64.c: Likewise.
27027         * tests/test-binary-io.c: Likewise.
27028         * tests/test-byteswap.c: Likewise.
27029         * tests/test-c-ctype.c: Likewise.
27030         * tests/test-c-strcasecmp.c: Likewise.
27031         * tests/test-c-strcasestr.c: Likewise.
27032         * tests/test-c-strncasecmp.c: Likewise.
27033         * tests/test-c-strstr.c: Likewise.
27034         * tests/test-canonicalize-lgpl.c: Likewise.
27035         * tests/test-canonicalize.c: Likewise.
27036         * tests/test-carray_list.c: Likewise.
27037         * tests/test-ceilf.c: Likewise.
27038         * tests/test-ceill.c: Likewise.
27039         * tests/test-count-one-bits.c: Likewise.
27040         * tests/test-crc.c: Likewise.
27041         * tests/test-dirname.c: Likewise.
27042         * tests/test-fbufmode.c: Likewise.
27043         * tests/test-fcntl.c: Likewise.
27044         * tests/test-fflush.c: Likewise.
27045         * tests/test-floorf.c: Likewise.
27046         * tests/test-floorl.c: Likewise.
27047         * tests/test-fopen.c: Likewise.
27048         * tests/test-fprintf-posix.c: Likewise.
27049         * tests/test-fprintf-posix.h: Likewise.
27050         * tests/test-fpurge.c: Likewise.
27051         * tests/test-freadable.c: Likewise.
27052         * tests/test-freadahead.c: Likewise.
27053         * tests/test-freading.c: Likewise.
27054         * tests/test-freopen.c: Likewise.
27055         * tests/test-frexp.c: Likewise.
27056         * tests/test-frexpl.c: Likewise.
27057         * tests/test-fseek.c: Likewise.
27058         * tests/test-fseeko.c: Likewise.
27059         * tests/test-fseterr.c: Likewise.
27060         * tests/test-fstrcmp.c: Likewise.
27061         * tests/test-ftell.c: Likewise.
27062         * tests/test-ftello.c: Likewise.
27063         * tests/test-fwritable.c: Likewise.
27064         * tests/test-fwriting.c: Likewise.
27065         * tests/test-getaddrinfo.c: Likewise.
27066         * tests/test-getpass.c: Likewise.
27067         * tests/test-gettimeofday.c: Likewise.
27068         * tests/test-hmac-md5.c: Likewise.
27069         * tests/test-hmac-sha1.c: Likewise.
27070         * tests/test-iconv.c: Likewise.
27071         * tests/test-iconvme.c: Likewise.
27072         * tests/test-inttypes.c: Likewise.
27073         * tests/test-isnan.c: Likewise.
27074         * tests/test-isnanf.c: Likewise.
27075         * tests/test-isnanl-nolibm.c: Likewise.
27076         * tests/test-isnanl.c: Likewise.
27077         * tests/test-isnanl.h: Likewise.
27078         * tests/test-ldexpl.c: Likewise.
27079         * tests/test-linked_list.c: Likewise.
27080         * tests/test-linkedhash_list.c: Likewise.
27081         * tests/test-locale.c: Likewise.
27082         * tests/test-localename.c: Likewise.
27083         * tests/test-lock.c: Likewise.
27084         * tests/test-lseek.c: Likewise.
27085         * tests/test-malloca.c: Likewise.
27086         * tests/test-math.c: Likewise.
27087         * tests/test-mbscasecmp.c: Likewise.
27088         * tests/test-mbscasestr1.c: Likewise.
27089         * tests/test-mbscasestr2.c: Likewise.
27090         * tests/test-mbscasestr3.c: Likewise.
27091         * tests/test-mbscasestr4.c: Likewise.
27092         * tests/test-mbschr.c: Likewise.
27093         * tests/test-mbscspn.c: Likewise.
27094         * tests/test-mbsncasecmp.c: Likewise.
27095         * tests/test-mbspbrk.c: Likewise.
27096         * tests/test-mbspcasecmp.c: Likewise.
27097         * tests/test-mbsrchr.c: Likewise.
27098         * tests/test-mbsspn.c: Likewise.
27099         * tests/test-mbsstr1.c: Likewise.
27100         * tests/test-mbsstr2.c: Likewise.
27101         * tests/test-mbsstr3.c: Likewise.
27102         * tests/test-md5.c: Likewise.
27103         * tests/test-memmem.c: Likewise.
27104         * tests/test-netinet_in.c: Likewise.
27105         * tests/test-open.c: Likewise.
27106         * tests/test-printf-frexp.c: Likewise.
27107         * tests/test-printf-frexpl.c: Likewise.
27108         * tests/test-printf-posix.c: Likewise.
27109         * tests/test-printf-posix.h: Likewise.
27110         * tests/test-rbtree_list.c: Likewise.
27111         * tests/test-rbtree_oset.c: Likewise.
27112         * tests/test-rbtreehash_list.c: Likewise.
27113         * tests/test-read-file.c: Likewise.
27114         * tests/test-rijndael.c: Likewise.
27115         * tests/test-search.c: Likewise.
27116         * tests/test-signbit.c: Likewise.
27117         * tests/test-sleep.c: Likewise.
27118         * tests/test-snprintf-posix.c: Likewise.
27119         * tests/test-snprintf-posix.h: Likewise.
27120         * tests/test-snprintf.c: Likewise.
27121         * tests/test-sprintf-posix.c: Likewise.
27122         * tests/test-sprintf-posix.h: Likewise.
27123         * tests/test-stat-time.c: Likewise.
27124         * tests/test-stdbool.c: Likewise.
27125         * tests/test-stdint.c: Likewise.
27126         * tests/test-stdio.c: Likewise.
27127         * tests/test-stdlib.c: Likewise.
27128         * tests/test-stpncpy.c: Likewise.
27129         * tests/test-strcasestr.c: Likewise.
27130         * tests/test-striconv.c: Likewise.
27131         * tests/test-striconveh.c: Likewise.
27132         * tests/test-striconveha.c: Likewise.
27133         * tests/test-string.c: Likewise.
27134         * tests/test-sys_select.c: Likewise.
27135         * tests/test-sys_socket.c: Likewise.
27136         * tests/test-sys_stat.c: Likewise.
27137         * tests/test-sys_time.c: Likewise.
27138         * tests/test-sysexits.c: Likewise.
27139         * tests/test-time.c: Likewise.
27140         * tests/test-tls.c: Likewise.
27141         * tests/test-trunc.c: Likewise.
27142         * tests/test-truncf.c: Likewise.
27143         * tests/test-truncl.c: Likewise.
27144         * tests/test-unistd.c: Likewise.
27145         * tests/test-vasnprintf-posix.c: Likewise.
27146         * tests/test-vasnprintf-posix2.c: Likewise.
27147         * tests/test-vasnprintf.c: Likewise.
27148         * tests/test-vasprintf-posix.c: Likewise.
27149         * tests/test-vasprintf.c: Likewise.
27150         * tests/test-verify.c: Likewise.
27151         * tests/test-vfprintf-posix.c: Likewise.
27152         * tests/test-vprintf-posix.c: Likewise.
27153         * tests/test-vsnprintf-posix.c: Likewise.
27154         * tests/test-vsnprintf.c: Likewise.
27155         * tests/test-vsprintf-posix.c: Likewise.
27156         * tests/test-wchar.c: Likewise.
27157         * tests/test-wctype.c: Likewise.
27158         * tests/test-wcwidth.c: Likewise.
27159         * tests/test-xstrtol.c: Likewise.
27160         * tests/test-xvasprintf.c: Likewise.
27161         * tests/uniconv/test-u16-conv-from-enc.c: Likewise.
27162         * tests/uniconv/test-u16-conv-to-enc.c: Likewise.
27163         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
27164         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
27165         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
27166         * tests/uniconv/test-u32-conv-to-enc.c: Likewise.
27167         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
27168         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
27169         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
27170         * tests/uniconv/test-u8-conv-to-enc.c: Likewise.
27171         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
27172         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
27173         * tests/uniname/test-uninames.c: Likewise.
27174         * tests/unistdio/test-u16-asnprintf1.c: Likewise.
27175         * tests/unistdio/test-u16-asnprintf1.h: Likewise.
27176         * tests/unistdio/test-u16-printf1.h: Likewise.
27177         * tests/unistdio/test-u16-vasnprintf1.c: Likewise.
27178         * tests/unistdio/test-u16-vasnprintf2.c: Likewise.
27179         * tests/unistdio/test-u16-vasnprintf3.c: Likewise.
27180         * tests/unistdio/test-u16-vasprintf1.c: Likewise.
27181         * tests/unistdio/test-u16-vsnprintf1.c: Likewise.
27182         * tests/unistdio/test-u16-vsprintf1.c: Likewise.
27183         * tests/unistdio/test-u32-asnprintf1.c: Likewise.
27184         * tests/unistdio/test-u32-asnprintf1.h: Likewise.
27185         * tests/unistdio/test-u32-printf1.h: Likewise.
27186         * tests/unistdio/test-u32-vasnprintf1.c: Likewise.
27187         * tests/unistdio/test-u32-vasnprintf2.c: Likewise.
27188         * tests/unistdio/test-u32-vasnprintf3.c: Likewise.
27189         * tests/unistdio/test-u32-vasprintf1.c: Likewise.
27190         * tests/unistdio/test-u32-vsnprintf1.c: Likewise.
27191         * tests/unistdio/test-u32-vsprintf1.c: Likewise.
27192         * tests/unistdio/test-u8-asnprintf1.c: Likewise.
27193         * tests/unistdio/test-u8-asnprintf1.h: Likewise.
27194         * tests/unistdio/test-u8-printf1.h: Likewise.
27195         * tests/unistdio/test-u8-vasnprintf1.c: Likewise.
27196         * tests/unistdio/test-u8-vasnprintf2.c: Likewise.
27197         * tests/unistdio/test-u8-vasnprintf3.c: Likewise.
27198         * tests/unistdio/test-u8-vasprintf1.c: Likewise.
27199         * tests/unistdio/test-u8-vsnprintf1.c: Likewise.
27200         * tests/unistdio/test-u8-vsprintf1.c: Likewise.
27201         * tests/unistdio/test-ulc-asnprintf1.c: Likewise.
27202         * tests/unistdio/test-ulc-asnprintf1.h: Likewise.
27203         * tests/unistdio/test-ulc-printf1.h: Likewise.
27204         * tests/unistdio/test-ulc-vasnprintf1.c: Likewise.
27205         * tests/unistdio/test-ulc-vasnprintf2.c: Likewise.
27206         * tests/unistdio/test-ulc-vasnprintf3.c: Likewise.
27207         * tests/unistdio/test-ulc-vasprintf1.c: Likewise.
27208         * tests/unistdio/test-ulc-vsnprintf1.c: Likewise.
27209         * tests/unistdio/test-ulc-vsprintf1.c: Likewise.
27210         * tests/uniwidth/test-u16-strwidth.c: Likewise.
27211         * tests/uniwidth/test-u16-width.c: Likewise.
27212         * tests/uniwidth/test-u32-strwidth.c: Likewise.
27213         * tests/uniwidth/test-u32-width.c: Likewise.
27214         * tests/uniwidth/test-u8-strwidth.c: Likewise.
27215         * tests/uniwidth/test-u8-width.c: Likewise.
27216         * tests/uniwidth/test-uc_width.c: Likewise.
27217         * config/srclist-update: Likewise.
27218         (fixlicense): Update to GPLv3+.
27219
27220         Change copyright notice from LGPLv2.1+ to LGPLv3+.
27221         * tests/test-tsearch.c: Change copyright notice.
27222
27223         Change copyright notice from LGPLv2.0+ to LGPLv3+.
27224         * lib/c-strcaseeq.h: Change copyright notice.
27225         * lib/streq.h: Likewise.
27226         * lib/uniconv.h: Likewise.
27227         * lib/uniconv/u-conv-from-enc.h: Likewise.
27228         * lib/uniconv/u-conv-to-enc.h: Likewise.
27229         * lib/uniconv/u-strconv-from-enc.h: Likewise.
27230         * lib/uniconv/u-strconv-to-enc.h: Likewise.
27231         * lib/uniconv/u16-conv-from-enc.c: Likewise.
27232         * lib/uniconv/u16-conv-to-enc.c: Likewise.
27233         * lib/uniconv/u16-strconv-from-enc.c: Likewise.
27234         * lib/uniconv/u16-strconv-from-locale.c: Likewise.
27235         * lib/uniconv/u16-strconv-to-enc.c: Likewise.
27236         * lib/uniconv/u16-strconv-to-locale.c: Likewise.
27237         * lib/uniconv/u32-conv-from-enc.c: Likewise.
27238         * lib/uniconv/u32-conv-to-enc.c: Likewise.
27239         * lib/uniconv/u32-strconv-from-enc.c: Likewise.
27240         * lib/uniconv/u32-strconv-from-locale.c: Likewise.
27241         * lib/uniconv/u32-strconv-to-enc.c: Likewise.
27242         * lib/uniconv/u32-strconv-to-locale.c: Likewise.
27243         * lib/uniconv/u8-conv-from-enc.c: Likewise.
27244         * lib/uniconv/u8-conv-to-enc.c: Likewise.
27245         * lib/uniconv/u8-strconv-from-enc.c: Likewise.
27246         * lib/uniconv/u8-strconv-from-locale.c: Likewise.
27247         * lib/uniconv/u8-strconv-to-enc.c: Likewise.
27248         * lib/uniconv/u8-strconv-to-locale.c: Likewise.
27249         * lib/uniname.h: Likewise.
27250         * lib/uniname/uniname.c: Likewise.
27251         * lib/unistdio.h: Likewise.
27252         * lib/unistdio/u-asnprintf.h: Likewise.
27253         * lib/unistdio/u-asprintf.h: Likewise.
27254         * lib/unistdio/u-printf-args.c: Likewise.
27255         * lib/unistdio/u-printf-args.h: Likewise.
27256         * lib/unistdio/u-printf-parse.h: Likewise.
27257         * lib/unistdio/u-snprintf.h: Likewise.
27258         * lib/unistdio/u-sprintf.h: Likewise.
27259         * lib/unistdio/u-vasprintf.h: Likewise.
27260         * lib/unistdio/u-vsnprintf.h: Likewise.
27261         * lib/unistdio/u-vsprintf.h: Likewise.
27262         * lib/unistdio/u16-asnprintf.c: Likewise.
27263         * lib/unistdio/u16-asprintf.c: Likewise.
27264         * lib/unistdio/u16-printf-parse.c: Likewise.
27265         * lib/unistdio/u16-snprintf.c: Likewise.
27266         * lib/unistdio/u16-sprintf.c: Likewise.
27267         * lib/unistdio/u16-u16-asnprintf.c: Likewise.
27268         * lib/unistdio/u16-u16-asprintf.c: Likewise.
27269         * lib/unistdio/u16-u16-snprintf.c: Likewise.
27270         * lib/unistdio/u16-u16-sprintf.c: Likewise.
27271         * lib/unistdio/u16-u16-vasnprintf.c: Likewise.
27272         * lib/unistdio/u16-u16-vasprintf.c: Likewise.
27273         * lib/unistdio/u16-u16-vsnprintf.c: Likewise.
27274         * lib/unistdio/u16-u16-vsprintf.c: Likewise.
27275         * lib/unistdio/u16-vasnprintf.c: Likewise.
27276         * lib/unistdio/u16-vasprintf.c: Likewise.
27277         * lib/unistdio/u16-vsnprintf.c: Likewise.
27278         * lib/unistdio/u16-vsprintf.c: Likewise.
27279         * lib/unistdio/u32-asnprintf.c: Likewise.
27280         * lib/unistdio/u32-asprintf.c: Likewise.
27281         * lib/unistdio/u32-printf-parse.c: Likewise.
27282         * lib/unistdio/u32-snprintf.c: Likewise.
27283         * lib/unistdio/u32-sprintf.c: Likewise.
27284         * lib/unistdio/u32-u32-asnprintf.c: Likewise.
27285         * lib/unistdio/u32-u32-asprintf.c: Likewise.
27286         * lib/unistdio/u32-u32-snprintf.c: Likewise.
27287         * lib/unistdio/u32-u32-sprintf.c: Likewise.
27288         * lib/unistdio/u32-u32-vasnprintf.c: Likewise.
27289         * lib/unistdio/u32-u32-vasprintf.c: Likewise.
27290         * lib/unistdio/u32-u32-vsnprintf.c: Likewise.
27291         * lib/unistdio/u32-u32-vsprintf.c: Likewise.
27292         * lib/unistdio/u32-vasnprintf.c: Likewise.
27293         * lib/unistdio/u32-vasprintf.c: Likewise.
27294         * lib/unistdio/u32-vsnprintf.c: Likewise.
27295         * lib/unistdio/u32-vsprintf.c: Likewise.
27296         * lib/unistdio/u8-asnprintf.c: Likewise.
27297         * lib/unistdio/u8-asprintf.c: Likewise.
27298         * lib/unistdio/u8-printf-parse.c: Likewise.
27299         * lib/unistdio/u8-snprintf.c: Likewise.
27300         * lib/unistdio/u8-sprintf.c: Likewise.
27301         * lib/unistdio/u8-u8-asnprintf.c: Likewise.
27302         * lib/unistdio/u8-u8-asprintf.c: Likewise.
27303         * lib/unistdio/u8-u8-snprintf.c: Likewise.
27304         * lib/unistdio/u8-u8-sprintf.c: Likewise.
27305         * lib/unistdio/u8-u8-vasnprintf.c: Likewise.
27306         * lib/unistdio/u8-u8-vasprintf.c: Likewise.
27307         * lib/unistdio/u8-u8-vsnprintf.c: Likewise.
27308         * lib/unistdio/u8-u8-vsprintf.c: Likewise.
27309         * lib/unistdio/u8-vasnprintf.c: Likewise.
27310         * lib/unistdio/u8-vasprintf.c: Likewise.
27311         * lib/unistdio/u8-vsnprintf.c: Likewise.
27312         * lib/unistdio/u8-vsprintf.c: Likewise.
27313         * lib/unistdio/ulc-asnprintf.c: Likewise.
27314         * lib/unistdio/ulc-asprintf.c: Likewise.
27315         * lib/unistdio/ulc-printf-parse.c: Likewise.
27316         * lib/unistdio/ulc-snprintf.c: Likewise.
27317         * lib/unistdio/ulc-sprintf.c: Likewise.
27318         * lib/unistdio/ulc-vasnprintf.c: Likewise.
27319         * lib/unistdio/ulc-vasprintf.c: Likewise.
27320         * lib/unistdio/ulc-vsnprintf.c: Likewise.
27321         * lib/unistdio/ulc-vsprintf.c: Likewise.
27322         * lib/unistr.h: Likewise.
27323         * lib/unistr/u-cpy-alloc.h: Likewise.
27324         * lib/unistr/u-cpy.h: Likewise.
27325         * lib/unistr/u-endswith.h: Likewise.
27326         * lib/unistr/u-move.h: Likewise.
27327         * lib/unistr/u-set.h: Likewise.
27328         * lib/unistr/u-startswith.h: Likewise.
27329         * lib/unistr/u-stpcpy.h: Likewise.
27330         * lib/unistr/u-stpncpy.h: Likewise.
27331         * lib/unistr/u-strcat.h: Likewise.
27332         * lib/unistr/u-strcpy.h: Likewise.
27333         * lib/unistr/u-strcspn.h: Likewise.
27334         * lib/unistr/u-strdup.h: Likewise.
27335         * lib/unistr/u-strlen.h: Likewise.
27336         * lib/unistr/u-strncat.h: Likewise.
27337         * lib/unistr/u-strncpy.h: Likewise.
27338         * lib/unistr/u-strnlen.h: Likewise.
27339         * lib/unistr/u-strpbrk.h: Likewise.
27340         * lib/unistr/u-strspn.h: Likewise.
27341         * lib/unistr/u-strstr.h: Likewise.
27342         * lib/unistr/u-strtok.h: Likewise.
27343         * lib/unistr/u16-check.c: Likewise.
27344         * lib/unistr/u16-chr.c: Likewise.
27345         * lib/unistr/u16-cmp.c: Likewise.
27346         * lib/unistr/u16-cpy-alloc.c: Likewise.
27347         * lib/unistr/u16-cpy.c: Likewise.
27348         * lib/unistr/u16-endswith.c: Likewise.
27349         * lib/unistr/u16-mblen.c: Likewise.
27350         * lib/unistr/u16-mbsnlen.c: Likewise.
27351         * lib/unistr/u16-mbtouc-aux.c: Likewise.
27352         * lib/unistr/u16-mbtouc-unsafe-aux.c: Likewise.
27353         * lib/unistr/u16-mbtouc-unsafe.c: Likewise.
27354         * lib/unistr/u16-mbtouc.c: Likewise.
27355         * lib/unistr/u16-mbtoucr.c: Likewise.
27356         * lib/unistr/u16-move.c: Likewise.
27357         * lib/unistr/u16-next.c: Likewise.
27358         * lib/unistr/u16-prev.c: Likewise.
27359         * lib/unistr/u16-set.c: Likewise.
27360         * lib/unistr/u16-startswith.c: Likewise.
27361         * lib/unistr/u16-stpcpy.c: Likewise.
27362         * lib/unistr/u16-stpncpy.c: Likewise.
27363         * lib/unistr/u16-strcat.c: Likewise.
27364         * lib/unistr/u16-strchr.c: Likewise.
27365         * lib/unistr/u16-strcmp.c: Likewise.
27366         * lib/unistr/u16-strcpy.c: Likewise.
27367         * lib/unistr/u16-strcspn.c: Likewise.
27368         * lib/unistr/u16-strdup.c: Likewise.
27369         * lib/unistr/u16-strlen.c: Likewise.
27370         * lib/unistr/u16-strmblen.c: Likewise.
27371         * lib/unistr/u16-strmbtouc.c: Likewise.
27372         * lib/unistr/u16-strncat.c: Likewise.
27373         * lib/unistr/u16-strncmp.c: Likewise.
27374         * lib/unistr/u16-strncpy.c: Likewise.
27375         * lib/unistr/u16-strnlen.c: Likewise.
27376         * lib/unistr/u16-strpbrk.c: Likewise.
27377         * lib/unistr/u16-strrchr.c: Likewise.
27378         * lib/unistr/u16-strspn.c: Likewise.
27379         * lib/unistr/u16-strstr.c: Likewise.
27380         * lib/unistr/u16-strtok.c: Likewise.
27381         * lib/unistr/u16-to-u32.c: Likewise.
27382         * lib/unistr/u16-to-u8.c: Likewise.
27383         * lib/unistr/u16-uctomb-aux.c: Likewise.
27384         * lib/unistr/u16-uctomb.c: Likewise.
27385         * lib/unistr/u32-check.c: Likewise.
27386         * lib/unistr/u32-chr.c: Likewise.
27387         * lib/unistr/u32-cmp.c: Likewise.
27388         * lib/unistr/u32-cpy-alloc.c: Likewise.
27389         * lib/unistr/u32-cpy.c: Likewise.
27390         * lib/unistr/u32-endswith.c: Likewise.
27391         * lib/unistr/u32-mblen.c: Likewise.
27392         * lib/unistr/u32-mbsnlen.c: Likewise.
27393         * lib/unistr/u32-mbtouc-unsafe.c: Likewise.
27394         * lib/unistr/u32-mbtouc.c: Likewise.
27395         * lib/unistr/u32-mbtoucr.c: Likewise.
27396         * lib/unistr/u32-move.c: Likewise.
27397         * lib/unistr/u32-next.c: Likewise.
27398         * lib/unistr/u32-prev.c: Likewise.
27399         * lib/unistr/u32-set.c: Likewise.
27400         * lib/unistr/u32-startswith.c: Likewise.
27401         * lib/unistr/u32-stpcpy.c: Likewise.
27402         * lib/unistr/u32-stpncpy.c: Likewise.
27403         * lib/unistr/u32-strcat.c: Likewise.
27404         * lib/unistr/u32-strchr.c: Likewise.
27405         * lib/unistr/u32-strcmp.c: Likewise.
27406         * lib/unistr/u32-strcpy.c: Likewise.
27407         * lib/unistr/u32-strcspn.c: Likewise.
27408         * lib/unistr/u32-strdup.c: Likewise.
27409         * lib/unistr/u32-strlen.c: Likewise.
27410         * lib/unistr/u32-strmblen.c: Likewise.
27411         * lib/unistr/u32-strmbtouc.c: Likewise.
27412         * lib/unistr/u32-strncat.c: Likewise.
27413         * lib/unistr/u32-strncmp.c: Likewise.
27414         * lib/unistr/u32-strncpy.c: Likewise.
27415         * lib/unistr/u32-strnlen.c: Likewise.
27416         * lib/unistr/u32-strpbrk.c: Likewise.
27417         * lib/unistr/u32-strrchr.c: Likewise.
27418         * lib/unistr/u32-strspn.c: Likewise.
27419         * lib/unistr/u32-strstr.c: Likewise.
27420         * lib/unistr/u32-strtok.c: Likewise.
27421         * lib/unistr/u32-to-u16.c: Likewise.
27422         * lib/unistr/u32-to-u8.c: Likewise.
27423         * lib/unistr/u32-uctomb.c: Likewise.
27424         * lib/unistr/u8-check.c: Likewise.
27425         * lib/unistr/u8-chr.c: Likewise.
27426         * lib/unistr/u8-cmp.c: Likewise.
27427         * lib/unistr/u8-cpy-alloc.c: Likewise.
27428         * lib/unistr/u8-cpy.c: Likewise.
27429         * lib/unistr/u8-endswith.c: Likewise.
27430         * lib/unistr/u8-mblen.c: Likewise.
27431         * lib/unistr/u8-mbsnlen.c: Likewise.
27432         * lib/unistr/u8-mbtouc-aux.c: Likewise.
27433         * lib/unistr/u8-mbtouc-unsafe-aux.c: Likewise.
27434         * lib/unistr/u8-mbtouc-unsafe.c: Likewise.
27435         * lib/unistr/u8-mbtouc.c: Likewise.
27436         * lib/unistr/u8-mbtoucr.c: Likewise.
27437         * lib/unistr/u8-move.c: Likewise.
27438         * lib/unistr/u8-next.c: Likewise.
27439         * lib/unistr/u8-prev.c: Likewise.
27440         * lib/unistr/u8-set.c: Likewise.
27441         * lib/unistr/u8-startswith.c: Likewise.
27442         * lib/unistr/u8-stpcpy.c: Likewise.
27443         * lib/unistr/u8-stpncpy.c: Likewise.
27444         * lib/unistr/u8-strcat.c: Likewise.
27445         * lib/unistr/u8-strchr.c: Likewise.
27446         * lib/unistr/u8-strcmp.c: Likewise.
27447         * lib/unistr/u8-strcpy.c: Likewise.
27448         * lib/unistr/u8-strcspn.c: Likewise.
27449         * lib/unistr/u8-strdup.c: Likewise.
27450         * lib/unistr/u8-strlen.c: Likewise.
27451         * lib/unistr/u8-strmblen.c: Likewise.
27452         * lib/unistr/u8-strmbtouc.c: Likewise.
27453         * lib/unistr/u8-strncat.c: Likewise.
27454         * lib/unistr/u8-strncmp.c: Likewise.
27455         * lib/unistr/u8-strncpy.c: Likewise.
27456         * lib/unistr/u8-strnlen.c: Likewise.
27457         * lib/unistr/u8-strpbrk.c: Likewise.
27458         * lib/unistr/u8-strrchr.c: Likewise.
27459         * lib/unistr/u8-strspn.c: Likewise.
27460         * lib/unistr/u8-strstr.c: Likewise.
27461         * lib/unistr/u8-strtok.c: Likewise.
27462         * lib/unistr/u8-to-u16.c: Likewise.
27463         * lib/unistr/u8-to-u32.c: Likewise.
27464         * lib/unistr/u8-uctomb-aux.c: Likewise.
27465         * lib/unistr/u8-uctomb.c: Likewise.
27466         * lib/unitypes.h: Likewise.
27467         * lib/uniwidth.h: Likewise.
27468         * lib/uniwidth/cjk.h: Likewise.
27469         * lib/uniwidth/u16-strwidth.c: Likewise.
27470         * lib/uniwidth/u16-width.c: Likewise.
27471         * lib/uniwidth/u32-strwidth.c: Likewise.
27472         * lib/uniwidth/u32-width.c: Likewise.
27473         * lib/uniwidth/u8-strwidth.c: Likewise.
27474         * lib/uniwidth/u8-width.c: Likewise.
27475         * lib/uniwidth/width.c: Likewise.
27476
27477 2007-10-07  Bruno Haible  <bruno@clisp.org>
27478
27479         * lib/inttypes.in.h: Change copyright notice from LGPL to GPL.
27480         The file is still under LGPL (see modules/inttypes).
27481
27482 2007-10-06  Bruno Haible  <bruno@clisp.org>
27483
27484         * modules/trunc (Dependencies): Add 'extensions'.
27485         * m4/trunc.m4 (gl_FUNC_TRUNC): Require gl_USE_SYSTEM_EXTENSIONS.
27486         Reported by Ben Pfaff <blp@gnu.org>.
27487
27488 2007-10-06  Bruno Haible  <bruno@clisp.org>
27489
27490         * modules/freopen-tests: New file.
27491         * tests/test-freopen.c: New file.
27492
27493         * modules/fopen-tests: New file.
27494         * tests/test-fopen.c: New file.
27495
27496         * modules/fopen: New file.
27497         * lib/fopen.c: New file.
27498         * m4/fopen.m4: New file.
27499         * modules/freopen: New file.
27500         * lib/freopen.c: New file.
27501         * m4/freopen.m4: New file.
27502         * lib/stdio.in.h (fopen, freopen): New declarations.
27503         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize also GNULIB_FOPEN,
27504         GNULIB_FREOPEN, REPLACE_FOPEN, REPLACE_FREOPEN.
27505         * modules/stdio (Makefile.am): Substitute also GNULIB_FOPEN,
27506         GNULIB_FREOPEN, REPLACE_FOPEN, REPLACE_FREOPEN.
27507         * doc/functions/fopen.texi: Mention the 'fopen' module.
27508         * doc/functions/freopen.texi: Mention the 'freopen' module.
27509
27510 2007-10-06  Bruno Haible  <bruno@clisp.org>
27511
27512         * modules/open-tests: New file.
27513         * tests/test-open.c: New file.
27514
27515         * modules/open: New file.
27516         * lib/open.c: New file.
27517         * m4/open.m4: New file.
27518         * lib/fchdir.c (open): If the gnulib module 'open' is used, do what
27519         lib/open.c does.
27520         * lib/fcntl.in.h (open): Declare also if replaced by the 'open' module.
27521         * m4/fcntl_h.m4 (gl_FCNTL_MODULE_INDICATOR, gl_FCNTL_H_DEFAULTS): New
27522         macros.
27523         (gl_FCNTL_H): Require gl_FCNTL_H_DEFAULTS.
27524         * modules/fcntl (Makefile.am): Also substitute GNULIB_OPEN and
27525         REPLACE_OPEN.
27526         * doc/functions/open.texi: Mention the 'open' module.
27527
27528 2007-10-04  Bruno Haible  <bruno@clisp.org>
27529
27530         * modules/ceill-tests: New file.
27531         * tests/test-ceill.c: New file.
27532
27533         * modules/ceill: New file.
27534         * lib/ceill.c: Replace entire file.
27535         * m4/ceill.m4: New file.
27536         * lib/math.in.h (ceill): Replace declaration.
27537         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_CEILL.
27538         * modules/math (Makefile.am): Substitute also GNULIB_CEILL.
27539         * doc/functions/ceill.texi: Mention the 'ceill' module.
27540         * modules/mathl (Files): Remove lib/ceill.c.
27541         (Depends-on): Add ceill.
27542
27543 2007-10-04  Bruno Haible  <bruno@clisp.org>
27544
27545         * modules/ceilf-tests: New file.
27546         * tests/test-ceilf.c: New file.
27547
27548         * modules/ceilf: New file.
27549         * lib/ceil.c: New file.
27550         * lib/ceilf.c: New file.
27551         * m4/ceilf.m4: New file.
27552         * lib/math.in.h (ceilf): New declaration.
27553         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_CEILF and
27554         HAVE_DECL_CEILF.
27555         * modules/math (Makefile.am): Substitute also GNULIB_CEILF and
27556         HAVE_DECL_CEILF.
27557         * doc/functions/ceilf.texi: Mention the 'ceilf' module.
27558
27559 2007-10-04  Bruno Haible  <bruno@clisp.org>
27560
27561         * modules/floorl-tests: New file.
27562         * tests/test-floorl.c: New file.
27563
27564         * modules/floorl: New file.
27565         * lib/floorl.c: Replace entire file.
27566         * m4/floorl.m4: New file.
27567         * lib/math.in.h (floorl): Replace declaration.
27568         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FLOORL.
27569         * modules/math (Makefile.am): Substitute also GNULIB_FLOORL.
27570         * doc/functions/floorl.texi: Mention the 'floorl' module.
27571         * modules/mathl (Files): Remove lib/floorl.c.
27572         (Depends-on): Add floorl.
27573
27574 2007-10-04  Bruno Haible  <bruno@clisp.org>
27575
27576         * modules/floorf-tests: New file.
27577         * tests/test-floorf.c: New file.
27578
27579         * modules/floorf: New file.
27580         * lib/floor.c: New file.
27581         * lib/floorf.c: New file.
27582         * m4/floorf.m4: New file.
27583         * lib/math.in.h (floorf): New declaration.
27584         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FLOORF and
27585         HAVE_DECL_FLOORF.
27586         * modules/math (Makefile.am): Substitute also GNULIB_FLOORF and
27587         HAVE_DECL_FLOORF.
27588         * doc/functions/floorf.texi: Mention the 'floorf' module.
27589
27590 2007-10-04  Benoit Sigoure  <tsuna@lrde.epita.fr>
27591             Bruno Haible  <bruno@clisp.org>
27592
27593         Advertise for the Git server instead of the CVS server.
27594         * doc/gnulib-intro.texi (Steady Development): Mention the Git
27595         repository instead of the CVS one.
27596         * doc/gnulib-tool.texi (VCS Issues): Renamed from "CVS Issues". Talk
27597         about all VCS systems generically.
27598         * doc/gnulib.texi (Introduction): Capitalize `Git'.
27599
27600 2007-10-04  Bruno Haible  <bruno@clisp.org>
27601
27602         * doc/gnulib.texi (Function Substitutes): Explain what an absent module
27603         means.
27604         Reported by Benoît Sigoure <tsuna@lrde.epita.fr>.
27605
27606 2007-10-04  Bruno Haible  <bruno@clisp.org>
27607
27608         * modules/truncl-tests: New file.
27609         * tests/test-truncl.c: New file.
27610
27611         * modules/truncl: New file.
27612         * lib/truncl.c: New file.
27613         * m4/truncl.m4: New file.
27614         * lib/math.in.h (truncl): New declaration.
27615         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_TRUNCL and
27616         HAVE_DECL_TRUNCL.
27617         * modules/math (Makefile.am): Substitute also GNULIB_TRUNCL and
27618         HAVE_DECL_TRUNCL.
27619         * doc/functions/truncl.texi: Mention the 'truncl' module.
27620
27621 2007-10-04  Bruno Haible  <bruno@clisp.org>
27622
27623         * modules/truncf-tests: New file.
27624         * tests/test-truncf.c: New file.
27625
27626         * modules/truncf: New file.
27627         * lib/trunc.c: Make paramerizable through USE_* macros.
27628         * lib/truncf.c: New file.
27629         * m4/truncf.m4: New file.
27630         * lib/math.in.h (truncf): New declaration.
27631         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_TRUNCF and
27632         HAVE_DECL_TRUNCF.
27633         * modules/math (Makefile.am): Substitute also GNULIB_TRUNCF and
27634         HAVE_DECL_TRUNCF.
27635         * doc/functions/truncf.texi: Mention the 'truncf' module.
27636
27637 2007-10-03  Bruno Haible  <bruno@clisp.org>
27638
27639         * gnulib-tool (func_get_automake_snippet): Synthesize an EXTRA_DIST
27640         augmentation also for tests modules.
27641         * modules/argp-tests (Makefile.am): Remove EXTRA_DIST augmentation.
27642         * modules/atexit-tests (Makefile.am): Likewise.
27643         * modules/binary-io-tests (Makefile.am): Likewise.
27644         * modules/c-strcase-tests (Makefile.am): Likewise.
27645         * modules/canonicalize-lgpl-tests (Makefile.am): Likewise.
27646         * modules/canonicalize-tests (Makefile.am): Likewise.
27647         * modules/closein-tests (Makefile.am): Likewise.
27648         * modules/fprintf-posix-tests (Makefile.am): Likewise.
27649         * modules/freadahead-tests (Makefile.am): Likewise.
27650         * modules/fseek-tests (Makefile.am): Likewise.
27651         * modules/fseeko-tests (Makefile.am): Likewise.
27652         * modules/ftell-tests (Makefile.am): Likewise.
27653         * modules/ftello-tests (Makefile.am): Likewise.
27654         * modules/isnanl-nolibm-tests (Makefile.am): Likewise.
27655         * modules/isnanl-tests (Makefile.am): Likewise.
27656         * modules/lseek-tests (Makefile.am): Likewise.
27657         * modules/mbscasecmp-tests (Makefile.am): Likewise.
27658         * modules/mbscasestr-tests (Makefile.am): Likewise.
27659         * modules/mbschr-tests (Makefile.am): Likewise.
27660         * modules/mbscspn-tests (Makefile.am): Likewise.
27661         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
27662         * modules/mbspbrk-tests (Makefile.am): Likewise.
27663         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
27664         * modules/mbsrchr-tests (Makefile.am): Likewise.
27665         * modules/mbsspn-tests (Makefile.am): Likewise.
27666         * modules/mbsstr-tests (Makefile.am): Likewise.
27667         * modules/printf-posix-tests (Makefile.am): Likewise.
27668         * modules/snprintf-posix-tests (Makefile.am): Likewise.
27669         * modules/sprintf-posix-tests (Makefile.am): Likewise.
27670         * modules/tsearch-tests (Makefile.am): Likewise.
27671         * modules/uniname/uniname-tests (Makefile.am): Likewise.
27672         * modules/unistdio/u16-vasnprintf-tests (Makefile.am): Likewise.
27673         * modules/unistdio/u32-vasnprintf-tests (Makefile.am): Likewise.
27674         * modules/unistdio/u8-vasnprintf-tests (Makefile.am): Likewise.
27675         * modules/unistdio/ulc-vasnprintf-tests (Makefile.am): Likewise.
27676         * modules/vasnprintf-posix-tests (Makefile.am): Likewise.
27677         * modules/vfprintf-posix-tests (Makefile.am): Likewise.
27678         * modules/vprintf-posix-tests (Makefile.am): Likewise.
27679         * modules/vsnprintf-posix-tests (Makefile.am): Likewise.
27680         * modules/vsprintf-posix-tests (Makefile.am): Likewise.
27681         * modules/xstrtoimax-tests (Makefile.am): Likewise.
27682         * modules/xstrtol-tests (Makefile.am): Likewise.
27683         * modules/xstrtoumax-tests (Makefile.am): Likewise.
27684         * modules/yesno-tests (Makefile.am): Likewise.
27685
27686 2007-10-03  Bruno Haible  <bruno@clisp.org>
27687
27688         * modules/trunc-tests: New file.
27689         * tests/test-trunc.c: New file.
27690
27691         * modules/trunc: New file.
27692         * lib/trunc.c: New file.
27693         * m4/trunc.m4: New file.
27694         * lib/math.in.h (trunc): New declaration.
27695         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_TRUNC and
27696         HAVE_DECL_TRUNC.
27697         * modules/math (Makefile.am): Substitute also GNULIB_TRUNC and
27698         HAVE_DECL_TRUNC.
27699         * doc/functions/trunc.texi: Mention the 'trunc' module.
27700
27701 2007-10-03  Bruno Haible  <bruno@clisp.org>
27702
27703         * tests/test-fpending.c: New file, mostly copied
27704         from coreutils/lib/t-fpending.c.
27705         * modules/fpending-tests: New file.
27706
27707 2007-10-03  Bruno Haible  <bruno@clisp.org>
27708
27709         Port the stdio extensions to QNX (untested).
27710         * lib/fseterr.c (fseterr): Add support for QNX.
27711         * lib/fbufmode.c (fbufmode): Likewise.
27712         * lib/freadable.c (freadable): Likewise.
27713         * lib/fwritable.c (fwritable): Likewise.
27714         * lib/freading.c (freading): Likewise.
27715         * lib/fwriting.c (fwriting): Likewise.
27716         * lib/freadahead.c (freadahed): Likewise.
27717         * lib/fpurge.c (fpurge): Likewise.
27718         * lib/fseeko.c (rpl_fseeko): Likewise.
27719
27720 2007-10-03  Bruno Haible  <bruno@clisp.org>
27721             Jim Meyering  <jim@meyering.net>
27722             Eric Blake  <ebb9@byu.net>
27723
27724         * doc/relocatable.texi: Use @command instead of @program.
27725
27726 2007-10-02  Jim Meyering  <jim@meyering.net>
27727
27728         Perform one more "_.h" -> ".in.h" substitution.
27729         * modules/unistd (Makefile.am) [unistd.h]: Use unistd.h.in
27730         instead of unistd_.h here, too.
27731
27732 2007-10-01  Bruno Haible  <bruno@clisp.org>
27733
27734         * gnulib-tool (func_emit_initmacro_done): Special case for alloca.c.
27735         Needed for the alloca-opt module.
27736
27737 2007-09-30  Bruno Haible  <bruno@clisp.org>
27738
27739         * lib/alloca.in.h: Renamed from lib/alloca_.h.
27740         * modules/alloca-opt (Files, Makefile.am): Use alloca.in.h instead of
27741         alloca_.h.
27742         * lib/argz.in.h: Renamed from lib/argz_.h.
27743         * modules/argz (Files, Makefile.am): Use argz.in.h instead of argz_.h.
27744         * lib/byteswap.in.h: Renamed from lib/byteswap_.h.
27745         * modules/byteswap (Files, Makefile.am): Use byteswap.in.h instead of
27746         byteswap_.h.
27747         * lib/dirent.in.h: Renamed from lib/dirent_.h.
27748         * modules/fchdir (Files, Makefile.am): Use dirent.in.h instead of
27749         dirent_.h.
27750         * lib/fcntl.in.h: Renamed from lib/fcntl_.h.
27751         * modules/fcntl (Files, Makefile.am): Use fcntl.in.h instead of
27752         fcntl_.h.
27753         * lib/float.in.h: Renamed from lib/float_.h.
27754         * modules/float (Files, Makefile.am): Use float.in.h instead of
27755         float_.h.
27756         * lib/fnmatch.in.h: Renamed from lib/fnmatch_.h.
27757         * modules/fnmatch (Files, Makefile.am): Use fnmatch.in.h instead of
27758         fnmatch_.h.
27759         * lib/getopt.in.h: Renamed from lib/getopt_.h.
27760         * modules/getopt (Files, Makefile.am): Use getopt.in.h instead of
27761         getopt_.h.
27762         * lib/glob.in.h: Renamed from lib/glob_.h.
27763         * modules/glob (Files, Makefile.am): Use glob.in.h instead of glob_.h.
27764         * lib/iconv.in.h: Renamed from lib/iconv_.h.
27765         * modules/iconv_open (Files, Makefile.am): Use iconv.in.h instead of
27766         iconv_.h.
27767         * lib/inttypes.in.h: Renamed from lib/inttypes_.h.
27768         * modules/inttypes (Files, Makefile.am): Use inttypes.in.h instead of
27769         inttypes_.h.
27770         * lib/locale.in.h: Renamed from lib/locale_.h.
27771         * modules/locale (Files, Makefile.am): Use locale.in.h instead of
27772         locale_.h.
27773         * lib/math.in.h: Renamed from lib/math_.h.
27774         * modules/math (Files, Makefile.am): Use math.in.h instead of math_.h.
27775         * lib/netinet_in.in.h: Renamed from lib/netinet_in_.h.
27776         * modules/netinet_in (Files, Makefile.am): Use netinet_in.in.h instead
27777         of netinet_in_.h. Add dependency.
27778         * lib/poll.in.h: Renamed from lib/poll_.h.
27779         * modules/poll (Files, Makefile.am): Use poll.in.h instead of poll_.h.
27780         * lib/search.in.h: Renamed from lib/search_.h.
27781         * modules/search (Files, Makefile.am): Use search.in.h instead of
27782         search_.h.
27783         * lib/signal.in.h: Renamed from lib/signal_.h.
27784         * modules/signal (Files, Makefile.am): Use signal.in.h instead of
27785         _signal.h.
27786         * lib/stdbool.in.h: Renamed from lib/stdbool_.h.
27787         * modules/stdbool (Files, Makefile.am): Use stdbool.in.h instead of
27788         stdbool_.h.
27789         * lib/stdint.in.h: Renamed from lib/stdint_.h.
27790         * modules/stdint (Files, Makefile.am): Use stdint.in.h instead of
27791         stdint_.h.
27792         * lib/stdio.in.h: Renamed from lib/stdio_.h.
27793         * modules/stdio (Files, Makefile.am): Use stdio.in.h instead of
27794         stdio_.h.
27795         * lib/stdlib.in.h: Renamed from lib/stdlib_.h.
27796         * modules/stdlib (Files, Makefile.am): Use stdlib.in.h instead of
27797         stdlib_.h.
27798         * lib/string.in.h: Renamed from lib/string_.h.
27799         * modules/string (Files, Makefile.am): Use string.in.h instead of
27800         string_.h.
27801         * doc/gnulib-tool.texi (Initial import): Update.
27802         * lib/sys_select.in.h: Renamed from lib/sys_select_.h.
27803         * modules/sys_select (Files, Makefile.am): Use sys_select.in.h instead
27804         of sys_select_.h. Add dependency.
27805         * lib/sys_socket.in.h: Renamed from lib/sys_socket_.h.
27806         * modules/sys_socket (Files, Makefile.am): Use sys_socket.in.h instead
27807         of sys_socket_.h.
27808         * lib/sys_stat.in.h: Renamed from lib/sys_stat_.h.
27809         * modules/sys_stat (Files, Makefile.am): Use sys_stat.in.h instead of
27810         sys_stat_.h.
27811         * lib/sys_time.in.h: Renamed from lib/sys_time_.h.
27812         * modules/sys_time (Files, Makefile.am): Use sys_time.in.h instead of
27813         sys_time_.h.
27814         * lib/sysexits.in.h: Renamed from lib/sysexits_.h.
27815         * modules/sysexits (Files, Makefile.am): Use sysexits.in.h instead of
27816         sysexits_.h.
27817         * lib/time.in.h: Renamed from lib/time_.h.
27818         * modules/time (Files, Makefile.am): Use time.in.h instead of time_.h.
27819         * lib/unistd.in.h: Renamed from lib/unistd_.h.
27820         * modules/unistd (Files, Makefile.am): Use unistd.in.h instead of
27821         unistd_.h.
27822         * lib/wchar.in.h: Renamed from lib/wchar_.h.
27823         * modules/wchar (Files, Makefile.am): Use wchar.in.h instead of
27824         wchar_.h.
27825         * lib/wctype.in.h: Renamed from lib/wctype_.h.
27826         * modules/wctype (Files, Makefile.am): Use wctype.in.h instead of
27827         wctype_.h.
27828         * build-aux/bootstrap (slurp): Update.
27829         * lib/.cppi-disable: Update.
27830
27831 2007-09-30  Bruno Haible  <bruno@clisp.org>
27832
27833         * tests/test-getaddrinfo.c (AF_UNSPEC): Provide a fallback definition.
27834         Needed on BeOS.
27835
27836 2007-09-30  Bruno Haible  <bruno@clisp.org>
27837
27838         * modules/dirname-tests (check_PROGRAMS): Renamed from noinst_PROGRAMS.
27839
27840 2007-09-29  Bruno Haible  <bruno@clisp.org>
27841
27842         * lib/stdio_.h (getdelim, getline): Add identifiers. Doc tweak.
27843
27844 2007-09-29  Bruno Haible  <bruno@clisp.org>
27845
27846         * lib/xreadlink.c (xreadlink): Simplify to a wrapper around areadlink.
27847         * modules/xreadlink (Depends-on): Add areadlink, remove readlink etc.
27848         * build-aux/install-reloc: Compile also areadlink.c.
27849         * modules/relocatable-prog-wrapper (Files): Add lib/areadlink.[hc].
27850
27851 2007-09-29  Bruno Haible  <bruno@clisp.org>
27852
27853         * gnulib-tool (func_emit_initmacro_done): Indentation.
27854
27855 2007-09-29  Bruno Haible  <bruno@clisp.org>
27856
27857         * README: Add CVS checkout update instructions.
27858         Info from Bob Proulx <bob@proulx.com>.
27859
27860 2007-09-28  Eric Blake  <ebb9@byu.net>
27861
27862         Provide move-if-change.
27863         * build-aux/move-if-change: New file, based on best practice
27864         rather than any canonical upstream location.
27865
27866 2007-09-28  Jim Meyering  <jim@meyering.net>
27867
27868         Fix canonicalize loop-detection corner case.
27869         Do not attempt to stat the symlink values stored via seen_triple.
27870         Without this, coreutils' tests/misc/readlink-fp-loop test would fail
27871         on linux-2.6.18, (but not 2.6.22).
27872         * lib/canonicalize.c (seen_triple): Use triple_compare_ino_str, not
27873         triple_compare.  The former compares dev,ino,filename, while the latter
27874         would actually stat dirname(filename) when dev and ino were equal.
27875         * lib/hash-triple.c: Install <string.h>.
27876         (STREQ): Define.
27877         (triple_compare_ino_str): New function.
27878         * lib/hash-triple.h (triple_compare_ino_str): Declare it.
27879
27880 2007-09-28  Eric Blake  <ebb9@byu.net>
27881
27882         Enforce that AC_REPLACE_FUNCS files exist.
27883         * gnulib-tool (func_emit_initmacro_done): Make AC_LIBSOURCES
27884         override check for typos.
27885
27886         Fix test-closein on Solaris 10.
27887         * tests/test-closein.c (main): Don't assume stdin can be inherited
27888         closed on all systems.
27889         * tests/test-closein.sh: Likewise.
27890         Reported by Piotr Tarnowski.
27891
27892 2007-09-28  Jim Meyering  <jim@meyering.net>
27893
27894         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Fix typo in comment.
27895
27896 2007-09-27  Jim Meyering  <jim@meyering.net>
27897
27898         canonicalize: Avoid a false-positive cycle failure.
27899         * modules/canonicalize (Depends-on): Add file-set and hash-triple.
27900         Sort.  Remove cycle-check.
27901         * lib/canonicalize.c: Include file-set.h and hash-triple.h,
27902         not cycle-check.h.
27903         (seen_triple): New function.
27904         (canonicalize_filename_mode): Use it instead of cycle-check.
27905         * tests/test-canonicalize.c: Add a test for this bug.
27906         * tests/test-canonicalize.sh: Set up and run the test.
27907
27908         New module, file-set, from coreutils.
27909         * modules/file-set: Define it.
27910         * lib/file-set.c, lib/file-set.h: Implement.
27911
27912         New module, hash-triple, from coreutils.
27913         * modules/hash-triple: Define it.
27914         * lib/hash-triple.c, lib/hash-triple.h: Implement.
27915
27916 2007-09-25  Eric Blake  <ebb9@byu.net>
27917
27918         Fix strerror on Interix.
27919         * lib/string_.h (strerror): Declare replacement.
27920         * doc/functions/strerror.texi (strerror): Document the Interix
27921         shortcoming.
27922         * modules/string (Makefile.am): Support new hooks.
27923         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Add new hooks.
27924         * m4/strerror.m4 (gl_FUNC_STRERROR): Defer to
27925         gl_FUNC_STRERROR_SEPARATE.
27926         (gl_FUNC_STRERROR_SEPARATE): Check for Interix bug.
27927         * lib/strerror.c (rpl_strerror): Provide replacement.
27928         * modules/strerror (Depends-on): Add string.
27929         (configure.ac): Detect use of module.
27930         * tests/test-strerror.c: New file.
27931         * modules/strerror-tests: New test module.
27932         * modules/argp (Depends-on): Add strerror.
27933         * modules/error (Depends-on): Likewise.
27934         Reported by Martin Koeppe.
27935
27936 2007-09-24  Bruno Haible  <bruno@clisp.org>
27937
27938         * README: Update git instructions.
27939
27940 2007-09-24  Eric Blake  <ebb9@byu.net>
27941
27942         Revert fpending breakage from 2007-09-08.
27943         * m4/fpending.m4 (gl_FUNC_FPENDING): Don't require existence of
27944         __fpending.c.
27945
27946 2007-09-24  Jim Meyering  <jim@meyering.net>
27947
27948         filenamecat.c: Add a test.
27949         * lib/filenamecat.c (main) [TEST_FILE_NAME_CONCAT]: Add a test
27950         showing how the function works when DIR is the empty string.
27951
27952 2007-09-21  Simon Josefsson  <simon@josefsson.org>
27953
27954         * tests/test-canonicalize.sh: Turn on executable bit.
27955
27956 2007-09-19  Eric Blake  <ebb9@byu.net>
27957
27958         * README: Update CVS instructions.
27959
27960 2007-09-18  Bruno Haible  <bruno@clisp.org>
27961
27962         * modules/areadlink: New file.
27963         * lib/areadlink.h (areadlink): New declaration.
27964         * lib/areadlink.c: New file, based on lib/xreadlink.c.
27965
27966 2007-09-17  Jim Meyering  <jim@meyering.net>
27967
27968         * lib/savewd.c (ESTALE) [!defined]: Define.
27969         Reported to be required on Interix by Martin Koeppe.
27970
27971 2007-09-17  Bruno Haible  <bruno@clisp.org>
27972
27973         * gnulib-tool (func_version): Use $version.
27974
27975 2007-09-16  Bruno Haible  <bruno@clisp.org>
27976
27977         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE, gl_PRINTF_INFINITE,
27978         gl_PRINTF_INFINITE_LONG_DOUBLE): Increase buf's size from 100 to 10000.
27979         Needed on glibc-2.6.1 with -fstack-protector -D_FORTIFY_SOURCE=2.
27980         Reported by Greg Schafer <gschafer@zip.com.au>.
27981
27982 2007-09-15  Bruno Haible  <bruno@clisp.org>
27983
27984         * gnulib-tool (sed): Try a little harder to make bash understand the
27985         alias.
27986         Reported by Bruce Korb <bruce.korb@gmail.com>.
27987
27988 2007-09-13  Eric Blake  <ebb9@byu.net>
27989
27990         * ChangeLog: Remove conflict markers.
27991
27992 2007-09-13  Simon Josefsson  <simon@josefsson.org>
27993
27994         * lib/gc-gnulib.c (gc_hash_open): Catch NULL calloc return value.
27995         Reported by Bruno Haible <bruno@clisp.org>.
27996
27997 2007-09-12  Bruno Haible  <bruno@clisp.org>
27998
27999         * m4/lock.m4: Don't provide an AC_USE_SYSTEM_EXTENSIONS definition.
28000         (gl_LOCK_EARLY_BODY): Use AC_GNU_SOURCE when AC_USE_SYSTEM_EXTENSIONS
28001         is not defined.
28002
28003 2007-09-12  Eric Blake  <ebb9@byu.net>
28004
28005         Track CVS Autoconf on AC_USE_SYSTEM_EXTENSIONS.
28006         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Update to CVS
28007         Autoconf definition.
28008         * modules/euidaccess (Depends-on): Add extensions, for
28009         AC_USE_SYSTEM_EXTENSIONS with autoconf <= 2.59.
28010         * modules/fnmatch (Depends-on): Likewise.
28011         * modules/getaddrinfo (Depends-on): Likewise.
28012         * modules/getdelim (Depends-on): Likewise.
28013         * modules/getline (Depends-on): Likewise.
28014         * modules/getsubopt (Depends-on): Likewise.
28015         * modules/gettext (Depends-on): Likewise.
28016         * modules/group-member (Depends-on): Likewise.
28017         * modules/mbchar (Depends-on): Likewise.
28018         * modules/memmem (Depends-on): Likewise.
28019         * modules/mempcpy (Depends-on): Likewise.
28020         * modules/memrchr (Depends-on): Likewise.
28021         * modules/pagealign_alloc (Depends-on): Likewise.
28022         * modules/readutmp (Depends-on): Likewise.
28023         * modules/stpcpy (Depends-on): Likewise.
28024         * modules/stpncpy (Depends-on): Likewise.
28025         * modules/strchrnul (Depends-on): Likewise.
28026         * modules/strndup (Depends-on): Likewise.
28027         * modules/strsep (Depends-on): Likewise.
28028         * modules/strverscmp (Depends-on): Likewise.
28029         * modules/vasprintf (Depends-on): Likewise.
28030         * modules/wcwidth (Depends-on): Likewise.
28031         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): AC_GNU_SOURCE will be
28032         obsolete in Autoconf 2.62; use AC_USE_SYSTEM_EXTENSIONS instead.
28033         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_GNU): Likewise.
28034         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDR_INFO): Likewise.
28035         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
28036         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
28037         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Likewise.
28038         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
28039         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER): Likewise.
28040         * m4/mbchar.m4 (gl_MBCHAR): Likewise.
28041         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
28042         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
28043         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
28044         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Likewise.
28045         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC): Likewise.
28046         * m4/readutmp.m4 (gl_READUTMP): Likewise.
28047         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
28048         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
28049         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
28050         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
28051         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
28052         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
28053         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
28054         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP): Likewise.
28055         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): Likewise.
28056         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
28057         * m4/lock.m4 (gl_LOCK_EARLY_BODY): Likewise, but provide fallback,
28058         so that lock.m4 can be used in gettext without extensions module.
28059
28060 2007-09-11  Bruno Haible  <bruno@clisp.org>
28061
28062         * m4/isc-posix.m4: Remove file.
28063         Suggested by Eric Blake.
28064
28065 2007-09-11  Eric Blake  <ebb9@byu.net>
28066
28067         * ChangeLog: Restore lines accidentally truncated 2007-04-06.
28068
28069 2007-09-10  Bruno Haible  <bruno@clisp.org>
28070
28071         * posix-modules: Fix typo in error message.
28072         Reported by Matt <mkraai@beckman.com>.
28073
28074 2007-09-09  Bruno Haible  <bruno@clisp.org>
28075
28076         * doc/functions/getdelim.texi: Update list of platforms lacking the
28077         function.
28078         * doc/functions/getline.texi: Likewise.
28079
28080 2007-09-09  Jim Meyering  <jim@meyering.net>
28081
28082         * lib/hash.c (hash_initialize): Detect calloc failure.
28083         Reported by Bruno Haible.
28084
28085 2007-09-09  Bruno Haible  <bruno@clisp.org>
28086
28087         * lib/canonicalize-lgpl.c (__realpath): Set errno to ENOMEM when
28088         malloc or realloc fails.
28089
28090 2007-09-09  Bruno Haible  <bruno@clisp.org>
28091
28092         * modules/getcwd (Depends-on): Add malloc-posix.
28093         * modules/glob (Depends-on): Likewise.
28094         * modules/putenv (Depends-on): Likewise.
28095         * modules/strdup (Depends-on): Likewise.
28096         * modules/getdelim (Depends-on): Add realloc-posix.
28097         * modules/read-file (Depends-on): Likewise.
28098
28099 2007-09-09  Bruno Haible  <bruno@clisp.org>
28100
28101         * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): New macro.
28102         (gl_FUNC_MALLOC_POSIX): Require it.
28103         * m4/realloc.m4 (gl_FUNC_REALLOC_POSIX): Likewise.
28104         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): Likewise.
28105         * modules/realloc (Files): Add m4/malloc.m4.
28106         * modules/calloc (Files): Likewise.
28107
28108 2007-09-09  Bruno Haible  <bruno@clisp.org>
28109
28110         * modules/malloc-posix: New file.
28111         * modules/malloc (Depends-on): Add malloc-posix.
28112         * lib/malloc.c: Include errno.h.
28113         (rpl_malloc): Merge the requirements of a glibc-compatible malloc
28114         and a POSIX-compatible malloc into a single function. Set ENOMEM
28115         when returning NULL.
28116         * m4/malloc.m4: New file.
28117         * doc/functions/malloc.texi: Mention the malloc-posix module.
28118         * lib/stdlib_.h (malloc): New declaration.
28119         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
28120         GNULIB_MALLOC_POSIX and HAVE_MALLOC_POSIX.
28121         * modules/stdlib (stdlib.h): Substitute also GNULIB_MALLOC_POSIX
28122         and HAVE_MALLOC_POSIX.
28123
28124 2007-09-09  Bruno Haible  <bruno@clisp.org>
28125
28126         * modules/realloc-posix: New file.
28127         * modules/realloc (Depends-on): Add realloc-posix.
28128         * lib/realloc.c: Include errno.h.
28129         (rpl_realloc): Merge the requirements of a glibc-compatible realloc
28130         and a POSIX-compatible realloc into a single function. Set ENOMEM
28131         when returning NULL.
28132         * m4/realloc.m4: New file.
28133         * doc/functions/realloc.texi: Mention the realloc-posix module.
28134         * lib/stdlib_.h (realloc): New declaration.
28135         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
28136         GNULIB_REALLOC_POSIX and HAVE_REALLOC_POSIX.
28137         * modules/stdlib (stdlib.h): Substitute also GNULIB_REALLOC_POSIX
28138         and HAVE_REALLOC_POSIX.
28139
28140 2007-09-09  Bruno Haible  <bruno@clisp.org>
28141
28142         * modules/calloc-posix: New file.
28143         * modules/calloc (Depends-on): Add calloc-posix.
28144         * lib/calloc.c: Include errno.h.
28145         (rpl_calloc): Merge the requirements of a glibc-compatible calloc
28146         and a POSIX-compatible calloc into a single function. Set ENOMEM
28147         when returning NULL.
28148         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): New macro.
28149         * doc/functions/calloc.texi: Mention the calloc-posix module.
28150         * lib/stdlib_.h (calloc): New declaration.
28151         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
28152         GNULIB_CALLOC_POSIX and HAVE_CALLOC_POSIX.
28153         * modules/stdlib (stdlib.h): Substitute also GNULIB_CALLOC_POSIX
28154         and HAVE_CALLOC_POSIX.
28155
28156 2007-09-09  Bruno Haible  <bruno@clisp.org>
28157
28158         Allow for modules to show an arbitrary notice.
28159         * modules/TEMPLATE-EXTENDED: Add 'Notice' field.
28160         * gnulib-tool: New option --extract-notice.
28161         (func_usage): Document it.
28162         (sed_extract_prog): Update.
28163         (func_get_notice): New function.
28164         (func_modules_notice): New function.
28165         (func_import, func_create_testdir): Invoke it.
28166         Suggested by Jim Meyering.
28167
28168 2007-09-09  Bruno Haible  <bruno@clisp.org>
28169
28170         * gnulib-tool: New options --verbose, --quiet.
28171         (func_usage): Document them.
28172         (verbose): New variable.
28173         (func_execute_command): New function.
28174         (func_import): Don't show the module list and the file list if
28175         $verbose < 0.
28176         (func_create_testdir): Likewise. Use func_execute_command.
28177         (func_create_megatestdir): Use func_execute_command.
28178
28179 2007-09-08  Bruno Haible  <bruno@clisp.org>
28180
28181         * gnulib-tool (func_import): Prefer rsync over wget when available,
28182         for fetching the PO files.
28183
28184 2007-09-08  Bruno Haible  <bruno@clisp.org>
28185
28186         * posix-modules: New file. Portions copied from gnulib-tool.
28187         * doc/gnulib.texi (POSIX Substitutes Library): New chapter.
28188
28189 2007-09-08  Jim Meyering  <jim@meyering.net>
28190
28191         Rename __fpending.c -> fpending.c and __fpending.h -> fpending.h
28192         * lib/fpending.h: Rename from __fpending.h.
28193         * lib/fpending.c: Rename from __fpending.c.
28194         Include "fpending.h", not "__fpending.h".
28195         * lib/__fpending.h, lib/__fpending.c: Remove files.
28196         * modules/fpending (Files): Reflect new file names.
28197         * lib/close-stream.c: Include "fpending.h", not "__fpending.h".
28198
28199 2007-09-08  Bruno Haible  <bruno@clisp.org>
28200
28201         * m4/inttypes-h.m4: Remove stub file.
28202
28203 2007-09-07  Simon Josefsson  <simon@josefsson.org>
28204
28205         * doc/headers/stdint.texi: Discuss #include_next issue.
28206
28207 2007-09-06  Paul Eggert  <eggert@cs.ucla.edu>
28208
28209         * build-aux/bootstrap: Remove obsolete comment about wget --help.
28210
28211 2007-09-06  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
28212
28213         * m4/time_h.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Fix misspelling
28214         in variable name.
28215
28216 2007-09-03  Jim Meyering  <jim@meyering.net>
28217
28218         New module: git-version-gen.
28219         * modules/git-version-gen: New file.
28220
28221         Import changes from coreutils for bootstrap script.
28222
28223         * build-aux/bootstrap (WGET_COMMAND): Remove code to set this variable.
28224
28225         bootstrap: uses rsync to download the .po files
28226         * build-aux/bootstrap (po_download_command_format): New global.
28227         (download_po_files): Use rsync.
28228         (update_po_files): Don't remove .po files after download,
28229         so future rsync runs can take advantage of the copies.
28230
28231         * build-aux/bootstrap (gnulib_tool): Make sha1sum check quietly.
28232
28233         Solve the unnecessary-.po-file-regeneration problem once and for all.
28234         * build-aux/bootstrap (download_po_files): New function, renamed from
28235         get_translations.  Now, downloads, but doesn't update LINGUAS.
28236         (update_po_files): New function.
28237
28238         bootstrap: Ignore more.
28239         * build-aux/bootstrap (symlink_to_dir): Add a directory name like
28240         uniwidth to e.g., lib/.gitignore.
28241         (slurp): Handle the sys_stat_.h -> sys mapping, too.
28242
28243         * build-aux/bootstrap: New setting: vc_ignore.
28244         (insert_sorted_if_absent): Create $file if absent.
28245         Adapt to new, possibly empty, list: $vc_ignore.
28246
28247         bootstrap: generate more ignorable names
28248         * build-aux/bootstrap (slurp): When generating ignorable names,
28249         also map .sin to .sed, .gperf to .c, and .y to .c.
28250
28251 2007-09-03  Jim Meyering  <jim@meyering.net>
28252
28253         * build-aux/git-version-gen: New file, from coreutils.  For details, see
28254         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commitdiff;h=bfe49f506
28255
28256 2007-09-02  Bruno Haible  <bruno@clisp.org>
28257
28258         Fix mis-recognition of 'mcs' on QNX 6.
28259         * m4/csharpcomp.m4 (gt_CSHARPCOMP): Test whether the "mcs --version"
28260         output contains the string "Mono".
28261         * lib/csharpcomp.c (compile_csharp_using_mono): Likewise.
28262         Reported by <kraai@ftbfs.org> at <https://savannah.gnu.org/bugs/?18337>.
28263
28264 2007-09-01  Bruno Haible  <bruno@clisp.org>
28265
28266         Fix collision between uniwidth/* and linebreak modules.
28267         * lib/linebreak.h (locale_charset, uc_width, u8_width, u16_width,
28268         u32_width): Remove declarations.
28269         * lib/linebreak.c: Include uniwidth.h, uniwidth/cjk.h, streq.h.
28270         (u32_mbtouc_unsafe, streq9, streq8, streq7, streq6, streq5, streq4,
28271         streq3, streq2, streq1, streq0): Remove functions.
28272         (STREQ): Remove macro.
28273         (is_cjk_encoding): Remove function.
28274         (nonspacing_table_data, nonspacing_table_ind): Remove constants.
28275         (uc_width, u8_width, u16_width, u32_width): Remove functions.
28276         * modules/linebreak (Depends-on): Add streq, uniwidth/width.
28277         * NEWS: Document the change.
28278
28279 2007-09-01  Bruno Haible  <bruno@clisp.org>
28280
28281         * lib/streq.h: Add double-inclusion guard.
28282
28283 2007-09-01  Karl Berry  <karl@gnu.org>
28284
28285         * MODULES.html.sh: Rename mreadlink_with_size to areadlink_with_size.
28286
28287 2007-08-28  Jim Meyering  <jim@meyering.net>
28288
28289         Rename mreadlink_with_size to areadlink_with_size.
28290         * NEWS: Document the change.
28291         * lib/mreadlink-with-size.c (mreadlink_with_size): Rename this to...
28292         * lib/areadlink-with-size.c (areadlink_with_size): ...this.
28293         * lib/mreadlink.h: Rename this to...
28294         * lib/areadlink.h: ...this.
28295         * modules/mreadlink-with-size: Rename this to...
28296         * modules/areadlink-with-size: ...this.
28297         * lib/canonicalize.c: Reflect the renaming.
28298         * modules/canonicalize: Likewise.
28299
28300 2007-08-26  Bruno Haible  <bruno@clisp.org>
28301
28302         * gnulib-tool (func_import): When deciding which files to remove,
28303         consider also dangling symbolic links.
28304         Reported by Eric Blake.
28305
28306 2007-08-26  Bruno Haible  <bruno@clisp.org>
28307
28308         * gnulib-tool (func_ln_if_changed): Use "test -h", not "test -L".
28309
28310 2007-08-23  Simon Josefsson  <simon@josefsson.org>
28311
28312         * lib/readline.c: Don't include getline.h, the prototype is now
28313         found in stdio.h.
28314
28315 2007-08-23  Jim Meyering  <jim@meyering.net>
28316
28317         Getdelim touchup.
28318         * lib/getdelim.c (getdelim): Don't bother to save/restore errno
28319         around the funlockfile call, since funlockfile never sets errno.
28320         Don't set errno upon failed realloc.
28321
28322 2007-08-22  Eric Blake  <ebb9@byu.net>
28323
28324         Getline touchups.
28325         * lib/getdelim.c (getdelim): Revert regression that required *n to
28326         be 0 when *lineptr is NULL.  Preserve errno across funlockfile.
28327         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Check for declaration of
28328         getdelim, rather than whether implementation is missing.
28329         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise for getline.
28330         * lib/stdio_.h (getline): Also declare if replacement is
28331         required.
28332         * doc/functions/getdelim.texi: New file.
28333         * doc/functions/getline.texi: Likewise.
28334         * doc/gnulib.texi (Function Substitutes): Add new files.
28335         Reported by Bruno Haible.
28336
28337 2007-08-22  Ludovic Courtès  <ludo@gnu.org>
28338
28339         * users.txt: Add Guile.
28340
28341 2007-08-22  Eric Blake  <ebb9@byu.net>
28342
28343         * tests/test-getdelim.c (main): Use remove, not unlink.
28344         * tests/test-getline.c (main): Likewise.
28345
28346         Move getline and getdelim into stdio.h, per POSIX 200x.
28347         * modules/getline (Files): Remove getline.h.
28348         (Depends-on): Add stdio.
28349         (configure.ac): Add module indicator.
28350         * modules/getdelim (Files): Remove getdelim.h.
28351         (Depends-on): Add stdio.
28352         (configure.ac): Add module indicator.
28353         * modules/stdio (Makefile.am): Work with new indicators.
28354         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add new defaults.
28355         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Work with stdio needs.
28356         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
28357         * lib/getdelim.h: Delete.
28358         * lib/getline.h: Delete.
28359         * lib/stdio_.h (getdelim, getline): Declare.
28360         * modules/getdelim-tests: New module.
28361         * modules/getline-tests: Likewise.
28362         * tests/test-getdelim.c: New file.
28363         * tests/test-getline.c: Likewise.
28364         * NEWS: Document the change.
28365         * lib/getline.c: Update choice of header.
28366         * lib/csharpcomp.c: Likewise.
28367         * lib/getpass.c: Likewise.
28368         * lib/javacomp.c: Likewise.
28369         * lib/javaversion.c: Likewise.
28370         * lib/yesno.c: Likewise.
28371         * lib/getdelim.c: Likewise.
28372         (getdelim): Set errno on failure, and avoid memory leak.
28373
28374 2007-08-19  Bruno Haible  <bruno@clisp.org>
28375
28376         * modules/closein (Depends-on): Add freadahead.
28377         * lib/closein.c: Include freadahead.h.
28378         (close_stdin): Skip the fseeko and fflush calls if freadahead(stdin)
28379         is zero.
28380
28381 2007-08-19  Bruno Haible  <bruno@clisp.org>
28382
28383         * modules/freadahead-tests: New file.
28384         * tests/test-freadahead.sh: New file.
28385         * tests/test-freadahead.c: New file.
28386
28387         * modules/freadahead: New file.
28388         * lib/freadahead.h: New file.
28389         * lib/freadahead.c: New file.
28390         * MODULES.html.sh (File stream based Input/Output): Add freadahead,
28391         fbufmode, fpurge, freadable, fwritable.
28392
28393 2007-08-19  Eric Blake  <ebb9@byu.net>
28394
28395         Test yesno in combination with closein.
28396         * lib/yesno.c (yesno): Document use of stdin.
28397         * modules/yesno-tests (Files): New module.
28398         * tests/test-yesno.c (main): New file.
28399         * tests/test-yesno.sh: Likewise.
28400
28401 2007-08-19  Bruno Haible  <bruno@clisp.org>
28402
28403         * lib/fbufmode.c (fbufmode): Add tentative support for Solaris/AMD64.
28404         * lib/fseeko.c (rpl_fseeko): Likewise.
28405         * lib/fseterr.c (fseterr): Likewise.
28406
28407 2007-08-19  Bruno Haible  <bruno@clisp.org>
28408
28409         * tests/test-lseek.c (main): Disable a test for BeOS.
28410         * doc/functions/lseek.texi: Document the BeOS bug.
28411
28412 2007-08-19  Bruno Haible  <bruno@clisp.org>
28413             Eric Blake  <ebb9@byu.net>
28414
28415         * lib/lseek.c: Include <sys/stat.h>.
28416         (rpl_lseek): Add workaround code also for Unix platforms.
28417         Needed for BeOS.
28418         * m4/lseek.m4 (gl_FUNC_LSEEK): When cross-compiling, fail on BeOS.
28419         * doc/functions/lseek.texi: Document BeOS definiency.
28420
28421 2007-08-18  Bruno Haible  <bruno@clisp.org>
28422
28423         * modules/fstrcmp-tests: New file.
28424         * tests/test-fstrcmp.c: New file.
28425
28426 2007-08-18  Bruno Haible  <bruno@clisp.org>
28427
28428         * modules/fstrcmp: New file, from GNU gettext with modifications.
28429         * lib/fstrcmp.h: New file, from GNU gettext.
28430         * lib/fstrcmp.c: New file, from GNU gettext.
28431         * MODULES.html.sh (String handling): Add fstrcmp.
28432
28433 2007-08-18  Bruno Haible  <bruno@clisp.org>
28434
28435         * lib/diffseq.h (struct context): Change type of 'heuristic' field to
28436         'bool'.
28437         (diag, compareseq): Remove const from the ctxt argument.
28438         (USE_HEURISTIC): Undefine at the end.
28439
28440 2007-08-18  Jim Meyering  <jim@meyering.net>
28441
28442         New file: lib/idcache.h
28443         * NEWS: Mention the addition.
28444         * modules/idcache (Files): Add lib/idcache.h
28445         * lib/idcache.c: Include "idcache.h".
28446         Don't include <sys/types.h>.
28447         Add a FIXME comment.
28448         Move file-scoped "static" declarations to the top.
28449         * lib/idcache.h: New file.  Include <sys/types.h> here, instead.
28450
28451 2007-08-17  Bruno Haible  <bruno@clisp.org>
28452         and Paul Eggert  <eggert@cs.ucla.edu>
28453
28454         * MODULES.html.sh: Add diffseq.
28455         * modules/diffseq: New file.
28456         * lib/diffseq.h: New file, from GNU gettext with a few minor changes,
28457         extracted from GNU gettext's fstrcmp.c and GNU diff's analyze.c.
28458
28459 2007-08-15  Paul Eggert  <eggert@cs.ucla.edu>
28460
28461         Import changes from coreutils for bootstrap script.
28462
28463         2007-07-21  Paul Eggert  <eggert@cs.ucla.edu>
28464
28465         * build-aux/bootstrap (slurp): Work even in environments where
28466         "ls" defaults to "ls -A".  Put in a FIXME, though, since the
28467         current code does not slurp files whose names start with ".", and
28468         this looks like it might be a troublesome area.
28469
28470         2007-07-11  Jim Meyering  <jim@meyering.net>
28471
28472         If there's a GPL vN copyright comment, require that N == 3.
28473
28474         2007-07-08  Jim Meyering  <jim@meyering.net>
28475
28476         Run the coreutils-specific code only if tests/Makefile.am.in exists.
28477         * build-aux/bootstrap (mam_template): Move definition out of loop.
28478
28479         Create symlinks for gl/{lib,m4}/*, just as for gnulib/{lib,m4}/*.
28480
28481         * build-aux/bootstrap (symlink_to_dir): Rename function from
28482         symlink_to_gnulib.  Add a directory parameter.  Update all
28483         callers.
28484         (cp_mark_as_generated): Also check for -- and link to -- files in
28485         gl/.
28486
28487         2007-07-08  Jim Meyering  <jim@meyering.net>
28488
28489         Adapt to deeper hierarchy in gnulib.
28490         * build-aux/bootstrap (symlink_to_dir): If the destination
28491         directory doesn't exist, create it. This is required at least for
28492         "lib/uniwidth/cjk.h".
28493
28494         2007-05-15  Jim Meyering  <jim@meyering.net>
28495
28496         * build-aux/bootstrap: Now that generated Makefile.am files
28497         are no longer under version control, they must be created at
28498         bootstrap time.
28499
28500 2007-08-14  Ben Pfaff  <blp@gnu.org>
28501
28502         * lib/count-one-bits.h: Add comments.  From Bruno Haible.
28503
28504 2007-08-14  Paul Eggert  <eggert@cs.ucla.edu>
28505
28506         * lib/count-one-bits.h: Don't include <limits.h>; no longer needed
28507         given the changes below.
28508         (COUNT_ONE_BITS): Use 'verify' rather than 'verify_true'.  Work
28509         even on hosts that have padding bits beyond the supported 64.
28510
28511 2007-08-10  Paul Eggert  <eggert@cs.ucla.edu>
28512
28513         * NEWS: In xstrtol, remove STRTOL_FATAL_ERROR and add xstrtol_fatal.
28514         * lib/xstrtol.h: Don't include exitfail.h; that's now internal to
28515         xstrtol.c.  Include getopt.h, since xstrtol_fatal's signature
28516         depends on it.
28517         (xstrtol_error): Remove.
28518         (xstrtol_fatal): New decl, replacing the functionality of xstrtol_error
28519         but with a different signature.
28520         (ATTRIBUTE_NORETURN, __attribute__): New macros.
28521         * lib/xstrtol-error.c: Include exitfail.h.
28522         (xstrtol_fatal): New function, with a different signature from the
28523         old xstrtol_error, so that the caller need not worry about passing
28524         in an exit status, or about storage management of the option argument.
28525         (xstrtol_error): Now a static function.  Redo signature to
28526         implement xstrtol_fatal.  Output the correct number of hyphens in
28527         front of the option so that the caller need not worry about
28528         storage management.
28529         (N_): New macro.
28530         (_): Remove; not used now.
28531         * modules/xstrtol: Depend on getopt.
28532         * tests/test-xstrtol.c (main): Use new xstrtol_error function instead
28533         of old STRTOL_FATAL_ERROR macro.
28534         * tests/test-xstrtol.sh (t-xstrtol.xo): Adjust to match new behavior
28535         of test program.
28536         * tests/test-xstrtoimax.sh (t-xstrtoimax.xo): Likewise.
28537         * tests/test-xstrtoumax.sh (t-xstrtoumax.xo): Likewise.
28538
28539 2007-08-08  Eric Blake  <ebb9@byu.net>
28540
28541         * lib/xstrtol-error.c: Add missing include.
28542
28543         Move xstrtol messages into gnulib domain, when --pobase is used.
28544         * lib/xstrtol.h (_STRTOL_ERROR): Move messages out of macro...
28545         * lib/xstrtol-error.c (xstrtol_error): ...into new file.
28546         * modules/xstrtol (Files): Distribute new file.
28547         * m4/xstrtol.m4 (gl_XSTRTOL): Build new file.
28548         * lib/xstrtol.c (TESTING_XSTRTO): Move tests...
28549         * tests/test-xstrtol.c: ...into new file.
28550         * tests/test-xstrtoul.c: Also test xstrtoul.
28551         * tests/test-xstrtoimax.c: Also test xstrtoimax.
28552         * tests/test-xstrtoumax.c: Also test xstrtoumax.
28553         * tests/test-xstrtol.sh: Drive the tests.
28554         * tests/test-xstrtoimax.sh: Likewise.
28555         * tests/test-xstrtoumax.sh: Likewise.
28556         * modules/xstrtol-tests: New module.
28557         * modules/xstrtoimax-tests: Likewise.
28558         * modules/xstrtoumax-tests: Likewise.
28559
28560 2007-08-08  Jim Meyering  <jim@meyering.net>
28561
28562         New function: mfile_name_concat.
28563         * lib/filenamecat.c (mfile_name_concat): New function, just like
28564         file_name_concat, but return NULL upon failure rather than exiting
28565         with a diagnostic.
28566         * lib/filenamecat.h: Declare it.
28567
28568 2007-08-07  Bruno Haible  <bruno@clisp.org>
28569
28570         * m4/inttypes.m4 (gl_INTTYPES_H): Use GL_TRIGGER_STDC_LIMIT_MACROS
28571         instead of __STDC_LIMIT_MACROS_TRIGGER. This avoids a redefinition
28572         warning from gcc.
28573         Reported by Eric Blake.
28574
28575 2007-08-07  Simon Josefsson  <simon@josefsson.org>
28576
28577         * modules/crypto/arctwo (License): Use the synonymous term "LGPLv2+".
28578         * modules/crypto/arcfour (License): Likewise.
28579         * modules/crypto/des-tests (License): Likewise.
28580         * modules/crypto/gc-arctwo-tests (License): Likewise.
28581         * modules/crypto/gc-des-tests (License): Likewise.
28582         * modules/crypto/gc-hmac-md5-tests (License): Likewise.
28583         * modules/crypto/gc-hmac-sha1-tests (License): Likewise.
28584         * modules/crypto/gc-md2-tests (License): Likewise.
28585         * modules/crypto/gc-md4-tests (License): Likewise.
28586         * modules/crypto/gc-md5-tests (License): Likewise.
28587         * modules/crypto/gc-pbkdf2-sha1-tests (License): Likewise.
28588         * modules/crypto/gc-rijndael-tests (License): Likewise.
28589         * modules/crypto/gc-sha1-tests (License): Likewise.
28590         * modules/crypto/gc-tests (License): Likewise.
28591         * modules/crypto/hmac-md5 (License): Likewise.
28592         * modules/crypto/hmac-sha1 (License): Likewise.
28593         * modules/crypto/md2-tests (License): Likewise.
28594         * modules/crypto/md4-tests (License): Likewise.
28595         * modules/crypto/md5 (License): Likewise.
28596         * modules/crypto/rijndael (License): Likewise.
28597         * modules/crypto/sha1 (License): Likewise.
28598         * modules/memxor (License): Likewise.
28599
28600 2007-08-06  Paul Eggert  <eggert@cs.ucla.edu>
28601         and Bruno Haible  <bruno@clisp.org>
28602
28603         * NEWS: Describe interface changes to human, xstrtol.
28604         * lib/human.h: Include <xstrtol.h>.
28605         (human_options): Return enum strtol_error, not int.  Remove
28606         bool arg; take int * instead.
28607         * lib/human.c: Don't include "gettext.h".
28608         (_): Remove; no longer used.
28609         Don't include <xstrtol.h>, since human.h does it.
28610         (human_options): Adjust to abovementioned interface changes.
28611         Do not report error to stderr; that's now the caller's
28612         responsibility.
28613         * lib/xstrtol.c (main) [defined TESTING_XSTRTO]: Adjust to
28614         interface change.
28615         * lib/xstrtol.h (_STRTOL_ERROR): Take Option, Arg rather than
28616         Str, Argument_type_string.  All uses changed.  Put " argument"
28617         in diagnostics to make them clearer.  Change wording of suffix
28618         message for clarity.
28619         (STRTOL_FATAL_ERROR): Take Option, Arg rather than Str,
28620         Argument_type_string.
28621         (STRTOL_FATAL_WARN): Remove; no longer used.
28622         * modules/human (Depends-on): Remove gettext-h.
28623
28624 2007-08-06  Simon Josefsson  <simon@josefsson.org>
28625
28626         * build-aux/maint.mk, build-aux/GNUmakefile: Relicense to GPLv3+.
28627
28628 2007-07-31  Bruno Haible  <bruno@clisp.org>
28629
28630         * m4/stdint.m4 (gl_STDINT_H): Test whether WCHAR_MIN and WCHAR_MAX
28631         are defined by <stdint.h> (as opposed to <wchar.h>, as on Dragonfly).
28632         Reported by Joerg Sonnenberger <joerg@britannica.bec.de>.
28633
28634 2007-07-31  Bruno Haible  <bruno@clisp.org>
28635
28636         * lib/fflush.c (rpl_fflush): On BSD systems, use the __SNPT flag.
28637         Suggested by Joerg Sonnenberger <joerg@britannica.bec.de>.
28638
28639 2007-07-30  Bruno Haible  <bruno@clisp.org>
28640
28641         * modules/base64 (License): Use the synonymous term "LGPLv2+".
28642         * modules/c-ctype (License): Likewise.
28643         * modules/c-strcase (License): Likewise.
28644         * modules/check-version (License): Likewise.
28645         * modules/iconv (License): Likewise.
28646         * modules/iconv_open (License): Likewise.
28647         * modules/read-file (License): Likewise.
28648         * modules/striconv (License): Likewise.
28649         * modules/strverscmp (License): Likewise.
28650         * modules/vasprintf (License): Likewise.
28651         * modules/crypto/des (License): Likewise.
28652         * modules/crypto/gc (License): Likewise.
28653         * modules/crypto/gc-arcfour (License): Likewise.
28654         * modules/crypto/gc-arctwo (License): Likewise.
28655         * modules/crypto/gc-des (License): Likewise.
28656         * modules/crypto/gc-hmac-md5 (License): Likewise.
28657         * modules/crypto/gc-hmac-sha1 (License): Likewise.
28658         * modules/crypto/gc-md2 (License): Likewise.
28659         * modules/crypto/gc-md4 (License): Likewise.
28660         * modules/crypto/gc-md5 (License): Likewise.
28661         * modules/crypto/gc-pbkdf2-sha1 (License): Likewise.
28662         * modules/crypto/gc-random (License): Likewise.
28663         * modules/crypto/gc-rijndael (License): Likewise.
28664         * modules/crypto/gc-sha1 (License): Likewise.
28665         * modules/crypto/md2 (License): Likewise.
28666         * modules/crypto/md4 (License): Likewise.
28667
28668 2007-07-30  Jim Meyering  <jim@meyering.net>
28669
28670         * lib/fts.c (fts_read): Upon failure to chdir into a subdirectory,
28671         set fts_info to FTS_DNR, not to FTS_ERR, so that the caller knows
28672         it has valid stat data.  This bug would cause du not to count the
28673         sizes of inaccessible directories.
28674         Patch by Bryan Mason <bmason@redhat.com>, via Jose Maria Plans
28675         in <http://bugzilla.redhat.com/250077>.
28676
28677 2007-07-25  Peter O'Gorman  <peter@pogma.com>
28678             Bruno Haible  <bruno@clisp.org>
28679
28680         * m4/include_next.m4 (gl_INCLUDE_NEXT): Test whether #include_next
28681         really works. Needed because AIX 4.3 "xlc -E" doesn't understand
28682         #include_next, gives a diagnostic about it, but reports no error in
28683         the exit code.
28684         Reported by Gary V. Vaughan <gary@thewrittenword.com>.
28685
28686 2007-07-24  Ben Pfaff  <blp@gnu.org>
28687
28688         Improve name: "count-one-bits" is better than "popcount".
28689         * MODULES.html.sh: Update name.
28690         * lib/popcount.h: Renamed lib/count-one-bits.h.
28691         (popcount): Renamed count_one_bits.
28692         (popcountl): Renamed count_one_bits_l.
28693         (popcountll): Renamed count_one_bits_ll.
28694         * m4/popcount.m4: Renamed m4/count-one-bits.m4.
28695         * modules/popcount: Renamed module/count-one-bits.
28696         * modules/popcount-tests: Renamed module/count-one-bits-tests.
28697         * tests/test-popcount.c: Renamed tests/test-count-one-bits.c.
28698
28699 2007-07-23  Ben Pfaff  <blp@gnu.org>
28700
28701         * lib/popcount.h (popcount32): Reduce size of constants, to allow
28702         better code generation, and add U to large constants to avoid
28703         warnings, in non-GCC case.
28704         Suggested by Bruno Haible.
28705
28706 2007-07-23  Ben Pfaff  <blp@gnu.org>
28707
28708         * lib/popcount.h: Use verify_true instead of if...abort.
28709         * modules/popcount: Depend on verify module.
28710         Suggested by Jim Meyering.
28711
28712 2007-07-23  Bruno Haible  <bruno@clisp.org>
28713
28714         * gnulib-tool (func_import): Create a .cvsignore file also when the
28715         directory is not yet in CVS but the toplevel directory is. When
28716         creating a .cvsignore file, add ".deps" and ".dirstamp" to it.
28717         Reported by Karl Berry.
28718
28719 2007-07-22  Ben Pfaff  <blp@gnu.org>
28720
28721         * lib/popcount.h: Use faster, branchless algorithm for non-GCC
28722         case.
28723         Suggested by Eric Blake.
28724
28725 2007-07-22  Ben Pfaff  <blp@gnu.org>
28726
28727         New module: popcount.
28728         * MODULES.html.sh: Add popcount.
28729         * modules/popcount: New file.
28730         * modules/popcount-tests: New file.
28731         * tests/test-popcount.c: New file.
28732         * lib/popcount.h: New file.
28733         * m4/popcount.m4: New file.
28734
28735 2007-07-22  Paul Eggert  <eggert@cs.ucla.edu>
28736
28737         * build-aux/announce-gen: Update to GPLv3.
28738
28739         * build-aux/config.guess: Update from config.
28740
28741 2007-07-21  Bruno Haible  <bruno@clisp.org>
28742
28743         * lib/error.c (_) [ENABLE_NLS]: Define to gettext.
28744         * lib/verror.c (_) [ENABLE_NLS]: Likewise.
28745
28746 2007-07-20  Jim Meyering  <jim@meyering.net>
28747
28748         * check-module: Diagnose a self-dependency.
28749
28750 2007-07-19  Bruno Haible  <bruno@clisp.org>
28751
28752         * gnulib-tool (func_import): Don't abort if pobase or po_domain is
28753         empty.
28754         Reported by Eric Blake.
28755
28756 2007-07-18  Bruno Haible  <bruno@clisp.org>
28757
28758         * gnulib-tool: New options --po-base, --po-domain.
28759         (func_usage): Document them.
28760         (pobase, po_domain): New variables.
28761         (func_emit_lib_Makefile_am): Augment AM_CPPFLAGS, defining
28762         DEFAULT_TEXT_DOMAIN.
28763         (func_emit_po_Makevars, func_emit_po_POTFILES_in): New functions.
28764         (func_import): Consider pobase and po_domain. Create a po/ directory.
28765         (func_create_testdir): Set pobase and po_domain to empty.
28766         * build-aux/po/Makefile.in.in: New file, from GNU gettext 0.16.1.
28767         * build-aux/po/remove-potcdate.sin: New file, from GNU gettext 0.16.1.
28768
28769 2007-07-18  Bruno Haible  <bruno@clisp.org>
28770
28771         * gnulib-tool (func_get_automake_snippet): Synthesize also an
28772         EXTRA_DIST augmentation for files in build-aux/.
28773
28774 2007-07-16  Bruno Haible  <bruno@clisp.org>
28775
28776         * modules/lseek (License): Use the synonymous term "LGPLv2+".
28777         * modules/getdelim (License): Likewise.
28778
28779 2007-07-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
28780
28781         * modules/arpa_inet (License): Use the synonymous term LGPLv2+.
28782         * modules/d-type (License): Likewise.
28783         * modules/extensions (License): Likewise.
28784         * modules/fnmatch (License): Likewise.
28785         * modules/fseeko (License): Likewise.
28786         * modules/getaddrinfo (License): Likewise.
28787         * modules/getline (License): Likewise.
28788         * modules/getlogin_r (License): Likewise.
28789         * modules/getpass (License): Likewise.
28790         * modules/gettimeofday (License): Likewise.
28791         * modules/glob (License): Likewise.
28792         * modules/inet_ntop (License): Likewise.
28793         * modules/malloc (License): Likewise.
28794         * modules/malloca (License): Likewise.
28795         * modules/memmem (License): Likewise.
28796         * modules/mempcpy (License): Likewise.
28797         * modules/memset (License): Likewise.
28798         * modules/minmax (License): Likewise.
28799         * modules/mktime (License): Likewise.
28800         * modules/netinet_in (License): Likewise.
28801         * modules/pathmax (License): Likewise.
28802         * modules/poll (License): Likewise.
28803         * modules/regex (License): Likewise.
28804         * modules/snprintf (License): Likewise.
28805         * modules/stdbool (License): Likewise.
28806         * modules/stdint (License): Likewise.
28807         * modules/stdio (License): Likewise.
28808         * modules/strcase (License): Likewise.
28809         * modules/strcasestr (License): Likewise.
28810         * modules/strdup (License): Likewise.
28811         * modules/string (License): Likewise.
28812         * modules/strndup (License): Likewise.
28813         * modules/strnlen (License): Likewise.
28814         * modules/strpbrk (License): Likewise.
28815         * modules/strptime (License): Likewise.
28816         * modules/strsep (License): Likewise.
28817         * modules/sys_select (License): Likewise.
28818         * modules/sys_socket (License): Likewise.
28819         * modules/sys_stat (License): Likewise.
28820         * modules/sys_time (License): Likewise.
28821         * modules/time (License): Likewise.
28822         * modules/time_r (License): Likewise.
28823         * modules/timegm (License): Likewise.
28824         * modules/unistd (License): Likewise.
28825         * modules/vsnprintf (License): Likewise.
28826         * modules/wctype (License): Likewise.
28827
28828 2007-07-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
28829
28830         * modules/argz (License): LGPLv2+.
28831
28832 2007-07-15  Karl Berry  <karl@gnu.org>
28833
28834         * doc/gnulib.texi: revise node structure per new fdl.texi.
28835
28836 2007-07-14  Bruno Haible  <bruno@clisp.org>
28837
28838         * lib/uniname/gen-uninames.lisp (main): Emit a "do not edit" line to
28839         the output file.
28840         * lib/uniname/uninames.h: Regenerated.
28841
28842 2007-07-14  Karl Berry  <karl@gnu.org>
28843
28844         * doc/*gpl*.texi, doc/fdl.texi: new versions, consistently
28845         omitting sectioning and index commands.
28846
28847 2007-07-13  Bruno Haible  <bruno@clisp.org>
28848
28849         New gnulib-tool option --more-symlinks.
28850         * gnulib-tool (func_usage): Document --more-symlinks.
28851         (do_copyrights): New variable.
28852         Recognize option --more-symlinks.
28853         (func_import): Don't add a copyright notice transform to
28854         sed_transform_lib_file if do_copyrights is empty.
28855
28856 2007-07-13  Bruno Haible  <bruno@clisp.org>
28857
28858         * lib/vasnprintf.c (decimal_point_char): Define also if
28859         (NEED_PRINTF_LONG_DOUBLE || NEED_PRINTF_INFINITE_DOUBLE)
28860         && !NEED_PRINTF_DIRECTIVE_A.
28861         Reported by Clemens Koller <clemens.koller@anagramm.de> via
28862         Gary V. Vaughan <gary@gnu.org>.
28863
28864 2007-07-13  Paul Eggert  <eggert@cs.ucla.edu>
28865
28866         * lib/inttypes_.h: Undo previous change, since it was fixed
28867         in a different way in the 2007-07-02 fix to m4/inttypes.m4.
28868
28869 2007-07-13  Bruno Haible  <bruno@clisp.org>
28870
28871         * lib/stdint_.h: Fix typo: _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H was
28872         misspelled as _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H.
28873
28874 2007-07-13  Jim Meyering  <jim@meyering.net>
28875
28876         df: Don't fail for Tru64's "file-on-file mount".
28877         * m4/fsusage.m4 (gl_FSUSAGE): Reject Tru64's buggy statvfs,
28878         so we fall through and use statfs instead.  Details here:
28879         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/10878>
28880         Reported by Albert Chin.
28881
28882 2007-07-13  Bruno Haible  <bruno@clisp.org>
28883
28884         * modules/alloca-opt (License): Use the synonymous term "LGPLv2+".
28885         * modules/configmake (License): Likewise.
28886         * modules/gettext (License): Likewise.
28887         * modules/gettext-h (License): Likewise.
28888         * modules/include_next (License): Likewise.
28889         * modules/link-warning (License): Likewise.
28890         * modules/localcharset (License): Likewise.
28891         * modules/localename (License): Likewise.
28892         * modules/lock (License): Likewise.
28893         * modules/relocatable-lib-lgpl (License): Likewise.
28894         * modules/size_max (License): Likewise.
28895         * modules/vasnprintf (License): Likewise.
28896         * modules/wchar (License): Likewise.
28897         * modules/xsize (License): Likewise.
28898
28899 2007-07-13  Bruno Haible  <bruno@clisp.org>
28900
28901         * gnulib-tool (func_import): Treat LGPLv2 as synonymous to LGPL.
28902         (func_create_testdir): Handle copying terms "GPLv2+" and "LGPLv2+".
28903
28904 2007-07-12  Bruno Haible  <bruno@clisp.org>
28905
28906         * doc/gnulib-intro.texi (Copyright): Clarify the license abbreviations
28907         in the modules files.
28908
28909 2007-07-11  Karl Berry  <karl@gnu.org>
28910
28911         * MODULES.html.sh (func_module): use
28912          sed -e '\|^'"${includefile}"'$|d'
28913          instead of /.../d, to avoid errors on $includefile's containing /.
28914
28915 2007-07-10  Sergey Poznyakoff  <gray@gnu.org.ua>
28916
28917         * gnulib-tool (func_import): Avoid duplication of --avoid
28918         statements
28919         (func_dest_tmpfilename,func_create_testdir): Translate `-' in file
28920         names to `_' in variable names.
28921
28922 2007-07-10  Eric Blake  <ebb9@byu.net>
28923
28924         * lib/version-etc.c (version_etc_va): Default to GPLv3+.
28925         * NEWS: Document this change.
28926
28927 2007-07-08  Bruno Haible  <bruno@clisp.org>
28928
28929         Update to Unicode 5.0.
28930         * lib/uniwidth/width.c (nonspacing_table_data): Add U+00AD,
28931         U+0350..U+035F, U+05A2, U+05BA, U+05C5, U+05C7, U+0600..U+0603,
28932         U+0610..U+0615, U+0656..U+065E, U+07EB..U+07F3, U+0A01, U+0AE2..U+0AE3,
28933         U+0CBC. Remove U+0CBF, U+0CC6. Add U+0CE2..U+0CE3, U+135F,
28934         U+17B4..U+17B5, U+17DD. Remove U+180E. Add U+1920..U+1922,
28935         U+1927..U+192B, U+1932, U+1939..U+193B, U+1A17..U+1A18, U+1B00..U+1B03,
28936         U+1B34, U+1B36..U+1B3A, U+1B3C, U+1B42, U+1B6B..U+1B73, U+1DC0..U+1DCA,
28937         U+1DFE..U+1DFF, U+20EB..U+20EF, U+A802, U+A806, U+A80B, U+A825..U+A826,
28938         U+10A01..U+10A03, U+10A05..U+10A06, U+10A0C..U+10A0F, U+10A38..U+10A3A,
28939         U+10A3F, U+1D242..U+1D244.
28940         (nonspacing_table_ind): Update.
28941         (uc_width): Assign width 0 to U+E0100..U+E01EF. Assign width 1 to
28942         U+4DC0..U+4DFF. Assign width 2 to U+2329..U+232A, U+FE10..U+FE1F.
28943
28944 2007-07-08  Bruno Haible  <bruno@clisp.org>
28945
28946         Update to Unicode 5.0.
28947         * lib/uniname/gen-uninames.lisp (main): Add the range 0x12xxx to the
28948         code transform. Extend the name index field of unicode_name_to_code and
28949         unicode_code_to_name from 16 to 24 bits.
28950         * lib/uniname/uniname.c (unicode_character_name,
28951         unicode_name_character): Add the range 0x12xxx to the code transform.
28952         * lib/uniname/uninames.h: Regenerated.
28953         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.0.
28954
28955 2007-07-07  Bruno Haible  <bruno@clisp.org>
28956
28957         * modules/wcwidth-tests: New file.
28958         * tests/test-wcwidth.c: New file.
28959
28960         Work around MacOS X wcwidth() bug.
28961         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test against MacOS X 10.3 bug.
28962         * lib/wcwidth.c: Include localcharset.h, streq.h, uniwidth.h.
28963         (rpl_wcwidth): Special-case the UTF-8 locales. Fall back to the
28964         original wcwidth in non-UTF-8 locales.
28965         * modules/wcwidth (Depends-on): Add localcharset, streq,
28966         uniwidth/width.
28967         * doc/functions/wcwidth.texi: Update.
28968
28969 2007-07-07  Bruno Haible  <bruno@clisp.org>
28970
28971         * lib/wchar_.h: Include the GL_LINK_WARNING macro.
28972         (wcwidth): New declaration.
28973         * m4/wchar.m4 (gl_WCHAR_MODULE_INDICATOR, gl_WCHAR_H_DEFAULTS): New
28974         macros.
28975         (gl_WCHAR_H): Require gl_WCHAR_H_DEFAULTS. Don't set WCHAR_H to empty
28976         here. Prepare for creating <wchar.h> unconditionally.
28977         * modules/wchar (Depends-on): Add link-warning.
28978         (Makefile.am): Substitute also GNULIB_WCWIDTH, HAVE_DECL_WCWIDTH,
28979         REPLACE_WCWIDTH, and GL_LINK_WARNING.
28980         * lib/wcwidth.h: Remove file.
28981         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gl_WCHAR_H_DEFAULTS. Set
28982         HAVE_DECL_WCWIDTH, REPLACE_WCWIDTH, WCHAR_H.
28983         * modules/wcwidth (Files): Remove lib/wcwidth.h.
28984         (configure.ac): Invoke gl_WCHAR_MODULE_INDICATOR.
28985         (Include): Replace wcwidth.h with <wchar.h>.
28986         * lib/wcwidth.c: Include <wchar.h> instead of wcwidth.h.
28987         * lib/mbchar.h: Don't include wcwidth.h.
28988         * lib/mbswidth.c: Likewise.
28989         * NEWS: Mention the change.
28990
28991 2007-07-07  Bruno Haible  <bruno@clisp.org>
28992
28993         * lib/wcwidth.c: New file, extracted from lib/wcwidth.h.
28994         * lib/wcwidth.h: Don't include wctype.h. Replace inline function
28995         definition with an external declaration.
28996         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Use wcwidth.c when wcwidth is not
28997         defined as a function. Remove AC_C_INLINE requirement.
28998         * modules/wcwidth (Files): Add lib/wcwidth.c.
28999         (Makefile.am): Remove redundant statement.
29000
29001 2007-07-07  Bruno Haible  <bruno@clisp.org>
29002
29003         * MODULES.html.sh (Unicode string functions): Add the new modules.
29004
29005         * tests/uniwidth/test-u32-strwidth.c: New file.
29006         * modules/uniwidth/u32-strwidth-tests: New file.
29007
29008         * lib/uniwidth/u32-strwidth.c: New file.
29009         * modules/uniwidth/u32-strwidth: New file.
29010
29011         * tests/uniwidth/test-u16-strwidth.c: New file.
29012         * modules/uniwidth/u16-strwidth-tests: New file.
29013
29014         * lib/uniwidth/u16-strwidth.c: New file.
29015         * modules/uniwidth/u16-strwidth: New file.
29016
29017         * tests/uniwidth/test-u8-strwidth.c: New file.
29018         * modules/uniwidth/u8-strwidth-tests: New file.
29019
29020         * lib/uniwidth/u8-strwidth.c: New file.
29021         * modules/uniwidth/u8-strwidth: New file.
29022
29023         * tests/uniwidth/test-u32-width.c: New file.
29024         * modules/uniwidth/u32-width-tests: New file.
29025
29026         * lib/uniwidth/u32-width.c: New file.
29027         * modules/uniwidth/u32-width: New file.
29028
29029         * tests/uniwidth/test-u16-width.c: New file.
29030         * modules/uniwidth/u16-width-tests: New file.
29031
29032         * lib/uniwidth/u16-width.c: New file.
29033         * modules/uniwidth/u16-width: New file.
29034
29035         * tests/uniwidth/test-u8-width.c: New file.
29036         * modules/uniwidth/u8-width-tests: New file.
29037
29038         * lib/uniwidth/u8-width.c: New file.
29039         * modules/uniwidth/u8-width: New file.
29040
29041         * tests/uniwidth/test-uc_width.c: New file.
29042         * modules/uniwidth/width-tests: New file.
29043
29044         * lib/uniwidth/width.c: New file, from GNU libiconv.
29045         * lib/uniwidth/cjk.h: New file, from GNU libiconv.
29046         * modules/uniwidth/width: New file.
29047
29048         * lib/uniwidth.h: New file, from GNU libiconv.
29049         * modules/uniwidth/base: New file.
29050
29051 2007-07-07  Bruno Haible  <bruno@clisp.org>
29052
29053         * lib/uniname.h: New file, from GNU gettext.
29054         * lib/uniname/gen-uninames.lisp: New file, from GNU gettext.
29055         * lib/uniname/uninames.h: New file, from GNU gettext.
29056         * lib/uniname/uniname.c: New file, from GNU gettext.
29057         * tests/uniname/test-uninames.sh: New file.
29058         * tests/uniname/test-uninames.c: New file, from GNU gettext.
29059         * tests/uniname/UnicodeDataNames.txt: New file, from GNU gettext.
29060         * modules/uniname/base: New file.
29061         * modules/uniname/uniname: New file.
29062         * modules/uniname/uniname-tests: New file.
29063         * MODULES.html.sh (Unicode string functions): Add the new modules.
29064
29065 2007-07-06  Bruno Haible  <bruno@clisp.org>
29066
29067         * doc/Makefile (TEXI2HTML): Specify a --reference-limit.
29068
29069 2007-07-06  Bruno Haible  <bruno@clisp.org>
29070
29071         * lib/sys_time_.h: Use a recursion-safe inclusion guard rather than
29072         a split double-inclusion guard. Needed for cygwin, where <sys/time.h>
29073         includes <cygwin/sys_time.h> which includes <sys/select.h> which
29074         include <sys/time.h>.
29075         Reported by Eric Blake.
29076
29077 2007-07-06  Eric Blake  <ebb9@byu.net>
29078
29079         Fix testing canonicalize on cygwin.
29080         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
29081         Revert patch from 2007-06-19.
29082         * tests/test-canonicalize-lgpl.c (main): Instead, skip test when
29083         canonicalize module is also in use.
29084         * tests/test-canonicalize.c: New file.
29085         * tests/test-canonicalize.sh: Likewise.
29086         * modules/canonicalize-tests: Likewise.
29087
29088 2007-07-06  Jim Meyering  <jim@meyering.net>
29089
29090         * lib/getugroups.c (getugroups): Detect getgrent failure.
29091         Adjust comment to reflect reality: this function may return -1.
29092
29093 2007-07-05  Sergey Poznyakoff  <gray@gnu.org.ua>
29094
29095         * build-aux/bootstrap (TP_URL,get_translations): Update to use
29096         the new TP address.
29097         (usage): Fix typo
29098         (gnulib_mk): New variable.
29099
29100 2007-07-05  Jim Meyering  <jim@meyering.net>
29101
29102         Don't let endgrent clobber errno, no matter how improbable.
29103         * lib/getugroups.c (getugroups): Save and restore errno around
29104         endgrent call.
29105
29106         Close the group DB even when failing with 2^31 or more members.
29107         * lib/getugroups.c (getugroups): Don't return without calling endgrent.
29108
29109 2007-07-04  Jim Meyering  <jim@meyering.net>
29110
29111         * lib/getugroups.h: New file.
29112         * lib/getugroups.c: Include "getugroups.h".
29113         Remove uses of "register" keyword.
29114         Move local variable, "cp", down into scope where used.
29115         Give "username" parameter the "const" attribute.
29116         * modules/getugroups (Files): Add lib/getugroups.h
29117
29118 2007-07-04  Karl Berry  <karl@gnu.org>
29119
29120         * MODULES.html.sh (func_all_modules): Complete rename of
29121         gpl/lgpl to gpl-2.0 and lgpl-2.1, and add gpl-3.0.
29122
29123 2007-07-02  Bruno Haible  <bruno@clisp.org>
29124
29125         * m4/inttypes.m4 (gl_INTTYPES_H): Define __STDC_LIMIT_MACROS in C++
29126         mode, when inttypes.h comes from gnulib.
29127         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
29128
29129 2007-07-02  Simon Josefsson  <simon@josefsson.org>
29130
29131         * NEWS: Mention lgpl module name change.
29132
29133         * modules/lgpl-2.1: Renamed from lgpl.
29134
29135         * NEWS: Mention gpl module name change.
29136
29137         * modules/gpl-3.0: New file, based on gpl-2.0.
29138
29139         * modules/gpl-2.0: Renamed from gpl.
29140
29141         * modules/gpl: Fix filename, doc/gpl.texi is now found at
29142         doc/gpl-2.0.texi.
29143
29144 2007-07-02  Paul Eggert  <eggert@cs.ucla.edu>
29145
29146         * lib/inttypes_.h [defined __cplusplus&&!defined __STDC_LIMIT_MACROS]:
29147         #define __STDC_LIMIT_MACROS temporarily while including
29148         <stdint.h>, so that __STDC_LIMIT_MACROS is defined.
29149         Problem reported by Joel E. Denny in
29150         <http://lists.gnu.org/archive/html/bug-gnulib/2007-07/msg00008.html>.
29151
29152 2007-07-01  Bruno Haible  <bruno@clisp.org>
29153
29154         * lib/unistdio.h: New file.
29155         * lib/unistdio/u-asnprintf.h: New file.
29156         * lib/unistdio/u-asprintf.h: New file.
29157         * lib/unistdio/u-printf-args.c: New file.
29158         * lib/unistdio/u-printf-args.h: New file.
29159         * lib/unistdio/u-printf-parse.h: New file.
29160         * lib/unistdio/u-snprintf.h: New file.
29161         * lib/unistdio/u-sprintf.h: New file.
29162         * lib/unistdio/u-vasprintf.h: New file.
29163         * lib/unistdio/u-vsnprintf.h: New file.
29164         * lib/unistdio/u-vsprintf.h: New file.
29165         * lib/unistdio/ulc-asnprintf.c: New file.
29166         * lib/unistdio/ulc-asprintf.c: New file.
29167         * lib/unistdio/ulc-fprintf.c: New file, based on lib/fprintf.c.
29168         * lib/unistdio/ulc-printf-parse.c: New file.
29169         * lib/unistdio/ulc-snprintf.c: New file.
29170         * lib/unistdio/ulc-sprintf.c: New file.
29171         * lib/unistdio/ulc-vasnprintf.c: New file.
29172         * lib/unistdio/ulc-vasprintf.c: New file.
29173         * lib/unistdio/ulc-vfprintf.c: New file, based on lib/vfprintf.c.
29174         * lib/unistdio/ulc-vsnprintf.c: New file.
29175         * lib/unistdio/ulc-vsprintf.c: New file.
29176         * lib/unistdio/u8-asnprintf.c: New file.
29177         * lib/unistdio/u8-asprintf.c: New file.
29178         * lib/unistdio/u8-printf-parse.c: New file.
29179         * lib/unistdio/u8-snprintf.c: New file.
29180         * lib/unistdio/u8-sprintf.c: New file.
29181         * lib/unistdio/u8-vasnprintf.c: New file.
29182         * lib/unistdio/u8-vasprintf.c: New file.
29183         * lib/unistdio/u8-vsnprintf.c: New file.
29184         * lib/unistdio/u8-vsprintf.c: New file.
29185         * lib/unistdio/u8-u8-asnprintf.c: New file.
29186         * lib/unistdio/u8-u8-asprintf.c: New file.
29187         * lib/unistdio/u8-u8-snprintf.c: New file.
29188         * lib/unistdio/u8-u8-sprintf.c: New file.
29189         * lib/unistdio/u8-u8-vasnprintf.c: New file.
29190         * lib/unistdio/u8-u8-vasprintf.c: New file.
29191         * lib/unistdio/u8-u8-vsnprintf.c: New file.
29192         * lib/unistdio/u8-u8-vsprintf.c: New file.
29193         * lib/unistdio/u16-asnprintf.c: New file.
29194         * lib/unistdio/u16-asprintf.c: New file.
29195         * lib/unistdio/u16-printf-parse.c: New file.
29196         * lib/unistdio/u16-snprintf.c: New file.
29197         * lib/unistdio/u16-sprintf.c: New file.
29198         * lib/unistdio/u16-vasnprintf.c: New file.
29199         * lib/unistdio/u16-vasprintf.c: New file.
29200         * lib/unistdio/u16-vsnprintf.c: New file.
29201         * lib/unistdio/u16-vsprintf.c: New file.
29202         * lib/unistdio/u16-u16-asnprintf.c: New file.
29203         * lib/unistdio/u16-u16-asprintf.c: New file.
29204         * lib/unistdio/u16-u16-snprintf.c: New file.
29205         * lib/unistdio/u16-u16-sprintf.c: New file.
29206         * lib/unistdio/u16-u16-vasnprintf.c: New file.
29207         * lib/unistdio/u16-u16-vasprintf.c: New file.
29208         * lib/unistdio/u16-u16-vsnprintf.c: New file.
29209         * lib/unistdio/u16-u16-vsprintf.c: New file.
29210         * lib/unistdio/u32-asnprintf.c: New file.
29211         * lib/unistdio/u32-asprintf.c: New file.
29212         * lib/unistdio/u32-printf-parse.c: New file.
29213         * lib/unistdio/u32-snprintf.c: New file.
29214         * lib/unistdio/u32-sprintf.c: New file.
29215         * lib/unistdio/u32-vasnprintf.c: New file.
29216         * lib/unistdio/u32-vasprintf.c: New file.
29217         * lib/unistdio/u32-vsnprintf.c: New file.
29218         * lib/unistdio/u32-vsprintf.c: New file.
29219         * lib/unistdio/u32-u32-asnprintf.c: New file.
29220         * lib/unistdio/u32-u32-asprintf.c: New file.
29221         * lib/unistdio/u32-u32-snprintf.c: New file.
29222         * lib/unistdio/u32-u32-sprintf.c: New file.
29223         * lib/unistdio/u32-u32-vasnprintf.c: New file.
29224         * lib/unistdio/u32-u32-vasprintf.c: New file.
29225         * lib/unistdio/u32-u32-vsnprintf.c: New file.
29226         * lib/unistdio/u32-u32-vsprintf.c: New file.
29227         * tests/unistdio/test-ulc-asnprintf1.c: New file.
29228         * tests/unistdio/test-ulc-asnprintf1.h: New file.
29229         * tests/unistdio/test-ulc-printf1.h: New file.
29230         * tests/unistdio/test-ulc-vasnprintf1.c: New file.
29231         * tests/unistdio/test-ulc-vasnprintf2.c: New file.
29232         * tests/unistdio/test-ulc-vasnprintf2.sh: New file.
29233         * tests/unistdio/test-ulc-vasnprintf3.c: New file.
29234         * tests/unistdio/test-ulc-vasnprintf3.sh: New file.
29235         * tests/unistdio/test-ulc-vasprintf1.c: New file.
29236         * tests/unistdio/test-ulc-vsnprintf1.c: New file.
29237         * tests/unistdio/test-ulc-vsprintf1.c: New file.
29238         * tests/unistdio/test-u8-asnprintf1.c: New file.
29239         * tests/unistdio/test-u8-asnprintf1.h: New file.
29240         * tests/unistdio/test-u8-printf1.h: New file.
29241         * tests/unistdio/test-u8-vasnprintf1.c: New file.
29242         * tests/unistdio/test-u8-vasnprintf2.c: New file.
29243         * tests/unistdio/test-u8-vasnprintf2.sh: New file.
29244         * tests/unistdio/test-u8-vasnprintf3.c: New file.
29245         * tests/unistdio/test-u8-vasnprintf3.sh: New file.
29246         * tests/unistdio/test-u8-vasprintf1.c: New file.
29247         * tests/unistdio/test-u8-vsnprintf1.c: New file.
29248         * tests/unistdio/test-u8-vsprintf1.c: New file.
29249         * tests/unistdio/test-u16-asnprintf1.c: New file.
29250         * tests/unistdio/test-u16-asnprintf1.h: New file.
29251         * tests/unistdio/test-u16-printf1.h: New file.
29252         * tests/unistdio/test-u16-vasnprintf1.c: New file.
29253         * tests/unistdio/test-u16-vasnprintf2.c: New file.
29254         * tests/unistdio/test-u16-vasnprintf2.sh: New file.
29255         * tests/unistdio/test-u16-vasnprintf3.c: New file.
29256         * tests/unistdio/test-u16-vasnprintf3.sh: New file.
29257         * tests/unistdio/test-u16-vasprintf1.c: New file.
29258         * tests/unistdio/test-u16-vsnprintf1.c: New file.
29259         * tests/unistdio/test-u16-vsprintf1.c: New file.
29260         * tests/unistdio/test-u32-asnprintf1.c: New file.
29261         * tests/unistdio/test-u32-asnprintf1.h: New file.
29262         * tests/unistdio/test-u32-printf1.h: New file.
29263         * tests/unistdio/test-u32-vasnprintf1.c: New file.
29264         * tests/unistdio/test-u32-vasnprintf2.c: New file.
29265         * tests/unistdio/test-u32-vasnprintf2.sh: New file.
29266         * tests/unistdio/test-u32-vasnprintf3.c: New file.
29267         * tests/unistdio/test-u32-vasnprintf3.sh: New file.
29268         * tests/unistdio/test-u32-vasprintf1.c: New file.
29269         * tests/unistdio/test-u32-vsnprintf1.c: New file.
29270         * tests/unistdio/test-u32-vsprintf1.c: New file.
29271         * modules/unistdio/base: New file.
29272         * modules/unistdio/u-printf-args: New file.
29273         * modules/unistdio/ulc-asnprintf: New file.
29274         * modules/unistdio/ulc-asprintf: New file.
29275         * modules/unistdio/ulc-fprintf: New file.
29276         * modules/unistdio/ulc-printf-parse: New file.
29277         * modules/unistdio/ulc-snprintf: New file.
29278         * modules/unistdio/ulc-sprintf: New file.
29279         * modules/unistdio/ulc-vasnprintf: New file.
29280         * modules/unistdio/ulc-vasprintf: New file.
29281         * modules/unistdio/ulc-vfprintf: New file.
29282         * modules/unistdio/ulc-vsnprintf: New file.
29283         * modules/unistdio/ulc-vsprintf: New file.
29284         * modules/unistdio/u8-asnprintf: New file.
29285         * modules/unistdio/u8-asprintf: New file.
29286         * modules/unistdio/u8-printf-parse: New file.
29287         * modules/unistdio/u8-snprintf: New file.
29288         * modules/unistdio/u8-sprintf: New file.
29289         * modules/unistdio/u8-vasnprintf: New file.
29290         * modules/unistdio/u8-vasprintf: New file.
29291         * modules/unistdio/u8-vsnprintf: New file.
29292         * modules/unistdio/u8-vsprintf: New file.
29293         * modules/unistdio/u8-u8-asnprintf: New file.
29294         * modules/unistdio/u8-u8-asprintf: New file.
29295         * modules/unistdio/u8-u8-snprintf: New file.
29296         * modules/unistdio/u8-u8-sprintf: New file.
29297         * modules/unistdio/u8-u8-vasnprintf: New file.
29298         * modules/unistdio/u8-u8-vasprintf: New file.
29299         * modules/unistdio/u8-u8-vsnprintf: New file.
29300         * modules/unistdio/u8-u8-vsprintf: New file.
29301         * modules/unistdio/u16-asnprintf: New file.
29302         * modules/unistdio/u16-asprintf: New file.
29303         * modules/unistdio/u16-printf-parse: New file.
29304         * modules/unistdio/u16-snprintf: New file.
29305         * modules/unistdio/u16-sprintf: New file.
29306         * modules/unistdio/u16-vasnprintf: New file.
29307         * modules/unistdio/u16-vasprintf: New file.
29308         * modules/unistdio/u16-vsnprintf: New file.
29309         * modules/unistdio/u16-vsprintf: New file.
29310         * modules/unistdio/u16-u16-asnprintf: New file.
29311         * modules/unistdio/u16-u16-asprintf: New file.
29312         * modules/unistdio/u16-u16-snprintf: New file.
29313         * modules/unistdio/u16-u16-sprintf: New file.
29314         * modules/unistdio/u16-u16-vasnprintf: New file.
29315         * modules/unistdio/u16-u16-vasprintf: New file.
29316         * modules/unistdio/u16-u16-vsnprintf: New file.
29317         * modules/unistdio/u16-u16-vsprintf: New file.
29318         * modules/unistdio/u32-asnprintf: New file.
29319         * modules/unistdio/u32-asprintf: New file.
29320         * modules/unistdio/u32-printf-parse: New file.
29321         * modules/unistdio/u32-snprintf: New file.
29322         * modules/unistdio/u32-sprintf: New file.
29323         * modules/unistdio/u32-vasnprintf: New file.
29324         * modules/unistdio/u32-vasprintf: New file.
29325         * modules/unistdio/u32-vsnprintf: New file.
29326         * modules/unistdio/u32-vsprintf: New file.
29327         * modules/unistdio/u32-u32-asnprintf: New file.
29328         * modules/unistdio/u32-u32-asprintf: New file.
29329         * modules/unistdio/u32-u32-snprintf: New file.
29330         * modules/unistdio/u32-u32-sprintf: New file.
29331         * modules/unistdio/u32-u32-vasnprintf: New file.
29332         * modules/unistdio/u32-u32-vasprintf: New file.
29333         * modules/unistdio/u32-u32-vsnprintf: New file.
29334         * modules/unistdio/u32-u32-vsprintf: New file.
29335         * modules/unistdio/ulc-asnprintf-tests: New file.
29336         * modules/unistdio/ulc-vasnprintf-tests: New file.
29337         * modules/unistdio/ulc-vasprintf-tests: New file.
29338         * modules/unistdio/ulc-vsnprintf-tests: New file.
29339         * modules/unistdio/ulc-vsprintf-tests: New file.
29340         * modules/unistdio/u8-asnprintf-tests: New file.
29341         * modules/unistdio/u8-vasnprintf-tests: New file.
29342         * modules/unistdio/u8-vasprintf-tests: New file.
29343         * modules/unistdio/u8-vsnprintf-tests: New file.
29344         * modules/unistdio/u8-vsprintf-tests: New file.
29345         * modules/unistdio/u16-asnprintf-tests: New file.
29346         * modules/unistdio/u16-vasnprintf-tests: New file.
29347         * modules/unistdio/u16-vasprintf-tests: New file.
29348         * modules/unistdio/u16-vsnprintf-tests: New file.
29349         * modules/unistdio/u16-vsprintf-tests: New file.
29350         * modules/unistdio/u32-asnprintf-tests: New file.
29351         * modules/unistdio/u32-vasnprintf-tests: New file.
29352         * modules/unistdio/u32-vasprintf-tests: New file.
29353         * modules/unistdio/u32-vsnprintf-tests: New file.
29354         * modules/unistdio/u32-vsprintf-tests: New file.
29355         * MODULES.html.sh (Unicode string functions): Add the new modules.
29356
29357 2007-07-01  Bruno Haible  <bruno@clisp.org>
29358
29359         * lib/sprintf.c (sprintf): Limit the available length estimation,
29360         to avoid address wraparound.
29361         * lib/vsprintf.c (vsprintf): Likewise.
29362         * modules/sprintf-posix (Dependencies): Add stdint.
29363         * modules/vsprintf-posix (Dependencies): Likewise.
29364
29365 2007-07-01  Bruno Haible  <bruno@clisp.org>
29366
29367         * gnulib-tool (self_abspathname): Determine PATH_SEPARATOR and handle
29368         Windows PATH as well. Conservative double-quoting. Comments.
29369
29370 2007-07-01  Bruno Haible  <bruno@clisp.org>
29371             Eric Blake  <ebb9@byu.net>
29372             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
29373
29374         * gnulib-tool (self_abspathname): Fix algorithm to cope with
29375         empty components in $PATH, denoting '.'.
29376
29377 2007-07-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
29378
29379         * gnulib-tool: Fix indentation.
29380         (func_create_megatestdir): Likewise.
29381         Report by Bruno Haible.
29382
29383 2007-06-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
29384
29385         Sync from Automake.
29386         * build-aux/gnupload: Fix shell portability issues with for loops.
29387         Report by Karl Berry.
29388
29389 2007-06-29  Simon Josefsson  <simon@josefsson.org>
29390
29391         * build-aux/maint.mk (POURL): Use translationproject.org.
29392
29393 2007-06-27  Simon Josefsson  <simon@josefsson.org>
29394             Bruno Haible  <bruno@clisp.org>
29395
29396         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Require gl_HEADER_SYS_SOCKET
29397         before using HAVE_WS2TCPIP_H. Check for gai_strerror through an
29398         explicit link test, rather than AC_REPLACE_FUNCS - for mingw.
29399         (gl_PREREQ_GETADDRINFO): Require gl_HEADER_SYS_SOCKET before using
29400         HAVE_SYS_SOCKET_H and HAVE_WS2TCPIP_H.
29401
29402 2007-06-27  Bruno Haible  <bruno@clisp.org>
29403
29404         * build-aux/config.rpath: Upgrade to libtool-1.5.24.
29405         * build-aux/config.libpath: Upgrade to libtool-1.5.24.
29406
29407 2007-06-26  Karl Berry  <karl@gnu.org>
29408
29409         * MODULES.html.sh: remove xreadlink-with-size.
29410
29411 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
29412
29413         * lib/time_.h: Port to Solaris 8 with Sun Studio 11, using a
29414         method that I hope also handles the double-include problem noted
29415         by Bruno Haible in
29416         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00186.html>.
29417
29418 2007-06-23  Bruno Haible  <bruno@clisp.org>
29419
29420         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
29421         Don't let the 'mostlyclean' target fail if the last subdirectory could
29422         not be removed.
29423         Reported by Karl Berry.
29424
29425 2007-06-23  Bruno Haible  <bruno@clisp.org>
29426
29427         * gnulib-tool (echo): Add a speedier workaround for ksh.
29428         * tests/test-echo.sh: Likewise.
29429
29430 2007-06-23  Bruno Haible  <bruno@clisp.org>
29431
29432         * gnulib-tool (echo): Add workarounds also for bash versions < 2.04.
29433         * tests/test-echo.sh: Likewise.
29434
29435 2007-06-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
29436
29437         * gnulib-tool (IFS): Initialize early, so we don't set it to
29438         empty later.
29439         (self_abspathname): Rewrite algorithm to set it, reindent.
29440         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am)
29441         (func_create_megatestdir): Merge some sed scripts.
29442
29443 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
29444
29445         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Check some typos
29446         exposed by Sun Studio 11 cc on Solaris 8.
29447
29448 2007-06-22  Bruno Haible  <bruno@clisp.org>
29449
29450         * gnulib-tool (echo): Ensure the echo primitive does not interpret
29451         backslashes.
29452         * tests/test-echo.sh: New file.
29453
29454 2007-06-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
29455
29456         * gnulib-tool (func_add_or_update, func_create_testdir): Do not
29457         simplify `sed_replace_build_aux' scripts, they are portable but
29458         echoing them with `echo' is not.
29459         Report and analysis by Fernando Ferreira <fernando.prog@netcabo.pt>.
29460
29461 2007-06-21  Karl Berry  <karl@gnu.org>
29462
29463         * config/srclist.txt: guess we can't handle the licenses via
29464         srclist at the moment.
29465
29466 2007-06-21  Paul Eggert  <eggert@cs.ucla.edu>
29467
29468         * MODULES.html.sh: Add include_next.
29469         * modules/include_next: New file.
29470
29471 2007-06-20  Paul Eggert  <eggert@cs.ucla.edu>
29472
29473         * m4/include_next.m4 (gl_INCLUDE_NEXT): Define and AC_SUBST
29474         INCLUDE_NEXT.
29475         (gl_CHECK_NEXT_HEADERS): New macro.
29476         * m4/fcntl_h.m4 (gl_FCNTL_H): use gl_CHECK_NEXT_HEADERS instead of
29477         the obsolescent gl_ABSOLUTE_HEADER.
29478         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
29479         * m4/float_h.m4 (gl_FLOAT_H): Likewise.
29480         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
29481         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
29482         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
29483         * m4/math_h.m4 (gl_MATH_H): Likewise.
29484         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
29485         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
29486         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
29487         * m4/stdint.m4 (gl_STDINT_H): Likewise.
29488         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
29489         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
29490         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
29491         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
29492         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
29493         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
29494         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
29495         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
29496         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Likewise.
29497         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
29498         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
29499         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
29500         * m4/inttypes.m4 (gl_INTTYPES_H): Define
29501         _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H to avoid the problem of unclean
29502         builds, since ABSOLUTE_INTTYPES_H is no longer being defined.
29503         * m4/stdint.m4 (gl_STDINT_H): Likewise, for
29504         _GL_JUST_INCLUDE_SYSTEM_STDINT_H.
29505         * lib/fcntl_.h: Use @INCLUDE_NEXT@ @NEXT_foo_H@
29506         rather than @HAVE_INCLUDE_NEXT@ and @ABSOLUTE_foo_H@.
29507         * lib/float_.h: Likewise.
29508         * lib/inttypes_.h: Likewise.
29509         * lib/math_.h: Likewise.
29510         * lib/search_.h: Likewise.
29511         * lib/signal_.h: Likewise.
29512         * lib/stdint_.h: Likewise.
29513         * lib/stdio_.h: Likewise.
29514         * lib/stdlib_.h: Likewise.
29515         * lib/string_.h: Likewise.
29516         * lib/sys_stat_.h: Likewise.
29517         * lib/sys_time_.h: Likewise.
29518         * lib/time_.h: Likewise.
29519         * lib/unistd_.h: Likewise.
29520         * lib/wchar_.h: Likewise.
29521         * lib/wctype_.h: Likewise.
29522         * lib/dirent_.h: Likewise.
29523         * lib/iconv_.h: Likewise.
29524         * lib/locale_.h: Likewise.
29525         * lib/netinet_in_.h: Likewise.
29526         * lib/sys_select_.h: Likewise.
29527         * lib/sys_socket_.h: Likewise.
29528         * lib/sysexits_.h: Likewise.
29529         * modules/fcntl (Depends-on): Depend on include_next, not
29530         absolute_header.
29531         (Makefile): Substitute INCLUDE_NEXT and NEXT_foo_H, not
29532         HAVE_INCLUDE_NEXT and ABSOLUTE_foo_H.
29533         * modules/fchdir: Likewise.
29534         * modules/float: Likewise.
29535         * modules/iconv_open: Likewise.
29536         * modules/inttypes: Likewise.
29537         * modules/locale: Likewise.
29538         * modules/math: Likewise.
29539         * modules/netinet_in: Likewise.
29540         * modules/search: Likewise.
29541         * modules/signal: Likewise.
29542         * modules/stdint: Likewise.
29543         * modules/stdio: Likewise.
29544         * modules/stdlib: Likewise.
29545         * modules/string: Likewise.
29546         * modules/sys_select: Likewise.
29547         * modules/sys_socket: Likewise.
29548         * modules/sys_stat: Likewise.
29549         * modules/sys_time: Likewise.
29550         * modules/sysexits: Likewise.
29551         * modules/time: Likewise.
29552         * modules/unistd: Likewise.
29553         * modules/wchar: Likewise.
29554         * modules/wctype: Likewise.
29555         * modules/sys_stat: Change maintainer to "all".
29556         * modules/unistd: Likewise.
29557
29558 2007-06-20  Karl Berry  <karl@gnu.org>
29559
29560         * config/srclist.txt: track www changes in license files.
29561
29562 2007-06-20  Sergey Poznyakoff  <gray@gnu.org.ua>
29563
29564         * build-aux/bootstrap: Remove stray dot.
29565         Make sure build_aux settings are honored when linking
29566         gnulib_extra_files.
29567
29568 2007-06-19  Eric Blake  <ebb9@byu.net>
29569
29570         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
29571         Allow compilation on cygwin.
29572
29573 2007-06-19  Jim Meyering  <jim@meyering.net>
29574
29575         xreadlink-with-size: Remove module.  No longer used.
29576         Ex-callers now use xreadlink or mreadlink-with-size.
29577         * modules/xreadlink-with-size: Remove module.
29578         * lib/xreadlink-with-size.c: Remove file.
29579         * lib/xreadlink.h (xreadlink_with_size): Remove prototype.
29580         (xreadlink): Remove inaccurate comment.  The one in xreadlink.c,
29581         just before the function definition *is* accurate.
29582
29583         Eliminate one way canonicalize_filename_mode could exit.
29584         * lib/canonicalize.c (canonicalize_filename_mode):
29585         Use mreadlink_with_size, not xreadlink_with_size.
29586
29587 2007-06-18  Paul Eggert  <eggert@cs.ucla.edu>
29588
29589         Detect porting problems to FreeBSD/arm, which has time_t wider than
29590         long int.  Original problem reported for GNU diff by Xin Li in
29591         <http://lists.gnu.org/archive/html/bug-gnu-utils/2007-06/msg00091.html>.
29592         * modules/getdate (Depends-on): Add intprops, verify.
29593         * lib/getdate.y: Include intprops.h, verify.h.  Verify that time_t
29594         is an integer type no wider than long int.
29595
29596 2007-06-18  Jim Meyering  <jim@meyering.net>
29597
29598         New module: mreadlink-with-size.
29599         * MODULES.html.sh: Add mreadlink-with-size.
29600         * modules/mreadlink-with-size: New module
29601         * modules/canonicalize (Depends-on): Depend on mreadlink-with-size,
29602         not xreadlink-with-size.
29603         * lib/mreadlink-with-size.c, lib/mreadlink.h: New files.
29604
29605 2007-06-16  Bruno Haible  <bruno@clisp.org>
29606
29607         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Catch the MacOS X 10.4 bug.
29608         * doc/functions/frexpl.texi: Document the MacOS X 10.4 bug.
29609         Reported by Gary V. Vaughan <gary@gnu.org>.
29610
29611 2007-06-15  Paul Eggert  <eggert@cs.ucla.edu>
29612
29613         Revamp lchown so that it lives in unistd.h where it belongs.
29614         * lib/lchown.h: Remove.
29615         * lib/dirchownmod.c: Don't include lib/lchown.h.
29616         * lib/fchownat.c: Likewise.
29617         * lib/openat.c: Likewise.
29618         * lib/lchown.c (REPLACE_CHOWN): Define to 0 if the system chown
29619         does not follow symlinks.
29620         (EOPNOTSUPP): Define if not defined.
29621         * lib/unistd_.h (chown): Do not replace if REPLADE_CHOWN
29622         is defined to 0.
29623         (lchown): New decl.
29624         * m4/lchown.m4 (gl_FUNC_LCHOWN): Require gl_UNISTD_H_DEFAULTS.
29625         Do not check for lchown decl.
29626         Set REPLACE_LCHOWN.
29627         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set GNULIB_LCHOWN,
29628         REPLACE_LCHOWN.
29629         * modules/chown: Make it clear it follows symlinks.
29630         * modules/lchown: Make it clear it doesn't follow symlinks.
29631         (Files): Remove lib/lchown.h
29632         (Depends-on): Add unistd.
29633         (configure.ac): Add gl_UNISTD_MODULE_INDICATOR([lchown]).
29634         (Include): Include <unistd.h>, not "lchown.h".
29635         * modules/unistd (unistd.h): Substitude GNULIB_LCHOWN and
29636         REPLACE_LCHOWN.
29637
29638 2007-06-15  Jim Meyering  <jim@meyering.net>
29639
29640         Change license (GPL to LGPL) of fsusage and dependents.
29641         * modules/fsusage (License): Change to LGPL.
29642         * modules/full-read (License): Likewise.
29643         * modules/full-write (License): Likewise.
29644         * modules/safe-read (License): Likewise.
29645         * modules/safe-write (License): Likewise.
29646
29647 2007-06-14  Ben Pfaff  <blp@gnu.org>
29648
29649         Missing part of allocsa -> malloca transition.
29650         * modules/relocatable-prog-wrapper: gl_ALLOCSA should be
29651         gl_MALLOCA.
29652
29653 2007-06-12  Bruno Haible  <bruno@clisp.org>
29654
29655         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Guess no when cross-compiling
29656         to ia64, x86_64, i386.
29657         Reported by Eric Blake.
29658
29659 2007-06-12  Bruno Haible  <bruno@clisp.org>
29660
29661         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Guess no also when
29662         cross-compiling to x86_64.
29663
29664 2007-06-12  Paul Eggert  <eggert@cs.ucla.edu>
29665
29666         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Fix POSIX sed portability
29667         glitch reported by Ralf Wildenhues in
29668         <http://lists.gnu.org/archive/html/bug-gnulib/2007-06/msg00114.html>.
29669
29670         * m4/regex.m4 (gl_REGEX): Catch a bug with [[:alnum:]_-] reported by
29671         Vin Shelton.
29672
29673 2007-06-11  Bruno Haible  <bruno@clisp.org>
29674
29675         * lib/printf-args.c (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Fix NULL
29676         replacement string.
29677         Reported by Eric Blake.
29678
29679 2007-06-10  Bruno Haible  <bruno@clisp.org>
29680
29681         Prepare vasnprintf code for use with Unicode strings.
29682         * lib/printf-args.h (PRINTF_FETCHARGS): New macro.
29683         (arg_type) [ENABLE_UNISTDIO]: Define TYPE_U8_STRING, TYPE_U16_STRING,
29684         TYPE_U32_STRING.
29685         (argument) [ENABLE_UNISTDIO]: Add a_u8_string, a_u16_string,
29686         a_u32_string variants.
29687         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
29688         * lib/printf-args.c: Don't include config.h and the specification
29689         header if PRINTF_FETCHARGS is already defined.
29690         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
29691         (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Add code for TYPE_U8_STRING,
29692         TYPE_U16_STRING, TYPE_U32_STRING.
29693         * lib/printf-parse.h [ENABLE_UNISTDIO] (u8_directive, u8_directives,
29694         u16_directive, u16_directives, u32_directive, u32_directives): New
29695         types.
29696         (ulc_printf_parse, u8_printf_parse, u16_printf_parse, u32_printf_parse):
29697         New declarations.
29698         * lib/printf-parse.c: Don't include config.h and the specification
29699         header if PRINTF_PARSE is already defined. Eliminate the set of
29700         parameters for WIDE_CHAR_VERSION; the user of this file must provide
29701         them now. Include c-ctype.h.
29702         (PRINTF_PARSE) [ENABLE_UNISTDIO]: Add code implementing the 'U'
29703         directive and CHAR_T_ONLY_ASCII.
29704         * lib/vasnprintf.c: Don't include config.h and the specification header
29705         if VASNPRINTF is already defined.
29706         (DCHAR_IS_TCHAR, DCHAR_CPY): New macros.
29707         (VASNPRINTF): Use PRINTF_FETCHARGS instead of printf_fetchargs. Use
29708         DCHAR_CPY. Handle the case that DCHAR_T and FCHAR_T are not the same
29709         type. Handle the case that TCHAR_T and FCHAR_T are not of the same
29710         size. Handle the case that DCHAR_T and TCHAR_T are not the same type,
29711         add a conversion from TCHAR_T[] to DCHAR_T[], and rework the padding
29712         code accordingly.
29713         (VASNPRINTF) [ENABLE_UNISTDIO]: Implement the 'U' directive. Enable
29714         pad_ourselves also in this case, with the 'c' and 's' directives, and
29715         with a different notion of "width".
29716         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): New macros.
29717
29718 2007-06-10  Bruno Haible  <bruno@clisp.org>
29719
29720         * modules/unistr/u32-mbsnlen: New file.
29721         * lib/unistr/u32-mbsnlen.c: New file.
29722
29723         * modules/unistr/u16-mbsnlen: New file.
29724         * lib/unistr/u16-mbsnlen.c: New file.
29725
29726         * modules/unistr/u8-mbsnlen: New file.
29727         * lib/unistr/u8-mbsnlen.c: New file.
29728
29729         * lib/unistr.h (u8_mbsnlen, u16_mbsnlen, u32_mbsnlen): New
29730         declarations.
29731
29732 2007-06-10  Bruno Haible  <bruno@clisp.org>
29733
29734         * lib/string_.h (mbsnlen): New declaration.
29735         * lib/mbsnlen.c: New file.
29736         * m4/mbsnlen.m4: New file.
29737         * modules/mbsnlen: New file.
29738         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set GNULIB_MBSNLEN.
29739         * modules/string (string.h): Substitute GNULIB_MBSNLEN.
29740         * MODULES.html.sh (Internationalization functions): Add mbsnlen.
29741
29742 2007-06-10  Bruno Haible  <bruno@clisp.org>
29743
29744         * lib/mbslen.c: Include <stdlib.h>, needed for MB_CUR_MAX.
29745
29746 2007-06-10  Bruno Haible  <bruno@clisp.org>
29747
29748         * lib/mbiter.h: Include <stddef.h>, needed for ptrdiff_t.
29749         * lib/mbuiter.h: Likewise.
29750
29751 2007-06-10  Bruno Haible  <bruno@clisp.org>
29752
29753         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Check for _snprintf
29754         declaration.
29755
29756 2007-06-10  Karl Berry  <karl@gnu.org>
29757
29758         * config/srclist.txt: remove gettext entries, Bruno prefers
29759         to update individually.
29760
29761 2007-06-10  Bruno Haible  <bruno@clisp.org>
29762
29763         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Remove variable
29764         'maxlen'. Ensure only length + width bytes are allocated, not
29765         length + 1 + width.
29766
29767 2007-06-09  Bruno Haible  <bruno@clisp.org>
29768
29769         * lib/vasnprintf.c (FCHAR_T, DCHAR_T, TCHAR_T): New macros.
29770         (CHAR_T): Remove macro.
29771         (VASNPRINTF): Update.
29772
29773 2007-06-09  Bruno Haible  <bruno@clisp.org>
29774
29775         * MODULES.html.sh (Unicode string functions): Add the new modules.
29776
29777         * modules/uniconv/u32-conv-to-enc: New file.
29778         * lib/uniconv/u32-conv-to-enc.c: New file.
29779         * modules/uniconv/u32-conv-to-enc-tests: New file.
29780         * tests/uniconv/test-u32-conv-to-enc.c: New file.
29781
29782         * modules/uniconv/u16-conv-to-enc: New file.
29783         * lib/uniconv/u16-conv-to-enc.c: New file.
29784         * lib/uniconv/u-conv-to-enc.h: New file.
29785         * modules/uniconv/u16-conv-to-enc-tests: New file.
29786         * tests/uniconv/test-u16-conv-to-enc.c: New file.
29787
29788         * modules/uniconv/u8-conv-to-enc: New file.
29789         * lib/uniconv/u8-conv-to-enc.c: New file.
29790         * modules/uniconv/u8-conv-to-enc-tests: New file.
29791         * tests/uniconv/test-u8-conv-to-enc.c: New file.
29792
29793         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
29794         u32_conv_to_encoding): New declarations.
29795
29796 2007-06-09  Bruno Haible  <bruno@clisp.org>
29797
29798         * tests/uniconv/test-u32-strconv-to-enc.c (main): Remove unused code.
29799
29800 2007-06-09  Bruno Haible  <bruno@clisp.org>
29801
29802         Rename 'allocsa' -> 'malloca', 'freesa' -> 'freea'.
29803         * modules/malloca: Renamed from modules/allocsa, updated.
29804         * lib/malloca.h: Renamed from lib/allocsa.h, updated.
29805         * lib/malloca.c: Renamed from lib/allocsa.c, updated.
29806         * lib/malloca.valgrind: Renamed from lib/allocsa.valgrind, updated.
29807         * m4/malloca.m4: Renamed from m4/allocsa.m4, updated.
29808         * modules/malloca-tests: Renamed from modules/allocsa-tests, updated.
29809         * tests/test-malloca.c: Renamed from tests/test-allocsa.c, updated.
29810         * modules/xmalloca: Renamed from modules/xallocsa, updated.
29811         * lib/xmalloca.h: Renamed from lib/xallocsa.h, updated.
29812         * lib/xmalloca.c: Renamed from lib/xallocsa.c, updated.
29813         * modules/c-strcasestr (Depends-on): Update.
29814         * lib/c-strcasestr.c: Update.
29815         * modules/c-strstr (Depends-on): Update.
29816         * lib/c-strstr.c: Update.
29817         * modules/canonicalize-lgpl (Depends-on): Update.
29818         * lib/canonicalize-lgpl.c: Update.
29819         * modules/clean-temp (Depends-on): Update.
29820         * lib/clean-temp.c: Update.
29821         * modules/csharpcomp (Depends-on): Update.
29822         * lib/csharpcomp.c: Update.
29823         * modules/csharpexec (Depends-on): Update.
29824         * lib/csharpexec.c: Update.
29825         * modules/javacomp (Depends-on): Update.
29826         * lib/javacomp.c: Update.
29827         * modules/javaexec (Depends-on): Update.
29828         * lib/javaexec.c: Update.
29829         * modules/mbscasestr (Depends-on): Update.
29830         * lib/mbscasestr.c: Update.
29831         * modules/mbsstr (Depends-on): Update.
29832         * lib/mbsstr.c: Update.
29833         * modules/setenv (Depends-on): Update.
29834         * lib/setenv.c: Update.
29835         * modules/strcasestr (Depends-on): Update.
29836         * lib/strcasestr.c: Update.
29837         * modules/striconveha (Depends-on): Update.
29838         * lib/striconveha.c: Update.
29839         * modules/relocatable-prog-wrapper (Files): Update.
29840         * lib/relocwrapper.c: Update.
29841         * build-aux/install-reloc: Update.
29842         * MODULES.html.sh (Memory management functions <stdlib.h>): Update.
29843
29844 2007-06-08  Bruno Haible  <bruno@clisp.org>
29845
29846         Port to uClibc.
29847         * lib/fbufmode.c (fbufmode): Add special code for uClibc.
29848         * lib/fpurge.c (fpurge): Likewise.
29849         * lib/freading.c (freading): Likewise.
29850         * lib/fseeko.c (rpl_fseeko): Likewise.
29851         * lib/fseterr.c (fseterr): Likewise.
29852         * lib/fwriting.c (fwriting): Likewise.
29853         * tests/test-fflush.c (main): Avoid a failure on uClibc.
29854
29855 2007-06-08  Bruno Haible  <bruno@clisp.org>
29856
29857         * m4/intlmacosx.m4: New file, extracted from gettext.m4.
29858         * m4/gettext.m4 (gt_INTL_MACOSX): Remove macro, moved to intlmacosx.m4.
29859         * modules/gettext (Files): Add m4/intlmacosx.m4.
29860
29861 2007-06-07  Bruno Haible  <bruno@clisp.org>
29862
29863         * modules/localename-tests: New file.
29864         * tests/test-localename.c: New file.
29865
29866         New module 'localename'.
29867         * lib/localename.h: New file.
29868         * lib/localename.c: New file, from GNU gettext.
29869         * m4/localename.m4: New file.
29870         * modules/localename: New file.
29871
29872 2007-06-07  Bruno Haible  <bruno@clisp.org>
29873
29874         Work around the lack of <wchar.h> on some builds of uClibc.
29875         * doc/headers/wchar.texi: Update.
29876         * lib/wchar_.h: Include <wchar.h> only if it exists.
29877         * m4/wchar.m4 (gl_WCHAR_H): Check for <wchar.h>. Set HAVE_WCHAR_H.
29878         * m4/stdint.m4 (gl_STDINT_H): Check for <wchar.h>.
29879         (gl_STDINT_TYPE_PROPERTIES): Don't try to include <wchar.h> if it
29880         doesn't exist.
29881         * modules/wchar (wchar.h): Substitute HAVE_WCHAR_H.
29882         * modules/mbfile (Depends-on): Add wchar.
29883         * modules/mbiter (Depends-on): Likewise.
29884         * modules/mbuiter (Depends-on): Likewise.
29885         Reported by Simon Josefsson.
29886
29887 2007-06-06  Paul Eggert  <eggert@cs.ucla.edu>
29888
29889         Work around problem reported by Steven M. Schweda in
29890         <http://lists.gnu.org/archive/html/bug-tar/2007-06/msg00002.html>:
29891         Tru64 5.1B with the Compaq compiler environment installed declares
29892         an 'isblank' function but does not define it in the C library.
29893         * lib/fnmatch.c (isblank): Check for HAVE_ISBLANK, too.
29894         * lib/regex_internal.h (isblank): Likewise.
29895         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for isblank existence.
29896         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
29897
29898 2007-06-05  Bruno Haible  <bruno@clisp.org>
29899
29900         Fix *printf so that it recognizes non-IEEE numbers on i386, x86_64,
29901         ia64.
29902         * modules/printf-safe: New file.
29903         * modules/fprintf-posix (Depends-on): Add printf-safe.
29904         * modules/printf-posix (Depends-on): Likewise.
29905         * modules/snprintf-posix (Depends-on): Likewise.
29906         * modules/sprintf-posix (Depends-on): Likewise.
29907         * modules/vasnprintf-posix (Depends-on): Likewise.
29908         * modules/vasprintf-posix (Depends-on): Likewise.
29909         * modules/vfprintf-posix (Depends-on): Likewise.
29910         * modules/vprintf-posix (Depends-on): Likewise.
29911         * modules/vsnprintf-posix (Depends-on): Likewise.
29912         * modules/vsprintf-posix (Depends-on): Likewise.
29913         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Require
29914         AC_C_BIGENDIAN. Define CHECK_PRINTF_SAFE if printf-safe is used. Test
29915         non-IEEE numbers on i386, x86_64, ia64. When cross-compiling, guess
29916         "no" on i386, x86_64, ia64.
29917         * tests/test-snprintf-posix.h (LDBL80_WORDS): New macro.
29918         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
29919         on i386, x86_64, ia64.
29920         * tests/test-sprintf-posix.h (LDBL80_WORDS): New macro.
29921         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
29922         on i386, x86_64, ia64.
29923         * tests/test-vasnprintf-posix.c: Include float.h.
29924         (LDBL80_WORDS): New macro.
29925         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
29926         on i386, x86_64, ia64.
29927         * tests/test-vasprintf-posix.c: Include float.h.
29928         (LDBL80_WORDS): New macro.
29929         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
29930         on i386, x86_64, ia64.
29931         * tests/test-snprintf-posix.c: Include float.h.
29932         * tests/test-sprintf-posix.c: Likewise.
29933         * tests/test-vsnprintf-posix.c: Likewise.
29934         * tests/test-vsprintf-posix.c: Likewise.
29935
29936 2007-06-05  Bruno Haible  <bruno@clisp.org>
29937
29938         Fix isnanl so that it recognizes non-IEEE numbers on i386, x86_64, ia64.
29939         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Require AC_C_BIGENDIAN. Test
29940         non-IEEE numbers on i386, x86_64, ia64.
29941         (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require AC_C_BIGENDIAN.
29942         * lib/isnan.c (FUNC): Add special code for i386, x86_64, ia64.
29943         * tests/test-isnanl.h: Include float.h.
29944         (main): Check also non-IEEE numbers on i386, x86_64, ia64.
29945
29946 2007-06-05  Bruno Haible  <bruno@clisp.org>
29947
29948         * lib/vasnprintf.c (VASNPRINTF): Do the extra handling of NaN and Inf
29949         also the %a / %A. Handle the %a / %A code before this extra handling.
29950
29951 2007-06-05  Bruno Haible  <bruno@clisp.org>
29952
29953         * lib/vasnprintf.c [NEED_PRINTF_LONG_DOUBLE ||
29954         NEED_PRINTF_INFINITE_LONG_DOUBLE]: Include fpucw.h.
29955
29956 2007-06-05  Bruno Haible  <bruno@clisp.org>
29957
29958         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): Fix
29959         typo in variable name.
29960
29961 2007-06-05  Eric Blake  <ebb9@byu.net>
29962
29963         * m4/lseek.m4 (gl_FUNC_LSEEK): Work when cross-compiling.
29964         Reported by Simon Josefsson.
29965
29966 2007-06-04  Bruno Haible  <bruno@clisp.org>
29967
29968         Avoid test failures on some PowerPC platforms.
29969         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP):
29970         Define differently for PowerPC.
29971         * tests/test-frexpl.c (MIN_NORMAL_EXP): Likewise.
29972         Reported by Gary V. Vaughan <gary@gnu.org>.
29973
29974 2007-06-02  Bruno Haible  <bruno@clisp.org>
29975
29976         Fix test-stdint failure on FreeBSD/ia64.
29977         * m4/stdint.m4 (gl_STDINT_H): Check the values of PTRDIFF_MIN,
29978         PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN,
29979         WCHAR_MAX, WINT_MIN, WINT_MAX entirely, not only for plausibility.
29980         * doc/headers/stdint.texi: Update.
29981
29982 2007-06-01  Bruno Haible  <bruno@clisp.org>
29983
29984         * tests/test-binary-io.c (main): Pass a third argument to open().
29985         Reported by Gary V. Vaughan <gary@gnu.org>.
29986
29987 2007-06-01  Bruno Haible  <bruno@clisp.org>
29988
29989         * doc/functions/frexpl.texi: Update for mingw.
29990
29991 2007-06-01  Bruno Haible  <bruno@clisp.org>
29992
29993         * tests/test-lseek.c (main): Disable test of errno for invalid third
29994         argument.
29995         * doc/functions/lseek.texi: Update.
29996         Reported by Gary V. Vaughan <gary@gnu.org>.
29997
29998 2007-05-28  Bruno Haible  <bruno@clisp.org>
29999
30000         * m4/intl.m4 (AM_INTL_SUBDIR): Substitute variables WOE32, WINDRES.
30001
30002 2007-05-31  Eric Blake  <ebb9@byu.net>
30003
30004         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Guess no on mingw when
30005         cross compiling.
30006
30007 2007-05-30  Eric Blake  <ebb9@byu.net>
30008         and Bruno Haible  <bruno@clisp.org>
30009
30010         Work around mingw test failures exposed by m4-1.4.9b.
30011         * m4/stdint.m4 (gl_STDINT_H): Detect mingw bug.
30012         * tests/test-unistd.c: Disable uid_t and git_t tests for the
30013         moment.
30014
30015 2007-05-30  Bruno Haible  <bruno@clisp.org>
30016
30017         * tests/test-lseek.c: Explicitly close file descriptors 0 and 1 before
30018         assuming that they are closed. Needed on HP-UX 11.
30019
30020 2007-05-29  Bruno Haible  <bruno@clisp.org>
30021
30022         Fix a problem with #include_next.
30023         * lib/dirent_.h: Split the double-inclusion guard.
30024         * lib/fcntl_.h: Likewise.
30025         * lib/float_.h: Likewise.
30026         * lib/iconv_.h: Likewise.
30027         * lib/inttypes_.h: Likewise.
30028         * lib/locale_.h: Likewise.
30029         * lib/math_.h: Likewise.
30030         * lib/netinet_in_.h: Likewise.
30031         * lib/search_.h: Likewise.
30032         * lib/signal_.h: Likewise.
30033         * lib/stdint_.h: Likewise.
30034         * lib/stdio_.h: Likewise.
30035         * lib/stdlib_.h: Likewise.
30036         * lib/string_.h: Likewise.
30037         * lib/sys_select_.h: Likewise.
30038         * lib/sys_socket_.h: Likewise.
30039         * lib/sys_stat_.h: Likewise.
30040         * lib/sys_time_.h: Likewise.
30041         * lib/sysexits_.h: Likewise.
30042         * lib/time_.h: Likewise.
30043         * lib/unistd_.h: Likewise.
30044         * lib/wchar_.h: Likewise.
30045         * lib/wctype_.h: Likewise.
30046
30047 2007-05-29  Bruno Haible  <bruno@clisp.org>
30048
30049         * tests/test-unistd.c: Disable the tests for useconds_t and intptr_t
30050         for the moment.
30051
30052 2007-05-29  Bruno Haible  <bruno@clisp.org>
30053
30054         * m4/isnan.m4 (gl_DOUBLE_EXPONENT_LOCATION): Silence the AC_C_BIGENDIAN
30055         invocation.
30056         Reported by Eric Blake.
30057
30058 2007-05-29  Bruno Haible  <bruno@clisp.org>
30059
30060         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Fix typo in cross-
30061         compiling case.
30062
30063 2007-05-29  Eric Blake  <ebb9@byu.net>
30064             Bruno Haible  <bruno@clisp.org>
30065
30066         * m4/isnanf.m4 (gl_FUNC_ISNANF_NO_LIBM): Avoid syntax error on
30067         cross compiles.
30068
30069 2007-05-28  Eric Blake  <ebb9@byu.net>
30070
30071         * modules/closein-tests (test_closein_LDADD): Support test on
30072         cygwin with libtool.
30073
30074 2007-05-28  Bruno Haible  <bruno@clisp.org>
30075
30076         * tests/uniconv/test-u16-conv-from-enc.c: Remove #ifdef HAVE_CONFIG_H.
30077         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
30078         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
30079         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
30080         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
30081         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
30082         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
30083         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
30084         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
30085
30086 2007-05-28  Eric Blake  <ebb9@byu.net>
30087
30088         Unconditionally include <config.h> in unit tests.
30089         * tests/test-alloca-opt.c: Remove #ifdef HAVE_CONFIG_H.
30090         * tests/test-allocsa.c, tests/test-arcfour.c,
30091         tests/test-arctwo.c, tests/test-argmatch.c, tests/test-argp.c,
30092         tests/test-array_list.c, tests/test-array_oset.c,
30093         tests/test-atexit.c, test-avltree_list.c, test-avltree_oset.c,
30094         test-avltreehash_list.c, test-base64.c, test-binary-io.c,
30095         test-c-ctype.c, test-c-strcasecmp.c, test-c-strcasestr.c,
30096         test-c-strncasecmp.c, test-c-strstr.c, test-canonicalize-lgpl.c,
30097         test-carray_list.c, test-crc.c, test-des.c, test-dirname.c,
30098         test-fflush.c, test-fprintf-posix.c, test-gc-arcfour.c,
30099         test-gc-arctwo.c, test-gc-des.c, test-gc-hmac-md5.c,
30100         test-gc-hmac-sha1.c, test-gc-md2.c, test-gc-md4.c, test-gc-md5.c,
30101         test-gc-pbkdf2-sha1.c, test-gc-rijndael.c, test-gc-sha1.c,
30102         test-gc.c, test-getpass.c, test-hmac-md5.c, test-hmac-sha1.c,
30103         test-iconv.c, test-linked_list.c, test-linkedhash_list.c,
30104         test-lock.c, test-mbscasecmp.c, test-mbscasestr1.c,
30105         test-mbscasestr2.c, test-mbscasestr3.c, test-mbscasestr4.c,
30106         test-mbschr.c, test-mbscspn.c, test-mbsncasecmp.c, test-mbspbrk.c,
30107         test-mbspcasecmp.c, test-mbsrchr.c, test-mbsspn.c, test-mbsstr1.c,
30108         test-mbsstr2.c, test-mbsstr3.c, test-md2.c, test-md4.c,
30109         test-md5.c, test-memmem.c, test-printf-posix.c,
30110         test-rbtree_list.c, test-rbtree_oset.c, test-rbtreehash_list.c,
30111         test-read-file.c, test-rijndael.c, test-snprintf-posix.c,
30112         test-snprintf.c, test-sprintf-posix.c, test-stdint.c,
30113         test-strcasestr.c, test-striconv.c, test-striconveh.c,
30114         test-striconveha.c, test-tls.c, test-vasnprintf-posix.c,
30115         test-vasnprintf-posix2.c, test-vasnprintf.c,
30116         test-vasprintf-posix.c, test-vasprintf.c, test-verify.c,
30117         test-vfprintf-posix.c, test-vprintf-posix.c,
30118         test-vsnprintf-posix.c, test-vsnprintf.c, test-vsprintf-posix.c,
30119         test-xvasprintf.c: Likewise.
30120
30121 2007-05-28  Bruno Haible  <bruno@clisp.org>
30122
30123         * gnulib-tool (func_import): Remember the --with-tests command-line
30124         option through the macro gl_WITH_TESTS in the gnulib-cache.m4.
30125         Reported by Eric Blake.
30126
30127 2007-05-28  Bruno Haible  <bruno@clisp.org>
30128
30129         * modules/ftell-tests: New file.
30130         * tests/test-ftell.c: New file, based on tests/test-ftello.c.
30131         * tests/test-ftell.sh: New file, based on tests/test-ftello.sh.
30132
30133         * lib/ftell.c: New file.
30134         * modules/ftell: New file.
30135         * m4/ftell.m4: New file.
30136         * doc/functions/ftell.texi: Update.
30137         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELL,
30138         REPLACE_FTELL.
30139         * lib/stdio_.h (rpl_ftell): New declaration.
30140         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELL,
30141         REPLACE_FTELL.
30142
30143 2007-05-28  Eric Blake  <ebb9@byu.net>
30144
30145         * lib/allocsa.h (safe_alloca): Avoid compiler warning.
30146
30147 2007-05-28  Bruno Haible  <bruno@clisp.org>
30148
30149         * modules/fseek-tests: New file.
30150         * tests/test-fseek.c: New file, based on tests/test-fseeko.c.
30151         * tests/test-fseek.sh: New file, based on tests/test-fseeko.sh.
30152
30153         * lib/fseek.c: New file.
30154         * modules/fseek: New file.
30155         * m4/fseek.m4: New file.
30156         * doc/functions/fseek.texi: Update.
30157         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEK,
30158         REPLACE_FSEEK.
30159         * lib/stdio_.h (rpl_fseek): New declaration.
30160         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEK,
30161         REPLACE_FSEEK.
30162
30163 2007-05-28  Bruno Haible  <bruno@clisp.org>
30164
30165         * lib/stdio_.h (fflush): More comments.
30166
30167 2007-05-28  Bruno Haible  <bruno@clisp.org>
30168
30169         * m4/lseek.m4 (gl_FUNC_LSEEK): When not cross-compiling, perform a real
30170         runtime test.
30171
30172 2007-05-28  Eric Blake  <ebb9@byu.net>
30173
30174         Improve lseek module.
30175         * lib/lseek.c (rpl_lseek): Detect EBADF on mingw.
30176         * lib/unistd_.h (lseek): Scale back link warning message.
30177         * tests/test-lseek.c: Beef up test.
30178         * tests/test-lseek.sh: Exercise more facets of lseek.
30179         Reported by Bruno Haible.
30180
30181 2007-05-28  Bruno Haible  <bruno@clisp.org>
30182
30183         * tests/test-unistd.c: Test all the types that <unistd.h> is expected
30184         to define.
30185
30186 2007-05-27  Bruno Haible  <bruno@clisp.org>
30187
30188         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-31 patch.
30189
30190 2007-05-27  Bruno Haible  <bruno@clisp.org>
30191
30192         * modules/openmp: New file.
30193         * m4/openmp.m4: New file, taken from autoconf's CVS with changes by
30194         Noah Misch.
30195
30196 2007-05-26  Bruno Haible  <bruno@clisp.org>
30197
30198         * modules/chdir-long (Depends-on): Add fchdir.
30199         * modules/chdir-safer (Depends-on): Likewise.
30200         * modules/fts (Depends-on): Likewise.
30201         * modules/fts-lgpl (Depends-on): Likewise.
30202         * modules/openat (Depends-on): Likewise.
30203         * modules/savewd (Depends-on): Likewise.
30204
30205 2007-05-24  Eric Blake  <ebb9@byu.net>
30206
30207         Fix lseek on mingw.
30208         * modules/lseek: New module.
30209         * m4/lseek.m4: New file.
30210         * lib/lseek.c: New file.
30211         * modules/lseek-tests: New file.
30212         * tests/test-lseek.c: New file.
30213         * tests/test-lseek.sh: New file.
30214         * MODULES.html.sh: Document lseek module.
30215         * modules/fflush (Depends-on): Add lseek, fseeko.
30216         * modules/fseeko (Depends-on): Likewise.
30217         * modules/ftello (Depends-on): Likewise.
30218         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Replace fseek[o] if lseek is
30219         broken.
30220         * m4/ftello.m4 (gl_FUNC_FTELLO): Replace ftell[o] if lseek is
30221         broken.
30222         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Trigger fseeko module.
30223         * lib/fseeko.c (rpl_fseeko): Quit early on non-seekable files.
30224         * lib/ftello.c (rpl_ftello): Likewise.
30225         * tests/test-fseeko.c (main): Test this.
30226         * tests/test-fseeko.sh: Likewise.
30227         * tests/test-ftello.c (main): Likewise.
30228         * tests/test-ftello.sh: Likewise.
30229         * lib/stdio_.h (fseek, ftell): Simplify, since missing fseeko now
30230         implies replacing fseek.
30231         * modules/stdio (Makefile.am): No longer need HAVE_FSEEKO,
30232         HAVE_FTELLO.
30233         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add lseek info.
30234         * modules/unistd (Makefile.am): Likewise.
30235         * lib/unistd_.h (lseek): Declare a replacement.
30236         * doc/functions/lseek.texi (lseek): Document this fix.
30237         * doc/functions/fseek.texi (fseek): Likewise.
30238         * doc/functions/ftell.texi (ftell): Likewise.
30239
30240 2007-05-24  Bruno Haible  <bruno@clisp.org>
30241
30242         * tests/test-vasnprintf-posix.c (test_function): Allow up to 50 bytes
30243         in the printed representation of a NaN.
30244         * tests/test-vasprintf-posix.c (test_function): Likewise.
30245         * tests/test-snprintf-posix.h (test_function): Likewise.
30246         * tests/test-sprintf-posix.h (test_function): Likewise.
30247         Reported by Eric Blake.
30248
30249 2007-05-23  Eric Blake  <ebb9@byu.net>
30250
30251         Fix fseeko/ftello on cygwin 1.5.24.
30252         * doc/functions/fseeko.texi (fseeko): Document the fix.
30253         * doc/functions/ftello.texi (ftello): Document the fix.
30254         * doc/functions/stdin.texi (stdin): Document the cygwin bug.
30255         * doc/functions/stdout.text (stdout): New file.
30256         * doc/functions/stderr.text (stderr): New file.
30257         * doc/gnulib.texi (Function Substitutes): Use new files.
30258         * tests/test-fseeko.c (main): Check for broken fseeko on cygwin
30259         prior to 1.7.0.
30260         * tests/test-ftello.c (main): Likewise for ftello.
30261         * tests/test-fseeko.sh: New file.
30262         * tests/test-ftello.sh: New file.
30263         * modules/fseeko-tests (Makefile.am): Ensure test-fseeko is run
30264         with seekable stdin.
30265         * modules/ftello-tests (Makefile.am): Likewise for test-ftello.
30266         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Detect the cygwin bug.
30267         (gl_REPLACE_FSEEKO): New macro.
30268         * m4/ftello.m4 (gl_FUNC_FTELLO, gl_REPLACE_FTELLO): Likewise.
30269         * modules/fseeko (Files): Distribute fseeko.c.
30270         * modules/ftello (Files): Distribute ftello.c.
30271         * lib/fseeko.c (rpl_fseeko) [__CYGWIN__]: Convert stdin to 64-bit
30272         mode.
30273         * lib/ftello.c (rpl_ftello): New file.
30274         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Allow replacement of
30275         fseeko, ftello.
30276         (gl_STDIN_LARGE_OFFSET): New macro.
30277         * modules/stdio (Makefile.am): Perform the replacement.
30278         * lib/stdio_.h (rpl_fseeko, rpl_ftello): Define when needed.
30279
30280 2007-05-23  Bruno Haible  <bruno@clisp.org>
30281
30282         * lib/stdio_.h (fseeko, ftello): Provide a link warning only if
30283         GNULIB_POSIXCHECK is defined.
30284
30285 2007-05-21  Bruno Haible  <bruno@clisp.org>
30286
30287         * m4/printf.m4 (gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE):
30288         Check also the output for NaN arguments. When cross-compiling, guess
30289         no on IRIX.
30290         * lib/vasnprintf.c: Update comments.
30291         * tests/test-vasnprintf-posix.c (strisnan): New function.
30292         (test_function): Use it.
30293         * tests/test-vasprintf-posix.c (strisnan): New function.
30294         (test_function): Use it.
30295         * tests/test-snprintf-posix.h (strisnan): New function.
30296         (test_function): Use it.
30297         * tests/test-sprintf-posix.h (strisnan): New function.
30298         (test_function): Use it.
30299         Reported by Eric Blake.
30300
30301 2007-05-20  Bruno Haible  <bruno@clisp.org>
30302
30303         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Add test for large finite
30304         numbers that fails on BeOS.
30305         * doc/functions/frexpl.texi: Update.
30306
30307 2007-05-20  Jim Meyering  <jim@meyering.net>
30308
30309         * NEWS: Mention the incompatible change (s/futimens/gl_futimens/)
30310         forced upon us by glibc-2.6.
30311
30312 2007-05-20  Bruno Haible  <bruno@clisp.org>
30313
30314         Fix *printf result for NaN, Inf on AIX, Solaris, OSF/1.
30315         * m4/printf.m4 (gl_PRINTF_INFINITE): Update cross-compiling guesses.
30316         (gl_PRINTF_INFINITE_LONG_DOUBLE): New macro.
30317         * lib/vasnprintf.c: Use NEED_PRINTF_INFINITE_DOUBLE instead of
30318         NEED_PRINTF_INFINITE.
30319         (is_infinitel): New function.
30320         (VASNPRINTF): Handle NEED_PRINTF_INFINITE_LONG_DOUBLE case.
30321         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE): Renamed from
30322         gl_PREREQ_VASNPRINTF_INFINITE.
30323         (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): New macro.
30324         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
30325         gl_PRINTF_INFINITE_LONG_DOUBLE and test its result. Invoke
30326         gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE and
30327         gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE instead of
30328         gl_PREREQ_VASNPRINTF_INFINITE.
30329         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
30330         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
30331         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
30332         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
30333         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
30334         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
30335         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
30336         * doc/functions/fprintf.texi: Update.
30337         * doc/functions/printf.texi: Update.
30338         * doc/functions/snprintf.texi: Update.
30339         * doc/functions/sprintf.texi: Update.
30340         * doc/functions/vfprintf.texi: Update.
30341         * doc/functions/vprintf.texi: Update.
30342         * doc/functions/vsnprintf.texi: Update.
30343         * doc/functions/vsprintf.texi: Update.
30344
30345 2007-05-20  Bruno Haible  <bruno@clisp.org>
30346
30347         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): Set REPLACE_FREXPL if frexpl
30348         was not found in libc.
30349         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
30350
30351 2007-05-20  Bruno Haible  <bruno@clisp.org>
30352
30353         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
30354         printed as "-nan" instead of "nan".
30355         * tests/test-vasprintf-posix.c (test_function): Likewise.
30356         * tests/test-snprintf-posix.h (test_function): Likewise.
30357         * tests/test-sprintf-posix.h (test_function): Likewise.
30358         Needed for HP-UX 11.
30359
30360 2007-05-20  Jim Meyering  <jim@meyering.net>
30361
30362         Fix buggy test for the fchownat-deref bug.
30363         * m4/openat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Create the dangling
30364         symlink required for the run-test.  Without it, this test would
30365         always declare that fchownat doesn't work, and client code would
30366         unnecessarily use the replacement function with fixed libc.
30367         (gl_FUNC_FCHOWNAT): Eliminate a variable that wasn't initialized.
30368         Reported by Greg Schafer.
30369
30370 2007-05-19  Bruno Haible  <bruno@clisp.org>
30371
30372         * m4/isnanf.m4 (gl_ISNANF_WORKS): New macro.
30373         (gl_FUNC_ISNANF_NO_LIBM): Invoke it.
30374         * lib/isnan.c (FUNC): Use run-time expressions for SGI compiler.
30375         Needed for IRIX 6.5 and Solaris 2.5.1.
30376
30377 2007-05-19  Bruno Haible  <bruno@clisp.org>
30378
30379         * tests/test-vasnprintf-posix.c (have_minus_zero): New function.
30380         (test_function): Skip tests involving -0.0 on platforms where
30381         -0.0 = 0.0.
30382         * tests/test-vasprintf-posix.c (have_minus_zero): New function.
30383         (test_function): Skip tests involving -0.0 on platforms where
30384         -0.0 = 0.0.
30385         * tests/test-snprintf-posix.h (have_minus_zero): New function.
30386         (test_function): Skip tests involving -0.0 on platforms where
30387         -0.0 = 0.0.
30388         * tests/test-sprintf-posix.h (have_minus_zero): New function.
30389         (test_function): Skip tests involving -0.0 on platforms where
30390         -0.0 = 0.0.
30391         * tests/test-fprintf-posix.h (test_function): Remove all -0.0 related
30392         tests.
30393         * tests/test-printf-posix.h (test_function): Likewise.
30394         * tests/test-printf-posix.output: Remove all -0.0 related results.
30395         Needed for IRIX 6.5.
30396
30397 2007-05-19  Bruno Haible  <bruno@clisp.org>
30398
30399         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
30400         printed as "nan0x7fffffff" instead of "nan".
30401         * tests/test-vasprintf-posix.c (test_function): Likewise.
30402         * tests/test-snprintf-posix.h (test_function): Likewise.
30403         * tests/test-sprintf-posix.h (test_function): Likewise.
30404         * tests/test-fprintf-posix.h (NaN): Remove macro.
30405         (test_function): Remove all NaN related tests.
30406         * tests/test-printf-posix.h (NaN): Remove macro.
30407         (test_function): Remove all NaN related tests.
30408         * tests/test-printf-posix.output: Remove all NaN related results.
30409         Needed for IRIX 6.5.
30410
30411 2007-05-19  Bruno Haible  <bruno@clisp.org>
30412
30413         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Fix C89 syntax error in test code.
30414         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
30415
30416 2007-05-19  Bruno Haible  <bruno@clisp.org>
30417
30418         * lib/float_.h: New file.
30419         * m4/float_h.m4: New file.
30420         * modules/float: New file.
30421         * modules/isnanl (Dependencies): Add float.
30422         * modules/isnanl-nolibm (Dependencies): Likewise.
30423         * modules/mathl (Dependencies): Likewise.
30424         * modules/printf-frexpl (Dependencies): Likewise.
30425         * modules/signbit (Dependencies): Likewise.
30426         * modules/vasnprintf (Dependencies): Likewise.
30427         * doc/headers/float.texi: Update.
30428
30429 2007-05-19  Jim Meyering  <jim@meyering.net>
30430
30431         * lib/utimens.c (gl_futimens): Rename from futimens,
30432         now that glibc-2.6 declares futimens.
30433         * lib/utimens.h: Likewise.
30434
30435 2007-05-19  Bruno Haible  <bruno@clisp.org>
30436
30437         Avoid test failures on mingw.
30438         * tests/test-fprintf-posix.sh: Convert CR/LF to LF in output.
30439         * tests/test-printf-posix.sh: Likewise.
30440         * tests/test-vfprintf-posix.sh: Likewise.
30441         * tests/test-vprintf-posix.sh: Likewise.
30442
30443 2007-05-19  Bruno Haible  <bruno@clisp.org>
30444
30445         Fix *printf result for NaN, Inf, -0.0 on mingw.
30446         * m4/printf.m4 (gl_PRINTF_INFINITE): New macro.
30447         * lib/vasnprintf.c: Include math.h and isnan.h.
30448         (is_infinite_or_zero): New function.
30449         (VASNPRINTF): Fix also the handling of infinite or zero 'double'
30450         values in the %f, %F, %e, %E, %g, %G directives.
30451         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE): New macro.
30452         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
30453         gl_PRINTF_INFINITE and test its result. Invoke
30454         gl_PREREQ_VASNPRINTF_INFINITE.
30455         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
30456         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
30457         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
30458         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
30459         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
30460         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
30461         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
30462         * doc/functions/fprintf.texi: Update.
30463         * doc/functions/printf.texi: Update.
30464         * doc/functions/snprintf.texi: Update.
30465         * doc/functions/sprintf.texi: Update.
30466         * doc/functions/vfprintf.texi: Update.
30467         * doc/functions/vprintf.texi: Update.
30468         * doc/functions/vsnprintf.texi: Update.
30469         * doc/functions/vsprintf.texi: Update.
30470
30471 2007-05-19  Bruno Haible  <bruno@clisp.org>
30472
30473         * lib/vasnprintf.c (convert_to_decimal): Add an extra_zeroes argument.
30474         (scale10_round_decimal_long_double): Inline scale10_round_long_double.
30475         Instead of multiplying with 10^k, set extra_zeroes to k.
30476         (scale10_round_long_double): Remove function.
30477
30478 2007-05-18  Bruno Haible  <bruno@clisp.org>
30479
30480         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Fix logic bug
30481         introduced on 2007-05-06.
30482
30483 2007-05-18  Bruno Haible  <bruno@clisp.org>
30484
30485         * tests/test-vasnprintf-posix.c (test_function): Also test the %e and
30486         %g directives.
30487         * tests/test-vasprintf-posix.c (test_function): Likewise.
30488         * tests/test-snprintf-posix.h (test_function): Likewise.
30489         * tests/test-sprintf-posix.h (test_function): Likewise.
30490
30491 2007-05-18  Bruno Haible  <bruno@clisp.org>
30492
30493         * tests/test-vasnprintf-posix.c (SIZEOF): New macro.
30494         (strmatch): New function.
30495         (test_function): Test the %f directive on numbers of various exponents.
30496         * tests/test-vasprintf-posix.c (SIZEOF): New macro.
30497         (strmatch): New function.
30498         (test_function): Test the %f directive on numbers of various exponents.
30499         * tests/test-snprintf-posix.h (strmatch): New function.
30500         (test_function): Test the %f directive on numbers of various exponents.
30501         * tests/test-sprintf-posix.h (strmatch): New function.
30502         (test_function): Test the %f directive on numbers of various exponents.
30503         * tests/test-snprintf-posix.c (SIZEOF): New macro.
30504         * tests/test-sprintf-posix.c (SIZEOF): New macro.
30505         * tests/test-vsnprintf-posix.c (SIZEOF): New macro.
30506         * tests/test-vsprintf-posix.c (SIZEOF): New macro.
30507
30508 2007-05-18  Bruno Haible  <bruno@clisp.org>
30509
30510         Add support for 'long double' number output.
30511         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE): New macro.
30512         * lib/vasnprintf.c: Include math.h and float+.h.
30513         (mp_limb_t): New type.
30514         (GMP_LIMB_BITS): New macro.
30515         (mp_twolimb_t): New type.
30516         (GMP_TWOLIMB_BITS): New macro.
30517         (mpn_t): New type.
30518         (multiply, divide, convert_to_decimal, decode_long_double,
30519         scale10_round_long_double, scale10_round_decimal_long_double,
30520         floorlog10l): New functions.
30521         (VASNPRINTF) [NEED_PRINTF_LONG_DOUBLE]: Implement 'long double' support
30522         for the %f, %F, %e, %E, %g, %G directives.
30523         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_LONG_DOUBLE): New macro.
30524         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
30525         gl_PRINTF_LONG_DOUBLE and test its result. Invoke
30526         gl_PREREQ_VASNPRINTF_LONG_DOUBLE.
30527         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
30528         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
30529         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
30530         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
30531         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
30532         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
30533         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
30534         * modules/fprintf-posix (Depends-on): Add frexpl-nolibm.
30535         * modules/snprintf-posix (Depends-on): Likewise.
30536         * modules/sprintf-posix (Depends-on): Likewise.
30537         * modules/vasnprintf-posix (Depends-on): Likewise.
30538         * modules/vasprintf-posix (Depends-on): Likewise.
30539         * modules/vfprintf-posix (Depends-on): Likewise.
30540         * modules/vsnprintf-posix (Depends-on): Likewise.
30541         * modules/vsprintf-posix (Depends-on): Likewise.
30542         * modules/vasnprintf (Files): Add lib/float+.h.
30543         * doc/functions/fprintf.texi: Update.
30544         * doc/functions/printf.texi: Update.
30545         * doc/functions/snprintf.texi: Update.
30546         * doc/functions/sprintf.texi: Update.
30547         * doc/functions/vfprintf.texi: Update.
30548         * doc/functions/vprintf.texi: Update.
30549         * doc/functions/vsnprintf.texi: Update.
30550         * doc/functions/vsprintf.texi: Update.
30551
30552 2007-05-18  Bruno Haible  <bruno@clisp.org>
30553
30554         * lib/vasnprintf.c (USE_SNPRINTF): Define to 0 on BeOS.
30555
30556 2007-05-18  Bruno Haible  <bruno@clisp.org>
30557
30558         * lib/vasnprintf.c (VASNPRINTF) [WIN32]: Use %I64d instead of %lld
30559         for printing 64-bit integers. Needed for mingw.
30560
30561 2007-05-18  Bruno Haible  <bruno@clisp.org>
30562
30563         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
30564         gl_FUNC_FREXPL_WORKS.
30565         * modules/printf-frexpl (Files): Add m4/frexpl.m4.
30566
30567 2007-05-18  Bruno Haible  <bruno@clisp.org>
30568
30569         * modules/frexpl-nolibm-tests: New file.
30570
30571         * modules/frexpl-nolibm: New file.
30572         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): New macro.
30573
30574 2007-05-17  Paul Eggert  <eggert@cs.ucla.edu>
30575
30576         * lib/dirent_.h: Prefer #include_next <foo.h> to #include
30577         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
30578         GCC 4.2, which otherwise issues a lot of warnings.
30579         * lib/iconv_.h, lib/locale_.h, lib/netinet_in_.h, lib/sys_select_.h:
30580         * lib/sys_socket_.h, lib/sys_stat_.h, lib/sysexits_.h, lib/unistd_.h:
30581         Likewise.
30582         * modules/fchdir (dirent.h): Substitute @HAVE_INCLUDE_NEXT@.
30583         * modules/iconv_open (iconv.h): Likewise.
30584         * modules/locale (locale.h): Likewise.
30585         * modules/netinet_in (netinet/in.h): Likewise.
30586         * modules/sys_select (sys_select.h): Likewise.
30587         * modules/sys_socket (sys/socket.h): Likewise.
30588         * modules/sys_stat (sys/stat.h): Likewise.
30589         * modules/sysexits (sysexits.h): Likewise.
30590         * modules/unistd (unistd.h): Likewise.
30591
30592 2007-05-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
30593
30594         * modules/closein-tests (Makefile.am): Distribute
30595         `test-closein.sh'.
30596
30597 2007-05-17  Bruno Haible  <bruno@clisp.org>
30598
30599         * tests/test-printf-posix.output: Renamed from
30600         tests/test-fprintf-posix.out.
30601         * modules/fprintf-posix-tests: Update.
30602         * modules/printf-posix-tests: Update.
30603         * modules/vfprintf-posix-tests: Update.
30604         * modules/vprintf-posix-tests: Update.
30605         * tests/test-fprintf-posix.sh: Update.
30606         * tests/test-printf-posix.sh: Update.
30607         * tests/test-vfprintf-posix.sh: Update.
30608         * tests/test-vprintf-posix.sh: Update.
30609         Reported by Ralf Wildenhues.
30610
30611 2007-05-16  Paul Eggert  <eggert@cs.ucla.edu>
30612
30613         * lib/fcntl_.h: Prefer #include_next <foo.h> to #include
30614         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
30615         GCC 4.2, which otherwise issues a lot of warnings.
30616         * lib/inttypes_.h, lib/math_.h, lib/search_.h, lib/signal_.h:
30617         * lib/stdint_.h, lib/stdio_.h, lib/stdlib_.h, lib/string_.h:
30618         * lib/sys_time_.h, lib/time_.h, lib/wchar_.h, lib/wctype_.h: Likewise.
30619         * lib/stdlib_.h: Don't bother with #pragma GCC system_header, as
30620         it should no longer be needed.
30621         * lib/string_.h: Likewise.
30622         * modules/absolute-header (HAVE_INCLUDE_NEXT): New 'make' define.
30623         * modules/fcntl (fcntl.h): Substitute @HAVE_INCLUDE_NEXT@.
30624         * modules/inttypes (inttypes.h): Likewise.
30625         * modules/math (math.h): Likewise.
30626         * modules/search (search.h): Likewise.
30627         * modules/signal (signal.h): Likewise.
30628         * modules/stdint (stdint.h): Likewise.
30629         * modules/stdio (stdio.h): Likewise.
30630         * modules/stdlib (stdlib.h): Likewise.
30631         * modules/string (string.h): Likewise.
30632         * modules/sys_time (sys/time.h): Likewise.
30633         * modules/time (time.h): Likewise.
30634         * modules/wchar (wchar.h): Likewise.
30635         * modules/wctype (wtype.h): Likewise.
30636
30637 2007-05-16  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
30638
30639         * doc/gnulib-tool.texi (CVS Issues): Fix typo.
30640
30641 2007-05-13  Bruno Haible  <bruno@clisp.org>
30642
30643         * stpcpy.m4 (gl_FUNC_STPCPY): Require AC_C_RESTRICT.
30644         * stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
30645         * strsep.m4 (gl_FUNC_STRSEP): Likewise.
30646         * strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
30647         (gl_PREREQ_STRTOK_R): Don't require it here.
30648
30649 2007-05-13  Bruno Haible  <bruno@clisp.org>
30650
30651         * lib/stdlib_.h (mkdtemp, mkstemp): Comment out argument name. Needed
30652         when used in C++ mode.
30653
30654 2007-05-12  Bruno Haible  <bruno@clisp.org>
30655
30656         * lib/linebuffer.h: Tweak doc.
30657         * lib/linebuffer.c: Likewise.
30658
30659 2007-05-12  James Youngman  <jay@gnu.org>
30660
30661         * lib/linebuffer.c (readlinebuffer_delim): New function,
30662         like readlinebuffer, but use a caller-specified delimiter.
30663         (readlinebuffer): Just call readlinebuffer_delim with '\n'
30664         as the delimiter.
30665         * lib/linebuffer.h (readlinebuffer_delim): Declare it.
30666
30667 2007-05-12  Sergey Poznyakoff  <gray@gnu.org.ua>
30668
30669         * m4/openat.m4 (gl_FUNC_OPENAT): Do not require openat-die.
30670         * modules/openat (Files): Remove openat-die.c.
30671         (Depends-on): Add openat-die.
30672         * modules/openat-die: New module.
30673
30674 2007-05-06  Bruno Haible  <bruno@clisp.org>
30675
30676         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING, gl_VSNPRINTF_ZEROSIZE_C99):
30677         Update with info about Cygwin.
30678         * doc/functions/fprintf.texi: Update.
30679         * doc/functions/printf.texi: Update.
30680         * doc/functions/snprintf.texi: Update.
30681         * doc/functions/sprintf.texi: Update.
30682         * doc/functions/vfprintf.texi: Update.
30683         * doc/functions/vprintf.texi: Update.
30684         * doc/functions/vsnprintf.texi: Update.
30685         * doc/functions/vsprintf.texi: Update.
30686         Reported by Eric Blake.
30687
30688 2007-05-06  Bruno Haible  <bruno@clisp.org>
30689
30690         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Perform the
30691         padding ourselves for the floating-point directives.
30692         * m4/printf.m4 (gl_PRINTF_FLAG_ZERO): New macro.
30693         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ZERO): New macro.
30694         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
30695         gl_PRINTF_FLAG_ZERO and test its result. Invoke
30696         gl_PREREQ_VASNPRINTF_FLAG_ZERO.
30697         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
30698         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
30699         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
30700         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
30701         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
30702         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
30703         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
30704         * tests/test-snprintf-posix.h (test_function): Also check the width
30705         and some flags in the %f directive.
30706         * tests/test-sprintf-posix.h (test_function): Likewise.
30707         * tests/test-vasnprintf-posix.c (test_function): Likewise.
30708         * tests/test-vasprintf-posix.c (test_function): Likewise.
30709         * doc/functions/fprintf.texi: Update.
30710         * doc/functions/printf.texi: Update.
30711         * doc/functions/snprintf.texi: Update.
30712         * doc/functions/sprintf.texi: Update.
30713         * doc/functions/vfprintf.texi: Update.
30714         * doc/functions/vprintf.texi: Update.
30715         * doc/functions/vsnprintf.texi: Update.
30716         * doc/functions/vsprintf.texi: Update.
30717
30718 2007-05-06  Bruno Haible  <bruno@clisp.org>
30719
30720         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_GROUPING]: Don't
30721         pass the ' flag character to sprintf or snprintf.
30722         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING): New macro.
30723         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_GROUPING): New macro.
30724         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
30725         gl_PRINTF_FLAG_GROUPING and test its result. Invoke
30726         gl_PREREQ_VASNPRINTF_FLAG_GROUPING.
30727         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
30728         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
30729         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
30730         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
30731         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
30732         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
30733         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
30734         * tests/test-snprintf-posix.h (test_function): Also check the grouping
30735         flag.
30736         * tests/test-sprintf-posix.h (test_function): Likewise.
30737         * tests/test-vasnprintf-posix.c (test_function): Likewise.
30738         * tests/test-vasprintf-posix.c (test_function): Likewise.
30739         * doc/functions/fprintf.texi: Update.
30740         * doc/functions/printf.texi: Update.
30741         * doc/functions/snprintf.texi: Update.
30742         * doc/functions/sprintf.texi: Update.
30743         * doc/functions/vfprintf.texi: Update.
30744         * doc/functions/vprintf.texi: Update.
30745         * doc/functions/vsnprintf.texi: Update.
30746         * doc/functions/vsprintf.texi: Update.
30747
30748 2007-05-01  Bruno Haible  <bruno@clisp.org>
30749
30750         * tests/test-argp-2.sh (func_compare): Drop .exe suffix.
30751
30752 2007-05-03  Paul Eggert  <eggert@cs.ucla.edu>
30753
30754         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use better
30755         comment for D_INO_IN_DIRENT.  Problem reported by James Youngman.
30756
30757 2007-05-02  Paul Eggert  <eggert@cs.ucla.edu>
30758
30759         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Test whether
30760         readdir returns garbage in d_ino.  Problem reported by Kaz Sasayama in
30761         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00021.html>.
30762
30763 2007-05-02  Sergey Poznyakoff  <gray@gnu.org.ua>
30764
30765         * lib/argp-help.c (struct hol_entry): New member `ord'.
30766         (HOL_ENTRY_PTRCMP): Use ord for comparison
30767         (hol_sort): Initialize ord.
30768
30769 2007-05-01  Bruno Haible  <bruno@clisp.org>
30770
30771         * doc/functions/_Exit_C99.texi: Renamed from doc/functions/_Exit.texi.
30772         Reported by Eric Blake.
30773         * doc/gnulib.texi (Function Substitutes): Update.
30774
30775 2007-05-01  Bruno Haible  <bruno@clisp.org>
30776
30777         * doc/functions.texi: Remove file, now redundant through
30778         doc/functions/*.texi.
30779
30780 2007-05-01  Bruno Haible  <bruno@clisp.org>
30781
30782         * modules/argp (Depends-on): Add sleep.
30783
30784 2007-05-01  Bruno Haible  <bruno@clisp.org>
30785
30786         * modules/sleep-tests: New file.
30787         * tests/test-sleep.c: New file.
30788
30789         * modules/sleep: New file.
30790         * lib/sleep.c: New file.
30791         * m4/sleep.m4: New file.
30792         * lib/unistd_.h (sleep): New declaration.
30793         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_SLEEP,
30794         HAVE_SLEEP.
30795         * modules/unistd (Makefile.am): Substitute GNULIB_SLEEP, HAVE_SLEEP.
30796         * doc/functions/sleep.texi: Document the sleep module.
30797
30798 2007-05-01  Bruno Haible  <bruno@clisp.org>
30799
30800         * lib/sigprocmask.h: Remove file.
30801         * lib/signal_.h: Incorporate the previous contents of sigprocmask.h.
30802         * lib/sigprocmask.c: Include <signal.h> instead of sigprocmask.h.
30803         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Substitute GNULIB_SIGPROCMASK,
30804         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T.
30805         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
30806         gl_SIGNAL_H_DEFAULTS. Set HAVE_POSIX_SIGNALBLOCKING as a shell variable.
30807         (gl_PREREQ_SIGPROCMASK): Require gl_SIGNAL_H_DEFAULTS. Set
30808         HAVE_SIGSET_T as a shell variable.
30809         * modules/signal (Makefile.am): Substitute GNULIB_SIGPROCMASK,
30810         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T into signal.h.
30811         * modules/sigprocmask (Files): Remove lib/sigprocmask.h.
30812         (Depends-on): Add signal. Remove verify.
30813         (configure.ac): Invoke gl_SIGNAL_MODULE_INDICATOR.
30814         (Include): Mention <signal.h> instead of sigprocmask.h.
30815         * NEWS: Mention the change.
30816         * lib/fatal-signal.c: Don't include sigprocmask.h.
30817
30818 2007-05-01  Bruno Haible  <bruno@clisp.org>
30819
30820         * modules/signal: New file.
30821         * lib/signal_.h: New file.
30822         * m4/signal_h.m4: New file.
30823
30824 2007-05-01  Bruno Haible  <bruno@clisp.org>
30825
30826         * lib/wctype_.h: Test HAVE_ISWCNTRL at configure time.
30827         * m4/wctype.m4 (gl_WCTYPE_H): Substitute HAVE_ISWCNTRL.
30828         * modules/wctype (Makefile.am): Substitute HAVE_ISWCNTRL instead of
30829         HAVE_WCTYPE_CTMP_BUG into wctype.h.
30830
30831 2007-05-01  Bruno Haible  <bruno@clisp.org>
30832
30833         * lib/sys_stat_.h: Test HAVE_LSTAT, HAVE_DECL_MKDIR, HAVE_IO_H at
30834         configure time.
30835         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Substitute HAVE_LSTAT,
30836         HAVE_DECL_MKDIR, HAVE_IO_H via AC_SUBST.
30837         * modules/sys_stat (Makefile.am): Substitute their values into
30838         sys/stat.h.
30839
30840 2007-05-01  Bruno Haible  <bruno@clisp.org>
30841
30842         * lib/glob_.h: Test HAVE_SYS_CDEFS_H at configure time.
30843         * m4/glob.m4 (gl_PREREQ_GLOB): Substitute HAVE_SYS_CDEFS_H via AC_SUBST.
30844         * modules/glob (Makefile.am): Put HAVE_SYS_CDEFS_H value into glob.h.
30845
30846 2007-05-01  Bruno Haible  <bruno@clisp.org>
30847
30848         * doc/header/assert.texi: Undo last change: don't mention the gnulib
30849         'assert' module here.
30850
30851 2007-05-01  Bruno Haible  <bruno@clisp.org>
30852
30853         * doc/functions/*.texi: New files.
30854         * doc/functions/google-ranking.txt: New file.
30855         * doc/gnulib.texi (Function Substitutes): New chapter.
30856         (ctime, inet_ntoa): Remove sections.
30857         * doc/ctime.texi: Remove file.
30858         * doc/inet_ntoa.texi: Remove file.
30859         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Update
30860         dependencies.
30861         (%.info): New rule, specifying a --reference-limit.
30862
30863 2007-05-01  Bruno Haible  <bruno@clisp.org>
30864
30865         * MODULES.html.sh (posix_functions): Remove 'exec', 'toc'.
30866
30867 2007-05-01  Bruno Haible  <bruno@clisp.org>
30868
30869         * modules/mkdir (Depends-on): Add sys_stat, because sys_stat provides
30870         the portability of 'mkdir' to mingw systems.
30871
30872 2007-05-01  Bruno Haible  <bruno@clisp.org>
30873
30874         * doc/headers/google-ranking.txt: New file.
30875
30876 2007-04-30  Eric Blake  <ebb9@byu.net>
30877
30878         Prefer fseeko to fseek.
30879         * modules/getpass (Depends-on): Add fseeko.
30880         * lib/getpass.c (getpass): Use fseeko, not fseek.
30881
30882 2007-04-30  Sergey Poznyakoff  <gray@gnu.org.ua>
30883
30884         * lib/argp-help.c (hol_entry_cmp): Option sorting algorithm
30885         assumes the sorting is stable, while most qsort implementations
30886         are not.  Use argument addresses to ensure they never compare as
30887         equal.
30888
30889         * tests/test-argp-2.sh (usage-indent test): Fix output
30890         (func_compare): Restore diff options
30891         * tests/test-argp.c: Restore #include "progname.h"
30892
30893 2007-04-29  Bruno Haible  <bruno@clisp.org>
30894
30895         * m4/printf.m4 (gl_VSNPRINTF_ZEROSIZE_C99): New macro.
30896         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
30897         gl_VSNPRINTF_ZEROSIZE_C99. Test gl_cv_func_vsnprintf_zerosize_c99.
30898         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
30899         * modules/snprintf-posix-tests (Files): Add tests/test-snprintf.c.
30900         (configure.ac): Define CHECK_SNPRINTF_POSIX.
30901         (TESTS, check_PROGRAMS): Add test-snprintf.
30902         * modules/vsnprintf-posix-tests (Files): Add tests/test-vsnprintf.c.
30903         (configure.ac): Define CHECK_VSNPRINTF_POSIX.
30904         (TESTS, check_PROGRAMS): Add test-vsnprintf.
30905         * tests/test-snprintf.c (main) [!CHECK_SNPRINTF_POSIX]: Disable
30906         assertions that fail on HP-UX, OSF/1, or IRIX.
30907         * tests/test-vsnprintf.c (main) [!CHECK_VSNPRINTF_POSIX]: Likewise.
30908
30909 2007-04-29  Bruno Haible  <bruno@clisp.org>
30910
30911         * MODULES.html.sh (posix_functions): Remove 'contents'.
30912
30913 2007-04-29  Karl Berry  <karl@gnu.org>
30914
30915         * config/srclist.txt (gendocs_template_min): new entry.
30916
30917 2007-04-29  Bruno Haible  <bruno@clisp.org>
30918
30919         Work around fpurge bug on BSD systems.
30920         * modules/fpurge (Makefile.am): Compile fpurge.c unconditionally.
30921         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't invoke AC_LIBOBJ.
30922         * lib/fpurge.h (fpurge): Don't handle __fpurge wrapper here. Define
30923         fpurge to rpl_fpurge if the system already has this function.
30924         * lib/fpurge.c (fpurge): Handle also the __fpurge wrapper case and
30925         the case where the system already has this function. Correct invariants
30926         on BSD systems.
30927         * lib/fseeko.c (rpl_fseeko): Update recognition of preceding fflush on
30928         BSD systems.
30929
30930 2007-04-29  Sergey Poznyakoff  <gray@gnu.org.ua>
30931
30932         * lib/argp-help.c (hol_cluster_cmp): Reverse comparison.  Change
30933         proposed by Sven Verdoolaege.
30934
30935         * tests/test-argp.c: Fix option ordering.  Test deeply clustered
30936         options.
30937         * tests/test-argp-2.sh (func_compare): Use diff instead of cmp.
30938         (usage and help tests): Update
30939
30940 2007-04-29  Bruno Haible  <bruno@clisp.org>
30941
30942         * tests/test-fflush.c (main): Use a file of size 17, not 10.
30943         Print more information in case of failure. Disable a test on BeOS.
30944
30945 2007-04-29  Bruno Haible  <bruno@clisp.org>
30946
30947         * tests/**/test-*.[hc] (ASSERT): Use fprintf to show the line number.
30948         This helps debugging on systems on which no gdb is available.
30949
30950 2007-04-29  Bruno Haible  <bruno@clisp.org>
30951
30952         * lib/freading.h: Improve comments.
30953         * lib/fwriting.h: Likewise.
30954         * tests/test-freading.c (main): Don't check freading immediately after
30955         repositioning. Needed for glibc.
30956
30957 2007-04-29  Bruno Haible  <bruno@clisp.org>
30958
30959         * lib/freading.c (freading): Trivial simplification.
30960
30961 2007-04-28  Bruno Haible  <bruno@clisp.org>
30962
30963         * tests/test-fwriting.c (main): Also test the interaction between
30964         fflush and fwriting.
30965         * modules/fwriting-tests (Depends-on): Add fflush.
30966
30967         * tests/test-freading.c (main): Also test the interaction between
30968         fflush and freading.
30969         * modules/freading-tests (Depends-on): Add fflush.
30970
30971 2007-04-28  Bruno Haible  <bruno@clisp.org>
30972
30973         * lib/stdio_.h (fseek, ftell): Provide link warnings suggesting to use
30974         fseeko and ftello.
30975         Suggested by Eric Blake.
30976
30977 2007-04-28  Jim Meyering  <jim@meyering.net>
30978
30979         Avoid false-negative in gl_STDINT_H's C99 conformance test.
30980         * m4/stdint.m4 (gl_STDINT_H): When checking whether stdint.h conforms
30981         to C99, include all of gl_STDINT_INCLUDES, not just <stddef.h>.
30982
30983 2007-04-27  Eric Blake  <ebb9@byu.net>
30984
30985         * doc/headers/assert.texi (assert.h): Document assert module use.
30986
30987 2007-04-27  Bruno Haible  <bruno@clisp.org>
30988
30989         * doc/headers/*.texi: New files.
30990         * doc/gnulib.texi (Header File Substitutes): New chapter.
30991         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Specify
30992         dependencies.
30993         (standards.info ,standards.html, standards.dvi): Update dependencies.
30994         (mostlyclean, clean): New targets.
30995
30996 2007-04-27  Bruno Haible  <bruno@clisp.org>
30997
30998         * lib/sysexits_.h: Renamed from lib/sysexit_.h.
30999         * modules/sysexits (Files, Makefile.am): Update.
31000
31001         * lib/sys_socket_.h: Renamed from lib/socket_.h.
31002         * modules/sys_socket (Files, Makefile.am): Update.
31003
31004         * lib/sys_stat_.h: Renamed from lib/stat_.h.
31005         * modules/sys_stat (Files, Makefile.am): Update.
31006
31007 2007-04-27  Eric Blake  <ebb9@byu.net>
31008
31009         * lib/freading.h: Improve comments.
31010         * lib/fwriting.h: Likewise.
31011         * lib/fflush.c: Likewise.
31012
31013         Fix closein for mingw.
31014         * modules/closein-tests: Add tests for closein.
31015         * tests/test-closein.c: New file.
31016         * tests/test-closein.sh: Likewise.
31017         * lib/unistd_.h [!SEEK_CUR]: Mingw also needs stdlib.h for _exit.
31018         * lib/closein.c (close_stdin): Don't fflush non-seekable streams.
31019
31020 2007-04-27  Bruno Haible  <bruno@clisp.org>
31021
31022         * lib/inttypes_.h [_DECC]: Don't use #include_next if the compiler
31023         version is < 6.
31024         * lib/math_.h [__DECC]: Likewise.
31025         * lib/stdio_.h [__DECC]: Likewise.
31026         * lib/stdlib_.h [__DECC]: Likewise.
31027         * lib/string_.h [__DECC]: Likewise.
31028         * lib/time_.h [__DECC]: Likewise.
31029         * lib/wchar_.h [__DECC]: Likewise.
31030         * lib/wctype_.h [__DECC]: Likewise.
31031
31032 2007-04-27  Bruno Haible  <bruno@clisp.org>
31033
31034         * tests/test-fbufmode.c (main): Relax test, to avoid failure on mingw.
31035
31036 2007-04-27  Bruno Haible  <bruno@clisp.org>
31037
31038         * lib/fflush.c: Add comments.
31039         * modules/fpurge-tests (Depends-on): Add fflush.
31040         * modules/freadable-tests (Depends-on): Likewise.
31041         * modules/fwritable-tests (Depends-on): Likewise.
31042
31043 2007-04-27  Charles Wilson  <libtool@cwilson.fastmail.fm>
31044
31045         * m4/argz.m4 (gl_FUNC_ARGZ): Use !HAVE_WORKING_ARGZ instead of
31046         SYSTEM_ARGZ_IS_BROKEN.  Also, minor stylistic improvements.
31047         Report by Bruno Haible <bruno@clisp.org>.
31048
31049 2007-04-26  Eric Blake  <ebb9@byu.net>
31050
31051         Fix fflush on mingw.
31052         * modules/fflush (Depends-on): Add freading.
31053         * lib/fflush.c (rpl_fflush): Use freading to avoid losing buffered
31054         but unread data.
31055
31056 2007-04-26  Eric Blake  <ebb9@byu.net>
31057         and Bruno Haible  <bruno@clisp.org>
31058
31059         Implement freading and fwriting.
31060         * lib/freading.c: New file.
31061         * lib/freading.h: Likewise.
31062         * m4/freading.m4: Likewise.
31063         * modules/freading: Likewise.
31064         * modules/freading-tests: Likewise.
31065         * tests/test-freading.c: Likewise.
31066         * lib/fwriting.c: New file.
31067         * lib/fwriting.h: Likewise.
31068         * m4/fwriting.m4: Likewise.
31069         * modules/fwriting: Likewise.
31070         * modules/fwriting-tests: Likewise.
31071         * tests/test-fwriting.c: Likewise.
31072         * MODULES.html.sh (File stream based Input/Output): Mention them.
31073
31074 2007-04-26  Bruno Haible  <bruno@clisp.org>
31075
31076         * lib/stdio_.h (fseeko, ftello): Check that off_t has the same size as
31077         'long' when we assume it.
31078         Suggested by Eric Blake.
31079
31080 2007-04-26  Bruno Haible  <bruno@clisp.org>
31081
31082         Ensure fseeko, ftello are declared on glibc systems.
31083         * modules/fflush (configure.ac-early): Require AC_FUNC_FSEEKO.
31084         * modules/fseeko (configure.ac-early): Likewise.
31085         * modules/ftello (configure.ac-early): Likewise.
31086         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't define HAVE_FSEEKO, rely on
31087         AC_FUNC_FSEEKO for this.
31088         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Inline gl_CHECK_FSEEKO.
31089         (gl_CHECK_FSEEKO): Remove macro.
31090
31091 2007-04-26  Bruno Haible  <bruno@clisp.org>
31092
31093         * tests/test-fflush.c (main): Also check the ftell result after
31094         fflush and fseek/fseeko.
31095         * lib/fflush.c (rpl_fflush): For BSD implementations, update the
31096         file descriptor position cache in the stream.
31097         * lib/fseeko.c (rpl_fseeko): Likewise.
31098
31099 2007-04-26  Bruno Haible  <bruno@clisp.org>
31100
31101         * modules/fflush-tests (Depends-on): Add fseeko.
31102
31103 2007-04-25  Charles Wilson  <libtool@cwilson.fastmail.fm>
31104             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
31105
31106         * lib/argz_.h: ensure error_t definition is obtained in same
31107         mechanism system argz.h would have.
31108         * m4/argz.m4 (gl_FUNC_ARGZ): add new test to check if $host's
31109         argz facilities are known bad.  Err on the side of caution if
31110         cross-compiling.
31111
31112 2007-04-25  Eric Blake  <ebb9@byu.net>
31113
31114         * lib/fpurge.c (includes): Use stdlib.h for free.
31115         * tests/test-fflush.c (main): Also test fflush-fseeko.
31116
31117 2007-04-25  Bruno Haible  <bruno@clisp.org>
31118
31119         Make fflush+fseek POSIX-compliant on FreeBSD and MacOS X.
31120         * lib/fseeko.c: New file.
31121         * lib/stdio_.h: Include <sys/types.h> when off_t is needed.
31122         (fseeko, fseek): Define to replacements if REPLACE_FFLUSH.
31123         * m4/fseeko.m4 (gl_CHECK_FSEEKO): New macro, extracted from
31124         gl_FUNC_FSEEKO.
31125         (gl_FUNC_FSEEKO): Invoke it.
31126         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Arrange to compile fseeko.c. Invoke
31127         gl_CHECK_FSEEKO. Define HAVE_FSEEKO.
31128         * modules/fflush (Files): Add lib/fseeko.c, m4/fseeko.m4.
31129
31130 2007-04-25  Bruno Haible  <bruno@clisp.org>
31131
31132         * modules/fflush (Depends-on): Add ftello.
31133
31134 2007-04-25  Bruno Haible  <bruno@clisp.org>
31135
31136         * modules/ftello-tests: New file.
31137         * tests/test-ftello.c: New file.
31138
31139         * modules/ftello: New file.
31140         * m4/ftello.m4: New file.
31141         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELLO,
31142         HAVE_FTELLO.
31143         * lib/stdio_.h (ftello): New declaration.
31144         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELLO,
31145         HAVE_FTELLO.
31146
31147 2007-04-25  Bruno Haible  <bruno@clisp.org>
31148
31149         * modules/fseeko-tests: New file.
31150         * tests/test-fseeko.c: New file.
31151
31152         * modules/fseeko: New file.
31153         * m4/fseeko.m4: New file.
31154         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEKO,
31155         HAVE_FSEEKO.
31156         * lib/stdio_.h (fseeko): New declaration.
31157         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEKO,
31158         HAVE_FSEEKO.
31159
31160 2007-04-25  Bruno Haible  <bruno@clisp.org>
31161
31162         * lib/stdio_.h (fflush): Add support for GNULIB_POSIXCHECK.
31163
31164 2007-04-25  Bruno Haible  <bruno@clisp.org>
31165
31166         * lib/unistd_.h: Include <stdio.h> if needed to get the SEEK_* macros.
31167         * tests/test-stdio.c: Check that the various SEEK_* macros are defined.
31168         * tests/test-unistd.c: Likewise.
31169         * tests/test-fcntl.c: Likewise.
31170
31171 2007-04-23  Eric Blake  <ebb9@byu.net>
31172
31173         * lib/fflush.c: Fix missing include.
31174         Reported by Bruno Haible.
31175
31176 2007-04-23  Bruno Haible  <bruno@clisp.org>
31177
31178         * lib/fpurge.c (fpurge) [glibc, BSD]: Free a malloc()ed ungetc buffer.
31179         Reported by Eric Blake.
31180
31181 2007-04-23  Bruno Haible  <bruno@clisp.org>
31182
31183         * lib/fbufmode.c (fbufmode): Port to Solaris/SPARC64.
31184
31185 2007-04-23  Bruno Haible  <bruno@clisp.org>
31186
31187         * lib/fseterr.c (fseterr): Don't hardcode the value of _IOERR.
31188
31189 2007-04-23  Bruno Haible  <bruno@clisp.org>
31190
31191         * tests/test-fbufmode.c (main): Be prepared to a failure of setvbuf.
31192         Needed on HP-UX 11.
31193
31194 2007-04-16  Eric Blake  <ebb9@byu.net>
31195
31196         Make fflush rely on fpurge.
31197         * lib/fflush.c (rpl_fflush): Rely on fpurge module, rather than
31198         open coding all variants.
31199         * modules/fflush (Depends-on): Add fpurge and unistd.
31200         * modules/fflush-tests (Depends-on): Unistd is no longer extra.
31201         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Simplify.
31202
31203         Fix --with-tests compilation on cygwin.
31204         * modules/argmatch-tests (Makefile.am): List gnulib library first
31205         in LDADD.
31206         * modules/argp-tests (Makefile.am): Likewise.
31207         * modules/array-list-tests (Makefile.am): Likewise.
31208         * modules/array-oset-tests (Makefile.am): Likewise.
31209         * modules/avltree-list-tests (Makefile.am): Likewise.
31210         * modules/avltree-oset-tests (Makefile.am): Likewise.
31211         * modules/avltreehash-list-tests (Makefile.am): Likewise.
31212         * modules/carray-list-tests (Makefile.am): Likewise.
31213         * modules/dirname-tests (Makefile.am): Likewise.
31214         * modules/frexp-tests (Makefile.am): Likewise.
31215         * modules/isnanl-tests (Makefile.am): Likewise.
31216         * modules/linked-list-tests (Makefile.am): Likewise.
31217         * modules/linkedhash-list-tests (Makefile.am): Likewise.
31218         * modules/lock-tests (Makefile.am): Likewise.
31219         * modules/rbtree-list-tests (Makefile.am): Likewise.
31220         * modules/rbtree-oset-tests (Makefile.am): Likewise.
31221         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
31222         * modules/tls-tests (Makefile.am): Likewise.
31223         * modules/tsearch-tests (Makefile.am): Likewise.
31224         * modules/xvasprintf-tests (Makefile.am): Likewise.
31225
31226         Fix fpurge for cygwin.
31227         * lib/fpurge.c (fpurge): Fix order of operation flub, and return a
31228         value.
31229         * modules/fpurge-tests (Depends-on): Clean up trash.
31230
31231 2007-04-16  Simon Josefsson  <simon@josefsson.org>
31232
31233         * lib/gc-libgcrypt.c (gc_hash_open): Shut up compiler warnings.
31234
31235         * m4/autobuild.m4: Re-indent.
31236
31237 2007-04-13  Bruno Haible  <bruno@clisp.org>
31238
31239         * modules/fpurge-tests: New file.
31240         * tests/test-fpurge.c: New file.
31241
31242         * modules/fpurge: New file.
31243         * lib/fpurge.h: New file.
31244         * lib/fpurge.c: New file.
31245         * m4/fpurge.m4: New file.
31246
31247 2007-04-13  Bruno Haible  <bruno@clisp.org>
31248
31249         * modules/fbufmode-tests: New file.
31250         * tests/test-fbufmode.c: New file.
31251
31252         * modules/fbufmode: New file.
31253         * lib/fbufmode.h: New file.
31254         * lib/fbufmode.c: New file.
31255         * m4/fbufmode.m4: New file.
31256
31257 2007-04-13  Bruno Haible  <bruno@clisp.org>
31258
31259         * modules/fwritable-tests: New file.
31260         * tests/test-fwritable.c: New file.
31261
31262         * modules/fwritable: New file.
31263         * lib/fwritable.h: New file.
31264         * lib/fwritable.c: New file.
31265         * m4/fwritable.m4: New file.
31266
31267 2007-04-13  Bruno Haible  <bruno@clisp.org>
31268
31269         * modules/freadable-tests: New file.
31270         * tests/test-freadable.c: New file.
31271
31272         * modules/freadable: New file.
31273         * lib/freadable.h: New file.
31274         * lib/freadable.c: New file.
31275         * m4/freadable.m4: New file.
31276
31277 2007-04-13  Bruno Haible  <bruno@clisp.org>
31278
31279         * modules/fflush-tests (Makefile.am): Remove EXTRA_DIST. Augment
31280         MOSTLYCLEANFILES.
31281
31282 2007-04-13  Paul Eggert  <eggert@cs.ucla.edu>
31283
31284         * build-aux/bootstrap (gnulib_tool_option_extras): New var, used by
31285         gzip bootstrap.conf to avoid dragging in i18n machinery.
31286         (gnulib_tool_option): Use it.
31287
31288 2007-04-13  Bruno Haible  <bruno@clisp.org>
31289
31290         * tests/test-vasnprintf-posix.c (test_function): Add tests for %f and
31291         %F directives.
31292         * tests/test-vasprintf-posix.c (test_function): Likewise.
31293         * tests/test-snprintf-posix.h (test_function): Likewise.
31294         * tests/test-sprintf-posix.h (test_function): Likewise.
31295         * tests/test-fprintf-posix.h (test_function): Likewise.
31296         * tests/test-printf-posix.h (test_function): Likewise.
31297         * tests/test-fprintf-posix.out: Likewise.
31298
31299 2007-04-13  Bruno Haible  <bruno@clisp.org>
31300
31301         * modules/lock-tests (configure.ac): For LIBSCHED, try also -lposix4.
31302         * modules/tls-tests (configure.ac): Likewise.
31303         Reported by Arto C. Nirkko <anirkko@insel.ch>.
31304
31305 2007-04-13  Bruno Haible  <bruno@clisp.org>
31306
31307         * lib/tls.c (glthread_tls_get): Fix return type.
31308         Patch by Arto C. Nirkko <anirkko@insel.ch>.
31309
31310 2007-04-12  Eric Blake  <ebb9@byu.net>
31311
31312         * modules/gettime (Depends-on): Remove gettime.
31313         Reported by Dmitry V. Levin.
31314
31315 2007-04-12  Bruno Haible  <bruno@clisp.org>
31316
31317         * modules/fflush (Include): Mention <stdio.h>.
31318         * modules/strtoimax (Include): Mention <inttypes.h>.
31319         * modules/strtoumax (Include): Likewise.
31320
31321 2007-04-12  Eric Blake  <ebb9@byu.net>
31322
31323         * .cvsignore: New file.
31324         * .gitignore: Likewise.
31325
31326 2007-04-12  Bruno Haible  <bruno@clisp.org>
31327
31328         * modules/iconv-tests (test_iconv_LDADD): Mention -liconv after LDADD,
31329         not before, since $(LDADD) often contains libgnu.a.
31330         * modules/striconv-tests (test_striconv_LDADD): Likewise.
31331         * modules/striconveh-tests (test_striconveh_LDADD): Likewise.
31332         * modules/striconveha-tests (test_striconveha_LDADD): Likewise.
31333         Needed on Cygwin.
31334
31335 2007-04-12  Eric Blake  <ebb9@byu.net>
31336
31337         Work around glibc's failure to flush stdin on fclose.
31338         * lib/closein.c (close_stdin): Flush stdin before closing.
31339
31340         Work around glibc's failure to reset seekable stdin on exit.
31341         * modules/closein: New module.
31342         * lib/closein.c: New file.
31343         * lib/closein.h: Likewise.
31344         * m4/closein.m4: Likewise.
31345         * MODULES.html.sh (File stream based Input/Output): Document it.
31346
31347 2007-04-12  Simon Josefsson  <simon@josefsson.org>
31348
31349         * gnulib-tool: Rename generated 'autobuild' script to
31350         'do-autobuild' in --create-megatestdir output.
31351
31352         * doc/gnulib.texi (Build robot for gnulib): Fix.
31353
31354 2007-04-12  Simon Josefsson  <simon@josefsson.org>
31355
31356         * modules/sysexits (Depends-on): Add absolute-header.
31357
31358 2007-04-12  Eric Blake  <ebb9@byu.net>
31359
31360         No need to preserve errno on success.
31361         * lib/fflush.c (rpl_fflush): Simplify errno tracking.
31362         Reported by Bruno Haible.
31363
31364 2007-04-12  Simon Josefsson  <simon@josefsson.org>
31365
31366         * MODULES.html.sh (Support for maintaining and releasing
31367         projects): Add autobuild.  Suggested by Eric Blake <ebb9@byu.net>.
31368
31369 2007-04-12  Simon Josefsson  <simon@josefsson.org>
31370
31371         * gnulib-tool (func_modules_add_dummy): Respect --avoid=dummy.
31372
31373 2007-04-12  Simon Josefsson  <simon@josefsson.org>
31374
31375         * modules/autobuild: New module.
31376
31377         * m4/autobuild.m4: New file.
31378
31379 2007-04-11  Bruno Haible  <bruno@clisp.org>
31380
31381         * lib/vasnprintf.c (VASNPRINTF): Implement the %F directive using the
31382         %f directive, if NEED_PRINTF_DIRECTIVE_F is defined.
31383         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): New macro.
31384         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_F): New macro.
31385         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
31386         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
31387         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
31388         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
31389         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
31390         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
31391         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Invoke
31392         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
31393         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
31394         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Invoke
31395         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
31396         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
31397         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Invoke
31398         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
31399         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
31400         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Invoke
31401         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
31402         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
31403         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Invoke
31404         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
31405         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
31406         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Invoke
31407         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
31408         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
31409         Reported by Eric Blake.
31410
31411 2007-04-11  Bruno Haible  <bruno@clisp.org>
31412
31413         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Fix test. It always failed.
31414
31415 2007-04-10  Bruno Haible  <bruno@clisp.org>
31416
31417         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
31418         for NaN and Infinity. Needed on FreeBSD 6.1.
31419         * tests/test-vasnprintf-posix.c (test_function): Undo last change
31420         regarding results for "%010a" of Infinity and NaN.
31421         * tests/test-vasprintf-posix.c (test_function): Likewise.
31422         * tests/test-snprintf-posix.h (test_function): Likewise.
31423         * tests/test-sprintf-posix.h (test_function): Likewise.
31424         * tests/test-fprintf-posix.h (test_function): Likewise.
31425         * tests/test-printf-posix.h (test_function): Likewise.
31426         * tests/test-fprintf-posix.out: Likewise.
31427
31428 2007-04-10  Bruno Haible  <bruno@clisp.org>
31429
31430         * modules/locale-tests: New file.
31431         * tests/test-locale.c: New file.
31432
31433         * modules/locale: New file.
31434         * lib/locale_.h: New file.
31435         * m4/locale_h.m4: New file.
31436
31437 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
31438             Bruno Haible  <bruno@clisp.org>
31439
31440         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
31441         be determined, test for availability of the copysignf, copysign,
31442         copysignl functions.
31443         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
31444         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
31445         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
31446
31447 2007-04-09  Eric Blake  <ebb9@byu.net>
31448
31449         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
31450         * modules/stdio (Makefile.am): Support fflush.
31451         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
31452         * modules/fflush: New file.
31453         * lib/fflush.c: Likewise.
31454         * m4/fflush.m4: Likewise.
31455         * modules/fflush-tests: New test.
31456         * tests/test-fflush.c: Likewise.
31457         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
31458
31459 2007-04-06  Bruno Haible  <bruno@clisp.org>
31460
31461         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
31462         (VASNPRINTF): Use signbit for faster determination whether to print a
31463         minus sign.
31464         * modules/vasnprintf (Files): Remove lib/float+.h.
31465         * modules/fprintf-posix (Depends-on): Add signbit.
31466         * modules/snprintf-posix (Depends-on): Likewise.
31467         * modules/sprintf-posix (Depends-on): Likewise.
31468         * modules/vasnprintf-posix (Depends-on): Likewise.
31469         * modules/vasprintf-posix (Depends-on): Likewise.
31470         * modules/vfprintf-posix (Depends-on): Likewise.
31471         * modules/vsnprintf-posix (Depends-on): Likewise.
31472         * modules/vsprintf-posix (Depends-on): Likewise.
31473
31474 2007-04-06  Bruno Haible  <bruno@clisp.org>
31475
31476         * tests/test-frexp.c (main): Test also the sign bit of zero results.
31477         * tests/test-frexpl.c (main): Likewise.
31478         * tests/test-ldexpl.c (main): Likewise.
31479         * modules/frexp-tests (Depends-on): Add signbit.
31480         * modules/frexpl-tests (Depdends-on): Likewise.
31481         * modules/ldexpl-tests (Depdends-on): Likewise.
31482
31483 2007-04-06  Bruno Haible  <bruno@clisp.org>
31484
31485         * modules/signbit-tests: New file.
31486         * tests/test-signbit.c: New file.
31487
31488         * modules/signbit: New file.
31489         * lib/signbitf.c: New file.
31490         * lib/signbitd.c: New file.
31491         * lib/signbitl.c: New file.
31492         * m4/signbit.m4: New file.
31493         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
31494         (signbit): New macro.
31495         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
31496         REPLACE_SIGNBIT.
31497         * modules/math (Makefile.am) Substibute also GNULIB_SIGNBIT and
31498         REPLACE_FREXPL into math.h.
31499
31500 2007-04-06  Bruno Haible  <bruno@clisp.org>
31501
31502         * modules/isnanf-nolibm-tests: New file.
31503         * tests/test-isnanf.c: New file.
31504
31505         * modules/isnanf-nolibm: New file.
31506         * lib/isnanf.h: New file.
31507         * lib/isnanf.c: New file.
31508         * lib/isnan.c: Consider the USE_FLOAT macro.
31509         * m4/isnanf.m4: New file.
31510
31511 2007-04-06  Bruno Haible  <bruno@clisp.org>
31512
31513         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
31514         (Link): New section.
31515
31516         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
31517
31518 2007-04-06  Bruno Haible  <bruno@clisp.org>
31519
31520         Assume the 'long double' type.
31521         * m4/longdouble.m4: Remove file.
31522         * config/srclist.txt: Don't mention longdouble.m4.
31523         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
31524         * lib/float+.h: Likewise.
31525         * lib/frexp.c: Likewise.
31526         * lib/printf-args.h: Likewise.
31527         * lib/printf-args.c: Likewise.
31528         * lib/printf-frexp.c: Likewise.
31529         * lib/printf-parse.c: Likewise.
31530         * lib/vasnprintf.c: Likewise.
31531         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
31532         * m4/intl.m4: Likewise.
31533         * m4/isnanl.m4: Likewise.
31534         * m4/printf.m4: Likewise.
31535         * m4/printf-frexpl.m4: Likewise.
31536         * m4/vasnprintf.m4: Likewise.
31537         * modules/allocsa (Files): Remove m4/longdouble.m4.
31538         * modules/gettext (Files): Likewise.
31539         * modules/relocatable-prog-wrapper (Files): Likewise.
31540         * modules/vasnprintf (Files): Likewise.
31541         * modules/isnanl (Files): Likewise.
31542         (Include): Simplify.
31543         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
31544         (Include): Simplify.
31545         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
31546         (Include): Simplify.
31547         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
31548         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
31549         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
31550         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
31551         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
31552         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
31553         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
31554         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
31555         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
31556         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
31557         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
31558         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
31559         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
31560         * tests/test-isnanl.c: Likewise.
31561         * tests/test-snprintf-posix.h: Likewise.
31562         * tests/test-sprintf-posix.h: Likewise.
31563         * tests/test-vasnprintf-posix.c: Likewise.
31564         * tests/test-vasnprintf-posix2.c: Likewise.
31565         * tests/test-vasprintf-posix.c: Likewise.
31566
31567 2007-04-06  Bruno Haible  <bruno@clisp.org>
31568
31569         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
31570         * lib/math_.h [__DECC]: Include the overridden include file through
31571         #include_next, outside the double-inclusion guard.
31572         * lib/stdio_.h [__DECC]: Likewise.
31573         * lib/stdlib_.h [__DECC]: Likewise.
31574         * lib/string_.h [__DECC]: Likewise.
31575         * lib/time_.h [__DECC]: Likewise.
31576         * lib/wchar_.h [__DECC]: Likewise.
31577         * lib/wctype_.h [__DECC]: Likewise.
31578         * lib/inttypes_.h [__DECC]: Likewise.
31579         Reported by Albert Chin <china@thewrittenword.com> in
31580         <http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00088.html>.
31581
31582 2007-04-04  Eric Blake  <ebb9@byu.net>
31583
31584         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
31585         1.5.x.
31586
31587 2007-04-04  Bruno Haible  <bruno@clisp.org>
31588
31589         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
31590         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
31591
31592 2007-04-04  Bruno Haible  <bruno@clisp.org>
31593
31594         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
31595         results for "%010a" of Infinity and NaN.
31596         * tests/test-vasprintf-posix.c (test_function): Likewise.
31597         * tests/test-snprintf-posix.h (test_function): Likewise.
31598         * tests/test-sprintf-posix.h (test_function): Likewise.
31599         * tests/test-fprintf-posix.h (test_function): Remove these tests.
31600         * tests/test-printf-posix.h (test_function): Likewise.
31601         * tests/test-fprintf-posix.out: Update.
31602         Needed for FreeBSD 6.1.
31603
31604 2007-04-04  Bruno Haible  <bruno@clisp.org>
31605
31606         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
31607         directly used by the gnulib modules nor by gnulib-tool.
31608
31609 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
31610
31611         * DEPENDENCIES: Give overall description of version dependency
31612         desirability.  Use more-typical names for apps.
31613         Add shell, coreutils, diffutils, grep, tar, gzip.
31614
31615 2007-04-04  Simon Josefsson  <simon@josefsson.org>
31616
31617         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
31618
31619 2007-04-04  Karl Berry  <karl@gnu.org>
31620
31621         * MODULES.html.sh (func_module): missing '.
31622
31623 2007-04-03  Bruno Haible  <bruno@clisp.org>
31624
31625         * modules/argmatch-tests (Makefile.am): New variable
31626         test_argmatch_LDADD.
31627         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
31628         * modules/array-list-tests (Makefile.am): New variable
31629         test_array_list_LDADD.
31630         * modules/array-oset-tests (Makefile.am): New variable
31631         test_array_oset_LDADD.
31632         * modules/avltree-list-tests (Makefile.am): New variable
31633         test_avltree_list_LDADD.
31634         * modules/avltree-oset-tests (Makefile.am): New variable
31635         test_avltree_oset_LDADD.
31636         * modules/avltreehash-list-tests (Makefile.am): New variable
31637         test_avltreehash_list_LDADD.
31638         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
31639         test_canonicalize_lgpl_LDADD.
31640         * modules/carray-list-tests (Makefile.am): New variable
31641         test_carray_list_LDADD.
31642         * modules/dirname-tests (Makefile.am): New variable
31643         test_dirname_LDADD.
31644         * modules/linked-list-tests (Makefile.am): New variable
31645         test_linked_list_LDADD.
31646         * modules/linkedhash-list-tests (Makefile.am): New variable
31647         test_linkedhash_list_LDADD.
31648         * modules/rbtree-list-tests (Makefile.am): New variable
31649         test_rbtree_list_LDADD.
31650         * modules/rbtree-oset-tests (Makefile.am): New variable
31651         test_rbtree_oset_LDADD.
31652         * modules/rbtreehash-list-tests (Makefile.am): New variable
31653         test_rbtreehash_list_LDADD.
31654         * modules/xvasprintf-tests (Makefile.am): New variable
31655         test_xvasprintf_LDADD.
31656         Reported by Eric Blake.
31657
31658 2007-04-03  Eric Blake  <ebb9@byu.net>
31659
31660         * DEPENDENCIES: Weaken m4 requirements.
31661
31662 2007-04-03  Bruno Haible  <bruno@clisp.org>
31663
31664         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
31665         * modules/isnanl-tests (configure.ac): Likewise.
31666
31667 2007-04-03  Ben Pfaff  <blp@gnu.org>
31668
31669         * modules/iconv_open: Add $(srcdir)/ to source directory
31670         references in Makefile fragments that call gperf, to fix VPATH
31671         builds.
31672
31673 2007-04-03  Bruno Haible  <bruno@clisp.org>
31674
31675         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
31676         * lib/ldexpl.c: Undo last change.
31677
31678 2007-04-03  Bruno Haible  <bruno@clisp.org>
31679
31680         * modules/printf-frexpl (Depends-on): Undo last change.
31681         (Files): Add m4/ldexpl.m4.
31682
31683 2007-04-03  Bruno Haible  <bruno@clisp.org>
31684
31685         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
31686         * modules/isnanl (Link): New section.
31687
31688         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
31689         * modules/frexp (Link): New section.
31690
31691         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
31692         * modules/frexpl (Link): New section.
31693
31694         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
31695         * modules/ldexpl (Link): New section.
31696
31697 2007-04-03  Bruno Haible  <bruno@clisp.org>
31698
31699         * modules/TEMPLATE-EXTENDED: New file.
31700         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
31701
31702 2007-04-03  Bruno Haible  <bruno@clisp.org>
31703
31704         * DEPENDENCIES: New file.
31705         Suggested by Simon Josefsson.
31706
31707 2007-04-03  Bruno Haible  <bruno@clisp.org>
31708
31709         * doc/gnulib.texi: Escape @.
31710
31711 2007-04-03  James Youngman  <jay@gnu.org>
31712         and Paul Eggert  <eggert@cs.ucla.edu>
31713
31714         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
31715         birthtime on all systems that have birthtime, not just those which
31716         use st_birthtimensec rather than st_birthtim.  Putting zero in
31717         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
31718         that the birth time is not available for files on an NFS mount.
31719
31720 2007-04-03  Simon Josefsson  <simon@josefsson.org>
31721
31722         * modules/memxor: Move back from crypto/, suggested by Bruno.
31723         * modules/crypto/hmac-sha1: Fix memxor dependency.
31724
31725         * modules/crypto/gc: Moved from ../.
31726
31727 2007-04-02  Eric Blake  <ebb9@byu.net>
31728
31729         * lib/ldexpl.c (includes): Avoid libm.
31730
31731         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
31732
31733 2007-04-02  Bruno Haible  <bruno@clisp.org>
31734
31735         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
31736         on IRIX.
31737
31738 2007-04-02  Bruno Haible  <bruno@clisp.org>
31739
31740         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
31741         x86 or x86_64 platforms running MacOS X.
31742         Reported by Ryan Schmidt <@ryandesign.com>.
31743
31744 2007-04-02  Bruno Haible  <bruno@clisp.org>
31745
31746         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
31747         i386.
31748
31749 2007-04-01  Simon Josefsson  <simon@josefsson.org>
31750
31751         * modules/crypto/arcfour: Moved from ../.
31752         * modules/crypto/arcfour-tests: Moved from ../.
31753         * modules/crypto/arctwo: Moved from ../.
31754         * modules/crypto/arctwo-tests: Moved from ../.
31755         * modules/crypto/des: Moved from ../.
31756         * modules/crypto/des-tests: Moved from ../.
31757         * modules/crypto/gc-arcfour: Moved from ../.
31758         * modules/crypto/gc-arcfour-tests: Moved from ../.
31759         * modules/crypto/gc-arctwo: Moved from ../.
31760         * modules/crypto/gc-arctwo-tests: Moved from ../.
31761         * modules/crypto/gc-des: Moved from ../.
31762         * modules/crypto/gc-des-tests: Moved from ../.
31763         * modules/crypto/gc-hmac-md5: Moved from ../.
31764         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
31765         * modules/crypto/gc-hmac-sha1: Moved from ../.
31766         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
31767         * modules/crypto/gc-md2: Moved from ../.
31768         * modules/crypto/gc-md2-tests: Moved from ../.
31769         * modules/crypto/gc-md4: Moved from ../.
31770         * modules/crypto/gc-md4-tests: Moved from ../.
31771         * modules/crypto/gc-md5: Moved from ../.
31772         * modules/crypto/gc-md5-tests: Moved from ../.
31773         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
31774         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
31775         * modules/crypto/gc-random: Moved from ../.
31776         * modules/crypto/gc-rijndael: Moved from ../.
31777         * modules/crypto/gc-rijndael-tests: Moved from ../.
31778         * modules/crypto/gc-sha1: Moved from ../.
31779         * modules/crypto/gc-sha1-tests: Moved from ../.
31780         * modules/crypto/gc-tests: Moved from ../.
31781         * modules/crypto/hmac-md5: Moved from ../.
31782         * modules/crypto/hmac-md5-tests: Moved from ../.
31783         * modules/crypto/hmac-sha1: Moved from ../.
31784         * modules/crypto/hmac-sha1-tests: Moved from ../.
31785         * modules/crypto/md2: Moved from ../.
31786         * modules/crypto/md2-tests: Moved from ../.
31787         * modules/crypto/md4: Moved from ../.
31788         * modules/crypto/md4-tests: Moved from ../.
31789         * modules/crypto/md5: Moved from ../.
31790         * modules/crypto/md5-tests: Moved from ../.
31791         * modules/crypto/memxor: Moved from ../.
31792         * modules/crypto/rijndael: Moved from ../.
31793         * modules/crypto/rijndael-tests: Moved from ../.
31794         * modules/crypto/sha1: Moved from ../.
31795
31796 2007-03-30  James Youngman  <jay@gnu.org>
31797
31798         * tests/test-stat-time.c (prepare_test): use chmod() rather than
31799         rename() to change the ctime of a file (because ctime is unaffected
31800         by rename on jfs2 on AIX 5.1).
31801         (main): Start by doing cleanup, in case a previous run failed leaving
31802         test files behind.
31803
31804 2007-03-31  Bruno Haible  <bruno@clisp.org>
31805
31806         Support old proprietary implementations of iconv.
31807         * modules/iconv_open: New file.
31808         * lib/iconv_.h: New file.
31809         * m4/iconv_h.m4: New file.
31810         * lib/iconv_open.c: New file.
31811         * lib/iconv_open-aix.gperf: New file.
31812         * lib/iconv_open-hpux.gperf: New file.
31813         * lib/iconv_open-irix.gperf: New file.
31814         * lib/iconv_open-osf.gperf: New file.
31815         * m4/iconv_open.m4: New file.
31816         * modules/linebreak (Depends-on): Add iconv_open.
31817         * modules/striconv (Depends-on): Likewise.
31818         * modules/striconveh (Depends-on): Likewise.
31819         * modules/unicodeio (Depends-on): Likewise.
31820         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
31821         (iconv_t)(-1).
31822         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
31823         conversion if cd is (iconv_t)(-1).
31824         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
31825         is not possible.
31826
31827 2007-03-31  Bruno Haible  <bruno@clisp.org>
31828
31829         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
31830         work on Solaris either. Protect also second use of "autodetect_jp".
31831
31832 2007-03-31  Bruno Haible  <bruno@clisp.org>
31833
31834         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
31835         the function is not present.
31836
31837 2007-03-31  Bruno Haible  <bruno@clisp.org>
31838
31839         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
31840         the function is not present.
31841
31842 2007-03-31  Bruno Haible  <bruno@clisp.org>
31843
31844         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
31845         a bug in HP-UX iconv_open().
31846
31847 2007-03-31  Bruno Haible  <bruno@clisp.org>
31848
31849         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
31850         (Mathematics <math.h>): New section, add fpieee.
31851         (Input/output <stdio.h>): Add fseterr.
31852         (Mathematics <math.h>): New section, add printf-frexp.
31853         (Container data structures): Add sublist.
31854         (Core language properties): Add fpucw, inline.
31855         (Functions for greatest-width integer types <inttypes.h>): Add
31856         imaxabs, imaxdiv, inttypes.
31857         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
31858         isnanl-nolibm, ldexp.
31859         (Mathematics <math.h>): New section, add printf-frexpl.
31860         (Support for systems lacking POSIX:2001): Add fprintf-posix,
31861         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
31862         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
31863         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
31864         (Unicode string functions): Add unistr/u*-mbtoucr.
31865         (Java): Add javacomp-script, javaexec-script.
31866         (C#): Add csharpcomp-script, csharpexec-script.
31867         (Support for building libraries and executables): Add havelib,
31868         relocatable-*.
31869         (Support for maintaining and releasing projects): Renamed from
31870         'Support for maintaining and release projects'. Add announce-gen.
31871
31872 2007-03-31  Bruno Haible  <bruno@clisp.org>
31873
31874         * README: Talk primarily about git.
31875         (git and CVS): Renamed from CVS.
31876         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
31877         gnulib is available through git.
31878         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
31879
31880 2007-03-30  Bruno Haible  <bruno@clisp.org>
31881
31882         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
31883         * lib/poll_.h: Likewise.
31884         * lib/stat_.h: Likewise.
31885         * lib/sys_time_.h: Likewise.
31886         * lib/sysexit_.h: Likewise.
31887         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
31888         * lib/stdbool_.h: Likewise.
31889         * lib/byteswap_.h: Add double-inclusion guard.
31890
31891 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
31892
31893         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
31894
31895 2007-03-30  Karl Berry  <karl@gnu.org>
31896
31897         * config/srclist-update: double space after USA in the license
31898         substitution, since that's how it's usually (?) written.
31899
31900 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
31901
31902         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
31903         reported by Bruno Haible.
31904
31905 2007-03-29  Bruno Haible  <bruno@clisp.org>
31906
31907         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
31908         a bug in AIX iconv().
31909
31910 2007-03-29  Bruno Haible  <bruno@clisp.org>
31911
31912         * modules/ldexpl-tests: New file.
31913         * tests/test-ldexpl.c: New file.
31914
31915 2007-03-29  Bruno Haible  <bruno@clisp.org>
31916
31917         * lib/ldexpl.c: Include fpucw.h.
31918         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
31919         multiplication.
31920         * modules/ldexpl (Depends-on): Add fpucw.
31921
31922 2007-03-29  Bruno Haible  <bruno@clisp.org>
31923
31924         * modules/ldexpl: New file.
31925         * m4/ldexpl.m4: New file.
31926         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
31927         set.
31928         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
31929         REPLACE_LDEXPL.
31930         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
31931         REPLACE_LDEXPL.
31932         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
31933         gl_FUNC_LDEXPL_WORKS.
31934         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
31935         * modules/mathl (Files): Remove lib/ldexpl.c.
31936         (Depends-on): Add ldexpl.
31937
31938 2007-03-29  Bruno Haible  <bruno@clisp.org>
31939
31940         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
31941
31942 2007-03-29  Bruno Haible  <bruno@clisp.org>
31943
31944         * tests/test-striconveh.c (main): Don't assume that a direct conversion
31945         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
31946         and possibly also HP-UX.
31947         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
31948         work on AIX, IRIX, HP-UX, OSF/1.
31949         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
31950         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
31951         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
31952         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
31953         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
31954         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
31955
31956 2007-03-29  Bruno Haible  <bruno@clisp.org>
31957
31958         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
31959
31960 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
31961
31962         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
31963         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
31964
31965 2007-03-29  Eric Blake  <ebb9@byu.net>
31966
31967         * lib/acl-internal.h: Remove redundant include.
31968         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
31969         Cygwin when a file is locked.
31970
31971 2007-03-29  Bruno Haible  <bruno@clisp.org>
31972
31973         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
31974         file.
31975         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
31976
31977 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
31978
31979         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
31980         try to remove a parent directory if the child couldn't be removed
31981         (except for the first rmdir, which could fail because the child
31982         doesn't exist).  Problem reported by Jeff Blaine in
31983         <http://lists.gnu.org/archive/html/bug-tar/2007-03/msg00014.html>.
31984
31985 2007-03-28  Bruno Haible  <bruno@clisp.org>
31986
31987         * lib/striconveh.c (utf8conv_carefully): New function.
31988         (mem_cd_iconveh_internal): Invoke it.
31989
31990 2007-03-28  Bruno Haible  <bruno@clisp.org>
31991
31992         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
31993         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
31994         input.
31995         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
31996         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
31997         unistr/u8-uctomb.
31998
31999 2007-03-28  Bruno Haible  <bruno@clisp.org>
32000
32001         * modules/unistr/u8-mbtoucr: New file.
32002         * lib/unistr/u8-mbtoucr.c: New file.
32003         * modules/unistr/u16-mbtoucr: New file.
32004         * lib/unistr/u16-mbtoucr.c: New file.
32005         * modules/unistr/u16-mbtoucr: New file.
32006         * lib/unistr/u16-mbtoucr.c: New file.
32007         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
32008
32009 2007-03-27  Simon Josefsson  <simon@josefsson.org>
32010             Bruno Haible  <bruno@clisp.org>
32011
32012         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
32013         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
32014         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
32015
32016         * m4/stdio_h.m4: Add stubs for vasprintf too.
32017
32018         * modules/stdio: Support vasprintf in sed command.
32019
32020         * modules/vasprintf: Depend on stdio for prototypes.  Remove
32021         vasprintf.h.  Add stdio module indicator.
32022
32023         * lib/stdio_.h: Declare asprintf and vasprintf, based on
32024         vasprintf.h.
32025
32026         * lib/vasprintf.h: File removed.
32027
32028         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
32029         * lib/vasprintf.c: Ditto.
32030         * lib/xvasprintf.c: Ditto.
32031         * tests/test-vasprintf-posix.c: Ditto.
32032         * tests/test-vasprintf.c: Ditto.
32033
32034 2007-03-27  Bruno Haible  <bruno@clisp.org>
32035
32036         Make vasnprintf multithread-safe.
32037         * lib/vasnprintf.c (decimal_point_char): New function.
32038         (VASNPRINTF): Use it.
32039         Suggested by Simon Josefsson.
32040
32041 2007-03-27  Eric Blake  <ebb9@byu.net>
32042
32043         Support sub-second birthtime on cygwin.
32044         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
32045         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
32046         (get_stat_birthtime): Also work with st_birthtim.
32047
32048 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
32049
32050         * lib/stat-time.h (USE_BIRTHTIME): Remove.
32051         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
32052         (get_stat_birthtime_ns): Do not try to use "spare" fields.
32053         (get_stat_birthtime_ns): Simplify compile-time tests.
32054         (get_stat_birthtime): Change the API to look like
32055         get_stat_mtime etc., except return a negative tv_nsec on error.
32056         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
32057         Don't check for "spare" fields.
32058         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
32059         or for struct stat.st_birthtime, as these tests aren't used.
32060         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
32061
32062 2007-03-27  Bruno Haible  <bruno@clisp.org>
32063
32064         * lib/stat-time.h: Include <sys/stat.h>.
32065
32066 2007-03-27  James Youngman  <jay@gnu.org>
32067
32068         * lib/stat-time.h (get_stat_birthtime): New function for
32069           retrieving st_birthtime as provided by UFS2 (hence *BSD).
32070         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
32071           and its variants.
32072         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
32073         * modules/stat-time-test: New file.
32074         * tests/test-stat-time.c: New test, devised by Bruno Haible.
32075
32076 2007-03-26  Bruno Haible  <bruno@clisp.org>
32077
32078         Better support of signalling NaNs.
32079         * lib/atanl.c: Include isnanl.h.
32080         (atanl): Perform test for NaN at the beginning of the function and
32081         through a call to isnanl.
32082         * lib/cosl.c: Include isnanl.h.
32083         (cosl): Perform test for NaN at the beginning of the function and
32084         through a call to isnanl.
32085         * lib/ldexpl.c: Include isnanl.h.
32086         (ldexpl): Perform test for NaN through a call to isnanl.
32087         * lib/logl.c: Include isnanl.h.
32088         (logl): Perform test for NaN at the beginning of the function and
32089         through a call to isnanl.
32090         * lib/sinl.c: Include isnanl.h.
32091         (sinl): Perform test for NaN at the beginning of the function and
32092         through a call to isnanl.
32093         * lib/sqrtl.c: Include isnanl.h.
32094         (sqrtl): Perform test for NaN at the beginning of the function and
32095         through a call to isnanl.
32096         * lib/tanl.c: Include isnanl.h.
32097         (tanl): Perform test for NaN at the beginning of the function and
32098         through a call to isnanl.
32099         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
32100         * modules/mathl (Depends-on): Add isnanl.
32101
32102 2007-03-26  Eric Blake  <ebb9@byu.net>
32103
32104         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
32105         regression in logic sense of previous patch.
32106
32107 2007-03-26  Bruno Haible  <bruno@clisp.org>
32108
32109         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
32110         unportable shell command "if ! ...".
32111         Reported by Ralf Wildenhues.
32112
32113 2007-03-25  Bruno Haible  <bruno@clisp.org>
32114
32115         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
32116         <sysexits.h> file, and only add EX_CONFIG.
32117         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
32118         absolute file name and whether it is sufficient. Substitute also
32119         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
32120         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
32121         ABSOLUTE_SYSEXITS_H into sysexits.h.
32122
32123 2007-03-25  Bruno Haible  <bruno@clisp.org>
32124
32125         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
32126         hints is NULL.
32127
32128 2007-03-25  Bruno Haible  <bruno@clisp.org>
32129
32130         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
32131         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
32132
32133 2007-03-25  Bruno Haible  <bruno@clisp.org>
32134
32135         * lib/vasnprintf.c: Include langinfo.h.
32136         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
32137         multithread-safe.
32138         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
32139         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
32140         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
32141         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
32142         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
32143         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
32144         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
32145         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
32146         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
32147         Reported by Simon Josefsson.
32148
32149 2007-03-25  Bruno Haible  <bruno@clisp.org>
32150
32151         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
32152         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
32153         * modules/vasnprintf (Depends-on): Add stdint.
32154
32155 2007-03-25  Bruno Haible  <bruno@clisp.org>
32156
32157         * modules/fpieee: New file.
32158         * m4/fpieee.m4: New file.
32159         * modules/isnan-nolibm (Depends-on): Add fpieee.
32160         * modules/isnanl-nolibm (Depends-on): Add fpieee.
32161         * modules/isnanl (Depends-on): Add fpieee.
32162
32163 2007-03-25  Bruno Haible  <bruno@clisp.org>
32164
32165         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
32166
32167 2007-03-25  Bruno Haible  <bruno@clisp.org>
32168
32169         Avoid test failures on IRIX 6.5.
32170         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
32171         (main): Use it.
32172         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
32173         macros.
32174         (main): Use them.
32175
32176 2007-03-25  Bruno Haible  <bruno@clisp.org>
32177
32178         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
32179         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
32180         exists but doesn't work.
32181         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
32182         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
32183         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
32184         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
32185
32186 2007-03-25  Bruno Haible  <bruno@clisp.org>
32187
32188         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
32189         returns inf. Needed on IRIX 6.5.
32190
32191 2007-03-25  Bruno Haible  <bruno@clisp.org>
32192
32193         * tests/test-frexpl.c: Include isnanl-nolibm.h.
32194         (main): Use isnanl instead of x != x idiom.
32195         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
32196
32197         * tests/test-frexp.c: Include isnan.h.
32198         (main): Use isnan instead of x != x idiom.
32199         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
32200
32201 2007-03-25  Bruno Haible  <bruno@clisp.org>
32202
32203         * tests/test-frexp.c (NaN): New function/macro.
32204         (main): Use it instead of 0.0 / 0.0.
32205         * tests/test-isnan.c (NaN): New function/macro.
32206         (main): Use it instead of 0.0 / 0.0.
32207         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
32208         (test_function): Use it instead of 0.0 / 0.0.
32209         * tests/test-vasprintf-posix.c (NaN): New function/macro.
32210         (test_function): Use it instead of 0.0 / 0.0.
32211         * tests/test-snprintf-posix.h (NaN): New function/macro.
32212         (test_function): Use it instead of 0.0 / 0.0.
32213         * tests/test-sprintf-posix.h (NaN): New function/macro.
32214         (test_function): Use it instead of 0.0 / 0.0.
32215         * tests/test-fprintf-posix.h (NaN): New function/macro.
32216         (test_function): Use it instead of 0.0 / 0.0.
32217         * tests/test-printf-posix.h (NaN): New function/macro.
32218         (test_function): Use it instead of 0.0 / 0.0.
32219
32220         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
32221
32222 2007-03-25  Bruno Haible  <bruno@clisp.org>
32223
32224         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
32225
32226 2007-03-25  Bruno Haible  <bruno@clisp.org>
32227
32228         * lib/regexec.c (merge_state_with_log): Make static.
32229
32230 2007-03-25  Bruno Haible  <bruno@clisp.org>
32231
32232         * lib/trigl.c (kernel_rem_pio2): Make static.
32233
32234 2007-03-25  Bruno Haible  <bruno@clisp.org>
32235
32236         * lib/sincosl.c (sincosl_table): Make static.
32237
32238 2007-03-25  Bruno Haible  <bruno@clisp.org>
32239
32240         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
32241         if the compiler does not support C99.
32242
32243 2007-03-25  Bruno Haible  <bruno@clisp.org>
32244
32245         * modules/time (Makefile.am): Ensure all rule action lines start with a
32246         tab.
32247
32248 2007-03-24  Bruno Haible  <bruno@clisp.org>
32249
32250         * modules/tsearch-tests: New file.
32251         * tests/test-tsearch.sh: New file.
32252         * tests/test-tsearch.c: New file, mostly copied from glibc.
32253
32254         * modules/search-tests: New file.
32255         * tests/test-search.c: New file.
32256
32257         * modules/search: New file.
32258         * lib/search_.h: New file, incorporating lib/tsearch.h.
32259         * m4/search_h.m4: New file.
32260         * lib/tsearch.h: Remove file.
32261         * lib/tsearch.c: Include search.h instead of tsearch.h.
32262         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
32263         HAVE_TSEARCH.
32264         * modules/tsearch (Files): Remove lib/tsearch.h.
32265         (Depends-on): Add search.
32266         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
32267         (Include): Change tsearch.h into search.h.
32268
32269 2007-03-24  Bruno Haible  <bruno@clisp.org>
32270
32271         * modules/fpucw: New file.
32272         * lib/fpucw.h: New file.
32273         * lib/frexp.c: Include fpucw.h.
32274         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
32275         (FUNC): Use them.
32276         * lib/printf-frexp.c: Include fpucw.h.
32277         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
32278         (FUNC): Use them.
32279         * lib/vasnprintf.c: Include fpucw.h.
32280         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
32281         'long double' calculations.
32282         * tests/test-frexpl.c: Include fpucw.h.
32283         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
32284         * tests/test-printf-frexpl.c: Include fpucw.h.
32285         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
32286         * modules/frexpl (Depends-on): Add fpucw.
32287         * modules/printf-frexpl (Depends-on): Likewise.
32288         * modules/fprintf-posix (Depends-on): Likewise.
32289         * modules/snprintf-posix (Depends-on): Likewise.
32290         * modules/sprintf-posix (Depends-on): Likewise.
32291         * modules/vasnprintf-posix (Depends-on): Likewise.
32292         * modules/vasprintf-posix (Depends-on): Likewise.
32293         * modules/vfprintf-posix (Depends-on): Likewise.
32294         * modules/vsnprintf-posix (Depends-on): Likewise.
32295         * modules/vsprintf-posix (Depends-on): Likewise.
32296         * modules/frexpl-tests (Depends-on): Likewise.
32297         * modules/printf-frexpl-tests (Depends-on): Likewise.
32298
32299 2007-03-24  Bruno Haible  <bruno@clisp.org>
32300
32301         * lib/float+.h: New file.
32302         * lib/isnan.c: Include float+.h.
32303         (SIZE): New macro.
32304         (FUNC): Compare only SIZE bytes of the value.
32305         * lib/vasnprintf.c: Include float+.h.
32306         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
32307         SIZEOF_LDBL or SIZEOF_DBL bytes.
32308         * modules/isnan-nolibm (Files): Add lib/float+.h.
32309         * modules/isnanl-nolibm (Files): Add lib/float+.h.
32310         * modules/isnanl (Files): Add lib/float+.h.
32311         * modules/vasnprintf (Files): Add lib/float+.h.
32312
32313 2007-03-24  Bruno Haible  <bruno@clisp.org>
32314
32315         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
32316         include isnanl-nolibm.h.
32317
32318 2007-03-24  Bruno Haible  <bruno@clisp.org>
32319
32320         * tests/test-read-file.c (main): Don't produce spurious output for
32321         expected situations. Make the test fail if it encountered unexpected
32322         results.
32323
32324 2007-03-24  Bruno Haible  <bruno@clisp.org>
32325
32326         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
32327         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
32328
32329 2007-03-24  Bruno Haible  <bruno@clisp.org>
32330
32331         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
32332
32333 2007-03-24  Bruno Haible  <bruno@clisp.org>
32334
32335         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
32336         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
32337
32338         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
32339         * modules/utf8-ucs4: Turn into a symbolic link to module
32340         unistr/u8-mbtouc.
32341
32342         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
32343         utf8-ucs4-unsafe.
32344         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
32345         unistr/u8-mbtouc-unsafe.
32346
32347         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
32348         * modules/utf16-ucs4: Turn into a symbolic link to module
32349         unistr/u16-mbtouc.
32350
32351         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
32352         utf16-ucs4-unsafe.
32353         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
32354         unistr/u16-mbtouc-unsafe.
32355
32356         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
32357         * modules/ucs4-utf8: Turn into a symbolic link to module
32358         unistr/u8-ubtomb.
32359
32360         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
32361         * modules/ucs4-utf16: Turn into a symbolic link to module
32362         unistr/u16-ubtomb.
32363
32364 2007-03-24  Bruno Haible  <bruno@clisp.org>
32365
32366         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
32367         Enable the function only if HAVE_INLINE.
32368         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
32369         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
32370         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
32371         Enable the function only if HAVE_INLINE.
32372         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
32373         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
32374         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
32375         Enable the function only if HAVE_INLINE.
32376         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
32377         Enable the function only if HAVE_INLINE.
32378         * modules/utf8-ucs4: Update.
32379         * modules/utf8-ucs4-unsafe: Update.
32380         * modules/utf16-ucs4: Update.
32381         * modules/utf16-ucs4-unsafe: Update.
32382         * modules/ucs4-utf8: Update.
32383         * modules/ucs4-utf16: Update.
32384
32385 2007-03-24  Bruno Haible  <bruno@clisp.org>
32386
32387         * lib/utf8-ucs4.h: Remove file.
32388         * lib/utf8-ucs4-unsafe.h: Remove file.
32389         * lib/utf16-ucs4.h: Remove file.
32390         * lib/utf16-ucs4-unsafe.h: Remove file.
32391         * lib/ucs4-utf8.h: Remove file.
32392         * lib/ucs4-utf16.h: Remove file.
32393         * lib/unistr.h: Include their previous contents.
32394         * m4/utf-ucs4.m4: Remove file.
32395         * m4/ucs4-utf.m4: Remove file.
32396         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
32397         (Depends-on): Add unistr/base.
32398         (configure.ac): Remove gl_UTF_UCS4.
32399         (Makefile.am): Update.
32400         (Include): Change to unistr.h.
32401         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
32402         (Depends-on): Add unistr/base.
32403         (configure.ac): Remove gl_UTF_UCS4.
32404         (Makefile.am): Update.
32405         (Include): Change to unistr.h.
32406         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
32407         (Depends-on): Add unistr/base.
32408         (configure.ac): Remove gl_UTF_UCS4.
32409         (Makefile.am): Update.
32410         (Include): Change to unistr.h.
32411         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
32412         (Depends-on): Add unistr/base.
32413         (configure.ac): Remove gl_UTF_UCS4.
32414         (Makefile.am): Update.
32415         (Include): Change to unistr.h.
32416         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
32417         (Depends-on): Add unistr/base.
32418         (configure.ac): Remove gl_UCS4_UTF.
32419         (Makefile.am): Update.
32420         (Include): Change to unistr.h.
32421         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
32422         (Depends-on): Add unistr/base.
32423         (configure.ac): Remove gl_UCS4_UTF.
32424         (Makefile.am): Update.
32425         (Include): Change to unistr.h.
32426         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
32427         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
32428         utf8-ucs4-unsafe.h.
32429         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
32430         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
32431         utf16-ucs4-unsafe.h.
32432         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
32433         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
32434         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
32435         * lib/unistr/u8-strchr.c: Likewise.
32436         * lib/unistr/u8-strrchr.c: Likewise.
32437         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
32438         * lib/unistr/u16-strchr.c: Likewise.
32439         * lib/unistr/u16-strrchr.c: Likewise.
32440         * lib/striconveh.c: Update.
32441         * lib/linebreak.c: Update.
32442
32443 2007-03-24  Bruno Haible  <bruno@clisp.org>
32444
32445         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
32446         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
32447
32448 2007-03-22  Bruno Haible  <bruno@clisp.org>
32449
32450         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
32451
32452 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
32453
32454         * MODULES.html.sh (File system functions): New module write-any-file.
32455         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
32456         * m4/write-any-file.m4: New files.
32457
32458 2007-03-23  Eric Blake  <ebb9@byu.net>
32459
32460         * gnulib-tool: Rearrange space-tab sequences, since some editors
32461         like to eat them.
32462
32463 2007-03-23  Eric Blake  <ebb9@byu.net>
32464
32465         * lib/version-etc.c (version_etc_va): Update license wording to
32466         be more concise.  Recommended by Richard Stallman.
32467
32468 2007-03-22  Bruno Haible  <bruno@clisp.org>
32469
32470         * lib/poll.c (MSG_PEEK): New fallback definition.
32471
32472 2007-03-22  Bruno Haible  <bruno@clisp.org>
32473
32474         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
32475         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
32476         (main): Update.
32477         Fixes a compilation error on BeOS.
32478
32479 2007-03-22  Bruno Haible  <bruno@clisp.org>
32480
32481         * modules/frexpl-tests: New file.
32482         * tests/test-frexpl.c: New file.
32483
32484         * modules/frexpl: New file.
32485         * m4/frexpl.m4: New file.
32486         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
32487         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
32488         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
32489         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
32490         (Depends-on): Add frexpl. Remove isnanl-nolibm.
32491         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
32492
32493 2007-03-22  Bruno Haible  <bruno@clisp.org>
32494
32495         * lib/frexpl.c: Share code with lib/frexp.c.
32496         * modules/mathl (Files): Add lib/frexp.c.
32497         (Depends-on): Add isnanl-nolibm.
32498
32499 2007-03-22  Bruno Haible  <bruno@clisp.org>
32500
32501         * modules/printf-frexp (Files): Add m4/frexp.m4.
32502         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
32503         only if the found frexp function actually works.
32504
32505 2007-03-22  Bruno Haible  <bruno@clisp.org>
32506
32507         * lib/frexp.c: Remove older implementation that uses divisions.
32508
32509 2007-03-21  Bruno Haible  <bruno@clisp.org>
32510
32511         * modules/frexp-tests: New file.
32512         * tests/test-frexp.c: New file.
32513
32514         * modules/frexp: New file.
32515         * lib/frexp.c: New file.
32516         * m4/frexp.m4: New file.
32517         * lib/math_.h (frexp): New declaration.
32518         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
32519         REPLACE_FREXP.
32520         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
32521
32522 2007-03-21  Bruno Haible  <bruno@clisp.org>
32523
32524         * modules/isnanl-tests: New file.
32525         * tests/test-isnanl.c: New file.
32526
32527         * modules/isnanl: New file.
32528         * lib/isnanl.h: New file.
32529         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
32530         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
32531         gl_FUNC_ISNANL_WORKS.
32532         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
32533         New macros.
32534
32535 2007-03-21  Bruno Haible  <bruno@clisp.org>
32536
32537         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
32538         lib/isnanl.h.
32539         (Include): Update.
32540         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
32541         * lib/vasnprintf.c: Update.
32542         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
32543         tests/test-isnanl.h, remove tests/test-isnanl.c.
32544         (Makefile.am): Update.
32545         * tests/test-isnanl-nolibm.c: New file.
32546         * tests/test-isnanl.h: New file.
32547         * tests/test-isnanl.c: Remove file.
32548
32549 2007-03-21  Jim Meyering  <jim@meyering.net>
32550
32551         When trying to open ".", treat ESTALE like EACCES.
32552         * lib/savewd.c (savewd_save): Resort to forking not just upon
32553         failure with EACCES, but also when errno is ESTALE.
32554
32555 2007-03-20  Bruno Haible  <bruno@clisp.org>
32556
32557         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
32558         Needed on AIX 5.1. Reported by Matthew Woehlke.
32559
32560 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
32561
32562         Suggestions by Bruno Haible:
32563         * lib/acl-internal.h: Include "gettext.h" rather than rolling
32564         our own.
32565         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
32566         * modules/acl (Depends-on): Add gettext.
32567
32568 2007-03-19  Bruno Haible  <bruno@clisp.org>
32569
32570         * modules/iconvme: Remove file.
32571         * lib/iconvme.h: Remove file.
32572         * lib/iconvme.c: Remove file.
32573         * m4/iconvme.m4: Remove file.
32574
32575 2007-03-19  Bruno Haible  <bruno@clisp.org>
32576
32577         * doc/relocatable-maint.texi: Break long shell script line.
32578         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
32579
32580 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
32581
32582         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
32583         handle file_has_acl.
32584         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
32585         * lib/acl.c: Move header inclusions and related macro defns into
32586         lib/acl-internal.h.
32587         (S_ISLNK): Remove defn, since that's now done for us.
32588         (file_has_acl): Move to lib/file-has-acl.c.
32589         Call acl_trivial if available.  This is the crucial part of the fix.
32590         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
32591         shared within the library.  Rewrite a bit, partly to make it compatible
32592         with the GNU coding style.
32593         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
32594         Remove unnecessary double-quotes.
32595         Don't test for acl_to_text; the build will catch that.
32596         Replace acl_entries if it doesn't exist and it is needed.
32597         Check for -lsec and acl_trivial (as used on Solaris 10).
32598         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
32599         lib/file-has-acl.c.
32600         (Depends-on): Add sys_stat, for S_ISLNK.
32601
32602 2007-03-19  Ben Pfaff  <blp@gnu.org>
32603
32604         * doc/gnulib.texi: Fix typos.
32605         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
32606
32607 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
32608
32609         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
32610         If size is zero here, buf must be zero.
32611
32612 2007-03-19  Simon Josefsson  <simon@josefsson.org>
32613
32614         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
32615         <bruno@clisp.org>.
32616
32617 2007-03-18  Bruno Haible  <bruno@clisp.org>
32618
32619         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
32620         Suggested by Eric Blake.
32621
32622 2007-03-18  Ben Pfaff  <blp@gnu.org>
32623
32624         * doc/relocatable.texi: Recommend using as prefix a directory
32625         that does not exist and will never be created.  Based on
32626         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
32627         and others.
32628
32629 2007-03-17  Bruno Haible  <bruno@clisp.org>
32630
32631         * lib/fchownat.c: Include lchown.h.
32632
32633 2007-03-17  Bruno Haible  <bruno@clisp.org>
32634
32635         Fix endless loop when the given allocated size was > INT_MAX.
32636         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
32637         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
32638         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
32639         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
32640         * lib/sprintf.c (sprintf): Likewise.
32641
32642 2007-03-17  Bruno Haible  <bruno@clisp.org>
32643
32644         * tests/test-argp-2.sh (func_compare): Output a context diff.
32645
32646 2007-03-17  Bruno Haible  <bruno@clisp.org>
32647
32648         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
32649         locale's decimal-point character.
32650
32651 2007-03-17  Bruno Haible  <bruno@clisp.org>
32652
32653         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
32654         before comparing it. Needed because on some platforms (e.g. x86) a
32655         'long double' occupies less bytes than sizeof (long double).
32656
32657 2007-03-17  Bruno Haible  <bruno@clisp.org>
32658
32659         * tests/test-crc.c (main): Make printf statements 64-bit clean.
32660         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
32661         * tests/test-getaddrinfo.c (simple): Likewise.
32662         * tests/test-read-file.c (main): Likewise.
32663
32664 2007-03-17  Bruno Haible  <bruno@clisp.org>
32665
32666         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
32667
32668 2007-03-17  Bruno Haible  <bruno@clisp.org>
32669
32670         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
32671         unused variable.
32672
32673 2007-03-17  Bruno Haible  <bruno@clisp.org>
32674
32675         * tests/test-c-strcasecmp.c: Include c-strcase.h.
32676         * tests/test-c-strncasecmp.c: Likewise.
32677
32678 2007-03-17  Bruno Haible  <bruno@clisp.org>
32679
32680         * modules/stdlib (Depends-on): Add unistd.
32681         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
32682         Needed for MacOS X 10.3.
32683
32684 2007-03-17  Bruno Haible  <bruno@clisp.org>
32685
32686         * lib/unistr/u-strdup.h: Include <stdlib.h>.
32687
32688 2007-03-17  Bruno Haible  <bruno@clisp.org>
32689
32690         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
32691
32692 2007-03-17  Bruno Haible  <bruno@clisp.org>
32693
32694         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
32695         to reflect files copied from gnulib (with or without modifications).
32696         Suggested by Jim Meyering.
32697
32698 2007-03-17  Eric Blake  <ebb9@byu.net>
32699
32700         * NEWS: Document stdlib change from 2007-02-18.
32701
32702 2007-03-17  Jim Meyering  <jim@meyering.net>
32703
32704         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
32705         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
32706         someone uses a name containing shell meta-characters.
32707         Reported by Alfred M. Szmidt.
32708
32709         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
32710
32711 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
32712
32713         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
32714         and copy gettext configuration files only if configure.ac contains
32715         a use of AM_GNU_GETTEXT_VERSION.
32716
32717 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
32718
32719         * build-aux/bootstrap (gnulib_name): New variable.
32720         (gnulib_tool_options): Use it.
32721
32722 2007-03-13  Simon Josefsson  <simon@josefsson.org>
32723
32724         * tests/test-des.c: Use new namespace.
32725
32726 2007-03-15  Bruno Haible  <bruno@clisp.org>
32727
32728         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
32729         Reported by James Youngman <jay@gnu.org>.
32730
32731 2007-03-15  Bruno Haible  <bruno@clisp.org>
32732
32733         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
32734         declared prototype. Needed with cc on OSF/1 5.1.
32735
32736 2007-03-15  Bruno Haible  <bruno@clisp.org>
32737
32738         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
32739         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
32740         (struct gl_list_implementation): Add dispose_fn argument to the
32741         'create_empty', 'create' methods.
32742         (struct gl_list_impl_base): Add field 'dispose_fn'.
32743         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
32744         argument.
32745         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
32746         dispose_fn argument.
32747         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
32748         dispose_fn on the dropped values.
32749         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
32750         dispose_fn argument.
32751         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
32752         dropped values.
32753         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
32754         (gl_tree_remove_node): Call dispose_fn on the dropped value.
32755         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
32756         (gl_tree_remove_node): Call dispose_fn on the dropped value.
32757         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
32758         argument.
32759         (gl_tree_list_free): Call dispose_fn on the dropped values.
32760         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
32761         the dropped values.
32762         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
32763         Add dispose_fn argument.
32764         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
32765         Call dispose_fn on the dropped values.
32766         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
32767         Add dispose_fn argument.
32768         (gl_sublist_create): Initialize the 'dispose_fn' field.
32769         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
32770         * tests/test-array_list.c (main): Update.
32771         * tests/test-carray_list.c (main): Update.
32772         * tests/test-avltree_list.c (main): Update.
32773         * tests/test-rbtree_list.c (main): Update.
32774         * tests/test-avltreehash_list.c (main): Update.
32775         * tests/test-rbtreehash_list.c (main): Update.
32776         * tests/test-linked_list.c (main): Update.
32777         * tests/test-linkedhash_list.c (main): Update.
32778         * tests/test-array_oset.c (main): Update.
32779
32780 2007-03-15  Bruno Haible  <bruno@clisp.org>
32781
32782         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
32783         (gl_oset_create_empty): Add dispose_fn argument.
32784         (struct gl_oset_implementation): Add dispose_fn argument to
32785         'create_empty' method.
32786         (struct gl_oset_impl_base): Add dispose_fn field.
32787         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
32788         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
32789         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
32790         values.
32791         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
32792         (gl_tree_oset_free): Call dispose_fn on the dropped values.
32793         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
32794         dropped value.
32795         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
32796         dropped value.
32797         * tests/test-array_oset.c (main): Update.
32798         * tests/test-avltree_oset.c (main): Update.
32799         * tests/test-rbtree_oset.c (main): Update.
32800         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
32801
32802 2007-03-13  Bruno Haible  <bruno@clisp.org>
32803
32804         * tests/test-stdbool.c (i): Update after last patch.
32805
32806 2007-03-12  Bruno Haible  <bruno@clisp.org>
32807
32808         * lib/quotearg.c: Include <wctype.h> early, before the definition of
32809         the iswprint macro. Needed on Solaris 2.5.1.
32810
32811 2007-03-12  Bruno Haible  <bruno@clisp.org>
32812
32813         * tests/test-printf-frexp.c (main): Declare x as volatile.
32814
32815 2007-03-12  Simon Josefsson  <simon@josefsson.org>
32816
32817         * doc/gnulib.texi (Build robot for gnulib): New section.
32818
32819 2007-03-12  Jim Meyering  <jim@meyering.net>
32820
32821         * build-aux/bootstrap: New file.
32822         * build-aux/bootstrap.conf: New file, from coreutils.
32823
32824 2007-03-11  Bruno Haible  <bruno@clisp.org>
32825
32826         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
32827
32828 2007-03-12  Simon Josefsson  <simon@josefsson.org>
32829
32830         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
32831         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
32832         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
32833
32834 2007-03-11  Bruno Haible  <bruno@clisp.org>
32835
32836         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
32837         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
32838
32839 2007-03-11  Bruno Haible  <bruno@clisp.org>
32840
32841         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
32842         formula. Needed for SunPRO C 5.0.
32843
32844 2007-03-11  Bruno Haible  <bruno@clisp.org>
32845
32846         * modules/long-options (Depends-on): Add getopt.
32847
32848 2007-03-11  Bruno Haible  <bruno@clisp.org>
32849
32850         * modules/modechange (Depends-on): Add stdbool.
32851
32852 2007-03-11  Bruno Haible  <bruno@clisp.org>
32853
32854         * modules/i-ring (Depends-on): Add stdbool.
32855
32856 2007-03-11  Bruno Haible  <bruno@clisp.org>
32857
32858         * modules/gc-des (Depends-on): Add stdbool.
32859
32860 2007-03-11  Bruno Haible  <bruno@clisp.org>
32861
32862         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
32863
32864 2007-03-11  Bruno Haible  <bruno@clisp.org>
32865
32866         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
32867
32868 2007-03-11  Bruno Haible  <bruno@clisp.org>
32869
32870         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
32871
32872 2007-03-11  Bruno Haible  <bruno@clisp.org>
32873
32874         * lib/vasnprintf.c (sprintf): Undefine.
32875
32876 2007-03-11  Bruno Haible  <bruno@clisp.org>
32877
32878         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
32879         initializers in SunPRO C and Compaq C compilers.
32880
32881 2007-03-11  Bruno Haible  <bruno@clisp.org>
32882
32883         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
32884         decrementing code ANSI C compliant.
32885
32886 2007-03-11  Bruno Haible  <bruno@clisp.org>
32887
32888         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
32889         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
32890
32891 2007-03-11  Bruno Haible  <bruno@clisp.org>
32892
32893         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
32894         <stdbool.h> substitute doesn't pass.
32895
32896 2007-03-11  Bruno Haible  <bruno@clisp.org>
32897
32898         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
32899
32900 2007-03-11  Bruno Haible  <bruno@clisp.org>
32901
32902         * gnulib-tool (func_create_megatestdir): Create also an autobuild
32903         script, for submission to autobuild.josefsson.org.
32904
32905 2007-03-10  Bruno Haible  <bruno@clisp.org>
32906
32907         * modules/canonicalize-lgpl-tests: New file.
32908         * tests/test-canonicalize-lgpl.sh: New file.
32909         * tests/test-canonicalize-lgpl.c: New file.
32910
32911         * modules/c-strcase-tests: New file.
32912         * tests/test-c-strcase.sh: New file.
32913         * tests/test-c-strcasecmp.c: New file.
32914         * tests/test-c-strncasecmp.c: New file.
32915
32916         * modules/atexit-tests: New file.
32917         * tests/test-atexit.sh: New file.
32918         * tests/test-atexit.c: New file.
32919
32920 2007-03-10  Bruno Haible  <bruno@clisp.org>
32921
32922         * tests/test-binary-io.sh: Use temporary filenames that are not so
32923         likely to clash with those of other tests (in a parallel make).
32924         * tests/test-binary-io.c: Likewise.
32925
32926 2007-03-10  Bruno Haible  <bruno@clisp.org>
32927
32928         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
32929         fallback; use #error instead.
32930         Suggested by Simon Josefsson.
32931
32932 2007-03-10  Bruno Haible  <bruno@clisp.org>
32933
32934         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
32935         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
32936         first and the last.
32937
32938 2007-03-10  Bruno Haible  <bruno@clisp.org>
32939
32940         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
32941
32942 2007-03-10  Bruno Haible  <bruno@clisp.org>
32943
32944         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
32945         "make distcheck".
32946         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
32947         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
32948         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
32949
32950 2007-03-10  Bruno Haible  <bruno@clisp.org>
32951
32952         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
32953         variable.
32954         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
32955         variable.
32956
32957 2007-03-09  Eric Blake  <ebb9@byu.net>
32958         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
32959
32960         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
32961         types are not being provided by gnulib.
32962         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
32963         types are supported.
32964
32965 2007-03-10  Bruno Haible  <bruno@clisp.org>
32966
32967         * lib/stdio_.h (__attribute__): New macro.
32968         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
32969         vsprintf): Specify __attribute__ __format__ for GCC.
32970         Suggested by Eric Blake.
32971
32972 2007-03-09  Bruno Haible  <bruno@clisp.org>
32973
32974         * modules/printf-posix-tests: New file.
32975         * tests/test-printf-posix.sh: New file.
32976         * tests/test-printf-posix.c: New file.
32977
32978         * modules/printf-posix: New file.
32979         * lib/printf.c: New file.
32980         * m4/printf-posix-rpl.m4: New file.
32981         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
32982         REPLACE_PRINTF.
32983         * lib/stdio_.h (printf): New declaration.
32984         (format, __format__, ____printf____, ____scanf____, ____strftime____,
32985         ____strfmon____): New macros.
32986         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
32987         REPLACE_PRINTF.
32988
32989 2007-03-09  Bruno Haible  <bruno@clisp.org>
32990
32991         * tests/test-vasnprintf-posix2.sh: New file.
32992         * tests/test-vasnprintf-posix2.c: New file.
32993         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
32994         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
32995         (Makefile.am): Activate test-vasnprintf-posix2.sh.
32996
32997         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
32998         a locale dependent decimal point, rather than always '.'.
32999
33000 2007-03-09  Eric Blake  <ebb9@byu.net>
33001
33002         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
33003         spite of platforms like Tandem/NSK that define it to -1.
33004
33005 2007-03-08  Bruno Haible  <bruno@clisp.org>
33006
33007         * modules/vprintf-posix-tests: New file.
33008         * tests/test-vprintf-posix.sh: New file.
33009         * tests/test-vprintf-posix.c: New file.
33010         * tests/test-printf-posix.h: New file.
33011
33012         * modules/vprintf-posix: New file.
33013         * lib/vprintf.c: New file.
33014         * m4/vprintf-posix.m4: New file.
33015         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
33016         REPLACE_VPRINTF.
33017         * lib/stdio_.h (vprintf): New declaration.
33018         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
33019         REPLACE_VPRINTF.
33020
33021 2007-03-08  Bruno Haible  <bruno@clisp.org>
33022
33023         * modules/fprintf-posix-tests: New file.
33024         * tests/test-fprintf-posix.sh: New file.
33025         * tests/test-fprintf-posix.c: New file.
33026
33027         * modules/fprintf-posix: New file.
33028         * lib/fprintf.c: New file.
33029         * m4/fprintf-posix.m4: New file.
33030         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
33031         REPLACE_FPRINTF.
33032         * lib/stdio_.h (fprintf): New declaration.
33033         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
33034         REPLACE_FPRINTF.
33035
33036 2007-03-08  Bruno Haible  <bruno@clisp.org>
33037
33038         * modules/vfprintf-posix-tests: New file.
33039         * tests/test-vfprintf-posix.sh: New file.
33040         * tests/test-vfprintf-posix.c: New file.
33041         * tests/test-fprintf-posix.h: New file.
33042         * tests/test-fprintf-posix.out: New file.
33043
33044         * modules/vfprintf-posix: New file.
33045         * lib/vfprintf.c: New file.
33046         * m4/vfprintf-posix.m4: New file.
33047         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
33048         REPLACE_VFPRINTF.
33049         * lib/stdio_.h (vfprintf): New declaration.
33050         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
33051         REPLACE_VFPRINTF.
33052
33053 2007-03-08  Bruno Haible  <bruno@clisp.org>
33054
33055         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
33056
33057 2007-03-08  Bruno Haible  <bruno@clisp.org>
33058
33059         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
33060         instead of 'expr' invocations.
33061         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
33062         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
33063         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
33064         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
33065         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
33066         Suggested by Paul Eggert.
33067
33068 2007-03-08  Bruno Haible  <bruno@clisp.org>
33069
33070         * modules/fseterr-tests: New file.
33071         * tests/test-fseterr.c: New file.
33072
33073         * modules/fseterr: New file.
33074         * lib/fseterr.h: New file.
33075         * lib/fseterr.c: New file.
33076
33077 2007-03-08  Bruno Haible  <bruno@clisp.org>
33078
33079         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
33080         * lib/getopt_.h: Likewise.
33081         * lib/mbswidth.h: Likewise.
33082         * lib/setenv.h: Likewise.
33083         * lib/vasnprintf.h: Likewise.
33084         * lib/vasprintf.h: Likewise.
33085         * lib/verror.h: Likewise.
33086         * lib/xsetenv.h: Likewise.
33087         * lib/xvasprintf.h: Likewise.
33088
33089 2007-03-08  Jim Meyering  <jim@meyering.net>
33090
33091         * users.txt: Add parted.
33092
33093         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
33094
33095 2007-03-07  Bruno Haible  <bruno@clisp.org>
33096
33097         * m4/printf.m4: Make the shell script snippets copy&pastable.
33098
33099 2007-03-02  Bruno Haible  <bruno@clisp.org>
33100
33101         * lib/netinet_in_.h: New file.
33102         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
33103         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
33104         * modules/netinet_in (Files): Add lib/netinet_in_.h.
33105         (Depends-on): Add absolute-header.
33106         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
33107         into netinet/in.h.
33108
33109 2007-03-03  Bruno Haible  <bruno@clisp.org>
33110
33111         * lib/sys_select_.h: New file.
33112         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
33113         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
33114         * modules/sys_select (Files): Add lib/sys_select_.h.
33115         (Depends-on): Add absolute-header.
33116         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
33117         into sys/select.h.
33118
33119 2007-03-02  Bruno Haible  <bruno@clisp.org>
33120
33121         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
33122         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
33123         values.
33124         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
33125         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
33126         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
33127         * modules/sys_socket (Depends-on): Add absolute-header.
33128         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
33129         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
33130         (Include): Remove requirement of inclusion of <sys/types.h>.
33131
33132 2007-03-02  Bruno Haible  <bruno@clisp.org>
33133
33134         * lib/byteswap_.h (bswap_32): Fix formula.
33135
33136 2007-03-06  Bruno Haible  <bruno@clisp.org>
33137
33138         * modules/sprintf-posix-tests: New file.
33139         * tests/test-sprintf-posix.c: New file.
33140
33141         * modules/sprintf-posix: New file.
33142         * lib/sprintf.c: New file.
33143         * m4/sprintf-posix.m4: New file.
33144         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
33145         REPLACE_SPRINTF.
33146         * lib/stdio_.h (sprintf): New declaration.
33147         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
33148         REPLACE_SPRINTF.
33149
33150 2007-03-06  Bruno Haible  <bruno@clisp.org>
33151
33152         * modules/vsprintf-posix-tests: New file.
33153         * tests/test-vsprintf-posix.c: New file.
33154         * tests/test-sprintf-posix.h: New file.
33155
33156         * modules/vsprintf-posix: New file.
33157         * lib/vsprintf.c: New file.
33158         * m4/vsprintf-posix.m4: New file.
33159         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
33160         REPLACE_VSPRINTF.
33161         * lib/stdio_.h (vsprintf): New declaration.
33162         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
33163         REPLACE_VSPRINTF.
33164
33165 2007-03-06  Bruno Haible  <bruno@clisp.org>
33166
33167         * modules/vsnprintf (Depend-on): Remove minmax.
33168
33169 2007-03-06  Bruno Haible  <bruno@clisp.org>
33170
33171         * modules/snprintf-posix-tests: New file.
33172         * tests/test-snprintf-posix.c: New file.
33173
33174         * modules/snprintf-posix: New file.
33175         * m4/snprintf-posix.m4: New file.
33176         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
33177         gl_FUNC_SNPRINTF.
33178         (gl_FUNC_SNPRINTF): Invoke it.
33179         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
33180         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
33181         is set.
33182         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
33183
33184 2007-03-06  Bruno Haible  <bruno@clisp.org>
33185
33186         * modules/vsnprintf-posix-tests: New file.
33187         * tests/test-vsnprintf-posix.c: New file.
33188         * tests/test-snprintf-posix.h: New file.
33189
33190         * modules/vsnprintf-posix: New file.
33191         * m4/vsnprintf-posix.m4: New file.
33192         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
33193         gl_FUNC_VSNPRINTF.
33194         (gl_FUNC_VSNPRINTF): Invoke it.
33195         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
33196         * lib/stdio_.h (vsnprintf): Define as a replacement if
33197         REPLACE_VSNPRINTF is set.
33198         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
33199
33200 2007-03-06  Bruno Haible  <bruno@clisp.org>
33201
33202         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
33203         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
33204
33205 2007-03-06  Bruno Haible  <bruno@clisp.org>
33206
33207         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
33208         (asinl): Declare also if HAVE_DECL_ASINL is set.
33209         (atanl): Declare also if HAVE_DECL_ATANL is set.
33210         (ceill): Declare also if HAVE_DECL_CEILL is set.
33211         (cosl): Declare also if HAVE_DECL_COSL is set.
33212         (expl): Declare also if HAVE_DECL_EXPL is set.
33213         (floorl): Declare also if HAVE_DECL_FLOORL is set.
33214         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
33215         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
33216         (logl): Declare also if HAVE_DECL_LOGL is set.
33217         (sinl): Declare also if HAVE_DECL_SINL is set.
33218         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
33219         (tanl): Declare also if HAVE_DECL_TANL is set.
33220         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
33221         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
33222         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
33223         declaration of frexpl, ldexpl.
33224         * modules/printf-frexpl (Depends-on): Add math.
33225         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
33226
33227 2007-03-05  Bruno Haible  <bruno@clisp.org>
33228
33229         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
33230         frexpl and ldexpl are declared.
33231         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
33232
33233 2007-03-05  Bruno Haible  <bruno@clisp.org>
33234
33235         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
33236         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
33237
33238 2007-03-05  Bruno Haible  <bruno@clisp.org>
33239
33240         * lib/stdio_.h: Include <stddef.h>.
33241
33242 2007-03-05  Bruno Haible  <bruno@clisp.org>
33243
33244         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
33245
33246 2007-03-05  Bruno Haible  <bruno@clisp.org>
33247
33248         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
33249         NetBSD 4, from Ralf Wildenhues.
33250
33251 2007-03-04  Bruno Haible  <bruno@clisp.org>
33252
33253         * lib/vasprintf.h: Update #if logic for the case when the functions
33254         exist but are overridden.
33255
33256 2007-03-04  Bruno Haible  <bruno@clisp.org>
33257
33258         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
33259         implementations: glibc-2.4 and MacOS X 10.3.
33260         * tests/test-vasnprintf-posix.c (test_function): Test also the case
33261         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
33262         * tests/test-vasprintf-posix.c (test_function): Likewise.
33263
33264 2007-03-04  Bruno Haible  <bruno@clisp.org>
33265
33266         * modules/vasprintf-posix-tests: New file.
33267         * tests/test-vasprintf-posix.c: New file.
33268
33269         * modules/vasprintf-posix: New file.
33270         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
33271         defined.
33272         * m4/vasprintf-posix.m4: New file.
33273         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
33274         gl_FUNC_VASPRINTF.
33275         (gl_FUNC_VASPRINTF): Invoke it.
33276         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
33277         here.
33278         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
33279
33280 2007-03-04  Bruno Haible  <bruno@clisp.org>
33281
33282         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
33283         REPLACE_GETTIMEOFDAY.
33284         * modules/sys_time (Makefile.am): Likewise.
33285         * m4/sys_time_h.m4: Likewise.
33286         * m4/gettimeofday.m4: Likewise.
33287
33288 2007-03-04  Bruno Haible  <bruno@clisp.org>
33289
33290         * modules/vasnprintf-posix-tests: New file.
33291         * tests/test-vasnprintf-posix.c: New file.
33292
33293         * modules/vasnprintf-posix: New file.
33294         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
33295         printf-frexpl.h.
33296         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
33297         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
33298         REPLACE_VASNPRINTF is defined.
33299         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
33300         gl_FUNC_VASNPRINTF.
33301         (gl_FUNC_VASNPRINTF): Invoke it.
33302         * m4/vasnprintf-posix.m4: New file.
33303         * m4/printf.m4: New file.
33304
33305 2007-03-04  Bruno Haible  <bruno@clisp.org>
33306
33307         Compile progreloc.c only if --enable-relocatable is specified.
33308         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
33309         if --enable-relocatable was specified.
33310         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
33311         lib_SOURCES.
33312
33313 2007-03-04  Jim Meyering  <jim@meyering.net>
33314
33315         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
33316         Use it consistently, rather than enumerating errno constants.
33317
33318 2007-03-04  Bruno Haible  <bruno@clisp.org>
33319
33320         * modules/xvasprintf-tests: New file.
33321         * tests/test-xvasprintf.c: New file.
33322
33323         * modules/vasprintf-tests: New file.
33324         * tests/test-vasprintf.c: New file.
33325
33326         * modules/vasnprintf-tests: New file.
33327         * tests/test-vasnprintf.c: New file.
33328
33329         * modules/vsnprintf-tests: New file.
33330         * tests/test-vsnprintf.c: New file.
33331
33332         * modules/snprintf-tests: New file.
33333         * tests/test-snprintf.c: New file.
33334
33335 2007-03-04  Bruno Haible  <bruno@clisp.org>
33336
33337         Compile relocatable.c only if --enable-relocatable is specified.
33338         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
33339         gl_RELOCATABLE_LIBRARY.
33340         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
33341         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
33342         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
33343         gl_RELOCATABLE_LIBRARY.
33344         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
33345         (Makefile.am): Remove lib_SOURCES.
33346         * modules/relocatable-lib-lgpl (configure.ac): Invoke
33347         gl_RELOCATABLE_LIBRARY.
33348         (Makefile.am): Remove lib_SOURCES.
33349         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
33350         always.
33351         * modules/relocatable-prog-wrapper (configure.ac): Invoke
33352         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
33353
33354 2007-03-04  Bruno Haible  <bruno@clisp.org>
33355
33356         * modules/argmatch-tests: New file.
33357         * tests/test-argmatch.c: New file.
33358
33359         * tests/test-allocsa.c (main): Halve the number of loop runs.
33360
33361         * modules/alloca-opt-tests: New file.
33362         * tests/test-alloca-opt.c: New file.
33363
33364 2007-03-04  Jim Meyering  <jim@meyering.net>
33365
33366         Work around difference between Linux ACLs and Solaris 10 ZFS.
33367         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
33368         for EINVAL.
33369
33370 2007-03-03  Bruno Haible  <bruno@clisp.org>
33371
33372         * modules/relocatable-prog (Depends-on): Add back progreloc's
33373         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
33374
33375 2007-03-03  Bruno Haible  <bruno@clisp.org>
33376
33377         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
33378         * modules/relocatable-lib: New file.
33379
33380 2007-03-03  Bruno Haible  <bruno@clisp.org>
33381
33382         * modules/relocatable-prog: Renamed from modules/relocatable.
33383         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
33384
33385 2007-03-03  Bruno Haible  <bruno@clisp.org>
33386
33387         * modules/relocatable-script (Files): Add doc/relocatable.texi,
33388         m4/relocatable-lib.m4.
33389         (Depends-on): Remove 'relocatable'.
33390         (configure.ac): Add gl_RELOCATABLE_NOP.
33391
33392 2007-03-03  Bruno Haible  <bruno@clisp.org>
33393
33394         * modules/relocatable-prog-wrapper: New file.
33395         * modules/relocatable (Depends-on): Add it. Remove all other
33396         dependencies except progname.
33397         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
33398
33399         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
33400         (gl_FUNC_STRERROR): Nop.
33401         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
33402
33403         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
33404         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
33405
33406         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
33407         (gl_FUNC_READLINK): Update.
33408
33409         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
33410
33411 2007-03-03  Bruno Haible  <bruno@clisp.org>
33412
33413         * lib/xreadlink.c: Include <unistd.h> unconditionally.
33414         * modules/xreadlink (Depends-on): Add unistd.
33415         * modules/xreadlink-with-size (Depends-on): Likewise.
33416
33417 2007-03-03  Bruno Haible  <bruno@clisp.org>
33418
33419         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
33420         extracted from gt_FUNC_SETENV.
33421         (gt_FUNC_SETENV): Remove macro.
33422         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
33423         remove gt_FUNC_SETENV.
33424
33425 2007-03-03  Bruno Haible  <bruno@clisp.org>
33426
33427         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
33428         ENABLE_RELOCATABLE here.
33429         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
33430
33431 2007-03-03  Bruno Haible  <bruno@clisp.org>
33432
33433         * modules/rbtreehash-list-tests (Depends-on): Add progname.
33434         * tests/test-rbtreehash_list.c: Include progname.h.
33435         (main): Call set_program_name.
33436
33437         * modules/rbtree-oset-tests (Depends-on): Add progname.
33438         * tests/test-rbtree_oset.c: Include progname.h.
33439         (main): Call set_program_name.
33440
33441         * modules/rbtree-list-tests (Depends-on): Add progname.
33442         * tests/test-rbtree_list.c: Include progname.h.
33443         (main): Call set_program_name.
33444
33445         * modules/linked-list-tests (Depends-on): Add progname.
33446         * tests/test-linked_list.c: Include progname.h.
33447         (main): Call set_program_name.
33448
33449 2007-03-03  Bruno Haible  <bruno@clisp.org>
33450
33451         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
33452         All uses of __restrict changed to _Restrict_.
33453         * lib/glob_.h (__restrict): Remove macro.
33454
33455 2007-03-02  Bruno Haible  <bruno@clisp.org>
33456
33457         * modules/gettext (configure.ac): Require gettext infrastructure
33458         from version 0.16.1.
33459
33460 2007-03-02  Bruno Haible  <bruno@clisp.org>
33461
33462         * modules/linkedhash-list-tests (Depends-on): Add progname.
33463         * tests/test-linkedhash_list.c: Include progname.h.
33464         (main): Call set_program_name.
33465
33466         * modules/carray-list-tests (Depends-on): Add progname.
33467         * tests/test-carray_list.c: Include progname.h.
33468         (main): Call set_program_name.
33469
33470         * modules/avltreehash-list-tests (Depends-on): Add progname.
33471         * tests/test-avltreehash_list.c: Include progname.h.
33472         (main): Call set_program_name.
33473
33474         * modules/avltree-oset-tests (Depends-on): Add progname.
33475         * tests/test-avltree_oset.c: Include progname.h.
33476         (main): Call set_program_name.
33477
33478         * modules/avltree-list-tests (Depends-on): Add progname.
33479         * tests/test-avltree_list.c: Include progname.h.
33480         (main): Call set_program_name.
33481
33482         * modules/array-oset-tests (Depends-on): Add progname.
33483         * tests/test-array_oset.c: Include progname.h.
33484         (main): Call set_program_name.
33485
33486         * modules/array-list-tests (Depends-on): Add progname.
33487         * tests/test-array_list.c: Include progname.h.
33488         (main): Call set_program_name.
33489
33490         * modules/argp-tests (Depends-on): Add progname.
33491         * tests/test-argp.c: Include argp.h first. Include progname.h.
33492         (main): Call set_program_name.
33493
33494 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
33495
33496         * doc/gnulib-tool.texi (Initial import): Reword description of
33497         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
33498         limited effect even if defined after the first system include.
33499
33500 2007-03-01  Bruno Haible  <bruno@clisp.org>
33501
33502         * build-aux/config.libpath: Update to libtool-1.5.22.
33503         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
33504
33505 2007-03-01  Bruno Haible  <bruno@clisp.org>
33506
33507         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
33508         foo_CFLAGS.
33509         Reported by Ralf Wildenhues.
33510
33511 2007-03-01  Bruno Haible  <bruno@clisp.org>
33512
33513         * build-aux/install-reloc: Remove object files left over by some
33514         compilers.
33515         Reported by Ralf Wildenhues.
33516
33517 2007-03-01  Bruno Haible  <bruno@clisp.org>
33518
33519         * build-aux/install-reloc: Break long lines.
33520
33521 2007-03-01  Bruno Haible  <bruno@clisp.org>
33522
33523         * doc/relocatable.texi: Document that it may not work on OpenBSD.
33524         Reported by Ralf Wildenhues.
33525
33526 2007-03-01  Bruno Haible  <bruno@clisp.org>
33527
33528         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
33529         include ordering constraints.
33530
33531 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
33532
33533         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
33534         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
33535         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
33536         as another example.
33537         * lib/time_.h: Fix misspelling.
33538         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
33539         Require gl_HEADER_TIME_H_DEFAULTS.
33540         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
33541         * m4/time_r.m4 (gl_TIME_R): Likewise.
33542         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
33543
33544 2007-03-01  Bruno Haible  <bruno@clisp.org>
33545
33546         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
33547         * m4/utimens.m4 (gl_UTIMENS): Likewise.
33548
33549 2007-03-01  Jim Meyering  <jim@meyering.net>
33550
33551         * modules/xreadlink (Maintainer): Add my name.
33552         * modules/xreadlink-with-size (Depends-on): Alphabetize.
33553
33554 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
33555             Bruno Haible  <bruno@clisp.org>
33556
33557         * build-aux/install-reloc: Compile also c-ctype.c.
33558         * build-aux/relocatable.sh.in: New file.
33559         * doc/relocatable.texi: New file.
33560         * doc/relocatable-maint.texi: New file.
33561         * doc/gnulib.texi: Include relocatable-maint.texi.
33562         * lib/progreloc.c: Include unistd.h unconditionally.
33563         * lib/relocwrapper.c: Include unistd.h unconditionally.
33564         Include c-ctype.h.
33565         (add_dotbin): Use c_tolower.
33566         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
33567         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
33568         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
33569         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
33570         to m4/relocatable-lib.m4.
33571         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
33572         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
33573         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
33574         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
33575         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
33576         * modules/relocatable: New file.
33577         * modules/relocatable-lib: New file.
33578         * modules/relocatable-script: New file.
33579
33580 2007-02-28  Bruno Haible  <bruno@clisp.org>
33581
33582         Import --enable-relocatable infrastructure.
33583         * build-aux/config.libpath: New file, from GNU gettext.
33584         * build-aux/install-reloc: New file, from GNU gettext.
33585         * build-aux/reloc-ldflags: New file, from GNU gettext.
33586         * lib/relocatable.h: New file, from GNU gettext.
33587         * lib/relocatable.c: New file, from GNU gettext.
33588         * lib/relocwrapper.c: New file, from GNU gettext.
33589         * m4/relocatable.m4: New file, from GNU gettext.
33590
33591 2007-02-28  Bruno Haible  <bruno@clisp.org>
33592
33593         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
33594
33595         * modules/xreadlink: New file, from GNU gettext with modifications.
33596         * lib/xreadlink.c: New file, from GNU gettext.
33597         * lib/xreadlink.h: Add comments.
33598         (xreadlink): New declaration.
33599
33600         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
33601         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
33602         lib/xreadlink-with-size.c.
33603         (configure.ac): Remove gl_XREADLINK invocation.
33604         (Makefile.am): Augment lib_SOURCES.
33605         * m4/xreadlink.m4: Remove file.
33606         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
33607         (xreadlink_with_size): Renamed from xreadink.
33608         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
33609         * modules/canonicalize (Depends-on): Replace xreadlink with
33610         xreadlink-with-size.
33611         * lib/canonicalize.c (canonicalize_filename_mode): Update.
33612
33613 2007-02-25  Jim Meyering  <jim@meyering.net>
33614
33615         * build-aux/announce-gen: When complaining about excess arguments,
33616         list them.
33617
33618 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
33619
33620         * README: Document signed integer overflow situation more
33621         accurately.
33622
33623 2007-02-25  Bruno Haible  <bruno@clisp.org>
33624
33625         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
33626         'a' or 'A' conversion.
33627
33628 2007-02-25  Bruno Haible  <bruno@clisp.org>
33629
33630         * modules/filename: Renamed from modules/pathname.
33631         (Files): Replace lib/pathname.h with lib/filename.h. Replace
33632         lib/concatpath.c with lib/concat-filename.c.
33633         (Makefile.am): Update.
33634         (Include): Replace pathname.h with filename.h.
33635         * lib/filename.h: Renamed from lib/pathname.h.
33636         (concatenated_filename): Renamed from concatenated_pathname.
33637         * lib/concat-filename.c: Renamed from lib/concatpath.c.
33638         (concatenated_filename): Renamed from concatenated_pathname.
33639         * lib/findprog.c: Include filename.h instead of pathname.h.
33640         (find_in_path): Update.
33641         * lib/javacomp.c: Include filename.h instead of pathname.h.
33642         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
33643         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
33644         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
33645         is_oldgcj_14_13_usable, is_javac_usable): Update.
33646         * lib/javaexec.c: Include filename.h instead of pathname.h.
33647         (execute_java_class): Update.
33648         * modules/findprog: Update.
33649         * modules/javacomp: Update.
33650         * modules/javaexec: Update.
33651         * MODULES.html.sh (File system functions): Add 'filename', remove
33652         'pathname'.
33653
33654 2007-02-25  Bruno Haible  <bruno@clisp.org>
33655
33656         * modules/printf-frexpl-tests: New file.
33657         * tests/test-printf-frexpl.c: New file.
33658
33659         * modules/printf-frexpl: New file.
33660         * lib/printf-frexpl.h: New file.
33661         * lib/printf-frexpl.c: New file.
33662         * m4/printf-frexpl.m4: New file.
33663
33664 2007-02-25  Bruno Haible  <bruno@clisp.org>
33665
33666         * modules/printf-frexp-tests: New file.
33667         * tests/test-printf-frexp.c: New file.
33668
33669         * modules/printf-frexp: New file.
33670         * lib/printf-frexp.h: New file.
33671         * lib/printf-frexp.c: New file.
33672         * m4/printf-frexp.m4: New file.
33673
33674 2007-02-25  Bruno Haible  <bruno@clisp.org>
33675
33676         Assume automake >= 1.10 for the tests.
33677         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
33678         * modules/arctwo-tests: Likewise.
33679         * modules/argp-tests: Likewise.
33680         * modules/avltree-list-tests: Likewise.
33681         * modules/avltree-oset-tests: Likewise.
33682         * modules/avltreehash-list-tests: Likewise.
33683         * modules/carray-list-tests: Likewise.
33684         * modules/crc-tests: Likewise.
33685         * modules/des-tests: Likewise.
33686         * modules/gc-arcfour-tests: Likewise.
33687         * modules/gc-arctwo-tests: Likewise.
33688         * modules/gc-des-tests: Likewise.
33689         * modules/gc-hmac-md5-tests: Likewise.
33690         * modules/gc-hmac-sha1-tests: Likewise.
33691         * modules/gc-md2-tests: Likewise.
33692         * modules/gc-md4-tests: Likewise.
33693         * modules/gc-md5-tests: Likewise.
33694         * modules/gc-pbkdf2-sha1-tests: Likewise.
33695         * modules/gc-rijndael-tests: Likewise.
33696         * modules/gc-sha1-tests: Likewise.
33697         * modules/gc-tests: Likewise.
33698         * modules/getaddrinfo-tests: Likewise.
33699         * modules/hmac-md5-tests: Likewise.
33700         * modules/hmac-sha1-tests: Likewise.
33701         * modules/linked-list-tests: Likewise.
33702         * modules/linkedhash-list-tests: Likewise.
33703         * modules/lock-tests: Likewise.
33704         * modules/md2-tests: Likewise.
33705         * modules/md4-tests: Likewise.
33706         * modules/md5-tests: Likewise.
33707         * modules/rbtree-list-tests: Likewise.
33708         * modules/rbtree-oset-tests: Likewise.
33709         * modules/rbtreehash-list-tests: Likewise.
33710         * modules/read-file-tests: Likewise.
33711         * modules/rijndael-tests: Likewise.
33712         * modules/stdint-tests: Likewise.
33713         * modules/tls-tests: Likewise.
33714
33715 2007-02-24  Bruno Haible  <bruno@clisp.org>
33716
33717         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
33718         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
33719         function; instead check whether isnan with a double argument links.
33720         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
33721         function; instead check whether isnan with a 'long double' argument
33722         links.
33723         Reported by Eric Blake <ebb9@byu.net>.
33724
33725 2007-02-24  Bruno Haible  <bruno@clisp.org>
33726
33727         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
33728         defined.
33729         * lib/isnanl.c: Remove all code. Just include isnan.c.
33730         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
33731
33732 2007-02-25  Jim Meyering  <jim@meyering.net>
33733
33734         Avoid conflicting types for 'unsetenv' on FreeBSD.
33735         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
33736         conflicting with FreeBSD's (5.0 and 6.1) function declaration
33737         in stdlib.h.
33738
33739 2007-02-24  Bruno Haible  <bruno@clisp.org>
33740
33741         * modules/isnanl-nolibm-tests: New file.
33742         * tests/test-isnanl.c: New file.
33743
33744         * modules/isnanl-nolibm: New file.
33745         * lib/isnanl.h: New file.
33746         * lib/isnanl.c: New file.
33747         * m4/isnanl.m4: New file.
33748
33749 2007-02-24  Bruno Haible  <bruno@clisp.org>
33750
33751         * modules/isnan-nolibm-tests: New file.
33752         * tests/test-isnan.c: New file.
33753
33754         * modules/isnan-nolibm: New file.
33755         * lib/isnan.h: New file.
33756         * lib/isnan.c: New file.
33757         * m4/isnan.m4: New file.
33758
33759 2007-02-24  Bruno Haible  <bruno@clisp.org>
33760
33761         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
33762         assume that an exponent fits in 20 bits.
33763
33764 2007-02-24  Jim Meyering  <jim@meyering.net>
33765
33766         * m4/regex.m4: Update the description of the configure-time option,
33767         --without-included-regex, to state accurately what the defaults are,
33768         and perhaps to give people an idea why using this option is risky.
33769
33770 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
33771
33772         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
33773         loops on small arguments.  This attempts to avoid the problem
33774         Bruno Haible reported for AIX 4.3.2 in
33775         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
33776
33777 2007-02-23  Bruno Haible  <bruno@clisp.org>
33778
33779         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
33780         Needed for help2man.
33781
33782 2007-02-23  Karl Berry  <karl@gnu.org>
33783
33784         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
33785         exists, foo.h should be cvs-ignored, not committed.
33786
33787 2007-02-23  Eric Blake  <ebb9@byu.net>
33788
33789         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
33790         * lib/stat-time.h (includes): Likewise.
33791         * lib/utimecmp.c (includes): Likewise.
33792         * lib/utimens.h (includes): Likewise.
33793         * lib/getdate.y (includes): Also include "timespec.h" for use
33794         internal to the module.
33795         * modules/utimens (Depends-on): Revert yesterday's patch.
33796         * modules/nanosleep (Depends-on): Add missing dependency.
33797
33798 2007-02-22  Bruno Haible  <bruno@clisp.org>
33799
33800         * lib/glob.c: Don't include getlogin_r.h.
33801
33802 2007-02-22  Jim Meyering  <jim@meyering.net>
33803
33804         * modules/utimens (Depends-on): Add timespec, required for
33805         utimens.h's inclusion of timespec.h.
33806
33807 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
33808
33809         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
33810         long unreadable paths in GNU/Linux.  Problem reported by Andreas
33811         Schwab in
33812         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
33813         I'll try to think of a better way to fix the Solaris problem.
33814
33815         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
33816         like glibc; on Solaris 10, it fails with errno == EINVAL.
33817         POSIX says the behavior is unspecified if the first argument is NULL,
33818         so play it safe and never pass NULL to the system getcwd.
33819
33820 2007-02-21  Jim Meyering  <jim@meyering.net>
33821
33822         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
33823         of gettimeofday.  It would conflict with the one now always
33824         provided via sys_time_.h.  Reported by Matthew Woehlke, as
33825         an IRIX 6.5 build failure.
33826
33827 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
33828
33829         Minor fixups to port to Solaris 10 with Sun C 5.8.
33830         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
33831         * modules/getcwd (Depends-on): Add dirfd.
33832         * lib/putenv.c (putenv): #undef it.
33833         (rpl_putenv): New decl.
33834         (malloc, free): Include <stdlib.h> rather than prototyping separately.
33835
33836 2007-02-20  Bruno Haible  <bruno@clisp.org>
33837
33838         * modules/stdio-tests: New file.
33839         * tests/test-stdio.c: New file.
33840
33841         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
33842         (Depends-on): Add stdio.
33843         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
33844         (Include): Use <stdio.h> instead of vsnprintf.h.
33845         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
33846         HAVE_DECL_VSNPRINTF.
33847         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
33848
33849         * modules/snprintf (Files): Remove lib/snprintf.h.
33850         (Depends-on): Add stdio.
33851         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
33852         (Include): Use <stdio.h> instead of snprintf.h.
33853         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
33854         HAVE_DECL_SNPRINTF.
33855         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
33856         * lib/getaddrinfo.c: Likewise.
33857
33858         * modules/stdio: New file.
33859         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
33860         * lib/snprintf.h: Remove file.
33861         * lib/vsnprintf.h: Remove file.
33862         * lib/.cppi-disable: Remove snprintf.h.
33863         * m4/stdio_h.m4: New file.
33864         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
33865
33866 2007-02-20  Jim Meyering  <jim@meyering.net>
33867
33868         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
33869         used by e.g., mingw.  From Bruno Haible.
33870
33871 2007-02-19  Bruno Haible  <bruno@clisp.org>
33872
33873         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
33874         warnings.
33875         Reported by Ben Pfaff <blp@cs.stanford.edu>.
33876
33877 2007-02-19  Bruno Haible  <bruno@clisp.org>
33878
33879         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
33880         from mingw users.
33881
33882 2007-02-19  Bruno Haible  <bruno@clisp.org>
33883
33884         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
33885         warnings.
33886         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
33887
33888 2007-02-19  Jim Meyering  <jim@meyering.net>
33889
33890         Don't use FD after a successful "fdopendir (fd)".
33891         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
33892         Reset it by calling dirfd on the just-obtained DIR*.
33893
33894         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
33895         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
33896
33897 2007-02-18  Bruno Haible  <bruno@clisp.org>
33898
33899         * lib/readlink.c: Include <unistd.h>.
33900         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
33901         HAVE_READLINK.
33902         * modules/readlink (Depends-on): Add unistd.
33903         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
33904         (Include): Add <unistd.h>.
33905
33906         * lib/getlogin_r.h: Remove file.
33907         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
33908         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
33909         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
33910         HAVE_DECL_GETLOGIN_R.
33911         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
33912         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
33913         (Include): Use <unistd.h> instead of getlogin_r.h.
33914
33915         * lib/getcwd.h: Remove file.
33916         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
33917         * lib/xgetcwd.c: Likewise.
33918         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
33919         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
33920         * modules/getcwd (Files): Remove lib/getcwd.h.
33921         (Depends-on): Add unistd.
33922         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
33923         (Include): Use <unistd.h> instad of getcwd.h.
33924
33925         * lib/ftruncate.c: Include <unistd.h> first.
33926         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
33927         Set HAVE_FTRUNCATE.
33928         * modules/ftruncate (Depends-on): Add unistd.
33929         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
33930
33931         * lib/fchdir.c: Include <unistd.h> first.
33932         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
33933         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
33934         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
33935         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
33936         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
33937
33938         * lib/dup2.c: Include <unistd.h> first.
33939         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
33940         HAVE_DUP2.
33941         * modules/dup2 (Depends-on): Add unistd.
33942         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
33943
33944         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
33945         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
33946         REPLACE_CHOWN. Don't define chown as a macro here.
33947         * modules/chown (Depends-on): Add unistd.
33948         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
33949
33950         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
33951         Add definition for GL_LINK_WARNING.
33952         (chown, dup2): New declarations.
33953         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
33954         link warning.
33955         (ftruncate): New declaration.
33956         (getcwd): New declaration, taken from old getcwd.h.
33957         (getlogin_r): New declaration, taken from old getlogin_r.h.
33958         (readlink): New declaration.
33959         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
33960         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
33961         (gl_PREREQ_UNISTD): Remove macro.
33962         (gl_UNISTD_MODULE_INDICATOR): New macro.
33963         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
33964         many new variables. Don't set UNISTD_H.
33965         * modules/unistd (Description): Change.
33966         (Depends-on): Add link-warning.
33967         (configure.ac): Update.
33968         (Makefile.am): Create unistd.h always. Substitute many new variables
33969         into it.
33970
33971 2007-02-18  Bruno Haible  <bruno@clisp.org>
33972
33973         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
33974         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
33975         HAVE_GETSUBOPT.
33976         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
33977         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
33978         * lib/getsubopt.h: Remove file.
33979         * modules/getsubopt (Files): Remove lib/getsubopt.h.
33980         (Depends-on): Add stdlib.
33981         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
33982         (Includes): Use <stdlib.h> instead of getsubopt.h.
33983         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
33984         Set HAVE_GETSUBOPT.
33985         * lib/getsubopt.c: Don't include getsubopt.h.
33986
33987 2007-02-18  Bruno Haible  <bruno@clisp.org>
33988
33989         * modules/fchdir (Depends-on): Add dup2.
33990
33991 2007-02-18  Bruno Haible  <bruno@clisp.org>
33992
33993         * lib/stdlib_.h: Handle glibc's special invocation convention
33994         specially.
33995
33996 2007-02-18  Bruno Haible  <bruno@clisp.org>
33997
33998         * modules/stdlib-tests: New file.
33999         * tests/test-stdlib.c: New file.
34000
34001         * modules/mkstemp (Files): Remove lib/mkstemp.h.
34002         (Depends-on): Add stdlib.
34003         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
34004         (Includes): Use <stdlib.h> instead of mkstemp.h.
34005         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
34006         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
34007         * lib/mkstemp.c: Don't include mkstemp.h.
34008         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
34009         * lib/stdlib--.h: Don't include mkstemp.h.
34010
34011         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
34012         (Depends-on): Add stdlib.
34013         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
34014         (Includes): Use <stdlib.h> instead of mkdtemp.h.
34015         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
34016         HAVE_MKDTEMP.
34017         * lib/mkdtemp.c: Don't include mkdtemp.h.
34018         * lib/clean-temp.c: Don't include mkdtemp.h.
34019
34020         * modules/exit (Files): Remove lib/exit.h.
34021         (Depends-on): Add stdlib.
34022         (Makefile.am): Remove lib_SOURCES.
34023         (Include): Use <stdlib.h> instead of exit.h.
34024         * lib/argmatch.c: Don't include exit.h.
34025         * lib/execute.c: Likewise.
34026         * lib/pagealign_alloc.c: Likewise.
34027         * lib/pipe.c: Likewise.
34028         * lib/wait-process.c: Likewise.
34029         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
34030         * lib/exitfail.c: Likewise.
34031         * lib/savewd.c: Likewise.
34032         * lib/xsetenv.c: Likewise.
34033
34034         * modules/stdlib: New file.
34035         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
34036         and extra comments about mkstemp().
34037         * lib/exit.h: Remove file.
34038         * lib/mkdtemp.h: Remove file.
34039         * lib/mkstemp.h: Remove file.
34040         * m4/stdlib_h.m4: New file.
34041         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
34042
34043 2007-02-18  Bruno Haible  <bruno@clisp.org>
34044
34045         * modules/math-tests: New file.
34046         * tests/test-math.c: New file.
34047
34048         * modules/math: New file.
34049         * modules/mathl (Files): Remove lib/mathl.h.
34050         (Depends-on): Add math.
34051         (Makefile.am): Don't mention mathl.h.
34052         (Include): Use <math.h> instead of mathl.h.
34053         * lib/math_.h: New file.
34054         * lib/mathl.h: Remove file.
34055         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
34056         mathl.h.
34057         * lib/asinl.c: Likewise.
34058         * lib/atanl.c: Likewise.
34059         * lib/ceill.c: Likewise.
34060         * lib/cosl.c: Likewise.
34061         * lib/expl.c: Likewise.
34062         * lib/floorl.c: Likewise.
34063         * lib/frexpl.c: Likewise.
34064         * lib/ldexpl.c: Likewise.
34065         * lib/logl.c: Likewise.
34066         * lib/sincosl.c: Likewise.
34067         * lib/sinl.c: Likewise.
34068         * lib/sqrtl.c: Likewise.
34069         * lib/tanl.c: Likewise.
34070         * lib/trigl.c: Likewise.
34071         * m4/math_h.m4: New file.
34072         * MODULES.html.sh (Mathematics): Add math.
34073
34074 2007-02-17  Bruno Haible  <bruno@clisp.org>
34075
34076         * modules/wctype-tests: New file.
34077         * tests/test-wctype.c: New file.
34078
34079         * modules/wchar-tests: New file.
34080         * tests/test-wchar.c: New file.
34081
34082         * modules/unistd-tests: New file.
34083         * tests/test-unistd.c: New file.
34084
34085         * modules/time-tests: New file.
34086         * tests/test-time.c: New file.
34087
34088         * modules/sysexits-tests: New file.
34089         * tests/test-sysexits.c: New file.
34090
34091         * modules/sys_time-tests: New file.
34092         * tests/test-sys_time.c: New file.
34093
34094         * modules/sys_stat-tests: New file.
34095         * tests/test-sys_stat.c: New file.
34096
34097         * modules/sys_socket-tests: New file.
34098         * tests/test-sys_socket.c: New file.
34099
34100         * modules/sys_select-tests: New file.
34101         * tests/test-sys_select.c: New file.
34102
34103         * modules/string-tests: New file.
34104         * tests/test-string.c: New file.
34105
34106         * modules/stdbool-tests: New file.
34107         * tests/test-stdbool.c: New file.
34108
34109         * modules/netinet_in-tests: New file.
34110         * tests/test-netinet_in.c: New file.
34111
34112         * modules/inttypes-tests: New file.
34113         * tests/test-inttypes.c: New file.
34114
34115         * modules/fcntl-tests: New file.
34116         * tests/test-fcntl.c: New file.
34117
34118         * modules/byteswap-tests: New file.
34119         * tests/test-byteswap.c: New file.
34120
34121         * modules/arpa_inet-tests: New file.
34122         * tests/test-arpa_inet.c: New file.
34123
34124 2007-02-17  Bruno Haible  <bruno@clisp.org>
34125
34126         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
34127         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
34128         if the corresponding module is not enabled. Emit link warnings if
34129         the function is used nevertheless.
34130         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
34131         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
34132         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
34133         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
34134         * modules/inttypes (Depends-on): Add link-warning.
34135         (Makefile.am): Copy the contents of build-aux/link-warning.h into
34136         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
34137         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
34138         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
34139         * modules/imaxdiv (configure.ac): Likewise.
34140         * modules/strtoimax (configure.ac): Likewise.
34141         * modules/strtoumax (configure.ac): Likewise.
34142
34143 2007-02-17  Bruno Haible  <bruno@clisp.org>
34144
34145         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
34146         gl_STRING_MODULE_INDICATOR_DEFAULTS.
34147         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
34148         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
34149
34150 2007-02-17  Bruno Haible  <bruno@clisp.org>
34151
34152         * modules/link-warning: New file.
34153         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
34154         * lib/string_.h (GL_LINK_WARNING): Remove definition.
34155         * modules/string (Depends-on): Add link-warning.
34156         (Makefile.am): Copy the contents of build-aux/link-warning.h into
34157         string.h.
34158         * MODULES.html.sh (Support for building libraries and executables): Add
34159         link-warning.
34160
34161 2007-02-17  Bruno Haible  <bruno@clisp.org>
34162
34163         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
34164         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
34165         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
34166         long lines.
34167
34168 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
34169             Bruno Haible  <bruno@clisp.org>
34170
34171         * modules/tmpfile: New file.
34172         * lib/tmpfile.c: New file.
34173         * m4/tmpfile.m4: New file.
34174         * MODULES.html.sh (func_all_modules): New section "Input/output".
34175
34176 2007-02-15  Bruno Haible  <bruno@clisp.org>
34177
34178         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
34179         (supports_delete_on_close): New function.
34180         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
34181
34182 2007-02-14  Bruno Haible  <bruno@clisp.org>
34183
34184         * modules/mbspcasecmp-tests: New file.
34185         * tests/test-mbspcasecmp.sh: New file.
34186         * tests/test-mbspcasecmp.c: New file.
34187
34188         New module mbspcasecmp.
34189         * modules/mbspcasecmp: New file.
34190         * lib/mbspcasecmp.c: New file.
34191         * lib/string_.h (strncasecmp): Change warning message.
34192         (mbspcasecmp): New declaration.
34193         * m4/mbspcasecmp.m4: New file.
34194         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
34195         GNULIB_MBSPCASECMP.
34196         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
34197         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
34198
34199 2007-02-14  Bruno Haible  <bruno@clisp.org>
34200
34201         * modules/mbsncasecmp-tests: New file.
34202         * tests/test-mbsncasecmp.sh: New file.
34203         * tests/test-mbsncasecmp.c: New file.
34204
34205         New module mbsncasecmp.
34206         * modules/mbsncasecmp: New file.
34207         * lib/mbsncasecmp.c: New file.
34208         * lib/string_.h (mbsncasecmp): New declaration.
34209         * m4/mbsncasecmp.m4: New file.
34210         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
34211         GNULIB_MBSNCASECMP.
34212         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
34213         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
34214
34215 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
34216
34217         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
34218         Verify that it doesn't overlap with our flags.
34219         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
34220         do not have the desired effect in multibyte locales; instead, use
34221         mbscasecmp.
34222         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
34223         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
34224         we don't require GNU fnmatch ourselves (if our users require it, they
34225         should do so explicitly).
34226
34227         Fix regex code so it doesn't rely on strcasecmp.
34228         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
34229         Otherwise, include gnulib's langinfo.h.
34230         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
34231         undesirable behavior in non-C locales.  Instead, rely on localecharset.
34232         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
34233         * modules/regex (FILES): Remove m4/codeset.m4.
34234         (Depends-on): Add localcharset.  Remove strcase.
34235
34236 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
34237
34238         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
34239         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
34240
34241 2007-02-13  Bruno Haible  <bruno@clisp.org>
34242
34243         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
34244         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
34245
34246 2007-02-12  Bruno Haible  <bruno@clisp.org>
34247
34248         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
34249         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
34250         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
34251         time warning rather than a link error.
34252
34253 2007-02-12  Bruno Haible  <bruno@clisp.org>
34254
34255         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
34256         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
34257         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
34258
34259 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
34260
34261         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
34262         args, not 2.
34263
34264 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
34265
34266         New module 'time', so that apps can include <time.h> as per
34267         POSIX and GNU instead of separate include files like time_r.h
34268         and timegm.h.  This implementation tries out a simpler approach
34269         for replacing decls in standard include files (as compared to
34270         the string module), somewhat as an experiment.
34271
34272         * config/srclist.txt: Comment out mktime.c for now.
34273         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
34274         since it doesn't apply any more.  Use generic wording instead.
34275         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
34276         'time'.
34277         * lib/time_.h, m4/time_h.m4, modules/time: New files.
34278         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
34279         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
34280         Don't include <sys/types.h>; no longer needed since we assume C89.
34281         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
34282         * lib/strftime.c: Likewise.
34283         * lib/time_r.c: Likewise.
34284         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
34285         * lib/nanosleep.c: Include <time.h> first, to check interface.
34286         * lib/strptime.c: Likewise.
34287         * lib/time_r.c: Likewise.
34288         * lib/timegm.c: Likewise.
34289         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
34290         needed.
34291         * lib/timegm.c: Don't include timegm.h; no longer needed.
34292         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
34293         time.h now handles any problems in that area.
34294         (struct timespec, nanosleep): Remove; time.h now arranges for these.
34295         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
34296         that time.h defines struct timespec.
34297         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
34298         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
34299         handles that.
34300         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
34301         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
34302         needed.  Set REPLACE_LOCALTIME.
34303         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
34304         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
34305         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
34306         nanosleep; time_h.m4 now does that.  Don't require
34307         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
34308         module handles this now.
34309         * modules/getdate (Depends-on): Remove timespec.  Add time.
34310         * modules/nanosleep (Depends-on): Likewise.
34311         * modules/stat-time (Depends-on): Likewise.
34312         * modules/nanosleep (Include): Include time.h, not timespec.h.
34313         * modules/strptime (Files): Remove lib/strptime.h.
34314         (Depends-on): Add extensions, time.
34315         (Include): Include time.h, not strptime.h.
34316         * modules/time_r (Files): Remove lib/time_r.h.
34317         (Depends-on): Add time.
34318         (Include): Include time.h, not time_r.h.
34319         * modules/timegm: Likewise.
34320         * modules/timespec (Description): Now does timespec-related decls
34321         of our own, instead of struct timespec itself.
34322         (Depends-on): Add time; remove extensions.
34323         (Maintainer): Add self.
34324         * modules/utimecmp (Depends-on): Add time; remove timespec.
34325         * modules/utimens (Depends-on): Likewise.
34326         * modules/xnanosleep (Depends-on): Likewise.
34327
34328 2007-02-11  Bruno Haible  <bruno@clisp.org>
34329
34330         * lib/c-strstr.c: Include allocsa.h.
34331         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
34332         * lib/c-strcasestr.c: Include allocsa.h.
34333         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
34334         * lib/strcasestr.c: Include allocsa.h.
34335         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
34336         * lib/mbsstr.c: Include allocsa.h.
34337         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
34338         allocsa/freesa instead of malloc/free.
34339         * lib/mbscasestr.c: Include allocsa.h.
34340         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
34341         allocsa/freesa instead of malloc/free.
34342         * modules/c-strstr (Depends-on): Add allocsa.
34343         * modules/c-strcasestr (Depends-on): Likewise.
34344         * modules/strcasestr (Depends-on): Likewise.
34345         * modules/mbsstr (Depends-on): Likewise.
34346         * modules/mbscasestr (Depends-on): Likewise.
34347
34348 2007-02-11  Bruno Haible  <bruno@clisp.org>
34349
34350         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
34351
34352         * modules/mbsspn-tests: New file.
34353         * tests/test-mbsspn.sh: New file.
34354         * tests/test-mbsspn.c: New file.
34355
34356 2007-02-11  Bruno Haible  <bruno@clisp.org>
34357
34358         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
34359
34360         * modules/mbspbrk-tests: New file.
34361         * tests/test-mbspbrk.sh: New file.
34362         * tests/test-mbspbrk.c: New file.
34363
34364 2007-02-11  Bruno Haible  <bruno@clisp.org>
34365
34366         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
34367         unneeded cast.
34368
34369         * modules/mbscspn-tests: New file.
34370         * tests/test-mbscspn.sh: New file.
34371         * tests/test-mbscspn.c: New file.
34372
34373 2007-02-11  Bruno Haible  <bruno@clisp.org>
34374
34375         * modules/mbscasecmp-tests: New file.
34376         * tests/test-mbscasecmp.sh: New file.
34377         * tests/test-mbscasecmp.c: New file.
34378
34379 2007-02-11  Bruno Haible  <bruno@clisp.org>
34380
34381         Ensure O(n) worst-case complexity of mbscasestr.
34382         * lib/mbscasestr.c: Include stdbool.h.
34383         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
34384         functions.
34385         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
34386         the bookkeeping indicates that it's worth it.
34387         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
34388
34389         * modules/mbscasestr-tests: New file.
34390         * tests/test-mbscasestr1.c: New file.
34391         * tests/test-mbscasestr2.sh: New file.
34392         * tests/test-mbscasestr2.c: New file.
34393         * tests/test-mbscasestr3.sh: New file.
34394         * tests/test-mbscasestr3.c: New file.
34395         * tests/test-mbscasestr4.sh: New file.
34396         * tests/test-mbscasestr4.c: New file.
34397         * m4/locale-tr.m4: New file.
34398
34399 2007-02-11  Bruno Haible  <bruno@clisp.org>
34400
34401         Ensure O(n) worst-case complexity of mbsstr.
34402         * lib/mbsstr.c: Include stdbool.h.
34403         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
34404         functions.
34405         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
34406         bookkeeping indicates that it's worth it.
34407         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
34408
34409         * modules/mbsstr-tests: New file.
34410         * tests/test-mbsstr1.c: New file.
34411         * tests/test-mbsstr2.sh: New file.
34412         * tests/test-mbsstr2.c: New file.
34413         * tests/test-mbsstr3.sh: New file.
34414         * tests/test-mbsstr3.c: New file.
34415         * m4/locale-fr.m4: New file.
34416
34417 2007-02-11  Bruno Haible  <bruno@clisp.org>
34418
34419         * lib/mbsrchr.c (mbsrchr): Fix bug.
34420
34421         * modules/mbsrchr-tests: New file.
34422         * tests/test-mbsrchr.sh: New file.
34423         * tests/test-mbsrchr.c: New file.
34424
34425 2007-02-11  Bruno Haible  <bruno@clisp.org>
34426
34427         * lib/mbschr.c (mbschr): Fix bug.
34428
34429         * modules/mbschr-tests: New file.
34430         * tests/test-mbschr.sh: New file.
34431         * tests/test-mbschr.c: New file.
34432         * m4/locale-zh.m4: New file.
34433
34434 2007-02-11  Bruno Haible  <bruno@clisp.org>
34435
34436         Support for copying multibyte string iterators.
34437         * lib/mbiter.h: Include <string.h>.
34438         (mbiter_multi_copy): New function.
34439         (mbi_copy): New macro.
34440         * lib/mbuiter.h: Include <string.h>.
34441         (mbuiter_multi_copy): New function.
34442         (mbui_copy): New macro.
34443
34444 2007-02-11  Bruno Haible  <bruno@clisp.org>
34445
34446         New module mbslen.
34447         * modules/mbslen: New file.
34448         * lib/mbslen.c: New file.
34449         * lib/string_.h (mbslen): New declaration.
34450         * m4/mbslen.m4: New file.
34451         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
34452         GNULIB_MBSLEN.
34453         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
34454         * MODULES.html.sh (Internationalization functions): Add mbslen.
34455
34456 2007-02-11  Bruno Haible  <bruno@clisp.org>
34457
34458         Ensure O(n) worst-case complexity of strcasestr substitute.
34459         * lib/strcasestr.c: Include stdbool.h.
34460         (knuth_morris_pratt): New function.
34461         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
34462         bookkeeping indicates that it's worth it.
34463         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
34464
34465         * modules/strcasestr-tests: New file.
34466         * tests/test-strcasestr.c: New file.
34467
34468 2007-02-11  Bruno Haible  <bruno@clisp.org>
34469
34470         Ensure O(n) worst-case complexity of c_strcasestr.
34471         * lib/c-strcasestr.c: Include stdbool.h, string.h.
34472         (knuth_morris_pratt): New function.
34473         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
34474         the bookkeeping indicates that it's worth it.
34475         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
34476
34477         * modules/c-strcasestr-tests: New file.
34478         * tests/test-c-strcasestr.c: New file.
34479
34480 2007-02-11  Bruno Haible  <bruno@clisp.org>
34481
34482         Ensure O(n) worst-case complexity of c_strstr.
34483         * lib/c-strstr.c: Include stdbool.h, string.h.
34484         (knuth_morris_pratt): New function.
34485         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
34486         bookkeeping indicates that it's worth it.
34487         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
34488
34489         * lib/c-strstr.c: Complete rewrite for maintainability.
34490
34491         * modules/c-strstr-tests: New file.
34492         * tests/test-c-strstr.c: New file.
34493
34494 2007-02-11  Bruno Haible  <bruno@clisp.org>
34495
34496         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
34497         5.2.1 and earlier, whereby \055 was treated just like the range
34498         delimiter '-'.
34499         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
34500
34501 2007-02-08  Bruno Haible  <bruno@clisp.org>
34502
34503         * modules/regex (Depends-on): Add stdbool.
34504         Reported by Dalibor Topic <robilad@kaffe.org>.
34505
34506 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
34507
34508         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
34509         Prefer returning from main to exiting from it.
34510         Remove unnecessary parens after sizeof.
34511
34512 2007-02-05  Bruno Haible  <bruno@clisp.org>
34513
34514         New module mbssep.
34515         * modules/mbssep: New file.
34516         * lib/mbssep.c: New file.
34517         * lib/string_.h (strsep): Add a conditional link warning.
34518         (mbssep): New declaration.
34519         * m4/mbssep.m4: New file.
34520         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
34521         GNULIB_MBSSEP.
34522         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
34523         * MODULES.html.sh (Internationalization functions): Add mbssep.
34524
34525 2007-02-05  Bruno Haible  <bruno@clisp.org>
34526
34527         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
34528         Optimize search in case of 1 delimiter.
34529
34530 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
34531
34532         * lib/acl.h: Include sys/types.h before sys/acl.h.
34533
34534 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
34535
34536         Merge upstream fix for glibc bugzilla #3957:
34537
34538         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
34539
34540         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
34541         bit for RE_HAT_LISTS_NOT_NEWLINE.
34542         (build_charclass_op): Remove bogus comment.
34543
34544 2007-02-05  Simon Josefsson  <simon@josefsson.org>
34545
34546         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
34547
34548 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
34549
34550         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
34551         * lib/memmem.c [!defined _LIBC]: Include config.h.
34552
34553 2007-02-04  Bruno Haible  <bruno@clisp.org>
34554
34555         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
34556         warning message.
34557
34558 2007-02-04  Bruno Haible  <bruno@clisp.org>
34559
34560         New module mbstok_r.
34561         * modules/mbstok_r: New file.
34562         * lib/mbstok_r.c: New file.
34563         * lib/string_.h (strtok_r): Change argument names to match the
34564         comments. Add a conditional link warning.
34565         (mbstok_r): New declaration.
34566         * m4/mbstok_r.m4: New file.
34567         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
34568         GNULIB_MBSTOK_R.
34569         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
34570         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
34571
34572 2007-02-04  Bruno Haible  <bruno@clisp.org>
34573
34574         New module mbsspn.
34575         * modules/mbsspn: New file.
34576         * lib/mbsspn.c: New file.
34577         * lib/string_.h (strspn): Add a conditional link warning.
34578         (mbsspn): New declaration.
34579         * m4/mbsspn.m4: New file.
34580         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
34581         GNULIB_MBSSPN.
34582         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
34583         * MODULES.html.sh (Internationalization functions): Add mbsspn.
34584
34585 2007-02-04  Bruno Haible  <bruno@clisp.org>
34586
34587         New module mbspbrk.
34588         * modules/mbspbrk: New file.
34589         * lib/mbspbrk.c: New file.
34590         * lib/string_.h (strpbrk): Add a conditional link warning.
34591         (mbspbrk): New declaration.
34592         * m4/mbspbrk.m4: New file.
34593         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
34594         GNULIB_MBSPBRK.
34595         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
34596         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
34597
34598 2007-02-04  Bruno Haible  <bruno@clisp.org>
34599
34600         New module mbscspn.
34601         * modules/mbscspn: New file.
34602         * lib/mbscspn.c: New file.
34603         * lib/string_.h (strcspn): Add a conditional link warning.
34604         (mbscspn): New declaration.
34605         * m4/mbscspn.m4: New file.
34606         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
34607         GNULIB_MBSCSPN.
34608         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
34609         * MODULES.html.sh (Internationalization functions): Add mbscspn.
34610
34611 2007-02-04  Bruno Haible  <bruno@clisp.org>
34612
34613         New module mbscasestr, reduced goal of strcasestr.
34614         * modules/mbscasestr: New file.
34615         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
34616         (mbscasestr): Renamed from strcasestr.
34617         * lib/strcasestr.c: Don't include mbuiter.h.
34618         (strcasestr): Remove support for multibyte locales.
34619         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
34620         Change the conditional link warning.
34621         (mbscasestr): New declaration.
34622         * m4/mbscasestr.m4: New file.
34623         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
34624         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
34625         REPLACE_STRCASESTR.
34626         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
34627         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
34628         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
34629         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
34630         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
34631         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
34632         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
34633         (Depends-on): Remove mbuiter.
34634         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
34635
34636 2007-02-04  Bruno Haible  <bruno@clisp.org>
34637
34638         Simplify handling of strncasecmp.
34639         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
34640         the conditional link warning.
34641         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
34642         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
34643         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
34644         * modules/strcase (configure.ac): Don't invoke
34645         gl_STRING_MODULE_INDICATOR.
34646         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
34647
34648 2007-02-04  Bruno Haible  <bruno@clisp.org>
34649
34650         New module mbscasecmp, reduced goal of strcasecmp.
34651         * modules/mbscasecmp: New file.
34652         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
34653         (mbscasecmp): Renamed from strcasecmp.
34654         * lib/strcasecmp.c: Don't include mbuiter.h.
34655         (strcasecmp): Remove support for multibyte locales.
34656         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
34657         Change the conditional link warning.
34658         (mbscasecmp): New declaration.
34659         * m4/mbscasecmp.m4: New file.
34660         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
34661         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
34662         REPLACE_STRCASECMP.
34663         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
34664         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
34665         GNULIB_MBSCASECMP.
34666         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
34667         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
34668         * modules/strcase (Files): Remove m4/mbrtowc.m4.
34669         (Depends-on): Remove mbuiter.
34670         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
34671
34672 2007-02-04  Bruno Haible  <bruno@clisp.org>
34673
34674         New module mbsstr. Remove module strstr.
34675         * modules/mbsstr: New file.
34676         * modules/strstr: Remove file.
34677         * lib/mbsstr.c: Renamed from lib/strstr.c.
34678         (mbsstr): Renamed from strstr.
34679         * lib/string_.h (strstr): Remove declaration. Change the conditional
34680         link warning.
34681         (mbsstr): New declaration.
34682         * m4/mbsstr.m4: New file.
34683         * m4/strstr.m4: Remove file.
34684         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
34685         REPLACE_STRSTR.
34686         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
34687         Don't initialize GNULIB_STRSTR.
34688         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
34689         substitute GNULIB_STRSTR and REPLACE_STRSTR.
34690         * MODULES.html.sh (Internationalization functions): Add mbsstr.
34691         (Support for systems lacking ANSI C 89): Remove strstr.
34692
34693 2007-02-04  Bruno Haible  <bruno@clisp.org>
34694
34695         New module mbsrchr.
34696         * modules/mbsrchr: New file.
34697         * lib/mbsrchr.c: New file.
34698         * lib/string_.h (strrchr): Add a conditional link warning.
34699         (mbsrchr): New declaration.
34700         * m4/mbsrchr.m4: New file.
34701         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
34702         GNULIB_MBSRCHR.
34703         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
34704         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
34705
34706 2007-02-04  Bruno Haible  <bruno@clisp.org>
34707
34708         New module mbschr.
34709         * modules/mbschr: New file.
34710         * lib/mbschr.c: New file.
34711         * lib/string_.h (strchr): Add a conditional link warning.
34712         (mbschr): New declaration.
34713         * m4/mbschr.m4: New file.
34714         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
34715         GNULIB_MBSCHR.
34716         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
34717         * MODULES.html.sh (Internationalization functions): Add mbschr.
34718
34719 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
34720
34721         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
34722
34723         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
34724
34725 2007-02-04  Bruno Haible  <bruno@clisp.org>
34726
34727         New module description section 'configure.ac-early'.
34728         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
34729         (func_get_autoconf_early_snippet): New function.
34730         (func_import, func_create_testdir): Use it. Remove special cases for
34731         modules 'extensions' and 'lock'.
34732         * modules/extensions (configure.ac-early): Require
34733         gl_USE_SYSTEM_EXTENSIONS.
34734         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
34735
34736 2007-02-04  Bruno Haible  <bruno@clisp.org>
34737
34738         Make use of gcj-4.3's -fsource and -ftarget option.
34739         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
34740         and if so try the options -fsource and -ftarget.
34741         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
34742         source_version, ftarget_option, target_version arguments.
34743         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
34744         (is_envjavac_oldgcj_14_14_usable): Renamed from
34745         is_envjavac_gcj_14_14_usable.
34746         (is_envjavac_oldgcj_14_13_usable): Renamed from
34747         is_envjavac_gcj_14_13_usable.
34748         (is_gcj_present): Update.
34749         (is_gcj_43, is_gcj43_usable): New functions.
34750         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
34751         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
34752         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
34753         try the options -fsource and -ftarget.
34754
34755 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
34756
34757         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
34758         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
34759         larger value.
34760
34761 2007-02-03  Jim Meyering  <jim@meyering.net>
34762
34763         Give tools a better chance to allocate space for very large buffers.
34764         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
34765
34766         Make pwd and readlink work also when run with an unreadable parent dir
34767         on systems with openat support.
34768         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
34769         provided getcwd function, even when we have openat support.
34770         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
34771
34772 2007-02-02  Bruno Haible  <bruno@clisp.org>
34773
34774         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
34775         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
34776         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
34777         portability problems if one of these functions is only used on specific
34778         platforms.
34779         Reported by Paul Eggert.
34780
34781 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
34782
34783         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
34784         is causing more trouble than it's curing.
34785         * lib/regex_internal.h (__mempcpy): Remove.
34786         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
34787         (and make the code a tad smaller to boot).
34788         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
34789
34790 2007-02-02  Jim Meyering  <jim@meyering.net>
34791
34792         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
34793         section, not in the Makefile.am: one.
34794
34795 2007-02-02  Eric Blake  <ebb9@byu.net>
34796
34797         * lib/strchrnul.c: Always include config.h first.
34798
34799         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
34800         gnulib strstr is not necessary here.
34801
34802 2007-02-02  Simon Josefsson  <simon@josefsson.org>
34803
34804         * m4/socklen.m4: Fix typo.
34805
34806 2007-02-02  Eric Blake  <ebb9@byu.net>
34807
34808         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
34809         * modules/netinet_in (Makefile.am): Likewise.
34810
34811 2007-02-01  Bruno Haible  <bruno@clisp.org>
34812
34813         * lib/string_.h (GL_LINK_WARNING): New macro.
34814         (strcasecmp, strstr, strcasestr): If provided by the system,
34815         conditionally define as a macro that leads to a warning instead of to
34816         an error.
34817         (strncasecmp): Conditionally define as a macro that leads to a warning.
34818
34819 2007-02-01  Karl Berry  <karl@gnu.org>
34820
34821         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
34822
34823 2007-02-01  Bruno Haible  <bruno@clisp.org>
34824
34825         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
34826         renamings.
34827
34828 2007-02-01  Eric Blake  <ebb9@byu.net>
34829
34830         * modules/regex (Depends-on): Revert dependence on mempcpy.
34831         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
34832         module's definition of mempcpy.
34833         Reported by Paul Eggert.
34834
34835 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
34836
34837         * lib/string_.h: If the gnulib module XYZ is not present, undefine
34838         the symbol XYZ before redefining it.  This fixes a problem with
34839         programs that don't use XYZ, when compiled on systems that define
34840         XYZ to something else.
34841
34842 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
34843
34844         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
34845         occurs when "mkdir -m foo" creates a setgid directory that is (1)
34846         writeable to group or other and (2) is intended to have a special
34847         mode bit that is set or cleared.  In such a case, the directory
34848         should be neither group- nor other-writeable until the special
34849         mode bits are right.
34850
34851 2007-01-31  Eric Blake  <ebb9@byu.net>
34852
34853         * modules/mountlist (Depends-on): Add strstr.
34854
34855         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
34856         bug.
34857         * modules/string (Makefile.am): Remove redundant replacement.
34858         * modules/regex (Depends-on): Add mempcpy.
34859
34860 2007-01-31  Bruno Haible  <bruno@clisp.org>
34861
34862         New module description field 'Link'.
34863         * gnulib-tool (func_usage): Document --extract-link-directive.
34864         (sed_extract_prog): Recognize 'Link' directive.
34865         (func_get_link_directive): New function.
34866         (func_import): Show summary of link directives.
34867         Handle --extract-link-directive option.
34868         * modules/acl (Link): New section.
34869         * modules/clock-time (Link): New section.
34870         * modules/euidaccess (Link): New section.
34871         * modules/gettext (Link): New section.
34872         * modules/iconv (Link): New section.
34873         * modules/lock (Link): New section.
34874         * modules/nanosleep (Link): New section.
34875         * modules/readline (Link): New section.
34876
34877 2007-01-27  Bruno Haible  <bruno@clisp.org>
34878
34879         Enforce the use of gnulib modules for unportable <string.h> functions.
34880         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
34881         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
34882         (gl_HEADER_STRING_H_BODY): Require it.
34883         * lib/string_.h: If the gnulib module XYZ is not present, redefine
34884         the symbol XYZ to one that gives a link error.
34885         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
34886         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
34887         * modules/mempcpy (configure.ac): Likewise.
34888         * modules/memrchr (configure.ac): Likewise.
34889         * modules/stpcpy (configure.ac): Likewise.
34890         * modules/stpncpy (configure.ac): Likewise.
34891         * modules/strcase (configure.ac): Likewise.
34892         * modules/strcasestr (configure.ac): Likewise.
34893         * modules/strchrnul (configure.ac): Likewise.
34894         * modules/strdup (configure.ac): Likewise.
34895         * modules/strndup (configure.ac): Likewise.
34896         * modules/strnlen (configure.ac): Likewise.
34897         * modules/strpbrk (configure.ac): Likewise.
34898         * modules/strsep (configure.ac): Likewise.
34899         * modules/strstr (configure.ac): Likewise.
34900         * modules/strtok_r (configure.ac): Likewise.
34901
34902 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
34903
34904         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
34905
34906 2007-01-30  Jim Meyering  <jim@meyering.net>
34907
34908         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
34909
34910 2007-01-29  Bruno Haible  <bruno@clisp.org>
34911
34912         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
34913         * lib/execute.c: Likewise.
34914         * lib/pipe.c: Likewise.
34915         * lib/printf-args.h: Likewise.
34916         * lib/printf-args.c: Likewise.
34917         * lib/printf-parse.c: Likewise.
34918         * lib/vasnprintf.c: Likewise.
34919
34920 2007-01-29  Eric Blake  <ebb9@byu.net>
34921
34922         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
34923         declaration.
34924
34925 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
34926
34927         * lib/strptime.h (strptime): Use 'restrict' for args where
34928         POSIX requires this.
34929         * lib/strptime.c (strptime): Likewise.
34930         Change license notice from LGPL to GPL, since gnulib-tool will
34931         change this as needed.
34932         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
34933         defined.
34934         Include "strptime.h" first, to check interface.
34935         Do not #undef _LIBC and _NL_CURRENT.
34936         Do not include <stdlib.h>; no longer needed.
34937         Include "time_r.h" and declare ptime_locale_status
34938         only if _LIBC is not defined.
34939         (__P): Remove unused macro.
34940         (match_string): Bring back glibc version, but use it only if _LIBC
34941         is defined.
34942         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
34943         Remove unnecessary assertion and abort() call.
34944         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
34945         * m4/strptime.m4: Fix serial number comment.
34946         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
34947         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
34948         (Depends-on): Add time_r.
34949
34950 2007-01-29  Bruno Haible  <bruno@clisp.org>
34951
34952         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
34953         strptime.
34954         * modules/strptime (Depends-on): Add stdbool.
34955         * lib/strptime.h: Include <time.h> always. Add comments.
34956
34957 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
34958
34959         * modules/strptime: New file.
34960         * lib/strptime.h: New file.
34961         * lib/strptime.c: New file.
34962         * m4/strptime.m4: New file.
34963
34964 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
34965
34966         * MODULES.html.sh: New module mpsort.
34967         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
34968
34969         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
34970         a circularity problem with HP-UX ia64 reported by Bob Proulx in
34971         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
34972         All uses changed.
34973         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
34974         All uses changed.
34975         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
34976         to _Restrict_.
34977         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
34978         the parameter matches the prototype.
34979
34980 2007-01-28  Jim Meyering  <jim@meyering.net>
34981
34982         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
34983         sys/time.h here, reverting that part of the previous patch:
34984         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
34985
34986 2007-01-28  Bruno Haible  <bruno@clisp.org>
34987
34988         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
34989         value of $(SYS_TIME_H).
34990         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
34991         remove it conditionally, too. [added by Jim Meyering]
34992         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
34993         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
34994         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
34995         GETTIMEOFDAY_REPLACEMENT to 1.
34996
34997 2007-01-28  Bruno Haible  <bruno@clisp.org>
34998
34999         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
35000         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
35001         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
35002         Set UNISTD_H instead of UNISTD_H2.
35003         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
35004
35005 2007-01-28  Bruno Haible  <bruno@clisp.org>
35006
35007         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
35008         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
35009
35010 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
35011
35012         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
35013         (func_create_testdir): Ensure C locale for `grep' and `tr'
35014         character ranges.
35015         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
35016         ACLOCAL_AMFLAGS parsing state machine.
35017
35018 2007-01-27  Bruno Haible  <bruno@clisp.org>
35019
35020         * modules/unistr/base: Update.
35021
35022 2007-01-27  Bruno Haible  <bruno@clisp.org>
35023
35024         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
35025         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
35026         * modules/unistr/u32-mbtouc-unsafe: Renamed from
35027         modules/unistr/u32-mbtouc.
35028         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
35029         * lib/unistr.h: Update.
35030         * lib/linebreak.c: Update.
35031         * modules/unistr/u32-mbtouc: Renamed from
35032         modules/unistr/u32-mbtouc-safe.
35033         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
35034         * lib/unistr.h: Update.
35035         * lib/unistr/u32-to-u8.c: Update.
35036         * lib/unistr/u32-to-u16.c: Update.
35037
35038 2007-01-27  Bruno Haible  <bruno@clisp.org>
35039
35040         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
35041         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
35042         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
35043         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
35044         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
35045         * modules/unistr/u16-mbtouc-unsafe: Renamed from
35046         modules/unistr/u16-mbtouc.
35047         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
35048         * lib/unistr.h: Update.
35049         * lib/linebreak.c: Update.
35050         * modules/linebreak: Update.
35051         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
35052         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
35053         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
35054         * modules/unistr/u16-mbtouc: Renamed from
35055         modules/unistr/u16-mbtouc-safe.
35056         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
35057         * lib/unistr.h: Update.
35058         * lib/unistr/u16-to-u8.c: Update.
35059         * modules/unistr/u16-to-u8: Update.
35060         * lib/unistr/u16-to-u32.c: Update.
35061         * modules/unistr/u16-to-u32: Update.
35062
35063 2007-01-27  Bruno Haible  <bruno@clisp.org>
35064
35065         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
35066         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
35067         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
35068         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
35069         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
35070         * modules/unistr/u8-mbtouc-unsafe: Renamed from
35071         modules/unistr/u8-mbtouc.
35072         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
35073         * lib/unistr.h: Update.
35074         * lib/striconveh.c: Update.
35075         * modules/striconveh: Update.
35076         * lib/linebreak.c: Update.
35077         * modules/linebreak: Update.
35078         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
35079         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
35080         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
35081         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
35082         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
35083         * lib/unistr.h: Update.
35084         * lib/striconveh.c: Update.
35085         * modules/striconveh: Update.
35086         * lib/unistr/u8-to-u16.c: Update.
35087         * modules/unistr/u8-to-u16: Update.
35088         * lib/unistr/u8-to-u32.c: Update.
35089         * modules/unistr/u8-to-u32: Update.
35090
35091 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
35092
35093         Sync from Libtool.
35094         * lib/argz.c: Do not include strings.h nor memory.h, include
35095         string.h unconditionally.  Patch by Simon Josefsson.
35096
35097 2007-01-27  Bruno Haible  <bruno@clisp.org>
35098
35099         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
35100         from gl_HEADER_STRING_H_BODY.
35101         (gl_HEADER_STRING_H_BODY): Require it.
35102         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
35103         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
35104         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
35105         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
35106         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
35107         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
35108         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
35109         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
35110         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
35111         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
35112         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
35113         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
35114         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
35115         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
35116         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
35117
35118 2007-01-27  Bruno Haible  <bruno@clisp.org>
35119
35120         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
35121         check_PROGRAMS into noinst_PROGRAMS.
35122         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
35123         check_PROGRAMS in this case.
35124         (func_import): Set for_test to false.
35125         (func_create_testdir): Set for_test to true.
35126
35127 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
35128             Bruno Haible  <bruno@clisp.org>
35129
35130         * modules/strcasestr (Files): Remove lib/strcasestr.h.
35131         (Depends-on): Add string.
35132         (Includes): Use <string.h> instead of strcasestr.h.
35133         * modules/string (Makefile.am): Also substitute the value of
35134         REPLACE_STRCASESTR.
35135         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
35136         assume strcasestr is declared in <string.h> not <strings.h>. Also
35137         set REPLACE_STRCASESTR.
35138         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
35139         REPLACE_STRCASESTR.
35140         * lib/strcasestr.h: Remove file.
35141         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
35142         * lib/string_.h (strcasestr): New declaration.
35143
35144 2007-01-27  Bruno Haible  <bruno@clisp.org>
35145
35146         * lib/string_.h: Use 'extern'.
35147
35148 2007-01-27  Jim Meyering  <jim@meyering.net>
35149
35150         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
35151         of set-but-not-used local, "q".
35152
35153         * lib/mempcpy.c: Include <config.h> before <string.h>.
35154         This fixes a compilation error on HP-UX, due to the system's
35155         "restrict"-using mempcpy prototype.
35156
35157 2007-01-26  Bruno Haible  <bruno@clisp.org>
35158
35159         Small optimization.
35160         * lib/javacomp.c: Include c-strstr.h.
35161          (is_envjavac_gcj): Use c_strstr instead of strstr.
35162         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
35163
35164 2007-01-26  Bruno Haible  <bruno@clisp.org>
35165
35166         * MODULES.html.sh (Unicode string functions): Add the new modules.
35167
35168         * modules/uniconv/u32-strconv-to-locale: New file.
35169         * lib/uniconv/u32-strconv-to-locale.c: New file.
35170
35171         * modules/uniconv/u16-strconv-to-locale: New file.
35172         * lib/uniconv/u16-strconv-to-locale.c: New file.
35173
35174         * modules/uniconv/u8-strconv-to-locale: New file.
35175         * lib/uniconv/u8-strconv-to-locale.c: New file.
35176
35177         * modules/uniconv/u32-strconv-from-locale: New file.
35178         * lib/uniconv/u32-strconv-from-locale.c: New file.
35179
35180         * modules/uniconv/u16-strconv-from-locale: New file.
35181         * lib/uniconv/u16-strconv-from-locale.c: New file.
35182
35183         * modules/uniconv/u8-strconv-from-locale: New file.
35184         * lib/uniconv/u8-strconv-from-locale.c: New file.
35185
35186         * modules/uniconv/u32-strconv-to-enc: New file.
35187         * lib/uniconv/u32-strconv-to-enc.c: New file.
35188         * modules/uniconv/u32-strconv-to-enc-tests: New file.
35189         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
35190
35191         * modules/uniconv/u16-strconv-to-enc: New file.
35192         * lib/uniconv/u16-strconv-to-enc.c: New file.
35193         * lib/uniconv/u-strconv-to-enc.h: New file.
35194         * modules/uniconv/u16-strconv-to-enc-tests: New file.
35195         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
35196
35197         * modules/uniconv/u8-strconv-to-enc: New file.
35198         * lib/uniconv/u8-strconv-to-enc.c: New file.
35199         * modules/uniconv/u8-strconv-to-enc-tests: New file.
35200         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
35201
35202         * modules/uniconv/u32-strconv-from-enc: New file.
35203         * lib/uniconv/u32-strconv-from-enc.c: New file.
35204         * modules/uniconv/u32-strconv-from-enc-tests: New file.
35205         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
35206
35207         * modules/uniconv/u16-strconv-from-enc: New file.
35208         * lib/uniconv/u16-strconv-from-enc.c: New file.
35209         * modules/uniconv/u16-strconv-from-enc-tests: New file.
35210         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
35211
35212         * modules/uniconv/u8-strconv-from-enc: New file.
35213         * lib/uniconv/u8-strconv-from-enc.c: New file.
35214         * lib/uniconv/u-strconv-from-enc.h: New file.
35215         * modules/uniconv/u8-strconv-from-enc-tests: New file.
35216         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
35217
35218         * modules/uniconv/u32-conv-from-enc: New file.
35219         * lib/uniconv/u32-conv-from-enc.c: New file.
35220         * modules/uniconv/u32-conv-from-enc-tests: New file.
35221         * tests/uniconv/test-u32-conv-from-enc.c: New file.
35222
35223         * modules/uniconv/u16-conv-from-enc: New file.
35224         * lib/uniconv/u16-conv-from-enc.c: New file.
35225         * lib/uniconv/u-conv-from-enc.h: New file.
35226         * modules/uniconv/u16-conv-from-enc-tests: New file.
35227         * tests/uniconv/test-u16-conv-from-enc.c: New file.
35228
35229         * modules/uniconv/u8-conv-from-enc: New file.
35230         * lib/uniconv/u8-conv-from-enc.c: New file.
35231         * modules/uniconv/u8-conv-from-enc-tests: New file.
35232         * tests/uniconv/test-u8-conv-from-enc.c: New file.
35233
35234         * modules/uniconv/base: New file.
35235         * lib/uniconv.h: New file.
35236
35237 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
35238
35239         * doc/gnulib-tool.texi (Initial import): Update to match current
35240         behavior with strdup module.
35241         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
35242         * lib/memmem.h: Remove; all uses removed.  This is now done
35243         by <string.h>.
35244         * lib/mempcpy.h: Likewise.
35245         * lib/memrchr.h: Likewise.
35246         * lib/stpcpy.h: Likewise.
35247         * lib/stpncpy.h: Likewise.
35248         * lib/strcase.h: Likewise.
35249         * lib/strchrnul.h: Likewise.
35250         * lib/strdup.h: Likewise.
35251         * lib/strndup.h: Likewise.
35252         * lib/strnlen.h: Likewise.
35253         * lib/strpbrk.h: Likewise.
35254         * lib/strsep.h: Likewise.
35255         * lib/strstr.h: Likewise.
35256         * lib/strtok_r.h: Likewise.
35257         * lib/string_.h: New file.
35258         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
35259         Rely on <string.h> instead.
35260         * lib/canon-host.c: Likewise.
35261         * lib/chdir-long.c: Likewise.
35262         * lib/concatpath.c: Likewise.
35263         * lib/exclude.c: Likewise.
35264         * lib/fchdir.c: Likewise.
35265         * lib/getaddrinfo.c: Likewise.
35266         * lib/getcwd.c: Likewise.
35267         * lib/getsubopt.c: Likewise.
35268         * lib/glob.c: Likewise.
35269         * lib/hard-locale.c: Likewise.
35270         * lib/iconvme.c: Likewise.
35271         * lib/javacomp.c: Likewise.
35272         * lib/mempcpy.c: Likewise.
35273         * lib/memrchr.c: Likewise.
35274         * lib/regex_internal.h: Likewise.
35275         * lib/stpncpy.c: Likewise.
35276         * lib/strcasecmp.c: Likewise.
35277         * lib/strchrnul.c: Likewise.
35278         * lib/strdup.c: Likewise.
35279         * lib/striconv.c: Likewise.
35280         * lib/striconveh.c: Likewise.
35281         * lib/striconveha.c: Likewise.
35282         * lib/strncasecmp.c: Likewise.
35283         * lib/strndup.c: Likewise.
35284         * lib/strnlen.c: Likewise.
35285         * lib/strsep.c: Likewise.
35286         * lib/strstr.c: Likewise.
35287         * lib/strtok_r.c: Likewise.
35288         * lib/userspec.c: Likewise.
35289         * lib/w32spawn.h: Likewise.
35290         * lib/xstrndup.c: Likewise.
35291         * lib/mountlist.c (strstr): Remove decl.
35292         * m4/string_h.m4: New file.
35293         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
35294         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
35295         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
35296         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
35297         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
35298         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
35299         Set REPLACE_STRCASECMP if necessary.
35300         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
35301         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
35302         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
35303         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
35304         HAVE_DECL_STRDUP if necessary.
35305         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
35306         since gl_FUNC_STRNDUP does that now.
35307         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
35308         Check for decl here...
35309         (gl_PREREQ_STRNLEN): ... not here.
35310         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
35311         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
35312         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
35313         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
35314         necessary.
35315         * modules/string: New file.
35316         * modules/memmem (Files): Remove special-purpose include file.
35317         (Depends-on): Add string.
35318         (Include): Include <string.h>, not the removed file.
35319         * modules/mempcpy: Likewise.
35320         * modules/memrchr: Likewise.
35321         * modules/stpcpy: Likewise.
35322         * modules/stpncpy: Likewise.
35323         * modules/strcase: Likewise.
35324         * modules/strchrnul: Likewise.
35325         * modules/strdup: Likewise.
35326         * modules/strndup: Likewise.
35327         * modules/strnlen: Likewise.
35328         * modules/strpbrk: Likewise.
35329         * modules/strsep: Likewise.
35330         * modules/strstr: Likewise.
35331         * modules/strtok_r: Likewise.
35332         * tests/test-dirname.c: Don't include "strdup.h", since
35333         <string.h> now suffices.
35334         * tests/test-memmem.c: Don't include "memmem.h", since
35335         <string.h> now suffices.
35336
35337 2007-01-25  Bruno Haible  <bruno@clisp.org>
35338
35339         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
35340         *resultp is 0.
35341
35342         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
35343         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
35344         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
35345         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
35346
35347         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
35348         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
35349         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
35350         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
35351         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
35352         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
35353
35354 2007-01-24  Bruno Haible  <bruno@clisp.org>
35355
35356         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
35357         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
35358         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
35359         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
35360         gl_FUNC_FTS_CORE.
35361         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
35362         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
35363         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
35364         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
35365         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
35366         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
35367         gl_FUNC_FCHOWNAT.
35368         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
35369         gl_FUNC_STRFTIME.
35370         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
35371         Reported by Ralf Wildenhues.
35372
35373 2007-01-24  Bruno Haible  <bruno@clisp.org>
35374
35375         Drop AC_REQUIRE calls that are redundant with the module dependencies.
35376         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
35377         gl_GETADDRINFO.
35378         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
35379         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
35380         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
35381
35382 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
35383
35384         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
35385         Don't use 'exit'; just return from 'main'.
35386         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
35387
35388         * lib/fnmatch_.h: Readjust white space and comments to match
35389         glibc, to avoid spurious diffs.
35390
35391 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
35392
35393         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
35394         2004-12-01 change by Jakub Jelinek, since this code won't compile
35395         if !LIBC.  Problem reported by Bob Proulx.
35396
35397 2007-01-23  Bruno Haible  <bruno@clisp.org>
35398
35399         * lib/striconveh.c: Include c-strcaseeq.h.
35400         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
35401         * modules/striconveh (Depends-on): Add c-strcaseeq.
35402
35403 2007-01-23  Bruno Haible  <bruno@clisp.org>
35404
35405         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
35406
35407         * modules/c-strcaseeq: New file.
35408         * lib/c-strcaseeq.h: New file.
35409
35410         * modules/streq: New file.
35411         * lib/streq.h: New file.
35412
35413 2007-01-23  Bruno Haible  <bruno@clisp.org>
35414
35415         * modules/striconveha-tests: New file.
35416         * tests/test-striconveha.c: New file.
35417
35418         * lib/striconveha.h: Include <stdbool.h>.
35419         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
35420         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
35421         (mem_iconveha_notranslit): Renamed from mem_iconveha.
35422         (mem_iconveha): New function.
35423         (str_iconveha_notranslit): Renamed from str_iconveha.
35424         (str_iconveha): New function.
35425         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
35426         c-strcase.
35427
35428 2007-01-23  Bruno Haible  <bruno@clisp.org>
35429
35430         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
35431         encodings without forgiving before trying any encoding with handler.
35432         (str_iconveha): Try all encodings without forgiving before trying any
35433         encoding with handler.
35434
35435 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
35436
35437         Import the following changes from libc.
35438
35439         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
35440
35441         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
35442
35443         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
35444
35445         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
35446         normal_bracket label.
35447
35448         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
35449
35450         [BZ #361]
35451         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
35452         to normal_bracket after fetching the next character.
35453
35454 2007-01-22  Bruno Haible  <bruno@clisp.org>
35455
35456         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
35457         argument.
35458         * lib/striconveh.c (iconv_carefully_1): New function.
35459         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
35460         argument.
35461         (str_cd_iconveh): Update.
35462         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
35463         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
35464         * tests/test-striconveh.c (MAGIC): New macro.
35465         (new_offsets): New function.
35466         (main): Test call with and without offsets.
35467
35468 2007-01-22  Bruno Haible  <bruno@clisp.org>
35469
35470         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
35471         * modules/sys_select (Makefile.am): Likewise.
35472         * modules/sys_socket (Makefile.am): Likewise.
35473         * modules/sys_time (Makefile.am): Likewise.
35474
35475 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
35476
35477         * modules/gettimeofday (License): Change from GPL to LGPL, since
35478         gettimeofday is a library function.
35479
35480 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
35481
35482         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
35483
35484 2007-01-21  Bruno Haible  <bruno@clisp.org>
35485
35486         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
35487
35488 2007-01-21  Bruno Haible  <bruno@clisp.org>
35489
35490         * modules/striconveha: New file.
35491         * lib/striconveha.h: New file.
35492         * lib/striconveha.c: New file.
35493         * MODULES.html.sh (Internationalization functions): Add striconveha.
35494         * lib/striconv.c (str_iconv): Optimize the case of an empty input
35495         string.
35496         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
35497
35498 2007-01-21  Bruno Haible  <bruno@clisp.org>
35499
35500         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
35501         * lib/striconveh.c (str_iconveh): Likewise.
35502
35503 2007-01-21  Bruno Haible  <bruno@clisp.org>
35504
35505         * lib/striconveh.h (mem_iconveh): New declaration.
35506         * lib/striconveh.c (mem_iconveh): New function.
35507         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
35508
35509 2007-01-21  Bruno Haible  <bruno@clisp.org>
35510
35511         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
35512
35513         * lib/striconveh.h (mem_cd_iconveh): Change specification.
35514         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
35515         original result buffer.
35516         (str_cd_iconveh): Update.
35517         * tests/test-striconveh.c (main): Update.
35518
35519         * lib/striconv.h (mem_cd_iconv): Change specification.
35520         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
35521         result buffer.
35522         (str_cd_iconv): Update.
35523         * tests/test-striconv.c (main): Update.
35524
35525 2007-01-21  Bruno Haible  <bruno@clisp.org>
35526
35527         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
35528
35529 2007-01-20  Jim Meyering  <jim@meyering.net>
35530
35531         * lib/userspec.c (parse_with_separator): If a user or group string
35532         starts with "+", skip the corresponding name-to-ID look-up, since
35533         such a look-up must fail: user and group names may not include "+".
35534
35535 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
35536
35537         * lib/poll.c: Include sys/time.h and time.h unconditionally,
35538         since we now assume the sys_time module.
35539         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
35540         check for sys/time.h; no longer needed.
35541         * modules/poll (Depends-on): Depend on sys_time.
35542
35543 2007-01-18  Bruno Haible  <bruno@clisp.org>
35544
35545         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
35546         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
35547
35548         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
35549         gettimeofday.
35550
35551         * tests/test-gettimeofday.c: Include <time.h>.
35552         (dummy): Remove variable.
35553
35554         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
35555         gl_HEADER_SYS_TIME_H.
35556         (gl_HEADER_SYS_TIME_H): New macro.
35557
35558         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
35559         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
35560         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
35561         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
35562         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
35563         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
35564         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
35565         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
35566         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
35567         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
35568         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
35569
35570         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
35571         last change; it caused a compilation error when cross-compiling to
35572         Cygwin.
35573
35574 2007-01-18  Jim Meyering  <jim@meyering.net>
35575
35576         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
35577         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
35578         than the race-prone "test -d sys || mkdir sys".
35579         (configure.ac): Use AC_PROG_MKDIR_P.
35580         * modules/sys_select: Likewise.
35581         * modules/sys_socket: Likewise.
35582         * modules/sys_time: Likewise.
35583
35584 2007-01-18  Eric Blake  <ebb9@byu.net>
35585
35586         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
35587         replace gettimeofday.
35588         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
35589         name, to avoid infinite recursion.
35590
35591 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
35592
35593         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
35594         module sys_time.
35595         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
35596         assume timespec.h defines struct timeval.
35597         * lib/settime.c: Likewise.
35598         * lib/utimens.c: Likewise.
35599         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
35600         since we now assume the gettimeofday module.
35601         * lib/tempname.c (__gen_tempname): Likewise.
35602         * lib/gettimeofday.h: Remove.
35603         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
35604         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
35605         Include <time.h>, for 'time()'.
35606         (localtime_buffer_addr): Also use this workaround if
35607         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
35608         to simplify the uses.  All uses changed.
35609         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
35610         that #undef is inside {}, and 'const' follows type name consistently.
35611         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
35612         (gettimeofday): Do not use the maximum possible value for
35613         tv->tv_usec, since that might break usages other than ls.c.
35614         Instead, we'll leave ls.c alone.  This undoes today's patch
35615         by Bruno.  Add a compile-time warning for 1s-clock resolution;
35616         we've never observed the problem but might as well keep the
35617         canary.
35618         * lib/nanosleep.c: Include timespec.h first, for interface check.
35619         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
35620         now assume the sys_time module.
35621         * lib/tempname.c: Likewise.
35622         * lib/timespec.h: Likewise.
35623         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
35624         needed.
35625         * lib/strftime.c: Likewise.
35626         * lib/timespec.h: Likewise.
35627         * lib/posixtm.c: Include posixtm.h first, for interface check.
35628         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
35629         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
35630         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
35631         * lib/sys_time_.h: New file.
35632         * lib/timespec.h (struct timespec): Use long int, not long.
35633         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
35634         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
35635         Remove obsolescent call to AC_HEADER_TIME.
35636         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
35637         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
35638         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
35639         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
35640         Likewise.
35641         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
35642         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
35643         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
35644         into the sys_time module.  Check for gettimeofday just once.
35645         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
35646         for gettimeofday signature to just check the signature.  Merely
35647         compile it, since linking doesn't test signature.  Improve test for
35648         whether gettimeofday.o is actually needed.
35649         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
35650         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
35651         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
35652         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
35653         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
35654         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
35655         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
35656         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
35657         than worrying about sys/time.h.
35658         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
35659         Don't bother worrying about TIME_WITH_SYS_TIME.
35660         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
35661         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
35662         * m4/sys_time_h.m4: New file.
35663         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
35664         Don't include sys/time.h.  Return from main rather than exiting.
35665         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
35666         all uses changed.
35667         * modules/gethrxtime (Depends-on): Add sys_time.
35668         * modules/gettime (Depends-on): Likewise.
35669         * modules/gettimeofday (Depends-on): Likewise.
35670         * modules/nanosleep (Depends-on): Likewise.
35671         * modules/settime (Depends-on): Likewise.
35672         * modules/tempname (Depends-on): Likewise.
35673         * modules/utimens (Depends-on): Likewise.
35674         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
35675         (Include:) Change back to <sys/time.h>.
35676         (Maintainer:) Add self.
35677         * modules/sys_time: New file.
35678         * modules/tempname (Depends-on): Add gettimeofday.
35679         * tests/test-gettimeofday.c: Include <sys/time.h>
35680         rather than gettimeofday.h.
35681
35682 2007-01-17  Bruno Haible  <bruno@clisp.org>
35683
35684         * gnulib-tool (func_get_license): Revert last patch. Instead, let
35685         the license default to GPL.
35686         (func_create_testdir): Don't complain if a module is LGPL and its
35687         tests module depends on GPLed modules.
35688
35689 2007-01-17  Bruno Haible  <bruno@clisp.org>
35690
35691         * lib/gettimeofday.c (gettimeofday): Add code for the case
35692         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
35693         maximum possible value for tv->tv_usec, rather than the minimum one.
35694
35695 2005-10-08  Martin Lambers  <marlam@marlam.de>
35696 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
35697 2007-01-16  Bruno Haible  <bruno@clisp.org>
35698
35699         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
35700         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
35701         gl_FUNC_GETTIMEOFDAY.
35702         (Include): Add gettimeofday.h.
35703         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
35704         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
35705         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
35706         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
35707         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
35708         * lib/gettimeofday.h: New file.
35709         * lib/gettimeofday.c: Include <sys/timeb.h>.
35710         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
35711         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
35712         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
35713         fall back on time().
35714
35715         * tests/test-gettimeofday.c: New file.
35716         * modules/gettimeofday-tests: New file.
35717
35718 2007-01-16  Eric Blake  <ebb9@byu.net>
35719
35720         * modules/fnmatch (Depends-on): Depend on wchar.
35721         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
35722         * m4/fnmatch.m4: Likewise.
35723         * modules/mbchar (Makefile.am): Assume <wchar.h>.
35724         * m4/mbchar.m4: Likewise.
35725         * modules/mbswidth (Depends-on): Depend on wchar.
35726         * lib/mbswidth.c: Assume <wchar.h>.
35727         * m4/mbswidth.m4: Likewise.
35728         * modules/quotearg (Depends-on): Depend on wchar.
35729         * lib/quotearg.c: Assume <wchar.h>.
35730         * m4/quotearg.m4: Likewise.
35731         * modules/regex (Depends-on): Depend on wchar.
35732         * lib/regex_internal.h: Assume <wchar.h>.
35733         * m4/regex.m4: Likewise.
35734         * modules/stdint (Depends-on): Depend on wchar.
35735         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
35736         * m4/stdint.m4: Likewise.
35737         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
35738         * modules/strftime (Depends-on): Depend on wchar.
35739         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
35740         * modules/strtol (Depends-on): Depend on wchar.
35741         * lib/strtol.c: Assume <wchar.h>.
35742         * modules/wcwidth (Depends-on): Depend on wchar.
35743         * lib/wcwidth.h: Assume <wchar.h>.
35744         * m4/wcwidth.m4: Likewise.
35745
35746 2007-01-16  Bruno Haible  <bruno@clisp.org>
35747
35748         * modules/csharpexec-script: New, created from...
35749         * modules/csharpexec: ... this.
35750
35751 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
35752
35753         * modules/javaexec-script: New, created from...
35754         * modules/javaexec: ... this.
35755
35756 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
35757
35758         * modules/poll (Dependencies): Add sys_select.
35759
35760 2007-01-15  Jim Meyering  <jim@meyering.net>
35761
35762         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
35763         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
35764         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
35765         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
35766
35767 2007-01-15  Bruno Haible  <bruno@clisp.org>
35768
35769         * modules/striconveh: New file.
35770         * lib/striconveh.h: New file.
35771         * lib/striconveh.c: New file.
35772         * MODULES.html.sh (Internationalization functions): Add striconveh.
35773
35774         * modules/striconveh-tests: New file.
35775         * tests/test-striconveh.c: New file.
35776
35777 2007-01-15  Bruno Haible  <bruno@clisp.org>
35778
35779         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
35780         not from GNU libiconv or GNU libc.
35781
35782 2007-01-15  Bruno Haible  <bruno@clisp.org>
35783
35784         * doc/gnulib-intro.texi (Copyright): Explain the different license
35785         terms for module descriptions, autoconf macros, tests, documentation.
35786
35787 2007-01-14  Bruno Haible  <bruno@clisp.org>
35788
35789         * modules/striconv-tests: New file.
35790         * tests/test-striconv.c: New file.
35791
35792 2007-01-14  Bruno Haible  <bruno@clisp.org>
35793
35794         * modules/iconv-tests: New file.
35795         * tests/test-iconv.c: New file.
35796
35797 2007-01-14  Bruno Haible  <bruno@clisp.org>
35798
35799         * gnulib-tool (func_get_license): For test modules, use the license of
35800         the main module.
35801
35802 2007-01-14  Bruno Haible  <bruno@clisp.org>
35803
35804         * modules/iconv (Include): Clarify that <iconv.h> can only be included
35805         if iconv is found to exist.
35806
35807 2007-01-14  Bruno Haible  <bruno@clisp.org>
35808
35809         * modules/c-ctype-tests: New file.
35810         * tests/test-c-ctype.c: New file.
35811
35812 2007-01-14  Bruno Haible  <bruno@clisp.org>
35813
35814         * modules/binary-io-tests: New file.
35815         * tests/test-binary-io.sh: New file.
35816         * tests/test-binary-io.c: New file.
35817
35818 2007-01-14  Bruno Haible  <bruno@clisp.org>
35819
35820         * modules/array-oset-tests: New file.
35821         * tests/test-array_oset.c: New file.
35822
35823 2007-01-14  Bruno Haible  <bruno@clisp.org>
35824
35825         * modules/array-list-tests: New file.
35826         * tests/test-array_list.c: New file.
35827
35828 2007-01-14  Bruno Haible  <bruno@clisp.org>
35829
35830         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
35831         and make.
35832         Reported by Simon Josefsson in
35833         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
35834
35835 2007-01-14  Bruno Haible  <bruno@clisp.org>
35836
35837         * modules/allocsa-tests: New file.
35838         * tests/test-allocsa.c: New file.
35839
35840 2007-01-14  Bruno Haible  <bruno@clisp.org>
35841
35842         * modules/fchdir (Depends-on): Add absolute-header.
35843         * modules/unistd (Depends-on): Likewise.
35844
35845 2006-12-30  Bruno Haible  <bruno@clisp.org>
35846
35847         * modules/fchdir: New file.
35848         * modules/unistd (Files): Add lib/unistd_.h.
35849         (Makefile.am): Generate unistd.h from unistd_.h.
35850         * lib/fchdir.c: New file.
35851         * lib/dirent_.h: New file.
35852         * lib/unistd_.h: New file.
35853         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
35854         * m4/fchdir.m4: New file.
35855         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
35856         (gl_HEADER_UNISTD): Invoke it.
35857         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
35858         function.
35859         * lib/backupfile.c (opendir, closedir): Undefine.
35860         * lib/chown.c (open, close): Undefine.
35861         * lib/clean-temp.c (open, close): Undefine.
35862         * lib/copy-file.c (open, close): Undefine.
35863         * lib/execute.c (open, close): Undefine.
35864         * lib/fsusage.c (open, close): Undefine.
35865         * lib/gc-gnulib.c (open, close): Undefine.
35866         * lib/getcwd.c (opendir, closedir): Undefine.
35867         * lib/glob.c (opendir, closedir): Undefine.
35868         * lib/javacomp.c (open, close): Undefine.
35869         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
35870         * lib/openat-proc.c (open, close): Undefine.
35871         * lib/pagealign_alloc.c (open, close): Undefine.
35872         * lib/pipe.c (open, close): Undefine.
35873         * lib/progreloc.c (open, close): Undefine.
35874         * lib/savedir.c (opendir, closedir): Undefine.
35875         * lib/utime.c (open, close): Undefine.
35876         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
35877
35878 2007-01-10  Bruno Haible  <bruno@clisp.org>
35879
35880         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
35881
35882 2007-01-12  Eric Blake  <ebb9@byu.net>
35883
35884         Provide a robust <wchar.h>.  Further simplifications are now
35885         possible in other modules, but not included here.
35886         * modules/wchar: New module.
35887         * m4/wchar.m4: New file.
35888         * lib/wchar_.h: Likewise.
35889         * modules/mbchar (Depends-on): Depend on wchar, as the first use
35890         of the new module.
35891         * MODULES.html.sh (Extended multibyte and wide character utilities):
35892         New section.
35893
35894 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
35895
35896         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
35897         to a reasonable default for memory allocation.
35898         (xreadlink): Don't allocate a huge buffer, to work around a buggy
35899         file system that reports garbage st_size values for symlinks.
35900         Problem reported by Liyang Hu.
35901
35902 2007-01-11  Simon Josefsson  <simon@josefsson.org>
35903
35904         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
35905         Emacs .#* auto-save files).
35906
35907 2007-01-11  Bruno Haible  <bruno@clisp.org>
35908
35909         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
35910         directory.
35911
35912 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
35913
35914         Use @...@ consistently in lib/wctype_.h.
35915         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
35916         on it being set to 1 or 0.
35917         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
35918         go back to AC_SUBSTing it.
35919         * modules/wctype (Makefile.am): Undo previous change.
35920
35921 2007-01-10  Eric Blake  <ebb9@byu.net>
35922
35923         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
35924         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
35925         * modules/wctype (Makefile.am): Likewise.
35926         Reported by Chris McGuire.
35927
35928 2007-01-10  Jim Meyering  <jim@meyering.net>
35929
35930         fts.c: a small readability/maintainability improvement
35931         * lib/fts.c (fts_read): Make this code slightly more readable and
35932         maintainable by hoisting the "sp->fts_cur = p" assignments to
35933         immediately follow the statements that set P.  Derived from
35934         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
35935
35936 2007-01-10  Eric Blake  <ebb9@byu.net>
35937
35938         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
35939         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
35940         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
35941         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
35942         Reported by Chris McGuire.
35943
35944 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
35945
35946         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
35947         in sed script.
35948
35949 2007-01-09  Bruno Haible  <bruno@clisp.org>
35950
35951         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
35952         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
35953         variables.
35954         (func_module): Use them.
35955
35956 2007-01-09  Bruno Haible  <bruno@clisp.org>
35957
35958         * modules/unistr/base: New file.
35959         * lib/unistr.h: New file.
35960
35961         * modules/unistr/u8-to-u16: New file.
35962         * lib/unistr/u8-to-u16.c: New file.
35963
35964         * modules/unistr/u8-to-u32: New file.
35965         * lib/unistr/u8-to-u32.c: New file.
35966
35967         * modules/unistr/u16-to-u8: New file.
35968         * lib/unistr/u16-to-u8.c: New file.
35969
35970         * modules/unistr/u16-to-u32: New file.
35971         * lib/unistr/u16-to-u32.c: New file.
35972
35973         * modules/unistr/u32-to-u8: New file.
35974         * lib/unistr/u32-to-u8.c: New file.
35975
35976         * modules/unistr/u32-to-u16: New file.
35977         * lib/unistr/u32-to-u16.c: New file.
35978
35979         * modules/unistr/u8-check: New file.
35980         * modules/unistr/u16-check: New file.
35981         * modules/unistr/u32-check: New file.
35982         * lib/unistr/u8-check.c: New file.
35983         * lib/unistr/u16-check.c: New file.
35984         * lib/unistr/u32-check.c: New file.
35985
35986         * modules/unistr/u8-chr: New file.
35987         * modules/unistr/u16-chr: New file.
35988         * modules/unistr/u32-chr: New file.
35989         * lib/unistr/u8-chr.c: New file.
35990         * lib/unistr/u16-chr.c: New file.
35991         * lib/unistr/u32-chr.c: New file.
35992
35993         * modules/unistr/u8-cmp: New file.
35994         * modules/unistr/u16-cmp: New file.
35995         * modules/unistr/u32-cmp: New file.
35996         * lib/unistr/u8-cmp.c: New file.
35997         * lib/unistr/u16-cmp.c: New file.
35998         * lib/unistr/u32-cmp.c: New file.
35999
36000         * modules/unistr/u8-cpy: New file.
36001         * modules/unistr/u16-cpy: New file.
36002         * modules/unistr/u32-cpy: New file.
36003         * lib/unistr/u8-cpy.c: New file.
36004         * lib/unistr/u16-cpy.c: New file.
36005         * lib/unistr/u32-cpy.c: New file.
36006         * lib/unistr/u-cpy.h: New file.
36007
36008         * modules/unistr/u8-cpy-alloc: New file.
36009         * modules/unistr/u16-cpy-alloc: New file.
36010         * modules/unistr/u32-cpy-alloc: New file.
36011         * lib/unistr/u8-cpy-alloc.c: New file.
36012         * lib/unistr/u16-cpy-alloc.c: New file.
36013         * lib/unistr/u32-cpy-alloc.c: New file.
36014         * lib/unistr/u-cpy-alloc.h: New file.
36015
36016         * modules/unistr/u8-endswith: New file.
36017         * modules/unistr/u16-endswith: New file.
36018         * modules/unistr/u32-endswith: New file.
36019         * lib/unistr/u8-endswith.c: New file.
36020         * lib/unistr/u16-endswith.c: New file.
36021         * lib/unistr/u32-endswith.c: New file.
36022         * lib/unistr/u-endswith.h: New file.
36023
36024         * modules/unistr/u8-mblen: New file.
36025         * modules/unistr/u16-mblen: New file.
36026         * modules/unistr/u32-mblen: New file.
36027         * lib/unistr/u8-mblen.c: New file.
36028         * lib/unistr/u16-mblen.c: New file.
36029         * lib/unistr/u32-mblen.c: New file.
36030
36031         * modules/unistr/u8-mbtouc: New file.
36032         * modules/unistr/u16-mbtouc: New file.
36033         * modules/unistr/u32-mbtouc: New file.
36034         * lib/unistr/u8-mbtouc.c: New file.
36035         * lib/unistr/u16-mbtouc.c: New file.
36036         * lib/unistr/u32-mbtouc.c: New file.
36037
36038         * modules/unistr/u8-mbtouc-safe: New file.
36039         * modules/unistr/u16-mbtouc-safe: New file.
36040         * modules/unistr/u32-mbtouc-safe: New file.
36041         * lib/unistr/u8-mbtouc-safe.c: New file.
36042         * lib/unistr/u16-mbtouc-safe.c: New file.
36043         * lib/unistr/u32-mbtouc-safe.c: New file.
36044
36045         * modules/unistr/u8-move: New file.
36046         * modules/unistr/u16-move: New file.
36047         * modules/unistr/u32-move: New file.
36048         * lib/unistr/u8-move.c: New file.
36049         * lib/unistr/u16-move.c: New file.
36050         * lib/unistr/u32-move.c: New file.
36051         * lib/unistr/u-move.h: New file.
36052
36053         * modules/unistr/u8-next: New file.
36054         * modules/unistr/u16-next: New file.
36055         * modules/unistr/u32-next: New file.
36056         * lib/unistr/u8-next.c: New file.
36057         * lib/unistr/u16-next.c: New file.
36058         * lib/unistr/u32-next.c: New file.
36059
36060         * modules/unistr/u8-prev: New file.
36061         * modules/unistr/u16-prev: New file.
36062         * modules/unistr/u32-prev: New file.
36063         * lib/unistr/u8-prev.c: New file.
36064         * lib/unistr/u16-prev.c: New file.
36065         * lib/unistr/u32-prev.c: New file.
36066
36067         * modules/unistr/u8-set: New file.
36068         * modules/unistr/u16-set: New file.
36069         * modules/unistr/u32-set: New file.
36070         * lib/unistr/u8-set.c: New file.
36071         * lib/unistr/u16-set.c: New file.
36072         * lib/unistr/u32-set.c: New file.
36073         * lib/unistr/u-set.h: New file.
36074
36075         * modules/unistr/u8-startswith: New file.
36076         * modules/unistr/u16-startswith: New file.
36077         * modules/unistr/u32-startswith: New file.
36078         * lib/unistr/u8-startswith.c: New file.
36079         * lib/unistr/u16-startswith.c: New file.
36080         * lib/unistr/u32-startswith.c: New file.
36081         * lib/unistr/u-startswith.h: New file.
36082
36083         * modules/unistr/u8-stpcpy: New file.
36084         * modules/unistr/u16-stpcpy: New file.
36085         * modules/unistr/u32-stpcpy: New file.
36086         * lib/unistr/u8-stpcpy.c: New file.
36087         * lib/unistr/u16-stpcpy.c: New file.
36088         * lib/unistr/u32-stpcpy.c: New file.
36089         * lib/unistr/u-stpcpy.h: New file.
36090
36091         * modules/unistr/u8-stpncpy: New file.
36092         * modules/unistr/u16-stpncpy: New file.
36093         * modules/unistr/u32-stpncpy: New file.
36094         * lib/unistr/u8-stpncpy.c: New file.
36095         * lib/unistr/u16-stpncpy.c: New file.
36096         * lib/unistr/u32-stpncpy.c: New file.
36097         * lib/unistr/u-stpncpy.h: New file.
36098
36099         * modules/unistr/u8-strcat: New file.
36100         * modules/unistr/u16-strcat: New file.
36101         * modules/unistr/u32-strcat: New file.
36102         * lib/unistr/u8-strcat.c: New file.
36103         * lib/unistr/u16-strcat.c: New file.
36104         * lib/unistr/u32-strcat.c: New file.
36105         * lib/unistr/u-strcat.h: New file.
36106
36107         * modules/unistr/u8-strchr: New file.
36108         * modules/unistr/u16-strchr: New file.
36109         * modules/unistr/u32-strchr: New file.
36110         * lib/unistr/u8-strchr.c: New file.
36111         * lib/unistr/u16-strchr.c: New file.
36112         * lib/unistr/u32-strchr.c: New file.
36113
36114         * modules/unistr/u8-strcmp: New file.
36115         * modules/unistr/u16-strcmp: New file.
36116         * modules/unistr/u32-strcmp: New file.
36117         * lib/unistr/u8-strcmp.c: New file.
36118         * lib/unistr/u16-strcmp.c: New file.
36119         * lib/unistr/u32-strcmp.c: New file.
36120
36121         * modules/unistr/u8-strcpy: New file.
36122         * modules/unistr/u16-strcpy: New file.
36123         * modules/unistr/u32-strcpy: New file.
36124         * lib/unistr/u8-strcpy.c: New file.
36125         * lib/unistr/u16-strcpy.c: New file.
36126         * lib/unistr/u32-strcpy.c: New file.
36127         * lib/unistr/u-strcpy.h: New file.
36128
36129         * modules/unistr/u8-strcspn: New file.
36130         * modules/unistr/u16-strcspn: New file.
36131         * modules/unistr/u32-strcspn: New file.
36132         * lib/unistr/u8-strcspn.c: New file.
36133         * lib/unistr/u16-strcspn.c: New file.
36134         * lib/unistr/u32-strcspn.c: New file.
36135         * lib/unistr/u-strcspn.h: New file.
36136
36137         * modules/unistr/u8-strdup: New file.
36138         * modules/unistr/u16-strdup: New file.
36139         * modules/unistr/u32-strdup: New file.
36140         * lib/unistr/u8-strdup.c: New file.
36141         * lib/unistr/u16-strdup.c: New file.
36142         * lib/unistr/u32-strdup.c: New file.
36143         * lib/unistr/u-strdup.h: New file.
36144
36145         * modules/unistr/u8-strlen: New file.
36146         * modules/unistr/u16-strlen: New file.
36147         * modules/unistr/u32-strlen: New file.
36148         * lib/unistr/u8-strlen.c: New file.
36149         * lib/unistr/u16-strlen.c: New file.
36150         * lib/unistr/u32-strlen.c: New file.
36151         * lib/unistr/u-strlen.h: New file.
36152
36153         * modules/unistr/u8-strmblen: New file.
36154         * modules/unistr/u16-strmblen: New file.
36155         * modules/unistr/u32-strmblen: New file.
36156         * lib/unistr/u8-strmblen.c: New file.
36157         * lib/unistr/u16-strmblen.c: New file.
36158         * lib/unistr/u32-strmblen.c: New file.
36159
36160         * modules/unistr/u8-strmbtouc: New file.
36161         * modules/unistr/u16-strmbtouc: New file.
36162         * modules/unistr/u32-strmbtouc: New file.
36163         * lib/unistr/u8-strmbtouc.c: New file.
36164         * lib/unistr/u16-strmbtouc.c: New file.
36165         * lib/unistr/u32-strmbtouc.c: New file.
36166
36167         * modules/unistr/u8-strncat: New file.
36168         * modules/unistr/u16-strncat: New file.
36169         * modules/unistr/u32-strncat: New file.
36170         * lib/unistr/u8-strncat.c: New file.
36171         * lib/unistr/u16-strncat.c: New file.
36172         * lib/unistr/u32-strncat.c: New file.
36173         * lib/unistr/u-strncat.h: New file.
36174
36175         * modules/unistr/u8-strncmp: New file.
36176         * modules/unistr/u16-strncmp: New file.
36177         * modules/unistr/u32-strncmp: New file.
36178         * lib/unistr/u8-strncmp.c: New file.
36179         * lib/unistr/u16-strncmp.c: New file.
36180         * lib/unistr/u32-strncmp.c: New file.
36181
36182         * modules/unistr/u8-strncpy: New file.
36183         * modules/unistr/u16-strncpy: New file.
36184         * modules/unistr/u32-strncpy: New file.
36185         * lib/unistr/u8-strncpy.c: New file.
36186         * lib/unistr/u16-strncpy.c: New file.
36187         * lib/unistr/u32-strncpy.c: New file.
36188         * lib/unistr/u-strncpy.h: New file.
36189
36190         * modules/unistr/u8-strnlen: New file.
36191         * modules/unistr/u16-strnlen: New file.
36192         * modules/unistr/u32-strnlen: New file.
36193         * lib/unistr/u8-strnlen.c: New file.
36194         * lib/unistr/u16-strnlen.c: New file.
36195         * lib/unistr/u32-strnlen.c: New file.
36196         * lib/unistr/u-strnlen.h: New file.
36197
36198         * modules/unistr/u8-strpbrk: New file.
36199         * modules/unistr/u16-strpbrk: New file.
36200         * modules/unistr/u32-strpbrk: New file.
36201         * lib/unistr/u8-strpbrk.c: New file.
36202         * lib/unistr/u16-strpbrk.c: New file.
36203         * lib/unistr/u32-strpbrk.c: New file.
36204         * lib/unistr/u-strpbrk.h: New file.
36205
36206         * modules/unistr/u8-strrchr: New file.
36207         * modules/unistr/u16-strrchr: New file.
36208         * modules/unistr/u32-strrchr: New file.
36209         * lib/unistr/u8-strrchr.c: New file.
36210         * lib/unistr/u16-strrchr.c: New file.
36211         * lib/unistr/u32-strrchr.c: New file.
36212
36213         * modules/unistr/u8-strspn: New file.
36214         * modules/unistr/u16-strspn: New file.
36215         * modules/unistr/u32-strspn: New file.
36216         * lib/unistr/u8-strspn.c: New file.
36217         * lib/unistr/u16-strspn.c: New file.
36218         * lib/unistr/u32-strspn.c: New file.
36219         * lib/unistr/u-strspn.h: New file.
36220
36221         * modules/unistr/u8-strstr: New file.
36222         * modules/unistr/u16-strstr: New file.
36223         * modules/unistr/u32-strstr: New file.
36224         * lib/unistr/u8-strstr.c: New file.
36225         * lib/unistr/u16-strstr.c: New file.
36226         * lib/unistr/u32-strstr.c: New file.
36227         * lib/unistr/u-strstr.h: New file.
36228
36229         * modules/unistr/u8-strtok: New file.
36230         * modules/unistr/u16-strtok: New file.
36231         * modules/unistr/u32-strtok: New file.
36232         * lib/unistr/u8-strtok.c: New file.
36233         * lib/unistr/u16-strtok.c: New file.
36234         * lib/unistr/u32-strtok.c: New file.
36235         * lib/unistr/u-strtok.h: New file.
36236
36237         * modules/unistr/u8-uctomb: New file.
36238         * modules/unistr/u16-uctomb: New file.
36239         * modules/unistr/u32-uctomb: New file.
36240         * lib/unistr/u8-uctomb.c: New file.
36241         * lib/unistr/u16-uctomb.c: New file.
36242         * lib/unistr/u32-uctomb.c: New file.
36243
36244         * MODULES.html.sh (Unicode string functions): Add the new modules.
36245
36246 2007-01-08  Bruno Haible  <bruno@clisp.org>
36247
36248         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
36249         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
36250         subdirectories.
36251
36252 2007-01-08  Karl Berry  <karl@gnu.org>
36253
36254         * doc/error.texi: mention that main() fns must set program_name
36255         when progname is used.
36256
36257 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
36258
36259         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
36260         WCTYPE_H is empty, for the benefit of builds from non-distclean
36261         directories.  Problem reported by Eric Blake in
36262         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
36263
36264 2007-01-08  Bruno Haible  <bruno@clisp.org>
36265
36266         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
36267         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
36268         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
36269         PROVIDE_CANONICALIZE_FILENAME_MODE.
36270         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
36271
36272 2007-01-08  Bruno Haible  <bruno@clisp.org>
36273
36274         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
36275         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
36276         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
36277         * lib/fts.c: Likewise.
36278         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
36279
36280 2006-12-25  Bruno Haible  <bruno@clisp.org>
36281
36282         * modules/utf8-ucs4-safe: New file.
36283         * lib/utf8-ucs4-safe.h: New file.
36284         * lib/unistr/utf8-ucs4-safe.c: New file.
36285
36286         * modules/utf16-ucs4-safe: New file.
36287         * lib/utf16-ucs4-safe.h: New file.
36288         * lib/unistr/utf16-ucs4-safe.c: New file.
36289
36290         * MODULES.html.sh (Unicode string functions): Add the new modules.
36291
36292 2007-01-08  Bruno Haible  <bruno@clisp.org>
36293
36294         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
36295         (Depends-on): Add unitypes.
36296         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
36297         (u8_mbtouc_aux): Move out to separate file.
36298         (u8_mbtouc): Use ucs4_t, uint8_t types.
36299         * lib/unistr/utf8-ucs4.c: New file.
36300
36301         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
36302         (Depends-on): Add unitypes.
36303         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
36304         (u16_mbtouc_aux): Move out to separate file.
36305         (u16_mbtouc): Use ucs4_t, uint16_t types.
36306         * lib/unistr/utf16-ucs4.c: New file.
36307
36308         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
36309         (Depends-on): Add unitypes.
36310         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
36311         (u8_uctomb_aux): Move out to separate file.
36312         (u8_uctomb): Use ucs4_t, uint8_t types.
36313         * lib/unistr/ucs4-utf8.c: New file.
36314
36315         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
36316         (Depends-on): Add unitypes.
36317         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
36318         (u16_uctomb_aux): Move out to separate file.
36319         (u16_uctomb): Use ucs4_t, uint16_t types.
36320         * lib/unistr/ucs4-utf16.c: New file.
36321
36322 2006-12-25  Bruno Haible  <bruno@clisp.org>
36323
36324         * modules/unitypes: New file.
36325         * lib/unitypes.h: New file.
36326         * MODULES.html.sh (func_all_modules): New section "Unicode string
36327         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
36328         this section. Add unitypes.
36329
36330 2007-01-08  Bruno Haible  <bruno@clisp.org>
36331
36332         Avoid variable names that conflict with those from libtool.
36333         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
36334         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
36335         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
36336         library_names_spec to acl_library_names_spec, hardcode_* to
36337         acl_hardcode_*.
36338         Reported by Ralf Wildenhues.
36339
36340 2007-01-08  Bruno Haible  <bruno@clisp.org>
36341
36342         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
36343         definition.
36344         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
36345         definition.
36346         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
36347         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
36348         definition.
36349         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
36350         definition.
36351         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
36352         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
36353         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
36354         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
36355         definition.
36356         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
36357         definition.
36358         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
36359         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
36360         GC_USE_<algorithm>.
36361         * lib/gc-libgcrypt.c: Likewise.
36362         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
36363         * modules/gc-arctwo (configure.ac): Likewise.
36364         * modules/gc-des (configure.ac): Likewise.
36365         * modules/gc-hmac-md5 (configure.ac): Likewise.
36366         * modules/gc-hmac-sha1 (configure.ac): Likewise.
36367         * modules/gc-md2 (configure.ac): Likewise.
36368         * modules/gc-md4 (configure.ac): Likewise.
36369         * modules/gc-md5 (configure.ac): Likewise.
36370         * modules/gc-random (configure.ac): Likewise.
36371         * modules/gc-rijndael (configure.ac): Likewise.
36372         * modules/gc-sha1 (configure.ac): Likewise.
36373
36374 2007-01-08  Bruno Haible  <bruno@clisp.org>
36375
36376         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
36377         macro definition.
36378         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
36379         definition.
36380         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
36381         definition.
36382         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
36383         * modules/fcntl-safer (configure.ac): Likewise.
36384         * modules/fopen-safer (configure.ac): Likewise.
36385         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
36386         GNULIB_FWRITEERROR macro definition.
36387
36388 2007-01-08  Bruno Haible  <bruno@clisp.org>
36389
36390         * m4/gnulib-common.m4: New file.
36391         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
36392         (func_get_filelist): Add m4/gnulib-common.m4.
36393
36394 2007-01-08  Bruno Haible  <bruno@clisp.org>
36395
36396         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
36397         command.
36398
36399 2007-01-08  Jim Meyering  <jim@meyering.net>
36400
36401         Use a more robust test for a "can't happen" condition.
36402         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
36403         narrowed the st_size value.  Presuming the "can't happen" condition
36404         is true, that narrowing could conceivably convert an invalid st_size
36405         value into a valid one.  Instead, use a change based on Matthew
36406         Woehlke's original patch.
36407
36408         Slight readability improvement: use an assert-like macro
36409         in place of literal "abort ()" uses.
36410         * lib/fts.c (fts_assert): Define.
36411         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
36412         Use this macro instead of a bare 'abort'.
36413
36414 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
36415
36416         Don't worry about using IRIX 5.3's wctype.h broken definitions;
36417         simply work around them.
36418         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
36419         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
36420         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
36421         declaring.
36422         Don't bother to define as macros, since the standard doesn't require it.
36423         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
36424         longer worry about IRIX 5.3.
36425         (HAVE_WCTYPE_CTMP_BUG): Remove.
36426
36427 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
36428
36429         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
36430         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
36431         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
36432         Problems reported by Georg Schwarz for IRIX 5.3.
36433
36434         * gnulib-tool (autoconf_minversion): Take the maximum version number
36435         found, not the minimum.  Problem reported by James Youngman.
36436
36437 2007-01-03  Karl Berry  <karl@gnu.org>
36438
36439         * doc/error.texi: new file, explaining interaction with progname.
36440         * doc/gnulib.texi: include it.  Update copyright.
36441
36442 2007-01-03  Simon Josefsson  <simon@josefsson.org>
36443
36444         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
36445         AC_CANONICAL_HOST, to improve autobuild outputs.
36446
36447 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
36448             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
36449
36450         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
36451         sockets, server sockets, and other file descriptors.  Count errors
36452         to compute the return value.  Reorder the code a bit to be easier
36453         to follow.  Don't set event bits that were not requested (except
36454         POLLERR and POLLHUP).
36455
36456 2007-01-01  Bruno Haible  <bruno@clisp.org>
36457
36458         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
36459
36460 2007-01-03  Jim Meyering  <jim@meyering.net>
36461
36462         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
36463
36464 2007-01-02  Bruno Haible  <bruno@clisp.org>
36465
36466         * modules/settime (Include): Require timespec.h.
36467         * modules/nanosleep (Include): Likewise.
36468
36469 2007-01-01  Bruno Haible  <bruno@clisp.org>
36470
36471         * gnulib-tool (func_emit_copyright_notice): Bump year.
36472         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
36473
36474 2007-01-01  Bruno Haible  <bruno@clisp.org>
36475
36476         Improve support for OpenBSD.
36477         * build-aux/config.rpath (libname_spec): Export.
36478         (library_names_spec): New variable. Export.
36479         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
36480         library_names_spec from the config.rpath output. Locate shared library
36481         through the name pattern in library_names_spec.
36482
36483 2007-01-01  Eric Blake  <ebb9@byu.net>
36484
36485         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
36486
36487 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
36488
36489         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
36490         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
36491         assume the C locale, and avoid an "eval" that could cause trouble.
36492         Problem with SORT reported by Bob Proulx.
36493
36494         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
36495         Define.  Trivial patch from Henning Nielsen Lund, originally
36496         sent to bug-grep@gnu.org today.
36497
36498 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
36499
36500         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
36501         struct stat.  Problem reported by Henning Nielsen Lund.
36502         * lib/acl.c: Include acl.h first, to check interface.  Don't
36503         bother to include sys/types.h and sys/stat.h again.
36504
36505 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
36506
36507         Import the following change from libc; problem reported by
36508         Sven Verdoolaege.
36509
36510         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
36511
36512         [BZ #1373]
36513         * lib/argp.h: Remove __NTH for __argp_usage inline function.
36514
36515 2006-12-28  Jim Meyering  <jim@meyering.net>
36516
36517         * build-aux/announce-gen: Do not assume that the package
36518         builds any of tar.gz, tar.bz2, and .xdelta files.
36519         Suggestion from Simon Josefsson.
36520
36521 2006-12-28  Simon Josefsson  <simon@josefsson.org>
36522
36523         * modules/announce-gen: New file.
36524
36525 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
36526
36527         * lib/mbchar.h: Just include <wctype.h>; the wctype module
36528         handles its gotchas now.
36529         * lib/mbswidth.c: Likewise.
36530         * lib/wcwidth.h: Likewise.
36531         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
36532         and iswcntrl; the wctype module does this stuff now.
36533         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
36534         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
36535         * modules/mbchar (Depends-on): Add wctype.
36536         * modules/mbswidth (Depends-on): Likewise.
36537         * modules/wcwidth (Depends-on): Likewise.
36538
36539 2006-12-27  Eric Blake  <ebb9@byu.net>
36540
36541         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
36542         module uses more than what <wctype.h> is required to provide.
36543
36544 2006-12-26  Eric Blake  <ebb9@byu.net>
36545
36546         * gnulib-tool (sed_extract_prog): Avoid space-tab.
36547
36548 2006-12-26  Eric Blake  <ebb9@byu.net>
36549
36550         * modules/absolute-header: New module.
36551         * modules/fcntl (Depends-on): Depend on it.
36552         * modules/inttypes (Depends-on): Likewise.
36553         * modules/stdint (Depends-on): Likewise.
36554         * modules/sys_stat (Depends-on): Likewise.
36555         * modules/wctype (Depends-on): Likewise.
36556         * MODULES.html.sh (Support for building libraries and
36557         executables): Document it.
36558
36559 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
36560
36561         * gnulib-tool (SED): Remove, undoing previous change.
36562         The problem was that it broke coreutils on Solaris, because
36563         "sed --posix" leaked into a makefile.
36564         (sed): New alias, if 'alias' and GNU sed.
36565
36566 2006-12-24  Jim Meyering  <jim@meyering.net>
36567
36568         Work around an fchownat bug in glibc-2.4:
36569         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
36570         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
36571         in spite of the -P option.
36572         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
36573         New macros.
36574         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
36575         * modules/openat (Files): Add lib/fchownat.c.
36576         * lib/openat.c (fchownat): Don't define here.  Move to...
36577         * lib/fchownat.c: ...this new file.
36578
36579 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
36580
36581         Fix bug reported by Bruno Haible in
36582         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
36583         where quotearg.c didn't compile on Mac OS X 10.2 because it
36584         lacks <wchar.h> and wint_t.
36585         * lib/wctype_.h (__wctype_wint_t): New type.
36586         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
36587         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
36588         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
36589         Arg is now of type __wctype_wint_t, not wint_t.
36590         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
36591         substitute HAVE_WINT_T.
36592         * modules/wctype (Files): Add m4/wint_t.m4.
36593         (wctype.h): Substitute HAVE_WINT_T.
36594
36595 2006-12-23  Bruno Haible  <bruno@clisp.org>
36596
36597         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
36598
36599 2006-12-23  Bruno Haible  <bruno@clisp.org>
36600
36601         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
36602         S_ISLNK.
36603         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
36604         mingw.
36605
36606 2006-12-22  Bruno Haible  <bruno@clisp.org>
36607
36608         * lib/copy-file.c: Include acl.h.
36609         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
36610         Close the file descriptors only after being done with copy_acl.
36611         * modules/copy-file (Depends-on): Add acl.
36612
36613 2006-12-22  Bruno Haible  <bruno@clisp.org>
36614
36615         * gnulib-tool (SED): New variable.
36616         Use $SED instead of sed everywhere.
36617
36618 2006-12-22  Bruno Haible  <bruno@clisp.org>
36619
36620         * modules/no-c++: New file.
36621         * m4/no-c++.m4: New file.
36622         * MODULES.html.sh (Support for building libraries and executables):
36623         Add no-c++.
36624
36625 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
36626
36627         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
36628         Include <limits.h>, and use its INT_MAX to rewrite the
36629         j loop so that it does not overflow 'int'.  Problem reported by
36630         Ralf Wildenhues in
36631         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
36632         Play it safe by shifting left by 1 rather than multiplying by 2,
36633         as GCC is less likely to optimize this away when the value
36634         is signed (when it assumes overflow leads to undefined behavior).
36635         Also, don't assume time_t uses two's complement.
36636
36637 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
36638
36639         * MODULES.html.sh: New module wctype.
36640         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
36641         * lib/fnmatch.c: Don't bother to include <wchar.h> before
36642         <wctype.h>, since the new wctype module should fix this.
36643         * lib/quotearg.c: Include <wctype.h> unconditionally, since
36644         the wctype module should arrange for it.
36645         * lib/regex_internal.h: Likewise.
36646         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
36647         since the wctype module should handle this now.
36648         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
36649         * modules/fnmatch (Depends-on): Add wctype.
36650         * modules/quotearg (Depends-on): Likewise.
36651         * modules/regex (Depends-on): Likewise.
36652
36653 2006-12-19  Bruno Haible  <bruno@clisp.org>
36654
36655         * lib/strdup.h [C++]: Wrap definitions in extern "C".
36656         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
36657
36658 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
36659
36660         * modules/savewd (Depends-on): Fix dependency on fcntl.
36661
36662 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
36663
36664         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
36665         conforms to C99, rather than relying on the user's environment
36666         setting of STDINT_H.
36667
36668 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
36669         and Eric Blake  <ebb9@byu.net>
36670
36671         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
36672         This is more consistent with the other defines here.
36673         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
36674         Port to z/OS.  Problem reported by Paul Gilmartin.
36675         Change local vars to use gl_ prefix rather than ac_.
36676         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
36677         with other defines.
36678         * modules/double-slash-root: New module.
36679         * modules/dirname (Files): Remove m4/double-slash-root.m4.
36680         (Depends-on): Add double-slash-root.
36681         * MODULES.html.sh (File system functions): Mention new module.
36682
36683 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
36684
36685         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
36686         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
36687         This is for the benefit of gzip, which doesn't do i18n.
36688
36689 2006-12-12  Jim Meyering  <jim@meyering.net>
36690
36691         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
36692         Reported by Andreas Schwab <schwab@suse.de>.
36693
36694 2006-12-12  Bruno Haible  <bruno@clisp.org>
36695
36696         Merge these changes.
36697         2006-09-05  Bruno Haible  <bruno@clisp.org>
36698         * lib/iconvme.c (iconv_string): No need to save and restore errno when
36699         iconv_alloc succeeded.
36700         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
36701         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
36702         test for " && dest " at the end - dest is always != NULL there. Call
36703         iconv with 4xNULL arguments initially, to reset the state. Call iconv
36704         with 2xNULL arguments, also to flush the state storage. Handle the
36705         IRIX iconv behaviour. Realloc the final result, to throw away unused
36706         memory.
36707
36708 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
36709
36710         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
36711         and fchmodat unconditionally, since glibc 2.4 has them.
36712         Problem reported by Arkadiusz Miskiewicz.
36713
36714 2006-12-10  Bruno Haible  <bruno@clisp.org>
36715
36716         * gnulib-tool (func_import): Show the include files only for those
36717         modules that are copied and specified.
36718         Reported by Karl Berry.
36719
36720 2006-12-08  Jim Meyering  <jim@meyering.net>
36721
36722         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
36723         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
36724
36725         * build-aux/announce-gen: Add two new options, both optional:
36726         --bootstrap-tools=TOOL_LIST
36727               a comma-separated list of tools, e.g.,
36728               autoconf,automake,bison,gnulib
36729         --gnulib-snapshot-date=DATE
36730               if gnulib is in the bootstrap tool list,
36731               then report this as the snapshot date.
36732               If not specified, use the current date/time.
36733               If you specify a date here, be sure it's UTC.
36734
36735 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
36736
36737         * tests/test-argp-2.sh: Fix test to match actual output.
36738         (func_compare): Fix sed script to be portable.
36739
36740 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
36741
36742         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
36743         workaround for this case.  It is not autoconfigured now; offhand
36744         it's hard to see how to autoconfigure it.
36745
36746 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
36747
36748         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
36749         a directory that is about to be chowned.  Such a directory's
36750         initial file permissions should permit the owner only and this
36751         should not be changed until after the chown, since the group and
36752         other bits would be incorrect if they granted permission before
36753         the chown.
36754
36755         Fix porting problem for iswctype reported by Georg Schwarz in:
36756         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
36757         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
36758         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
36759         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
36760         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
36761
36762 2006-12-03  Jim Meyering  <jim@meyering.net>
36763
36764         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
36765         p->fts_statp may not yet be defined.
36766         (fts_read): Instead, set it in the caller, once p->fts_statp is
36767         sure to be defined, and corresponds to a top-level directory.
36768         This bug made du -x fail.  Here's the coreutils test case:
36769         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
36770         Reported by Mike Frysinger.
36771
36772 2006-12-01  Jim Meyering  <jim@meyering.net>
36773
36774         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
36775         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
36776         Reported by Simon Josefsson.
36777
36778 2006-11-30  Jim Meyering  <jim@meyering.net>
36779
36780         * m4/warning.m4: Use the all-permissive copyright notice
36781         recommended by RMS (rather than LGPL).
36782         * m4/vararrays.m4: Likewise.
36783         * m4/flexmember.m4: Likewise.
36784
36785 2006-11-29  Bruno Haible  <bruno@clisp.org>
36786
36787         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
36788         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
36789         using +=.
36790         Reported by Simon Josefsson <simon@josefsson.org>.
36791
36792 2006-11-28  James Youngman <jay@gnu.org>
36793
36794         * README: Advise users that they might find the bug-gnulib@gnu.org
36795         and autotools-announce@gnu.org mailing lists useful.
36796
36797 2006-11-28  Bruno Haible  <bruno@clisp.org>
36798
36799         * m4/ptrdiff_max.m4: Remove file.
36800
36801 2006-11-21  Bruno Haible  <bruno@clisp.org>
36802
36803         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
36804         _AC_COMPUTE_INT.
36805         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
36806         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
36807         _AC_COMPUTE_INT.
36808         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
36809         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
36810         _AC_COMPUTE_INT.
36811         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
36812
36813 2006-11-28  Jim Meyering  <jim@meyering.net>
36814
36815         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
36816         warning from "gcc -Wshadow" about shadowing the builtin.
36817
36818 2006-11-27  Bruno Haible  <bruno@clisp.org>
36819
36820         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
36821         _AC_COMPUTE_INT.
36822         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
36823
36824 2006-11-27  Bruno Haible  <bruno@clisp.org>
36825             Paul Eggert  <eggert@cs.ucla.edu>
36826
36827         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
36828
36829 2006-11-26  Bruno Haible  <bruno@clisp.org>
36830
36831         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
36832         noinst_LTLIBRARIES.
36833
36834 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
36835             Bruno Haible  <bruno@clisp.org>
36836
36837         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
36838         if compiling with "gcc -ansi".
36839
36840 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
36841
36842         Fix some incompatibilities with gcc -ansi -pedantic.
36843         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
36844         if compiling pedantically with GCC, unless it's C99 or later.
36845         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
36846         it mishandles gcc -ansi -pedantic as well.
36847         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
36848         if gcc -pedantic.
36849         * lib/regexec.c (check_node_accept_bytes): Don't use auto
36850         initializers for struct if -pedantic, unless it's C99 or later.
36851
36852 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
36853
36854         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
36855         Don't close an fd more than once. Identical atimes indicate
36856         success, not failure.
36857
36858 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
36859
36860         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
36861
36862 2006-11-23  Jim Meyering  <jim@meyering.net>
36863
36864         * build-aux/announce-gen: New file.  From coreutils.
36865
36866 2006-11-22  Jim Meyering  <jim@meyering.net>
36867
36868         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
36869         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
36870         (fts_read): Use a temporary to narrow the overused st_size member
36871         before using it in a switch statement.  Reported by Matthew Woehlke.
36872
36873         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
36874         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
36875
36876 2006-11-20  Bruno Haible  <bruno@clisp.org>
36877
36878         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
36879         changequote instead of pairs of brackets.
36880         Reported by Andreas Schwab <schwab@suse.de>.
36881
36882 2006-11-21  Jim Meyering  <jim@meyering.net>
36883
36884         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
36885         so as to remain compatible with older compilers.
36886         Patch from Michael Deutschmann.
36887
36888 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
36889
36890         * MODULES.html.sh (File system functions): Add openat.
36891
36892         * lib/openat.h (rpl_fstatat): New macro, if
36893         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
36894         (fstatat): Define to rpl_fstatat under the same conditions,
36895         unless COMPILING_FSTATAT.
36896         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
36897         seems to have the bug.
36898         * lib/fstatat.c: New file.
36899         * modules/openat (Files): Add it.
36900
36901 2006-11-20  Bruno Haible  <bruno@clisp.org>
36902
36903         * Makefile: New file.
36904
36905 2006-11-20  Jim Meyering  <jim@meyering.net>
36906
36907         The beginnings of syntax-related checks for gnulib.
36908         * lib/Makefile: New file.
36909         * lib/t-idcache: New script.  Ensure that the two halves of
36910         idcache.c stay in sync.
36911
36912         * lib/idcache.c: Adjust comments in user- and group- portions to
36913         be more accurate, and to be consistent with one another.
36914
36915 2006-11-20  Jim Meyering  <jim@meyering.net>
36916
36917         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
36918         continue using the flexible array member (thus, this module performs
36919         half as many malloc calls), with the addition that...
36920         (getgroup, getuser): Consistently record a non-match via an empty
36921         "name" string, and map an empty string match to a NULL return value.
36922         * modules/idcache (Depends-on): Re-add flexmember.
36923
36924         * lib/idcache.c (getuser): Remove all uses of the register keyword.
36925         (getuidbyname, getgroup, getgidbyname): Likewise.
36926
36927         Use cleaner syntax: NULL rather than 0.
36928         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
36929
36930 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
36931
36932         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
36933         It mishandled the case where the group was missing.
36934         Problem reported by Greg Schafer.
36935         * modules/idcache: Likewise.
36936
36937 2006-11-18  Jim Meyering  <jim@meyering.net>
36938
36939         * check-module (%exempt_header): Add exception for some
36940         conditionally-included headers.
36941
36942         * modules/i-ring (Depends-on): Add verify.
36943         (License): Change to LGPL.
36944
36945 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
36946
36947         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
36948         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
36949         and inttostr.h.  Use snprintf rather than uinttostr, so that
36950         LGPLed code doesn't depend on GPLed.
36951
36952 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
36953
36954         * modules/inline (License): Change from GPL to LGPL.
36955
36956 2006-11-17  Jim Meyering  <jim@meyering.net>
36957
36958         * modules/d-type (License): Switch to LGPL.
36959
36960 2006-11-15  Bruno Haible  <bruno@clisp.org>
36961
36962         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
36963
36964 2006-11-15  Eric Blake  <ebb9@byu.net>
36965
36966         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
36967         the module dependency.
36968
36969 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
36970             Bruno Haible  <bruno@clisp.org>
36971
36972         * gnulib-tool (func_create_testdir): Add license consistency check.
36973
36974 2006-11-15  Eric Blake  <ebb9@byu.net>
36975
36976         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
36977         random "(cached)" in configure output.
36978
36979 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
36980
36981         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
36982         test for conforming inttypes.h is both announced and cached.
36983
36984         * MODULES.html.sh (seen_modules, seen_files): New variables.
36985         (func_module): Rewrite to use a few less gnulib-tool and sed
36986         invocations.  Avoid a couple of quadratic algorithms for ...
36987         (missed_modules, missed_files): ... these, with ...
36988         (func_append, func_tmpdir): ... these new functions, from
36989         gnulib-tool.  Analogously, install traps for cleanup.
36990
36991         * tests/test-gc.c (main): Remove unused variables.
36992         * tests/test-read-file.c: Include stdlib.h, for 'free'.
36993
36994 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
36995
36996         * modules/inttostr (License): Change to LGPL.
36997
36998 2006-11-14  Eric Blake  <ebb9@byu.net>
36999
37000         * modules/tempname (License): Change to LGPL.
37001
37002 2006-11-14  Eric Blake  <ebb9@byu.net>
37003
37004         * doc/functions.texi (Function Portability): *printf functions on
37005         Cygwin now understand all POSIX size specifiers.
37006
37007 2006-11-14  Bruno Haible  <bruno@clisp.org>
37008
37009         * modules/c-ctype (License): Change to LGPL.
37010
37011 2006-11-12  Bruno Haible  <bruno@clisp.org>
37012
37013         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
37014         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
37015         for GNOME libraries, for which the include files are installed in
37016         subdirectories of $prefix/include.
37017
37018 2006-11-12  Bruno Haible  <bruno@clisp.org>
37019
37020         * m4/lib-link.m4: Require at least autoconf-2.54.
37021         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
37022         name to underscores for the --with option.
37023
37024 2006-11-13  Bruno Haible  <bruno@clisp.org>
37025
37026         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
37027         the tests directory.
37028         Reported by Ralf Wildenhues.
37029
37030 2006-11-13  Bruno Haible  <bruno@clisp.org>
37031
37032         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
37033         (func_emit_initmacro_end): Undo the override here.
37034         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
37035         Works around the famous automake error in coreutils.
37036
37037 2006-11-13  Eric Blake  <ebb9@byu.net>
37038
37039         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
37040         element, not its node.
37041
37042 2006-11-12  Bruno Haible  <bruno@clisp.org>
37043
37044         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
37045         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
37046
37047 2006-11-12  Bruno Haible  <bruno@clisp.org>
37048
37049         * gnulib-tool: New option --local-symlink.
37050         (func_usage): Document it.
37051         (lsymbolic): New variable.
37052         (func_import, func_create_testdir): If --symlink was not specified,
37053         test whether --local-symlink was specified and the file comes from
37054         the local_gnulib_dir.
37055
37056 2006-11-12  Bruno Haible  <bruno@clisp.org>
37057
37058         * gnulib-tool (func_ln): New function.
37059         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
37060
37061 2006-11-12  Bruno Haible  <bruno@clisp.org>
37062
37063         Finish support for source files in subdirectories.
37064         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
37065         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
37066         AUTOMAKE_OPTIONS.
37067         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
37068
37069 2006-11-12  Bruno Haible  <bruno@clisp.org>
37070
37071         * gnulib-tool (func_get_automake_snippet): Synthesize also an
37072         EXTRA_lib_SOURCES augmentation.
37073         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
37074
37075 2006-11-12  Jim Meyering  <jim@meyering.net>
37076
37077         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
37078         file descriptors.  This also averts a failure on systems with
37079         native openat support when a traversed directory lacks "x" access.
37080         * lib/fts_.h: Include "i-ring.h"
37081         (struct FTS) [fts_fd_ring]: New member.
37082         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
37083         (FCHDIR): Add parentheses.
37084         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
37085         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
37086         When descending, rather than simply closing the previous
37087         fts_cwd_fd value, push that file descriptor onto the ring.
37088         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
37089         (fts_open): Initialize the new fd_ring member.
37090         (fts_close): Clear the ring.
37091         (fts_safe_changedir): When possible, use our new fd_ring to skip
37092         the diropen and fstat and dev/ino comparison that would normally
37093         accompany a virtual `chdir ("..")'.
37094
37095         * modules/fts (Depends-on): Add i-ring.
37096         * modules/i-ring: New module.
37097         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
37098         * m4/i-ring.m4: New file.
37099
37100 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
37101
37102         * gnulib-tool (func_create_testdir): Fix replacement of
37103         `build-aux' in configure.ac.  Run autotools in gltests
37104         subdirectory.
37105         (func_create_testdir, func_create_megatestdir, test): There is
37106         no need for '--force' in most autotool invocations in a new
37107         tree.  Actually fail the whole test if any of the tools, or the
37108         configure or make stages fail.
37109
37110         Sync from Automake.
37111         * build-aux/gnupload: Revert last change.  Add pointer to upload
37112         instructions of the GNU Maintenance Instructions.
37113         Suggestion by Karl Berry.
37114
37115 2006-11-10  Jim Meyering  <jim@meyering.net>
37116
37117         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
37118
37119 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
37120
37121         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
37122         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
37123         (bind_textdomain_codeset) [! ENABLE_NLS]:
37124         Evaluate all the arguments.  That way, callers get compatible behavior
37125         if the arguments have side effects.  Also, it avoids some GCC
37126         diagnostics in some cases; Joel E. Denny reported problems when Bison
37127         was configured with --enable-gcc-warnigs.
37128
37129 2006-11-10  Jim Meyering  <jim@meyering.net>
37130
37131         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
37132         relevant options in CFLAGS (like -O, -fno-inline) are taken into
37133         account.
37134
37135 2006-11-10  Jim Meyering  <jim@meyering.net>
37136
37137         * modules/inline: New file/module.
37138         * modules/xalloc (Files): Remove m4/inline.m4.
37139         (Depends-on): Add inline, instead.
37140         * modules/oset: Likewise.
37141         * modules/list: Likewise.
37142
37143 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
37144
37145         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
37146         Problem reported by Matthew Woehlke.
37147
37148 2006-11-09  Bruno Haible  <bruno@clisp.org>
37149
37150         * lib/tempname.c (gen_tempname): Remove variant that invokes
37151         __gen_tempname.
37152         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
37153         __gen_tempname.
37154
37155 2006-11-08  Bruno Haible  <bruno@clisp.org>
37156
37157         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
37158         to 'yes' instead of 'cross-compiling'.
37159
37160 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
37161
37162         * lib/quotearg.h (quotearg_free): New decl.
37163         * lib/quotearg.c (quotearg_free): New function.
37164         (slot0, nslots, slotvec0, slotvec):
37165         Now file-scope so that quotearg_free can get at them.
37166
37167 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
37168
37169         Sync from Automake.
37170         * build-aux/gnupload: Add missing 'gnu' to example URL.
37171         Report by Karl Berry.
37172
37173 2006-11-08  Bruno Haible  <bruno@clisp.org>
37174
37175         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
37176         Suggested by Paul Eggert.
37177
37178 2006-11-08  Jim Meyering  <jim@meyering.net>
37179
37180         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
37181         It's already included if !_LIBC.
37182         (fts_safe_changedir): Add a comment.
37183
37184 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
37185
37186         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
37187         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
37188         Matthew Woehlke.
37189
37190         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
37191         definitions up, to avoid colliding with change below.
37192         (static_inline) [HAVE_INLINE]: New macro.
37193         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
37194         Provide extern decls when !HAVE_INLINE.  Do not define unless
37195         static_inline is defined, either by us or by xmalloc.c.  Use
37196         static_inline rather than static inline.
37197         (XCALLOC): Optimize sizeof(T) = 1 case.
37198         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
37199
37200 2006-11-07  Bruno Haible  <bruno@clisp.org>
37201
37202         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
37203         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
37204         AC_C_INLINE.
37205         * modules/xalloc (Files): Add m4/inline.m4.
37206
37207 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
37208
37209         * README: Fix typo.
37210         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
37211         (Miscellanous Notes): ...from this.
37212
37213 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
37214
37215         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
37216         Mention that offsetof should be used instead of sizeof.
37217         From Bruno Haible.
37218
37219 2006-11-07  Bruno Haible  <bruno@clisp.org>
37220
37221         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
37222
37223 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
37224
37225         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
37226         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
37227         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
37228         (gl_tree_add_before, gl_tree_add_after):
37229         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
37230         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
37231         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
37232         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
37233         (gl_linked_add_after, gl_linked_add_at): Likewise.
37234         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
37235         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
37236         (gl_tree_add_before, gl_tree_add_after): Likewise.
37237         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
37238         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
37239         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
37240
37241 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
37242
37243         * lib/gl_oset.h: Use C comment style, not C++ comment style.
37244
37245 2006-11-06  Bruno Haible  <bruno@clisp.org>
37246
37247         * m4/inline.m4: New file.
37248         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
37249         * modules/list (Files): Add m4/inline.m4.
37250         * modules/oset (Files): Likewise.
37251
37252 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
37253
37254         * lib/idcache.c: Include <stddef.h>, for offsetof.
37255         (struct userid.name): Change from char * to a flexible array member.
37256         All uses changed.
37257         * modules/idcache (Depends-on): Add flexmember.
37258
37259         * MODULES.html.sh (Core language properties): New module flexmember.
37260         * modules/flexmember, m4/flexmember.m4: New files.
37261
37262         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
37263         inline functions that are identical with the old xnmalloc_inline,
37264         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
37265         that we can avoid some unnecessary integer multiplications and
37266         divisions in the common case where the element size is known at
37267         compile time.
37268         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
37269         needed.
37270         (xnboundedmalloc): Remove.
37271         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
37272         arguments, for consistency with rest of this header.
37273         (xcharalloc): Rewrite using XNMALLOC.
37274         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
37275         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
37276         versions have been moved to lib/xalloc.h and renamed to be the
37277         non-*_inline versions.
37278         (xmalloc, xrealloc): Implement without reference to the xnmalloc
37279         and xnrealloc functions, since those functions are now inline and
37280         now call us.
37281         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
37282         renaming described above.
37283         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
37284         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
37285         captures the dependency in AC_C_INLINE.
37286
37287         New module canonicalize-lgpl, proposed by Charles Wilson in
37288         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
37289         with a few small changes afterwards.
37290         * MODULES.html.sh (File system functions): New module
37291         canonicalize-lgpl.
37292         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
37293         and canonicalize_file_name.
37294         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
37295         * modules/canonicalize-lgpl: New files.
37296
37297 2006-11-05  Bruno Haible  <bruno@clisp.org>
37298
37299         * gnulib-tool (func_import, func_create_testdir): Create directories
37300         also for files in subdirectories of lib/.
37301
37302 2006-11-05  Bruno Haible  <bruno@clisp.org>
37303
37304         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
37305         ANSI C compliant.
37306
37307 2006-11-03  Bruno Haible  <bruno@clisp.org>
37308
37309         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
37310         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
37311         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
37312         (xnboundedmalloc): New inline function.
37313         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
37314         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
37315         xmalloc.
37316         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
37317         xmalloc.
37318         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
37319         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
37320         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
37321         xmalloc.
37322         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
37323         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
37324         xmalloc.
37325         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
37326         gl_tree_add_after): Use XMALLOC instead of xmalloc.
37327         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
37328         xmalloc.
37329         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
37330         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
37331         gl_tree_add_after): Use XMALLOC instead of xmalloc.
37332         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
37333         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
37334         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
37335         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
37336
37337 2006-11-03  Bruno Haible  <bruno@clisp.org>
37338
37339         * lib/c-ctype.h [C++]: Define functions without name mangling.
37340         * lib/fwriteerror.h [C++]: Likewise.
37341         * lib/gcd.h [C++]: Likewise.
37342         * lib/linebreak.h [C++]: Likewise.
37343
37344 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
37345
37346         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
37347         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
37348         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
37349         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
37350         Check for functions and headers just once.
37351         Check for declaration of canonicalize_file_name.
37352         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
37353
37354 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
37355
37356         * gnulib-tool (func_import): Fix typo in actioncmd.
37357
37358 2006-11-02  Bruno Haible  <bruno@clisp.org>
37359
37360         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
37361         newline sequence in the Makefile.am snippet as a space, like "make"
37362         does.
37363         Reported by Roger Persson <perrog@gmail.com>.
37364
37365 2006-11-01  Bruno Haible  <bruno@clisp.org>
37366
37367         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
37368         already declared in <string.h>.
37369         * lib/strcase.h (strncasecmp): Don't declare it if yes.
37370
37371 2006-11-01  Bruno Haible  <bruno@clisp.org>
37372
37373         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
37374         * lib/strcase.h: Include <string.h>.
37375         (strcasecmp): Define to rpl_strcasecmp here.
37376
37377 2006-11-01  Bruno Haible  <bruno@clisp.org>
37378
37379         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
37380
37381 2006-11-01  Eric Blake  <ebb9@byu.net>
37382
37383         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
37384
37385         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
37386
37387 2006-10-29  Bruno Haible  <bruno@clisp.org>
37388
37389         Make it compile in C++ mode.
37390         * lib/full-write.c (full_rw): Add a cast.
37391
37392 2006-11-01  Bruno Haible  <bruno@clisp.org>
37393
37394         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
37395         be POSIX compliant.
37396         Reported by Roger Persson <perrog@gmail.com>.
37397
37398 2006-11-01  Eric Blake  <ebb9@byu.net>
37399
37400         * lib/getopt_.h: Fix comments.
37401
37402 2006-10-31  Eric Blake  <ebb9@byu.net>
37403
37404         * modules/tmpdir (Depends-on): Add sys_stat.
37405         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
37406         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
37407         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
37408         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
37409         tempname.
37410
37411 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
37412
37413         Avoid some C++ diagnostics reported by Bruno Haible.
37414         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
37415         xmalloc.
37416         (quotearg_alloc): Use xcharalloc rather than xmalloc.
37417         (struct slotvec): Move to top level.
37418         (quotearg_n_options): Rewrite to avoid xmalloc.
37419         * lib/xalloc.h (xcharalloc): New function.
37420         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
37421         [defined __cplusplus]: Add function template that provides result
37422         type propagation.  This part of the change is from Bruno Haible.
37423
37424 2006-10-29  Bruno Haible  <bruno@clisp.org>
37425
37426         Make it compile in C++ mode.
37427         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
37428         * lib/strnlen1.c (strnlen1): Cast memchr result.
37429         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
37430         * lib/clean-temp.c (string_equals, string_hash): Add casts.
37431         (create_temp_dir): Rename local variable 'template'.
37432         (compile_csharp_using_sscli): Add cast.
37433         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
37434         * lib/findprog.c (find_in_path): Likewise.
37435         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
37436         * lib/wait-process.c (register_slave_subprocess): Likewise.
37437
37438 2006-10-22  Bruno Haible  <bruno@clisp.org>
37439
37440         * modules/tsearch: New file.
37441         * lib/tsearch.h: New file.
37442         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
37443         * m4/tsearch.m4: New file.
37444         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
37445
37446 2006-10-29  Eric Blake  <ebb9@byu.net>
37447
37448         * lib/arcfour.c: Assume config.h.
37449         * lib/arctwo.c: Likewise.
37450         * lib/base64.c: Likewise.
37451         * lib/check-version.c: Likewise.
37452         * lib/crc.c: Likewise.
37453         * lib/des.c: Likewise.
37454         * lib/gc-gnulib.c: Likewise.
37455         * lib/gc-libgcrypt.c: Likewise.
37456         * lib/gc-pbkdf2-sha1.c: Likewise.
37457         * lib/getaddrinfo.c: Likewise.
37458         * lib/getdelim.c: Likewise.
37459         * lib/getline.c: Likewise.
37460         * lib/hmac-md5.c: Likewise.
37461         * lib/hmac-sha1.c: Likewise.
37462         * lib/iconvme.c: Likewise.
37463         * lib/md2.c: Likewise.
37464         * lib/md4.c: Likewise.
37465         * lib/memxor.c: Likewise.
37466         * lib/read-file.c: Likewise.
37467         * lib/readline.c: Likewise.
37468         * lib/rijndael-alg-fst.c: Likewise.
37469         * lib/rijndael-api-fst.c: Likewise.
37470         * lib/xgetdomainname.c: Likewise.
37471
37472 2006-10-28  Eric Blake  <ebb9@byu.net>
37473
37474         * lib/xstrndup.c: Assume config.h.
37475
37476 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
37477
37478         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
37479         stat-macros.h is now for our own macros, whereas stat_h is for
37480         macros in the <sys/stat.h> name space.
37481         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
37482         (STAT_MACROS_H): Remove.
37483         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
37484         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
37485         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
37486         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
37487         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
37488         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
37489         Move these macros to ...
37490         * lib/stat_.h: here.  Don't include stat-macros.h.
37491         * lib/canonicalize.c: Don't include stat-macros.h.
37492         * lib/chown.c: Likewise.
37493         * lib/euidaccess.c: Likewise.
37494         * lib/file-type.c: Likewise.
37495         * lib/filemode.c: Likewise.
37496         * lib/glob.c: Likewise.
37497         * lib/isapipe.c: Likewise.
37498         * lib/lchown.c: Likewise.
37499         * lib/lstat.c: Likewise.
37500         * lib/mkdir-p.c: Likewise.
37501         * lib/rmdir.c: Likewise.
37502         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
37503         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
37504         unless mkdir isn't declared, to speed up 'configure'.
37505         Always create sys/stat.h, since it's unlikely any real sys/stat.h
37506         would define all the S_* symbols.
37507         * modules/canonicalize (Depends-on):
37508         Depend on sys_stat, not stat-macros.
37509         * modules/chown: Likewise.
37510         * modules/euidaccess: Likewise.
37511         * modules/filemode: Likewise.
37512         * modules/file-type: Likewise.
37513         * modules/glob: Likewise.
37514         * modules/isapipe: Likewise.
37515         * modules/lchown: Likewise.
37516         * modules/lstat: Likewise.
37517         * modules/mkancesdirs: Likewise.
37518         * modules/rmdir: Likewise.
37519         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
37520         * modules/modechange: Likewise.
37521         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
37522         (configure.ac): Remove gl_STAT_MACROS.
37523         * modules/sys_stat (Depends-on): Remove stat-macros.
37524
37525 2006-10-27  Bruno Haible  <bruno@clisp.org>
37526
37527         * m4/signed.m4: Remove file.
37528         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
37529         invocation.
37530         * modules/vasnprintf (Files): Remove m4/signed.m4.
37531
37532 2006-10-27  Bruno Haible  <bruno@clisp.org>
37533
37534         Update to GNU gettext 0.16.
37535         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
37536         m4/inttypes-h.m4, m4/signed.m4.
37537         * m4/gettext.m4: Update to GNU gettext 0.16.
37538         * m4/intl.m4: New file, from GNU gettext.
37539         * m4/intldir.m4: New file, from GNU gettext.
37540         * config/srclist.txt: Update
37541
37542 2006-10-27  Eric Blake  <ebb9@byu.net>
37543
37544         * MODULES.html.sh: Document tempname.
37545         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
37546         dependencies.
37547         (Files): Move lib/tempname.c...
37548         * modules/tempname: ...to this new module.
37549         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
37550         (gl_PREREQ_TEMPNAME): Move...
37551         * m4/tempname.m4: ...to this new file.
37552         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
37553         * modules/sys_stat (Depends-on): Add stat-macros.
37554         * lib/stat_.h (includes): Pick up stat macros.
37555         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
37556         if stat macros are broken.
37557         * lib/tempname.c (includes): No need to include "stat-macros.h".
37558         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
37559         (direxists, __path_search) [!_LIBC]: Don't compile these in
37560         gnulib; the tmpdir module covers that.
37561         * lib/tempname.h: New file.
37562
37563 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
37564
37565         * COPYING: Explain how gnulib-tool converts licence headers.
37566         Almost all wording by Eric Blake.
37567
37568 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
37569
37570         * lib/mbchar.h (is_basic_table): Make read-only.
37571         * lib/mbchar.c (is_basic_table): Likewise.
37572         Reported by John Darrington.
37573
37574 2006-10-25  Bruno Haible  <bruno@clisp.org>
37575
37576         * lib/progname.h (set_program_name): Undefine before defining.
37577
37578 2006-10-25  Bruno Haible  <bruno@clisp.org>
37579
37580         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
37581         false for non-gcc C++ compilers.
37582         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
37583
37584 2006-10-24  Bruno Haible  <bruno@clisp.org>
37585
37586         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
37587         iconv implementations like Irix iconv.
37588
37589 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
37590
37591         * modules/vararrays: New file.
37592         * m4/vararrays.m4: New file, taken from diffutils.
37593         * MODULES.html.sh: New module vararrays.
37594
37595 2006-10-24  Karl Berry  <karl@gnu.org>
37596
37597         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
37598         Don't call GNU Unix.
37599
37600 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
37601
37602         * users.txt: Add Libtool.
37603
37604         Sync from Libtool:
37605
37606         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
37607
37608         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
37609         to gnulib's policy of including config.h unconditionally.
37610
37611 2006-10-24  Bruno Haible  <bruno@clisp.org>
37612
37613         * modules/wcwidth (Files): Add m4/wint_t.m4.
37614         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
37615         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
37616
37617 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
37618
37619         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
37620         to pacify GCC with some -W flags enabled.  Problem reported by
37621         Bruno Haible.
37622
37623 2006-10-24  Jim Meyering  <jim@meyering.net>
37624
37625         * MODULES.html.sh: Remove uinttostr.  It's not a module.
37626         Reported by Karl Berry.
37627
37628 2006-10-23  Bruno Haible  <bruno@clisp.org>
37629
37630         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
37631
37632 2006-10-24  Bruno Haible  <bruno@clisp.org>
37633
37634         * lib/gl_list.h: Use C comment style, not C++ comment style.
37635
37636 2006-10-23  Eric Blake  <ebb9@byu.net>
37637
37638         * lib/getaddrinfo.c (includes): Add missing include.
37639
37640 2006-10-23  Bruno Haible  <bruno@clisp.org>
37641             Paul Eggert  <eggert@cs.ucla.edu>
37642
37643         Ability to rename obstack_free.
37644         * lib/obstack.h (__obstack_free): New macro. Declare instead of
37645         obstack_free.
37646         (obstack_free): Invoke the __obstack_free macro.
37647         * lib/obstack.c (obstack_free): Use __obstack_free macro.
37648
37649 2006-10-23  Bruno Haible  <bruno@clisp.org>
37650             Paul Eggert  <eggert@cs.ucla.edu>
37651
37652         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
37653         __argc, __argv from the declaration. (They are defined as macros on
37654         mingw.)
37655
37656 2006-10-22  Bruno Haible  <bruno@clisp.org>
37657
37658         * doc/gnulib-intro.texi: New file.
37659         * doc/gnulib.texi: Include it.
37660
37661 2006-10-21  Bruno Haible  <bruno@clisp.org>
37662
37663         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
37664         "Introduction", "Miscellanous Notes", "Particular Modules".
37665
37666 2006-10-21  Bruno Haible  <bruno@clisp.org>
37667
37668         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
37669         Change mostlyclean-local rule to avoid sh syntax error from bash
37670         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
37671
37672 2006-10-23  Jim Meyering  <jim@meyering.net>
37673
37674         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
37675         in place of snprintf.
37676
37677         * modules/inttostr (Files): Add lib/uinttostr.c.
37678         * lib/uinttostr.c (inttostr): New file/function.
37679         * lib/inttostr.h (uinttostr): Declare.
37680         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
37681         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
37682         Add uinttostr.
37683         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
37684
37685 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
37686
37687         * lib/canonicalize.c (ELOOP): Define if not already defined.
37688         Problem reported by Bruno Haible in
37689         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
37690
37691 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
37692
37693         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
37694         Problem reported by Perry Smith and Ville Laurikari.
37695
37696         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
37697         uses.
37698
37699 2006-10-19  Bruno Haible  <bruno@clisp.org>
37700
37701         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
37702         for mingw.
37703
37704 2006-10-19  Bruno Haible  <bruno@clisp.org>
37705
37706         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
37707         Needed for mingw.
37708
37709 2006-10-19  Bruno Haible  <bruno@clisp.org>
37710
37711         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
37712
37713 2006-10-19  Bruno Haible  <bruno@clisp.org>
37714
37715         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
37716         it.
37717
37718 2006-10-19  Bruno Haible  <bruno@clisp.org>
37719
37720         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
37721         invocation.
37722
37723 2006-10-19  Bruno Haible  <bruno@clisp.org>
37724
37725         * gnulib-tool (func_create_testdir): Don't include ftruncate and
37726         mountlist by default.
37727
37728 2006-10-16  Bruno Haible  <bruno@clisp.org>
37729
37730         * lib/c-strstr.c: Include c-strstr.h.
37731
37732 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
37733
37734         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
37735         in a slash.
37736
37737 2006-10-18  Bruno Haible  <bruno@clisp.org>
37738
37739         * lib/lock.h [C++]: Wrap definitions in extern "C".
37740
37741 2006-10-18  Bruno Haible  <bruno@clisp.org>
37742
37743         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
37744         gl_LIBOBJS list.
37745
37746 2006-10-18  Bruno Haible  <bruno@clisp.org>
37747
37748         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
37749
37750 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
37751
37752         * lib/xstrtol.h: Include gettext.h.
37753         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
37754         Problem reported by Eric Blake.
37755         * modules/xstrtol (Depends-on): Add gettext-h.
37756
37757 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
37758
37759         * lib/strftime.c (advance): New macro.
37760         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
37761         incomplete type, so you can't add 0 to it.  Problem and patch
37762         reported by Eelco Dolstra for dietlibc.
37763
37764 2006-10-18  Jim Meyering  <jim@meyering.net>
37765
37766         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
37767         type for a local, and rename it: s/up/user_proc/.
37768
37769 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
37770
37771         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
37772         READ_UTMP_USER_PROCESS.
37773         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
37774
37775 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
37776
37777         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
37778         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
37779
37780 2006-10-17  Eric Blake  <ebb9@byu.net>
37781
37782         * lib/sigprocmask.c (sigprocmask): Fix typo.
37783
37784         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
37785
37786         * modules/clean-temp (Makefile.am): Don't add to make output...
37787         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
37788         config.h.
37789
37790 2006-10-17  Bruno Haible  <bruno@clisp.org>
37791
37792         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
37793         differently if DEFAULT_TEXT_DOMAIN is set.
37794
37795 2006-10-16  Bruno Haible  <bruno@clisp.org>
37796
37797         * lib/clean-temp.c: Include fwriteerror.h.
37798
37799 2006-10-16  Bruno Haible  <bruno@clisp.org>
37800
37801         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
37802
37803 2006-10-16  Bruno Haible  <bruno@clisp.org>
37804
37805         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
37806         * lib/sigprocmask.h: Include <sys/types.h>.
37807         (sigset_t): Use the system's definition if present.
37808
37809 2006-10-17  Eric Blake  <ebb9@byu.net>
37810
37811         * lib/xvasprintf.c (includes): Assume config.h.
37812         * lib/xasprintf.c (includes): Likewise.
37813
37814 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
37815
37816         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
37817         at least as wide as intmax_t.
37818
37819 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
37820
37821         (Imported from Automake.)
37822         * build-aux/gnupload: Update to version 1.1 of directive file.
37823
37824 2006-10-16  Eric Blake  <ebb9@byu.net>
37825
37826         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
37827         match Automake 1.10a.
37828
37829 2006-10-14  Bruno Haible  <bruno@clisp.org>
37830
37831         * modules/sigprocmask: New file.
37832         * lib/sigprocmask.h: New file.
37833         * lib/sigprocmask.c: New file.
37834         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
37835         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
37836         request sigprocmask.o.
37837         (gl_PREREQ_SIGPROCMASK): New macro.
37838         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
37839         (Depends-on): Add sigprocmask.
37840         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
37841         gt_SIGNALBLOCKING. Test for 'raise' only once.
37842         * lib/fatal-signal.c: Include sigprocmask.h.
37843         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
37844         unblock_fatal_signals): Define always.
37845         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
37846         sigprocmask.
37847
37848 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
37849
37850         Sync from Automake.
37851         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
37852         which incorrectly sets the mode of an existing destination
37853         directory.  In some cases the unpatched install-sh could do the
37854         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
37855         system.  We hope this is rare in practice, but it's clearly worth
37856         fixing.  Problem reported by Alex Unleashed in
37857         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
37858         Also, don't bother to check for -m bugs unless we're using -m;
37859         suggested by Stepan Kasal.
37860
37861 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
37862
37863         Sync from Automake.
37864         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
37865         `-c' flag, so they appear at the same position as in %FASTDEP%
37866         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
37867         which ignores unknown options only after the first non-option.
37868         Bug report against M4 by Nelson H. F. Beebe.
37869
37870 2006-10-13  Jim Meyering  <jim@meyering.net>
37871
37872         Fix a bug in yesterday's change.
37873         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
37874         p->fts_statp->st_dev would be used uninitialized.
37875         Ensures that we always call fts_stat on the very first entry.
37876         Miklos Szeredi reported that find -xdev stopped working.
37877
37878 2006-10-12  Bruno Haible  <bruno@clisp.org>
37879
37880         * gnulib-tool (func_get_automake_snippet): Append an automatically
37881         computed EXTRA_DIST augmentation.
37882         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
37883         * modules/alloca-opt (Makefile.am): Likewise.
37884         * modules/allocsa (Makefile.am): Likewise.
37885         * modules/arcfour (Makefile.am): Likewise.
37886         * modules/arctwo (Makefile.am): Likewise.
37887         * modules/argmatch (Makefile.am): Likewise.
37888         * modules/argz (Makefile.am): Likewise.
37889         * modules/atexit (Makefile.am): Likewise.
37890         * modules/backupfile (Makefile.am): Likewise.
37891         * modules/byteswap (Makefile.am): Likewise.
37892         * modules/c-strtod (Makefile.am): Likewise.
37893         * modules/c-strtold (Makefile.am): Likewise.
37894         * modules/calloc (Makefile.am): Likewise.
37895         * modules/canon-host (Makefile.am): Likewise.
37896         * modules/canonicalize (Makefile.am): Likewise.
37897         * modules/chdir-long (Makefile.am): Likewise.
37898         * modules/chdir-safer (Makefile.am): Likewise.
37899         * modules/check-version (Makefile.am): Likewise.
37900         * modules/chown (Makefile.am): Likewise.
37901         * modules/cloexec (Makefile.am): Likewise.
37902         * modules/close-stream (Makefile.am): Likewise.
37903         * modules/closeout (Makefile.am): Likewise.
37904         * modules/crc (Makefile.am): Likewise.
37905         * modules/csharpexec (Makefile.am): Likewise.
37906         * modules/cycle-check (Makefile.am): Likewise.
37907         * modules/des (Makefile.am): Likewise.
37908         * modules/dev-ino (Makefile.am): Likewise.
37909         * modules/dirfd (Makefile.am): Likewise.
37910         * modules/dirname (Makefile.am): Likewise.
37911         * modules/dup2 (Makefile.am): Likewise.
37912         * modules/eealloc (Makefile.am): Likewise.
37913         * modules/error (Makefile.am): Likewise.
37914         * modules/euidaccess (Makefile.am): Likewise.
37915         * modules/exclude (Makefile.am): Likewise.
37916         * modules/exitfail (Makefile.am): Likewise.
37917         * modules/fcntl-safer (Makefile.am): Likewise.
37918         * modules/fcntl (Makefile.am): Likewise.
37919         * modules/file-type (Makefile.am): Likewise.
37920         * modules/fileblocks (Makefile.am): Likewise.
37921         * modules/filemode (Makefile.am): Likewise.
37922         * modules/filenamecat (Makefile.am): Likewise.
37923         * modules/fnmatch (Makefile.am): Likewise.
37924         * modules/fopen-safer (Makefile.am): Likewise.
37925         * modules/fpending (Makefile.am): Likewise.
37926         * modules/fprintftime (Makefile.am): Likewise.
37927         * modules/free (Makefile.am): Likewise.
37928         * modules/fsusage (Makefile.am): Likewise.
37929         * modules/ftruncate (Makefile.am): Likewise.
37930         * modules/fts (Makefile.am): Likewise.
37931         * modules/gc-arcfour (Makefile.am): Likewise.
37932         * modules/gc-des (Makefile.am): Likewise.
37933         * modules/gc-hmac-md5 (Makefile.am): Likewise.
37934         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
37935         * modules/gc-md4 (Makefile.am): Likewise.
37936         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
37937         * modules/gc-sha1 (Makefile.am): Likewise.
37938         * modules/gc (Makefile.am): Likewise.
37939         * modules/getaddrinfo (Makefile.am): Likewise.
37940         * modules/getcwd (Makefile.am): Likewise.
37941         * modules/getdelim (Makefile.am): Likewise.
37942         * modules/getdomainname (Makefile.am): Likewise.
37943         * modules/getgroups (Makefile.am): Likewise.
37944         * modules/gethostname (Makefile.am): Likewise.
37945         * modules/gethrxtime (Makefile.am): Likewise.
37946         * modules/getline (Makefile.am): Likewise.
37947         * modules/getloadavg (Makefile.am): Likewise.
37948         * modules/getlogin_r (Makefile.am): Likewise.
37949         * modules/getndelim2 (Makefile.am): Likewise.
37950         * modules/getopt (Makefile.am): Likewise.
37951         * modules/getpagesize (Makefile.am): Likewise.
37952         * modules/getpass-gnu (Makefile.am): Likewise.
37953         * modules/getpass (Makefile.am): Likewise.
37954         * modules/getsubopt (Makefile.am): Likewise.
37955         * modules/gettime (Makefile.am): Likewise.
37956         * modules/gettimeofday (Makefile.am): Likewise.
37957         * modules/getugroups (Makefile.am): Likewise.
37958         * modules/getusershell (Makefile.am): Likewise.
37959         * modules/glob (Makefile.am): Likewise.
37960         * modules/group-member (Makefile.am): Likewise.
37961         * modules/hard-locale (Makefile.am): Likewise.
37962         * modules/hash (Makefile.am): Likewise.
37963         * modules/hmac-md5 (Makefile.am): Likewise.
37964         * modules/hmac-sha1 (Makefile.am): Likewise.
37965         * modules/human (Makefile.am): Likewise.
37966         * modules/idcache (Makefile.am): Likewise.
37967         * modules/imaxabs (Makefile.am): Likewise.
37968         * modules/imaxdiv (Makefile.am): Likewise.
37969         * modules/inet_ntop (Makefile.am): Likewise.
37970         * modules/inet_pton (Makefile.am): Likewise.
37971         * modules/intprops (Makefile.am): Likewise.
37972         * modules/inttostr (Makefile.am): Likewise.
37973         * modules/inttypes (Makefile.am): Likewise.
37974         * modules/isapipe (Makefile.am): Likewise.
37975         * modules/javaversion (Makefile.am): Likewise.
37976         * modules/lchmod (Makefile.am): Likewise.
37977         * modules/lchown (Makefile.am): Likewise.
37978         * modules/localcharset (Makefile.am): Likewise.
37979         * modules/long-options (Makefile.am): Likewise.
37980         * modules/lstat (Makefile.am): Likewise.
37981         * modules/malloc (Makefile.am): Likewise.
37982         * modules/mathl (Makefile.am): Likewise.
37983         * modules/mbchar (Makefile.am): Likewise.
37984         * modules/md2 (Makefile.am): Likewise.
37985         * modules/md4 (Makefile.am): Likewise.
37986         * modules/md5 (Makefile.am): Likewise.
37987         * modules/memcasecmp (Makefile.am): Likewise.
37988         * modules/memchr (Makefile.am): Likewise.
37989         * modules/memcmp (Makefile.am): Likewise.
37990         * modules/memcoll (Makefile.am): Likewise.
37991         * modules/memcpy (Makefile.am): Likewise.
37992         * modules/memmem (Makefile.am): Likewise.
37993         * modules/memmove (Makefile.am): Likewise.
37994         * modules/mempcpy (Makefile.am): Likewise.
37995         * modules/memrchr (Makefile.am): Likewise.
37996         * modules/memset (Makefile.am): Likewise.
37997         * modules/memxor (Makefile.am): Likewise.
37998         * modules/mkancesdirs (Makefile.am): Likewise.
37999         * modules/mkdir-p (Makefile.am): Likewise.
38000         * modules/mkdir (Makefile.am): Likewise.
38001         * modules/mkdtemp (Makefile.am): Likewise.
38002         * modules/mkstemp (Makefile.am): Likewise.
38003         * modules/mktime (Makefile.am): Likewise.
38004         * modules/modechange (Makefile.am): Likewise.
38005         * modules/mountlist (Makefile.am): Likewise.
38006         * modules/nanosleep (Makefile.am): Likewise.
38007         * modules/obstack (Makefile.am): Likewise.
38008         * modules/openat (Makefile.am): Likewise.
38009         * modules/pagealign_alloc (Makefile.am): Likewise.
38010         * modules/pathmax (Makefile.am): Likewise.
38011         * modules/physmem (Makefile.am): Likewise.
38012         * modules/poll (Makefile.am): Likewise.
38013         * modules/posixtm (Makefile.am): Likewise.
38014         * modules/posixver (Makefile.am): Likewise.
38015         * modules/putenv (Makefile.am): Likewise.
38016         * modules/quote (Makefile.am): Likewise.
38017         * modules/quotearg (Makefile.am): Likewise.
38018         * modules/raise (Makefile.am): Likewise.
38019         * modules/read-file (Makefile.am): Likewise.
38020         * modules/readline (Makefile.am): Likewise.
38021         * modules/readlink (Makefile.am): Likewise.
38022         * modules/readtokens (Makefile.am): Likewise.
38023         * modules/readutmp (Makefile.am): Likewise.
38024         * modules/realloc (Makefile.am): Likewise.
38025         * modules/regex (Makefile.am): Likewise.
38026         * modules/rename-dest-slash (Makefile.am): Likewise.
38027         * modules/rename (Makefile.am): Likewise.
38028         * modules/rijndael (Makefile.am): Likewise.
38029         * modules/rmdir (Makefile.am): Likewise.
38030         * modules/rpmatch (Makefile.am): Likewise.
38031         * modules/safe-read (Makefile.am): Likewise.
38032         * modules/safe-write (Makefile.am): Likewise.
38033         * modules/same-inode (Makefile.am): Likewise.
38034         * modules/same (Makefile.am): Likewise.
38035         * modules/save-cwd (Makefile.am): Likewise.
38036         * modules/savedir (Makefile.am): Likewise.
38037         * modules/setenv (Makefile.am): Likewise.
38038         * modules/settime (Makefile.am): Likewise.
38039         * modules/sha1 (Makefile.am): Likewise.
38040         * modules/sig2str (Makefile.am): Likewise.
38041         * modules/snprintf (Makefile.am): Likewise.
38042         * modules/stat-macros (Makefile.am): Likewise.
38043         * modules/stat-time (Makefile.am): Likewise.
38044         * modules/stdbool (Makefile.am): Likewise.
38045         * modules/stdint (Makefile.am): Likewise.
38046         * modules/stdlib-safer (Makefile.am): Likewise.
38047         * modules/stpcpy (Makefile.am): Likewise.
38048         * modules/stpncpy (Makefile.am): Likewise.
38049         * modules/strcase (Makefile.am): Likewise.
38050         * modules/strcasestr (Makefile.am): Likewise.
38051         * modules/strchrnul (Makefile.am): Likewise.
38052         * modules/strcspn (Makefile.am): Likewise.
38053         * modules/strdup (Makefile.am): Likewise.
38054         * modules/strerror (Makefile.am): Likewise.
38055         * modules/strftime (Makefile.am): Likewise.
38056         * modules/strndup (Makefile.am): Likewise.
38057         * modules/strnlen (Makefile.am): Likewise.
38058         * modules/strpbrk (Makefile.am): Likewise.
38059         * modules/strsep (Makefile.am): Likewise.
38060         * modules/strstr (Makefile.am): Likewise.
38061         * modules/strtod (Makefile.am): Likewise.
38062         * modules/strtoimax (Makefile.am): Likewise.
38063         * modules/strtok_r (Makefile.am): Likewise.
38064         * modules/strtol (Makefile.am): Likewise.
38065         * modules/strtoll (Makefile.am): Likewise.
38066         * modules/strtoul (Makefile.am): Likewise.
38067         * modules/strtoull (Makefile.am): Likewise.
38068         * modules/strtoumax (Makefile.am): Likewise.
38069         * modules/strverscmp (Makefile.am): Likewise.
38070         * modules/sys_socket (Makefile.am): Likewise.
38071         * modules/sys_stat (Makefile.am): Likewise.
38072         * modules/sysexits (Makefile.am): Likewise.
38073         * modules/time_r (Makefile.am): Likewise.
38074         * modules/timegm (Makefile.am): Likewise.
38075         * modules/timespec (Makefile.am): Likewise.
38076         * modules/tmpfile-safer (Makefile.am): Likewise.
38077         * modules/trim (Makefile.am): Likewise.
38078         * modules/unistd-safer (Makefile.am): Likewise.
38079         * modules/unlinkdir (Makefile.am): Likewise.
38080         * modules/unlocked-io (Makefile.am): Likewise.
38081         * modules/userspec (Makefile.am): Likewise.
38082         * modules/utime (Makefile.am): Likewise.
38083         * modules/utimecmp (Makefile.am): Likewise.
38084         * modules/utimens (Makefile.am): Likewise.
38085         * modules/vasnprintf (Makefile.am): Likewise.
38086         * modules/vasprintf (Makefile.am): Likewise.
38087         * modules/vsnprintf (Makefile.am): Likewise.
38088         * modules/xalloc (Makefile.am): Likewise.
38089         * modules/xgetcwd (Makefile.am): Likewise.
38090         * modules/xnanosleep (Makefile.am): Likewise.
38091         * modules/xreadlink (Makefile.am): Likewise.
38092         * modules/xstrtod (Makefile.am): Likewise.
38093         * modules/xstrtol (Makefile.am): Likewise.
38094         * modules/xstrtold (Makefile.am): Likewise.
38095         * modules/yesno (Makefile.am): Likewise.
38096         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
38097
38098 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
38099
38100         * modules/error (Makefile.am): Distribute files through
38101         EXTRA_DIST, not lib_SOURCES.
38102
38103 2006-10-12  Eric Blake  <ebb9@byu.net>
38104
38105         * modules/error (Makefile.am): Distribute files in /lib.
38106         * modules/obstack (Makefile.am): Likewise.
38107
38108 2006-10-12  Bruno Haible  <bruno@clisp.org>
38109
38110         * modules/acl (Makefile.am): Distribute all files in lib/ through
38111         EXTRA_DIST.
38112         * modules/arcfour (Makefile.am): Likewise.
38113         * modules/arctwo (Makefile.am): Likewise.
38114         * modules/argmatch (Makefile.am): Likewise.
38115         * modules/argz (Makefile.am): Likewise.
38116         * modules/atexit (Makefile.am): Likewise.
38117         * modules/backupfile (Makefile.am): Likewise.
38118         * modules/c-strtod (Makefile.am): Likewise.
38119         * modules/c-strtold (Makefile.am): Likewise.
38120         * modules/calloc (Makefile.am): Likewise.
38121         * modules/canon-host (Makefile.am): Likewise.
38122         * modules/canonicalize (Makefile.am): Likewise.
38123         * modules/chdir-long (Makefile.am): Likewise.
38124         * modules/chdir-safer (Makefile.am): Likewise.
38125         * modules/check-version (Makefile.am): Likewise.
38126         * modules/chown (Makefile.am): Likewise.
38127         * modules/cloexec (Makefile.am): Likewise.
38128         * modules/close-stream (Makefile.am): Likewise.
38129         * modules/closeout (Makefile.am): Likewise.
38130         * modules/crc (Makefile.am): Likewise.
38131         * modules/cycle-check (Makefile.am): Likewise.
38132         * modules/des (Makefile.am): Likewise.
38133         * modules/dirfd (Makefile.am): Likewise.
38134         * modules/dirname (Makefile.am): Likewise.
38135         * modules/dup2 (Makefile.am): Likewise.
38136         * modules/euidaccess (Makefile.am): Likewise.
38137         * modules/exclude (Makefile.am): Likewise.
38138         * modules/exitfail (Makefile.am): Likewise.
38139         * modules/fcntl-safer (Makefile.am): Likewise.
38140         * modules/file-type (Makefile.am): Likewise.
38141         * modules/fileblocks (Makefile.am): Likewise.
38142         * modules/filemode (Makefile.am): Likewise.
38143         * modules/filenamecat (Makefile.am): Likewise.
38144         * modules/fnmatch (Makefile.am): Likewise.
38145         * modules/fopen-safer (Makefile.am): Likewise.
38146         * modules/fpending (Makefile.am): Likewise.
38147         * modules/fprintftime (Makefile.am): Likewise.
38148         * modules/free (Makefile.am): Likewise.
38149         * modules/fsusage (Makefile.am): Likewise.
38150         * modules/ftruncate (Makefile.am): Likewise.
38151         * modules/fts (Makefile.am): Likewise.
38152         * modules/gc (Makefile.am): Likewise.
38153         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
38154         * modules/getaddrinfo (Makefile.am): Likewise.
38155         * modules/getcwd (Makefile.am): Likewise.
38156         * modules/getdelim (Makefile.am): Likewise.
38157         * modules/getdomainname (Makefile.am): Likewise.
38158         * modules/getgroups (Makefile.am): Likewise.
38159         * modules/gethostname (Makefile.am): Likewise.
38160         * modules/gethrxtime (Makefile.am): Likewise.
38161         * modules/getline (Makefile.am): Likewise.
38162         * modules/getloadavg (Makefile.am): Likewise.
38163         * modules/getlogin_r (Makefile.am): Likewise.
38164         * modules/getopt (Makefile.am): Likewise.
38165         * modules/getpass (Makefile.am): Likewise.
38166         * modules/getpass-gnu (Makefile.am): Likewise.
38167         * modules/getsubopt (Makefile.am): Likewise.
38168         * modules/gettime (Makefile.am): Likewise.
38169         * modules/gettimeofday (Makefile.am): Likewise.
38170         * modules/getugroups (Makefile.am): Likewise.
38171         * modules/getusershell (Makefile.am): Likewise.
38172         * modules/glob (Makefile.am): Likewise.
38173         * modules/group-member (Makefile.am): Likewise.
38174         * modules/hard-locale (Makefile.am): Likewise.
38175         * modules/hash (Makefile.am): Likewise.
38176         * modules/hmac-md5 (Makefile.am): Likewise.
38177         * modules/hmac-sha1 (Makefile.am): Likewise.
38178         * modules/human (Makefile.am): Likewise.
38179         * modules/idcache (Makefile.am): Likewise.
38180         * modules/imaxabs (Makefile.am): Likewise.
38181         * modules/imaxdiv (Makefile.am): Likewise.
38182         * modules/inet_ntop (Makefile.am): Likewise.
38183         * modules/inet_pton (Makefile.am): Likewise.
38184         * modules/inttostr (Makefile.am): Likewise.
38185         * modules/isapipe (Makefile.am): Likewise.
38186         * modules/lchown (Makefile.am): Likewise.
38187         * modules/long-options (Makefile.am): Likewise.
38188         * modules/lstat (Makefile.am): Likewise.
38189         * modules/malloc (Makefile.am): Likewise.
38190         * modules/mathl (Makefile.am): Likewise.
38191         * modules/mbchar (Makefile.am): Likewise.
38192         * modules/md2 (Makefile.am): Likewise.
38193         * modules/md4 (Makefile.am): Likewise.
38194         * modules/md5 (Makefile.am): Likewise.
38195         * modules/memcasecmp (Makefile.am): Likewise.
38196         * modules/memchr (Makefile.am): Likewise.
38197         * modules/memcmp (Makefile.am): Likewise.
38198         * modules/memcoll (Makefile.am): Likewise.
38199         * modules/memcpy (Makefile.am): Likewise.
38200         * modules/memmem (Makefile.am): Likewise.
38201         * modules/memmove (Makefile.am): Likewise.
38202         * modules/mempcpy (Makefile.am): Likewise.
38203         * modules/memrchr (Makefile.am): Likewise.
38204         * modules/memset (Makefile.am): Likewise.
38205         * modules/memxor (Makefile.am): Likewise.
38206         * modules/mkancesdirs (Makefile.am): Likewise.
38207         * modules/mkdir (Makefile.am): Likewise.
38208         * modules/mkdir-p (Makefile.am): Likewise.
38209         * modules/mkdtemp (Makefile.am): Likewise.
38210         * modules/mkstemp (Makefile.am): Likewise.
38211         * modules/mktime (Makefile.am): Likewise.
38212         * modules/modechange (Makefile.am): Likewise.
38213         * modules/mountlist (Makefile.am): Likewise.
38214         * modules/nanosleep (Makefile.am): Likewise.
38215         * modules/openat (Makefile.am): Likewise.
38216         * modules/pagealign_alloc (Makefile.am): Likewise.
38217         * modules/physmem (Makefile.am): Likewise.
38218         * modules/poll (Makefile.am): Likewise.
38219         * modules/posixtm (Makefile.am): Likewise.
38220         * modules/posixver (Makefile.am): Likewise.
38221         * modules/putenv (Makefile.am): Likewise.
38222         * modules/quote (Makefile.am): Likewise.
38223         * modules/quotearg (Makefile.am): Likewise.
38224         * modules/raise (Makefile.am): Likewise.
38225         * modules/read-file (Makefile.am): Likewise.
38226         * modules/readline (Makefile.am): Likewise.
38227         * modules/readlink (Makefile.am): Likewise.
38228         * modules/readtokens (Makefile.am): Likewise.
38229         * modules/readutmp (Makefile.am): Likewise.
38230         * modules/realloc (Makefile.am): Likewise.
38231         * modules/regex (Makefile.am): Likewise.
38232         * modules/rename (Makefile.am): Likewise.
38233         * modules/rename-dest-slash (Makefile.am): Likewise.
38234         * modules/rijndael (Makefile.am): Likewise.
38235         * modules/rmdir (Makefile.am): Likewise.
38236         * modules/rpmatch (Makefile.am): Likewise.
38237         * modules/safe-read (Makefile.am): Likewise.
38238         * modules/safe-write (Makefile.am): Likewise.
38239         * modules/same (Makefile.am): Likewise.
38240         * modules/save-cwd (Makefile.am): Likewise.
38241         * modules/savedir (Makefile.am): Likewise.
38242         * modules/setenv (Makefile.am): Likewise.
38243         * modules/settime (Makefile.am): Likewise.
38244         * modules/sha1 (Makefile.am): Likewise.
38245         * modules/sig2str (Makefile.am): Likewise.
38246         * modules/snprintf (Makefile.am): Likewise.
38247         * modules/stdlib-safer (Makefile.am): Likewise.
38248         * modules/stpcpy (Makefile.am): Likewise.
38249         * modules/stpncpy (Makefile.am): Likewise.
38250         * modules/strcase (Makefile.am): Likewise.
38251         * modules/strcasestr (Makefile.am): Likewise.
38252         * modules/strchrnul (Makefile.am): Likewise.
38253         * modules/strcspn (Makefile.am): Likewise.
38254         * modules/strdup (Makefile.am): Likewise.
38255         * modules/strerror (Makefile.am): Likewise.
38256         * modules/strftime (Makefile.am): Likewise.
38257         * modules/strndup (Makefile.am): Likewise.
38258         * modules/strnlen (Makefile.am): Likewise.
38259         * modules/strpbrk (Makefile.am): Likewise.
38260         * modules/strsep (Makefile.am): Likewise.
38261         * modules/strstr (Makefile.am): Likewise.
38262         * modules/strtod (Makefile.am): Likewise.
38263         * modules/strtoimax (Makefile.am): Likewise.
38264         * modules/strtok_r (Makefile.am): Likewise.
38265         * modules/strtol (Makefile.am): Likewise.
38266         * modules/strtoll (Makefile.am): Likewise.
38267         * modules/strtoul (Makefile.am): Likewise.
38268         * modules/strtoull (Makefile.am): Likewise.
38269         * modules/strtoumax (Makefile.am): Likewise.
38270         * modules/strverscmp (Makefile.am): Likewise.
38271         * modules/time_r (Makefile.am): Likewise.
38272         * modules/timegm (Makefile.am): Likewise.
38273         * modules/tmpfile-safer (Makefile.am): Likewise.
38274         * modules/unistd-safer (Makefile.am): Likewise.
38275         * modules/unlinkdir (Makefile.am): Likewise.
38276         * modules/userspec (Makefile.am): Likewise.
38277         * modules/utime (Makefile.am): Likewise.
38278         * modules/utimecmp (Makefile.am): Likewise.
38279         * modules/utimens (Makefile.am): Likewise.
38280         * modules/vasnprintf (Makefile.am): Likewise.
38281         * modules/vasprintf (Makefile.am): Likewise.
38282         * modules/vsnprintf (Makefile.am): Likewise.
38283         * modules/xalloc (Makefile.am): Likewise.
38284         * modules/xgetcwd (Makefile.am): Likewise.
38285         * modules/xnanosleep (Makefile.am): Likewise.
38286         * modules/xreadlink (Makefile.am): Likewise.
38287         * modules/xstrtod (Makefile.am): Likewise.
38288         * modules/xstrtol (Makefile.am): Likewise.
38289         * modules/xstrtold (Makefile.am): Likewise.
38290         * modules/yesno (Makefile.am): Likewise.
38291
38292 2006-10-12  Jim Meyering  <jim@meyering.net>
38293
38294         * m4/getloadavg.m4: Revert the change below.
38295
38296         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
38297         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
38298         fail with a symlink, which is what coreutils' ./bootstrap now
38299         creates by default.
38300
38301 2006-10-12  Bruno Haible  <bruno@clisp.org>
38302
38303         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
38304         mingw.
38305         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
38306         MSVC and mingw explicitly.
38307
38308 2006-10-11  Simon Josefsson  <jas@extundo.com>
38309             Bruno Haible  <bruno@clisp.org>
38310
38311         Add support for multiple gnulib-tool invocations in the scope of a
38312         single configure.ac file.
38313         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
38314         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
38315         with the same contents as the _LIBADD variable.
38316         (func_emit_initmacro_start, func_emit_initmacro_end,
38317         func_emit_initmacro_done): New functions.
38318         (func_import, func_create_testdir): Invoke them. Allow the identifiers
38319         gl_LIBOBJS and gl_LTLIBOBJS.
38320
38321 2006-10-11  Bruno Haible  <bruno@clisp.org>
38322
38323         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
38324         (func_create_testdir): Don't create po/Makefile.am, don't invoke
38325         autoreconf. Instead, invoke autopoint explicitly but move back the
38326         *.m4 files from gnulib.
38327
38328 2006-10-11  Bruno Haible  <bruno@clisp.org>
38329
38330         * gnulib-tool (func_usage): Make module names after --create-testdir
38331         optional.
38332         (func_create_testdir): If no module was specified, use nearly all
38333         modules.
38334
38335 2006-10-12  Jim Meyering  <jim@meyering.net>
38336
38337         Big performance improvement for fts-based tools that use FTS_NOSTAT.
38338         Avoid spurious inode-mismatch problems on non-POSIX file systems.
38339         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
38340         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
38341         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
38342         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
38343         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
38344         (fts_set_stat_required): New function.
38345         (fts_open): Defer the calls to fts_stat, if possible or requested.
38346         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
38347         into fts_stat itself.
38348         (fts_read): Perform any required (deferred) fts_stat call.
38349         (fts_build): Likewise, for the directory we're about to open and read.
38350         In the readdir loop, carefully decide whether each entry will require
38351         an eventual call to fts_stat, using dirent.d_type info if available.
38352         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
38353         a command line argument into this function.  Update all callers.
38354         Map a return value of FTS_DOT to FTS_D for a command line argument.
38355         * modules/fts (Depends-on): Add d-type.  Alphabetize.
38356         Thanks to Miklos Szeredi for his tenacity and for the initial
38357         bug report about "find" failing on a FUSE-based file system.
38358
38359         * lib/fts.c (fts_open): Use consistent indentation.
38360
38361 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
38362
38363         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
38364         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
38365         reported by Jim Meyering.  All uses of cache variables renamed
38366         to match Autoconf's.
38367         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
38368         the other one.
38369
38370         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
38371         Fix misspelling in diagnostic.
38372
38373 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
38374
38375         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
38376         defined.  Problem reported by Matthew Woehlke.
38377
38378         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
38379         Add support for Tandem NonStop R series.
38380         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
38381         Use new macro.
38382
38383         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
38384         (has_trailing_slash): Omit size arg; all callers changed.
38385         Omit 'inline', since it doesn't help performance and we'd
38386         need to configure it.
38387         Don't count //, ///, etc. as having a trailing slash.
38388         As a side effect, this removes a C99ism reported by Matthew Woehlke.
38389         (rpl_rename_dest_slash): On failure, use rename's errno rather
38390         than (in some cases) an incorrect or junk errno.
38391         Simplify code by removing need to compute length; this does
38392         cause it to make two passes instead of one over the file name,
38393         but it's worth it.
38394
38395         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
38396         change, since Autoconf's version may no longer be appropriate now
38397         that we are using CVS Autoconf's version.  Add support for Tandem.
38398
38399 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
38400             Bruno Haible  <bruno@clisp.org>
38401
38402         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
38403         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
38404         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
38405         gl_AC_TYPE_LONG_LONG.
38406
38407         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
38408         instead of HAVE_LONG_LONG.
38409         * lib/printf-args.c (printf_fetchargs): Likewise.
38410         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
38411         * lib/vasnprintf.c (VASNPRINTF): Likewise.
38412         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
38413         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
38414         gl_AC_TYPE_LONG_LONG.
38415
38416 2006-10-11  Bruno Haible  <bruno@clisp.org>
38417
38418         * m4/longlong.m4: Add comments.
38419         * m4/ulonglong.m4: Likewise.
38420
38421 2006-10-10  Bruno Haible  <bruno@clisp.org>
38422
38423         Make it possible to #define stpcpy, strdup to aliases.
38424         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
38425         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
38426
38427 2006-10-10  Bruno Haible  <bruno@clisp.org>
38428
38429         Make it possible to #define gcd to an alias.
38430         * lib/gcd.c: Include config.h.
38431
38432 2006-10-10  Bruno Haible  <bruno@clisp.org>
38433
38434         Make it possible to #define c_isascii to an alias.
38435         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
38436         defined. Undefine the macros before defining them, to avoid gcc
38437         warnings.
38438         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
38439         define NO_C_CTYPE_MACROS early.
38440
38441 2006-10-10  Bruno Haible  <bruno@clisp.org>
38442
38443         Make it possible to #define set_program_name to an alias.
38444         * lib/progname.c: Don't undefine set_program_name; instead, undefine
38445         ENABLE_RELOCATABLE early.
38446
38447 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
38448
38449         Port to Tandem NSK OSS, which has 64-bit signed int but at most
38450         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
38451         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
38452         More generally, don't assume that 64-bit signed int is available
38453         if unsigned int is, and vice versa.
38454         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
38455         unsigned symbols, not on their signed counterparts.
38456         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
38457         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
38458         (UINT64_C, UINTMAX_C):
38459         Likewise.
38460         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
38461         unsigned counterparts.
38462         (Have_long_long, Unsigned): New macros.
38463         (Int): Renamed from INT.
38464         (strtoimax): Use the new macros.
38465         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
38466         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
38467         * modules/inttypes (inttypes.h): Substitute
38468         HAVE_UNSIGNED_LONG_LONG_INT.
38469         * modules/stdint (stdint.h): Likewise.
38470         (Files): Add m4/ulonglong.m4.
38471
38472 2006-10-10  Bruno Haible  <bruno@clisp.org>
38473
38474         Fix a gcc -Wshadow warning.
38475         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
38476         to 'bucket'.
38477         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
38478         gl_linked_indexof_from_to): Likewise.
38479         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
38480         Likewise.
38481         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
38482         Likewise.
38483         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
38484         Reported by Eric Blake.
38485
38486 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
38487
38488         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
38489         for NetBSD.  Problem reported by Bruno Haible.
38490
38491 2006-10-09  Jim Meyering  <jim@meyering.net>
38492
38493         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
38494         Patch from Bruno Haible.
38495
38496 2006-10-09  Jim Meyering  <jim@meyering.net>
38497
38498         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
38499         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
38500         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
38501
38502 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
38503
38504         Don't include <config.h> twice; this doesn't work in some cases,
38505         e.g., when config.h has "#define intmax_t long long int" and
38506         we include <config.h>, <inttypes.h>, <config.h> in that order.
38507         Problem reported by Matthew Woehlke in:
38508         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
38509         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
38510         * lib/fts-cycle.c: Don't include config.h.
38511         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
38512         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
38513         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
38514         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
38515         inttypes.h.
38516         * lib/xstrtoumax.c: Likewise.
38517         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
38518         __strtol and the like, so that this module is more like its siblings.
38519         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
38520         Remove; no longer needed now that we assume gnulib inttypes.h.
38521
38522 2006-10-08  Bruno Haible  <bruno@clisp.org>
38523
38524         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
38525         option.
38526
38527 2006-10-07  Jim Meyering  <jim@meyering.net>
38528
38529         * modules/inttypes (inttypes.h): Revert what seems to have been
38530         an inadvertent part of today's change: use "|", not "/" in the
38531         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
38532
38533 2006-10-07  Bruno Haible  <bruno@clisp.org>
38534
38535         * modules/sublist: New file.
38536
38537 2006-10-07  Bruno Haible  <bruno@clisp.org>
38538
38539         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
38540         * modules/argz (argz.h): Likewise.
38541         * modules/arpa_inet (arpa/inet.h): Likewise.
38542         * modules/byteswap (byteswap.h): Likewise.
38543         * modules/configmake (configmake.h): Likewise.
38544         * modules/fcntl (fcntl.h): Likewise.
38545         * modules/fnmatch (fnmatch.h): Likewise.
38546         * modules/getopt (getopt.h): Likewise.
38547         * modules/glob (glob.h): Likewise.
38548         * modules/inttypes (inttypes.h): Likewise.
38549         * modules/netinet_in (netinet/in.h): Likewise.
38550         * modules/poll (poll.h): Likewise.
38551         * modules/stdbool (stdbool.h): Likewise.
38552         * modules/stdint (stdint.h): Likewise.
38553         * modules/sys_select (sys/select.h): Likewise.
38554         * modules/sys_socket (sys/socket.h): Likewise.
38555         * modules/sys_stat (sys/stat.h): Likewise.
38556         * modules/sysexits (sysexits.h): Likewise.
38557         * modules/unistd (unistd.h): Likewise.
38558         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
38559         Add a "DO NOT EDIT" comment to the generated file.
38560         (func_import): Likewise for gnulib-comp.m4.
38561
38562 2006-10-07  Bruno Haible  <bruno@clisp.org>
38563
38564         * lib/gl_sublist.h: New file.
38565         * lib/gl_sublist.c: New file.
38566
38567 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
38568
38569         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
38570         name (relative to the original working directory) and the file
38571         name component (relative to the temporary working directory).  All
38572         callers changed.
38573         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
38574         * lib/mkdir-p.c (make_dir_parents): Likewise.
38575         * lib/mkdir-p.h (make_dir_parents): Likewise.
38576
38577 2006-10-06  Eric Blake  <ebb9@byu.net>
38578
38579         Define several macros for use by the clean-temp module.
38580         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
38581         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
38582         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
38583
38584         * lib/clean-temp.h (close_stream_temp): New declaration.
38585         * lib/clean-temp.c (includes): Pull in headers according to what
38586         other modules are in use.
38587         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
38588
38589 2006-10-06  Bruno Haible  <bruno@clisp.org>
38590
38591         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
38592         instead of fopen, fwriteerror.
38593
38594 2006-10-06  Bruno Haible  <bruno@clisp.org>
38595
38596         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
38597         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
38598         int.
38599         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
38600         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
38601         Return an error indicator.
38602         Suggested by Eric Blake.
38603
38604 2006-10-06  Bruno Haible  <bruno@clisp.org>
38605
38606         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
38607         Reported by Eric Blake.
38608
38609 2006-10-06  Bruno Haible  <bruno@clisp.org>
38610
38611         * modules/closeout (Description): Mention stderr too.
38612
38613 2006-10-06  Bruno Haible  <bruno@clisp.org>
38614         and Paul Eggert  <eggert@cs.ucla.edu>
38615
38616         * lib/closeout.c (close_stdout): Also close stderr.
38617         * lib/closeout.h: Update comment.
38618
38619 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
38620
38621         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
38622         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
38623         * lib/dirchownmod.c: Include lchown.h.
38624         * lib/lchown.c: Don't include files that lchown.h now includes.
38625         Don't declare chown, since lchown.h now does that.
38626         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
38627         (lchown): Define to rpl_chown if lchown is declared but
38628         does not exist.  Declare using a prototype if lchown is not
38629         declared.  Add a copyright notice.
38630         * lib/mkstemp.h: Include <unistd.h>.
38631         * lib/openat.c: Include lchown.h.
38632
38633         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
38634         we now test for that separately.
38635         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
38636         rather than O_NOFOLLOW, when testing whether it's possible to
38637         avoid a race condition reliably.
38638         * lib/savewd.c (savewd_chdir): Likewise.
38639
38640         Remove macros that are no longer needed now that stdint.h is
38641         reliable.
38642         * lib/fsusage.c (UINTMAX_MAX): Remove.
38643         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
38644         * lib/utimecmp.c (SIZE_MAX): Remove.
38645
38646         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
38647
38648         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
38649         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
38650         O_NOATIME works.
38651
38652 2006-10-05  Bruno Haible  <bruno@clisp.org>
38653
38654         * lib/gl_list.h (gl_sortedlist_search_from_to,
38655         gl_sortedlist_indexof_from_to): New declarations.
38656         (gl_list_implementation): New fields sortedlist_search_from_to,
38657         sortedlist_indexof_from_to.
38658         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
38659         inline functions.
38660         * lib/gl_list.c (gl_sortedlist_search_from_to,
38661         gl_sortedlist_indexof_from_to): New functions.
38662         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
38663         function.
38664         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
38665         (gl_array_sortedlist_search_from_to): New function.
38666         (gl_array_list_implementation): Update.
38667         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
38668         function.
38669         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
38670         (gl_carray_sortedlist_search_from_to): New function.
38671         (gl_carray_list_implementation): Update.
38672         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
38673         gl_linked_sortedlist_indexof_from_to): New functions.
38674         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
38675         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
38676         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
38677         gl_tree_sortedlist_indexof_from_to): New functions.
38678         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
38679         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
38680         Update.
38681         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
38682         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
38683         Update.
38684
38685 2006-10-05  Bruno Haible  <bruno@clisp.org>
38686
38687         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
38688         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
38689         (struct gl_list_implementation): Add fields search_from_to,
38690         indexof_from_to. Remove fields search, indexof.
38691         (gl_list_search): Use the search_from_to method.
38692         (gl_list_search_from, gl_list_search_from_to): New functions.
38693         (gl_list_indexof): Use the indexof_from_to method.
38694         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
38695         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
38696         (gl_list_search_from, gl_list_search_from_to): New functions.
38697         (gl_list_indexof): Use the indexof_from_to method.
38698         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
38699         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
38700         gl_array_indexof. Add start_index, end_index arguments.
38701         (gl_array_search_from_to): Renamed from gl_array_search. Add
38702         start_index, end_index arguments.
38703         (gl_array_remove, gl_array_list_implementation): Update.
38704         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
38705         gl_carray_indexof. Add start_index, end_index arguments.
38706         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
38707         start_index, end_index arguments.
38708         (gl_carray_remove, gl_carray_list_implementation): Update.
38709         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
38710         gl_linked_search. Add start_index, end_index arguments.
38711         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
38712         start_index, end_index arguments.
38713         (gl_linked_remove): Update.
38714         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
38715         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
38716         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
38717         field to 'size_t'.
38718         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
38719         gl_tree_search. Add start_index, end_index arguments.
38720         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
38721         start_index, end_index arguments.
38722         (gl_tree_remove): Update.
38723         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
38724         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
38725         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
38726         function.
38727         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
38728         gl_tree_search. Add start_index, end_index arguments.
38729         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
38730         start_index, end_index arguments.
38731         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
38732         Update.
38733         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
38734
38735 2006-10-05  Bruno Haible  <bruno@clisp.org>
38736
38737         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
38738
38739         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
38740         fwriteerror_temp): New declarations.
38741         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
38742         (descriptors): New variable.
38743         (cleanup): First, close the descriptors.
38744         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
38745         fclose_temp, fwriteerror_temp): New functions.
38746
38747 2006-10-04  Jim Meyering  <jim@meyering.net>
38748
38749         * lib/fts.c (fts_open): Tiny comment change.
38750
38751 2006-10-04  Bruno Haible  <bruno@clisp.org>
38752
38753         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
38754         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
38755         gl_LOCK_BODY.
38756         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
38757         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
38758         gl_LOCK_EARLY_BODY.
38759         (gl_LOCK): Require gl_LOCK_BODY.
38760
38761 2006-10-04  Bruno Haible  <bruno@clisp.org>
38762
38763         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
38764         (gl_oset_search_atleast): New declaration.
38765         (struct gl_oset_implementation): Add field 'search_atleast'.
38766         (gl_oset_search_atleast): New inline function.
38767         * lib/gl_oset.c (gl_oset_search_atleast): New function.
38768         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
38769         (gl_array_oset_implementation): Update.
38770         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
38771         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
38772         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
38773
38774 2006-10-04  Bruno Haible  <bruno@clisp.org>
38775
38776         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
38777
38778 2006-10-03  Bruno Haible  <bruno@clisp.org>
38779
38780         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
38781         from gl_avltreehash_list_implementation.
38782
38783 2006-10-03  Bruno Haible  <bruno@clisp.org>
38784
38785         * lib/gl_oset.c (gl_oset_add): Fix return type.
38786
38787 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
38788
38789         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
38790
38791 2006-10-02  Eric Blake  <ebb9@byu.net>
38792
38793         * modules/strnlen (Depends-on): Add extensions.
38794
38795 2006-10-02  Eric Blake  <ebb9@byu.net>
38796
38797         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
38798         definition in 2.60+.
38799
38800 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
38801
38802         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
38803         checks.
38804
38805 2006-10-02  Bruno Haible  <bruno@clisp.org>
38806
38807         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
38808         to the AUTOMAKE_OPTIONS.
38809         Reported by Jim Meyering.
38810
38811 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
38812
38813         Work around bug in Solaris 10 /proc file system:
38814         /proc/self/fd/NNN/.. isn't the parent directory of
38815         the directory whose file descriptor is NNN.  This needs to
38816         be worked around at run time, not compile time, since a
38817         program might be built on Solaris 8, where things work, and
38818         run on Solaris 10.
38819         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
38820         to use the following interface instead:
38821         (OPENAT_BUFFER_SIZE): New macro.
38822         (openat_proc_name): New function.
38823         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
38824         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
38825         Likewise.
38826         * lib/openat-proc.c: New file.
38827         * modules/openat (Files): Add lib/openat-proc.c.
38828         (Depends-on): Add same-inode, stdbool.
38829         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
38830
38831 2006-09-29  Bruno Haible  <bruno@clisp.org>
38832
38833         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
38834         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
38835         argument. Set stdout_closed before testing for ferror, not after.
38836         (fwriteerror, fwriteerror_no_ebadf): New functions.
38837
38838 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
38839
38840         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
38841
38842 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
38843
38844         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
38845         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
38846
38847 2006-09-28  Jim Meyering  <jim@meyering.net>
38848
38849         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
38850         Include <unistd.h>.
38851
38852 2006-09-28  Bruno Haible  <bruno@clisp.org>
38853
38854         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
38855         * modules/linkedhash-list (Depends-on): Likewise.
38856         * modules/rbtreehash-list (Depends-on): Likewise.
38857
38858 2006-09-28  Bruno Haible  <bruno@clisp.org>
38859
38860         * lib/strndup.h: Simplify the redefinition of strndup.
38861         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
38862         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
38863
38864 2006-09-28  Bruno Haible  <bruno@clisp.org>
38865
38866         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
38867         * lib/gl_linkedhash_list.c: Likewise.
38868         * lib/gl_rbtreehash_list.c: Likewise.
38869
38870 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
38871
38872         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
38873         getaddrinfo.
38874
38875         * lib/__fpending.h: Don't include <stdio_ext.h> unless
38876         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
38877         it causes <stdio_ext.h> to cause a compile-time error.
38878         Problem reported by Nelson H. F. Beebe.
38879         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
38880         of HAVE_DECL___PENDING.
38881
38882         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
38883         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
38884         declaration.
38885
38886 2006-09-27  Jim Meyering  <jim@meyering.net>
38887
38888         This file could end up with a definition for a function
38889         named __strndup, rather than rpl_strndup on a system with
38890         incomplete weak_alias support.
38891         * lib/strndup.c (strndup): Rename from __strndup.
38892         Remove #defines that used to map __strndup to strndup.
38893         Don't use K&R prototypes.
38894         Remove LIBC-related code, since this file is not sync'd with glibc.
38895         * lib/strndup.h: Revamp, accordingly.
38896         * m4/strndup.m4: Modernize.
38897
38898 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
38899
38900         * modules/savewd (Depends-on): Add 'raise'.
38901         * lib/savewd.c: Include <signal.h>, for 'raise'.
38902
38903 2006-09-26  Jim Meyering  <jim@meyering.net>
38904
38905         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
38906         when we detect Darwin 8.7.0's acl_get_file bug.
38907         Rearrange to perform the new (below) run-test while $LIBS
38908         contains any acl-related library.  Set USE_ACL at the end.
38909         (gl_ACL_GET_FILE): New function.
38910
38911 2006-09-26  Eric Blake  <ebb9@byu.net>
38912
38913         * lib/verror.c: Include <config.h> unconditionally.
38914
38915 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
38916
38917         * modules/clock-time (Maintainer): Add self.
38918         * modules/getlogin_r (Depends-on): Add extensions.
38919
38920 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
38921
38922         * modules/clock-time: New module.
38923         * modules/nanosleep (Depends-on): Add clock-time.
38924         * modules/gethrxtime (Depends-on): Likewise.
38925         * modules/gettime (Depends-on): Likewise.
38926         * modules/settime (Depends-on): Likewise.
38927
38928         * modules/fts-lgpl: Depend on openat.
38929         * modules/mkancesdirs: Depend on savewd.
38930         * modules/mkdir-p: Likewise.
38931
38932 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
38933
38934         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
38935
38936         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
38937         `gl_have_arbitrary_file_name_length_limit' to
38938         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
38939         actually works between configure runs.
38940
38941 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
38942             Bruno Haible  <bruno@clisp.org>
38943
38944         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
38945
38946 2006-09-25  Jim Meyering  <jim@meyering.net>
38947
38948         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
38949         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
38950
38951 2006-09-25  Eric Blake  <ebb9@byu.net>
38952
38953         * gnulib-tool (func_import, func_create_testdir): Fix typos in
38954         exec's in 2006-09-18 patch when shuffling fds.
38955
38956 2006-09-25  Bruno Haible  <bruno@clisp.org>
38957
38958         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
38959         Reported by Jim Meyering.
38960
38961 2006-09-24  Jim Meyering  <jim@meyering.net>
38962
38963         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
38964         compare a pointer against a literal "0".  That caused failures with
38965         at least HP-UX's hpcc.
38966
38967 2006-09-22  Simon Josefsson  <jas@extundo.com>
38968
38969         * modules/gc-sha1:
38970         * modules/gc-md4:
38971         * modules/gc-hmac-sha1:
38972         * modules/gc-hmac-md5:
38973         * modules/gc-des:
38974         * modules/gc-arcfour: Distribute more files.
38975
38976 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
38977
38978         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
38979         (gl_linked_iterator_from_to): Initialize struct completely.
38980         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
38981         (gl_tree_iterator_from_to): Likewise
38982         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
38983         * lib/gl_array_list.c [lint] (gl_array_iterator)
38984         (gl_array_iterator_from_to): Likewise.
38985         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
38986         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
38987         (gl_carray_iterator_from_to): Likewise.
38988
38989         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
38990         * lib/md4.c (md4_process_block): Remove unused variable.
38991         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
38992         parentheses for clarity.
38993
38994 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
38995
38996         * modules/bison-i18n (Depends-on): Add gettext.
38997
38998 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
38999
39000         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
39001         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
39002         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
39003         also add missing comma that caused broken test.
39004         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
39005         stdlib.h, for `abort'.
39006         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
39007         variables.
39008         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
39009         include unistd.h if present, for `rmdir'.
39010         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
39011         variables.
39012         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
39013         in the process include standard headers for prototypes.
39014         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
39015         gets declared on GNU/Linux.
39016         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
39017         unistd.h, for `rmdir'.
39018         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
39019
39020         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
39021         always true.
39022         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
39023
39024         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
39025
39026 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
39027
39028         * gnulib-tool (func_version): Create output all at once.  This
39029         may help avoid triggering unnecessary SIGPIPEs, and at any
39030         rate it doesn't hurt.
39031
39032 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
39033             Bruno Haible  <bruno@clisp.org>
39034
39035         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
39036         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
39037         * m4/signed.m4 (bh_C_SIGNED): Likewise.
39038
39039         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
39040         (gl_FUNC_VASPRINTF): Invoke it.
39041
39042 2006-09-22  Bruno Haible  <bruno@clisp.org>
39043
39044         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
39045         getloadavg.c as first argument.
39046
39047 2006-09-22  Bruno Haible  <bruno@clisp.org>
39048
39049         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
39050         at the beginning of the gl_INIT macro.
39051         * modules/getloadavg (configure.ac): Pass $gl_source_base to
39052         gl_GETLOADAVG.
39053
39054 2006-09-22  Bruno Haible  <bruno@clisp.org>
39055
39056         * gnulib-tool (func_create_megatestdir): Don't include the config-h
39057         module.
39058         Suggested by Ralf Wildenhues.
39059
39060 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
39061
39062         Import this patch from libc:
39063
39064         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
39065
39066         * lib/regex_internal.c (re_string_reconstruct): Handle
39067         offset < pstr->valid_raw_len && pstr->offsets_needed case.
39068         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
39069         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
39070         re_string_context_at.
39071
39072         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
39073         now requires it.
39074         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
39075         gl_REGEX now does it for us.
39076         (gl_REGEX): Add test taken from
39077         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
39078
39079         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
39080         Check that large offsets work.  Modernize Autoconf usages.
39081         Prefer "yes" to mean a good thing rather than a bad.
39082         Don't put "#define mkstemp" in config.h, as this might interfere
39083         with standard system headers that "#define mkstemp mkstemp64".
39084
39085         * modules/mkstemp (Depends-on): Add extensions, so that
39086         mkstemp is visible on some platforms.
39087         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
39088         (Include): Change to "mkstemp.h" from <stdlib.h>.
39089         (Files): Add mkstemp.h.
39090
39091         * lib/mkstemp.h: New file, since some standard headers
39092         #define mkstemp.
39093         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
39094         Include "mkstemp.h".
39095         Make the _LIBC code resemble glibc original more,
39096         e.g., use K&R style.
39097         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
39098         (mkstemp): Remove, since mkstemp.h does this for us.
39099         * lib/stdlib--.h: Include mkstemp.h.
39100
39101         Import this patch from libc:
39102
39103         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
39104
39105         * lib/tempname.c (__gen_tempname): Change attempts_min
39106         into a macro.  Use preprocessor to decide how to initialize
39107         attempts [Coverity CID 67].
39108
39109 2006-09-20  Bruno Haible  <bruno@clisp.org>
39110
39111         * lib/mkdtemp.c: Import from libc.
39112         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
39113                 * sysdeps/posix/tempname.c (__gen_tempname): Change
39114                 attempts_min into a macro.  Use preprocessor to decide how to
39115                 initialize attempts [Coverity CID 67].
39116         2001-11-27  Paul Eggert  <eggert@twinsun.com>
39117                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
39118                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
39119
39120 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
39121
39122         * gnulib-tool (func_exit): New function, to allow to pass the
39123         exit status portably through the trap.  Use everywhere.
39124         (--help, --version): Signal a write error.
39125         (trap): catch SIGPIPE, for write errors.
39126         Exit at the end of the trap, with the correct exit status.
39127
39128 2006-09-19  Karl Berry  <karl@gnu.org>
39129
39130         * doc/gnulib.texi: note about the license texinfo files.
39131
39132 2006-09-19  Eric Blake  <ebb9@byu.net>
39133
39134         * gnulib-tool: Avoid space-tab.
39135
39136 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
39137
39138         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
39139         that prevented coreutils 6.1 from building.  Problem reported
39140         by Petter Reinholdtsen.
39141
39142 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
39143
39144         * gnulib-tool (avoidlist): Fix typo that broke options like
39145         --avoid=lock that are used by coreutils bootstrap.
39146
39147 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
39148
39149         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
39150         more systematically.
39151
39152 2006-09-18  Jim Meyering  <jim@meyering.net>
39153
39154         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
39155
39156 2006-09-18  Bruno Haible  <bruno@clisp.org>
39157
39158         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
39159
39160 2006-09-18  Bruno Haible  <bruno@clisp.org>
39161
39162         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
39163         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
39164         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
39165         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
39166         * m4/gettext.m4: Require autoconf >= 2.52.
39167         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
39168         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
39169         of gl_cv_header_inttypes_h.
39170
39171 2006-09-18  Bruno Haible  <bruno@clisp.org>
39172
39173         * lib/javaversion.c: Include configmake.h.
39174
39175 2006-09-18  Bruno Haible  <bruno@clisp.org>
39176
39177         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
39178         avoid that the while loops be executed in a subshell.
39179
39180 2006-09-18  Bruno Haible  <bruno@clisp.org>
39181
39182         * MODULES.html.sh (func_module): Break long lines.
39183         Suggested by Bruce Korb <bkorb@gnu.org>.
39184
39185 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
39186
39187         Speed up by a factor of 1.12.
39188         * gnulib-tool (nl): New variable.
39189         (func_import): Rewrite include directive extraction to only read each
39190         directive once.
39191
39192 2006-09-17  Bruno Haible  <bruno@clisp.org>
39193
39194         * modules/javaversion (Makefile.am): Remove DEFS setting.
39195         (Depends-on): Add configmake, for PKGDATADIR definition.
39196
39197 2006-09-17  Bruno Haible  <bruno@clisp.org>
39198
39199         * gnulib-tool (func_create_testdir): Rewrite all files at once.
39200
39201 2006-09-17  Bruno Haible  <bruno@clisp.org>
39202
39203         * gnulib-tool (func_append): New function, stolen from libtool.m4.
39204         (func_modules_transitive_closure, func_modules_add_dummy,
39205         func_modules_to_filelist, func_import, func_create_testdir,
39206         func_create_megatestdir, ...): Use it wherever possible.
39207         Suggested by Ralf Wildenhues.
39208
39209 2006-09-16  Karl Berry  <karl@gnu.org>
39210
39211         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
39212         to avoid sectioning errors.
39213         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
39214         [ifinfo]: blank line after @center-ed titles.
39215         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
39216         Spell FSF address consistently with others.
39217         (These changes approved by rms.)
39218
39219 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
39220
39221         Speed up by a factor of 1.61.
39222         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
39223         already checked module names again.
39224
39225 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
39226
39227         Speed up by a factor of 1.13.
39228         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
39229         for new_files, and the input to func_add_or_update.
39230
39231 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
39232
39233         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
39234         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
39235
39236 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
39237
39238         * modules/mkancesdirs (Depends-on): Add fcntl.
39239         * modules/savewd: New file.
39240         * MODULES.html.sh (File system functions): Add savewd.
39241
39242         * modules/configmake (Makefile.am): Add support for the
39243         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
39244
39245 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
39246
39247         * m4/savewd.m4: New file.
39248
39249 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
39250
39251         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
39252         (dirchownmod): New arg FD.  All callers changed.
39253         Use FD rather than opening the directory ourself, as opening is
39254         now the caller's responsibility.
39255         * lib/dirchownmod.h: Likewise.
39256         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
39257         hosts that require <sys/types.h> before <sys/stat.h>.  Include
39258         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
39259         (test_dir): Remove.
39260         (mkancesdirs): Return length of prefix of FILE that has already
39261         been made, or -2 if there is a child doing the work.  Redo
39262         algorithm so that it is O(N) rather than O(N**2).  Optimize away
39263         ".", and treat ".." specially since it might stray back into
39264         already-created areas.  Use a subprocess if necessary.  New arg
39265         WD; all users changed.  MAKE_DIR function should now return 1
39266         if it creates a directory that is not readable.  Return -2 if
39267         a child process is spun off.
39268         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
39269         Adjust signature to match code.
39270         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
39271         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
39272         all users changed.
39273         * lib/savewd.c, lib/savewd.h: New files.
39274
39275 2006-09-15  Jim Meyering  <jim@meyering.net>
39276
39277         * modules/rename-dest-slash: New module.
39278         * MODULES.html.sh (posix_compat): Add it here.
39279
39280         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
39281
39282 2006-09-15  Jim Meyering  <jim@meyering.net>
39283
39284         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
39285         file.
39286
39287         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
39288
39289 2006-09-15  Jim Meyering  <jim@meyering.net>
39290
39291         * lib/rename-dest-slash.c (has_trailing_slash): Use
39292         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
39293         (rpl_rename_dest_slash): Perform the cheaper trailing slash
39294         test before testing whether SRC is a directory.
39295         Suggestions from Bruno Haible.
39296
39297         Avoid a warning about an unused variable.
39298         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
39299         into the #ifdef block where it's used.
39300
39301         * lib/rename-dest-slash.c: New file.
39302
39303 2006-09-14  Bruno Haible  <bruno@clisp.org>
39304
39305         * lib/allocsa.c: Include <config.h> unconditionally.
39306         * lib/asnprintf.c: Likewise.
39307         * lib/asprintf.c: Likewise.
39308         * lib/c-strcasecmp.c: Likewise.
39309         * lib/c-strcasestr.c: Likewise.
39310         * lib/c-strncasecmp.c: Likewise.
39311         * lib/c-strstr.c: Likewise.
39312         * lib/classpath.c: Likewise.
39313         * lib/clean-temp.c: Likewise.
39314         * lib/concatpath.c: Likewise.
39315         * lib/copy-file.c: Likewise.
39316         * lib/csharpcomp.c: Likewise.
39317         * lib/csharpexec.c: Likewise.
39318         * lib/execute.c: Likewise.
39319         * lib/fatal-signal.c: Likewise.
39320         * lib/findprog.c: Likewise.
39321         * lib/fwriteerror.c: Likewise.
39322         * lib/gl_array_list.c: Likewise.
39323         * lib/gl_array_oset.c: Likewise.
39324         * lib/gl_avltree_list.c: Likewise.
39325         * lib/gl_avltree_oset.c: Likewise.
39326         * lib/gl_avltreehash_list.c: Likewise.
39327         * lib/gl_carray_list.c: Likewise.
39328         * lib/gl_linked_list.c: Likewise.
39329         * lib/gl_linkedhash_list.c: Likewise.
39330         * lib/gl_list.c: Likewise.
39331         * lib/gl_oset.c: Likewise.
39332         * lib/gl_rbtree_list.c: Likewise.
39333         * lib/gl_rbtree_oset.c: Likewise.
39334         * lib/gl_rbtreehash_list.c: Likewise.
39335         * lib/imaxabs.c: Likewise.
39336         * lib/imaxdiv.c: Likewise.
39337         * lib/javacomp.c: Likewise.
39338         * lib/javaexec.c: Likewise.
39339         * lib/javaversion.c: Likewise.
39340         * lib/linebreak.c: Likewise.
39341         * lib/localcharset.c: Likewise.
39342         * lib/lock.c: Likewise.
39343         * lib/mbchar.c: Likewise.
39344         * lib/mbswidth.c: Likewise.
39345         * lib/mkdtemp.c: Likewise.
39346         * lib/pipe.c: Likewise.
39347         * lib/printf-args.c: Likewise.
39348         * lib/printf-parse.c: Likewise.
39349         * lib/progname.c: Likewise.
39350         * lib/progreloc.c: Likewise.
39351         * lib/readlink.c: Likewise.
39352         * lib/sh-quote.c: Likewise.
39353         * lib/stpcpy.c: Likewise.
39354         * lib/stpncpy.c: Likewise.
39355         * lib/strcasecmp.c: Likewise.
39356         * lib/strcasestr.c: Likewise.
39357         * lib/strcspn.c: Likewise.
39358         * lib/striconv.c: Likewise.
39359         * lib/strncasecmp.c: Likewise.
39360         * lib/strnlen1.c: Likewise.
39361         * lib/strstr.c: Likewise.
39362         * lib/strtok_r.c: Likewise.
39363         * lib/tls.c: Likewise.
39364         * lib/tmpdir.c: Likewise.
39365         * lib/unicodeio.c: Likewise.
39366         * lib/unsetenv.c: Likewise.
39367         * lib/vasnprintf.c: Likewise.
39368         * lib/vasprintf.c: Likewise.
39369         * lib/wait-process.c: Likewise.
39370         * lib/xallocsa.c: Likewise.
39371         * lib/xsetenv.c: Likewise.
39372         * lib/xstriconv.c: Likewise.
39373
39374 2006-09-13  Simon Josefsson  <jas@extundo.com>
39375
39376         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
39377         that internally, suggested by Ralf Wildenhues
39378         <Ralf.Wildenhues@gmx.de>.
39379
39380 2006-09-13  Simon Josefsson  <jas@extundo.com>
39381
39382         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
39383         @LIBOBJS@.
39384         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
39385
39386 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
39387
39388         * lib/_fpending.c: Include <config.h> unconditionally, since we no
39389         longer worry about uses that don't define HAVE_CONFIG_H.
39390         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
39391         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
39392         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
39393         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
39394         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
39395         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
39396         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
39397         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
39398         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
39399         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
39400         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
39401         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
39402         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
39403         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
39404         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
39405         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
39406         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
39407         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
39408         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
39409         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
39410         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
39411         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
39412         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
39413         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
39414         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
39415         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
39416         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
39417         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
39418         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
39419         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
39420         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
39421         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
39422         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
39423         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
39424         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
39425         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
39426         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
39427         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
39428         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
39429         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
39430         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
39431         Likewise.
39432
39433 2006-09-13  Eric Blake  <ebb9@byu.net>
39434
39435         * lib/getopt.c: Fix typo in last commit.
39436
39437 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
39438
39439         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
39440         dgettext.
39441
39442 2006-09-12  Jim Meyering  <jim@meyering.net>
39443
39444         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
39445         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
39446         Reported by Nelson H. F. Beebe.
39447
39448 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
39449
39450         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
39451         program_invocation_name and program_invocation_short_name are
39452         initialized.
39453         * lib/argp-namefrob.h: Move declarations of program_invocation_name
39454         and program_invocation_short_name to argp.h, so they are visible
39455         to user programs.
39456         * lib/argp.h: Likewise
39457
39458 2006-09-10  Bruno Haible  <bruno@clisp.org>
39459
39460         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
39461         m4/inttypes_h.m4, m4/uintmax_t.m4.
39462
39463 2006-09-10  Bruno Haible  <bruno@clisp.org>
39464
39465         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
39466         gl_AC_TYPE_UINTMAX_T.
39467
39468 2006-09-10  Bruno Haible  <bruno@clisp.org>
39469
39470         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
39471
39472 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
39473
39474         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
39475         convention.  Text proposed by Bruno Haible.
39476         (struct argp_option): Document the use of N_() wrappers.
39477
39478         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
39479         '\v', and translate the two parts separately, instead of feeding
39480         the whole string to gettext.  This allows to exclude
39481         '\v' from the strings visible to the translator by writing doc
39482         strings as N_("..") "\v" N_("..").
39483
39484 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
39485
39486         * config/srclist.txt: Undo latest change; the bug was fixed.
39487
39488 2006-09-09  Bruno Haible  <bruno@clisp.org>
39489
39490         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
39491         assignments if building a library without libtool.
39492         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
39493         in func_emit_lib_Makefile_am.
39494         (func_import): When building a static library libfoo.a, arrange to
39495         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
39496         (func_create_testdir): Likewise.
39497         * modules/gc (configure.ac, Makefile.am): If building statically,
39498         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
39499         * modules/iconvme (configure.ac, Makefile.am): Likewise.
39500         * modules/striconv (configure.ac, Makefile.am): Likewise.
39501         Based on a suggestion by Ralf Wildenhues.
39502
39503 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
39504
39505         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
39506         Check for unistd.h too, since Autoconf doesn't assume POSIX.
39507         Also:
39508
39509         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
39510         Add year_2050_test to catch glibc bug 2821
39511         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
39512
39513         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
39514         Prefer #ifdef to #if.
39515
39516         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
39517         Return from 'main' instead of calling 'exit'.
39518
39519 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
39520
39521         * lib/mktime.c (guess_time_tm): Fix bug where mktime
39522         returned the maximum time_t value rather than (time_t) -1.
39523         Problem originally reported by William Bardwell
39524         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
39525
39526         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
39527         Moved to here ...
39528         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
39529         ... from here.
39530
39531 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
39532
39533         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
39534         2821 is fixed.
39535
39536 2006-09-08  Jim Meyering  <jim@meyering.net>
39537
39538         Don't make generated files read-only.  That would bother too many
39539         people.  However, do retain the ability to work when targets are
39540         read-only: remove the destination and temporary files before writing
39541         them (when generated via sed or echo), or by using the -f option for
39542         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
39543         * modules/alloca-opt, modules/argz, modules/arpa_inet:
39544         * modules/byteswap, modules/configmake, modules/fcntl:
39545         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
39546         * modules/localcharset, modules/netinet_in, modules/poll:
39547         * modules/stdbool, modules/stdint, modules/sys_select:
39548         * modules/sys_socket, modules/sys_stat, modules/sysexits:
39549
39550 2006-09-08  Jim Meyering  <jim@meyering.net>
39551
39552         Avoid new build failure on FreeBSD 6.0.
39553         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
39554         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
39555         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
39556
39557 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
39558
39559         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
39560
39561 2006-09-07  Jim Meyering  <jim@meyering.net>
39562
39563         Fix global typo in last change: use chmod u-w, not chmod u-x.
39564         Spotted by Paul Eggert and Bruce Korb.
39565         * modules/alloca-opt, modules/argz, modules/arpa_inet:
39566         * modules/byteswap, modules/configmake, modules/fcntl:
39567         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
39568         * modules/localcharset, modules/netinet_in, modules/poll:
39569         * modules/stdbool, modules/stdint, modules/sys_select:
39570         * modules/sys_socket, modules/sys_stat, modules/sysexits:
39571
39572 2006-09-06  Jim Meyering  <jim@meyering.net>
39573
39574         Make generated files be read-only.
39575         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
39576         Ensure that each generated file is now read-only.
39577         * modules/argz: Likewise.
39578         * modules/arpa_inet: Likewise.
39579         * modules/byteswap: Likewise.
39580         * modules/configmake: Likewise.
39581         * modules/fcntl: Likewise.
39582         * modules/fnmatch: Likewise.
39583         * modules/getopt: Likewise.
39584         * modules/glob: Likewise.
39585         * modules/inttypes: Likewise.
39586         * modules/netinet_in: Likewise.
39587         * modules/poll: Likewise.
39588         * modules/stdbool: Likewise.
39589         * modules/stdint: Likewise.
39590         * modules/sys_select: Likewise.
39591         * modules/sys_socket: Likewise.
39592         * modules/sys_stat: Likewise.
39593         * modules/sysexits: Likewise.
39594         * modules/localcharset: Same as above, but continue using temporary
39595         file named "t-$@" (why different?) rather than the "$@-t" used
39596         everywhere else.
39597
39598         * modules/sysexits (Makefile.am): Replace literal occurrences
39599         of "sysexit.h" more readable, and more consistent, "$@".
39600
39601 2006-09-06  Bruno Haible  <bruno@clisp.org>
39602
39603         * modules/striconv: New file.
39604         * modules/xstriconv: New file.
39605         * MODULES.html.sh (Internationalization functions): Add striconv,
39606         xstriconv.
39607
39608 2006-09-06  Bruno Haible  <bruno@clisp.org>
39609
39610         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
39611         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
39612         not using libtool correctly.
39613
39614 2006-09-06  Bruno Haible  <bruno@clisp.org>
39615
39616         * lib/striconv.h: New file.
39617         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
39618         iconvstring.c.
39619         * lib/xstriconv.h: New file.
39620         * lib/xstriconv.c: New file.
39621
39622 2006-09-06  Bruno Haible  <bruno@clisp.org>
39623
39624         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
39625         lib_..._LDFLAGS.
39626
39627 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
39628
39629         * lib/argz_.h: Sync from Libtool.
39630
39631         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
39632                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
39633
39634         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
39635
39636 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
39637
39638         * modules/trim: New file.
39639
39640 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
39641
39642         * lib/trim.h: New file.
39643         * lib/trim.c: New file.
39644
39645 2006-09-05  Bruno Haible  <bruno@clisp.org>
39646
39647         * MODULES.html.sh (String handling): Add trim.
39648
39649 2006-09-04  Karl Berry  <karl@gnu.org>
39650
39651         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
39652         until next release.
39653
39654 2006-09-03  Bruno Haible  <bruno@clisp.org>
39655
39656         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
39657         correctly.
39658
39659 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
39660
39661         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
39662         not gl_GETLOADAVG.  Omit unneeded semicolons.
39663         Problems reported by Ralf Wildenhues in
39664         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
39665         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
39666         at the end, which is the usual gnulib style.
39667
39668         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
39669         of doing all the work ourselves.
39670         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
39671         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
39672
39673 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
39674
39675         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
39676         Problem reported by Ralf Wildenhues in
39677         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
39678
39679         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
39680         HAVE_STRUCT_STATFS_F_FSTYPENAME.
39681
39682 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
39683
39684         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
39685         yesterday's patch by changing test -n to test -z.
39686
39687 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
39688
39689         * modules/getloadavg (Files): Add m4/getloadavg.m4.
39690         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
39691         the former is now obsolescent.
39692
39693         * modules/chdir-long (Depends-on): Add fcntl.
39694
39695 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
39696
39697         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
39698         obsolescent, and programs should use gnulib instead.
39699         * m4/getloadavg.m4: New file, with contents taken from Autoconf
39700         but with prefixes changed.
39701
39702 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
39703
39704         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
39705         or stdbool.h, because they might not exist while configuring.
39706
39707         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
39708         Don't include unistd.h or limits.h; not needed, since chdir-long.h
39709         does that for us.
39710         (O_DIRECTORY): Remove.
39711
39712 2006-08-31  Eric Blake  <ebb9@byu.net>
39713
39714         * gnulib-tool: Don't let emacs change spaces to TAB.
39715
39716 2006-08-31  Bruno Haible  <bruno@clisp.org>
39717
39718         * gnulib-tool: When calling func_import more than once, do it in a
39719         subshell.
39720         Reported by Eric Blake <ebb9@byu.net>.
39721
39722 2006-08-31  Bruno Haible  <bruno@clisp.org>
39723
39724         * gnulib-tool (nl): Remove variable.
39725         (sed_transform_lib_file): Use more robust test for config-h module.
39726         (func_import): Fix typo in 2006-08-25 patch.
39727
39728 2006-08-31  Bruno Haible  <bruno@clisp.org>
39729
39730         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
39731         specified, augment Makefile.am variables instead of assigning them.
39732
39733 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
39734
39735         Work around a bug in both the Linux and SunOS 64-bit kernels:
39736         nanosleep mishandles sleeps for longer than 2**31 seconds.
39737         Problem reported by Frank v Waveren in
39738         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
39739         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
39740         Check for nanosleep bug.
39741         (LIB_NANOSLEEP): Append clock_gettime library if needed.
39742
39743 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
39744
39745         Work around a bug in both the Linux and SunOS 64-bit kernels:
39746         nanosleep mishandles sleeps for longer than 2**31 seconds.
39747         Problem reported by Frank v Waveren in
39748         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
39749         * lib/nanosleep.c (BILLION): New constant.
39750         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
39751         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
39752         implementation.
39753
39754 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
39755
39756         * modules/nanosleep (Depends-on): Add gettime.
39757
39758 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
39759         and Simon Josefsson  <jas@extundo.com>
39760         and Oskar Liljeblad  <oskar@osk.mine.nu>
39761
39762         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
39763         * gnulib-tool (func_import): New license type 'unmodifiable license
39764         text'.
39765         * modules/fdl: Use it.  Longer description.
39766         * module/gpl, module/lgpl: New files.
39767
39768 2006-08-30  Jim Meyering  <jim@meyering.net>
39769
39770         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
39771         shadowing the parameter.
39772
39773 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
39774
39775         Sync from Libtool:
39776
39777         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
39778
39779         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
39780         sharing with gnulib.  Report by Eric Blake.
39781
39782 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
39783
39784         * modules/isapipe: New file.
39785         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
39786
39787 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
39788
39789         * modules/configmake (Makefile.am): Add a comment, and omit
39790         the CONFIGMAKE_ prefix from generated macro names.  Suggested
39791         by Bruno Haible.
39792
39793 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
39794
39795         * m4/isapipe.m4: New file.
39796
39797 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
39798
39799         * lib/isapipe.c, lib/isapipe.h: New files.
39800
39801 2006-08-29  Jim Meyering  <jim@meyering.net>
39802
39803         * modules/configmake (Makefile.am): Make configmake.h depend on
39804         Makefile.  Otherwise, a stale configmake.h could hang around.
39805
39806 2006-08-29  Eric Blake  <ebb9@byu.net>
39807
39808         * lib/error.c (error_at_line, print_errno_message): Match libc, after
39809         resolution of upstream bug 3044.
39810
39811 2006-08-29  Bruno Haible  <bruno@clisp.org>
39812
39813         * modules/localcharset (Depends-on): Add configmake.
39814         (Makefile.am): Remove setting of LIBDIR through DEFS.
39815
39816 2006-08-29  Bruno Haible  <bruno@clisp.org>
39817
39818         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
39819         defined.
39820
39821 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
39822
39823         * modules/fcntl: New file.
39824         * modules/chdir-safer (Depends-on): Add fcntl.
39825         * modules/fts: Likewise.
39826         * modules/mkdir-p: Likewise.
39827
39828         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
39829         This undoes the most recent change, since we're now addressing the
39830         problem in a different way.
39831
39832         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
39833         into output, since the output might be called Makefile.am even
39834         if $makefile_name is something different.
39835         (func_import): Use $makefile_am rather than
39836         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
39837         empty.
39838
39839         * modules/inttypes (Files): Add m4/inttypes-h.m4.
39840
39841 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
39842
39843         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
39844         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
39845         recent change to stdint.m4, since we're now addressing the problem in a
39846         different way.
39847
39848 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
39849
39850         * m4/fcntl_h.m4: New file.
39851
39852 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
39853
39854         * lib/fcntl_.h: New file.
39855         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
39856         the fcntl module.
39857         * lib/dirchownmod.c: Likewise.
39858         * lib/fts.c: Likewise.
39859
39860         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
39861         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
39862         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
39863         just before including <inttypes.h>, to avoid circular inclusion.
39864
39865 2006-08-28  Jim Meyering  <jim@meyering.net>
39866
39867         * doc/visibility.texi: Actually read and correct the grammar of the
39868         sentence affected by yesterday's change.
39869
39870 2006-08-28  Eric Blake  <ebb9@byu.net>
39871
39872         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
39873         needs wrapper.
39874
39875 2006-08-28  Eric Blake  <ebb9@byu.net>
39876
39877         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
39878
39879 2006-08-28  Eric Blake  <ebb9@byu.net>
39880
39881         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
39882
39883 2006-08-28  Bruno Haible  <bruno@clisp.org>
39884
39885         * modules/c-strstr: New file, from GNU gettext.
39886         * MODULES.html.sh (String handling): Add c-strstr.
39887
39888 2006-08-28  Bruno Haible  <bruno@clisp.org>
39889
39890         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
39891         macros.
39892         Reported by Eric Blake.
39893
39894 2006-08-28  Bruno Haible  <bruno@clisp.org>
39895
39896         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
39897         (VASNPRINTF): Return a string of length > INT_MAX without failing.
39898         * lib/vasprintf.c: Include errno.h, limits.h.
39899         (EOVERFLOW): New fallback definition.
39900         (vasprintf): Test here whether the string length is > INT_MAX.
39901         * lib/vsnprintf.c: Include errno.h, limits.h.
39902         (EOVERFLOW): New fallback definition.
39903         (vsnprintf): Fix bug when generated string was too long for the buffer.
39904         Test here whether the string length is > INT_MAX.
39905
39906 2006-08-28  Bruno Haible  <bruno@clisp.org>
39907
39908         * lib/inttypes_.h (SCNX*): Remove definitions.
39909         Reported by Eric Blake.
39910
39911 2006-08-28  Bruno Haible  <bruno@clisp.org>
39912
39913         * lib/c-strstr.h: New file, from GNU gettext.
39914         * lib/c-strstr.c: New file, from GNU gettext.
39915
39916 2006-08-28  Bruno Haible  <bruno@clisp.org>
39917
39918         * gnulib-tool: Reorder some statements.
39919
39920 2006-08-28  Bruno Haible  <bruno@clisp.org>
39921
39922         * gnulib-tool: New option --makefile-name.
39923         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
39924         $makefile_name.
39925         (func_import): Write $makefile_name to the cache file, and read it from
39926         there unless explicitly specified. Use $makefile_name as file name
39927         instead of Makefile.am. Adjust the recommendations accordingly.
39928
39929 2006-08-28  Bruno Haible  <bruno@clisp.org>
39930
39931         * gnulib-tool (func_verify_module): Check against misapplying patch.
39932
39933 2006-08-28  Bruno Haible  <bruno@clisp.org>
39934
39935         * gnulib-tool (func_relativize, func_relconcat): New functions.
39936         Give an error if --local-dir is given with --update.
39937         Remove trailing slashes from $local_gnulib_dir.
39938         (func_import): Store the relativized $local_gnulib_dir in
39939         gnulib-cache.m4, and read it from there if not specified explicitly.
39940
39941 2006-08-28  Bruno Haible  <bruno@clisp.org>
39942
39943         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
39944         is the current directory. Respect also $local_gnulib_dir.
39945
39946 2006-08-28  Bruno Haible  <bruno@clisp.org>
39947             Simon Josefsson  <jas@extundo.com>
39948
39949         BeOS portability.
39950         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
39951
39952 2006-08-27  Jim Meyering  <jim@meyering.net>
39953
39954         * doc/visibility.texi: Remove duplicate word: "pointer".
39955
39956 2006-08-26  Bruno Haible  <bruno@clisp.org>
39957
39958         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
39959         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
39960         (Makefile.am): Create inttypes.h from inttypes_.h.
39961         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
39962
39963         * modules/imaxabs: New file.
39964
39965         * modules/imaxdiv: New file.
39966
39967 2006-08-26  Bruno Haible  <bruno@clisp.org>
39968
39969         * m4/inttypes.m4: New file.
39970         * m4/_inttypes_h.m4: Remove file.
39971         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
39972         PRI_MACROS_BROKEN.
39973         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
39974
39975         * m4/imaxabs.m4: New file.
39976
39977         * m4/imaxdiv.m4: New file.
39978
39979 2006-08-26  Bruno Haible  <bruno@clisp.org>
39980
39981         * lib/inttypes_.h: New file.
39982         * lib/inttypes.h: Remove file.
39983         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
39984
39985         * lib/imaxabs.c: New file.
39986
39987         * lib/imaxdiv.c: New file.
39988
39989 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
39990
39991         New config-h module, so that "make" output needn't be cluttered
39992         by -DHAVE_CONFIG_H.
39993         * MODULES.html.sh (Support for building libraries and executables):
39994         Add config-h.
39995         * modules/config-h: New file.
39996         * gnulib-tool (nl, sed_transform_lib_file): New vars.
39997         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
39998         the config-h module is used.
39999
40000         New configmake module, so that "make" output needn't be cluttered
40001         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
40002         * MODULES.html.sh (Support for building libraries and executables):
40003         Add configmake.
40004         * modules/configmake: New file.
40005
40006 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
40007
40008         * m4/config-h.m4: New file.
40009
40010 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
40011
40012         * config/srclist.txt: Add elisp-comp.
40013
40014 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
40015
40016         * MODULES.html.sh (Support for building libraries and executables):
40017         Add elisp-comp.
40018         * build-aux/elisp-comp: New file.
40019         * modules/elisp-comp: New file.
40020
40021 2006-08-24  Bruno Haible  <bruno@clisp.org>
40022
40023         * gnulib-tool (func_create_testdir): Use non-default values of
40024         sourcebase and m4base.
40025
40026 2006-08-24  Bruno Haible  <bruno@clisp.org>
40027
40028         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
40029         HTML structure.
40030
40031 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
40032
40033         * modules/openat (Depends-on): Add lchown.
40034
40035 2006-08-23  Bruno Haible  <bruno@clisp.org>
40036
40037         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
40038         of gl_LOCK_EARLY instead of gl_LOCK.
40039
40040 2006-08-23  Bruno Haible  <bruno@clisp.org>
40041
40042         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
40043         on OSF/1 to no.
40044         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
40045
40046 2006-08-23  Bruno Haible  <bruno@clisp.org>
40047
40048         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
40049         as unusable.
40050
40051         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
40052         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
40053         (gl_LOCK): New macro.
40054
40055 2006-08-22  Simon Josefsson  <jas@extundo.com>
40056
40057         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
40058         to md5 module.
40059
40060 2006-08-22  Simon Josefsson  <jas@extundo.com>
40061
40062         * MODULES.html.sh: Add "Support for maintaining and release
40063         projects".
40064
40065         * build-aux/gnupload: New file, from coreutils.
40066
40067 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
40068
40069         Avoid the need for AC_LIBSOURCES in m4 macros.
40070         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
40071         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
40072         * modules/check-version (EXTRA_DIST): Add check-version.h.
40073         * modules/crc (EXTRA_DIST): Add crc.h.
40074         * modules/des (EXTRA_DIST): Add des.h.
40075         * modules/gc (EXTRA_DIST): Add gc.h.
40076         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
40077         * modules/getline (EXTRA_DIST): Add getline.h.
40078         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
40079         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
40080         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
40081         * modules/md2 (EXTRA_DIST): Add md2.h.
40082         * modules/md4 (EXTRA_DIST): Add md4.h.
40083         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
40084         * modules/read-file (EXTRA_DIST): Add read-file.h.
40085         * modules/readline (EXTRA_DIST): Add readline.h.
40086         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
40087         rijndael-api-fst.h.
40088
40089 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
40090
40091         * m4/rijndael.m4 (gl_ARCFOUR):
40092         * m4/arctwo.m4 (gl_ARCTWO):
40093         * m4/check-version.m4 (gl_CHECK_VERSION):
40094         * m4/crc.m4 (gl_CRC):
40095         * m4/des.m4 (gl_DES):
40096         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
40097         * m4/gc.m4 (gl_GC):
40098         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
40099         * m4/getline.m4 (gl_FUNC_GETLINE):
40100         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
40101         * m4/hmac-md5.m4 (gl_HMAC_MD5):
40102         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
40103         * m4/md2.m4 (gl_MD2):
40104         * m4/md4.m4 (gl_MD4):
40105         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
40106         * m4/read-file.m4 (gl_FUNC_READ_FILE):
40107         * m4/readline.m4 (gl_FUNC_READLINE):
40108         * m4/rijndael.m4 (gl_RIJNDAEL):
40109         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
40110         to get the necessary .h files and whatnot.
40111
40112 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
40113
40114         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
40115         gnulib rather than the other way around.
40116         * config/srclistvars.sh (COREUTILS): Remove.
40117
40118 2006-08-22  Jim Meyering  <jim@meyering.net>
40119
40120         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
40121
40122         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
40123
40124 2006-08-22  Eric Blake  <ebb9@byu.net>
40125
40126         * modules/regexprops-generic: New file.
40127         * MODULES.html.sh (Support for building documentation): List it.
40128
40129 2006-08-22  Eric Blake  <ebb9@byu.net>
40130
40131         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
40132         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
40133         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
40134         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
40135
40136 2006-08-22  Bruno Haible  <bruno@clisp.org>
40137
40138         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
40139         and lib_LTLIBRARIES like the other lib_* variables.
40140
40141 2006-08-22  Bruno Haible  <bruno@clisp.org>
40142
40143         * build-aux/x-to-1.in: New file, from GNU gettext.
40144
40145 2006-08-22  Bruno Haible  <bruno@clisp.org>
40146
40147         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
40148         <utmpx.h> exists.
40149
40150 2006-08-22  Bruno Haible  <bruno@clisp.org>
40151
40152         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
40153         <utmpx.h> exists.
40154
40155 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
40156
40157         BeOS portability.
40158         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
40159         exist.
40160         Problem reported by Bruno Haible.
40161
40162 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
40163
40164         Avoid the need for AC_LIBSOURCES in m4 macros.
40165         * modules/acl (EXTRA_DIST): Add acl.h.
40166         * modules/argmatch (Files): Add m4/argmatch.m4.
40167         (configure.ac): Add gl_ARGMATCH.
40168         (EXTRA_DIST): Renamed from lib_SOURCES, for
40169         consistency with the other modules.  Remove argmatch.c.
40170         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
40171         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
40172         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
40173         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
40174         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
40175         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
40176         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
40177         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
40178         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
40179         * modules/closeout (EXTRA_DIST): Add closeout.h.
40180         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
40181         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
40182         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
40183         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
40184         dirname.h; remove basename.c and stripslash.c.
40185         * modules/exclude (EXTRA_DIST): Add exclude.h.
40186         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
40187         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
40188         * modules/file-type (EXTRA_DIST): Add file-type.h.
40189         * modules/filemode (EXTRA_DIST): Add filemode.h.
40190         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
40191         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
40192         * modules/fpending (EXTRA_DIST): Add __fpending.h.
40193         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
40194         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
40195         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
40196         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
40197         * modules/getdate (EXTRA_DIST): Add getdate.c.
40198         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
40199         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
40200         * modules/getpass (EXTRA_DIST): Add getpass.h.
40201         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
40202         * modules/group-member (EXTRA_DIST): Add group-member.h.
40203         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
40204         * modules/hash (EXTRA_DIST): Add hash.h.
40205         * modules/human (EXTRA_DIST): Add human.h.
40206         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
40207         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
40208         * modules/lchown (EXTRA_DIST): Add lchown.h.
40209         * modules/long-options (EXTRA_DIST): Add long-options.h.
40210         * modules/lstat (EXTRA_DIST): Add lstat.h.
40211         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
40212         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
40213         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
40214         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
40215         * modules/memxor (EXTRA_DIST): Add memxor.h.
40216         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
40217         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
40218         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
40219         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
40220         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
40221         * modules/physmem (EXTRA_DIST): Add physmem.h.
40222         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
40223         * modules/posixver (EXTRA_DIST): Add posixver.h.
40224         * modules/quote (EXTRA_DIST): Add quote.h.
40225         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
40226         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
40227         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
40228         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
40229         regex_internal.h regexec.c.
40230         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
40231         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
40232         * modules/same (EXTRA_DIST): Add same.h.
40233         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
40234         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
40235         * modules/savedir (EXTRA_DIST): Add savedir.h.
40236         * modules/sha1 (EXTRA_DIST): Add sha1.h.
40237         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
40238         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
40239         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
40240         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
40241         * modules/strdup (EXTRA_DIST): Add strdup.h.
40242         * modules/strftime (EXTRA_DIST): Add strftime.h.
40243         * modules/strndup (EXTRA_DIST): Add strndup.h.
40244         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
40245         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
40246         * modules/time_r (EXTRA_DIST): Add time_r.h.
40247         * modules/timespec (EXTRA_DIST): Add timespec.h.
40248         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
40249         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
40250         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
40251         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
40252         * modules/userspec (EXTRA_DIST): Add userspec.h.
40253         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
40254         * modules/utimens (EXTRA_DIST): Add utimens.h.
40255         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
40256         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
40257         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
40258         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
40259         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
40260         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
40261         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
40262         * modules/yesno (EXTRA_DIST): Add yesno.h.
40263
40264 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
40265
40266         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
40267
40268         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
40269         * m4/dev-ino.m4, same-inode.m4: Remove.
40270
40271         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
40272         * m4/acl.m4 (AC_FUNC_ACL):
40273         * m4/backupfile.m4 (gl_BACKUPFILE):
40274         * m4/c-strtod.m4 (gl_C99_STRTOLD):
40275         * m4/canon-host.m4 (gl_CANON_HOST):
40276         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
40277         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
40278         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
40279         * m4/cloexec.m4 (gl_CLOEXEC):
40280         * m4/close-stream.m4 (gl_CLOSE_STREAM):
40281         * m4/closeout.m4 (gl_CLOSEOUT):
40282         * m4/dirfd.m4 (gl_FUNC_DIRFD):
40283         * m4/dirname.m4 (gl_DIRNAME):
40284         * m4/exclude.m4 (gl_EXCLUDE):
40285         * m4/exitfail.m4 (gl_EXITFAIL):
40286         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
40287         * m4/file-type.m4 (gl_FILE_TYPE):
40288         * m4/filemode.m4 (gl_FILEMODE):
40289         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
40290         * m4/fpending.m4 (gl_FUNC_FPENDING):
40291         * m4/fprintftime.m4 (gl_FPRINTFTIME):
40292         * m4/fts.m4 (gl_FUNC_FTS):
40293         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
40294         * m4/getdate.m4 (gl_GETDATE):
40295         * m4/gethrxtime.m4 (gl_GETHRXTIME):
40296         * m4/getpagesize.m4 (gl_GETPAGESIZE):
40297         * m4/getpass.m4 (gl_FUNC_GETPASS):
40298         * m4/gettime.m4 (gl_GETTIME):
40299         * m4/getugroups.m4 (gl_GETUGROUPS):
40300         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
40301         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
40302         * m4/hard-locale.m4 (gl_HARD_LOCALE):
40303         * m4/hash.m4 (gl_HASH):
40304         * m4/idcache.m4 (gl_IDCACHE):
40305         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
40306         * m4/lchown.m4 (gl_FUNC_LCHOWN):
40307         * m4/long-options.m4 (gl_LONG_OPTIONS):
40308         * m4/lstat.m4 (gl_FUNC_LSTAT):
40309         * m4/md5.m4 (gl_MD5):
40310         * m4/memcasecmp.m4 (gl_MEMCASECMP):
40311         * m4/memcoll.m4 (gl_MEMCOLL):
40312         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
40313         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
40314         * m4/memxor.m4 (gl_MEMXOR):
40315         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
40316         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
40317         * m4/modechange.m4 (gl_MODECHANGE):
40318         * m4/mountlist.m4 (gl_MOUNTLIST):
40319         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
40320         * m4/openat.m4 (gl_FUNC_OPENAT):
40321         * m4/pathmax.m4 (gl_PATHMAX):
40322         * m4/physmem.m4 (gl_PHYSMEM):
40323         * m4/posixtm.m4 (gl_POSIXTM):
40324         * m4/posixver.m4 (gl_POSIXVER):
40325         * m4/quote.m4 (gl_QUOTE):
40326         * m4/quotearg.m4 (gl_QUOTEARG):
40327         * m4/readtokens.m4 (gl_READTOKENS):
40328         * m4/readutmp.m4 (gl_READUTMP):
40329         * m4/regex.m4 (gl_REGEX):
40330         * m4/safe-read.m4 (gl_SAFE_READ):
40331         * m4/safe-write.m4 (gl_SAFE_WRITE):
40332         * m4/same.m4 (gl_SAME):
40333         * m4/save-cwd.m4 (gl_SAVE_CWD):
40334         * m4/savedir.m4 (gl_SAVEDIR):
40335         * m4/settime.m4 (gl_SETTIME):
40336         * m4/sha1.m4 (gl_SHA1):
40337         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
40338         * m4/stat-macros.m4 (gl_STAT_MACROS):
40339         * m4/stat-time.m4 (gl_STAT_TIME):
40340         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
40341         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
40342         * m4/strdup.m4 (gl_FUNC_STRDUP):
40343         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
40344         * m4/strndup.m4 (gl_FUNC_STRNDUP):
40345         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
40346         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
40347         * m4/time_r.m4 (gl_TIME_R):
40348         * m4/timespec.m4 (gl_TIMESPEC):
40349         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
40350         * m4/unlinkdir.m4 (gl_UNLINKDIR):
40351         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
40352         * m4/userspec.m4 (gl_USERSPEC):
40353         * m4/utimecmp.m4 (gl_UTIMECMP):
40354         * m4/utimens.m4 (gl_UTIMENS):
40355         * m4/xalloc.m4 (gl_XALLOC):
40356         * m4/xgetcwd.m4 (gl_XGETCWD):
40357         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
40358         * m4/xreadlink.m4 (gl_XREADLINK):
40359         * m4/xstrtod.m4 (gl_XSTRTOD):
40360         * m4/yesno.m4 (gl_YESNO):
40361         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
40362         to get the necessary .h files and whatnot.
40363
40364 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
40365             Bruno Haible  <bruno@clisp.org>
40366
40367         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
40368         /bin/sh understanding of '!' conditional negation.
40369
40370 2006-08-21  Jim Meyering  <jim@meyering.net>
40371
40372         * modules/openat (Depends-on): Really alphabetize.
40373
40374         * modules/acl (Depends-on): Add error and quote.
40375
40376         * check-module (find_included_lib_files): Add at-func.c to the
40377         ok-to-include-more-than-once white list.
40378
40379         * modules/openat (Depends-on): Add lstat.  Alphabetize.
40380
40381 2006-08-21  Bruno Haible  <bruno@clisp.org>
40382
40383         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
40384         Emit a pkgdata_DATA variable only if some snippets add contents to it.
40385         Reported by Martin Lambers <marlam@marlam.de>.
40386
40387 2006-08-21  Bruno Haible  <bruno@clisp.org>
40388
40389         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
40390         specify an installation location, don't emit a noinst_LIBRARIES or
40391         noinst_LTLIBRARIES assignment.
40392
40393 2006-08-21  Bruno Haible  <bruno@clisp.org>
40394
40395         BeOS portability.
40396         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
40397         BeOS has mbrtowc() but no <wctype.h>.
40398
40399 2006-08-21  Bruno Haible  <bruno@clisp.org>
40400
40401         BeOS portability.
40402         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
40403         exist.
40404
40405 2006-08-21  Bruno Haible  <bruno@clisp.org>
40406
40407         BeOS portability.
40408         * lib/mbchar.h: Include <wctype.h> only if it exists.
40409
40410 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
40411
40412         Remove files that are no longer needed by their respective modules.
40413         * m4/obstack.m4: Remove.
40414         * m4/strerror_r.m4: Remove.
40415         * m4/uint32_t.m4: Remove.
40416         * m4/uintptr_t.m4: Remove.
40417         * m4/ullong_max.m4: Remove.
40418         * m4/xstrtoimax.m4: Remove.
40419         * m4/xstrtoumax.m4: Remove.
40420
40421         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
40422         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
40423         dependencies now capture this.
40424
40425         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
40426         Do not use AC_LIBSOURCES, since gnulib modules now do this.
40427         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
40428         * m4/human.m4 (gl_HUMAN): Likewise.
40429         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
40430         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
40431
40432         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
40433
40434         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
40435         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
40436         stdint.
40437         * m4/human.m4 (gl_HUMAN): Likewise.
40438         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
40439         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
40440         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
40441         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
40442         * m4/xstrtol (gl_XSTRTOL): Likewise.
40443
40444         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
40445         AC_TYPE_LONG_LONG_INT.
40446         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
40447         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
40448         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
40449         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
40450
40451         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
40452         on stdbool.
40453
40454         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
40455         (gl_PREREQ_XSTRTOUL): Remove.
40456
40457         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
40458
40459         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
40460         mode.
40461
40462 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
40463
40464         Add and change modules to make it easier for coreutils to use
40465         gnulib-tool.
40466         * modules/backupfile (Files): Remove m4/d-ino.m4.
40467         (Depends-on): Add d-ino.
40468         * modules/cycle-check (Depends-on): Add stdint.
40469         (lib_SOURCES): Add cycle-check.h.
40470         * modules/d-ino: New module.
40471         * modules/d-type: New module.
40472         * modules/error (Files): Remove m4/strerror_r.m4.
40473         * modules/filemode (Files): Add m4/st_dm_mode.m4.
40474         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
40475         m4/inttypes_h.m4, m4/uintmax_t.m4.
40476         (Depends-on): Add stdint.
40477         (lib_SOURCES): Add fsusage.h.
40478         * modules/getcwd (Files): Remove d-ino.m4.
40479         (Depends-on): Add d-ino.
40480         * modules/getndelim2 (Depends-on): Add stdint.
40481         * modules/glob (Files): Remove m4/d-type.m4.
40482         (Depends-on): Add d-type.
40483         * modules/host-os: New module.
40484         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
40485         m4/inttypes_h.m4, m4/uintmax_t.m4.
40486         * Depends-on: Add stdint.
40487         (lib_SOURCES): Add human.h.
40488         * modules/inttostr (Files): Remove m4/intmax_t.m4,
40489         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
40490         m4/uintmax_t.m4, m4/ulonglong.m4.
40491         (Depends-on): Add stdint.
40492         (EXTRA_DIST): Add inttostr.h.
40493         * modules/lchmod: New module.
40494         * modules/link-follow: New module.
40495         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
40496         (Depends-on): Add lchmod.
40497         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
40498         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
40499         (Depends-on): Add stdint.
40500         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
40501         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
40502         (Depends-on): Add stdint.
40503         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
40504         * modules/perl: New module.
40505         * modules/regex (Depends-on): Add stdint.
40506         * modules/rmdir-errno: New module.
40507         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
40508         m4/intmax_t.m4.
40509         (Depends-on): Add stdint.
40510         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
40511         m4/uintmax_t.m4.
40512         (Depends-on): Add stdint.
40513         * modules/unlink-busy: New module.
40514         * modules/utimecmp (Depends-on): Add stdint.
40515         * modules/uptime: New module.
40516         * modules/winsz-ioctl: New module.
40517         * modules/winsz-termios: New module.
40518         * modules/xnanosleep (Depends-on): Add nanosleep.
40519         * modules/ullong_max: Remove.
40520         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
40521         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
40522         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
40523         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
40524         (Depends-on): Add inttypes.
40525         (lib_SOURCES): Add xstrtol.h.
40526         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
40527         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
40528         * MODULES.html.sh: Move 'assert' into the assert section.
40529         Move 'dummy' into the linking section.
40530         Remove ullong_max.
40531         Add section for compatibility checks for POSIX:2001 functions,
40532         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
40533         winsz-ioctl, and winsz-termios into it.
40534         Add lchmod.
40535         Add top-level Misc section and put host-os, perl, and uptime
40536         into it.
40537
40538 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
40539
40540         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
40541         now assume the stdint module.  Do not include inttypes.h.
40542         * lib/fsusage.h: Likewise.
40543         * lib/getndelim2.c: Likewise.
40544         * lib/human.h: Likewise.
40545         * lib/inttostr.h: Likewise.
40546         * lib/obstack.c: Likewise.
40547         * lib/regex_internal.h: Likewise.
40548         * lib/tempname.c: Likewise.
40549         * lib/utimecmp.c: Likewise.
40550         * lib/xstrtol.h: Likewise.
40551
40552         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
40553
40554         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
40555         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
40556         * lib/xtime.h: Likewise.
40557
40558 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
40559
40560         * modules/openat (Files): Add lib/fchmodat.c.
40561         Fixes problem reported by Jay Youngman.
40562
40563 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
40564
40565         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
40566         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
40567
40568 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
40569             Bruno Haible  <bruno@clisp.org>
40570
40571         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
40572         and is a script that invokes bison. Tighten the code. Add comments.
40573
40574 2006-08-18  Jim Meyering  <jim@meyering.net>
40575
40576         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
40577         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
40578         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
40579         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
40580
40581 2006-08-18  Bruno Haible  <bruno@clisp.org>
40582
40583         * modules/bison-i18n: New file.
40584         * MODULES.html.sh (Internationalization functions): Add it.
40585
40586 2006-08-18  Bruno Haible  <bruno@clisp.org>
40587
40588         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
40589         sys/statvfs.h. When getmntinfo was found, check its declaration and
40590         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
40591
40592 2006-08-18  Bruno Haible  <bruno@clisp.org>
40593
40594         * m4/bison-i18n.m4: New file, from bison.
40595
40596 2006-08-18  Bruno Haible  <bruno@clisp.org>
40597
40598         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
40599         (ME_DUMMY): Treat "kernfs" as a dummy.
40600         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
40601
40602 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
40603
40604         Update from coreutils.
40605
40606         2006-08-15  Jim Meyering  <jim@meyering.net>
40607
40608         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
40609
40610         2006-01-17  Jim Meyering  <jim@meyering.net>
40611
40612         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
40613
40614         2006-01-11  Jim Meyering  <jim@meyering.net>
40615
40616         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
40617         Check for the lchmod function.
40618
40619 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
40620
40621         Update from coreutils.
40622
40623         * lib/__fpending.h: Add copyright notice.
40624         * lib/fprintftime.h: Likewise.
40625         * lib/savedir.c: Use (C) in copyright notice.
40626         * lib/savedir.h: Likewise.
40627
40628         2006-08-15  Jim Meyering  <jim@meyering.net>
40629
40630         * lib/at-func.c: New file, with the logic of all emulated at-functions.
40631         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
40632         in support of the EXPECTED_ERRNO macro.
40633         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
40634         definitions.  Instead, define the appropriate symbols and include
40635         "at-func.c".
40636         * lib/mkdirat.c (mkdirat): Likewise.
40637         * lib/fchmodat.c (fchmodat): Likewise.
40638         (ENOSYS): Remove definition.
40639         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
40640         it.  Don't include "unistd--.h" -- it wasn't ever used.
40641
40642         2006-01-17  Jim Meyering  <jim@meyering.net>
40643
40644         Rewrite fts.c not to change the current working directory,
40645         by using openat, fstatat, fdopendir, etc..
40646
40647         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
40648         (HAVE_OPENAT_SUPPORT): Define.
40649         [_LIBC] (fchdir): Don't undef or define; no longer used.
40650         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
40651         Now, this `function' always succeeds, and consumes its file descriptor
40652         parameter -- so callers must not close such FDs.  Update callers.
40653         (diropen_fd, opendirat, cwd_advance_fd): New functions.
40654         (diropen): Add parameter, SP.  Adjust all callers.
40655         Implement using diropen_fd, rather than open.
40656         (fts_open): Initialize new member, fts_cwd_fd.
40657         Remove fts_rft-setting code.
40658         (fts_close): Close fts_cwd_fd, if necessary.
40659         (__opendir2): Define in terms of opendir or opendirat,
40660         depending on whether the FST_NOCHDIR flag is set.
40661         (fts_build): Since fts_safe_changedir consumes its FD, and since
40662         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
40663         and close the dup'd file descriptor upon failure.
40664         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
40665         (fts_safe_changedir): Tweak semantics to reflect that this function
40666         now calls cwd_advance_fd and hence consumes its FD argument.
40667         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
40668         [struct FTS] (fts_rft): Remove now-unused member.
40669         [struct FTS] (fts_cycle.state): Improve comment.
40670
40671         * lib/openat.c (openat_needs_fchdir): New function.
40672         * lib/openat.h (openat_needs_fchdir): Declare it.
40673
40674 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
40675
40676         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
40677         Problem and fix reported by Pádraig Brady in
40678         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
40679
40680 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
40681
40682         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
40683
40684 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
40685
40686         * lib/memcoll.c (memcoll): Optimize for the common case where the
40687         arguments are bytewise equal.
40688
40689 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
40690
40691         * doc/regexprops-generic.texi: Add a copyright notice.
40692
40693 2006-08-15  Bruno Haible  <bruno@clisp.org>
40694
40695         * modules/tmpdir (License): Change to LGPL.
40696
40697 2006-08-15  Bruno Haible  <bruno@clisp.org>
40698
40699         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
40700         module.
40701
40702 2006-08-14  Simon Josefsson  <jas@extundo.com>
40703
40704         * config/srclist.txt: Add gnupload.
40705
40706 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
40707
40708         Change copyright notice from LGPL 2 to GPL 2, since that's the
40709         standard form used in the gnulib repository.
40710         * tests/test-lock.c: Likewise.
40711         * tests/test-stdint.c: Likewise.
40712         * tests/test-tls.c: Likewise.
40713
40714         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
40715         prelude-manager.  User shorter URLs for GNU projects, without '?'.
40716         Add copyright notice.
40717
40718         * check-module: Add copyright notice.  Output a copyright
40719         notice if "--version" is specified.
40720         * modules/COPYING: New file.
40721         * tests/test-getaddrinfo.c: Add copyright notice.
40722         * tests/test-verify.c: Likewise.
40723
40724 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
40725
40726         Change copyright notice from LGPL 2 to GPL 2, since that's the
40727         standard form used in the gnulib repository.
40728         * lib/lock.c: LGPL -> GPL.
40729         * lib/lock.h: Likewise.
40730         * lib/strnlen1.c: Likewise.
40731         * lib/strnlen1.h: Likewise.
40732         * lib/tls.c: Likewise.
40733         * lib/tls.h: Likewise.
40734         * lib/tmpdir.c: Likewise.
40735
40736         * lib/TODO: Remove; this belongs only in coreutils.
40737
40738 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
40739
40740         Add copyright notices to long-enough files that lack them, since
40741         otherwise the files aren't clearly free.  Use the same notice that
40742         getdate.texi already uses.
40743         * doc/alloca-opt.texi: Add copyright notice.
40744         * doc/alloca.texi: Likewise.
40745         * doc/ctime.texi: Likewise.
40746         * doc/functions.texi: Likewise.
40747         * doc/gcd.texi: Likewise.
40748         * doc/gnulib-tool.texi: Likewise.
40749         * doc/inet_ntoa.texi: Likewise.
40750         * doc/visibility.texi: Likewise.
40751
40752         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
40753         * doc/quote.texi: Add copyright notice.
40754
40755         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
40756         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
40757         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
40758         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
40759         is now obsolete, and give a pointer to the Sun list.
40760         Add copyright notice.
40761
40762 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
40763
40764         * config/srclistvars.sh: Add copyright notice.
40765
40766 2006-08-14  Eric Blake  <ebb9@byu.net>
40767
40768         Import the following change from libc:
40769
40770         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
40771
40772         Upstream bug 2997.
40773         * lib/misc/error.c: Add space between program name and message if file
40774         name is missing.
40775
40776 2006-08-12  Karl Berry  <karl@gnu.org>
40777
40778         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
40779         remove, these originate in gnulib now.
40780
40781 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
40782
40783         * doc/Makefile (standards.info standards.html standards.dvi):
40784         Also depend on make-stds.texi.
40785
40786 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
40787
40788         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
40789         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
40790
40791         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
40792         in wchar_t.  Problem reported by Eric Blake.
40793
40794         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
40795         LEN is smaller than SIZE.  Suggested by Bruno Haible.
40796         Also, help the compiler to keep LEN in a register.
40797
40798 2006-08-11  Eric Blake  <ebb9@byu.net>
40799
40800         * users.txt: Sort.  Add tar.
40801
40802 2006-08-11  Bruno Haible  <bruno@clisp.org>
40803
40804         * users.txt: New file.
40805
40806 2006-08-11  Bruno Haible  <bruno@clisp.org>
40807
40808         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
40809         before <wchar.h>. Needed for OSF/1 and BSD/OS.
40810
40811 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
40812
40813         * modules/snprintf (Depends-on): Remove minmax.
40814         (Maintainer): Add self and Bruno.
40815
40816 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
40817
40818         * lib/.cppi-disable: Add snprintf.h, socket_.h.
40819         * lib/snprintf.c: Include <errno.h> and <limits.h>.
40820         (EOVERFLOW): Define if the system does not.
40821         Do not include "minmax.h"; it wasn't used.
40822         (snprintf): Don't assume size_t promotes to an unsigned type.
40823         Fix bug when generated string was too long for the buffer: the
40824         buffer's contents are supposed to be the initial prefix of the
40825         output.  Don't assume vasnprintf returns EOVERFLOW if the size
40826         exceeds INT_MAX; do the check ourselves.
40827
40828         Import the following changes from libc:
40829
40830         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
40831
40832         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
40833         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
40834         set wc to the byte which couldn't be converted.
40835         (re_string_reconstruct): Don't clear valid_raw_len before calling
40836         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
40837         tip_context using re_string_context_at.
40838
40839         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
40840
40841         * lib/posix/regex.h: g++ still cannot handled [restrict].
40842
40843         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
40844
40845         * lib/posix/regex.h: Remove special handling for VMS.
40846
40847 2006-08-10  Jim Meyering  <jim@meyering.net>
40848
40849         * modules/same-inode: New module.
40850         * modules/dev-ino: New module.
40851         * modules/cycle-check: Depend on these modules, rather than simply
40852         including their .h files.
40853         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
40854         required via m4/cycle-check.m4.
40855         * modules/same: Depend on new same-inode module, rather than
40856         including same-inode.h.
40857         * modules/chdir-safer: New file.
40858
40859         * modules/chown (Depends-on): Add stat-macros.
40860
40861 2006-08-10  Jim Meyering  <jim@meyering.net>
40862
40863         * m4/cycle-check.m4: New file.
40864         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
40865         * m4/dev-ino.m4, m4/same-inode.m4: New files.
40866
40867 2006-08-10  Eric Blake  <ebb9@byu.net>
40868
40869         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
40870         in from original proposal.
40871
40872 2006-08-10  Eric Blake  <ebb9@byu.net>
40873         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
40874
40875         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
40876         namespace.
40877
40878 2006-08-10  Bruno Haible  <bruno@clisp.org>
40879
40880         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
40881         as well.
40882
40883 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
40884
40885         Sync from coreutils.
40886
40887         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
40888
40889         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
40890         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
40891
40892 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
40893
40894         * modules/restrict: Remove; no longer needed now that we assume
40895         Autoconf 2.59 or later.
40896         * MODULES.html.sh: Remove 'restrict'.
40897         * modules/argp (Depends-on): Remove 'restrict'.
40898         * modules/base64 (Depends-on): Likewise.
40899         * modules/gc (Depends-on): Likewise.
40900         * modules/getaddrinfo (Depends-on): Likewise.
40901         * modules/glob (Depends-on): Likewise.
40902         * modules/inet_ntop (Depends-on): Likewise.
40903         * modules/inet_pton (Depends-on): Likewise.
40904         * modules/memxor (Depends-on): Likewise.
40905         * modules/regex (Depends-on): Likewise.
40906         * modules/strtok_r (Depends-on): Likewise.
40907         * modules/time_r (Depends-on): Likewise.
40908
40909 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
40910
40911         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
40912         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
40913         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
40914         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
40915         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
40916         * m4/memxor.m4 (gl_MEMXOR): Likewise.
40917         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
40918         gl_C_RESTRICT replaced by AC_C_RESTRICT.
40919
40920         Merge from coreutils.
40921         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
40922         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
40923         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
40924         * m4/time_r.m4 (gl_TIME_R): Likewise.
40925
40926 2006-08-09  Karl Berry  <karl@gnu.org>
40927
40928         * config/srclist.txt: no more gettext-tools, per Bruno.
40929
40930 2006-08-08  Eric Blake  <ebb9@byu.net>
40931
40932         * modules/verror: New module.
40933         * MODULES.html.sh: Document it.
40934
40935 2006-08-08  Eric Blake  <ebb9@byu.net>
40936
40937         * lib/verror.h, lib/verror.c: New files.
40938
40939 2006-08-08  Eric Blake  <ebb9@byu.net>
40940
40941         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
40942         verror_at_line output complies with GNU Coding Standards even when
40943         file is NULL.
40944
40945 2006-08-07  Bruno Haible  <bruno@clisp.org>
40946
40947         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
40948         versions of AIX.
40949         Reported by Ralf Wildenhues.
40950
40951 2006-08-07  Bruno Haible  <bruno@clisp.org>
40952
40953         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
40954         in an AC_DEFUN. Needed so that the autoconf snippets can use
40955         AC_REQUIRE.
40956
40957 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
40958
40959         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
40960         Initialize pkgdata_DATA.
40961         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
40962         overriding it.
40963
40964 2006-08-06  Eric Blake  <ebb9@byu.net>
40965
40966         * lib/error.h: Fold in some upstream changes from glibc.
40967         * lib/error.c: Likewise.
40968
40969 2006-08-04  Bruno Haible  <bruno@clisp.org>
40970
40971         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
40972         Make the mostlyclean-local rule depend on mostlyclean-generic.
40973         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
40974
40975 2006-07-31  Bruno Haible  <bruno@clisp.org>
40976
40977         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
40978         <stdlib.h>, <string.h>.
40979
40980 2006-07-30  Bruno Haible  <bruno@clisp.org>
40981
40982         * modules/readlink (License): Change to LGPL.
40983
40984 2006-07-30  Bruno Haible  <bruno@clisp.org>
40985
40986         * modules/javaversion (Makefile.am): Distribute javaversion.java and
40987         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
40988         set PKGDATADIR to point to it.
40989
40990 2006-07-30  Bruno Haible  <bruno@clisp.org>
40991
40992         * modules/csharpexec (configure.ac): Comment out macro invocation.
40993         * modules/javaexec (configure.ac): Likewise.
40994         * modules/javacomp-script (configure.ac): Likewise.
40995
40996         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
40997
40998 2006-07-30  Bruno Haible  <bruno@clisp.org>
40999
41000         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
41001         linked-list.
41002
41003 2006-07-30  Bruno Haible  <bruno@clisp.org>
41004
41005         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
41006
41007 2006-07-30  Bruno Haible  <bruno@clisp.org>
41008
41009         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
41010         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
41011         get removed.
41012
41013 2006-07-29  Bruno Haible  <bruno@clisp.org>
41014
41015         Make it possible for gnulib-tool to work with locally modified or
41016         augmented gnulib repositories.
41017         * gnulib-tool (func_usage): Document --local-dir option.
41018         (local_gnulib_dir): New variable.
41019         Handle --local-dir option.
41020         (func_lookup_file): New function.
41021         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
41022         (func_get_description, func_get_filelist, func_get_description,
41023         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
41024         func_get_automake_snippet, func_get_include_directive,
41025         func_get_license, func_get_maintainer): Use func_lookup_file.
41026         (func_import, func_create_testdir): Use func_lookup_file.
41027
41028 2006-07-29  Bruno Haible  <bruno@clisp.org>
41029
41030         * modules/setenv (Depends-on): Add unistd.
41031
41032 2006-07-29  Bruno Haible  <bruno@clisp.org>
41033
41034         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
41035
41036 2006-07-29  Bruno Haible  <bruno@clisp.org>
41037
41038         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
41039
41040 2006-07-29  Bruno Haible  <bruno@clisp.org>
41041
41042         * gnulib-tool (import, update): If there is no Makefile.am, look at
41043         aclocal.m4, instead of bailing out.
41044
41045 2006-07-29  Bruno Haible  <bruno@clisp.org>
41046
41047         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
41048         Categorize the options by when they are useful.
41049
41050 2006-07-29  Bruno Haible  <bruno@clisp.org>
41051
41052         * gnulib-tool (func_usage): Document option --no-libtool.
41053         Handle option --no-libtool.
41054         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
41055         for changed semantics of $libtool variable.
41056         (func_import): Likewise. If libtool is not used, show this through
41057         an option --no-libtool.
41058         (func_create_testdir): Update.
41059
41060 2006-07-29  Bruno Haible  <bruno@clisp.org>
41061
41062         * gnulib-tool (func_import): Extend error message about missing
41063         --doc-base.
41064
41065 2006-07-29  Bruno Haible  <bruno@clisp.org>
41066
41067         * gnulib-tool (func_import): Don't create the $docbase directory if
41068         there is no file to store there.
41069
41070 2006-07-29  Bruno Haible  <bruno@clisp.org>
41071
41072         * gnulib-tool (autoconf_minversion): If a --dir option is given and
41073         relevant, look for configure.ac there, not in the current directory.
41074         Also use a simple search for AC_PREREQ, not "autoconf --trace".
41075
41076 2006-07-29  Bruno Haible  <bruno@clisp.org>
41077
41078         * gnulib-tool (SORT): New variable.
41079         (func_usage): Undocument --assume-autoconf option.
41080         Remove --assume-autoconf option handling.
41081         (autoconf_minversion): Determine from the contents of configure.ac.
41082         (func_import): Remove autoconf_minversion handling.
41083         Suggested by Eric Blake.
41084
41085 2006-07-29  Bruno Haible  <bruno@clisp.org>
41086
41087         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
41088
41089 2006-07-29  Bruno Haible  <bruno@clisp.org>
41090
41091         * config/srclist.txt (*setenv.[ch]): Remove rules.
41092
41093 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
41094
41095         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
41096
41097 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
41098
41099         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
41100         arpa/inet.h.
41101
41102 2006-07-28  Simon Josefsson  <jas@extundo.com>
41103
41104         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
41105         * modules/inet_pton (Depends-on): Likewise.
41106
41107 2006-07-28  Simon Josefsson  <jas@extundo.com>
41108
41109         * m4/netinet_in_h.m4: New file.
41110
41111 2006-07-28  Simon Josefsson  <jas@extundo.com>
41112
41113         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
41114         #include's.
41115
41116 2006-07-28  Simon Josefsson  <jas@extundo.com>
41117
41118         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
41119         #include's.
41120
41121 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
41122
41123         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
41124         setgid on directories only if they set these bits.
41125         * lib/modechange.h: Remove obsolete comment about masks.
41126
41127 2006-07-28  Eric Blake  <ebb9@byu.net>
41128
41129         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
41130         macro expansion.
41131
41132 2006-07-28  Bruno Haible  <bruno@clisp.org>
41133
41134         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
41135
41136 2006-07-28  Bruno Haible  <bruno@clisp.org>
41137
41138         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
41139
41140 2006-07-28  Bruno Haible  <bruno@clisp.org>
41141
41142         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
41143         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
41144         Define fallbacks.
41145         Avoids link error on FreeBSD 4.x.
41146         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
41147
41148         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
41149         encoding.
41150         * lib/mbswidth.c (iswcntrl): Likewise.
41151
41152 2006-07-27  Bruno Haible  <bruno@clisp.org>
41153
41154         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
41155         test.
41156
41157 2006-07-27  Bruno Haible  <bruno@clisp.org>
41158
41159         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
41160         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
41161         defined.
41162
41163 2006-07-26  Eric Blake  <ebb9@byu.net>
41164
41165         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
41166
41167 2006-07-26  Eric Blake  <ebb9@byu.net>
41168
41169         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
41170         like mingw that lack mkstemp.
41171         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
41172         avoid compilation warning on mingw.
41173
41174 2006-07-26  Bruno Haible  <bruno@clisp.org>
41175
41176         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
41177         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
41178         INT_FAST*_MIN, INTPTR_MIN.
41179
41180 2006-07-25  Bruno Haible  <bruno@clisp.org>
41181
41182         * modules/version-etc (Depends-on): Add stdarg.
41183
41184 2006-07-25  Bruno Haible  <bruno@clisp.org>
41185
41186         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
41187         complex commands.
41188
41189 2006-07-25  Bruno Haible  <bruno@clisp.org>
41190
41191         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
41192         defined in <stdarg.h> or config.h.
41193
41194 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
41195
41196         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
41197         (gl_STDIO_SAFER): Remove.
41198
41199 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
41200
41201         * MODULES.html.sh (File stream based Input/Output):
41202         Add fopen-safer, tmpfile-safer; remove stdio-safer.
41203         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
41204         * modules/fopen-safer, modules/tmpfile-safer: New files.
41205         * modules/stdio-safer: Remove.
41206
41207 2006-07-24  Bruno Haible  <bruno@clisp.org>
41208
41209         * modules/tmpdir: New file.
41210         * MODULES.html.sh (File system functions): Add it.
41211
41212 2006-07-24  Bruno Haible  <bruno@clisp.org>
41213
41214         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
41215         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
41216
41217 2006-07-24  Bruno Haible  <bruno@clisp.org>
41218
41219         * modules/clean-temp: New file.
41220
41221 2006-07-24  Bruno Haible  <bruno@clisp.org>
41222
41223         * m4/tmpdir.m4: New file, from GNU gettext.
41224
41225 2006-07-24  Bruno Haible  <bruno@clisp.org>
41226
41227         * lib/tmpdir.h: New file, from GNU gettext.
41228         * lib/tmpdir.c: New file, from GNU gettext.
41229
41230 2006-07-24  Bruno Haible  <bruno@clisp.org>
41231
41232         * lib/clean-temp.h: New file, from GNU gettext.
41233         * lib/clean-temp.c: New file, from GNU gettext.
41234
41235 2006-07-23  Eric Blake  <ebb9@byu.net>
41236
41237         * modules/stdio-safer (Files): Add tmpfile-safer.c.
41238         (Depends-on): Add binary-io.
41239
41240 2006-07-23  Eric Blake  <ebb9@byu.net>
41241
41242         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
41243
41244 2006-07-23  Eric Blake  <ebb9@byu.net>
41245
41246         * lib/tmpfile-safer.c: New file.
41247         * lib/stdio-safer.h (fopen_safer): Add prototype.
41248         * lib/stdio--.h (tmpfile): Make safer.
41249
41250 2006-07-23  Bruno Haible  <bruno@clisp.org>
41251
41252         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
41253         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
41254         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
41255         gl_linked_remove_at): Use it.
41256
41257 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
41258         and Simon Josefsson <jas@extundo.com>
41259
41260         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
41261
41262         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
41263
41264 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
41265
41266         * modules/close-stream: New file.
41267         * modules/closeout (Description): Make it clear that it exits
41268         with a diagnostic on error.
41269         (Depends-on): Add close-stream.  Remove fpending, stdbool.
41270         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
41271
41272 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
41273
41274         * m4/close-stream.m4: New file.
41275
41276 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
41277
41278         * lib/close-stream.c, lib/close-stream.h: New files.
41279
41280 2006-07-22  Bruno Haible  <bruno@clisp.org>
41281
41282         Merge from GNU gettext 0.15.
41283
41284         2006-05-01  Bruno Haible  <bruno@clisp.org>
41285
41286                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
41287
41288         2006-07-22  Bruno Haible  <bruno@clisp.org>
41289
41290                 * modules/javaversion: New file.
41291                 * MODULES.html.sh (Java): Add javaversion.
41292
41293         2006-03-12  Bruno Haible  <bruno@clisp.org>
41294
41295                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
41296
41297         2005-12-04  Bruno Haible  <bruno@clisp.org>
41298
41299                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
41300                 (untested).
41301
41302         2006-06-21  Bruno Haible  <bruno@clisp.org>
41303
41304                 Avoid warnings from recent versions of mcs.
41305                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
41306                 -o, -L, -r any more. Use options documented since mcs-1.0
41307                 instead. Similarly for -g.
41308
41309         2005-12-04  Bruno Haible  <bruno@clisp.org>
41310
41311                 * build-aux/csharpcomp.sh.in: Suffix for resources is
41312                 .resources, not .resource.
41313
41314         2005-07-09  Bruno Haible  <bruno@clisp.org>
41315
41316                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
41317                 add a .dll suffix.
41318                 Reported by Mark Junker <mjscod@gmx.de>.
41319
41320         2006-07-22  Bruno Haible  <bruno@clisp.org>
41321
41322                 * modules/gettext: Upgrade to gettext-0.15.
41323                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
41324                 m4/visibility.m4.
41325                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
41326
41327 2006-07-22  Bruno Haible  <bruno@clisp.org>
41328
41329         Merge from GNU gettext 0.15.
41330
41331         2006-03-25  Bruno Haible  <bruno@clisp.org>
41332
41333                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
41334
41335         2006-07-21  Bruno Haible  <bruno@clisp.org>
41336
41337                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
41338                 "1.1".
41339
41340         2006-05-09  Bruno Haible  <bruno@clisp.org>
41341
41342                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
41343                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
41344                 for the conftestver execution.
41345
41346         2006-05-01  Bruno Haible  <bruno@clisp.org>
41347
41348                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
41349                 optional target-version argument. Verify that the compiler
41350                 groks source of the specified source-version, or add -source
41351                 option as necessary. Verify that the compiler produces
41352                 bytecode in the specified target-version, or add -target and
41353                 -source options as necessary. Make the result of the test
41354                 available as variable CONF_JAVAC. Also log error output in
41355                 config.log.
41356
41357         2006-03-11  Bruno Haible  <bruno@clisp.org>
41358
41359                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
41360
41361         2006-05-09  Bruno Haible  <bruno@clisp.org>
41362
41363                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
41364                 CLASSPATH_SEPARATOR to a semicolon.
41365
41366         2006-03-12  Bruno Haible  <bruno@clisp.org>
41367
41368                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
41369                 available as variable CONF_JAVA, for subsequent autoconf
41370                 tests. Also log error output in config.log.
41371
41372         2006-07-19  Bruno Haible  <bruno@clisp.org>
41373
41374                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
41375                 that getline works on glibc2 systems. Needed to avoid trouble
41376                 in relocatable.c.
41377                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
41378
41379         2005-12-04  Bruno Haible  <bruno@clisp.org>
41380
41381                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
41382                 launcher (untested).
41383
41384         2005-12-04  Bruno Haible  <bruno@clisp.org>
41385
41386                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
41387
41388         2006-07-22  Bruno Haible  <bruno@clisp.org>
41389
41390                 * gettext.m4: Update from GNU gettext-0.15.
41391                 * nls.m4: Likewise.
41392                 * po.m4: Likewise.
41393                 * inttypes-pri.m4: Likewise.
41394                 * inttypes-h.m4: Renamed from inttypes.m4.
41395                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
41396
41397 2006-07-22  Bruno Haible  <bruno@clisp.org>
41398
41399         Merge from GNU gettext 0.15.
41400
41401         2005-07-05  Bruno Haible  <bruno@clisp.org>
41402
41403                 * printf-args.c (printf_fetchargs): Work around broken
41404                 definition of wint_t on mingw.
41405
41406         2005-02-12  Bruno Haible  <bruno@clisp.org>
41407
41408                 * xallocsa.h: Add extern "C" for C++.
41409
41410         2006-05-17  Bruno Haible  <bruno@clisp.org>
41411
41412                 Cygwin portability.
41413                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
41414
41415         2006-04-30  Bruno Haible  <bruno@clisp.org>
41416
41417                 * progreloc.c: Include <mach-o/dyld.h> if available.
41418                 (find_executable): Use _NSGetExecutablePath when possible.
41419
41420         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
41421
41422                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
41423                 function.
41424
41425         2005-12-29  Bruno Haible  <bruno@clisp.org>
41426
41427                 * progreloc.c (set_program_name_and_installdir): Fix
41428                 compilation error.
41429
41430         2005-12-04  Bruno Haible  <bruno@clisp.org>
41431
41432                 Cygwin portability.
41433                 * progreloc.c: Include <windows.h> also on Cygwin.
41434                 (find_executable): Add support for Cygwin.
41435                 (set_program_name_and_installdir): Handle also platforms with
41436                 nonempty EXEEXT.
41437
41438         2006-07-11  Bruno Haible  <bruno@clisp.org>
41439
41440                 * javacomp.c: Fix a comment.
41441                 Reported by Jim Meyering.
41442
41443         2006-04-30  Bruno Haible  <bruno@clisp.org>
41444
41445                 * javacomp.h (compile_java_class): Add source_version,
41446                 target_version arguments.
41447                 * javacomp.c: Rewritten to choose only a compiler that
41448                 respects the specified source_version and target_version.
41449
41450         2006-06-27  Bruno Haible  <bruno@clisp.org>
41451
41452                 Assume correct S_ISDIR macro.
41453                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
41454
41455         2006-07-22  Bruno Haible  <bruno@clisp.org>
41456
41457                 * javaversion.h: New file, from GNU gettext.
41458                 * javaversion.c: New file, from GNU gettext.
41459                 * javaversion.java: New file, from GNU gettext.
41460                 * javaversion.class: New file, from GNU gettext.
41461
41462         2006-05-17  Bruno Haible  <bruno@clisp.org>
41463
41464                 Cygwin portability.
41465                 * javaexec.c (execute_java_class): Test for jview program
41466                 also on Cygwin.
41467
41468         2006-04-09  Bruno Haible  <bruno@clisp.org>
41469
41470                 * fatal-signal.c: Don't include string.h.
41471                 (at_fatal_signal): Use a copying loop instead of memcpy.
41472
41473         2005-12-04  Bruno Haible  <bruno@clisp.org>
41474
41475                 * csharpexec.c: Add support for 'clix' launcher (untested).
41476                 (execute_csharp_using_sscli): New function.
41477                 (execute_csharp_program): Call it.
41478
41479         2006-06-21  Bruno Haible  <bruno@clisp.org>
41480
41481                 Avoid warnings from recent versions of mcs.
41482                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
41483                 -o, -L, -r any more. Use options documented since mcs-1.0
41484                 instead. Similarly for -g.
41485
41486         2005-07-09  Bruno Haible  <bruno@clisp.org>
41487
41488                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
41489                 add a .dll suffix.
41490                 Reported by Mark Junker <mjscod@gmx.de>.
41491
41492         2006-06-17  Bruno Haible  <bruno@clisp.org>
41493
41494                 * config.charset: Update for NetBSD 3.0.
41495
41496         2006-05-17  Bruno Haible  <bruno@clisp.org>
41497
41498                 Cygwin portability.
41499                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
41500
41501         2006-05-16  Bruno Haible  <bruno@clisp.org>
41502
41503                 * localcharset.c [CYGWIN]: Include <windows.h>.
41504                 (get_charset_aliases): For Cygwin, return the same CPxxx
41505                 aliases list as under WIN32.
41506                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
41507                 the environment variables. Fall back to GetACP().
41508
41509         2006-04-05  Bruno Haible  <bruno@clisp.org>
41510
41511                 * config.charset: Update Juan Manuel Guerrero's address.
41512
41513         2005-02-12  Bruno Haible  <bruno@clisp.org>
41514
41515                 * allocsa.h: Add extern "C" for C++.
41516
41517         2005-02-10  Bruno Haible  <bruno@clisp.org>
41518
41519                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
41520                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
41521
41522         2006-07-22  Bruno Haible  <bruno@clisp.org>
41523
41524                 * gettext.h: Update to GNU gettext-0.15.
41525
41526 2006-07-22  Bruno Haible  <bruno@clisp.org>
41527
41528         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
41529         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
41530         lib-prefix.m4, longdouble.m4, ssize_t.m4.
41531
41532 2006-07-21  Eric Blake  <ebb9@byu.net>
41533
41534         * modules/stdlib-safer: New file.
41535         * MODULES.html.sh (File stream based Input/Output): Add
41536         stdlib-safer.
41537
41538 2006-07-21  Eric Blake  <ebb9@byu.net>
41539
41540         * lib/stdlib-safer.h: New file from coreutils, required by
41541         stdlib--.h.
41542
41543 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
41544
41545         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
41546
41547 2006-07-20  Bruno Haible  <bruno@clisp.org>
41548
41549         * gnulib-tool: Recognize new option --assume-autoconf.
41550         (autoconf_minversion): New variable.
41551         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
41552
41553 2006-07-20  Bruno Haible  <bruno@clisp.org>
41554
41555         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
41556
41557 2006-07-19  Derek R. Price  <derek@ximbiot.com>
41558
41559         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
41560         Reindent and repaginate.
41561
41562 2006-07-19  Derek Price  <derek@ximbiot.com>
41563
41564         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
41565         Correct grammar.
41566
41567 2006-07-17  Bruno Haible  <bruno@clisp.org>
41568
41569         * modules/list: New file.
41570         * modules/array-list: New file.
41571         * modules/carray-list, modules/carray-list-tests: New files.
41572         * modules/linked-list, modules/linked-list-tests: New files.
41573         * modules/avltree-list, modules/avltree-list-tests: New files.
41574         * modules/rbtree-list, modules/rbtree-list-tests: New files.
41575         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
41576         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
41577         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
41578         * modules/oset: New file.
41579         * modules/array-oset: New file.
41580         * modules/avltree-oset, modules/avltree-oset-tests: New files.
41581         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
41582         * tests/test-carray_list.c: New file.
41583         * tests/test-linked_list.c: New file.
41584         * tests/test-avltree_list.c: New file.
41585         * tests/test-rbtree_list.c: New file.
41586         * tests/test-linkedhash_list.c: New file.
41587         * tests/test-avltreehash_list.c: New file.
41588         * tests/test-rbtreehash_list.c: New file.
41589         * tests/test-avltree_oset.c: New file.
41590         * tests/test-rbtree_oset.c: New file.
41591         * MODULES.html.sh (Container data structures): New section.
41592
41593 2006-07-17  Bruno Haible  <bruno@clisp.org>
41594
41595         * m4/gl_list.m4: New file.
41596
41597 2006-07-17  Bruno Haible  <bruno@clisp.org>
41598
41599         * lib/gl_list.h: New file.
41600         * lib/gl_list.c: New file.
41601         * lib/gl_array_list.h: New file.
41602         * lib/gl_array_list.c: New file.
41603         * lib/gl_carray_list.h: New file.
41604         * lib/gl_carray_list.c: New file.
41605         * lib/gl_linked_list.h: New file.
41606         * lib/gl_linked_list.c: New file.
41607         * lib/gl_anylinked_list1.h: New file.
41608         * lib/gl_anylinked_list2.h: New file.
41609         * lib/gl_avltree_list.h: New file.
41610         * lib/gl_avltree_list.c: New file.
41611         * lib/gl_anyavltree_list1.h: New file.
41612         * lib/gl_anyavltree_list2.h: New file.
41613         * lib/gl_rbtree_list.h: New file.
41614         * lib/gl_rbtree_list.c: New file.
41615         * lib/gl_anyrbtree_list1.h: New file.
41616         * lib/gl_anyrbtree_list2.h: New file.
41617         * lib/gl_anytree_list1.h: New file.
41618         * lib/gl_anytree_list2.h: New file.
41619         * lib/gl_linkedhash_list.h: New file.
41620         * lib/gl_linkedhash_list.c: New file.
41621         * lib/gl_anyhash_list1.h: New file.
41622         * lib/gl_anyhash_list2.h: New file.
41623         * lib/gl_avltreehash_list.h: New file.
41624         * lib/gl_avltreehash_list.c: New file.
41625         * lib/gl_rbtreehash_list.h: New file.
41626         * lib/gl_rbtreehash_list.c: New file.
41627         * lib/gl_anytreehash_list1.h: New file.
41628         * lib/gl_anytreehash_list2.h: New file.
41629
41630         * lib/gl_oset.h: New file.
41631         * lib/gl_oset.c: New file.
41632         * lib/gl_array_oset.h: New file.
41633         * lib/gl_array_oset.c: New file.
41634         * lib/gl_avltree_oset.h: New file.
41635         * lib/gl_avltree_oset.c: New file.
41636         * lib/gl_rbtree_oset.h: New file.
41637         * lib/gl_rbtree_oset.c: New file.
41638         * lib/gl_anytree_oset.h: New file.
41639
41640 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
41641
41642         * m4/mkancesdirs.m4: New file.
41643         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
41644         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
41645         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
41646         it.
41647
41648 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
41649
41650         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
41651         * lib/mkancesdirs.h: New files.
41652         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
41653         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
41654         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
41655         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
41656         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
41657         callers changed.  Revamp internals significantly, by not
41658         attempting to create directories that are temporarily more
41659         permissive than the final results.  Do not attempt to use
41660         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
41661         This removes some race conditions, fixes some bugs, and simplifies
41662         things.  Use new dirchownmod function to do owner and mode changes.
41663         * lib/mkdir-p.h: Likewise.
41664         * lib/modechange.c (octal_to_mode): New function.
41665         (struct mode_change): New member mentioned.
41666         (make_node_op_equals): New arg mentioned.  All callers changed.
41667         (mode_compile): Keep track of which mode bits the user has explicitly
41668         mentioned.
41669         (mode_adjust): New arg DIR, so that we implement the X op correctly.
41670         New arg PMODE_BITS, to keep track of which mode bits the user
41671         mentioned; it treats S_ISUID and S_ISGID speciall.
41672         All callers changed.
41673         * lib/modechange.h: Likewise.
41674
41675 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
41676
41677         * MODULES.html.sh: Add mkancestors.
41678         * modules/mkancesdirs: New module.
41679         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
41680         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
41681         The chdir-safer and afs files are now orphans; I'll remove them
41682         unless someone speaks up.
41683         Add lib/dirchownmod.c, lib/dirchownmod.h.
41684         (Depends-on): Remove alloca, chown, save-cwd, dirname.
41685         Add lchown, mkancesdirs.
41686         (Maintainer): Add self.
41687
41688 2006-07-15  Karl Berry  <karl@gnu.org>
41689
41690         * gnulib-tool: help message wording/arrangement.
41691
41692 2006-07-14  Simon Josefsson  <jas@extundo.com>
41693
41694         * doc/gnulib.texi (Libtool and Windows): New section.
41695
41696 2006-07-12  Simon Josefsson  <jas@extundo.com>
41697
41698         * modules/gendocs (License): Fix license, approved by Karl.
41699
41700 2006-07-12  Eric Blake  <ebb9@byu.net>
41701
41702         * MODULES.html.sh: Add gendocs.
41703
41704 2006-07-11  Eric Blake  <ebb9@byu.net>
41705
41706         * modules/fdl: New module, to install doc/fdl.texi.
41707         * MODULES.html.sh: Add new section for documentation modules.
41708         * gnulib-tool: Avoid space-tab.
41709         (--doc-base): New option, to manage files from doc.
41710
41711 2006-07-11  Eric Blake  <ebb9@byu.net>
41712
41713         * m4/absolute-header.m4: Fix comments to match recent change.
41714
41715 2006-07-11  Eric Blake  <ebb9@byu.net>
41716
41717         * gnulib-tool: List --doc-base before --tests-base.
41718
41719 2006-07-11  Derek R. Price  <derek@ximbiot.com>
41720
41721         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
41722
41723 2006-07-11  Bruno Haible  <bruno@clisp.org>
41724
41725         * README: Mention where to put documentation.
41726
41727 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
41728
41729         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
41730
41731 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
41732
41733         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
41734         to stdint.m4.
41735
41736 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
41737
41738         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
41739         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
41740         "no/such/file/stdint.h" when there is no such file, so that
41741         the resulting C code can be parsed by dodgy compilers.
41742         Problems reported by Bob Proulx.
41743
41744 2006-07-10  Derek R. Price  <derek@ximbiot.com>
41745
41746         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
41747         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
41748         macros into the GNU _D_EXACT_NAMLEN.
41749         * lib/savedir.c:  Likewise.
41750         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
41751
41752 2006-07-10  Derek R. Price  <derek@ximbiot.com>
41753         and Paul Eggert  <eggert@cs.ucla.edu>
41754
41755         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
41756         * m4/savedir.m4:
41757         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
41758         macros into the GNU _D_EXACT_NAMLEN.
41759
41760 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
41761
41762         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
41763         around the absolute name, to work around a problem with the HP-UX
41764         11.23 native C compiler, reported by Bob Proulx.
41765
41766 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
41767
41768         * doc/maintain.texi, make-stds.texi: Sync from
41769         <http://savannah.gnu.org/projects/gnustandards>.
41770
41771 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
41772
41773         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
41774
41775 2006-07-09  Jim Meyering  <jim@meyering.net>
41776
41777         * m4/glob.m4: Remove a doubled word in a comment.
41778
41779 2006-07-09  Jim Meyering  <jim@meyering.net>
41780
41781         * lib/argp-pv.c: Remove a doubled word in a comment.
41782         * lib/check-version.c (check_version): Likewise.
41783         * lib/javacomp.c (compile_java_class): Likewise.
41784
41785 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
41786
41787         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
41788         for the benefit of people using Autoconf 2.60.  If you want to
41789         support older Autoconf versions you can copy m4/onceonly_2_57.m4
41790         (or m4/onceonly.m4, if pre-2.57) manually.
41791
41792 2006-07-08  Jim Meyering  <jim@meyering.net>
41793
41794         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
41795         comment.
41796         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
41797         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
41798         comment.
41799
41800 2006-07-08  Jim Meyering  <jim@meyering.net>
41801
41802         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
41803
41804 2006-07-07  Simon Josefsson  <jas@extundo.com>
41805
41806         * tests/test-crc.c: Change expected crc value, the test vector
41807         were probably computed using the old broken crc.c?
41808
41809 2006-07-06  Simon Josefsson  <jas@extundo.com>
41810
41811         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
41812         now the canonical place for the M4 file).
41813
41814         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
41815         from the sys_socket dependency now.
41816
41817         * modules/inet_pton (Files): Ditto.
41818
41819         * modules/inet_ntop (Files): Ditto.
41820
41821 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
41822
41823         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
41824         not gl_PREREQ_GETUSERSHELL.
41825
41826 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
41827
41828         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
41829         with only one argument, for Autoconf 2.60.
41830         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
41831         expand to nothing, so add a shell command to avoid syntax error.
41832         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
41833
41834 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
41835
41836         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
41837
41838 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
41839
41840         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
41841         no longer needed.  Check for isblank decl.
41842         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
41843         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
41844         of existence.
41845
41846 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
41847
41848         * lib/getloadavg.c: Use __VMS, not VMS.
41849         * lib/getopt.c: Likewise.
41850         * lib/getpagesize.h: Likewise.
41851         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
41852         and probably does not work.
41853
41854 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
41855
41856         * lib/.cppi-disable: Add wcwidth.
41857         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
41858         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
41859         (ISGRAPH): Remove.  All uses changed to isgraph.
41860         (FOLD) [!defined _LIBC]: Remove special case.
41861         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
41862         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
41863         HAVE_ISBLANK.
41864         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
41865         case.
41866
41867 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
41868
41869         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
41870         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
41871         brackets.  Other minor changes to suppress some compiler
41872         warnings.
41873
41874 2006-07-06  Derek R. Price  <derek@ximbiot.com>
41875         and Paul Eggert  <eggert@cs.ucla.edu>
41876
41877         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
41878         of invoking obsolescent AC_HEADER_DIRENT macro.
41879         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
41880         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
41881         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
41882         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
41883         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
41884         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
41885         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
41886         * m4/readdir.m4: Remove; no longer needed.
41887
41888 2006-07-06  Derek R. Price  <derek@ximbiot.com>
41889         and Paul Eggert  <eggert@cs.ucla.edu>
41890
41891         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
41892         Don't worry about this obsolete case any more.
41893         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
41894         directories.
41895         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
41896         worry about this obsolete case any more.
41897         * lib/fts.c: Likewise.
41898         * lib/getcwd.c: Likewise.
41899         * lib/glob.h: Likewise.
41900         * lib/savedir.c: Likewise.
41901
41902 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
41903
41904         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
41905         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
41906         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
41907         needed.
41908         All uses removed.
41909         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
41910         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
41911         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
41912         needed.
41913         * m4/getdate.m4 (gl_GETDATE): Likewise.
41914         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
41915         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
41916         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
41917         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
41918         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
41919         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
41920         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
41921         needed.
41922
41923 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
41924
41925         * lib/memcasecmp.c: Include <limits.h>.
41926         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
41927         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
41928         Don't assume isdigit succeeds only on '0' through '9'.
41929
41930 2006-07-05  Eric Blake  <ebb9@byu.net>
41931
41932         * modules/getaddrinfo (Depends-on): Add snprintf.
41933
41934 2006-07-05  Eric Blake  <ebb9@byu.net>
41935
41936         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
41937         to avoid 'header present but could not be compiled' on cygwin.
41938
41939 2006-07-05  Eric Blake  <ebb9@byu.net>
41940
41941         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
41942         missing from netdb.h.
41943         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
41944
41945 2006-07-05  Derek R. Price  <derek@ximbiot.com>
41946
41947         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
41948         no longer needed.
41949         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
41950         * m4/getdate.m4 (gl_GETDATE): Likewise.
41951         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
41952         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
41953         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
41954         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
41955         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
41956
41957 2006-07-05  Derek R. Price  <derek@ximbiot.com>
41958
41959         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
41960         All uses of is_space replaced by isspace.
41961         * lib/exit.h: Don't talk about STDC_HEADERS.
41962         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
41963         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
41964         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
41965         replaced by isprint etc.
41966         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
41967         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
41968         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
41969         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
41970         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
41971         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
41972
41973 2006-07-05  Bruno Haible  <bruno@clisp.org>
41974
41975         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
41976         the function exists, before testing against AIX.
41977         Reported by Martin Lambers <marlam@marlam.de>.
41978
41979 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
41980
41981         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
41982         From Mark D. Baushke.
41983
41984 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
41985
41986         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
41987         to the absolute name, not just one, to bypass Sun C 5.8's
41988         "warning: #include of /usr/include/... may be non-portable".
41989
41990 2006-07-04  Eric Blake  <ebb9@byu.net>
41991
41992         * modules/dirname-tests: New test module.
41993         * tests/test-dirname.c: New file, replacing dirname.c
41994         TEST_DIRNAME section that was recently deleted.
41995
41996 2006-07-04  Bruno Haible  <bruno@clisp.org>
41997
41998         Assume ANSI C header files and <ctype.h> functions.
41999         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
42000         (mbsnwidth): Use isprint, iscntrl instead.
42001
42002 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
42003
42004         Merge from coreutils.
42005         * MODULES.html.sh: Add xstrtold.
42006         * modules/xstrtold: New file.
42007         * modules/cycle-check (Files): Add lib/same-inode.h.
42008         * modules/dirname (Files): Add m4/double-slash-root.m4.
42009         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
42010         * modules/mkdir-p (Files): Add lib/same-inode.h.
42011         * modules/same (Files): Add lib/same-inode.h.
42012
42013 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
42014
42015         * m4/absolute-header.m4: Renamed from full-header-path.m4.
42016         This is to keep the terminology clean; POSIX talks about
42017         "absolute pathnames", not "full pathnames", but the GNU
42018         Coding Standards say to use "path" for something else;
42019         so use "absolute" to keep both sides happy.
42020         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
42021         Set gl_absolute_header, not gl_full_header_path.
42022         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
42023         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
42024         All uses changed.
42025
42026         Merge from coreutils.
42027
42028         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
42029
42030         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
42031         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
42032         want to require the building of c-strtod.o.
42033         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
42034         needs -lm directly.
42035         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
42036
42037         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
42038
42039         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
42040         --as-needed option if available.  Problem reported by Albert Chin in
42041         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
42042         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
42043         cc merely issues a bunch of annoying warnings for --as-needed
42044         (this problem was reported by Bob Proulx).  Also, try linking with
42045         -lm to detect a bug in binutils 2.16 (this problem was reported
42046         by Ralf Wildenhues).
42047
42048         2006-06-18  Jim Meyering  <jim@meyering.net>
42049
42050         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
42051         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
42052         macro.
42053         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
42054         also check for glibc-2.4's abort-inducing bug.
42055
42056         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
42057         Low-probability clean-up should be to use rmdir to get rid of
42058         the just-created directory, not unlink.
42059
42060         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
42061         configure fail, and request a bug report to inform us about it.
42062         Add a comment that, barring reports to the contrary, in 2007 we'll
42063         assume ftruncate is universally available.
42064
42065         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
42066
42067         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
42068
42069         2006-03-12  Jim Meyering  <jim@meyering.net>
42070
42071         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
42072         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
42073         * m4/same.m4 (gl_SAME): Likewise.
42074         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
42075
42076         2006-03-11  Eric Blake  <ebb9@byu.net>
42077
42078         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
42079         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
42080         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
42081         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
42082
42083 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
42084
42085         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
42086         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
42087         reported by Mark D. Baushke, one in
42088         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
42089
42090         Merge from coreutils.
42091
42092         * lib/.cppi-disable: Add stdint_.h.
42093         * lib/.cvsignore: Add stdint.h.
42094
42095         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
42096
42097         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
42098         both double and long double versions.
42099         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
42100         * lib/xstrtold.c: New file.
42101         * lib/xstrtod.h (xstrtold): New decl.
42102
42103         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
42104
42105         * lib/filemode.c (setst): Remove.
42106         (strmode): Rewrite to avoid setst.  This makes the code shorter,
42107         (arguably) clearer, and the generated code is a bit smaller on my
42108         Debian GNU/Linux stable x86 host.
42109
42110         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
42111
42112         * lib/filemode.c: Include "filemode.h" first, to test the interface.
42113         Assume that filemode.h includes sys/types.h and sys/stat.h.
42114         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
42115         (ftypelet): Reorder to put common cases first, for efficiency.
42116         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
42117         to do 'M'.
42118         (strmode): Renamed from mode_string, and now stores 12 bytes instead
42119         of 10, for compatibility with FreeBSD.  All callers changed.
42120         (filemodestring): Now stores 12 bytes instead of 10, and sets file
42121         types that can't be deduced solely from st_mode.  First arg is now a
42122         const pointer.
42123         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
42124         (strmode): Renamed from mode_string.
42125         (filemodestring): New decl.
42126         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
42127         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
42128         needed.
42129         (S_ISPORT, S_ISWHT): New macros, if not already defined.
42130
42131         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
42132
42133         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
42134         fsusage.h now does that.  Include fsusage.h first, to test interface.
42135         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
42136         at most one method (the old code could have generated decls that
42137         didn't conform to C89, not that this was ever exercised).
42138         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
42139
42140         2006-03-19  Jim Meyering  <jim@meyering.net>
42141
42142         Work even in a chroot where d_ino values for entries in "/"
42143         don't match the stat.st_ino values for the same names.
42144         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
42145         number, iterate through all entries again, using lstat instead.
42146         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
42147         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
42148
42149         * lib/getcwd.c (__getcwd): Clarify a comment.
42150         Use memcpy in place of a call to strcpy.
42151
42152         2006-03-12  Jim Meyering  <jim@meyering.net>
42153
42154         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
42155         matches that of the current directory (which we're about to chdir ".."
42156         out of), then save the dev-ino of the parent, instead.
42157
42158         * lib/same-inode.h (SAME_INODE): New file/macro.
42159         * lib/chdir-safer.c (SAME_INODE): Remove definition.
42160         Include "same-inode.h", instead.
42161         * lib/same.c: Likewise.
42162         * lib/cycle-check.h: Include "same-inode.h".
42163         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
42164         * lib/cycle-check.c (SAME_INODE): Remove definition.
42165         * lib/root-dev-ino.h: Include "same-inode.h".
42166
42167         2006-03-11  Eric Blake  <ebb9@byu.net>
42168
42169         * lib/same.c (same_name): s/base_name/last_component/
42170         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
42171         * lib/filenamecat.c (file_name_concat): Likewise.
42172
42173         2006-03-11  Eric Blake  <ebb9@byu.net>,
42174                     Paul Eggert  <eggert@cs.ucla.edu>
42175
42176         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
42177         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
42178         drive prefix.
42179         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
42180         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
42181         (last_component): New method.
42182         * lib/dirname.c (dir_len): Determine when drive letters need a
42183         subsequent slash.  Preserve // when it is special.
42184         (dir_name): Don't append dot when drive letter is absolute.
42185         [TEST_DIRNAME]: Move into a full-blown gnulib test.
42186         * lib/basename.c (base_name): New semantics - malloc the result.
42187         Preserve // when it is special.  Preserve relative files that look
42188         like drive letters.
42189         (base_len): Preserve // when it is special.
42190         (last_component): New method, similar to old base_name semantics.
42191         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
42192         base_name.  Strip redundant slashes from ///.
42193
42194 2006-07-03  Jim Meyering  <jim@meyering.net>
42195
42196         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
42197         macro is used before the first cycle_check call.
42198
42199 2006-07-03  Eric Blake  <ebb9@byu.net>
42200
42201         * modules/dirname (Depends-on): Add xstrndup.
42202
42203 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
42204
42205         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
42206         test cases, so that config.log is a bit easier to follow.
42207
42208 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
42209
42210         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
42211         both are 64 bits, since this seems to be the tradition, and this
42212         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
42213         we ever run into a host that prefers long long to long in this
42214         case, we'll need another configure-time test.  Problem reported by
42215         Jim Meyering.
42216
42217 2006-07-02  Eric Blake  <ebb9@byu.net>
42218
42219         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
42220
42221 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
42222
42223         * modules/inttypes (Depends-on): No longer depends on stdint.
42224         * modules/stdint (Description): Say more about assumptions.
42225         Say that the fast types might differ.  Say macros are used.
42226         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
42227         (Makefile.am): Revise list of substituted symbols to match
42228         new stdint.m4.
42229         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
42230         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
42231         * tests/test-stdint.c (verify_same_types)
42232         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
42233         the code conforms to C99/C89.
42234         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
42235         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
42236
42237 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
42238
42239         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
42240         but fix a bug, by requiring at least 64 bits.
42241         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
42242         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
42243         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
42244         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
42245
42246         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
42247         changes.  Make 2.59 a prerequisite.  Check and substitute for
42248         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
42249         inttypes.h.  Do not use special include files; just use the
42250         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
42251         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
42252         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
42253         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
42254         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
42255         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
42256         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
42257         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
42258         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
42259         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
42260         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
42261         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
42262         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
42263         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
42264         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
42265         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
42266         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
42267         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
42268         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
42269         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
42270         WINT_MAX.  Check for C99 conformance more strictly, by detecting
42271         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
42272         not check for things that C99 does not require, e.g., int8_t.  If
42273         a test isn't needed unless <stdint.h> isn't working, and is
42274         unlikely to be needed for any other reason, then don't do it
42275         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
42276         size_t, since we assume C89 freestanding at least.  Do not check
42277         for sig_atomic_t, wchar_t, or wint_t, since the code now does
42278         the right thing even if the types are not defined.  Instead use:
42279         (gl_STDINT_TYPE_PROPERTIES): New macro.
42280         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
42281         testing whether <sys/types.h> clashes, as Autoconf does this for
42282         us now.  All uses removed.
42283         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
42284         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
42285         (gl_CHECK_TYPE_SAME):
42286         Remove; no longer needed.
42287         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
42288         exists, since we'll return 0 anyway in that case.
42289         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
42290
42291 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
42292
42293         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
42294         possible collision with system files.
42295         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
42296         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
42297         WCHAR_MIN and WCHAR_MAX in this case.
42298         (<stddef.h>): Do not include; no longer needed.
42299         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
42300         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
42301         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
42302         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
42303         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
42304         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
42305         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
42306         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
42307         !defined(__c99))]: Include in this case too, since it's harmless
42308         now.
42309         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
42310         dangerous to do so.
42311         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
42312         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
42313         (_STDINT_MIN, _STDINT_MAX): New macros.
42314         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
42315         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
42316         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
42317         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
42318         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
42319         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
42320         macros, not typedefs; this simplifies things quite a bit.
42321         Use long int for all types narrower than int64_t.
42322         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
42323         Define in terms of long long int or int64_t or long int,
42324         not int64_t or int32_t.  This saves some compile-time testing.
42325         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
42326         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
42327         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
42328         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
42329         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
42330         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
42331         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
42332         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
42333         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
42334         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
42335         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
42336         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
42337         undef any previous version and define our own version, for
42338         simplicity and consistency with the new macros for types.
42339         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
42340         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
42341         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
42342         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
42343         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
42344         @WINT_T_SUFFIX@ to keep things simple here.
42345         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
42346         Simplify by assuming typical 8/16/32/64 host, since we're
42347         already doing that elsewhere anyway.
42348         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
42349         and assume long long int is 64 bits if available.  This
42350         speeds up 'configure'.
42351
42352 2006-07-01  Eric Blake  <ebb9@byu.net>
42353
42354         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
42355         Reported by Andreas Buening.
42356
42357 2006-07-01  Eric Blake  <ebb9@byu.net>
42358
42359         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
42360
42361 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
42362
42363         * lib/getaddrinfo.c: fixed typo
42364
42365 2006-06-29  Jim Meyering  <jim@meyering.net>
42366
42367         * modules/strftime (Maintainer): Add my name, since with the
42368         FPRINTFTIME changes strftime.c has forked from glibc.
42369
42370 2006-06-29  Eric Blake  <ebb9@byu.net>
42371
42372         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
42373
42374 2006-06-29  Eric Blake  <ebb9@byu.net>
42375
42376         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
42377
42378 2006-06-29  Eric Blake  <ebb9@byu.net>
42379
42380         * lib/stat_.h: New file.
42381
42382 2006-06-29  Eric Blake  <ebb9@byu.net>
42383
42384         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
42385         unused static function.
42386
42387 2006-06-29  Eric Blake  <ebb9@byu.net>
42388
42389         * doc/functions.texi (Function Portability): Document missing lstat
42390         on mingw.
42391
42392 2006-06-29  Eric Blake  <ebb9@byu.net>
42393
42394         * MODULES.html.sh: Add sys_stat.
42395         * modules/sys_stat: New module.
42396         * modules/mkstemp (Depends-on): Add sys_stat.
42397
42398 2006-06-29  Derek R. Price  <derek@ximbiot.com>
42399
42400         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
42401
42402 2006-06-29  Derek R. Price  <derek@ximbiot.com>
42403
42404         * m4/c-bs-a.m4: Removed.
42405
42406 2006-06-29  Derek R. Price  <derek@ximbiot.com>
42407
42408         * lib/strftime.c: Assume strftime() exists.
42409
42410 2006-06-29  Derek Price  <derek@ximbiot.com>
42411
42412         * modules/c-bs-a: Removed - \a is C89.
42413         * MODULES.html.sh: Remove c-bs-a.
42414
42415 2006-06-29  Bruno Haible  <bruno@clisp.org>
42416
42417         * modules/wcwidth (License): Change to LGPL.
42418
42419 2006-06-28  Simon Josefsson  <jas@extundo.com>
42420
42421         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
42422         on _WIN32.
42423
42424         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
42425         getnameinfo.
42426
42427 2006-06-28  Simon Josefsson  <jas@extundo.com>
42428
42429         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
42430
42431 2006-06-28  Simon Josefsson  <jas@extundo.com>
42432
42433         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
42434         functions there.  It will succeed on Windows XP, but on Windows
42435         2000 and (presumably) earlier, it will fail, and use the internal
42436         re-implementation.
42437         (use_win32_p): New function.
42438         (getaddrinfo): Use strtoul on servname, to support numeric ports.
42439         Support AI_NUMERICSERV to disable getservbyname.
42440         (getnameinfo): New function, only supports
42441         NI_NUMERICHOST|NI_NUMERICSERV for now.
42442
42443         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
42444         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
42445         getnameinfo.
42446
42447 2006-06-28  Eric Blake  <ebb9@byu.net>
42448
42449         * modules/wcwidth: New file.
42450         * modules/mbchar (Depends-on): Add wcwidth.
42451         * modules/mbswidth (Depends-on): Add wcwidth.
42452         * MODULES.html.sh: Add wcwidth.
42453
42454 2006-06-28  Eric Blake  <ebb9@byu.net>
42455
42456         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
42457         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
42458
42459 2006-06-28  Eric Blake  <ebb9@byu.net>
42460
42461         * lib/xvasprintf.h: Fix comments.
42462
42463 2006-06-28  Eric Blake  <ebb9@byu.net>
42464
42465         * lib/mbchar.h (wcwidth): Include wcwidth.h.
42466         * lib/mbswidth.c (wcwidth): Move from here...
42467         * lib/wcwidth.h: ...to this new file.
42468
42469 2006-06-28  Derek R. Price  <derek@ximbiot.com>
42470
42471         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
42472
42473         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
42474         it's obsolete.
42475         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
42476
42477 2006-06-28  Derek R. Price  <derek@ximbiot.com>
42478
42479         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
42480         Autoconf 2.60 says this stuff was obsolete.
42481
42482 2006-06-28  Bruno Haible  <bruno@clisp.org>
42483
42484         * modules/wcwidth (Files): Add m4/wchar_t.m4.
42485
42486 2006-06-28  Bruno Haible  <bruno@clisp.org>
42487
42488         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
42489         gt_TYPE_WCHAR_T.
42490
42491 2006-06-28  Bruno Haible  <bruno@clisp.org>
42492
42493         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
42494         declaration for wcwidth.
42495         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
42496
42497 2006-06-28  Bruno Haible  <bruno@clisp.org>
42498
42499         * lib/mkdtemp.c [MINGW]: Include <io.h>.
42500         (mkdir): Define using _mkdir.
42501
42502 2006-06-28  Bruno Haible  <bruno@clisp.org>
42503
42504         * lib/getaddrinfo.h: Fix POSIX URL.
42505         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
42506         _WIN32.
42507         (use_win32_p): Make static.
42508         (getaddrinfo): Reject service name if it is empty or does not consist
42509         solely of decimal digits, or if its value is > 65535.
42510         (getnameinfo): Remove useless casts.
42511
42512 2006-06-27  Simon Josefsson  <jas@extundo.com>
42513
42514         * modules/sys_select: New file, suggested by Bruno Haible, Paul
42515         Eggert and Martin Lambers.
42516
42517 2006-06-27  Simon Josefsson  <jas@extundo.com>
42518
42519         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
42520         Eggert and Martin Lambers.
42521
42522 2006-06-27  Bruno Haible  <bruno@clisp.org>
42523
42524         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
42525         result to 0, not to empty.
42526         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
42527
42528 2006-06-27  Bruno Haible  <bruno@clisp.org>
42529
42530         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
42531
42532 2006-06-26  Simon Josefsson  <jas@extundo.com>
42533
42534         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
42535         present.
42536
42537 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
42538
42539         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
42540         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
42541         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
42542
42543 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
42544
42545         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
42546
42547 2006-06-26  Bruno Haible  <bruno@clisp.org>
42548
42549         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
42550
42551 2006-06-26  Bruno Haible  <bruno@clisp.org>
42552
42553         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
42554
42555 2006-06-26  Bruno Haible  <bruno@clisp.org>
42556
42557         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
42558         SGI C compiler in pre-C99 mode.
42559         Suggested by Mark D. Baushke and Larry Jones.
42560
42561 2006-06-26  Bruno Haible  <bruno@clisp.org>
42562
42563         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
42564         WCHAR_MAX.
42565         Reported by Mark D. Baushke and Larry Jones.
42566
42567 2006-06-26  Bruno Haible  <bruno@clisp.org>
42568
42569         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
42570         in pre-C99 mode.
42571         Suggested by Mark D. Baushke and Larry Jones.
42572
42573 2006-06-23  Simon Josefsson  <jas@extundo.com>
42574             Bruno Haible  <bruno@clisp.org>
42575
42576         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
42577         Emit mostlyclean-local rule.
42578         (func_emit_tests_Makefile_am): Likewise.
42579         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
42580
42581 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
42582
42583         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
42584
42585 2006-06-23  Bruno Haible  <bruno@clisp.org>
42586
42587         * tests/test-stdint.c: Update to match ISO C 99 Technical
42588         Corrigendum 1.
42589
42590 2006-06-23  Bruno Haible  <bruno@clisp.org>
42591
42592         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
42593
42594 2006-06-23  Bruno Haible  <bruno@clisp.org>
42595
42596         * lib/stdint_.h: Treat IRIX like OpenBSD.
42597
42598 2006-06-23  Bruno Haible  <bruno@clisp.org>
42599
42600         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
42601         ISO C 99 Technical Corrigendum 1.
42602
42603 2006-06-22  Simon Josefsson  <jas@extundo.com>
42604
42605         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
42606         MinGW.
42607
42608 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
42609
42610         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
42611         needed.  Some compiler complained about some of them.  Problem reported
42612         by Larry Jones in
42613         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
42614
42615 2006-06-21  Simon Josefsson  <jas@extundo.com>
42616
42617         * tests/test-getaddrinfo.c: New file.
42618
42619         * modules/getaddrinfo-tests: New file.
42620
42621         * MODULES.html.sh: Add inet_pton.
42622
42623         * modules/inet_pton: New file.
42624
42625 2006-06-21  Simon Josefsson  <jas@extundo.com>
42626
42627         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
42628         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
42629         of using the (limited) gnulib implementation on Windows XP.
42630
42631         * m4/inet_pton.m4: New file.
42632
42633 2006-06-21  Simon Josefsson  <jas@extundo.com>
42634
42635         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
42636         variable.
42637
42638         * lib/socket_.h: Don't define WINVER.
42639
42640         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
42641         slightly modified to work in gnulib.
42642
42643 2006-06-21  Simon Josefsson  <jas@extundo.com>
42644
42645         * doc/gnulib.texi (Windows sockets): Add.
42646
42647 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
42648
42649         * lib/read-file.c (fread_file): Start with buffer allocation of
42650         0 bytes rather than 1 byte; this simplifies the code.
42651         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
42652         code to free buffer and save/restore errno.
42653         (internal_read_file): Remove unused local.
42654
42655 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
42656
42657         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
42658         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
42659         Problem reported by Denis Excoffier in
42660         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
42661
42662 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
42663
42664         * modules/sys_socket, modules/socklen: Include sys/types since
42665         FreeBSD 4.x's sys/socket.h needs it.
42666
42667 2006-06-19  Simon Josefsson  <jas@extundo.com>
42668
42669         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
42670
42671 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
42672
42673         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
42674
42675 2006-06-19  Bruno Haible  <bruno@clisp.org>
42676
42677         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
42678         and FULL_PATH_INTTYPES_H in angle brackets.
42679         Reported by Mark D. Baushke <mdb@gnu.org>.
42680
42681 2006-06-17  Eric Blake  <ebb9@byu.net>
42682
42683         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
42684         errno.
42685
42686 2006-06-17  Bruno Haible  <bruno@clisp.org>
42687
42688         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
42689         <sys/inttypes.h>.
42690
42691 2006-06-17  Bruno Haible  <bruno@clisp.org>
42692
42693         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
42694         whether errno is declared. Assume <errno.h> declares errno.
42695
42696 2006-06-17  Bruno Haible  <bruno@clisp.org>
42697
42698         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
42699
42700 2006-06-17  Bruno Haible  <bruno@clisp.org>
42701
42702         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
42703         problem on Solaris 2.5.1.
42704
42705 2006-06-16  Eric Blake  <ebb9@byu.net>
42706
42707         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
42708         * lib/unicodeio.c [!defined errno]: Likewise.
42709         * lib/strtol.c [!defined errno]: Likewise.
42710         * lib/strtod.c [!defined errno]: Likewise.
42711
42712 2006-06-15  Eric Blake  <ebb9@byu.net>
42713
42714         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
42715
42716 2006-06-15  Eric Blake  <ebb9@byu.net>
42717
42718         * config/srclist.txt (ssize_t.m4): Lose sync.
42719
42720 2006-06-15  Bruno Haible  <bruno@clisp.org>
42721
42722         * modules/stdint (Files): Include m4/full-header-path.m4,
42723         m4/size_max.m4, m4/wchar_t.m4.
42724         (Makefile.am): Many more substitutions.
42725         * modules/stdint-tests: New file.
42726         * tests/test-stdint.c: New file.
42727
42728 2006-06-15  Bruno Haible  <bruno@clisp.org>
42729
42730         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
42731         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
42732         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
42733         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
42734         gl_CHECK_TYPE_SAME): New macros.
42735
42736 2006-06-15  Bruno Haible  <bruno@clisp.org>
42737
42738         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
42739
42740 2006-06-15  Bruno Haible  <bruno@clisp.org>
42741
42742         * lib/stdint_.h: Rewritten to be fully auto-configured.
42743         Fixes bug on HP-UX/IA64.
42744
42745 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
42746
42747         * lib/getdate.y (__attribute__): Don't define if already defined.
42748         Problem reported by Larry Jones.
42749         * lib/utimens.c (__attribute__): Likewise.
42750
42751 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
42752
42753         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
42754         reported by Andreas Schwab.
42755
42756 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
42757             Bruno Haible  <bruno@clisp.org>
42758
42759         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
42760         check for the declaration of strnlen and a run test that exposes the
42761         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
42762         rpl_strndup.
42763
42764 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
42765             Bruno Haible  <bruno@clisp.org>
42766
42767         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
42768
42769 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
42770
42771         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
42772         compile test, for Tru64 4.0D.
42773
42774 2006-05-28  Karl Berry  <karl@gnu.org>
42775
42776         * config/srclist.txt (printf-args.c): lose sync.
42777
42778 2006-05-26  Martin Lambers  <marlam@marlam.de>
42779
42780         * lib/getpass.c: Updates the test for the native W32 API, and adds
42781         missing includes, thus fixing compilation warnings.
42782
42783 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
42784
42785         * lib/exclude.c (exclude_fnmatch): New function.
42786         (excluded_file_name): Call exclude_fnmatch.
42787         * lib/exclude.h (excluded_file_name): New prototype
42788
42789 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
42790
42791         * lib/tempname.c (small_open, large_open): New macros.
42792         (__open, __open64) [!_LIBC]: Remove.
42793         (__gen_tempname): Use small_open and large_open instead of __open
42794         and __open64.  This fixes a portability bug on HP-UX 11.11i
42795         reported by Simon Wing-Tang in
42796         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
42797
42798 2006-05-24  Bruno Haible  <bruno@clisp.org>
42799
42800         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
42801         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
42802         Reported by Thorsten Maerz <torte@netztorte.de> via
42803         Aaron Stone <aaron@serendipity.cx>.
42804
42805 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
42806
42807         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
42808         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
42809         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
42810         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
42811         not really conditional on the cache.
42812         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
42813
42814 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
42815
42816         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
42817         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
42818         (my_usleep): Don't mishandle maximum value.
42819
42820 2006-05-19  Jim Meyering  <jim@meyering.net>
42821
42822         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
42823
42824 2006-05-17  Bruno Haible  <bruno@clisp.org>
42825
42826         Cygwin portability.
42827         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
42828
42829 2006-05-17  Bruno Haible  <bruno@clisp.org>
42830
42831         * lib/stdint_.h: Fix recognition of Cygwin.
42832
42833 2006-05-15  Bruno Haible  <bruno@clisp.org>
42834
42835         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
42836         on libtool patch by Ralf Wildenhues.
42837
42838 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
42839
42840         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
42841         test for C99 conformance; (bool) 0.5 is an integer constant
42842         expression, but (bool) -0.5 is not.  Problem reported by Fedor
42843         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
42844
42845 2006-05-11  Simon Josefsson  <jas@extundo.com>
42846
42847         * m4/xvasprintf.m4: Fix obvious typo.
42848
42849 2006-05-11  Jim Meyering  <jim@meyering.net>
42850
42851         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
42852         James Lemley.
42853
42854 2006-05-10  Simon Josefsson  <jas@extundo.com>
42855
42856         * lib/md4.c: Typo fix, update copyright years.
42857         (K1, K2): Don't use L because it turn computations into 64-bit on
42858         64-bit platforms.
42859
42860 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
42861
42862         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
42863         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
42864         unwanted sign propagation, e.g., on hosts with 64-bit int.
42865         There still are some problems with reeelly weird theoretical hosts
42866         (e.g., 33-bit int) but it's not worth worrying about now.
42867         * lib/sha1.c (rol): Likewise.
42868         (K1, K2, K3, K4): Remove unnecessary L suffix.
42869
42870 2006-05-10  Bruno Haible  <bruno@clisp.org>
42871
42872         * lib/des.c: Cast to avoid warnings.
42873
42874 2006-05-09  Bruno Haible  <bruno@clisp.org>
42875
42876         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
42877         (Depends-on): Depend also on xsize, stdarg.
42878         (configure.ac): Add gl_XVASPRINTF.
42879
42880 2006-05-09  Bruno Haible  <bruno@clisp.org>
42881
42882         * m4/xvasprintf.m4: New file.
42883
42884 2006-05-09  Bruno Haible  <bruno@clisp.org>
42885
42886         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
42887         (EOVERFLOW): Define fallback value.
42888         (xstrcat): New function.
42889         (xvasprintf): Recognize the special case of a string concatenation.
42890
42891 2006-05-08  Eric Blake  <ebb9@byu.net>
42892
42893         * gnulib-tool (func_version): Base copyright year on CVS date.
42894         (func_emit_copyright_notice): New function.
42895         (func_emit_lib_Makefile_am): Use it.
42896         (func_emit_tests_Makefile_am): Likewise.
42897         (func_import): Likewise.
42898
42899 2006-05-08  Bruno Haible  <bruno@clisp.org>
42900
42901         * modules/stdarg: New file.
42902         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
42903
42904 2006-05-08  Bruno Haible  <bruno@clisp.org>
42905
42906         * m4/stdarg.m4: New file, from GNU gettext.
42907
42908 2006-05-08  Bruno Haible  <bruno@clisp.org>
42909
42910         * config/srclist.txt (build-aux/config.rpath): different from latest
42911         release.
42912
42913 2006-05-08  Bruno Haible  <bruno@clisp.org>
42914
42915         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
42916
42917 2006-05-05  Jim Meyering  <jim@meyering.net>
42918
42919         * m4/warning.m4: New file, derived from bison's file by the same name.
42920
42921 2006-05-03  Bruno Haible  <bruno@clisp.org>
42922
42923         * lib/stdint_.h: Shorter URL.
42924         * lib/inttypes.h: Likewise.
42925
42926 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
42927
42928         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
42929
42930 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
42931
42932         * lib/verify.h: Document the internals better.  Most of this change
42933         was written by Bruno Haible.
42934
42935 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
42936
42937         * doc/verify.texi: New file, partly based on a proposal by
42938         Bruno Haible.
42939
42940 2006-05-02  Bruno Haible  <bruno@clisp.org>
42941
42942         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
42943         test from here...
42944         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
42945
42946 2006-04-29  Bruno Haible  <bruno@clisp.org>
42947
42948         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
42949         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
42950
42951 2006-04-29  Bruno Haible  <bruno@clisp.org>
42952
42953         * gnulib-tool: Make --update option actually work.
42954
42955 2006-04-29  Bruno Haible  <bruno@clisp.org>
42956
42957         * doc/gcd.texi: New file.
42958         * doc/gnulib.texi: Include it.
42959
42960 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
42961
42962         * lib/getdate.y (get_date): When adding relative date, start with the
42963         initial time, not with the result of the first mktime call.
42964
42965 2006-04-25  Bruno Haible  <bruno@clisp.org>
42966
42967         * gnulib-tool (func_import): Output the include directives in three
42968         blocks, sorted separately.
42969         Reported by Ben Pfaff <blp@cs.stanford.edu>.
42970
42971 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
42972
42973         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
42974         to define main with arguments, for C++.  Reported by Eric Blake.
42975         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
42976         Prefer 'int main ()' to 'int main (void)', for C++.
42977         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
42978         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
42979         for 'main', for C99 and C++.
42980
42981 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
42982
42983         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
42984         Don't assume that exit status -1 is valid.
42985         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
42986         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
42987         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
42988         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
42989         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
42990         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
42991         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
42992         functions can be used without declaring them, or that you can
42993         exit with status -1.
42994         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
42995
42996 2006-04-24  Karl Berry  <karl@gnu.org>
42997
42998         * config/srclist.txt (longdouble.m4): sync lost.
42999
43000 2006-04-24  Eric Blake  <ebb9@byu.net>
43001
43002         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
43003
43004 2006-04-24  Bruno Haible  <bruno@clisp.org>
43005
43006         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
43007         poll() implementation in AIX.
43008         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
43009
43010 2006-04-24  Bruno Haible  <bruno@clisp.org>
43011
43012         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
43013         assigned exactly once.
43014
43015 2006-04-23  Claudio Fontana  <claudio@gnu.org>
43016             Bruno Haible  <bruno@clisp.org>
43017
43018         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
43019         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
43020         for AM_CPPFLAGS.
43021
43022 2006-04-23  Bruno Haible  <bruno@clisp.org>
43023
43024         * modules/copy-file: Depend on unistd.
43025         * modules/execute: Likewise.
43026         * modules/fatal-signal: Likewise.
43027         * modules/findprog: Likewise.
43028         * modules/mkdtemp : Likewise.
43029         * modules/pipe: Likewise.
43030         * modules/wait-process: Likewise.
43031
43032 2006-04-23  Bruno Haible  <bruno@clisp.org>
43033
43034         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
43035         condition was already detected.
43036         Reported by Ben Pfaff <blp@cs.stanford.edu>.
43037
43038 2006-04-23  Bruno Haible  <bruno@clisp.org>
43039
43040         * lib/copy-file.c: Include <unistd.h> unconditionally.
43041         * lib/execute.c: Likewise.
43042         * lib/fatal-signal.c: Likewise.
43043         * lib/findprog.c: Likewise.
43044         * lib/mkdtemp.c: Likewise.
43045         * lib/pipe.h: Likewise.
43046         * lib/pipe.c: Likewise.
43047         * lib/wait-process.h: Likewise.
43048
43049 2006-04-23  Bruno Haible  <bruno@clisp.org>
43050
43051         * gnulib-tool (func_usage): Fix --import description. Document
43052         --update.
43053         (func_import): Create temporary file in a temporary directory, if
43054         --dry-run is specified. Silence errors from 'grep' when there are no
43055         m4 files in $m4dir.
43056         (func_create_testdir): Silence errors from 'grep' when there are no
43057         m4 files in $m4dir.
43058         Reported by Karl Berry <karl@freefriends.org>.
43059
43060 2006-04-20  Bruno Haible  <bruno@clisp.org>
43061
43062         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
43063         one argument, so that the code will be portable to Autoconf 2.60.
43064         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
43065         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
43066         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
43067
43068 2006-04-19  Derek Price  <derek@ximbiot.com>
43069             Eric Blake  <ebb9@byu.net>
43070
43071         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
43072         rather than "/full/path.h".  Update comment to match.  Shorten &
43073         generalize m4_translit call via AS_TR_CPP.
43074
43075 2006-04-19  Derek Price  <derek@ximbiot.com>
43076             Eric Blake  <ebb9@byu.net>
43077
43078         * lib/inttypes.h: Correct grammar in comment.
43079
43080 2006-04-18  Derek Price  <derek@ximbiot.com>
43081             Paul Eggert  <eggert@cs.ucla.edu>
43082
43083         * modules/inttypes: New file.
43084         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
43085
43086 2006-04-18  Derek Price  <derek@ximbiot.com>
43087             Paul Eggert  <eggert@cs.ucla.edu>
43088
43089         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
43090         New files.
43091
43092 2006-04-18  Derek Price  <derek@ximbiot.com>
43093             Paul Eggert  <eggert@cs.ucla.edu>
43094
43095         * lib/inttypes.h: New file.
43096         * lib/strtoimax.c: Assume <inttypes.h>.
43097
43098 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
43099
43100         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
43101         isn't mounted.  Problem reported by Kir Kolyshkin.
43102
43103 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
43104
43105         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
43106         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
43107         Derek R. Price.
43108         * lib/regex.h (RE_DUP_MAX): Update comment to match current
43109         implementation.
43110
43111 2006-04-12  Eric Blake  <ebb9@byu.net>
43112
43113         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
43114         is now done automatically by the corresponding Autoconf macro.
43115
43116 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
43117
43118         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
43119         time_r.h.
43120
43121 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
43122
43123         Merge regex changes from libc, removing some of our
43124         POSIX-conformance changes that were rejected and redoing them in a
43125         less-intrusive way.
43126
43127         * lib/regcomp.c (re_compile_internal, init_dfa):
43128         Length arg is now size_t, not Idx.  All uses changed.
43129         (peek_token): Forward decl now says internal_function.
43130         (__re_error_msgid, __re_error_msgid_idx):
43131         Now static rather than extern with attribute_hidden.
43132         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
43133         For some reason libc prefers K&R style defns for external functions.
43134         (regerror) [!defined _LIBC]: Likewise.
43135         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
43136         (seek_collating_symbol_entry, lookup_collation_sequence_value):
43137         (build_range_exp, build_collating_symbol):
43138         Use K&R-style defn.
43139         (re_compile_fastmap): Use '\0' to memset, not 0.
43140         (utf8_sb_map): Make the calculations more obvious.
43141         (init_dfa, parse_bracket_exp, build_charclass_op):
43142         Call calloc and cast result, as glibc does.
43143         (init_word_char, fetch_token, peek_token, peek_token_bracket):
43144         (build_range_exp, build_collating_symbol):
43145         Now internal functions.
43146
43147         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
43148
43149         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
43150         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
43151         Don't depend on VMS; depend on __VMS instead, for POSIX
43152         namespace cleanness.
43153         (regoff_t): Define to ssize_t, not long int.
43154
43155         Remove the REG_ macros named below.  Instead, make the old names
43156         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
43157         __USE_GNU_REGEX.
43158         (REG_BACKSLASH_ESCAPE_IN_LISTS):
43159         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
43160         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
43161         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
43162         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
43163         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
43164         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
43165         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
43166         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
43167         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
43168         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
43169         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
43170         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
43171         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
43172         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
43173         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
43174         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
43175         (REG_NREGS):
43176         Remove.  All uses replaced by the old RE_* names.
43177         (RE_BACKSLASH_ESCAPE_IN_LISTS):
43178         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
43179         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
43180         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
43181         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
43182         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
43183         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
43184         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
43185         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
43186         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
43187         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
43188         Don't bother having these macros be independent of each others'
43189         values, since they no longer exist in the POSIX name space.
43190
43191         Rename the following member names back to their old names,
43192         unless !__USE_GNU_REGEX.  All uses changed back.
43193         (buffer): Renamed from re_buffer.
43194         (allocated): Renamed from re_allocated.
43195         (used): Renamed from re_used.
43196         (syntax): Renamed from re_syntax.
43197         (fastmap): Renamed from re_fastmap.
43198         (translate): Renamed from re_translate.
43199         (can_be_null): Renamed from re_can_be_null.
43200         (regs_allocated): Renamed from re_regs_allocated.
43201         (fastmap_accurate): Renamed from re_fastmap_accurate.
43202         (no_sub): Renamed from re_no_sub.
43203         (not_bol): Renamed from re_not_bol.
43204         (not_eol): Renamed from re_not_eol.
43205         (newline_anchor): Renamed from re_newline_anchor.
43206         (num_regs): Renamed from rm_num_regs.
43207         (start): Renamed from rm_start.
43208         (end): Renamed from rm_end.
43209
43210         (free_state): Move up a bit.
43211
43212         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
43213         #define to be empty.
43214         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
43215         when that is what is intended.
43216         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
43217         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
43218         (MAX): New macro.
43219         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
43220         All uses changed back to re_malloc, etc.  It's now the caller's
43221         responsibility to check for overflow; all callers changed.
43222         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
43223         (re_x2nrealloc): Remove.
43224         (free_state): Remove decl.
43225
43226         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
43227         (re_set_registers, re_exec):
43228         Use K&R-style defn.
43229
43230         2006-01-31  Roland McGrath  <roland@redhat.com>
43231
43232         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
43233         Reported by Mike Frysinger <vapier@gentoo.org>.
43234
43235         2006-01-15  Andreas Jaeger  <aj@suse.de>
43236
43237         [BZ #1950]
43238         * lib/regex_internal.c (re_string_reconstruct): Adjust for
43239         build_wcs_upper_buffer change.
43240         (build_wcs_upper_buffer): Change return type.
43241
43242         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
43243
43244         * lib/regex_internal.h: Include <stdint.h> if available.
43245
43246         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
43247
43248         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
43249
43250         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
43251
43252         * lib/regcomp.c: Adjust for changed secondary hash function.
43253
43254         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
43255
43256         * lib/regex.h: Pretty printing.
43257         Clean up namespace a bit.
43258
43259         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
43260
43261         * lib/regexec.c (update_cur_sifted_state, check_arrival,
43262         check_arrival_add_next_nodes): Avoid using uninitialized variable.
43263
43264         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
43265                     Ulrich Drepper  <drepper@redhat.com>
43266
43267         [BZ #1302]
43268         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
43269         changed.
43270         (bitset_word_t): Renamed from bitset_word.  All uses changed.
43271
43272         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
43273
43274         [BZ #281]
43275         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
43276         * lib/regcomp.c: Remove unnecessary uses of
43277         unsigned RE_TRANSLATE_TYPE.
43278         * lib/regex_internal.h: Likewise.
43279         * lib/regex_internal.c: Likewise.
43280         * lib/regexec.c: Likewise.
43281         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
43282
43283         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
43284
43285         * lib/regexec.c (find_recover_state): Remove unnecessary
43286         initialization.
43287         (transit_state_bkref): Make DFA a const pointer.
43288         (get_subexp): Likewise.
43289         (check_arrival): Likewise.
43290         (update_cur_sifted_state): Likewise.
43291         (re_search_internal): Likewise.
43292         (prune_impossible_nodes): Likewise.
43293         (acquire_init_state_context): Likewise.
43294         (proceed_next_node): Likewise.
43295         (set_regs): Likewise.
43296         (free_fail_stack_return): Likewise.
43297         (check_arrival_expand_ecl): Mark DFA parameter as const.
43298         (check_arrival_expand_ecl_sub): Likewise.
43299         (check_subexp_limits): Likewise.
43300         (sub_epsilon_src_nodes):  Likewise.
43301         (add_epsilon_src_nodes):  Likewise.
43302         (merge_state_array): Likewise.
43303         (update_regs): Likewise.
43304         (build_trtable): Likewise.
43305         (sift_states_backward): Mark MCTX parameter as const.
43306         (build_sifted_states): Likewise.
43307         (update_cur_sifted_state): Likewise.
43308         (sift_states_mkref): Likewise.
43309         (check_arrival_expand_ecl): Mark eclosure as const.
43310         (check_dst_limits_calc_pos_1): Likewise.
43311         * lib/regex_internal.h (re_match_context_t): Make dfa a const
43312         pointer.
43313
43314         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
43315
43316         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
43317         (transit_state_sb): Likewise.
43318         (transit_state_mb): Likewise.
43319         (sift_states_iter_mb): Likewise.
43320         (check_arrival_add_next_nodes): Likewise.
43321         (check_node_accept_bytes): Change first parameter to pointer-to-const.
43322         [_LIBC] (re_search_2_stub): Use mempcpy.
43323
43324         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
43325         mbrtowc for very simple UTF-8 case.
43326
43327         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
43328         a pointer-to-const.
43329         (re_acquire_state_context): Likewise.
43330         * lib/regex_internal.h: Adjust prototypes.
43331
43332         * lib/regex.c: Prevent using C++ compilers.
43333
43334         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
43335         (re_acquire_state_context): Likewise.
43336
43337 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
43338
43339         * modules/regex (Depends-on): Add ssize_t.
43340
43341 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
43342
43343         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
43344         translation table.
43345
43346 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
43347
43348         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
43349
43350 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
43351             Bruno Haible  <bruno@clisp.org>
43352
43353         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
43354         <sys/types.h> and <inttypes.h>.
43355
43356 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
43357
43358         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
43359         `__error_t_defined', so argp.h will not typedef the former.
43360
43361 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
43362
43363         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
43364         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
43365         glibc names.  Even if glibc is changed to conform to POSIX, the
43366         traditional names will be available anyway, since regex depends on
43367         the extensions module.  Also, fix a longstanding typo in the
43368         implementation of Spencer ERE test #75 from grep 2.3.  Problems
43369         reported by Emanuele Giaquinta.  Also, change sense of cached
43370         variable, so that the message makes sense.
43371
43372 2006-03-24  Simon Josefsson  <jas@extundo.com>
43373
43374         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
43375         including some doc fixes.
43376         (base64_encode_alloc): Fix +1 bug on allocation failures.
43377
43378 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
43379
43380         * lib/base64.c (base64_encode): Do not read past end of array with
43381         unsanitized input on systems with CHAR_BIT > 8.
43382
43383 2006-03-24  Eric Blake  <ebb9@byu.net>
43384
43385         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
43386
43387 2006-03-22  Karl Berry  <karl@gnu.org>
43388
43389         * config/srclist.txt (*setenv.[ch]): get from coreutils.
43390         * config/srclistvars.sh (COREUTILS): new var.
43391
43392 2006-03-17  Jim Meyering  <jim@meyering.net>
43393
43394         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
43395         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
43396
43397 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
43398
43399         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
43400         no longer needs it.  Instead, check that regoff_t is as least
43401         as wide as ptrdiff_t.
43402
43403         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
43404         so that our regex.h stays compatible with the installed regex.
43405         This is helpful for installers who configure --without-included-regex.
43406         Problem reported by Emanuele Giaquinta.
43407
43408 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
43409
43410         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
43411         Typedef to long int, not to off_, as POSIX will likely change
43412         in that direction.
43413
43414 2006-03-15  Eric Blake  <ebb9@byu.net>
43415
43416         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
43417
43418 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
43419
43420         * lib/argp-help.c (validate_uparams): Fix typo
43421         * lib/argp-parse.c (argp_default_options): Consistently begin help
43422         messages with a lowercase letter.
43423
43424 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
43425
43426         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
43427         overrun buffers and shouldn't be used (much as gets shouldn't be
43428         used).
43429         * lib/time_r.c (asctime_r, ctime_r): Likewise.
43430
43431 2006-03-08  Simon Josefsson  <jas@extundo.com>
43432
43433         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
43434         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
43435
43436 2006-03-08  Simon Josefsson  <jas@extundo.com>
43437
43438         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
43439         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
43440
43441 2006-03-08  Simon Josefsson  <jas@extundo.com>
43442
43443         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
43444         signal that configure disabled the device.
43445
43446 2006-03-08  Simon Josefsson  <jas@extundo.com>
43447
43448         * build-aux/maint.mk: Fix refresh-po, to handle no translated
43449         languages.
43450
43451 2006-03-07  Simon Josefsson  <jas@extundo.com>
43452
43453         * modules/getopt (Depends-on): Add unistd.
43454
43455         * modules/unistd: New file.
43456
43457 2006-03-07  Simon Josefsson  <jas@extundo.com>
43458
43459         * modules/gc-random: New file.
43460
43461 2006-03-07  Simon Josefsson  <jas@extundo.com>
43462
43463         * m4/unistd_h.m4: New file.
43464
43465 2006-03-07  Simon Josefsson  <jas@extundo.com>
43466
43467         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
43468         test to be side-effect free by storing the result in the cache
43469         variable gl_cv_lib_readline, and moving the assignment of
43470         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
43471         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
43472
43473 2006-03-07  Simon Josefsson  <jas@extundo.com>
43474
43475         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
43476         error on missing devices (the functions will return an error).
43477
43478         * m4/gc.m4: Move random stuff to gc-random.m4
43479
43480 2006-03-07  Simon Josefsson  <jas@extundo.com>
43481
43482         * lib/unistd_.h: New file.
43483
43484 2006-03-07  Simon Josefsson  <jas@extundo.com>
43485
43486         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
43487
43488 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
43489
43490         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
43491         Problem reported by Juan Manuel Guerrero.
43492
43493 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
43494
43495         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
43496         the unistd module.
43497         * lib/getlogin_r.c: Likewise.
43498         * lib/getlogin_r.h: Likewise.
43499         * lib/glob.c: Likewise.
43500         * lib/pagealign_alloc.c: Likewise.
43501         * lib/unistd_.h: Remove; no longer needed.
43502
43503 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
43504
43505         * MODULES.html.sh (Support for systems lacking POSIX:2001):
43506         Add unistd.
43507         * modules/c-stack (Depends-on): Add unistd.
43508         * modules/getlogin_r: Likewise.
43509         * modules/glob: Likewise.
43510         * modules/pagealign_alloc: Likewise.
43511         * modules/unistd (Files): Remove lib/unistd_.h.
43512         (EXTRA_DIST): Remove.
43513         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
43514         need unistd_.h.
43515         (MOSTLYCLEANFILES): Remove unistd.h-t.
43516
43517 2006-03-03  Simon Josefsson  <jas@extundo.com>
43518
43519         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
43520
43521 2006-03-03  Simon Josefsson  <jas@extundo.com>
43522
43523         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
43524         libidn and bison.
43525
43526 2006-03-03  Simon Josefsson  <jas@extundo.com>
43527
43528         * build-aux/maint.mk: Add indent target.
43529
43530 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
43531
43532         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
43533         our replacement poll.h in any case, to avoid a differing
43534         declaration from a system header.  Seen on AIX.
43535
43536 2006-03-01  Simon Josefsson  <jas@extundo.com>
43537
43538         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
43539         <kasal@ucw.cz>.
43540
43541 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
43542
43543         * modules/gettime (Depends-on): Add extensions module.
43544         * modules/nanosleep (Depends-on): Likewise.
43545         * modules/settime (Depends-on): Likewise.
43546
43547 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
43548
43549         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
43550         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
43551         pedantically.
43552         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
43553         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
43554
43555         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
43556         not "==".  Reported by Ralf Wildenhues.
43557
43558 2006-03-01  Karl Berry  <karl@gnu.org>
43559
43560         * doc/Copyright/request-*: new files, synced from gnuorg.
43561
43562 2006-03-01  Karl Berry  <karl@gnu.org>
43563
43564         * config/srclist.txt (Copyright/*): new entries.
43565
43566 2006-02-28  Simon Josefsson  <jas@extundo.com>
43567
43568         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
43569
43570 2006-02-27  Simon Josefsson  <jas@extundo.com>
43571
43572         * lib/base64.h: Indent #define's.  From Jim Meyering
43573         <jim@meyering.net>.
43574
43575 2006-02-27  Jim Meyering  <jim@meyering.net>
43576
43577         Revert the change of 2006-02-24, so these files can continue
43578         to be sync'd from gettext.
43579         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
43580         of `config.h'.
43581
43582 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
43583
43584         * modules/intprops: New file.
43585         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
43586         Add intprops.
43587         * modules/getloadavg (Files): Remove lib/intprops.h.
43588         (Depends-on): Add intprops.
43589         * modules/human: Likewise.
43590         * modules/inttostr: Likewise.
43591         * modules/openat: Likewise.
43592         * modules/sig2str: Likewise.
43593         * modules/userspec: Likewise.
43594         * modules/utimecmp: Likewise.
43595         * modules/xnanosleep: Likewise.
43596         * modules/xstrtol: Likewise.
43597
43598 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
43599
43600         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
43601         * modules/lock-tests (TESTS): Use $(EXEEXT).
43602         * modules/tls-tests: Likewise.
43603         * modules/argp-tests: Likewise.
43604         (check_PROGRAMS): New var, replacing...
43605         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
43606
43607 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
43608
43609         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
43610         `config.h'.
43611
43612 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
43613
43614         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
43615
43616 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
43617
43618         Sync from coreutils.
43619         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
43620         gl_CHDIR_SAFER.
43621
43622 2006-02-22  Jim Meyering  <jim@meyering.net>
43623
43624         Sync from coreutils.
43625         * m4/chdir-safer.m4: New file.
43626
43627 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
43628
43629         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
43630         AT_FDCWD exceeds INT_MAX.
43631         * lib/openat.h (AT_FDCWD): Likewise.
43632
43633 2006-02-17  Eric Blake  <address@hidden>
43634
43635         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
43636
43637 2006-02-16  Simon Josefsson  <jas@extundo.com>
43638
43639         * modules/getaddrinfo (Depends-on): Add sys_socket.
43640
43641 2006-02-15  Simon Josefsson  <jas@extundo.com>
43642
43643         * build-aux/maint.mk: Add dsyntax-check rule.
43644
43645 2006-02-15  Eric Blake  <ebb9@byu.net>
43646
43647         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
43648         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
43649         'present but cannot compile' warnings on cygwin.
43650         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
43651         use ws2tcpip.h if sys/socket.h works.
43652         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
43653         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
43654
43655 2006-02-14  Simon Josefsson  <jas@extundo.com>
43656
43657         * modules/maintainer-makefile (Files): Rename.
43658
43659         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
43660         and (the local) Makefile.cfg to maint-cfg.mk.
43661
43662         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
43663         to the latter.
43664
43665         * modules/maintainer-makefile: New module.
43666
43667         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
43668         severaly stripped to make it possible to build it up from scratch
43669         with reliable tests.
43670
43671         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
43672         fixes to permit overriding the default actions when configure and
43673         makefile are not available.
43674
43675 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
43676
43677         Sync from coreutils.
43678         * modules/lstat (Depends-on): Don't depend on xalloc.
43679         (License): Change from GPL to LGPL, since this is now simply a
43680         replacement for a libc function.
43681
43682 2006-02-14  Jim Meyering  <jim@meyering.net>
43683
43684         Sync from coreutils.
43685
43686         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
43687         failure on deficient systems, and simplify gnulib lgpl dependencies.
43688         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
43689         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
43690
43691         * lib/xalloc-die.c: Remove unused definition of N_.
43692
43693 2006-02-14  Jim Meyering  <jim@meyering.net>
43694
43695         Sync from coreutils.
43696         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
43697         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
43698         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
43699         double-quote uses of that variable, to accommodate the rare case in
43700         which getmntent is available in none of the libraries checked.  This
43701         happens at least on FreeBSD 5.0.
43702
43703 2006-02-13  Simon Josefsson  <jas@extundo.com>
43704
43705         * gnulib-tool (Usage): Fix --import, from
43706         karl@freefriends.org (Karl Berry).
43707
43708 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
43709
43710         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
43711
43712 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
43713
43714         * lib/argp-namefrob.h: Restore changes accidentally lost during the
43715         "autoupdate" on 2005-12-12.
43716
43717 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
43718
43719         * modules/closeout (Depends-on): Remove atexit.
43720
43721 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
43722
43723         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
43724         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
43725
43726 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
43727
43728         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
43729         __EXTENSIONS__ if this causes compilation to fail.  Problem
43730         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
43731         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
43732
43733 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
43734
43735         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
43736         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
43737         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
43738         All uses changed.
43739
43740 2006-01-26  Simon Josefsson  <jas@extundo.com>
43741
43742         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
43743         prototype is visible on mingw32.
43744
43745         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
43746         for mingw32.
43747
43748         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
43749         mingw32).
43750
43751 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
43752
43753         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
43754         attempt to open for write; this always fails, at least on POSIX
43755         hosts.  This reinstates the 2006-01-09 change, which was
43756         inadvertently removed.
43757
43758 2006-01-26  Bruno Haible  <bruno@clisp.org>
43759
43760         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
43761         Reported by Paul Eggert.
43762
43763 2006-01-26  Bruno Haible  <bruno@clisp.org>
43764             Paul Eggert  <eggert@cs.ucla.edu>
43765
43766         * lib/stdbool_.h (_Bool)
43767         [(! (defined __cplusplus || defined __BEOS__)
43768           && !defined __GNUC__
43769           && !(defined __HP_cc || defined __xlc__
43770                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
43771                || defined __sgi))]:
43772         #define to signed char in these cases too; this simplifies
43773         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
43774         etc., separately) and makes it more conservative.
43775
43776 2006-01-25  Simon Josefsson  <jas@extundo.com>
43777
43778         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
43779         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
43780         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
43781
43782 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
43783
43784         * lib/argp-namefrob.h: Bugfix. Remove stray #
43785
43786 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
43787
43788         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
43789         so that we test the test.
43790         Check for yet another HP-UX cc bug involving *bool |= bool.
43791
43792 2006-01-25  Karl Berry  <karl@gnu.org>
43793
43794         * config/srclist.txt (vasnprintf.c): sync lost.
43795
43796 2006-01-25  Jim Meyering  <jim@meyering.net>
43797
43798         Sync from the stable (b5) branch of coreutils:
43799
43800         * lib/fts.c (fts_children): Don't let close() clobber errno from
43801         failed fchdir().
43802
43803         * lib/fts.c (fts_stat): When following a symlink-to-directory,
43804         don't necessarily interpret stat-fails+lstat-succeeds as indicating
43805         a dangling symlink.  That can also happen at least for ELOOP.
43806         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
43807         FYI, this bug predates the inclusion of fts.c in coreutils.
43808
43809         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
43810         in their own block, so pre-c99 compilers don't object.
43811
43812         Avoid the double-free (first in fts_read, second in fts_close) that
43813         would occur when an `active' directory is made inaccessible (e.g.,
43814         via chmod a-x) during a traversal.
43815         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
43816         before returning.  Reproduce this failure by
43817         mkdir -p a/b; cd a; chmod a-x . b
43818         Reported by Stavros Passas.
43819
43820 2006-01-25  Jim Meyering  <jim@meyering.net>
43821
43822         * lib/fileblocks.c: Remove more useless parentheses.
43823         * lib/readutmp.h: Likewise.
43824
43825 2006-01-25  Bruno Haible  <bruno@clisp.org>
43826
43827         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
43828         warnings.
43829         Reported by Paul Eggert.
43830
43831 2006-01-25  Bruno Haible  <bruno@clisp.org>
43832
43833         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
43834         rid of a trap command. For Solaris sh.
43835         Reported by Mark D. Baushke <mdb@gnu.org>.
43836
43837 2006-01-24  Simon Josefsson  <jas@extundo.com>
43838
43839         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
43840         Bruno.
43841
43842 2006-01-24  Karl Berry  <karl@gnu.org>
43843
43844         * config/srclist.txt (argp-namefrob.h): sync lost.
43845
43846 2006-01-24  Jim Meyering  <jim@meyering.net>
43847
43848         * modules/openat (Files): Add lib/intprops.h.
43849         From Mark D. Baushke.
43850
43851 2006-01-24  Jim Meyering  <jim@meyering.net>
43852
43853         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
43854         Reported by Mark D. Baushke.
43855
43856 2006-01-24  Jim Meyering  <jim@meyering.net>
43857
43858         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
43859
43860 2006-01-24  Bruno Haible  <bruno@clisp.org>
43861
43862         * modules/strnlen (Maintainer): Change from glibc to all.
43863
43864 2006-01-24  Bruno Haible  <bruno@clisp.org>
43865
43866         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
43867         Patch by Paul Eggert.
43868
43869 2006-01-24  Bruno Haible  <bruno@clisp.org>
43870
43871         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
43872         already has it.
43873         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
43874         2005-11-26.
43875
43876         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
43877         'signed char' to avoid problems with the built-in _Bool type.
43878         Reported by Paul Eggert on 2005-11-26.
43879
43880 2006-01-24  Bruno Haible  <bruno@clisp.org>
43881
43882         * gnulib-tool (func_import): Avoid constructing complicated sed
43883         expressions inside backquote.
43884         Report and solution by Mark D. Baushke <mdb@gnu.org>.
43885
43886 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
43887
43888         These changes imported from libc.
43889         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
43890         test and two separate function calls.
43891         * lib/strndup.c (__strndup): Add libc_hidden_def.
43892
43893 2006-01-23  Simon Josefsson  <jas@extundo.com>
43894
43895         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
43896         Remove the test_*_SOURCES variable: automake infers it by default.
43897         * modules/tls-tests: Likewise.
43898
43899 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
43900
43901         Work around porting bugs reported by Dieter in
43902         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
43903         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
43904         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
43905         Include "getopt.h" first, to check interface.
43906         (getenv): Declare only if defined HAVE_DECL_GETENV &&
43907         !HAVE_DECL_GETENV.
43908         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
43909         (__strndup): Revert to K&R-style function dfns, the glibc style.
43910         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
43911         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
43912         Include strnlen.h first, to get prototype properly.
43913         (strnlen): Renamed from __strnlen.
43914         Remove weak alias.
43915
43916 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
43917
43918         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
43919
43920 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
43921
43922         * config/srclist.txt: Adjust to reflect glibc reorganization.
43923         This affects only comments.
43924
43925 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
43926
43927          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
43928          Reported by Bruce Korb <bkorb@gnu.org>.
43929
43930 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
43931
43932         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
43933         to pacify gcc -Wswitch-default.
43934
43935 2006-01-22  Bruno Haible  <bruno@clisp.org>
43936
43937         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
43938         temporary buffer for sprintf, take into account the precision also
43939         for 'd', 'i', 'u', 'o', 'x', 'X'.
43940
43941 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
43942
43943         * modules/argp-tests: New module
43944         * tests/test-argp.c: New file
43945         * tests/test-argp-2.sh: New file
43946
43947 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
43948
43949         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
43950         (__argp_base_name): Removed
43951         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
43952         typo.
43953         (__argp_base_name): Provide macro definition or extern declaration
43954         depending on the configuration
43955
43956 2006-01-20  Simon Josefsson  <jas@extundo.com>
43957
43958         * modules/inet_ntop (Depends-on): Depend on sys_socket.
43959
43960 2006-01-20  Simon Josefsson  <jas@extundo.com>
43961
43962         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
43963
43964 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
43965
43966         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
43967         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
43968         Suggested by Bruno Haible.
43969
43970 2006-01-20  Karl Berry  <karl@gnu.org>
43971
43972         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
43973         until changes propagate, I guess.
43974
43975 2006-01-19  Simon Josefsson  <jas@extundo.com>
43976
43977         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
43978
43979 2006-01-19  Simon Josefsson  <jas@extundo.com>
43980
43981         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
43982
43983 2006-01-19  Simon Josefsson  <jas@extundo.com>
43984
43985         * gnulib-tool: Set check_PROGRAMS.
43986
43987         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
43988         modules/des-tests, modules/gc-arcfour-tests,
43989         modules/gc-arctwo-tests, modules/gc-des-tests,
43990         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
43991         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
43992         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
43993         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
43994         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
43995         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
43996         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
43997         test_*_SOURCES.
43998
43999 2006-01-18  Simon Josefsson  <jas@extundo.com>
44000
44001         * modules/socklen (Depends-on): Depend on sys_socket.
44002
44003 2006-01-18  Simon Josefsson  <jas@extundo.com>
44004
44005         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
44006         modules/des-tests, modules/gc-arcfour-tests,
44007         modules/gc-arctwo-tests, modules/gc-des-tests,
44008         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
44009         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
44010         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
44011         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
44012         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
44013         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
44014         $(EXEEXT) to automake TESTS variable, for mingw32.
44015
44016 2006-01-17  Simon Josefsson  <jas@extundo.com>
44017
44018         * modules/socklen (Include): Need sys/socket.h.
44019
44020 2006-01-17  Bruno Haible  <bruno@clisp.org>
44021
44022         * modules/ssize_t (Include): Add <sys/types.h>.
44023
44024 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
44025
44026         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
44027         it's not portable and it doesn't work with cross-compiles.
44028         Problem reported by Bruno Haible.  Fix missing-$ typo in
44029         'test "gl_cv_ignore_unused_libraries" ...' that prevented
44030         -zignore from being used with Sun's C compiler.
44031
44032 2006-01-12  Simon Josefsson  <jas@extundo.com>
44033
44034         * lib/base64.c: Fix warning, reported by Bruno Haible
44035         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
44036
44037 2006-01-12  Bruno Haible  <bruno@clisp.org>
44038
44039         * modules/ldd: New file.
44040         * build-aux/ldd.sh.in: New file.
44041         * MODULES.html.sh (Support for building libraries and executables): Add
44042         ldd.
44043
44044 2006-01-12  Bruno Haible  <bruno@clisp.org>
44045
44046         * m4/ldd.m4: New file.
44047
44048 2006-01-12  Bruno Haible  <bruno@clisp.org>
44049
44050         * gnulib-tool (func_import, func_create_testdir): Don't go into an
44051         endless loop while replacing $auxdir with build-aux.
44052
44053 2006-01-11  Simon Josefsson  <jas@extundo.com>
44054
44055         * lib/stdint_.h (SIZE_MAX): Add missing (.
44056
44057 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
44058
44059         Sync from coreutils.
44060         * lib/md5.c: Fix commentary typos.
44061         (alignof, UNALIGNED_P): No need for a GCC-specific version.
44062         * lib/md5.h (__attribute__): Remove; unused.
44063         * lib/sha1.c: Fix commentary to match md5 better.
44064         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
44065         so that we don't need to worry about alignment.  All uses changed.
44066         This merges the 2005-10-28 md5 change into sha1.
44067
44068 2006-01-11  Jim Meyering  <jim@meyering.net>
44069
44070         Sync from coreutils.
44071         * lib/md5.c (OP): Fix spacing.
44072
44073 2006-01-11  Bruno Haible  <bruno@clisp.org>
44074
44075         Ensure automatic ordering between gl_LOCK and gl_ARGP.
44076         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
44077         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
44078
44079 2006-01-11  Bruno Haible  <bruno@clisp.org>
44080
44081         Ensure automatic ordering between gl_LOCK and gl_ARGP.
44082         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
44083         the "early" section as well.
44084
44085 2006-01-11  Bruno Haible  <bruno@clisp.org>
44086
44087         Avoid "ar: no archive members specified" error on MacOS X.
44088         * gnulib-tool (func_modules_add_dummy): New function.
44089         (func_import, func_create_testdir): Invoke it.
44090
44091 2006-01-11  Bruno Haible  <bruno@clisp.org>
44092
44093         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
44094         with $auxdir in AC_CONFIG_FILES statements.
44095
44096 2006-01-11  Bruno Haible  <bruno@clisp.org>
44097
44098         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
44099         Initialize also noinst_HEADERS to empty.
44100
44101 2006-01-11  Bruno Haible  <bruno@clisp.org>
44102
44103         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
44104         variables.
44105         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
44106         autoreconf.
44107
44108 2006-01-11  Bruno Haible  <bruno@clisp.org>
44109
44110         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
44111         overridable by the user.
44112         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
44113
44114 2006-01-10  Simon Josefsson  <jas@extundo.com>
44115
44116         * modules/sys_socket: New file.
44117
44118 2006-01-10  Simon Josefsson  <jas@extundo.com>
44119
44120         * m4/sys_socket_h.m4: New file.
44121
44122 2006-01-10  Simon Josefsson  <jas@extundo.com>
44123
44124         * lib/socket_.h: New file.
44125
44126 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
44127
44128         * modules/readutmp (Maintainer): Add myself.
44129
44130 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
44131
44132         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
44133         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
44134         People who are still concerned with buggy memcmp implementations
44135         can invoke gl_FUNC_MEMCMP themselves.
44136
44137 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
44138
44139         * lib/regex_internal.h (BITSET_WORD_BITS):
44140         Work around a bug in 64-bit PGC (before version 6.1-2), where the
44141         preprocessor mishandles large unsigned values as if they were signed.
44142         Problem reported by Claudio Fontana in
44143         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
44144
44145 2006-01-10  Jim Meyering  <jim@meyering.net>
44146
44147         Avoid the double-free (first in fts_read, second in fts_close) that
44148         would occur when an `active' directory is made inaccessible (e.g.,
44149         via chmod a-x) during a traversal.
44150         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
44151         before returning.  Reproduce this failure by
44152         mkdir -p a/b; cd a; chmod a-x . b
44153         Reported by Stavros Passas.
44154
44155         Sync from coreutils.
44156         * lib/sha1.c: Tweak grammar in a comment.
44157
44158 2006-01-10  Jim Meyering  <jim@meyering.net>
44159
44160         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
44161         Patch by Joerg Sonnenberger.
44162
44163 2006-01-10  Bruno Haible  <bruno@clisp.org>
44164
44165         * modules/readutmp: Depend on module free.
44166         * modules/strtok_r: Depend on module restrict.
44167
44168 2006-01-10  Bruno Haible  <bruno@clisp.org>
44169
44170         * modules/gettext (configure.ac): Add an invocation of
44171         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
44172
44173 2006-01-10  Bruno Haible  <bruno@clisp.org>
44174
44175         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
44176         Reported by Werner Lemberg <wl@gnu.org>.
44177
44178 2006-01-10  Bruno Haible  <bruno@clisp.org>
44179
44180         * lib/localcharset.c: Update from GNU gettext.
44181
44182 2006-01-10  Bruno Haible  <bruno@clisp.org>
44183
44184         * lib/argp.h (__const): Remove macro. Use const instead.
44185         * lib/argp-fmtstream.h (__const): Likewise.
44186         * lib/glob_.h (__const): Remove macro.
44187         * lib/glob-libc.h: Use const instead of __const.
44188
44189 2006-01-10  Bruno Haible  <bruno@clisp.org>
44190
44191         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
44192         variable.
44193         Needed to avoid an automake error regarding the 'gettext' module.
44194
44195 2006-01-09  Simon Josefsson  <jas@extundo.com>
44196
44197         * modules/inet_ntop (Depends-on): Add restrict.
44198
44199 2006-01-09  Simon Josefsson  <jas@extundo.com>
44200
44201         * modules/gc-rijndael-tests (License): Put under LGPL.
44202
44203         * modules/gc-des-tests (License): Likewise.
44204
44205         * modules/gc-arcfour-tests (License): Likewise.
44206
44207         * modules/gc-arctwo-tests (License): Likewise.
44208
44209         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
44210
44211         * modules/gc-hmac-sha1-tests (Files): Likewise.
44212
44213         * modules/gc-hmac-md5-tests (License): Likewise.
44214
44215         * modules/gc-sha1-tests (License): Likewise.
44216
44217         * modules/gc-md5-tests (License): Likewise.
44218
44219         * modules/gc-md4-tests (License): Likewise.
44220
44221         * modules/gc-md2-tests (License): Likewise.
44222
44223         * modules/gc-tests (License): Likewise.
44224
44225         * modules/des-tests (License): Likewise.
44226
44227         * modules/md4-tests (License): Likewise.
44228
44229         * modules/md2-tests (License): Likewise.
44230
44231 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
44232
44233         Sync from coreutils:
44234
44235         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
44236         * modules/lib-ignore: New file.
44237         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
44238         chdir-safer.m4, lchmod.m4.
44239         * modules/openat: Add mkdirat.c, openat-priv.h.
44240
44241 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
44242
44243         Sync from coreutils.
44244         * m4/lib-ignore.m4: New file.
44245         * m4/lchmod.m4: New file.
44246
44247 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
44248
44249         Sync from coreutils.
44250         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
44251         for write access: POSIX says that must fail.
44252         * lib/fts.c (diropen): Likewise.
44253         * lib/save-cwd.c (save_cwd): Likewise.
44254         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
44255         well, for minor improvements on hosts that lack O_DIRECTORY.
44256         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
44257         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
44258         Fall back on chown if open failed with EACCES.
44259
44260         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
44261         Report an error at compile-time if only a 1-second nominal clock
44262         resolution is found.
44263
44264         * lib/lchmod.h: New file.
44265         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
44266         (make_dir_parents): Use lchown rather than chown, and
44267         lchmod rather than chmod.
44268
44269         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
44270         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
44271         "proc" reported by n0dalus.
44272
44273         * lib/mountlist.c: Include <limits.h>.
44274         (dev_from_mount_options)
44275         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
44276         New function.  It no longer assumes "dev=" has the System V meaning
44277         on Linux (since it doesn't).  It also parses "dev=" more carefully.
44278         (read_file_system_list)
44279         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
44280         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
44281         dev= in that case.
44282
44283         * lib/posixtm.h (PDS_PRE_2000): New macro.
44284         * lib/posixtm.c (year): Arg is now syntax_bits rather than
44285         allow_century.  All usages changed.  Reject dates outside the range
44286         1969-1999 if PDS_PRE_2000 is used.
44287
44288 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
44289
44290         Sync from coreutils.
44291         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
44292         (Time of day items): Mention the possibility of leap seconds.
44293         Problem reported by Dr. David Alan Gilbert.
44294
44295 2006-01-09  Jim Meyering  <jim@meyering.net>
44296
44297         Sync from coreutils.
44298
44299         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
44300
44301         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
44302
44303         * lib/modechange.c (mode_compile): Reject an invalid mode string
44304         that starts with an octal digit.  From Andreas Gruenbacher.
44305
44306         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
44307         and dup to open_safer and dup_safer, respectively.
44308         (openat_permissive): Fix typo in comment.
44309
44310         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
44311         "gettext.h"; either no longer needed or are guaranteed by openat.h.
44312         (_): Remove; no longer needed.
44313         (openat): Renamed from rpl_openat; no need for rpl_openat
44314         since openat.h renames openat for us.
44315         Replace most of the body with a call to openat_permissive,
44316         to avoid duplicate code.
44317         Port to (probably hypothetical) environments were mode_t is
44318         wider than int.
44319         (openat_permissive): Require mode arg, so that we can check
44320         types better.  Put it just after flags.  Change cwd failure
44321         indicator from pointer-to-bool to pointer-to-errno-value.
44322         All callers changed.
44323         Invoke openat_save_fail and/or openat_restore_fail if
44324         cwd_errno is null, so that openat can call us.
44325         (openat_permissive, fdopendir, fstatat, unlinkat):
44326         Simplify errno handling to avoid some duplicate code,
44327         as it's OK to set errno on success.
44328         * lib/openat.h: Revamp code so that function macros depend on
44329         __OPENAT_PREFIX only, not also on AT_FDCWD.
44330         (openat_ro): Remove.  Caller changed to use openat_permissive.
44331         (openat_permissive): Now a macro, if not a function.
44332         (openat_restore_fail, openat_save_fail): Now always functions,
44333         since mkdirat needs them even if __OPENAT_PREFIX is defined.
44334
44335         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
44336         and openat.c.
44337         * lib/mkdirat.c: Include openat-priv.h.
44338         Remove definitions of macros defined therein.
44339         * lib/openat.c: Likewise.
44340
44341         * lib/mkdirat.c (mkdirat): New file and function.
44342         * lib/openat.h (mkdirat): Declare.
44343
44344         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
44345
44346         * lib/openat.h (openat_permissive): Declare.
44347         (openat_ro): Define.
44348
44349         * lib/openat.c (EXPECTED_ERRNO): New macro.
44350         (openat_permissive): New function -- used in remove.c rewrite.
44351         (all functions): Set errno just before returning, only if there
44352         was an actual failure.
44353         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
44354
44355         Emulate openat-family functions using Linux's procfs, if possible.
44356         Idea and some code based on Ulrich Drepper's glibc changes.
44357
44358         * lib/openat.c: (BUILD_PROC_NAME): New macro.
44359         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
44360         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
44361         before falling back on save_cwd and restore_cwd.
44362         (fdopendir, fstatat, unlinkat): Likewise.
44363
44364         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
44365         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
44366
44367         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
44368         as second argument to va_arg.  Otherwise, some versions of gcc
44369         warn that `if this code is reached, the program will abort'.
44370
44371 2006-01-09  Jim Meyering  <jim@meyering.net>
44372
44373         Sync from coreutils.
44374         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
44375         Require openat-priv.h.
44376
44377 2006-01-09  Bruno Haible  <bruno@clisp.org>
44378
44379         * modules/strnlen (Include): Use strnlen.h.
44380
44381 2006-01-09  Bruno Haible  <bruno@clisp.org>
44382
44383         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
44384
44385 2006-01-09  Bruno Haible  <bruno@clisp.org>
44386
44387         * lib/sysexit_.h (EX_OK): New macro.
44388         Suggested by Martin Lambers <marlam@marlam.de>.
44389
44390 2006-01-09  Bruno Haible  <bruno@clisp.org>
44391
44392         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
44393         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
44394
44395 2006-01-09  Bruno Haible  <bruno@clisp.org>
44396
44397         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
44398         numbers.
44399
44400 2006-01-09  Bruno Haible  <bruno@clisp.org>
44401
44402         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
44403         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
44404         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
44405         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
44406
44407 2006-01-09  Bruno Haible  <bruno@clisp.org>
44408
44409         * build-aux/javacomp.sh.in: New file, moved from lib/.
44410         * modules/javacomp-script (Files): Update.
44411         (configure.ac): Add AC_CONFIG_FILES invocation.
44412         (EXTRA_DIST): Remove variable.
44413
44414         * build-aux/javaexec.sh.in: New file, moved from lib/.
44415         * modules/javaexec (Files): Update.
44416         (configure.ac): Add AC_CONFIG_FILES invocation.
44417         (EXTRA_DIST): Remove javaexec.sh.in.
44418
44419         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
44420         * modules/csharpcomp-script (Files): Update.
44421         (configure.ac): Add AC_CONFIG_FILES invocation.
44422         (EXTRA_DIST): Remove variable.
44423
44424         * build-aux/csharpexec.sh.in: New file, moved from lib/.
44425         * modules/csharpexec (Files): Update.
44426         (configure.ac): Add AC_CONFIG_FILES invocation.
44427         (EXTRA_DIST): Remove csharpexec.sh.in.
44428
44429 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
44430
44431         Sync from coreutils.
44432
44433         Add POSIX ACL support
44434         * lib/acl.h (copy_acl, set_acl): Add declarations.
44435         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
44436         systems other than Linux.
44437         (chmod_or_fchmod): New function: use fchmod when possible,
44438         and chmod otherwise.
44439         (file_has_acl): Add a POSIX ACL implementation, with a
44440         Linux-specific subcase.
44441         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
44442         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
44443         acls are unsupported.
44444         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
44445         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
44446         are unsupported.
44447
44448 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
44449
44450         Sync from coreutils.
44451         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
44452
44453 2006-01-07  Bruno Haible  <bruno@clisp.org>
44454
44455         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
44456         gl_EARLY.
44457
44458 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
44459
44460         * lib/strftime.c (tzname): Don't declare if it is already #defined.
44461         Problem reported for Mingw by Mark Junker.
44462
44463 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
44464
44465         * README: Gnulib normally doesn't generate a tarball.
44466
44467 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
44468
44469         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
44470         long int, not int, for nanosecond counts, so that people who are
44471         used to POSIX struct timespec won't be surprised.  Reported by Jim
44472         Meyering.
44473
44474 2005-12-28  Bruno Haible  <bruno@clisp.org>
44475
44476         * build-aux/config.rpath: Update from GNU gettext.
44477
44478 2005-12-16  Jim Meyering  <jim@meyering.net>
44479
44480         * modules/fprintftime: New module.
44481         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
44482
44483 2005-12-16  Jim Meyering  <jim@meyering.net>
44484
44485         * m4/fprintftime.m4: New file.
44486
44487 2005-12-16  Jim Meyering  <jim@meyering.net>
44488
44489         * lib/fprintftime.c, lib/fprintftime.h: New files.
44490
44491 2005-12-15  Simon Josefsson  <jas@extundo.com>
44492
44493         * modules/socklen (configure.ac): Fix M4 macro name, to align with
44494         new m4/socklen.m4.
44495
44496 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
44497
44498         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
44499         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
44500
44501 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
44502
44503         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
44504         * lib/argp-help.c (fill_in_uparams): Check if the constructed
44505         struct uparams is valid. Fall back to the default values if it is
44506         not.
44507
44508 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
44509
44510         * modules/argp (Files): Add argp-pin.c
44511         (Depends-on): dirname
44512         (lib_SOURCES): Add argp-pin.c
44513
44514 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
44515
44516         * m4/argp.m4:  Check if program_invocation_name and
44517         program_invocation_short_name are declared and define appropriate
44518         macros if they are not.
44519
44520 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
44521
44522         * lib/argp-help.c (__argp_base_name): New function
44523         (__argp_short_program_name): Rewrite using __argp_base_name
44524         * lib/argp-namefrob.h: Define program_invocation_name and
44525         program_invocation_short_name if requested
44526         (__argp_base_name): Add prototype
44527         * lib/argp-parse.c (argp_def): Use gettext wrappers
44528         (argp_default_parser): Use __argp_base_name
44529         * lib/argp-pin.c: New file. Defines program_invocation_name and
44530         program_invocation_short_name on systems that lack them.
44531
44532 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
44533
44534         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
44535         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
44536         porting problem reported by Georg Schwarz in
44537         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
44538
44539 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
44540
44541         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
44542         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
44543         porting problem reported by Georg Schwarz in
44544         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
44545
44546 2005-12-05  Bruno Haible  <bruno@clisp.org>
44547
44548         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
44549         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
44550         Reported by Mark Junker <mjscod@gmx.de>.
44551
44552 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
44553
44554         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
44555         Use implementation from Albert Chin, with some
44556         comments/corrections by Stepan Kasal and myself.
44557
44558 2005-12-02  Bruno Haible  <bruno@clisp.org>
44559
44560         * gnulib-tool (func_import): Accept GPLed build tool modules when
44561         --lgpl is given.
44562         * modules/csharpcomp-script: New file.
44563         * modules/csharpcomp: Depend on it.
44564         * modules/javacomp-script: New file.
44565         * modules/javacomp: Depend on it.
44566         Suggested by Simon Josefsson.
44567
44568 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
44569
44570         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
44571         statement, to work around an HP-UX 10.20 compiler bug reported by
44572         Peter O'Gorman.
44573
44574 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
44575
44576         * modules/savedir (Depends-on): Add openat.
44577
44578 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
44579
44580         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
44581         (uintmax_t) [defined uintmax_t]: Do not declare.
44582         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
44583         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
44584         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
44585         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
44586         sake of portability to weird hosts that C allows (though we don't
44587         know of any practical examples).
44588
44589         * lib/savedir.h (fdsavedir): New decl.
44590         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
44591         contains most of the former guts of savedir.
44592         (savedir): Use savedirstream.
44593         Include "openat.h".
44594
44595 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
44596
44597         * modules/obstack (Files): Add m4/ulonglong.m4.
44598         Problem reported by Davide Angelocola.
44599
44600 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
44601
44602         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
44603         coreutils no longer futzes with rounding modes.
44604
44605 2005-11-14  Jim Meyering  <jim@meyering.net>
44606
44607         * lib/mkstemp-safer.c: Include <config.h>, required for possible
44608         replacement of mkstemp.
44609
44610 2005-11-10  Simon Josefsson  <jas@extundo.com>
44611
44612         * lib/readline.c: Remove EOL.
44613
44614 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
44615
44616         * modules/gethrxtime (Depends-on): Add gettime.
44617
44618 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
44619
44620         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
44621         or gettimeofday; no longer needed.
44622
44623 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
44624
44625         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
44626         time business.
44627         (gethrxtime) [! (HAVE_NANOUPTIME
44628         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
44629         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
44630         our own approximation.
44631
44632 2005-11-08  Eric Blake  <ebb9@byu.net>
44633
44634         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
44635
44636 2005-11-08  Eric Blake  <ebb9@byu.net>
44637
44638         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
44639
44640 2005-11-04  Bruno Haible  <bruno@clisp.org>
44641
44642         * gnulib-tool: Implement --update mode.
44643
44644 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
44645
44646         Fix porting problem reported by Theodoros V. Kalamatianos.
44647         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
44648         Don't assume that futimes failing means we must fail.
44649
44650 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
44651
44652         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
44653         variables to suggest the intended function of the PATH_MAX check.
44654
44655 2005-10-30  Kean Johnston  <jkj@sco.com>
44656
44657         Trivial changes to support SCO systems.
44658         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
44659         as PATH_MAX.
44660         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
44661         where __ptr is null when no I/O is pending.
44662
44663 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
44664
44665         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
44666         leave errno alone.  Problem reported by Dmitry V. Levin.
44667
44668 2005-10-28  Simon Josefsson  <jas@extundo.com>
44669
44670         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
44671         Test more.
44672
44673         * tests/test-gc-md2.c, tests/test-md2.c: New files.
44674
44675         * modules/md2, modules/md2-tests: New files.
44676
44677 2005-10-28  Simon Josefsson  <jas@extundo.com>
44678
44679         * m4/inet_ntop.m4: More tests.
44680
44681         * m4/gc-md2.m4, md2.m4: New file.
44682
44683 2005-10-28  Simon Josefsson  <jas@extundo.com>
44684
44685         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
44686         "restrict" keywords, as per POSIX.  Protect the function
44687         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
44688         Don't use K&R prototypes.  Check the sprintf return values.
44689         Re-define EAFNOSUPPORT if not present.  Indent.
44690
44691         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
44692         suggested by Bruno Haible <bruno@clisp.org>.
44693
44694         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
44695
44696         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
44697
44698         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
44699         libgcrypt).
44700
44701         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
44702
44703         * lib/md2.h, lib/md2.c: New files.
44704
44705 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
44706
44707         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
44708         errno alone.  Problem reported by Frederic Jolliton.
44709
44710 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
44711
44712         * modules/verify (License): Change from GPL to LGPL.  This is a
44713         tiny module and there are apparently near-equivalents that are
44714         under the BSD license.
44715
44716 2005-10-24  Simon Josefsson  <jas@extundo.com>
44717
44718         * modules/sha1: Relicense to LGPL.
44719
44720 2005-10-24  Simon Josefsson  <jas@extundo.com>
44721
44722         * lib/md4.h: Shrink buffer size, now that we changed the type.
44723
44724 2005-10-23  Simon Josefsson  <jas@extundo.com>
44725
44726         * gnulib-tool (func_import): Fix --tests-base.
44727
44728 2005-10-22  Simon Josefsson  <jas@extundo.com>
44729
44730         * modules/arcfour (Depends-on): Need stdint.
44731
44732 2005-10-22  Simon Josefsson  <jas@extundo.com>
44733
44734         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
44735         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
44736
44737 2005-10-22  Simon Josefsson  <jas@extundo.com>
44738
44739         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
44740         suggested by Bruno Haible <bruno@clisp.org>.
44741
44742 2005-10-22  Simon Josefsson  <jas@extundo.com>
44743
44744         * lib/crc.h: Include stddef.h, for size_t.
44745
44746 2005-10-22  Simon Josefsson  <jas@extundo.com>
44747
44748         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
44749         arcfour_context struct (simplify test vector testing in GNU
44750         Shishi).
44751
44752 2005-10-21  Simon Josefsson  <jas@extundo.com>
44753
44754         * modules/des, modules/des-tests: New files.
44755
44756         * modules/gc-des, modules/gc-des-tests: New files.
44757
44758         * tests/test-des.c, tests/test-gc-des.c: New file.
44759
44760 2005-10-21  Simon Josefsson  <jas@extundo.com>
44761
44762         * modules/arctwo, modules/arctwo-tests: New files.
44763
44764         * tests/test-arctwo.c: New file.
44765
44766         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
44767
44768         * tests/test-gc-arctwo.c: New file.
44769
44770 2005-10-21  Simon Josefsson  <jas@extundo.com>
44771
44772         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
44773         Bruno Haible <bruno@clisp.org>.
44774
44775         * m4/gc-des.m4: New file.
44776
44777 2005-10-21  Simon Josefsson  <jas@extundo.com>
44778
44779         * m4/arctwo.m4: New file.
44780
44781         * m4/gc-arctwo.m4: New file.
44782
44783 2005-10-21  Simon Josefsson  <jas@extundo.com>
44784
44785         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
44786         block.
44787
44788 2005-10-21  Simon Josefsson  <jas@extundo.com>
44789
44790         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
44791         <bruno@clisp.org>.
44792
44793         * lib/hmac-sha1.c (hmac_sha1): Likewise.
44794
44795         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
44796         Bruno Haible <bruno@clisp.org>.
44797
44798         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
44799         <bruno@clisp.org>.
44800
44801 2005-10-21  Simon Josefsson  <jas@extundo.com>
44802
44803         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
44804
44805 2005-10-21  Simon Josefsson  <jas@extundo.com>
44806
44807         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
44808
44809 2005-10-21  Simon Josefsson  <jas@extundo.com>
44810
44811         * lib/des.h, lib/des.c: New files.
44812
44813         * lib/gc-gnulib.c: Support DES.c
44814
44815 2005-10-21  Simon Josefsson  <jas@extundo.com>
44816
44817         * lib/arctwo.h, lib/arctwo.c: New files.
44818
44819         * lib/gc-gnulib.c: Support ARCTWO.
44820
44821 2005-10-21  Simon Josefsson  <jas@extundo.com>
44822
44823         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
44824         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
44825
44826 2005-10-21  Simon Josefsson  <jas@extundo.com>
44827
44828         * gnulib-tool (func_import, func_create_testdir): Define automake
44829         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
44830         Makefile.am snippet),
44831         suggested by Bruno Haible <bruno@clisp.org>.
44832
44833         * modules/gc (Makefile.am): Use it.
44834
44835 2005-10-21  Bruno Haible  <bruno@clisp.org>
44836
44837         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
44838         patch.
44839
44840 2005-10-19  Simon Josefsson  <jas@extundo.com>
44841
44842         * tests/test-gc-rijndael.c: New file.
44843
44844         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
44845
44846 2005-10-19  Simon Josefsson  <jas@extundo.com>
44847
44848         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
44849         interface too.
44850
44851 2005-10-19  Simon Josefsson  <jas@extundo.com>
44852
44853         * tests/test-gc-arcfour.c: New file.
44854
44855         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
44856
44857 2005-10-19  Simon Josefsson  <jas@extundo.com>
44858
44859         * modules/gc-md4, modules/gc-md4-tests: New file.
44860
44861         * tests/test-gc-md4.c: New file.
44862
44863 2005-10-19  Simon Josefsson  <jas@extundo.com>
44864
44865         * m4/gc-md4.m4: New file.
44866
44867 2005-10-19  Simon Josefsson  <jas@extundo.com>
44868
44869         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
44870         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
44871         <kasal@ucw.cz>.
44872
44873 2005-10-19  Simon Josefsson  <jas@extundo.com>
44874
44875         * m4/gc-arcfour.m4: New file.
44876
44877         * m4/gc-rijndael.m4: New file.
44878
44879 2005-10-19  Simon Josefsson  <jas@extundo.com>
44880
44881         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
44882
44883 2005-10-19  Simon Josefsson  <jas@extundo.com>
44884
44885         * lib/gc-gnulib.c: Support ARCFOUR.
44886
44887 2005-10-19  Simon Josefsson  <jas@extundo.com>
44888
44889         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
44890         support.
44891
44892         * lib/gc.h: Add ECB enum type.
44893
44894         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
44895
44896 2005-10-18  Simon Josefsson  <jas@extundo.com>
44897
44898         * tests/test-md5.c: New file.
44899
44900         * modules/md5-tests: New file.
44901
44902 2005-10-18  Simon Josefsson  <jas@extundo.com>
44903
44904         * tests/test-md4.c: New file.
44905
44906         * modules/md4, modules/md4-tests: New files.
44907
44908 2005-10-18  Simon Josefsson  <jas@extundo.com>
44909
44910         * m4/md4.m4: New file.
44911
44912 2005-10-18  Simon Josefsson  <jas@extundo.com>
44913
44914         * lib/md4.h, lib/md4.c: New files, based on md5.?.
44915
44916 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
44917
44918         * gnulib-tool (func_create_testdir): Omit the second check whether
44919         BUILT_SOURCES in nonempty.
44920
44921 2005-10-17  Simon Josefsson  <jas@extundo.com>
44922
44923         * tests/test-rijndael.c: New file.
44924
44925 2005-10-17  Simon Josefsson  <jas@extundo.com>
44926
44927         * modules/sha1: Depend on stdint instead of md5.
44928
44929         * modules/md5: Depend on stdint, remove uint32_t.
44930
44931 2005-10-17  Simon Josefsson  <jas@extundo.com>
44932
44933         * modules/gc-sha1-tests: New file.
44934
44935         * tests/test-gc-sha1.c: New file.
44936
44937 2005-10-17  Simon Josefsson  <jas@extundo.com>
44938
44939         * m4/md5.m4: Remove call to uint32_t.m4.
44940
44941 2005-10-17  Simon Josefsson  <jas@extundo.com>
44942
44943         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
44944
44945         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
44946         md5.h.
44947
44948         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
44949
44950         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
44951
44952 2005-10-17  Simon Josefsson  <jas@extundo.com>
44953
44954         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
44955
44956 2005-10-17  Simon Josefsson  <jas@extundo.com>
44957
44958         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
44959
44960 2005-10-17  Simon Josefsson  <jas@extundo.com>
44961
44962         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
44963
44964         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
44965
44966 2005-10-17  Bruno Haible  <bruno@clisp.org>
44967
44968         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
44969         that it can also be used in a test.
44970
44971 2005-10-16  Bruno Haible  <bruno@clisp.org>
44972
44973         * gnulib-tool (func_emit_tests_Makefile_am): Also define
44974         TESTS_ENVIRONMENT, so that individual tests can augment it.
44975
44976         * gnulib-tool (func_create_testdir): Use an intermediate target for
44977         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
44978         macros, like $(ALLOCA_H), which cannot be passed through the command
44979         line.
44980
44981 2005-10-15  Simon Josefsson  <jas@extundo.com>
44982
44983         * modules/rijndael-tests: New file.
44984
44985         * modules/rijndael: New file.
44986
44987 2005-10-15  Simon Josefsson  <jas@extundo.com>
44988
44989         * m4/rijndael.m4: New file.
44990
44991 2005-10-15  Simon Josefsson  <jas@extundo.com>
44992
44993         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
44994
44995         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
44996
44997 2005-10-14  Simon Josefsson  <jas@extundo.com>
44998
44999         * tests/test-arcfour.c: New file.
45000
45001         * modules/arcfour, modules/arcfour-tests: New files.
45002
45003 2005-10-14  Simon Josefsson  <jas@extundo.com>
45004
45005         * m4/arcfour.m4: New file.
45006
45007 2005-10-14  Simon Josefsson  <jas@extundo.com>
45008
45009         * lib/arcfour.h, lib/arcfour.c: New files.
45010
45011 2005-10-14  Roland McGrath  <roland@redhat.com>
45012
45013         Import from libc.  [BZ #1331]
45014         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
45015         macro argument.
45016         Reported by Matej Vela <vela@debian.org>.
45017
45018 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
45019
45020         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
45021         include <wchar.h>; no longer needed.
45022
45023 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
45024
45025         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
45026
45027 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
45028         and  Ulrich Drepper  <drepper@redhat.com>
45029
45030         Import from libc.
45031         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
45032         instead of inline stream orientation test and two separate
45033         function calls.  Pay no attention to USE_IN_LIBIO.
45034
45035 2005-10-13  Simon Josefsson  <jas@extundo.com>
45036
45037         * modules/gc-hmac-md5-tests: New file.
45038
45039         * tests/test-gc-hmac-sha1.c: New file.
45040
45041         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
45042
45043         * modules/gc-hmac-md5-tests: New file.
45044
45045         * tests/test-gc-md5.c: New file.
45046
45047         * modules/gc-md5-tests: New file.
45048
45049 2005-10-13  Simon Josefsson  <jas@extundo.com>
45050
45051         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
45052         Move memory allocation outside of loop.
45053
45054 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
45055
45056         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
45057         intermediate directory is in a read-only file system.  Problem
45058         reported by Eric Blake.
45059
45060 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
45061
45062         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
45063
45064 2005-10-12  Simon Josefsson  <jas@extundo.com>
45065
45066         * tests/test-hmac-sha1.c: New file.
45067
45068         * modules/hmac-sha1-tests: New file.
45069
45070         * modules/hmac-sha1: New file.
45071
45072 2005-10-12  Simon Josefsson  <jas@extundo.com>
45073
45074         * modules/gc-sha1: New file.
45075
45076 2005-10-12  Simon Josefsson  <jas@extundo.com>
45077
45078         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
45079
45080         * tests/test-gc-pbkdf2-sha1.c: New file.
45081
45082 2005-10-12  Simon Josefsson  <jas@extundo.com>
45083
45084         * modules/gc-md5, modules/gc-hmac-md5: New files.
45085
45086         * modules/gc (Files): Remove md5, memxor and hmac files.
45087
45088 2005-10-12  Simon Josefsson  <jas@extundo.com>
45089
45090         * m4/gc-pbkdf2-sha1.m4: New file.
45091
45092         * m4/gc-hmac-sha1.m4: New file.
45093
45094         * m4/gc-sha1: New file.
45095
45096         * m4/hmac-sha1.m4: New file.
45097
45098 2005-10-12  Simon Josefsson  <jas@extundo.com>
45099
45100         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
45101
45102         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
45103
45104 2005-10-12  Simon Josefsson  <jas@extundo.com>
45105
45106         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
45107         suggested by Bruno Haible <bruno@clisp.org>.
45108
45109 2005-10-12  Simon Josefsson  <jas@extundo.com>
45110
45111         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
45112
45113 2005-10-12  Simon Josefsson  <jas@extundo.com>
45114
45115         * lib/gc-pbkdf2-sha1.c: New file.
45116
45117         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
45118
45119 2005-10-12  Simon Josefsson  <jas@extundo.com>
45120
45121         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
45122
45123         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
45124
45125 2005-10-12  Simon Josefsson  <jas@extundo.com>
45126
45127         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
45128         GC_USE_HMAC_MD5, respectively.
45129
45130         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
45131         (gc_md5): Fix typo.
45132
45133         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
45134
45135         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
45136
45137         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
45138
45139 2005-10-12  Bruno Haible  <bruno@clisp.org>
45140
45141         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
45142         Reported by Stepan Kasal <kasal@ucw.cz>.
45143
45144 2005-10-11  Simon Josefsson  <jas@extundo.com>
45145
45146         * tests/test-crc.c: New file.
45147
45148         * modules/crc, modules/crc-tests: New files.
45149
45150 2005-10-11  Simon Josefsson  <jas@extundo.com>
45151
45152         * m4/crc.m4: New file.
45153
45154 2005-10-11  Simon Josefsson  <jas@extundo.com>
45155
45156         * lib/gc.h: Add gc_hash and gc_hash_buffer.
45157
45158         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
45159
45160         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
45161
45162 2005-10-11  Simon Josefsson  <jas@extundo.com>
45163
45164         * lib/crc.h, lib/crc.c: New files.
45165
45166         * lib/gc.h (gc_hash_buffer): Add doc.
45167
45168 2005-10-11  Bruno Haible  <bruno@clisp.org>
45169
45170         * modules/c-strcasestr: New file.
45171         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
45172
45173 2005-10-11  Bruno Haible  <bruno@clisp.org>
45174
45175         * modules/c-strcase: New file.
45176         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
45177
45178 2005-10-11  Bruno Haible  <bruno@clisp.org>
45179
45180         * lib/strcasecmp.c: Include limits.h.
45181         (strcasecmp): Avoid integer overflow on exotic platforms.
45182         * lib/strncasecmp.c: Include limits.h.
45183         (strncasecmp): Avoid integer overflow on exotic platforms.
45184         Reported by Paul Eggert.
45185
45186 2005-10-11  Bruno Haible  <bruno@clisp.org>
45187
45188         * lib/c-strcasestr.h: New file, from GNU gettext.
45189         * lib/c-strcasestr.c: New file, from GNU gettext.
45190
45191 2005-10-11  Bruno Haible  <bruno@clisp.org>
45192
45193         * lib/c-strcase.h: New file, from GNU gettext.
45194         * lib/c-strcasecmp.c: New file, from GNU gettext.
45195         * lib/c-strncasecmp.c: New file, from GNU gettext.
45196
45197 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
45198
45199         * modules/mempcpy (License): GPL -> LGPL.
45200         * modules/strchrnul (License): Likewise.
45201         * modules/sysexits (License): Likewise.
45202
45203 2005-10-08  Simon Josefsson  <jas@extundo.com>
45204
45205         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
45206
45207 2005-10-07  Simon Josefsson  <jas@extundo.com>
45208
45209         * m4/memxor.m4: Remove gl_C_RESTRICT call.
45210
45211 2005-10-06  Simon Josefsson  <jas@extundo.com>
45212
45213         * tests/test-hmac-md5.c: New file.
45214
45215         * modules/hmac-md5-tests: New file.
45216
45217         * modules/hmac-md5: New file.
45218
45219 2005-10-06  Simon Josefsson  <jas@extundo.com>
45220
45221         * m4/hmac-md5.m4: New file.
45222
45223         * m4/memxor.m4: Require gl_C_RESTRICT.
45224
45225 2005-10-06  Simon Josefsson  <jas@extundo.com>
45226
45227         * lib/memxor.c (memxor): Avoid casts and warnings.
45228
45229 2005-10-06  Simon Josefsson  <jas@extundo.com>
45230
45231         * lib/hmac-md5.c: New file.
45232
45233         * lib/hmac.h: New file.
45234
45235 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
45236
45237         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
45238         promotes to int, not unsigned int, to catch the AIX 5.3
45239         compiler bug.
45240
45241 2005-10-05  Simon Josefsson  <jas@extundo.com>
45242
45243         * modules/memxor: New file.
45244
45245         * modules/iconv (Files): Move config.rpath to havelib, it is used
45246         there.
45247
45248         * modules/havelib (Files): Add config.rpath.
45249
45250 2005-10-05  Simon Josefsson  <jas@extundo.com>
45251
45252         * m4/memxor.m4: New file.
45253
45254 2005-10-05  Simon Josefsson  <jas@extundo.com>
45255
45256         * lib/memxor.c (memxor): Fix compiler error.
45257
45258         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
45259         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
45260
45261         * lib/memxor.h, lib/memxor.c: New files.
45262
45263         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
45264         we assume all systems have it, suggested by Jim Meyering
45265         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
45266         any systems lack sys/socket.h; mingw32 is known to lack it, but we
45267         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
45268         same reasons.
45269
45270 2005-10-05  Simon Josefsson  <jas@extundo.com>
45271
45272         * config/srclist.txt: Add glibc bug 1423 for md5.h.
45273
45274 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
45275
45276         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
45277         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
45278         needed, since the source code now assumes these .h files.
45279
45280 2005-10-05  Derek Price  <derek@ximbiot.com>
45281
45282         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
45283
45284 2005-10-05  Bruno Haible  <bruno@clisp.org>
45285
45286         * modules/stdint (License): Change to LGPL.
45287
45288 2005-10-04  Simon Josefsson  <jas@extundo.com>
45289
45290         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
45291         D. Baushke" <mdb@gnu.org>.
45292
45293 2005-10-04  Bruno Haible  <bruno@clisp.org>
45294
45295         * lib/verify.h (verify_true): Provide alternative definition for C++.
45296
45297 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
45298
45299         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
45300         (SSIZE_MAX): New macro, if not already defined.
45301         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
45302         than 2 GiB.
45303
45304 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
45305
45306         Sync from coreutils.
45307         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
45308         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
45309         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
45310         ULLONG_MAX doesn't work with 2.7.2.1.
45311
45312 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
45313
45314         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
45315         From Ben Pfaff.
45316
45317         * modules/exclude (Depends-on): Depend on verify.
45318         * modules/strtoimax (Depends-on): Likewise.
45319         * modules/utimecmp (Depends-on): Likewise.
45320
45321 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
45322
45323         * lib/exclude.c: Include verify.h.
45324         (verify): Remove.  All callers changed to use verify.h's version.
45325         * lib/strtoimax.c: Likewise.
45326         * lib/utimecmp.c: Likewis.e
45327
45328         Sync from coreutils.
45329         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
45330         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
45331         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
45332         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
45333         bother returning ENOSYS if settimeofday or stime fails; just let
45334         them return whatever errno they want to return.
45335         * lib/utimens.c: Include unistd.h, for dup2.
45336         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
45337         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
45338
45339 2005-10-02  Jim Meyering  <jim@meyering.net>
45340
45341         Sync from coreutils.
45342         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
45343         from glibc-2.2.5 that fails for read-only files.
45344
45345 2005-10-02  Jim Meyering  <jim@meyering.net>
45346
45347         Sync from coreutils.
45348         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
45349         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
45350         `#if HAVE_CONFIG_H'.
45351         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
45352         Remove AT_FDCWD test.
45353         Do not consume the fd unless successful.
45354         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
45355         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
45356         block, so that we don't even try to compile it if settimeofday is
45357         available.  This works around a compilation failure on OSF1 V5.1,
45358         due to stime requiring a `long int*' while tv_sec is `int'.
45359
45360 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
45361
45362         Sync from coreutils.
45363         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
45364         against `yes', rather than just testing for nonempty.
45365
45366 2005-10-01  Simon Josefsson  <jas@extundo.com>
45367
45368         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
45369         and Darwin.
45370
45371         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
45372         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
45373         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
45374         freeaddrinfo and gai_strerror are declared by the POSIX headers.
45375         Check if struct addrinfo is declared.
45376
45377 2005-10-01  Simon Josefsson  <jas@extundo.com>
45378
45379         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
45380         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
45381         AI_* and EAI_* definitions.  Protect function declarations.
45382
45383 2005-10-01  Jim Meyering  <jim@meyering.net>
45384
45385         Sync from coreutils.
45386
45387         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
45388         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
45389         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
45390         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
45391         in the inet and nsl libraries.  Required on Solaris 5.7.
45392
45393 2005-10-01  Jim Meyering  <jim@meyering.net>
45394
45395         Sync from coreutils.
45396         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
45397         in the inet and nsl libraries.  Required on Solaris 5.7.
45398
45399 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
45400
45401         * lib/getdelim.c (getdelim): Remove unused variables.
45402
45403 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
45404
45405         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
45406         so that the code works even with ancient cpp.  Portability problem
45407         with GCC 2.7.2.1 reported by Thomas M.Ott.
45408
45409 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
45410
45411         * modules/regex (Depends-on): Add strcase.
45412
45413         * modules/gethostname (Licence): Change from GPL to LGPL, since
45414         gethostname.c is a trivial implementation of a standard library
45415         function.
45416         * modules/poll (License): Change from GPL to LGPL, since it's
45417         derived from LGPL code.
45418
45419 2005-09-27  Jim Meyering  <jim@meyering.net>
45420
45421         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
45422         HAVE_CONFIG_H.
45423
45424         * lib/intprops.h (signed_type_or_expr__): Define.
45425         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
45426         for unsigned types.
45427
45428 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
45429
45430         * lib/verify.h (verify_expr): Remove, replacing with:
45431         (verify_true): New macro that returns true instead of void.
45432         (verify_type__): Remove.
45433         (verify): Use verify_true rather than verify_type__.
45434
45435 2005-09-26  Bruno Haible  <bruno@clisp.org>
45436
45437         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
45438         is necessary.
45439         (lib_SOURCES): Remove mbchar.c.
45440         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
45441         (Files): Add m4/mbrtowc.m4.
45442         * modules/mbiter: Likewise.
45443         * modules/mbuiter: Likewise.
45444
45445 2005-09-26  Bruno Haible  <bruno@clisp.org>
45446
45447         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
45448         compile mbchar.c if they are not both present.
45449         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
45450         * m4/mbiter.m4 (gl_MBITER): Likewise.
45451         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
45452         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
45453         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
45454
45455 2005-09-25  Jim Meyering  <jim@meyering.net>
45456
45457         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
45458         also uses socklen_t.
45459
45460 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
45461
45462         * lib/utimens.c (ENOSYS): Define if not already defined.
45463         (futimens): Support having a null PATH if the file descriptor
45464         is nonnegative.
45465
45466         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
45467         Remove.
45468         (__attribute): Define to empty unless GCC 3.1 or later.
45469         This works around a core dump on OpenBSD 3.4, which has GCC
45470         2.95.3, which dumps core when given __attribute__(()).  It also
45471         simplifies other tests, since we really don't want to bother with
45472         worrying about which ancient version of GCC supported what.
45473         Original problem reported by Yoann Vandoorselaere, with part of
45474         the fix suggested by Derek Price.
45475
45476 2005-09-24  Jim Meyering  <jim@meyering.net>
45477
45478         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
45479         so we can once again use a positive bitfield width of 1 -- now we
45480         don't have to explain why we were using a bitfield width of 2.
45481
45482 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
45483
45484         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
45485         and similarly for the other external symbols.  Problem reported
45486         by James Gallager.
45487
45488         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
45489         bug reported by Jim Meyering.
45490
45491         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
45492         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
45493         not needed, since socklen is a prerequisite module.
45494
45495 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
45496
45497         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
45498         Problem reported by Eric Blake.
45499         (getaddrinfo): Initialize se so that it's not garbage.
45500         Redo internal storage allocation so that it doesn't make unportable
45501         assumptions about alignment.
45502         Fix a memory leak.
45503
45504         * lib/utimens.c (futimens): Use futimesat if available.
45505         Prefer it to futimes since it doesn't have the futimes bug.
45506
45507         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
45508         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
45509         Instead, declare a function that returns a pointer to an array,
45510         and use verify_type__ to declare the size of the array.
45511         Problem and germ of a solution reported by Bruno Haible.
45512         (verify_type__): Use 2, not 1, for bitfield size, to avoid
45513         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
45514
45515 2005-09-23  Jim Meyering  <jim@meyering.net>
45516
45517         Sync from coreutils.
45518         Correct build failure (socklen_t not defined) on at least
45519         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
45520         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
45521
45522 2005-09-23  Jim Meyering  <jim@meyering.net>
45523
45524         * modules/getaddrinfo (Depends-on): Add socklen.
45525
45526 2005-09-23  Bruno Haible  <bruno@clisp.org>
45527
45528         * tests/test-verify.c: New file.
45529
45530 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
45531
45532         Sync from coreutils.
45533
45534         * modules/argmatch (Depends-on): Add verify.
45535         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
45536         unistd-safer.
45537         * modules/save-cwd (Depends-on): Likewise.
45538
45539         * modules/openat (Files): Add lib/openat-die.c.
45540         (Depends-on): Remove error, exitfail.
45541         Add dirname.
45542
45543         * modules/verify: New file.
45544         * MODULES.html.sh (Diagnostics <assert.h>): New section,
45545         with "verify" module.
45546
45547 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
45548
45549         Sync from coreutils.
45550
45551         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
45552         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
45553         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
45554         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
45555         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
45556         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
45557         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
45558         Don't bother checking for string.h, stdlib.h, unistd.h.
45559         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
45560         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
45561         module's job.
45562         * m4/jm-macros.m4 (gl_MACROS): Likewise.
45563         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
45564
45565         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
45566         (gl_GETDATE): Use it.
45567
45568         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
45569
45570 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
45571
45572         Sync from coreutils.
45573
45574         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
45575         stat-time.h.
45576         * lib/argmatch.h: Include verify.h
45577         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
45578         (ARGMATCH_ASSERT): Remove; unused.
45579         * lib/canonicalize.c: Assume STDC_HEADERS.
45580         * lib/exclude.c: Include "strcase.h".
45581         * lib/regex_internal.h [!defined _LIBC]: Likewise.
45582         * lib/getusershell.c: Include stdio--.h rather than stdio.h
45583         and stdio-safer.h.
45584         (getusershell): Call fopen, not fopen_safer.
45585         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
45586         Do not include unistd-safer.h.
45587         (save_cwd): Don't call fd_safer; no longer needed
45588         now that we include fcntl--.h.
45589
45590         * lib/getdate.y (relative_time): New type.
45591         (RELATIVE_TIME_0): New constant.
45592         (parser_control): Use relative_time instead of doing it ourselves.
45593         (%union): Add new relative_time rel member.
45594         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
45595         Now typeless.
45596         (relunit, relunit_snumber): Now of type rel.
45597         (zone, rel, relunit, get_date): Adjust to above changes.
45598
45599         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
45600         Do not include unistd-safer.h.
45601         (getloadavg): Don't call fd_safer; no longer needed
45602         now that we include fcntl--.h.
45603
45604         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
45605         (make_dir_parents): Treat ENOSYS like EEXIST.
45606
45607         Improve quality of diagnostics on restore_cwd failure.
45608         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
45609         (make_dir_parents): Last arg is now int * (for errno), not bool *.
45610         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
45611         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
45612         each time through the loop.  Do not diagnose restore_cwd failure;
45613         that is the caller's job (and perhaps the caller does not care).
45614
45615         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
45616         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
45617         If the file already exists but is not a directory, don't bother
45618         to try to make its parents.
45619         Close potential file descriptor leak if we can't chdir("/") (!).
45620         Don't always return true if chdir($PWD) fails; return true only
45621         if the requested action was done successfully (except for the
45622         chdir($PWD)).
45623         Don't log final directory unless we actually made it.
45624         Refactor to avoid duplicate code to fix up permissions.
45625         Don't attempt to fix up parent permissions if chdir($PWD) fails.
45626
45627         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
45628         to make it a bit faster and (I hope) clearer.
45629         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
45630         Fix bug in formats like %2N.
45631
45632         * lib/verify.h: New file.
45633
45634 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
45635
45636         Sync from coreutils.
45637         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
45638
45639 2005-09-22  Jim Meyering  <jim@meyering.net>
45640
45641         Sync from coreutils.
45642
45643         * m4/lstat.m4 (gl_FUNC_LSTAT):
45644         Use AC_LIBSOURCES to require lstat.c and lstat.h.
45645         Remove obsolete comment.
45646         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
45647         * m4/xstrtod.m4: Likewise.
45648
45649         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
45650
45651 2005-09-22  Jim Meyering  <jim@meyering.net>
45652
45653         Sync from coreutils.
45654
45655         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
45656
45657         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
45658         the .tm_year member, since otherwise gcc-4.0 would now warn about
45659         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
45660
45661         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
45662         order to avoid an unsuppressible warning from gcc on 64-bit systems.
45663
45664         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
45665         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
45666         when run in a time zone for which daylight savings time is in effect
45667         for the starting date.
45668
45669         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
45670         stop us from restricting permissions of just-created absolute-named
45671         directories.
45672         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
45673         to restore initial working directory.
45674         * lib/mkdir-p.c (make_dir_parents): New parameter:
45675         different_working_dir, to tell caller if/when we change the working
45676         directory and are unable to return to the initial one.
45677         * lib/mkdir-p.h (make_dir_parents): Update prototype.
45678         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
45679         `return false'.  This fixes a bug introduced on 2004-07-30.
45680
45681         * lib/openat.c (fdopendir): Be sure to close the supplied
45682         file descriptor before returning.  This makes our replacement
45683         implementation a little closer to Solaris's, where fdopendir
45684         ties the file descriptor to the returned DIR* pointer.
45685         * lib/openat.c (unlinkat): New function.
45686         * lib/openat.h (unlinkat): Add prototype.
45687         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
45688         (openat_restore_fail): Rename from openat_restore_die.
45689         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
45690
45691         Provide an alternative to exiting immediately upon save_cwd or
45692         restore_cwd failure.  Now, an application can arrange e.g.,
45693         to perform a longjump in that case.
45694         * lib/openat.c: Include dirname.h.
45695         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
45696         (rpl_openat, fdopendir, fstatat): Call openat_save_die
45697         and openat_restore_die rather than calling error directly.
45698         Don't include "error.h" or "exitfail.h"; they're no longer needed.
45699
45700         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
45701         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
45702         define.
45703
45704         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
45705         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
45706                             int utc, int nanoseconds);
45707         Background:
45708         date should not have to allocate a megabyte of virtual memory to
45709         handle a format argument like +%1048575T.  When implemented with
45710         strftime, it must allocate such a buffer, use strftime to fill it
45711         in, print it, then free it.
45712         With fprintftime, it simply prints everything and exits.
45713         With no need for memory allocation, that's one fewer way to fail.
45714         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
45715         optional field width, not before, so we accept %9:z, not %:9z.
45716         (my_strftime): Be sure to use L_('x') for literals.
45717
45718         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
45719         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
45720         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
45721         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
45722         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
45723         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
45724         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
45725         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
45726         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
45727         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
45728         * lib/xgethostname.c, lib/xreadlink.c:
45729         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
45730
45731         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
45732         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
45733         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
45734         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
45735         and don't include <sys/file.h>).
45736
45737 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
45738
45739         Sync from coreutils.
45740
45741         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
45742         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
45743         [!LDAV_DONE]: Avoid unused variable warning.
45744
45745 2005-09-21  Bruno Haible  <bruno@clisp.org>
45746
45747         * lib/unicodeio.h (unicode_to_mb): New declaration.
45748
45749 2005-09-20  Derek Price  <derek@ximbiot.com>
45750
45751         * lib/getaddrinfo.c: Don't include <netdb.h> included from
45752         getaddrinfo.h.
45753
45754 2005-09-20  Bruno Haible  <bruno@clisp.org>
45755
45756         * gnulib-tool: Remove trailing slashes from the values specified for
45757         --source-base, --m4-base, --tests-base, --aux-dir.
45758         Suggested by Simon Josefsson <jas@extundo.com>.
45759
45760 2005-09-20  Bruno Haible  <bruno@clisp.org>
45761
45762         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
45763         func_modules_to_filelist, func_import, func_create_testdir): Make all
45764         sorting results locale-independent, so that gnulib-cache.m4 doesn't
45765         change when gnulib-tool is invoked in a different locale.
45766
45767 2005-09-19  Simon Josefsson  <jas@extundo.com>
45768
45769         * m4/socklen.m4: Fix typo.
45770
45771 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
45772
45773         Use a consistent style for including <config.h>.
45774         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
45775         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
45776         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
45777         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
45778         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
45779         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
45780         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
45781         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
45782         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
45783         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
45784         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
45785         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
45786         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
45787         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
45788         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
45789         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
45790         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
45791         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
45792         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
45793         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
45794         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
45795         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
45796         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
45797         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
45798         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
45799         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
45800         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
45801         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
45802         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
45803         lib/xstrtoumax.c, lib/yesno.c:
45804         Standardize inclusion of config.h.
45805         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
45806         lib/inttostr.h:  Removed inclusion of config.h from header files.
45807         * lib/inttostr.c:  Adjusted in-tree users.
45808         * lib/timespec.h: Remove superfluous warning to include config.h.
45809         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
45810         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
45811         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
45812         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
45813         config.h with HAVE_CONFIG_H.
45814
45815 2005-09-19  Jim Meyering  <jim@meyering.net>
45816
45817         * modules/pathmax (License): Change to LGPL.
45818
45819 2005-09-19  Derek Price  <derek@ximbiot.com>
45820
45821         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
45822
45823 2005-09-19  Bruno Haible  <bruno@clisp.org>
45824
45825         * gnulib-tool (import): Provide default for --tests-base.
45826
45827 2005-09-19  Bruno Haible  <bruno@clisp.org>
45828
45829         * doc/quote.texi: New file, extracted from gnulib.texi.
45830         * doc/ctime.texi: New file, extracted from gnulib.texi.
45831         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
45832         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
45833         * doc/gnulib.texi: Include them.
45834
45835 2005-09-18  Bruno Haible  <bruno@clisp.org>
45836
45837         Portability fix.
45838         * gnulib-tool (func_readlink): New function.
45839         (func_ln_if_changed): Use it.
45840
45841 2005-09-18  Bruno Haible  <bruno@clisp.org>
45842
45843         * gnulib-tool: Support --with-tests also with --import.
45844         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
45845         (func_import): Use variables $testsbase and $inctests. Emit a
45846         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
45847         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
45848         SUBDIRS += $testsdir.
45849         (func_create_testdir): Update.
45850
45851 2005-09-18  Bruno Haible  <bruno@clisp.org>
45852
45853         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
45854         instead of $dry_run.
45855         (func_cp_if_changed, func_mv_if_changed): Remove functions.
45856         (func_ln_if_changed): Don't handle dry-run here.
45857         (func_import): In dry-run mode, detect more precisely which actions
45858         would be performed, and don't use "...ing" verbs.
45859
45860 2005-09-18  Bruno Haible  <bruno@clisp.org>
45861
45862         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
45863         (func_import): Use join on two temporary files instead of three nested
45864         loops, in order to determine which files are new or old.
45865
45866 2005-09-18  Bruno Haible  <bruno@clisp.org>
45867
45868         * gnulib-tool (func_import): Comment out code that spits out the
45869         new files with --dry-run.
45870
45871 2005-09-18  Bruno Haible  <bruno@clisp.org>
45872
45873         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
45874
45875 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
45876
45877         * lib/stat-time.h: New file.
45878         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
45879         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
45880         in a different way.
45881         (timespec_cmp): New function.
45882         * lib/utimecmp.c: Include stat-time.h.
45883         (SYSCALL_RESOLUTION): Depend on whether various struct stat
45884         members exist, not on the obsolescent ST_MTIM_NSEC.
45885         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
45886
45887 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
45888
45889         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
45890
45891 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
45892
45893         * MODULES.html.sh (File system functions): Add stat-time.
45894         * modules/stat-time: New file.
45895         * modules/timespec (Files): Remove m4/st_mtim.m4; this
45896         is now done in a different way, by the stat-time module.
45897         * modules/utimecmp (Depends-on): Add stat-time.
45898
45899 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
45900
45901         * m4/st_mtim.m4: Remove.  Superseded by...
45902         * m4/stat-time.m4: New file.
45903         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
45904         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
45905
45906 2005-09-15  Derek Price  <derek@ximbiot.com>
45907
45908         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
45909
45910 2005-09-15  Derek Price  <derek@ximbiot.com>
45911
45912         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
45913         * lib/regex_internal.c: Ditto, using this...
45914         (__GNUC_PREREQ): ...new macro.
45915         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
45916         using...
45917         (__GNUC_PREREQ): ...this new macro.
45918
45919         * lib/strstr.h: Include string.h. Define strstr as a macro here.
45920
45921 2005-09-15  Derek Price  <derek@ximbiot.com>
45922             Paul Eggert  <eggert@cs.ucla.edu>
45923
45924         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
45925         changes, consolidating in...
45926         * lib/regex_internal.h: ...this file.
45927
45928 2005-09-13  Jim Meyering  <jim@meyering.net>
45929
45930         * lib/canon-host.c: Filter through gnu indent and reword comments
45931         slightly.
45932         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
45933
45934 2005-09-13  Derek Price  <derek@ximbiot.com>
45935
45936         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
45937         failure.
45938         Reported by Jim Meyering  <jim@meyering.net>.
45939
45940 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
45941
45942         * lib/base64.c: Typo.
45943         (base64_encode): Put b64str in initialized data section.
45944
45945 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
45946
45947         Merge glibc and coreutils changes into gnulib, plus a few
45948         extra fixes.
45949         * lib/md5.c: Use #error rather than a string.
45950         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
45951         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
45952         (__attribute__): Define to empty for non recent-GCC.
45953         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
45954         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
45955         Renamed from their non-__ counterparts, with new macros replacing
45956         them if not _LIBC.  Add __THROW attribute.
45957         (rol): Remove.
45958         (struct md5_ctx): Align buffer if using GCC.
45959         * lib/sha1.h (struct sha1_ctx): Likewise.
45960         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
45961         The old name was backwards.
45962         (NOTSWAP): Remove; not used.
45963         (rol): New macro, moved here from md5.h.
45964         (sha1_process_block): Remove a FIXME that doesn't make sense.
45965
45966 2005-09-12  Derek Price  <derek@ximbiot.com>
45967
45968         Return usable errors from canon-host.
45969         * lib/canon-host.h: New file.
45970         * lib/canon-host.c (canon_host): Wrap...
45971         (canon_host_r): ...this new function, which now relies exclusively on
45972         getaddrinfo.
45973         (ch_strerror): New function.
45974         (last_cherror): New global.
45975         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
45976         interface.
45977         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
45978         void *.
45979         (freeaddrinfo): Free ai->ai_canonname when set.
45980
45981 2005-09-12  Derek Price  <derek@ximbiot.com>
45982
45983         Make canon-host require getaddrinfo.
45984         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
45985         AC_LIBSOURCE canon-host.h.  Call...
45986         (gl_PREREQ_CANON_HOST): ...this new function, which requires
45987         gl_GETADDRINFO.
45988         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
45989
45990 2005-09-12  Derek Price  <derek@ximbiot.com>
45991
45992         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
45993         LGPL.
45994         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
45995
45996 2005-09-12  Derek Price  <derek@ximbiot.com>
45997
45998         * lib/gai_strerror.c: Include config.h when available.  Include
45999         getaddrinfo.h before other headers to test interface.
46000         Reported by Larry Jones <lawrence.jones@ugs.com>.
46001
46002 2005-09-12  Derek Price  <derek@ximbiot.com>
46003             Paul Eggert  <eggert@cs.ucla.edu>
46004
46005         * modules/glob (Files): Add glob-libc.h.
46006
46007 2005-09-12  Derek Price  <derek@ximbiot.com>
46008             Paul Eggert  <eggert@cs.ucla.edu>
46009
46010         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
46011         glob_.h, glob-libc.h.
46012         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
46013
46014 2005-09-12  Derek Price  <derek@ximbiot.com>
46015             Paul Eggert  <eggert@cs.ucla.edu>
46016
46017         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
46018         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
46019         protecting things that should be done only in gnulib contexts.
46020         * lib/glob_.h: New file, containing only the glob things needed for
46021         gnulib.
46022         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
46023         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
46024         (glob, globfree, glob_pattern_p): Now defined simply in terms of
46025         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
46026         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
46027         and to respect the namespace rules better.
46028
46029 2005-09-08  Simon Josefsson  <jas@extundo.com>
46030
46031         * modules/socklen: New file.
46032
46033 2005-09-08  Simon Josefsson  <jas@extundo.com>
46034
46035         * m4/socklen.m4: New file.
46036
46037 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
46038
46039         * modules/utimens (Files): Add m4/utimbuf.m4, since
46040         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
46041         Reported by Sergey Poznyakoff.
46042
46043 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
46044
46045         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
46046         definitions, since that's the preferred style in glibc.
46047         Fix a minor spacing issue, and update copyright notice to match
46048         glibc's.
46049
46050 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
46051
46052         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
46053
46054 2005-09-06  Simon Josefsson  <jas@extundo.com>
46055
46056         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
46057         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
46058
46059 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
46060
46061         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
46062         warning.
46063
46064 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
46065
46066         * config/srclist.txt: Add glibc bug 1302.
46067
46068 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
46069
46070         Change bitset word type from unsigned int to unsigned long int,
46071         as this has better performance on typical 64-bit hosts.
46072         Port bitset code to hosts with unusual word sizes.
46073         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
46074         (build_collating_symbol):
46075         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
46076         argument is a bitset.  This is merely a style issue, but it makes
46077         it clearer that an entire array is expected.
46078         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
46079         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
46080         Port to the case where bitset_word is not the same as unsigned int.
46081         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
46082         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
46083         Likewise.
46084         * lib/regexec.c (check_dst_limits_calc_pos_1,
46085         check_subexp_matching_top):
46086         (build_trtable, group_nodes_into_DFAstates):
46087         Likewise.
46088         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
46089         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
46090         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
46091         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
46092         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
46093         * lib/regcomp.c (optimize_subexps, lower_subexp):
46094         Work even if bitset_word has holes in its bitwise representation.
46095         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
46096         * lib/regexec.c (check_dst_limits_calc_pos_1,
46097         check_subexp_matching_top):
46098         Likewise.
46099         * lib/regex_internal.c (re_string_reconstruct):
46100         Don't assume UCHAR_MAX == 255.
46101         * lib/regex_internal.h (bitset_set_all): Likewise.
46102         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
46103         All uses changed.
46104         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
46105         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
46106         All uses changed.
46107         (BITSET_WORD_MAX): New macro.
46108         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
46109         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
46110         (bitset_empty, bitset_copy):
46111         Prefer sizeof (bitset) to multiplying it out ourselves.
46112         (bitset_not_merge): Remove; unused.
46113         (bitset_contain): Return bool, not unsigned int with one bit on.
46114         All callers changed.
46115         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
46116         alignment than re_node_set; do this by defining a new internal
46117         type struct dests_alloc and using it to allocate memory.
46118
46119 2005-09-05  Bruno Haible  <bruno@clisp.org>
46120
46121         * gnulib-tool (func_import): Fix comparison in handling of symbolic
46122         links.
46123
46124 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
46125
46126         * modules/size_max (Makefile.am): Add size_max.h
46127
46128 2005-09-04  Derek Price  <derek@ximbiot.com>
46129
46130         * gnulib-tool (func_import): Fix reversed $symbolic logic.
46131
46132 2005-09-03  Simon Josefsson  <jas@extundo.com>
46133
46134         * gnulib-tool: Fix typo.
46135
46136 2005-09-03  Simon Josefsson  <jas@extundo.com>
46137
46138         * config/srclist.txt: Add glibc bug 1293.
46139
46140 2005-09-03  Derek Price  <derek@ximbiot.com>
46141
46142         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
46143         From Larry Jones <lawrence.jones@ugs.com>.
46144
46145 2005-09-02  Simon Josefsson  <jas@extundo.com>
46146
46147         * modules/socklen: New file.
46148
46149 2005-09-02  Simon Josefsson  <jas@extundo.com>
46150
46151         * modules/havelib: New module.
46152
46153         * modules/gettext, modules/iconv, modules/lock, modules/readline:
46154         Use havelib.
46155
46156 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
46157
46158         Check for arithmetic overflow when calculating sizes, to prevent
46159         some buffer-overflow issues.  These patches are conservative, in the
46160         sense that when I couldn't determine whether an overflow was possible,
46161         I inserted a run-time check.
46162         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
46163         macros.
46164         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
46165         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
46166         (re_xnrealloc, re_x2nrealloc): New inline functions.
46167         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
46168         parse_bracket_exp):
46169         (build_equiv_class, build_charclass): Check for arithmetic overflow
46170         in size expression calculations.
46171         * lib/regex_internal.c (re_string_realloc_buffers):
46172         (build_wcs_upper_buffer, re_node_set_add_intersect):
46173         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
46174         (re_dfa_add_node, register_state): Likewise.
46175         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
46176         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
46177         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
46178         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
46179
46180 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
46181
46182         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
46183         m4/ulonglong.m4.  Problem reported by Martin Lambers.
46184
46185 2005-09-02  Bruno Haible  <bruno@clisp.org>
46186
46187         Support for lib vs. lib64 distinction on biarch platforms.
46188         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
46189         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
46190         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
46191
46192 2005-09-02  Bruno Haible  <bruno@clisp.org>
46193
46194         * gnulib-tool (import): In the other first-use case, provide defaults
46195         as well.
46196
46197 2005-09-02  Bruno Haible  <bruno@clisp.org>
46198
46199         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
46200         patches not yet found in the latest gettext release.
46201
46202 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
46203
46204         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
46205         to avoid a collision with bits/local_lim.h in glibc.
46206         All uses changed.  Problem reported by Dmitry V. Levin in
46207         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
46208
46209         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
46210         bugs in int versus size_t comparisons.
46211         (re_string_context_at): Fix bug where the code assumed that
46212         Idx is signed.
46213
46214         Use bool where appropriate.
46215         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
46216         All callers changed.
46217         (calc_eclosure_iter): Likewise, for ROOT arg.
46218         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
46219         (build_charclass_op): Likewise, for NON_MATCH arg.
46220         * lib/regex_internal.c (re_string_allocate, re_string_construct):
46221         (re_string_construct_common): Likewise, for ICASE arg.
46222         * lib/regexec.c (re_search_2_stub, re_search_stub):
46223         Likewise, for RET_LEN arg.
46224         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
46225         (set_regs): Likewise, for FL_BACKTRACK arg.
46226         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
46227         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
46228         (calc_eclosure_iter, parse_bracket_exp):
46229         Use bool for internal variables that are booleans.
46230         * lib/regexec.c (re_search_internal, check_matching,
46231         proceed_next_node):
46232         (set_regs, build_sifted_states, sift_states_bkref):
46233         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
46234         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
46235         (find_collation_sequence_value):
46236         Likewise.
46237         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
46238         (re_node_set_compare):
46239         Return bool, not int. All callers changed.
46240         * lib/regexec.c (check_halt_node_context, check_dst_limits):
46241         (build_trtable, check_node_accept): Likewise.
46242         * lib/regex_internal.h: Include stdbool.h.
46243
46244         Fix bugs uncovered when converting to bool.
46245         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
46246         failure instead of charging ahead blindly.
46247         * lib/regex_internal.c (register_state): Likewise.
46248         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
46249         for freeing internal storage.
46250         (group_nodes_into_DFA_states): Use unsigned int, not int, for
46251         bitset pieces used as boolean, to avoid undefined behavior
46252         on hosts that do int overflow checking.
46253
46254 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
46255
46256         * config/srclist.txt: Add glibc bugs 1285-1287.
46257
46258 2005-09-01  Jim Meyering  <jim@meyering.net>
46259
46260         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
46261         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
46262         Require gl_STAT_MACROS, too.
46263
46264 2005-09-01  Bruno Haible  <bruno@clisp.org>
46265
46266         * gnulib-tool (import): In the first-use case, provide defaults.
46267
46268 2005-09-01  Bruno Haible  <bruno@clisp.org>
46269
46270         * gnulib-tool (func_import): Remove the .tmp files.
46271
46272 2005-09-01  Bruno Haible  <bruno@clisp.org>
46273
46274         * gnulib-tool (func_import): Fix handling of symbolic links.
46275
46276 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
46277
46278         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
46279         old glibc regex code mishandles strings longer than 2**31 bytes.
46280         This patch fixes this when the regex code is used in gnulib
46281         (i.e., outside glibc).
46282
46283         This patch should not affect the use of the regex code inside
46284         glibc.  No doubt this problem also needs to be handled for glibc
46285         as well, but the result will be an incompatible change to the
46286         glibc ABI, and the old ABI will have to be supported too.  That
46287         can be the the subject for another patch.
46288
46289         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
46290         governing whether the rest of this patch is active.  By default,
46291         the macro is disabled and the patch has no effect.
46292         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
46293         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
46294         (struct re_pattern_buffer, re_search, re_search_2, re_match):
46295         (re_match_2, re_set_registers): Use the new types.
46296         * lib/regex_internal.h (Idx, re_hashval_t): New types.
46297         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
46298         New macros.
46299         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
46300         (re_string_context_at, bin_tree_t, re_dfastate_t):
46301         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
46302         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
46303         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
46304         (re_string_char_size_at, re_string_wchar_at):
46305         (re_string_elem_size_at):
46306         Use the new types and macros to port to 64-bit hosts.
46307         Use unsigned types for internal values, so that the code
46308         mostly works even for arrays larger than SSIZE_MAX.
46309         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
46310         (search_duplicated_node, calc_eclosure_iter, fetch_number):
46311         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
46312         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
46313         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
46314         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
46315         (calc_inveclosure, parse_dup_op, build_range_exp):
46316         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
46317         (fetch_number, create_token_tree, mark_opt_subexp):
46318         Likewise.
46319         * lib/regex_internal.c (re_string_construct_common,
46320         create_ci_newstate):
46321         (create_cd_newstate, re_string_allocate, re_string_construct):
46322         (re_string_realloc_buffers, build_wcs_upper_buffer):
46323         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
46324         (re_string_reconstruct, re_string_peek_byte_case):
46325         (re_string_fetch_byte_case, re_string_context_at):
46326         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
46327         (re_node_set_init_copy, re_node_set_add_intersect):
46328         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
46329         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
46330         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
46331         (re_acquire_state, re_acquire_state_context, register_state):
46332         Likewise.
46333         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
46334         search_cur_bkref_entry):
46335         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
46336         (re_search_internal, re_search_2_stub, re_search_stub)
46337         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
46338         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
46339         (update_cur_sifted_state, check_dst_limits):
46340         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
46341         (check_subexp_limits, sift_states_bkref, merge_state_array):
46342         (check_subexp_matching_top, get_subexp, get_subexp_sub):
46343         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
46344         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
46345         (expand_bkref_cache, check_node_accept_bytes):
46346         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
46347         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
46348         (acquire_init_state_context, check_halt_node_context):
46349         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
46350         (sift_states_backward, clean_state_log_if_needed):
46351         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
46352         (find_recover_state, transit_state_sb, transit_state_mb):
46353         (transit_state_bkref, build_trtable, match_ctx_clean):
46354         Likewise.
46355         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
46356         to work around an assumption that REG_MISSING is negative.
46357
46358         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
46359         (seek_collating_symbol_entry) [defined _LIBC]:
46360         (lookup_collation_sequence_value) [defined _LIBC]:
46361         (build_range_exp, build_collating_symbol) [defined _LIBC]:
46362         Use prototypes rather than old-style function definitions.
46363         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
46364         (transit_state_sb) [0]:
46365         (find_collation_sequence_value) [defined _LIBC]: Likewise.
46366
46367         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
46368         rm_eo.
46369
46370         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
46371         (optimize_subexps, lower_subexp):
46372         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
46373         since the signed shift might overflow.  Use 1u<<31 instead.
46374         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
46375         Likewise.
46376         * lib/regexec.c (check_dst_limits_calc_pos_1,
46377         check_subexp_matching_top): Likewise.
46378
46379         * lib/regcomp.c (optimize_subexps, lower_subexp):
46380         Use CHAR_BIT rather than 8, for clarity.
46381         * lib/regexec.c (check_dst_limits_calc_pos_1):
46382         (check_subexp_matching_top): Likewise.
46383         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
46384         have to worry about portability issues when shifting it left.
46385         Remove no-longer-needed test for table_size > 0.
46386         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
46387         in a word, as the resulting behavior is undefined.
46388         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
46389         in one case, a <= should have been an <, and in another case the
46390         whole test was missing.
46391         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
46392         the standard name CHAR_BIT.
46393         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
46394         this is not true on one's complement and signed-magnitude hosts.
46395
46396         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
46397         next_last_offset.
46398         (struct re_dfa_t): Remove unused member states_alloc.
46399         * lib/regcomp.c (init_dfa): Don't initialize unused members.
46400
46401 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
46402
46403         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
46404         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
46405         and large-file glibc and in 32-bit large-file Solaris.
46406
46407 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
46408
46409         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
46410         lengths fit in regoff_t; this isn't true if regoff_t is the same
46411         width as size_t.
46412         * lib/regex.c (re_search_internal): 5th arg is LAST_START
46413         (= START + RANGE) instead of RANGE.  This avoids overflow
46414         problems when regoff_t is the same width as size_t.
46415         All callers changed.
46416         (re_search_2_stub): Check for overflow when adding the
46417         sizes of the two strings.
46418         (re_search_stub): Check for overflow when adding START
46419         to RANGE; if it occurs, substitute the extreme value.
46420
46421 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
46422
46423         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
46424
46425 2005-08-31  Jim Meyering  <jim@meyering.net>
46426
46427         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
46428         a pointer-to-const.
46429         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
46430         (register_state): Likewise.
46431         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
46432         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
46433         (group_nodes_into_DFAstates): Likewise.
46434
46435 2005-08-31  Jim Meyering  <jim@meyering.net>
46436
46437         * check-module: Add a FIXME comment.
46438
46439 2005-08-31  Eric Blake  <ebb9@byu.net>
46440
46441         * modules/unistd-safer (Files): Add unistd--.h.
46442         * modules/stdio-safer (Files): Add stdio--.h.
46443
46444 2005-08-31  Derek Price  <derek@ximbiot.com>
46445
46446         * lib/getdelim.c (getdelim): Return EOF on EOF.
46447         Reported by Larry Jones <lawrence.jones@ugs.com>.
46448
46449 2005-08-31  Bruno Haible  <bruno@clisp.org>
46450
46451         Avoid unnecessary diffs in the generated lib/Makefile.am.
46452         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
46453         the generated files.
46454         (func_import): Don't set cmd.
46455
46456 2005-08-31  Bruno Haible  <bruno@clisp.org>
46457
46458         * lib/strstr.c: Include <stddef.h>, for NULL.
46459         * lib/strcasestr.c: Likewise.
46460         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
46461
46462 2005-08-31  Bruno Haible  <bruno@clisp.org>
46463
46464         * gnulib-tool: New option --macro-prefix.
46465         (func_import): Use macro_prefix.
46466         (import): Handle option --macro-prefix.
46467
46468 2005-08-31  Bruno Haible  <bruno@clisp.org>
46469
46470         * gnulib-tool (import): Rename most ac_* variables to cached_*.
46471         Also use new variables cached_lgpl, cached_libtool.
46472
46473 2005-08-31  Bruno Haible  <bruno@clisp.org>
46474
46475         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
46476         always instantiating them.
46477
46478 2005-08-31  Bruno Haible  <bruno@clisp.org>
46479
46480         * gnulib-tool (func_import): Read the previous cached settings
46481         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
46482         earlier added by gnulib but are now dropped. Warn when a gnulib file
46483         overwrites a non-gnulib file.
46484
46485 2005-08-31  Bruno Haible  <bruno@clisp.org>
46486
46487         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
46488         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
46489         projects that don't keep autogenerated files in CVS. Put into
46490         actioncmd only the specified modules, not the transitive closure.
46491
46492 2005-08-31  Bruno Haible  <bruno@clisp.org>
46493
46494         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
46495         Create directories that shall be filled.
46496         (import): Don't look for gl_* macros in configure.ac. Recurse across
46497         all directories containing a gnulib-cache.m4 files, if meaningful.
46498
46499 2005-08-31  Bruno Haible  <bruno@clisp.org>
46500
46501         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
46502         (import): Set seen_libtool when we see gl_LIBTOOL.
46503
46504 2005-08-31  Bruno Haible  <bruno@clisp.org>
46505
46506         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
46507         declaration macro definitions from generated gnulib.m4.
46508
46509 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
46510
46511         * lib/iconvme.h: Add prototype for iconv_alloc.
46512
46513 2005-08-29  Simon Josefsson  <jas@extundo.com>
46514
46515         * lib/iconvme.c: Fix errno.
46516
46517 2005-08-29  Bruno Haible  <bruno@clisp.org>
46518
46519         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
46520         that it works when the directory contains spaces.
46521
46522 2005-08-29  Bruno Haible  <bruno@clisp.org>
46523
46524         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
46525
46526 2005-08-29  Bruno Haible  <bruno@clisp.org>
46527
46528         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
46529         Emit more advice.
46530
46531 2005-08-29  Bruno Haible  <bruno@clisp.org>
46532         and Stepan Kasal  <kasal@ucw.cz>
46533
46534         * check-module: If more parameters are given, check each of them
46535         separately; add more exceptions, as noted by Jim Meyering.
46536         (check_module): New procedure.
46537         (%exempt_header): Now contains all exceptions.
46538
46539 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
46540
46541         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
46542
46543 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
46544
46545         * lib/iconvme.c: Split iconv_string into iconv_alloc.
46546
46547 2005-08-28  Bruno Haible  <bruno@clisp.org>
46548
46549         * m4/gnulib-tool.m4: New file.
46550
46551 2005-08-27  Jim Meyering  <jim@meyering.net>
46552
46553         * modules/unistd-safer (Files): Add pipe-safer.c.
46554         * modules/fcntl-safer (Files): Add creat-safer.c.
46555
46556 2005-08-27  Jim Meyering  <jim@meyering.net>
46557
46558         * m4/stdlib-safer.m4: New file.  From coreutils.
46559         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
46560         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
46561         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
46562         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
46563         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
46564
46565 2005-08-27  Jim Meyering  <jim@meyering.net>
46566
46567         * lib/fopen-safer.c: Merge minor changes from coreutils.
46568         * lib/dup-safer.c: Likewise.
46569         * lib/fd-safer.c: Likewise.
46570
46571         Merge from coreutils.
46572         * lib/stdio--.h: New file.
46573         * lib/stdlib--.h: New file.
46574         * lib/mkstemp-safer.c: New file.
46575
46576         GNU tar needs these.
46577         * lib/pipe-safer.c: New file.
46578         * lib/creat-safer.c: New file.
46579         * lib/fcntl--.h (creat): Define to creat_safer.
46580         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
46581         * lib/unistd--.h (pipe): Define to pipe_safer.
46582         * lib/unistd-safer.h: Declare pipe_safer.
46583
46584 2005-08-26  Simon Josefsson  <jas@extundo.com>
46585
46586         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
46587         Haible <bruno@clisp.org>.
46588
46589 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
46590
46591         * lib/regex_internal.h: Remove all references to
46592         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
46593         or better.
46594         (bitset_not, bitset_merge, bitset_not_merge):
46595         (bitset_mask, re_string_allocate, re_string_construct):
46596         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
46597         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
46598         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
46599         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
46600         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
46601         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
46602         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
46603         (re_acquire_state_context):
46604         Remove unnecessary forward decls.
46605         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
46606         Put __attribute at function definition,
46607         now that the function decl has been removed.
46608         * lib/regex_internal.c (re_string_peek_byte_case):
46609         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
46610         Likewise.
46611
46612 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
46613
46614         * m4/regex.m4: Add AC_PREREQ(2.50).
46615         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
46616
46617 2005-08-25  Simon Josefsson  <jas@extundo.com>
46618
46619         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
46620         __fsetlocking.
46621
46622 2005-08-25  Simon Josefsson  <jas@extundo.com>
46623
46624         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
46625         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
46626         GLIBC specific code.
46627
46628 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
46629
46630         Make regex safe for g++.  This fixes one real bug (an "err"
46631         that should have been "*err").  g++ problem reported by
46632         Sam Steingold.
46633         * lib/regex_internal.h (re_calloc): New macro, consistent with
46634         re_malloc etc.  All callers of calloc changed to use re_calloc.
46635         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
46636         not int.  All callers changed.
46637         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
46638         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
46639         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
46640         (find_recover_state): Change "err" to "*err"; this fixes what
46641         appears to be a real bug.
46642         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
46643         versus int.
46644
46645 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
46646
46647         * modules/regex (Depends-on): Add malloc, since the code
46648         assumes that !malloc(0) means failure.
46649
46650 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
46651
46652         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
46653
46654         alloca modernization/simplification for regex.
46655         * lib/regex.c: Remove portability cruft for alloca.  This no longer
46656         needs to be at the start of the file, and can be moved into
46657         regex_internal.h and simplified.
46658         * lib/regex_internal.h: Include <alloca.h>.
46659         (__libc_use_alloca) [!defined _LIBC]: New macro.
46660         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
46661         now works outside glibc.
46662
46663 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
46664
46665         * config/srclist.txt: Add glibc bugs 1241, 1245.
46666
46667 2005-08-25  Jim Meyering  <jim@meyering.net>
46668
46669         * lib/open-safer.c: Include <config.h>.
46670         Otherwise, we'd lose LARGEFILE support in any file using
46671         e.g. "fcntl--.h"
46672
46673 2005-08-25  Bruno Haible  <bruno@clisp.org>
46674
46675         * m4/minmax.m4: Require autoconf 2.52.
46676         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
46677         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
46678         alternatives of translit over the alphabet.
46679         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
46680
46681 2005-08-24  Simon Josefsson  <jas@extundo.com>
46682
46683         * tests/test-getpass.c: New file.
46684
46685 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
46686
46687         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
46688         for GNU regex features.
46689
46690 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
46691
46692         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
46693         * lib/regex.h (regerror): Likewise.
46694
46695         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
46696         requires this.  (The code never needed it.)
46697
46698         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
46699         All uses of recently-renamed identifiers changed to use the new,
46700         POSIX-compliant names.  The code will build and run just fine
46701         without these changes, but it's better to eat our own dog food
46702         and use the standard-conforming names.
46703
46704         * lib/regex.h: Fix a multitude of POSIX name space violations.
46705         These changes have an effect only for programs that define
46706         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
46707         do not change anything for programs compiled in the normal way.
46708         Also, there is no effect on the ABI.
46709
46710         (_REGEX_SOURCE): New macro.
46711         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
46712         defined and _GNU_SOURCE is not; this fixes a name space violation.
46713
46714         Rename the following macros to obey POSIX requirements.
46715         The old names are still visible as macros if _REGEX_SOURCE is defined.
46716         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
46717         RE_BACKSLASH_ESCAPE_IN_LISTS.
46718         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
46719         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
46720         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
46721         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
46722         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
46723         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
46724         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
46725         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
46726         (REG_INTERVALS): renamed from RE_INTERVALS.
46727         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
46728         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
46729         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
46730         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
46731         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
46732         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
46733         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
46734         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
46735         RE_UNMATCHED_RIGHT_PAREN_ORD.
46736         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
46737         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
46738         (REG_DEBUG): renamed from RE_DEBUG.
46739         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
46740         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
46741         unusual, since we can't clash with the POSIX REG_ICASE.
46742         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
46743         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
46744         (REG_NO_SUB): renamed from RE_NO_SUB.
46745         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
46746         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
46747         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
46748         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
46749         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
46750         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
46751         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
46752         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
46753         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
46754         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
46755         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
46756         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
46757         RE_SYNTAX_POSIX_MINIMAL_BASIC.
46758         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
46759         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
46760         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
46761         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
46762         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
46763         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
46764         (REG_FIXED): Renamed from REGS_FIXED.
46765         (REG_NREGS): Renamed from RE_NREGS.
46766
46767         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
46768         of other REG_* macros, since POSIX says the user is allowed to
46769         #undef these macros selectively.
46770
46771         (reg_errcode_t): Update comment stating what other tables need
46772         to be consistent.
46773
46774         Rename the following enum values to obey POSIX requirements.
46775         The old names are still visible as macros.
46776         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
46777         is not defined, since GNU is supposed to be a superset of POSIX as
46778         much as possible, and since we want reg_errcode_t to be a signed
46779         type for implementation consistency.
46780         (_REG_NOERROR): Renamed from REG_NOERROR.
46781         (_REG_NOMATCH): Renamed from REG_NOMATCH.
46782         (_REG_BADPAT): Renamed from REG_BADPAT.
46783         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
46784         (_REG_ECTYPE): Renamed from REG_ECTYPE.
46785         (_REG_EESCAPE): Renamed from REG_EESCAPE.
46786         (_REG_ESUBREG): Renamed from REG_ESUBREG.
46787         (_REG_EBRACK): Renamed from REG_EBRACK.
46788         (_REG_EPAREN): Renamed from REG_EPAREN.
46789         (_REG_EBRACE): Renamed from REG_EBRACE.
46790         (_REG_BADBR): Renamed from REG_BADBR.
46791         (_REG_ERANGE): Renamed from REG_ERANGE.
46792         (_REG_ESPACE): Renamed from REG_ESPACE.
46793         (_REG_BADRPT): Renamed from REG_BADRPT.
46794         (_REG_EEND): Renamed from REG_EEND.
46795         (_REG_ESIZE): Renamed from REG_ESIZE.
46796         (_REG_ERPAREN): Renamed from REG_ERPAREN.
46797         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
46798         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
46799         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
46800         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
46801
46802         (_REG_RE_NAME, _REG_RM_NAME): New macros.
46803         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
46804         changed.  But support the old name if the new one is not defined
46805         and if _REGEX_SOURCE.
46806
46807         Change the following member names in struct re_pattern_buffer.
46808         The old names are still supported if !_REGEX_SOURCE.
46809         The new names are always supported, regardless of _REGEX_SOURCE.
46810         (re_buffer): Renamed from buffer.
46811         (re_allocated): Renamed from allocated.
46812         (re_used): Renamed from used.
46813         (re_syntax): Renamed from syntax.
46814         (re_fastmap): Renamed from fastmap.
46815         (re_translate): Renamed from translate.
46816         (re_can_be_null): Renamed from can_be_null.
46817         (re_regs_allocated): Renamed from regs_allocated.
46818         (re_fastmap_accurate): Renamed from fastmap_accurate.
46819         (re_no_sub): Renamed from no_sub.
46820         (re_not_bol): Renamed from not_bol.
46821         (re_not_eol): Renamed from not_eol.
46822         (re_newline_anchor): Renamed from newline_anchor.
46823
46824         Change the following member names in struct re_registers.
46825         The old names are still supported if !_REGEX_SOURCE.
46826         The new names are always supported, regardless of _REGEX_SOURCE.
46827         (rm_num_regs): Renamed from num_regs.
46828         (rm_start): Renamed from start.
46829         (rm_end): Renamed from end.
46830
46831         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
46832         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
46833         Prepend __ to parameter names.
46834
46835         Undo yesterday's changes.
46836
46837 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
46838
46839         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
46840         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
46841         lib/regex.c.
46842
46843 2005-08-24  Jim Meyering  <jim@meyering.net>
46844
46845         Sync from coreutils.
46846         * m4/fcntl-safer.m4: New file.
46847
46848         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
46849         and object files for this module.
46850
46851 2005-08-24  Jim Meyering  <jim@meyering.net>
46852
46853         Sync from coreutils.
46854         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
46855
46856 2005-08-24  Jim Meyering  <jim@meyering.net>
46857
46858         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
46859         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
46860
46861 2005-08-24  Jim Meyering  <jim@meyering.net>
46862
46863         * modules/fcntl-safer: New module.
46864         * modules/fts (Depends-on): Add fcntl-safer.
46865         * MODULES.html.sh (File descriptor based Input/Output):
46866         Add fcntl-safer.
46867
46868 2005-08-24  Bruno Haible  <bruno@clisp.org>
46869
46870         Support for unit test modules.
46871         * modules/README: Mention tests modules.
46872         * modules/TEMPLATE-TESTS: New file.
46873         * gnulib-tool: New options --extract-tests-module, --with-tests and
46874         --tests-base (unused for the moment).
46875         (testsbase, inctests): New variables.
46876         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
46877         (func_verify_module): Exclude TEMPLATE-TESTS.
46878         (func_verify_nontests_module, func_verify_tests_module): New functions.
46879         (func_get_dependencies): Add implicit dependency for tests modules.
46880         (func_get_tests_module): New function.
46881         (func_modules_transitive_closure): When --with-tests was specified,
46882         include the unit tests as well, unless explicitly avoided.
46883         (func_emit_lib_Makefile_am): Ignore the tests modules here.
46884         (func_emit_tests_Makefile_am): New function.
46885         (func_create_testdir): When --with-tests was specified, emit a
46886         tests/ directory.
46887         * MODULES.html.sh (Future developments): Update.
46888
46889 2005-08-24  Bruno Haible  <bruno@clisp.org>
46890
46891         * modules/tls-tests: New file.
46892         * tests/test-tls.c: New file, from GNU gettext.
46893
46894 2005-08-24  Bruno Haible  <bruno@clisp.org>
46895
46896         * modules/lock-tests: New file.
46897         * tests/test-lock.c: New file, from GNU gettext.
46898
46899 2005-08-24  Bruno Haible  <bruno@clisp.org>
46900
46901         * lib/lock.h: Add multiple inclusion guard.
46902         * lib/tls.h: Add multiple inclusion guard.
46903
46904 2005-08-24  Bruno Haible  <bruno@clisp.org>
46905
46906         * gnulib-tool: Add support for the --aux-dir option to
46907         --create-testdir, --create-megatestdir, --test, --megatest.
46908         (func_create_testdir, func_create_megatestdir): Optionally emit a
46909         AC_CONFIG_AUX_DIR directive.
46910         (create-testdir, create-megatestdir, test, megatest): Provide a
46911         default value for $auxdir.
46912
46913 2005-08-24  Bruno Haible  <bruno@clisp.org>
46914
46915         * gnulib-tool (import): Use compound statement instead of subshell
46916         where possible.
46917
46918 2005-08-24  Bruno Haible  <bruno@clisp.org>
46919
46920         * gnulib-tool (import): Change --aux-dir default to "build-aux".
46921
46922 2005-08-24  Bruno Haible  <bruno@clisp.org>
46923
46924         * gnulib-tool (func_version): Update.
46925
46926 2005-08-24  Bruno Haible  <bruno@clisp.org>
46927
46928         * gnulib-tool (func_import, func_create_testdir,
46929         func_create_megatestdir): Quote all autoconf macro arguments.
46930
46931 2005-08-24  Bruno Haible  <bruno@clisp.org>
46932
46933         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
46934         option --force, because --force causes the aclocal.m4 of each
46935         subdirectory to be newer than the corresponding config.h.in.
46936
46937 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
46938
46939         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
46940         All contents moved to gl_REGEX.
46941         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
46942         assume that it does.
46943
46944 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
46945
46946         * lib/regex.h (REG_NOSYS)
46947         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
46948         Define, since POSIX requires it as of 2001.
46949         (_REG_ENOSYS)
46950         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
46951         New private symbol, used to keep the enum signed in all cases.
46952         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
46953         Youngman in
46954         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
46955
46956         * lib/regex_internal.c (re_string_skip_chars, register_state):
46957         (calc_state_hash):
46958         Remove forward decls; no longer needed now that we use prototypes.
46959         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
46960         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
46961         (clean_state_log_if_needed): Likewise.
46962
46963 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
46964
46965         * config/srclist.txt: Add glibc bugs 1231-1233.
46966
46967 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
46968
46969         Fix problems reported by Sam Steingold in
46970         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
46971         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
46972         assumed that reg_errcode_t is a signed type, which is not
46973         necessarily true if _XOPEN_SOURCE is not defined.
46974         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
46975         since some compilers warn about it otherwise.
46976
46977 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
46978
46979         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
46980         (init_word_char, create_initial_state, duplicate_node_closure):
46981         (fetch_token, peek_token_bracket, build_range_exp):
46982         (build_collating_symbol): Remove forward decls; no longer needed
46983         now that we use prototypes.
46984
46985         * lib/regcomp.c:
46986         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
46987         (re_compile_fastmap_iter, regcomp, regerror, regfree):
46988         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
46989         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
46990         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
46991         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
46992         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
46993         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
46994         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
46995         (build_range_exp, build_collating_symbol, parse_bracket_exp):
46996         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
46997         (build_charclass, build_charclass_op, fetch_number, create_tree):
46998         (create_token_tree, mark_opt_subexp, duplicate_tree):
46999         Use prototypes rather than old-style definitions.
47000
47001         * lib/regex_internal.c:
47002         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
47003         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
47004         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
47005         (re_string_reconstruct, re_string_peek_byte_case):
47006         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
47007         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
47008         (re_node_set_init_copy, re_node_set_add_intersect):
47009         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
47010         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
47011         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
47012         (re_acquire_state, re_acquire_state_context, register_state):
47013         (create_ci_newstate, create_cd_newstate, free_state):
47014         Likewise.
47015         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
47016         re_search_2):
47017         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
47018         (re_search_internal, prune_impossible_nodes):
47019         (acquire_init_state_context, check_matching, static):
47020         (check_halt_node_context, check_halt_state_context, proceed_next_node):
47021         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
47022         (update_regs, sift_states_backward, build_sifted_states):
47023         (clean_state_log_if_needed, merge_state_array):
47024         (update_cur_sifted_state, add_epsilon_src_nodes):
47025         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
47026         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
47027         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
47028         (find_recover_state, check_subexp_matching_top, transit_state_mb):
47029         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
47030         (check_arrival, check_arrival_add_next_nodes):
47031         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
47032         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
47033         (check_node_accept_bytes, check_node_accept, extend_buffers):
47034         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
47035         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
47036         (sift_ctx_init):
47037         Likewise.
47038
47039         * lib/regex_internal.h:
47040         (re_string_allocate, re_string_construct, re_string_reconstruct):
47041         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
47042         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
47043         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
47044         (re_string_context_at, re_string_peek_byte_case):
47045         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
47046         is defined, since we now use prototypes always.
47047
47048         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
47049         C89 or better.  All uses removed.
47050
47051 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
47052
47053         * config/srclist.txt: Add glibc bugs 1220-1227.
47054
47055 2005-08-20  Jim Meyering  <jim@meyering.net>
47056
47057         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
47058         of unused local, dfa.
47059
47060 2005-08-20  Bruno Haible  <bruno@clisp.org>
47061
47062         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
47063
47064 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
47065
47066         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
47067         (re_node_set_insert_last, re_dfa_add_node):
47068         Rename local variables to avoid GCC shadowing warnings.
47069
47070 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
47071
47072         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
47073         [defined lint]: Suppress bogus uninitialized-variable warnings.
47074
47075         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
47076         and let the caller return REG_ESPACE if out of space.  This
47077         removes an uninitialied-variable warning with GCC 4.0.1, and also
47078         avoids taking the address of a local variable.  All callers
47079         changed.
47080
47081 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
47082
47083         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
47084         $LIBCSRC/posix/regexec.c.
47085         Add glibc bug 1217 for regcomp.c.
47086
47087 2005-08-19  Jim Meyering  <jim@meyering.net>
47088
47089         * lib/regexec.c (proceed_next_node): Redo local variables to
47090         avoid GCC shadowing warnings.
47091
47092 2005-08-18  Bruno Haible  <bruno@clisp.org>
47093
47094         * lib/strstr.c (strstr): Fix return value in multibyte case.
47095         * lib/strcasestr.c (strcasestr): Likewise.
47096
47097 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
47098
47099         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
47100
47101 2005-08-17  Jim Meyering  <jim@meyering.net>
47102
47103         Make the %s format (seconds since the epoch) work for a negative
47104         number and when used with a zero-padded field width, e.g. %015s.
47105
47106         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
47107         label so that it precedes the code to set `digits'.  Otherwise,
47108         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
47109         print `00-22'.  Now, it prints `-0022', as it should.
47110
47111 2005-08-17  Bruno Haible  <bruno@clisp.org>
47112
47113         * modules/strstr (Files): Add m4/mbrtowc.m4.
47114         (Depends-on): Add mbuiter.
47115
47116 2005-08-17  Bruno Haible  <bruno@clisp.org>
47117
47118         * modules/strcasestr: New file.
47119         * MODULES.html.sh (String handling, based on ANSI C 89): Add
47120         strcasestr.
47121
47122 2005-08-17  Bruno Haible  <bruno@clisp.org>
47123
47124         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
47125
47126 2005-08-17  Bruno Haible  <bruno@clisp.org>
47127
47128         * modules/mbuiter: New file.
47129         * MODULES.html.sh (Extended multibyte and wide character utilities):
47130         Add mbuiter.
47131
47132 2005-08-17  Bruno Haible  <bruno@clisp.org>
47133
47134         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
47135         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
47136
47137 2005-08-17  Bruno Haible  <bruno@clisp.org>
47138
47139         * m4/strcasestr.m4: New file.
47140
47141 2005-08-17  Bruno Haible  <bruno@clisp.org>
47142
47143         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
47144         * lib/strstr.c: Completely rewritten, with multibyte locale support.
47145
47146 2005-08-17  Bruno Haible  <bruno@clisp.org>
47147
47148         * lib/strcasestr.h: New file.
47149         * lib/strcasestr.c: New file.
47150
47151 2005-08-17  Bruno Haible  <bruno@clisp.org>
47152
47153         * lib/strcasecmp.c: Use mbuiter.h.
47154
47155 2005-08-17  Bruno Haible  <bruno@clisp.org>
47156
47157         * lib/mbuiter.h: New file.
47158
47159 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
47160
47161         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
47162         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
47163         and gl_GETOPT are both invoked via different paths (as happens
47164         with GNU tar CVS because it uses both argp and getopt), the former
47165         wins.
47166
47167 2005-08-16  Bruno Haible  <bruno@clisp.org>
47168
47169         * modules/tls: New file.
47170         * MODULES.html.sh (Multithreading): Add tls.
47171
47172 2005-08-16  Bruno Haible  <bruno@clisp.org>
47173
47174         * modules/strnlen1: New file.
47175         * MODULES.html.sh (String handling): Add strnlen1.
47176
47177 2005-08-16  Bruno Haible  <bruno@clisp.org>
47178
47179         * modules/strcase (Files): Add m4/mbrtowc.m4.
47180         (Depends-on): Add strnlen1, mbchar.
47181
47182 2005-08-16  Bruno Haible  <bruno@clisp.org>
47183
47184         * modules/mbiter: New file.
47185         * MODULES.html.sh (Extended multibyte and wide character utilities):
47186         Add mbiter.
47187
47188 2005-08-16  Bruno Haible  <bruno@clisp.org>
47189
47190         * modules/mbfile: New file.
47191         * MODULES.html.sh (Extended multibyte and wide character utilities):
47192         Add mbfile.
47193
47194 2005-08-16  Bruno Haible  <bruno@clisp.org>
47195
47196         * modules/mbchar: New file.
47197         * MODULES.html.sh (Extended multibyte and wide character utilities):
47198         New section.
47199
47200 2005-08-16  Bruno Haible  <bruno@clisp.org>
47201
47202         * m4/tls.m4: New file, from GNU gettext.
47203
47204 2005-08-16  Bruno Haible  <bruno@clisp.org>
47205
47206         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
47207         always.
47208         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
47209
47210 2005-08-16  Bruno Haible  <bruno@clisp.org>
47211
47212         * m4/mbiter.m4: New file.
47213
47214 2005-08-16  Bruno Haible  <bruno@clisp.org>
47215
47216         * m4/mbfile.m4: New file.
47217
47218 2005-08-16  Bruno Haible  <bruno@clisp.org>
47219
47220         * m4/mbchar.m4: New file.
47221
47222 2005-08-16  Bruno Haible  <bruno@clisp.org>
47223
47224         * lib/tls.h: New file, from GNU gettext.
47225         * lib/tls.c: New file, from GNU gettext.
47226
47227 2005-08-16  Bruno Haible  <bruno@clisp.org>
47228
47229         * lib/strnlen1.h: New file.
47230         * lib/strnlen1.c: New file.
47231
47232 2005-08-16  Bruno Haible  <bruno@clisp.org>
47233
47234         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
47235         (mbi_init): Update.
47236         (mbi_avail, mbi_advance): Let the iteration end before the terminating
47237         NUL byte, not after it.
47238
47239 2005-08-16  Bruno Haible  <bruno@clisp.org>
47240
47241         * lib/strcase.h (strcasecmp): Add note in comments.
47242         * lib/strncasecmp.c: Use code from strcasecmp.c.
47243         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
47244         (strcasecmp): Work correctly in multibyte locales.
47245
47246 2005-08-16  Bruno Haible  <bruno@clisp.org>
47247
47248         * lib/mbiter.h: New file.
47249
47250 2005-08-16  Bruno Haible  <bruno@clisp.org>
47251
47252         * lib/mbfile.h: New file.
47253
47254 2005-08-16  Bruno Haible  <bruno@clisp.org>
47255
47256         * lib/mbchar.h: New file.
47257         * lib/mbchar.c: New file.
47258
47259 2005-08-16  Bruno Haible  <bruno@clisp.org>
47260
47261         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
47262         the valid ones. Makes the comparison operations transitive:
47263         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
47264         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
47265
47266 2005-08-15  Simon Josefsson  <jas@extundo.com>
47267
47268         * modules/ssize_t (License): Change to 'unlimited'.
47269
47270         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
47271
47272 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
47273
47274         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
47275         Add comments for each pending glibc patch.
47276
47277 2005-08-15  Bruno Haible  <bruno@clisp.org>
47278
47279         * lib/regex.h (__restrict_arr): Don't define to __restrict if
47280         __cplusplus is defined.
47281
47282 2005-08-14  Jim Meyering  <jim@meyering.net>
47283
47284         Sync from coreutils.
47285
47286         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
47287         Use the hash-table-based cycle-detection code not just when
47288         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
47289         Reported by James Youngman in
47290         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
47291         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
47292         FTS_TIGHT_CYCLE_CHECK.
47293         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
47294         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
47295         once again.
47296         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
47297         * lib/fts.c (fd_safer): Remove decl.
47298         Include fcntl--.h rather than unistd-safer.h
47299         (fts_safe_changedir): Don't call fd_safer; no longer needed
47300         now that we include fcntl--.h.
47301
47302 2005-08-12  Simon Josefsson  <jas@extundo.com>
47303
47304         * modules/getndelim2: Use ssize_t module.
47305         * modules/getnline: Likewise.
47306         * modules/safe-read: Likewise.
47307         * modules/xreadlink: Likewise.
47308
47309         * modules/ssize_t: New file.
47310
47311 2005-08-12  Simon Josefsson  <jas@extundo.com>
47312
47313         * m4/readline.m4: Look for termcap, curses or ncurses if required.
47314
47315 2005-08-12  Simon Josefsson  <jas@extundo.com>
47316
47317         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
47318         ssize_t.
47319
47320 2005-08-12  Simon Josefsson  <jas@extundo.com>
47321
47322         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
47323         readline, getdelim and check_version.
47324         (Support for systems lacking ISO C 99: Sizes of integer types):
47325         Add size_max.
47326
47327 2005-08-12  Bruno Haible  <bruno@clisp.org>
47328
47329         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
47330
47331 2005-08-11  Simon Josefsson  <jas@extundo.com>
47332
47333         * modules/readline: New file.
47334
47335         * modules/strnlen (Files): Add strnlen.h.
47336
47337 2005-08-11  Simon Josefsson  <jas@extundo.com>
47338
47339         * m4/readline.m4: New file.
47340
47341 2005-08-11  Simon Josefsson  <jas@extundo.com>
47342
47343         * lib/readline.h, readline.c: New file.
47344
47345 2005-08-11  Simon Josefsson  <jas@extundo.com>
47346
47347         * doc/gnulib.texi (Initial import, Finishing touches): Mention
47348         gl_AVOID.
47349
47350 2005-08-11  Bruno Haible  <bruno@clisp.org>
47351
47352         * lib/strnlen.h (strnlen): Change parameter name to match comment.
47353
47354 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
47355
47356         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
47357
47358 2005-08-10  Simon Josefsson  <jas@extundo.com>
47359
47360         * tests/test-iconvme.c: New file.
47361
47362 2005-08-10  Simon Josefsson  <jas@extundo.com>
47363
47364         * m4/strnlen.m4: New file.
47365
47366         * m4/strndup.m4: Don't check for strnlen declaration, done in
47367         strnlen.m4.
47368
47369 2005-08-10  Simon Josefsson  <jas@extundo.com>
47370
47371         * lib/strndup.c: Use strnlen.h.
47372
47373         * lib/strnlen.h: New file.
47374
47375 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
47376
47377         * README: Typos.
47378
47379 2005-08-02  Simon Josefsson  <jas@extundo.com>
47380
47381         * modules/readline: New file.
47382
47383 2005-08-02  Simon Josefsson  <jas@extundo.com>
47384
47385         * modules/getdelim: New file.
47386
47387         * modules/getline: Rewrite, don't use getndelim2.
47388
47389 2005-08-02  Simon Josefsson  <jas@extundo.com>
47390
47391         * m4/getline.m4: Separate out getdelim stuff into separate module.
47392
47393         * m4/getdelim.m4: New file.
47394
47395 2005-08-02  Simon Josefsson  <jas@extundo.com>
47396
47397         * lib/getline.h, getline.c: Rewrite.
47398
47399         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
47400
47401 2005-07-31  Bruno Haible  <bruno@clisp.org>
47402
47403         * lib/lock.h (gl_lock_initializer): New macro.
47404         (gl_lock_define_initialized): Use it.
47405         (gl_rwlock_initializer): New macro.
47406         (gl_rwlock_define_initialized): Use it.
47407         (gl_recursive_lock_initializer): New macro.
47408         (gl_recursive_lock_define_initialized): Use it.
47409
47410 2005-07-30  Karl Berry  <karl@gnu.org>
47411
47412         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
47413         Report from Ben Pfaff, regarding getopt.
47414
47415 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
47416
47417         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
47418         normal way.
47419         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
47420         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
47421         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
47422         (gl_GETOPT): Use the new macros.  Most of the implementation
47423         is moved to the new macros.  This is for programs like Emacs
47424         that don't want all the functionality of gl_GETOPT.
47425
47426 2005-07-26  Bruno Haible  <bruno@clisp.org>
47427
47428         * m4/lock.m4: Update from GNU gettext.
47429
47430 2005-07-26  Bruno Haible  <bruno@clisp.org>
47431
47432         * lib/lock.h: Update from GNU gettext.
47433         * lib/lock.c: Update from GNU gettext.
47434
47435 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
47436
47437         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
47438         obsolescent AC_TRY_RUN.  Include the default includes files, for
47439         'exit'.
47440
47441 2005-07-24  Bruno Haible  <bruno@clisp.org>
47442
47443         * modules/visibility: New file.
47444         * MODULES.html.sh (Misc): Add visibility.
47445
47446 2005-07-24  Bruno Haible  <bruno@clisp.org>
47447
47448         * m4/visibility.m4: New file.
47449
47450 2005-07-24  Bruno Haible  <bruno@clisp.org>
47451
47452         * doc/visibility.texi: New file.
47453
47454 2005-07-22  Bruno Haible  <bruno@clisp.org>
47455
47456         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
47457         $(ALLOCA_H), redundant through BUILT_SOURCES.
47458         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
47459         redundant through BUILT_SOURCES.
47460         * modules/byteswap (Makefile.am): Remove explicit dependency on
47461         $(BYTESWAP_H), redundant through BUILT_SOURCES.
47462         * modules/fnmatch (Makefile.am): Remove explicit dependency on
47463         $(FNMATCH_H), redundant through BUILT_SOURCES.
47464         * modules/getopt (Makefile.am): Remove explicit dependency on
47465         $(GETOPT_H), redundant through BUILT_SOURCES.
47466         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
47467         redundant through BUILT_SOURCES.
47468         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
47469         redundant through BUILT_SOURCES.
47470         * modules/stdbool (Makefile.am): Remove explicit dependency on
47471         $(STDBOOL_H), redundant through BUILT_SOURCES.
47472         * modules/stdint (Makefile.am): Remove explicit dependency on
47473         $(STDINT_H), redundant through BUILT_SOURCES.
47474         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
47475         Remove explicit dependency on $(SYSEXITS_H).
47476         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
47477
47478 2005-07-18  Simon Josefsson  <jas@extundo.com>
47479
47480         * lib/check-version.c (check_version): Accept identical versions too.
47481
47482 2005-07-18  Bruno Haible  <bruno@clisp.org>
47483
47484         * modules/lock: New file.
47485         * MODULES.html.sh (Multithreading): New section.
47486
47487 2005-07-18  Bruno Haible  <bruno@clisp.org>
47488
47489         * m4/lock.m4: New file, from GNU gettext.
47490
47491 2005-07-18  Bruno Haible  <bruno@clisp.org>
47492
47493         * lib/lock.h: New file, from GNU gettext.
47494         * lib/lock.c: New file, from GNU gettext.
47495
47496 2005-07-18  Bruno Haible  <bruno@clisp.org>
47497
47498         * lib/lock.h (gl_once_t): New type.
47499         (gl_once_define, gl_once): New macros.
47500         * lib/lock.c (fresh_once): New variable.
47501         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
47502         functions.
47503
47504 2005-07-16  Simon Josefsson  <jas@extundo.com>
47505
47506         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
47507         workaround, suggested by Bruno.
47508
47509 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
47510
47511         * modules/xalloc (Depends-on): Add xalloc-die.
47512         * modules/xvasprintf (Depends-on): Add xalloc-die.
47513
47514 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
47515
47516         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
47517         with a minor change.
47518
47519 2005-07-15  Bruno Haible  <bruno@clisp.org>
47520
47521         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
47522         When using lib/poll.c, define poll as rpl_poll.
47523
47524 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
47525
47526         * modules/argp (Depends-on): Remove unlocked-io.
47527
47528 2005-07-14  Derek Price  <derek@ximbiot.com>
47529
47530         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
47531         for glob symlink bug.
47532
47533 2005-07-14  Bruno Haible  <bruno@clisp.org>
47534
47535         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
47536         Instead, test for *_unlocked function declarations directly.
47537
47538 2005-07-11  Simon Josefsson  <jas@extundo.com>
47539
47540         * modules/size_max: New file.
47541
47542         * modules/xsize: Depend on size_max module for size_max.m4.
47543
47544 2005-07-11  Simon Josefsson  <jas@extundo.com>
47545
47546         * lib/size_max.h: New file.
47547
47548 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
47549
47550         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
47551         copyright symbol and the year.
47552         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
47553         (version_etc_va): Use parameterized copyright notice.
47554         Reword to conform to the current GNU coding standards.
47555
47556 2005-07-11  Karl Berry  <karl@gnu.org>
47557
47558         * doc/gnulib.texi (Quoting): new node.
47559         (Initial import): more info, from Patrice.
47560
47561 2005-07-11  Bruno Haible  <bruno@clisp.org>
47562
47563         * gnulib-tool (func_usage): Document option --avoid.
47564         (Command line options): Handle --avoid.
47565         (func_acceptable): New function.
47566         (func_modules_transitive_closure): Use it.
47567
47568 2005-07-11  Bruno Haible  <bruno@clisp.org>
47569
47570         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
47571         Reported by Jim Meyering.
47572
47573 2005-07-10  Bruno Haible  <bruno@clisp.org>
47574
47575         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
47576         Needed when size_t is smaller than 'unsigned int'.
47577         Reported by Paul Eggert.
47578
47579 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
47580
47581         * modules/argp (Depends-on): Add unlocked-io
47582
47583 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
47584
47585         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
47586         block of defines.
47587
47588 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
47589
47590         * config/srclist.txt: Comment out regcomp.c, since we have a porting
47591         fix now.
47592
47593 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
47594         and Paul Eggert  <eggert@cs.ucla.edu>
47595
47596         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
47597         in wint_t, not wchar_t.  Remove now-unnecessary cast.
47598
47599 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
47600
47601         * modules/regex (Files): Add lib/regex_internal.c,
47602         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
47603         (Depends-on): Add extensions.
47604         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
47605
47606 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
47607
47608         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
47609         pathconf.
47610         * m4/same.m4 (gl_SAME): Likewise.
47611         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
47612
47613         * m4/regex.m4: Adjust to new libc regex implementation.
47614         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
47615         all the .c and .h parts of (the new) regex.
47616         Quote the m4 stuff better.
47617         Check for RE_ICASE bug of old gnulib.
47618         Check for REG_STARTEND of recent libc.
47619         Rename local variables from jm_* to gl_*.
47620         Quote operand of "test -f".
47621         Say "recent enough" version of libc, not "version 2".
47622         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
47623         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
47624         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
47625         Remove check for btowc, isascii.
47626         Require AM_LANGINFO_CODESET.
47627
47628 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
47629
47630         * lib/regex.c, regex.h: Sync from libc.
47631         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
47632         * lib/regexec.c:
47633         New files, synced from libc, except that regex_internal.h
47634         currently has a small porting fix.
47635
47636 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
47637
47638         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
47639         regex_internal.c, regexec.c.
47640         Add regex_internal.h too, but as a comment, since the libc version
47641         is currently broken in gnulib mode.
47642
47643 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
47644
47645         Support programs like Emacs that use gnulib but not gettext.
47646         * MODULES.html.sh (Internationalization functions): Add gettext-h.
47647         * modules/gettext-h: New file.
47648         * modules/gettext (Files): Remove lib/gettext.h.
47649         (Depends-on): Add gettext-h.
47650         (Makefile.am): Remove lib_SOURCES.
47651         * modules/argmatch, modules/c-stack, modules/closeout:
47652         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
47653         * modules/execute, modules/file-type, modules/getaddrinfo:
47654         * modules/getopt, modules/human, modules/javacomp:
47655         * modules/javaexec, modules/mkdir-p, modules/obstack:
47656         * modules/openat, modules/pagealign_alloc, modules/pipe:
47657         * modules/quotearg, modules/regex, modules/rpmatch:
47658         * modules/unicodeio, modules/userspec, modules/version-etc:
47659         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
47660         * modules/xsetenv:
47661         Depend on gettext-h, not gettext.
47662
47663 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
47664
47665         * gnulib-tool (func_import): Add support for 'public domain' license.
47666         * modules/alloca, modules/atexit, modules/memmove:
47667         Now public domain, not GPL.
47668         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
47669         * modules/realloc, modules/strerror, modules/strtod:
47670         Now LGPL, not GPL.
47671
47672 2005-07-05  Bruno Haible  <bruno@clisp.org>
47673
47674         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
47675         autoconf CVS. Needed for mingw.
47676
47677 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
47678
47679         Remove the dependency of the strftime module on the tzset module.
47680         * modules/strftime (Depends-on): Remove dependency on tzset.
47681
47682 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
47683
47684         Remove the dependency of the strftime module on the tzset module.
47685         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
47686         gl_FUNC_TZSET_CLOBBER.
47687
47688 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
47689
47690         Remove the dependency of the strftime module on the tzset module.
47691         * lib/strftime.c (my_strftime)
47692         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
47693         Copy the input structure, to work around some of the bug with
47694         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
47695         Solaris releases, you should also use the tzset module, but we won't
47696         require it as a dependency any more since we don't want LGPLed code
47697         to depend on GPLed code.
47698
47699 2005-07-02  Jim Meyering  <jim@meyering.net>
47700
47701         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
47702         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
47703         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
47704         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
47705
47706 2005-07-02  Jim Meyering  <jim@meyering.net>
47707
47708         * lib/backupfile.c (backup_args): Change a `0' to NULL.
47709
47710 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
47711
47712         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
47713         declares only 'struct timespec;' (!).
47714
47715 2005-07-01  Jim Meyering  <jim@meyering.net>
47716
47717         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
47718         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
47719         * lib/save-cwd.c, tempname.c:
47720         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
47721         and don't include <sys/file.h>).
47722
47723 2005-06-29  Jim Meyering  <jim@meyering.net>
47724
47725         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
47726         type name.  Use the variable name instead.
47727         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
47728         Likewise.
47729
47730 2005-06-28  Simon Josefsson  <jas@extundo.com>
47731
47732         * modules/check-version (Files): Add check-version.m4.
47733
47734 2005-06-28  Simon Josefsson  <jas@extundo.com>
47735
47736         * m4/check-version.m4: New file, suggested by Jim Meyering
47737         <jim@meyering.net>.
47738
47739 2005-06-28  Simon Josefsson  <jas@extundo.com>
47740
47741         * lib/check-version.h, lib/check-version.c: New files.
47742
47743 2005-06-28  Simon Josefsson  <jas@extundo.com>
47744
47745         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
47746         collision with global variable.  Better indentation.  Don't
47747         increment buffer pointer beyond buffer end.  Based on comments
47748         from Paul Eggert <eggert@cs.ucla.edu>.
47749
47750         * lib/base64.h: Indent.
47751
47752 2005-06-28  Simon Josefsson  <jas@extundo.com>
47753
47754         * doc/gnulib.texi (Library version handling): New section.
47755
47756 2005-06-28  Jim Meyering  <jim@meyering.net>
47757
47758         * check-module (find_included_lib_files): Hard-code another
47759         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
47760         but modules/fts-lgpl (correctly) does not list those files.
47761
47762         * modules/canonicalize (Files): Add lib/pathmax.h.
47763
47764 2005-06-25  Simon Josefsson  <jas@extundo.com>
47765
47766         * modules/check-version: New file.
47767
47768 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
47769
47770         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
47771         initializer of struct addrinfo, as an indication that we don't
47772         care how many members the structure has.
47773
47774 2005-06-24  Derek Price  <derek@ximbiot.com>
47775         and Bruno Haible  <bruno@clisp.org>
47776
47777         Remove stat module & update lstat.
47778         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
47779         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
47780         * m4/stat.m4: Remove this file.
47781
47782 2005-06-24  Derek Price  <derek@ximbiot.com>
47783         and Bruno Haible  <bruno@clisp.org>
47784
47785         Remove stat module & update lstat.
47786         * lib/stat.c: Remove this file...
47787         (slash_aware_lstat): ...moving this content and its support...
47788         * lib/lstat.c (rpl_lstat): ...into here.
47789         * lib/lstat.h: New file.
47790
47791 2005-06-24  Derek Price  <derek@ximbiot.com>
47792         and Bruno Haible  <bruno@clisp.org>
47793
47794         Remove stat module & update lstat.
47795         * config/srclist.txt (libc sources): Remove stat.
47796
47797 2005-06-24  Derek Price  <derek@ximbiot.com>
47798         and Bruno Haible  <bruno@clisp.org>
47799
47800         Remove stat module & update lstat.
47801         * MODULES.html.sh (stat): Remove.
47802         * MODULES.html: Regenerated.
47803         * modules/lstat (Description): Correct function name.
47804         (Files): Add "lstat.h".
47805         (Depends-on): Remove stat, add xalloc, stat-macros.
47806         * modules/stat: Remove this file.
47807         (Include): Add "lstat.h", remove <sys/stat.h>.
47808
47809 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
47810
47811         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
47812         (ranged_convert): Don't save conversion in a temporary struct.
47813         This causes a warning with GCC 4.0.0, and anyway in the typical
47814         case it's not worth the extra 100 bytes or so of code.
47815         (ranged_convert, __mktime_internal): When calling a function via a
47816         pointer P, use P () rather than (*P) (), as we now assume C89 or
47817         better.
47818
47819 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
47820
47821         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
47822         "who -r" failed to give output.  Problem reported by Tim Waugh.
47823
47824         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
47825         (xcalloc): Use it to avoid needless tests.
47826         Problem reported by Jim Meyering.
47827
47828 2005-06-20  Derek Price  <derek@ximbiot.com>
47829
47830         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
47831         unnecessary for Autoconfs > 2.59c.
47832
47833 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
47834
47835         * lib/argp.h (__option_is_short): Check upper limit of
47836         __key. Isprint() requires its argument to have the value
47837         of an unsigned char or EOF.
47838
47839 2005-06-16  Jim Meyering  <jim@meyering.net>
47840
47841         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
47842         when either N or S is zero.
47843
47844 2005-06-16  Derek Price  <derek@ximbiot.com>
47845
47846         * m4/bison.m4: Declare YACC & YFLAGS precious.
47847
47848 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
47849
47850         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
47851         multibyte string or pattern, fall back on unibyte matching.
47852         Problem reported by James Youngman.
47853
47854 2005-06-08  Bruno Haible  <bruno@clisp.org>
47855
47856         * modules/csharpcomp: New file.
47857         * MODULES.html.sh (C#): Add csharpcomp.
47858
47859 2005-06-08  Bruno Haible  <bruno@clisp.org>
47860
47861         * m4/csharpcomp.m4: New file, from GNU gettext.
47862
47863 2005-06-08  Bruno Haible  <bruno@clisp.org>
47864
47865         * lib/csharpcomp.h: New file, from GNU gettext.
47866         * lib/csharpcomp.c: New file, from GNU gettext.
47867         * lib/csharpcomp.sh.in: New file, from GNU gettext.
47868
47869 2005-06-08  Bruno Haible  <bruno@clisp.org>
47870
47871         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
47872         warning on mingw.
47873
47874 2005-06-07  Derek Price  <derek@ximbiot.com>
47875
47876         Sync from CVS.
47877         * lib/glob_.h: Indent nested #ifdef.
47878
47879 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
47880
47881         Sync from coreutils.
47882         Use "file name" when talking about file names, instead of "filename"
47883         or "path", as per the GNU coding standards.
47884         * lib/mkdir-p.c: Renamed from makepath.c.
47885         (make_dir_parents): Renamed from make_path.  All callers changed.
47886         * lib/mkdir-p.h: Likewise.  All includers changed.
47887         * lib/filenamecat.c: Renamed from path-concat.c.
47888         (file_name_concat): Renamed from path_concat.  All callers changed.
47889         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
47890         * lib/filenamecat.h: Likewise.  All includers changed.
47891         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
47892         in comments or local variable names.
47893         * lib/basename.c: Likewise.
47894         * lib/canonicalize.c, canonicalize.h: Likewise.
47895         * lib/dirname.c, dirname.h: Likewise.
47896         * lib/euidaccess.c: Likewise.
47897         * lib/exclude.c: Likewise
47898         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
47899         * lib/fsusage.c, fsuage.h: Likewise.
47900         * lib/fts.c, fts_.h: Likewise.
47901         * lib/getcwd.c: Likewise.
47902         * lib/getloadavg.c: Likewise.
47903         * lib/mkstemp.c: Likewise.
47904         * lib/mountlist.c, mountlist.h: Likewise.
47905         * lib/openat.c, openat.h: Likewise.
47906         * lib/readlink-stub.c: Likewise.
47907         * lib/readutmp.c, readutmp.h: Likewise.
47908         * lib/rename.c: Likewise.
47909         * lib/rmdir.c: Likewise.
47910         * lib/same.c: Likewise.
47911         * lib/savedir.c: Likewise.
47912         * lib/stripslash.c: Likewise.
47913         * lib/tempname.c: Likewise.
47914         * lib/xreadlink.c: Likewise.
47915         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
47916         All uses changed.
47917         * lib/exclude.h: Likewise.
47918
47919         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
47920         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
47921         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
47922         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
47923         * lib/pathmax.h: Include <limits.h> unconditionally, since other
47924         files have been getting away with it for years (MORE/BSD 4.3
47925         is extinct now).
47926         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
47927         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
47928
47929         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
47930         Define to 256, not 255, as per modern POSIX.
47931
47932 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
47933
47934         Sync from coreutils.
47935         Use "file name" when talking about file names, instead of "filename"
47936         or "path", as per the GNU coding standards.
47937         * MODULES.html.sh: mkdir-p renamed from makepath.
47938         filenamecat renamed from path-concat.
47939         * modules/filenamecat: Renamed from modules/path-concat.
47940         (Files): filenamecat.h and filenamecat.c renamed from
47941         path-concat.h and path-concat.c.
47942         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
47943         (Include): filenamecat.h, not path-concat.h.
47944         * modules/mkdir-p: Renamed from modules/makepath.
47945         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
47946         makepath.c.
47947         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
47948         (Include): mkdir-p.h, not makepath.h.
47949
47950 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
47951
47952         Sync from coreutils.
47953         * m4/mkdir-p.m4: Renamed from makepath.m4.
47954         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
47955         Rename files from makepath.c to mkdir-p.c, and from
47956         makepath.h to mkdir-p.h.
47957         * m4/filenamecat.m4: Renamed from path-concat.m4.
47958         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
47959         Rename files from path-concat.c to filenamecat.c,
47960         and from path-concat.h to filenamecat.h.
47961         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
47962         "file name" in local variables or comments.
47963         * m4/rename.m4: Likewise.
47964
47965 2005-06-01  Bruno Haible  <bruno@clisp.org>
47966
47967         * modules/csharpexec: New file.
47968         * MODULES.html.sh (C#): New section.
47969
47970 2005-06-01  Bruno Haible  <bruno@clisp.org>
47971
47972         * m4/csharp.m4: New file, from GNU gettext.
47973         * m4/csharpexec.m4: New file, from GNU gettext.
47974
47975 2005-06-01  Bruno Haible  <bruno@clisp.org>
47976
47977         * lib/csharpexec.h: New file, from GNU gettext.
47978         * lib/csharpexec.c: New file, from GNU gettext.
47979         * lib/csharpexec.sh.in: New file, from GNU gettext.
47980
47981 2005-05-31  Derek Price  <derek@ximbiot.com>
47982             Paul Eggert  <eggert@cs.ucla.edu>
47983
47984         Sync from cvs.
47985         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
47986
47987 2005-05-31  Derek Price  <derek@ximbiot.com>
47988             Paul Eggert  <eggert@cs.ucla.edu>
47989
47990         Sync from cvs.
47991         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
47992
47993 2005-05-29  Derek Price  <derek@ximbiot.com>
47994
47995         * config/srclist.txt (glob_.h, glob.c): Add these files.
47996
47997 2005-05-29  Derek Price  <derek@ximbiot.com>
47998
47999         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
48000         * modules/glob: New file.
48001         * modules/getlogin_r: Add link to POSIX spec in description.
48002
48003 2005-05-29  Derek Price  <derek@ximbiot.com>
48004             Paul Eggert  <eggert@cs.ucla.edu>
48005
48006         * m4/glob.m4: New file.
48007
48008 2005-05-29  Derek Price  <derek@ximbiot.com>
48009             Paul Eggert  <eggert@cs.ucla.edu>
48010
48011         * lib/glob_.h, lib/glob.c: New files.
48012
48013 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
48014
48015         * modules/fts (Files): Remove m4/inttypes-pri.m4.
48016         * modules/fts-lgpl (Depends-on): Remove gettext.
48017
48018 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
48019
48020         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
48021         and don't require gt_INTTYPES_PRI.
48022
48023 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
48024
48025         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
48026
48027         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
48028         the configuration hassle isn't worth it.
48029         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
48030         (LONGEST_MODIFIER, PRIuMAX): Remove.
48031
48032 2005-05-27  Bruno Haible  <bruno@clisp.org>
48033
48034         * lib/getlogin_r.h: Remove second include of <stddef.h>.
48035
48036 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
48037
48038         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
48039         _POSIX_PTHREAD_SEMANTICS for Solaris.
48040
48041 2005-05-25  Derek Price  <derek@ximbiot.com>
48042
48043         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
48044
48045 2005-05-25  Derek Price  <derek@ximbiot.com>
48046             Paul Eggert  <eggert@cs.ucla.edu>
48047
48048         * modules/getlogin_r, m4/getlogin_r.m4: New files.
48049         * lib/getlogin_r.c, getlogin_r.h: New files.
48050
48051 2005-05-25  Bruno Haible  <bruno@clisp.org>
48052             Derek Price  <derek@ximbiot.com>
48053
48054         * lib/getlogin_r.h: Simplify API documentation.
48055
48056 2005-05-23  Derek Price  <derek@ximbiot.com>
48057
48058         * modules/minmax (Files): Add m4/minmax.m4.
48059         (configure.ac): Add gl_MINMAX.
48060
48061 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
48062
48063         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
48064         so that unistd-safer.h (GPL'ed code) need not be included.
48065
48066 2005-05-22  Bruno Haible  <bruno@clisp.org>
48067
48068         * m4/minmax.m4: New file.
48069         Based on a patch by Derek Price <derek@ximbiot.com>.
48070
48071 2005-05-22  Bruno Haible  <bruno@clisp.org>
48072
48073         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
48074         (INT64_MIN): Fix definition.
48075         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
48076
48077         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
48078         NEED_SIGNED_INT_TYPES.
48079
48080         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
48081         HAVE_SYSTEM_INTTYPES.
48082
48083 2005-05-22  Bruno Haible  <bruno@clisp.org>
48084
48085         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
48086         Also include <sys/param.h> if it defines MIN, MAX.
48087         Based on a patch by Derek Price <derek@ximbiot.com>.
48088
48089 2005-05-21  Jim Meyering  <jim@meyering.net>
48090
48091         * modules/fts (Files): Add m4/inttypes-pri.m4.
48092         (Depends-on): Add lstat and remove gettext.  Alphabetize.
48093
48094 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
48095
48096         New fts module.
48097         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
48098         (setup_dir, free_dir): New functions.
48099         (enter_dir, leave_dir): Define trivial
48100         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
48101         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
48102         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
48103         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
48104         Move to fts-cycle.c.
48105         (fts_open): Use setup_dir.
48106         (fts_close): Use free_dir.
48107         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
48108         This adds a label and some gotos, but the alternatives were messier.
48109         Check for memory allocation failure when entering a dir.
48110         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
48111         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
48112         (FTS): New member fts_cycle, that is a union that contains the
48113         old active_dir_ht and cycle_state.  All uses changed to mention
48114         fts_cycle.ht and fts_cycle.state.
48115         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
48116         fts.c, with the following changes:
48117         (setup_dir, free_dir): New functions.
48118         (enter_dir): Now returns bool.  Return true if successful, false
48119         if memory exhausted.  All callers changed.
48120         Do not bother partly cleaning up on
48121         memory allocation failure; that is free_dir's job.
48122         However, free ad if hash_insert fails, to avoid memory leak.
48123         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
48124         fts->fts_options to see which union member to use.
48125
48126 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
48127
48128         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
48129         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
48130
48131 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
48132
48133         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
48134
48135 2005-05-20  Jim Meyering  <jim@meyering.net>
48136
48137         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
48138         Now a macro, to pacify GCC.
48139
48140 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
48141
48142         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
48143         of -1.
48144
48145 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
48146
48147         * lib/chown.c (rpl_chown): Return -1 on failure.
48148
48149 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
48150
48151         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
48152         Don't check for stddef.h.
48153         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
48154         don't use its results.
48155         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
48156         since we include them unconditionally.  Don't require
48157         AM_STDBOOL_H, since stdbool is a prerequisite.
48158         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
48159         since we assume C89 or better.
48160         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
48161         as we don't use their results.
48162         Don't check for fchdir, memmove, memset, strrchr, as we use
48163         them unconditionally.
48164         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
48165         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
48166
48167 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
48168
48169         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
48170         Include <stddef.h> unconditionally, since we assume C89 now.
48171         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
48172         * lib/fts.c: Include fts_.h first, to check interface.
48173         Do not include intprops.h; no longer needed.
48174         Include cycle-check.h and hash.h, since fts_.h no longer does.
48175         Remove unnecessary casts of closedir to void.
48176         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
48177         decide whether to decrement nlinks.
48178         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
48179         (FTS): Use struct hash_table * instead of Hash_table, so that
48180         we no longer need to include hash.h here.
48181
48182 2005-05-18  Jim Meyering  <jim@meyering.net>
48183
48184         * modules/dirfd (License): Change to LGPL.  Most of the code
48185         is already in the public domain.
48186
48187 2005-05-18  Jim Meyering  <jim@meyering.net>
48188
48189         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
48190         Reported by Yoann Vandoorselaere.
48191
48192 2005-05-17  Jim Meyering  <jim@meyering.net>
48193
48194         * m4/fts.m4: New file, from coreutils.
48195
48196 2005-05-17  Jim Meyering  <jim@meyering.net>
48197
48198         * lib/fts.c, lib/fts_.h: New files, from coreutils.
48199
48200 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
48201
48202         Sync from coreutils.
48203         * m4/unlinkdir.m4: New file.
48204
48205 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
48206
48207         Sync from coreutils.
48208         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
48209         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
48210         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
48211         White space changes only.
48212         * lib/makepath.c (make_path): Port to hosts where leading "//" is
48213         special.
48214         * lib/yesno.c: Include getline.h, not ctype.h.
48215         (yesno): Don't remove leading white space; POSIX doesn't allow it.
48216         Use getline to remove arbitrary restriction on response length.
48217
48218 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
48219
48220         * config/srclist-update: Spell out "Street" in FSF postal
48221         mail address; this is the style the FSF seems to prefer.
48222
48223         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
48224         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
48225         this updates FSF postal mail address.
48226
48227         Sync from coreutils.
48228         * modules/unlinkdir: New file.
48229         * modules/yesno (Depends-on): Add getline.
48230         * MODULES.html.sh (File system functions): Add unlinkdir.
48231
48232 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
48233
48234         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
48235         lib/strsep.h:
48236         Change the initial comment to refer to GPL, not LGPL.
48237         gnulib-tool will change it to LGPL as needed.
48238
48239         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
48240         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
48241         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
48242         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
48243         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
48244         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
48245         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
48246         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
48247         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
48248         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
48249         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
48250         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
48251         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
48252         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
48253         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
48254         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
48255         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
48256         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
48257         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
48258         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
48259         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
48260         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
48261         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
48262         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
48263         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
48264         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
48265         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
48266         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
48267         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
48268         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
48269         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
48270         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
48271         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
48272         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
48273         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
48274         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
48275         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
48276         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
48277         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
48278         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
48279         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
48280         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
48281         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
48282         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
48283         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
48284         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
48285         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
48286         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
48287         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
48288         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
48289         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
48290         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
48291         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
48292         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
48293         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
48294         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
48295         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
48296         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
48297         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
48298         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
48299         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
48300         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
48301         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
48302         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
48303         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
48304         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
48305         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
48306         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
48307         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
48308         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
48309         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
48310         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
48311         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
48312         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
48313         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
48314         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
48315         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
48316         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
48317         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
48318         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
48319         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
48320         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
48321         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
48322         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
48323         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
48324         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
48325         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
48326         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
48327         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
48328         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
48329         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
48330         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
48331         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
48332         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
48333         lib/yesno.c, lib/yesno.h:
48334         Update FSF postal mail address.
48335
48336 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
48337
48338         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
48339         tests/test-memmem.c, tests/test-stpncpy.c:
48340         Update FSF postal mail address.
48341
48342 2005-05-13  Bruno Haible  <bruno@clisp.org>
48343
48344         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
48345         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
48346         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
48347         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
48348         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
48349         Add support for 64-bit integers in the MSVC compiler.
48350
48351 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
48352
48353         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
48354
48355 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
48356
48357         * gnulib-tool (func_import): Sort and uniquify recommended includes.
48358
48359 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
48360
48361         * doc/getdate.texi (General date syntax): Don't say that date
48362         date --iso-8601=ns generates acceptable dates; it doesn't yet.
48363         Problem reported by Nic Ferrier.
48364
48365 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
48366
48367         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
48368         specified in ai_socktype. Fix invalid ai_protocol
48369         check. ai_protocol is usually set to 0 or depending on
48370         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
48371         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
48372         ai_socktype / ai_protocol in the returned addrinfo structure.
48373
48374 2005-05-10  Simon Josefsson  <jas@extundo.com>
48375
48376         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
48377         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
48378
48379 2005-05-10  Karl Berry  <karl@gnu.org>
48380
48381         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
48382         (from http://www.gnu.org/licenses).
48383         * doc/COPYING.LIB: also rename to COPYING.LESSER.
48384         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
48385         fdl.texi suffices.
48386
48387 2005-05-10  Karl Berry  <karl@gnu.org>
48388
48389         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
48390         (COPYING.DOC): remove.
48391
48392         * config/srclist-update: new FSF address.
48393
48394 2005-05-10  Derek Price  <derek@ximbiot.com>
48395
48396         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
48397         possible.
48398
48399 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
48400             Bruno Haible  <bruno@clisp.org>
48401
48402         * modules/inet_ntop: New file.
48403         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
48404         inet_ntop.
48405
48406 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
48407             Bruno Haible  <bruno@clisp.org>
48408
48409         * m4/inet_ntop.m4: New file.
48410
48411 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
48412             Bruno Haible  <bruno@clisp.org>
48413
48414         * lib/inet_ntop.h: New file.
48415         * lib/inet_ntop.c: New file, from glibc with modifications.
48416
48417 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
48418
48419         * modules/time_r (License): Change to LGPL.
48420         * modules/extensions (License): Change to LGPL.  Actually,
48421         the license is more permissive than that, but currently gnulib-tool
48422         doesn't know how to handle more-permissive licenses.
48423
48424         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
48425         Problem reported by Dave Love.
48426
48427 2005-05-08  Jim Meyering  <jim@meyering.net>
48428
48429         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
48430         blank.
48431
48432 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
48433
48434         * modules/argmatch (Depends-on): Add stdbool.
48435         * modules/backupfile (Depends-on): Likewise.
48436         * modules/chdir-long (Depends-on): Likewise.
48437         * modules/closeout (Depends-on): Likewise.
48438         * modules/cycle-check (Depends-on): Likewise.
48439         * modules/dirname (Depends-on): Likewise.
48440         * modules/fnmatch (Depends-on): Likewise.
48441         * modules/fsusage (Depends-on): Likewise.
48442         * modules/fwriteerror (Depends-on): Likewise.
48443         * modules/getcwd (Depends-on): Likewise.
48444         * modules/getloadavg (Depends-on): Likewise.
48445         * modules/hard-locale (Depends-on): Likewise.
48446         * modules/makepath (Depends-on): Likewise.
48447         * modules/mountlist (Depends-on): Likewise.
48448         * modules/nanosleep (Depends-on): Likewise.
48449         * modules/posixtm (Depends-on): Likewise.
48450         * modules/quotearg (Depends-on): Likewise.
48451         * modules/readtokens (Depends-on): Likewise.
48452         * modules/readtokens0 (Depends-on): Likewise.
48453         * modules/readutmp (Depends-on): Likewise.
48454         * modules/save-cwd (Depends-on): Likewise.
48455         * modules/strftime (Depends-on): Likewise.
48456         * modules/userspec (Depends-on): Likewise.
48457         * modules/utimecmp (Depends-on): Likewise.
48458         * modules/xgetcwd (Depends-on): Likewise.
48459         * modules/xnanosleep (Depends-on): Likewise.
48460         * modules/xstrtod (Depends-on): Likewise.
48461         * modules/yesno (Depends-on): Likewise.
48462
48463 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
48464
48465         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
48466         needless checks.
48467
48468 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
48469
48470         Merge from coreutils.  Among other things,
48471         add bulletproofing for cases where stdin, stdout, or stderr are closed.
48472         * lib/fd-safer.c: New file.
48473         * lib/fcntl-safer.h, open-safer.c: Remove.
48474         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
48475         * lib/dup-safer.c: Include unistd-safer.h first.
48476         Don't include errno.h.
48477         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
48478         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
48479         * lib/file-type.c: Rely on file-type.h change.
48480         * lib/getloadavg.c: Include unistd-safer.h.
48481         (getloadavg): Use safer open.
48482         * lib/getusershell.c: Include "stdio-safer.h".
48483         (getusershell): Use safer fopen.
48484         * lib/long-options.c (long_options): Use NULL rather than 0.
48485         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
48486         'free'.
48487         * lib/modechange.c: Likewise.
48488         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
48489         (MODE_DONE): New constant.
48490         (struct mode_change): Remove 'next' member.
48491         (make_node_op_equals): New function; like the old one of the
48492         same name, except it allocates an array.
48493         (mode_compile, mode_create_from_ref): Use it.
48494         (mode_compile): Allocate result as an array, not a linked list.
48495         Parse octal string ourself, so that we catch mistakes like "+0".
48496         (mode_adjust): Arg is an array, not a linked list.
48497         * lib/modechange.c: Include stat-macros.h, xalloc.h.
48498         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
48499         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
48500         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
48501         Remove.  This is now stat-macros.h's job.
48502         (talloc): Remove.  All callers replaced by xalloc, so that
48503         our invokers don't have to worry about reporting memory failures.
48504         (make_node_op_equals): Remove.
48505         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
48506         New constants.
48507         (struct mode_change): Moved here from modechange.h.
48508         (mode_append_entry): Remove.
48509         (mode_compile): Remove MASKED_OPS arg, since it encouraged
48510         apps to have incorrect behavior.  Use simpler algorithm for head
48511         and tail.  Don't futz with umask; that's now the job of mode_adjust.
48512         Detect more invalid usages rather than having somewhat-random behavior.
48513         Don't insert an "a=" action, as that leads to incorrect behavior.
48514         (mode_compile, mode_create_from_ref): Return NULL on error instead
48515         of an enum, since now there's only one way to have an error.  All
48516         callers changed.
48517         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
48518         at the correct time.  Simplify calculation of "+u" and its ilk.
48519         Don't mishandle "+X".
48520         (mode_free): Remove "register" and localize decls.
48521         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
48522         (struct mode_change): Move to modechange.c; callers don't
48523         need to see this stuff.
48524         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
48525         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
48526         (mode_change, mode_adjust): Reflect the new signatures noted above.
48527         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
48528         that might redefine system include files.
48529         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
48530         (my_usleep): Use NULL rather than (void *) 0.
48531         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
48532         Use siginterrupt to specify that system calls should be interrupted.
48533         (rpl_nanosleep): Move initialization of suspended closer to call of
48534         my_usleep.
48535         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
48536         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
48537         (desirable_utmp_entry): New function.
48538         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
48539         using x2nrealloc, to simplify logic.
48540         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
48541         size calculation.  Do not assume utmp file is a regular file.
48542         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
48543         (READ_UTMP_CHECK_PIDS): New constant.
48544         * lib/save-cwd.c: Include unistd-safer.h.
48545         (save_cwd): Use fd_safer.
48546         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
48547         [!_LIBC] Include "stat-macros.h" instead.
48548         * lib/unistd-safer.h (fd_safer): New decl.
48549
48550 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
48551
48552         * modules/getloadavg (Depends-on): Add unistd-safer.
48553         * modules/getusershell (Depends-on): Add stdio-safer.
48554         * modules/lstat (Depends-on): Remove xalloc.
48555         * modules/mkstemp (Depends-on): Add stat-macros.
48556         * modules/modechange (Depends-on): Remove xstrtol.
48557         Add stat-macros, xalloc.
48558         * modules/save-cwd (Depends-on): Add unistd-safer.
48559         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
48560         * modules/unistd-safer (Files): Add lib/fd-safer.c
48561         (Makefile.am): Remove lib_SOURCES.
48562
48563         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
48564         Remove fcntl-safer; unistd-safer supersedes it.
48565
48566 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
48567
48568         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
48569         AC_HEADER_STAT.
48570         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
48571         (gl_PREREQ_CHOWN): Remove.
48572         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
48573         it.  Don't require AC_HEADER_STAT.
48574         (gl_PREREQ_LSTAT): Remove.
48575         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
48576         Don't require AC_HEADER_STAT.
48577         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
48578         (gl_PREREQ_RMDIR): Remove.
48579         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
48580         mention stat-macros.h or AC_HEADER_STAT, since we'll make
48581         the stat-macros module a prerequisite.
48582         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
48583         * m4/filemode.m4 (gl_FILEMODE): Likewise.
48584         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
48585         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
48586         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
48587         variable names.
48588         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
48589         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
48590         variable prefixes.
48591         * m4/fcntl-safer.m4: Remove.
48592         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
48593         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
48594         Invoke gl_PREREQ_FD_SAFER.
48595         (gl_PREREQ_FD_SAFER): New macro.
48596         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
48597         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
48598         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
48599         Remove duplicate call to AC_LIBOBJ(readutmp).
48600         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
48601
48602         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
48603         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
48604
48605 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
48606
48607         * MODULES.html.sh (Misc): Add byteswap.
48608
48609 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
48610
48611         * modules/getcwd (Depends-on): Add extensions.
48612         * modules/openat (Depends-on): Likewise.
48613
48614 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
48615
48616         * modules/byteswap: New file.
48617
48618 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
48619
48620         * m4/byteswap.m4: New file.
48621
48622 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
48623
48624         * lib/byteswap_.h: New file.
48625
48626 2005-04-25  Karl Berry  <karl@gnu.org>
48627
48628         * m4/gettext.m4: Update from GNU gettext 0.14.4.
48629
48630 2005-04-25  Albert Chin  <china@thewrittenword.com>
48631
48632         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
48633         Toolkit C bug.
48634
48635 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
48636
48637         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
48638         (func_ln_if_changed) Remove forcibly for no error message
48639         in case file does not exist.
48640
48641 2005-04-19  Simon Josefsson  <jas@extundo.com>
48642
48643         * gnulib-tool (Options): Make --symlink mean --symbolic.
48644
48645 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
48646
48647         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
48648
48649 2005-04-16  Simon Josefsson  <jas@extundo.com>
48650
48651         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
48652
48653 2005-04-15  Simon Josefsson  <jas@extundo.com>
48654
48655         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
48656
48657 2005-04-15  Simon Josefsson  <jas@extundo.com>
48658
48659         * gnulib-tool: Rename --symlink to --symbolic.
48660
48661 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
48662
48663         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
48664         symbolic links to files instead of copying/moving.  Add --aux-dir,
48665         specifying directory relative --dir where auxiliary build tools
48666         are placed.
48667
48668 2005-04-14  Bruno Haible  <bruno@clisp.org>
48669
48670         * modules/allocsa (License): Change to LGPL.
48671         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
48672
48673 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
48674
48675         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
48676         that "UTC +1 second" continues to work.  Problem reported
48677         by Dmitry V. Levin.
48678         (relunit_snumber): New rule.
48679         (relunit): Use it.
48680
48681 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
48682
48683         * lib/getdate.y (universal_time_zone_table): New constant.
48684         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
48685         universal_time_zone_table.
48686         (lookup_zone): Prefer universal_time_zone_table to
48687         local_time_zone_table, so that "GMT" time stamps are allowed in
48688         London during the summer.  Problem reported by Ian Abbott.
48689
48690 2005-04-12  Jim Meyering  <jim@meyering.net>
48691
48692         * lib/human.c (humblock): Set *options even when returning due to
48693         xstrtoumax conversion failure.  Thanks to a used-uninitialized
48694         warning from gcc-4.
48695
48696 2005-04-09  Jim Meyering  <jim@meyering.net>
48697
48698         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
48699         -Wuninitialized: initialize tm0.tm_year.
48700
48701 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
48702
48703         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
48704         count, since there's no maximum.  All uses changed.
48705         Add member dsts_seen.
48706         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
48707         not being INT_MAX.
48708         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
48709         Use pc_rels_seen to decide whther a date is absolute.
48710
48711         * lib/getdate.y (number): Don't overwrite year.
48712         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
48713         check.
48714
48715 2005-04-02  Simon Josefsson  <jas@extundo.com>
48716
48717         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
48718         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
48719
48720 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
48721
48722         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
48723         where no absolute path name can be longer than PATH_MAX.
48724
48725 2005-03-27  Jim Meyering  <jim@meyering.net>
48726
48727         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
48728
48729 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
48730
48731         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
48732         "one's complement" -> "ones' complement" in comment, as per Knuth.
48733         "value of type" -> "type or expression" in comment.
48734         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
48735
48736 2005-03-26  Jim Meyering  <jim@meyering.net>
48737
48738         Comment nits.
48739         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
48740         Correct typos: s/or/of/.
48741
48742 2005-03-26  Jim Meyering  <jim@meyering.net>
48743
48744         * modules/check-include-files: Move to ../ and rename to...
48745         * check-module: ...this.
48746
48747 2005-03-25  Jim Meyering  <jim@meyering.net>
48748
48749         * modules/xvasprintf (Files): Add xalloc.h.
48750
48751 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
48752
48753         * modules/gettext (Files): config/config.rpath ->
48754         build-aux/config.rpath
48755         * modules/iconv (Files): Likewise.
48756         Problem reported by Oskar Liljeblad.
48757
48758 2005-03-23  Jim Meyering  <jim@meyering.net>
48759
48760         * modules/check-include-files: New script to check for
48761         missing dependencies, multiple includes, etc.
48762
48763         * modules/c-strtold (Depends-on): Add xalloc.
48764         * modules/c-strtod (Depends-on): Add xalloc.
48765         * modules/hash (Depends-on): Add xalloc.
48766         (Files): Remove lib/xalloc.h.
48767
48768         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
48769         * modules/userspec (Files): Add lib/inttostr.h.
48770
48771 2005-03-23  Jim Meyering  <jim@meyering.net>
48772
48773         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
48774
48775 2005-03-22  Jim Meyering  <jim@meyering.net>
48776
48777         * modules/stat-macros: New module.
48778         * modules/canonicalize, modules/euidaccess, modules/file-type,
48779         * modules/filemode, modules/lchown, modules/makepath,
48780         * modules/rmdir, modules/stat: Depend on new stat-macros module
48781         rather than listing lib/stat-macros.h manually.
48782         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
48783
48784 2005-03-22  Jim Meyering  <jim@meyering.net>
48785
48786         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
48787
48788 2005-03-22  Bruno Haible  <bruno@clisp.org>
48789
48790         * config/srclist.txt: Replace target directory 'config' with
48791         'build-aux'.
48792         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
48793         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
48794         ../build-aux/.
48795
48796 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
48797
48798         * modules/chdir-long (Depends-on): Add mempcpy.
48799
48800         * modules/acl, modules/backupfile, modules/c-strtod,
48801         modules/c-strtold, modules/canon-host, modules/canonicalize,
48802         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
48803         modules/exclude, modules/exitfail, modules/file-type,
48804         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
48805         modules/getdate, modules/getline, modules/getpagesize,
48806         modules/getpass, modules/getugroups, modules/group-member,
48807         modules/hard-locale, modules/hash, modules/human, modules/idcache,
48808         modules/inttostr, modules/long-options, modules/makepath,
48809         modules/md5, modules/memcasecmp, modules/memcoll,
48810         modules/modechange, modules/mountlist, modules/path-concat,
48811         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
48812         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
48813         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
48814         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
48815         modules/strftime, modules/strndup, modules/strverscmp,
48816         modules/timespec, modules/unlocked-io, modules/userspec,
48817         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
48818         modules/yesno:
48819         Remove lib_SOURCES line from Makefile.am section, as this is now
48820         done automatically by the corresponding Autoconf macro.
48821
48822 2005-03-21  Jim Meyering  <jim@meyering.net>
48823
48824         Changes imported from coreutils.
48825
48826         * lib/cycle-check.c: Don't include xalloc.h.
48827
48828         * lib/path-concat.c: Don't include assert.h.
48829         (path_concat): Remove assertion that would have triggered
48830         for ABASE starting with more than one slash.
48831         Reported by Andreas Schwab.
48832
48833         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
48834         properly when ABASE is an absolute file name.
48835         Correct the description of this function.
48836         Include <assert.h>.
48837         Add an assertion and a test driver.
48838         This fixes a bug introduced on 2004-07-02.
48839         Andreas Schwab reported the resulting failure of cp --parents:
48840         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
48841
48842 2005-03-21  Jim Meyering  <jim@meyering.net>
48843
48844         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
48845         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
48846
48847 2005-03-21  Jim Meyering  <jim@meyering.net>
48848         and  Paul Eggert  <eggert@cs.ucla.edu>
48849
48850         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
48851         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
48852         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
48853         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
48854         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
48855         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
48856         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
48857         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
48858         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
48859         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
48860         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
48861         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
48862         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
48863         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
48864         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
48865         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
48866         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
48867         for these modules.
48868
48869 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
48870
48871         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
48872         (which shouldn't happen), generate nothing instead of returning 0
48873         immediately, so that nstrftime (NULL, ...) doesn't return 0.
48874
48875 2005-03-16  Bruno Haible  <bruno@clisp.org>
48876
48877         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
48878         HAVE_LONGLONG_64BIT.
48879
48880 2005-03-16  Bruno Haible  <bruno@clisp.org>
48881
48882         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
48883         HAVE_LONGLONG_64BIT.
48884
48885 2005-03-16  Bruno Haible  <bruno@clisp.org>
48886
48887         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
48888         HAVE_LONGLONG_64BIT.
48889
48890 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
48891
48892         * lib/strftime.c (my_strftime): Prepend space to format so that we can
48893         reliably distinguish strftime failure from empty output on POSIX
48894         hosts.
48895
48896 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
48897
48898         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
48899         (iconv_string): Don't guess a size-zero buffer, as that might cause
48900         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
48901         result would be 'too large', where 'too large' is (heuristically)
48902         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
48903         overflow concerns.  This will prevent some unwanted malloc failures
48904         when the inputs are very large.
48905
48906 2005-03-15  Karl Berry  <karl@gnu.org>
48907
48908         * config/srclist.txt (config.rpath): from gettext.
48909         * config/config.rpath: update.
48910
48911 2005-03-15  Bruno Haible  <bruno@clisp.org>
48912
48913         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
48914         to 'negate'.
48915
48916         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
48917         variable.
48918
48919         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
48920         results.
48921
48922 2005-03-14  Simon Josefsson  <jas@extundo.com>
48923
48924         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
48925         <fx@gnu.org>.
48926
48927 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
48928
48929         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
48930         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
48931         intprops.h.
48932         * lib/strtol.c: Likewise.
48933
48934 2005-03-14  Jim Meyering  <jim@meyering.net>
48935
48936         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
48937         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
48938         to be nonzero so that we (and caller) can detect the difference
48939         between a valid zero-length expansion and an error return, even
48940         when the underlying strftime fails before writing anything into
48941         that location.
48942
48943 2005-03-14  Bruno Haible  <bruno@clisp.org>
48944
48945         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
48946         Update from GNU gettext 0.14.3.
48947
48948 2005-03-10  Jim Meyering  <jim@meyering.net>
48949
48950         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
48951
48952 2005-03-10  Jim Meyering  <jim@meyering.net>
48953
48954         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
48955         so that this module works on systems without fchdir.
48956
48957 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
48958
48959         Factor int-properties macros into a single file, except for
48960         glibc-related files.
48961         * lib/intprops.h: New file.
48962         * lib/getloadavg.c: Include it instead of limits.h.
48963         (INT_STRLEN_BOUND): Remove.
48964         * lib/human.c: Include intprops.h.
48965         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
48966         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
48967         302/1000.
48968         * lib/inttostr.h: Include intprops.h instead of limits.h.
48969         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
48970         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
48971         for consistency with intprops.h.
48972         (time_t_is_integer, twos_complement_arithmetic): Use them.
48973         * lib/sig2str.h: Include <signal.h>, intprops.h.
48974         (INT_STRLEN_BOUND): Remove.
48975         * lib/strftime.c (TYPE_SIGNED): Remove.
48976         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
48977         * lib/strtol.c: Adjust comments to match intprops.h.
48978         * lib/userspec.c: Include intprops.h.
48979         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
48980         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
48981         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
48982         instead of rolling our own expressions.
48983         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
48984
48985         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
48986         instead of int.
48987         (my_strftime): Do not mishandle years close to INT_MAX, by doing
48988         the right thing even if adding 1900 would overflow.  Similarly
48989         for tm_mon + 1 and tm_yday + 1.
48990         Make %Y always equivalent to %C%y, and similarly for %G and %g.
48991         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
48992         (DO_SIGNED_NUMBER): New macro.
48993         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
48994
48995 2005-03-07  Bruno Haible  <bruno@clisp.org>
48996
48997         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
48998
48999 2005-03-07  Bruno Haible  <bruno@clisp.org>
49000
49001         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
49002
49003 2005-03-04  Derek R. Price  <derek@ximbiot.com>
49004
49005         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
49006         (func_import): Only replace files via --import when they have actually
49007         changed.
49008
49009 2005-03-03  Derek R. Price  <derek@ximbiot.com>
49010
49011         * m4/mmap-anon.m4: New file.
49012         * m4/pagealign_alloc.m4: New file.
49013
49014 2005-03-03  Derek R. Price  <derek@ximbiot.com>
49015             Bruno Haible  <bruno@clisp.org>
49016
49017         * modules/pagealign_alloc: New file.
49018         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
49019
49020 2005-03-03  Derek R. Price  <derek@ximbiot.com>
49021             Bruno Haible  <bruno@clisp.org>
49022
49023         * lib/pagealign_alloc.h: New file.
49024         * lib/pagealign_alloc.c: New file.
49025
49026 2005-03-03  Bruno Haible  <bruno@clisp.org>
49027
49028         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
49029         Use an all-permissive copyright notice, recommended by RMS.
49030
49031 2005-03-02  Bruno Haible  <bruno@clisp.org>
49032
49033         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
49034         of AIX, the replacement has to be done only after <string.h> is
49035         included, therefore not in config.h. stpncpy.h does the replacement,
49036         and stpncpy.c uses it.
49037
49038 2005-03-02  Bruno Haible  <bruno@clisp.org>
49039
49040         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
49041         stpncpy.c uses it.
49042
49043 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
49044
49045         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
49046         The workaround isn't strictly needed for POSIX conformance, and
49047         it's too much of a pain to configure and maintain.  We'll ask
49048         people to fix their kernels instead.
49049         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
49050         (NANOSLEEP_BUG_WORKAROUND): Remove.
49051         (xnanosleep): Remove the workaround.
49052
49053 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
49054
49055         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
49056         Reported by Derek Price.
49057         (Include): Add "timespec.h".
49058
49059         * modules/xnanosleep (Depends-on): Remove gethrxtime.
49060
49061 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
49062
49063         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
49064         to detect nanosleep bug.
49065
49066 2005-03-01  Bruno Haible  <bruno@clisp.org>
49067
49068         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
49069
49070 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
49071
49072         * modules/gethrxtime: New file.
49073         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
49074         (Depends-on): Add gethrxtime.
49075         (configure.ac): Add gl_XNANOSLEEP.
49076         (Makefile.am): Remove lib_SOURCES line.
49077
49078 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
49079
49080         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
49081         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
49082
49083 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
49084
49085         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
49086         * lib/timespec.h (gettime): Return void, since it always
49087         succeeds now.  All uses changed.
49088         * lib/gettime.c (gettime) Likewise.
49089         [HAVE_NANOTIME]: Prefer nanotime.
49090         Assume gettimeofday succeeds, as POSIX requires.
49091         Assime time () succeeds, since other code already does.
49092         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
49093         (timespec_subtract): Remove.
49094         (NANOSLEEP_BUG_WORKAROUND): New constant.
49095         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
49096         things considerably.  Use it only on GNU/Linux hosts, since the
49097         workaround shouldn't be needed elsewhere.
49098
49099 2005-02-24  Bruno Haible  <bruno@clisp.org>
49100
49101         * modules/gettext (Files): Add m4/glibc2.m4.
49102
49103 2005-02-24  Bruno Haible  <bruno@clisp.org>
49104
49105         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
49106         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
49107         * m4/progtest.m4:
49108         Update from GNU gettext 0.14.2.
49109         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
49110
49111 2005-02-24  Bruno Haible  <bruno@clisp.org>
49112
49113         * lib/localcharset.c: Update from GNU gettext 0.14.2.
49114         * lib/config.charset: Update from GNU gettext 0.14.2.
49115
49116 2005-02-24  Bruno Haible  <bruno@clisp.org>
49117
49118         * lib/gettext.h: Update from GNU gettext 0.14.2.
49119
49120 2005-02-23  Simon Josefsson  <jas@extundo.com>
49121
49122         * m4/iconvme.m4: New file.
49123
49124 2005-02-23  Jim Meyering  <jim@meyering.net>
49125
49126         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
49127         change.
49128         Thanks to Bruno Haible for catching it.
49129
49130 2005-02-22  Simon Josefsson  <jas@extundo.com>
49131
49132         * modules/iconvme: New file.
49133
49134         * MODULES.html.sh: Add iconvme.
49135
49136 2005-02-22  Simon Josefsson  <jas@extundo.com>
49137
49138         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
49139
49140 2005-02-22  Simon Josefsson  <jas@extundo.com>
49141
49142         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
49143
49144 2005-02-22  Jim Meyering  <jim@meyering.net>
49145
49146         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
49147         s/ifndef/ifdef/.
49148
49149 2005-02-20  Neil Conway  <neilc@samurai.com>
49150
49151         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
49152         returned by OSX/Darwin if the specified buffer is not large
49153         enough for the hostname.
49154
49155 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
49156
49157         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
49158         pass it to _help, otherwise the latter coredumps trying to
49159         dereference state.root_argp.
49160
49161 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
49162
49163         * modules/chdir-long (Depends-on): Add memrchr.
49164         * modules/memrchr (Files): Add lib/memrchr.h.
49165         (Include): "memrchr.h".
49166
49167 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
49168
49169         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
49170
49171 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
49172
49173         * lib/memrchr.h: New file.
49174         * lib/chdir-long.c: Include it.
49175         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
49176         Don't bother including stddef.h.
49177
49178 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
49179
49180         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
49181         inclusion.
49182         Include <sys/types.h>, for dev_t.
49183         (ME_DUMMY, ME_REMOTE): Move from here....
49184         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
49185         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
49186         Dmitry V. Levin.
49187         Include mountlist.h first, to test the interface.
49188
49189 2005-01-29  Bruno Haible  <bruno@clisp.org>
49190
49191         * lib/progname.c (program_name): Initialize.
49192         Needed when linking statically on MacOS X.
49193
49194 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
49195
49196         Sync from coreutils.
49197         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
49198         (Depends-on): Add c-strtod.
49199         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
49200
49201 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
49202
49203         Sync from coreutils.
49204         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
49205
49206         Remove files that are specific to coreutils.
49207         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
49208
49209 2005-01-28  Bruno Haible  <bruno@clisp.org>
49210
49211         * modules/javacomp: New file.
49212         * MODULES.html.sh (Java): Add javacomp.
49213
49214 2005-01-28  Bruno Haible  <bruno@clisp.org>
49215
49216         * m4/javacomp.m4: New file, from GNU gettext.
49217
49218 2005-01-28  Bruno Haible  <bruno@clisp.org>
49219
49220         * lib/javacomp.sh.in: New file, from GNU gettext.
49221         * lib/javacomp.h: New file, from GNU gettext.
49222         * lib/javacomp.c: New file, from GNU gettext.
49223
49224 2005-01-26  Simon Josefsson  <jas@extundo.com>
49225
49226         * lib/gai_strerror.c: Use GPL in header.
49227
49228 2005-01-26  Bruno Haible  <bruno@clisp.org>
49229
49230         * modules/javaexec: New file.
49231         * MODULES.html.sh (Java): Add javaexec.
49232
49233 2005-01-26  Bruno Haible  <bruno@clisp.org>
49234
49235         * m4/javaexec.m4: New file, from GNU gettext.
49236
49237 2005-01-26  Bruno Haible  <bruno@clisp.org>
49238
49239         * lib/javaexec.sh.in: New file, from GNU gettext.
49240         * lib/javaexec.h: New file, from GNU gettext.
49241         * lib/javaexec.c: New file, from GNU gettext.
49242
49243 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
49244
49245         * modules/lchown (Depends-on): Remove lchown.h
49246
49247 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
49248
49249         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
49250         must be defined if the header file was not found, in order
49251         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
49252
49253 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
49254
49255         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
49256         initializers for struct pentry_state.
49257         (__argp_error): Check return value of __asprintf
49258         (__argp_failure): Translate error message
49259
49260         * lib/argp-parse.c: Removed braces around the expansion of N_()
49261
49262 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
49263
49264         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
49265         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
49266         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
49267         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
49268         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
49269         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
49270         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
49271         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
49272         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
49273         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
49274         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
49275         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
49276         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
49277         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
49278         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
49279         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
49280         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
49281         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
49282         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
49283         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
49284         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
49285         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
49286         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
49287         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
49288         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
49289         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
49290         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
49291         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
49292         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
49293         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
49294         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
49295         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
49296         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
49297         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
49298         xstrtol.m4, xstrtoumax.m4, yesno.m4:
49299         Use an all-permissive copyright notice, recommended by RMS.
49300
49301 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
49302
49303         * modules/chdir-long (Depends-on): Remove mempcpy.
49304
49305 2005-01-21  Jim Meyering  <jim@meyering.net>
49306
49307         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
49308         same value as for Solaris 9.
49309
49310         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
49311         component length.  This included changing the parameter to be
49312         of type `char *' rather than `char const *'.
49313         * lib/chdir-long.h (chdir_long): Update prototype.
49314
49315         * lib/openat.c (fdopendir, fstatat): New functions.
49316         * lib/openat.h: Include headers required for use of DIR and struct
49317         stat.
49318         [AT_SYMLINK_NOFOLLOW]: Define.
49319         (fdopendir, fstatat): Add prototypes.
49320
49321 2005-01-21  Bruno Haible  <bruno@clisp.org>
49322
49323         * modules/classpath: New file.
49324         * MODULES.html.sh (Java): Add classpath.
49325
49326 2005-01-21  Bruno Haible  <bruno@clisp.org>
49327
49328         * lib/classpath.h: New file, from GNU gettext.
49329         * lib/classpath.c: New file, from GNU gettext.
49330
49331 2005-01-20  Simon Josefsson  <jas@extundo.com>
49332
49333         * modules/version-etc-fsf: New file.
49334
49335 2005-01-20  Simon Josefsson  <jas@extundo.com>
49336
49337         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
49338         * lib/version-etc.c: Remove version_etc_copyright.
49339         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
49340         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
49341
49342 2005-01-20  Simon Josefsson  <jas@extundo.com>
49343
49344         * lib/base64.h (isbase64): Add.
49345
49346         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
49347         using a unsigned prototype, don't inline.
49348         (base64_decode): Use it.
49349
49350 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
49351
49352         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
49353         it.
49354
49355 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
49356
49357         * lib/save-cwd.c (save_cwd): Remove code to support the case
49358         where fchdir is missing or flaky.
49359
49360 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
49361
49362         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
49363
49364 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
49365
49366         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
49367         AC_LIBSOURCES now does this.
49368         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
49369         with new ullong_max module.
49370
49371 2005-01-19  Bruno Haible  <bruno@clisp.org>
49372
49373         * modules/sh-quote: New file.
49374         * MODULES.html.sh (Executing programs): Add sh-quote.
49375
49376 2005-01-19  Bruno Haible  <bruno@clisp.org>
49377
49378         * lib/sh-quote.h: New file, from GNU gettext.
49379         * lib/sh-quote.c: New file, from GNU gettext.
49380
49381 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
49382
49383         Merge from coreutils.
49384         * m4/ullong_max.m4: New file.
49385         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
49386         (gl_MACROS): Assume localeconv exists.
49387
49388 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
49389
49390         Merge changes from coreutils, as described below in several
49391         changelogs dated today.
49392
49393         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
49394         (O_DIRECTORY): Remove; not needed here, since "." must be
49395         a directory.  All uses removed.
49396         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
49397         universal on Suns, and we also need to test for IRIX.
49398         Revamp code to use 'if' rather than '#if'.
49399         Avoid unnecessary comparison of cwd->desc to 0.
49400
49401         * lib/utimens.c (futimens): Robustify the previous patch, by checking
49402         for known valid error numbers rather than observed invalid ones.
49403
49404 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
49405
49406         * modules/ullong_max: New file.
49407
49408         * modules/chdir-long, modules/openat: New files.
49409         * modules/save-cwd (Depends-on): Depend on chdir-long.
49410         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
49411
49412 2005-01-18  Jim Meyering  <jim@meyering.net>
49413
49414         Merge from coreutils.
49415         * m4/chdir-long.m4, m4/openat.m4: New files.
49416         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
49417         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
49418         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
49419         is sane and DOES follow symlinks.  Besides, testing 20 different
49420         systems found no broken chown implementations.
49421         Prompted by a change in rsync's copy of this macro.
49422         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
49423
49424         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
49425
49426         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
49427         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
49428         NULL-means-set-to-current-time semantics.
49429         Remove temporary file immediately, rather than waiting
49430         for configure's at-exit trap code to do it.
49431
49432 2005-01-18  Jim Meyering  <jim@meyering.net>
49433
49434         * lib/version-etc.c (version_etc_copyright): Update copyright date.
49435
49436         * lib/utimens.c (futimens): Account for the fact that futimes
49437         can also fail with errno == ENOSYS or errno == ENOENT.
49438         Patch from Dmitry V. Levin.
49439
49440         Change the name of the robust chdir function from chdir to chdir_long.
49441         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
49442         (restore_cwd): Use chdir_long, not chdir.
49443         * lib/chdir-long.c: Renamed from chdir.c.
49444         * lib/chdir-long.h: Renamed from chdir.h.
49445         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
49446         Hurd.
49447
49448 2005-01-18  Bruno Haible  <bruno@clisp.org>
49449
49450         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
49451         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
49452         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
49453         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
49454         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
49455         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
49456         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
49457         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
49458         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
49459         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
49460         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
49461         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
49462         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
49463         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
49464         Use an all-permissive copyright notice, recommended by RMS.
49465
49466 2005-01-18  Bob Proulx  <bob@proulx.com>
49467
49468         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
49469         simplify offsetof() macro construct to avoid compile failure with
49470         native HP-UX 11.0 ANSI C compiler.
49471
49472 2005-01-17  Bruno Haible  <bruno@clisp.org>
49473
49474         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
49475         redundant because stpncpy.m4 takes care of it.
49476
49477 2005-01-17  Bruno Haible  <bruno@clisp.org>
49478
49479         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
49480
49481 2005-01-17  Bruno Haible  <bruno@clisp.org>
49482
49483         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
49484         used.
49485
49486 2005-01-17  Bruno Haible  <bruno@clisp.org>
49487
49488         * lib/fwriteerror.h (fwriteerror): Change specification to include
49489         fclose.
49490         * lib/fwriteerror.c: Include <stdbool.h>.
49491         (fwriteerror): At the end, close the file stream. Record whether
49492         stdout was already closed.
49493
49494 2005-01-17  Bruno Haible  <bruno@clisp.org>
49495
49496         * lib/execute.c (environ): Declare if needed.
49497         * lib/pipe.c (environ): Likewise.
49498         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
49499
49500 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
49501
49502         * modules/argp: Depend on vsnprintf
49503
49504 2005-01-10  Jim Meyering  <jim@meyering.net>
49505
49506         * modules/closeout (Depends-on): Add atexit.
49507
49508 2005-01-06  Bruno Haible  <bruno@clisp.org>
49509
49510         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
49511
49512 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
49513
49514         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
49515         definitions to be after all include files, to avoid collisions.
49516         Problem reported by Bob Proulx.
49517
49518 2005-01-04  Jim Meyering  <jim@meyering.net>
49519
49520         Changes imported from coreutils.
49521         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
49522         as the mkstemp template, use a temporary directory and an
49523         8.3-friendly template to avoid trouble on systems like DJGPP.
49524         Reported by Juan M. Guerrero via Stepan Kasal.
49525         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
49526         close. Remove the temporary directory right away, rather than waiting
49527         for configure's at-exit trap code to do it.
49528         Suggestion from Stepan Kasal.
49529
49530 2005-01-01  Simon Josefsson  <jas@extundo.com>
49531
49532         * gnulib-tool: Print #include directives when --import'ing.
49533
49534 2004-12-28  Simon Josefsson  <jas@extundo.com>
49535
49536         * tests/test-base64.c: Include required header files.  Remove
49537         unused variables.
49538
49539 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
49540
49541         * modules/error (Depends-on): Remove gettext.
49542
49543 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
49544
49545         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
49546         not needed.  This removes a dependency on the gettext module.
49547         [defined _LIBC]: Do not include <libintl.h>; not needed.
49548
49549 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
49550
49551         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
49552         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
49553
49554 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
49555
49556         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
49557         HAVE_DECL_STRTOLD.
49558
49559 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
49560
49561         * modules/getdate (Depends-on): Remove alloca-opt.
49562
49563 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
49564
49565         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
49566
49567 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
49568
49569         * lib/argp-parse.c: Include <stddef.h>.
49570         (alignof, alignto): New macros.
49571         (parser_init): Don't assume that void * is aligned sufficiently
49572         for struct option.
49573
49574         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
49575         need to extend the stack.
49576         (YYINITDEPTH): New macro, so that the initial stack isn't overly
49577         large.
49578
49579 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
49580
49581         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
49582
49583 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
49584
49585         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
49586         (2004-10-24) change.  Apparently this was a false alarm.
49587
49588         * modules/getdate: Depend on alloca-opt, not alloca.
49589
49590 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
49591
49592         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
49593         Remove now-obsolete comment about AIX.
49594         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
49595         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
49596         (YYMAXDEPTH): New macro.
49597
49598 2004-12-18  Simon Josefsson  <jas@extundo.com>
49599
49600         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
49601
49602 2004-12-18  Bruno Haible  <bruno@clisp.org>
49603
49604         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
49605
49606 2004-12-18  Bruno Haible  <bruno@clisp.org>
49607
49608         * lib/fatal-signal.c (fatal_signals): Make non-const.
49609         (init_fatal_signals): New function.
49610         (uninstall_handlers, install_handlers): Ignore signals that were set to
49611         SIG_IGN.
49612         (at_fatal_signal): Call init_fatal_signals.
49613         (init_fatal_signal_set): Likewise. Ignore signals that were set to
49614         SIG_IGN.
49615         Reported by Paul Eggert.
49616
49617 2004-12-18  Bruno Haible  <bruno@clisp.org>
49618
49619         * doc/alloca.texi: New file.
49620         * doc/alloca-opt.texi: New file.
49621
49622 2004-12-17  Jim Meyering  <jim@meyering.net>
49623
49624         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
49625         Otherwise, install-sh could exit with improper exit status when
49626         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
49627
49628 2004-12-16  Simon Josefsson  <jas@extundo.com>
49629
49630         * tests/test-base64.c: Add license.
49631
49632 2004-12-15  Stepan Kasal  <address@hidden>
49633
49634         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
49635
49636 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
49637
49638         * modules/getcwd (Files): Add m4/d-ino.m4.
49639         Suggested by Mark D. Baushke.
49640
49641 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
49642
49643         * lib/getdate.y (textint): New member "negative".
49644         (time_zone_hhmm): New function.
49645         Expect 14 shift-reduce conflicts, not 13.
49646         (o_colon_minutes): New rule.
49647         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
49648         (yylex): Set the "negative" member of signed numbers.
49649
49650 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
49651
49652         * doc/getdate.texi (Time of day items, Time zone items):
49653         Describe new formats +00:00, UTC+00:00.
49654
49655 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
49656
49657         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
49658         spurious "-l"s.  Problem reported by Stepan Kasal.
49659
49660 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
49661
49662         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
49663         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
49664
49665 2004-12-04  Simon Josefsson  <jas@extundo.com>
49666
49667         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
49668         Vandoorselaere <yoann@prelude-ids.org>.
49669
49670 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
49671
49672         Changes imported from coreutils.
49673         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
49674         exist.
49675         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
49676
49677 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
49678
49679         Changes imported from coreutils.
49680         * lib/hard-locale.c: Assume <locale.h> exists.
49681         Include "strdup.h".
49682         (GLIBC_VERSION): New macro.
49683         (hard_locale): Assume setlocale exists.
49684         Rewrite to avoid #ifdef.
49685         Use strdup rather than malloc + strcpy.
49686         * lib/human.c: Assume <locale.h> exists.
49687         (human_readable): Assume localeconv exists.
49688
49689 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
49690
49691         * modules/hard-locale (Depends-on): Add strdup.
49692
49693 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
49694
49695         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
49696         convert T2, not T.  (Imported from libc.)
49697
49698 2004-11-30  Simon Josefsson  <jas@extundo.com>
49699
49700         * modules/restrict (License): Change to LGPL.
49701
49702 2004-11-30  Simon Josefsson  <jas@extundo.com>
49703
49704         * m4/restrict.m4: Add copyright and copying conditions.
49705
49706 2004-11-30  Simon Josefsson  <jas@extundo.com>
49707
49708         * m4/base64.m4: New file.
49709
49710 2004-11-30  Simon Josefsson  <jas@extundo.com>
49711
49712         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
49713         base64.
49714
49715         * tests/test-base64.c: New file.
49716
49717         * modules/base64: New file.
49718
49719 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
49720
49721         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
49722         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
49723
49724         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
49725
49726 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
49727
49728         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
49729         (__getcwd.c): Don't restore errno; glibc doesn't.
49730         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
49731         first, falling back to our code only if its results look suspicious.
49732         Ensure that the resulting buffer is only as large as necessary.
49733
49734         * lib/readutmp.c: Include readutmp.h first.
49735         Include <errno.h>, since readutmp.h no longer does that.
49736         * lib/readutmp.h: Don't include <errno.h>,
49737         <sys/param.h>, <time.h>; not needed to establish interface.
49738         (errno): Remove decl.
49739         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
49740         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
49741         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
49742
49743 2004-11-28  Simon Josefsson  <jas@extundo.com>
49744
49745         * lib/base64.h, base64.c: New file.
49746
49747 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
49748
49749         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
49750
49751 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
49752
49753         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
49754         (Depends-on): Remove pathmax, same.  Add mempcpy.
49755         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
49756         (Makefile.am): Append getcwd.h to lib_SOURCES.
49757         (Include): Add getcwd.h.
49758         (Maintainer): Change from Jim Meyering to "all, glibc",
49759         since getdate now uses intended-for-glibc code.
49760         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
49761         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
49762
49763 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
49764
49765         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
49766         HP's ANSI C compiler.
49767         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
49768         Declaring int functions causes warnings on some modern systems and
49769         shouldn't be needed to compile on ancient ones.
49770         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
49771         defined.
49772
49773         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
49774         with the following changes.
49775         (__set_errno): Parenthesize properly.
49776         Include <stdbool.h>.
49777         (MIN, MAX, MATCHING_INO): New macros.
49778         (__getcwd): Define with prototype, not K&R form.
49779         Use heuristics to allocate default buffer on stack if possible.
49780         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
49781         behavior, and to avoid the PATH_MAX limit when computing
49782         ../../../../...
49783         Use MATCHING_INO to compare inode number to file.
49784         Check for arithmetic overflow in size calculations.
49785         Fix bug in reallocation of dot array that caused getcwd to fail
49786         on directories nested deeper than 75.
49787         Be more careful about saving errno on error.
49788         Do not use realloc; use only free+malloc, as this is a bit
49789         more flexible and avoids a needless copy operation.
49790         Do not inspect st_dev and st_ino for symbolic links; POSIX
49791         doesn't specify the latter.
49792         Check for closedir errors.
49793         Avoid needless casts.
49794         Use "#ifdef weak_alias" around weak_alias, to be like other
49795         glibc code.
49796         The following changes to getcwd.c have effect only when used in
49797         gnulib; they have no effect inside glibc proper.
49798         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
49799         as alloca isn't used.
49800         (alloca, __alloca): Likewise.
49801         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
49802         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
49803         unconditionally, as gnulib assumes C89 or better.
49804         Do not include <sys/param.h>.
49805         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
49806         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
49807         better.
49808         (NULL) [!defined NULL]: Remove; we assume C89 or better.
49809         Include <dirent.h> in a way that is compatible with modern Autoconf.
49810         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
49811         New macros, if not already defined.
49812         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
49813         Use "_LIBC", not "defined _LIBC", for consistency.
49814         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
49815         a mempcpy module.
49816         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
49817         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
49818         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
49819         credit only to Jim Meyering and adjust the copyright dates.
49820         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
49821         <stdlib.h>, <unistd.h>, "pathmax.h".
49822         Instead, include "xgetcwd.h" (first) and "getcwd.h".
49823         (INITIAL_BUFFER_SIZE): Remove.
49824         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
49825
49826 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
49827
49828         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
49829         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
49830         Use the _ONCE methods, for efficiency.
49831         Check for fcntl.h.  In test program, include <errno.h>
49832         and <fcntl.h> if available.  Remove old K&R cruft from
49833         test program.  Check for common errors in GNU/Linux,
49834         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
49835         don't do AC_LIBOBJ, as that's getcwd.m4's job.
49836         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
49837         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
49838         name accordingly.
49839         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
49840         accommodate new getcwd.c.
49841         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
49842         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
49843         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
49844         that's all we need now.
49845
49846 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
49847
49848         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
49849         argp-parse.c depends on getopt internals, that means we should
49850         always use our getopt, to be on the safe side.
49851         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
49852         order not to spoil the result of an eventual previous invocation
49853         of gl_GETOPT_SUBSTITUTE.
49854
49855 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
49856
49857         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
49858         redefinition warnings. To avoid them, include the defines
49859         in `#if !defined __need_getopt ... #endif'. The only place
49860         where __getopt_argv_const is used is in definitions
49861         of getopt_long and getopt_long_only below, which are as well
49862         protected by `#ifndef __need_getopt'.
49863         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
49864         __need_getopt after including <stdio.h> and <unistd.h> These
49865         headers might have defined it.
49866
49867 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
49868
49869         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
49870
49871 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
49872
49873         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
49874         (futimens): New function, which uses futimes if available.
49875         (futimens, utimens): Support timespec==NULL, with same semantics
49876         as utime and utimens.
49877         * lib/utimens.h (futimens): New decl.
49878
49879 2004-11-23  Jim Meyering  <jim@meyering.net>
49880
49881         * lib/getopt_.h: Remove trailing blanks.
49882
49883 2004-11-23  Jim Meyering  <jim@meyering.net>
49884
49885         * lib/__fpending.c: Add comment.
49886
49887 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
49888
49889         * modules/canonicalize (Depends-on): Add xreadlink.
49890         Problem reported by James Youngman.
49891
49892 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
49893
49894         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
49895         New macros.
49896         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
49897         optopt): Use them instead of invoking ## directly; otherwise, the
49898         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
49899
49900 2004-11-19  Bruno Haible  <bruno@clisp.org>
49901
49902         * lib/strtok_r.c: Move comments from here...
49903         * lib/strtok_r.h: ... to here.
49904
49905 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
49906
49907         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
49908         implementations that mishandle size_t overflow.
49909
49910 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
49911
49912         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
49913         might fail.  Problem reported by Yoann Vandoorselaere.
49914         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
49915         implementations that mishandle size_t overflow.
49916
49917 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
49918
49919         * modules/canon-host (Depends-on): Add strdup.
49920
49921 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
49922
49923         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
49924
49925 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
49926
49927         * lib/canon-host.c: Include "strdup.h".
49928         (canon_host): Use getaddrinfo if available, so that IPv6 works.
49929         Use strdup instead of malloc/strcpy to duplicate strings.
49930
49931         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
49932         (human_space_before_unit): New constant.
49933         * lib/human.c (human_readable): Support it.
49934
49935         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
49936         (xgetcwd): Set errno correctly when failing.
49937         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
49938         the failure is actually due to a PATH_MAX problem.
49939
49940         Further getopt changes to make it more likely that glibc will
49941         buy the changes back.
49942         * lib/getopt.c (POSIXLY_CORRECT): New constant.
49943         (getopt): Use it, so to preserve glibc semantic
49944         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
49945         when compiling for libc.
49946         * lib/getopt_.h (__getopt_argv_const): Bring it back.
49947         (getopt_long, getopt_long_only): Use it.
49948
49949         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
49950         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
49951         (getopt): Argv is now char * const *, as per standard.
49952         (_getopt_internal_r, _getopt_internal): Argv is now char **,
49953         not char *__getopt_argv_const *.
49954         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
49955         _getopt_long_only_r): Likewise.
49956         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
49957         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
49958         _getopt_long_r, _getopt_long_only_r): Likewise.
49959         * lib/getopt_.h (__getopt_argv_const): Remove.
49960         (getopt): Argv is now char * const *, as per standard.
49961
49962         * lib/getdate.y (tORDINAL): New token.
49963         (day, relunit): Allow it for relative times.
49964         (relative_time_table): Use tORDINAL for ordinals.
49965
49966 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
49967
49968         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
49969         Document that "second" isn't allowed as an ordinal number.
49970
49971 2004-11-16  Jim Meyering  <jim@meyering.net>
49972
49973         * modules/closeout (Depends-on): Add fpending.
49974
49975 2004-11-15  Jim Meyering  <jim@meyering.net>
49976
49977         * lib/closeout.c: Include "__fpending.h" once again.
49978         Include <stdbool.h>.
49979         (close_stdout): Don't fail just because stdout was closed initially,
49980         since some programs don't write to stdout in the normal course of
49981         operation (other than --version and --help), and we don't want this
49982         function to make e.g. `touch file >&-' fail.
49983         But do fail if it was closed and someone has tried to write to it.
49984         E.g., `printf foo >&-' must fail.
49985
49986 2004-11-13  Jim Meyering  <jim@meyering.net>
49987
49988         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
49989
49990 2004-11-12  Simon Josefsson  <jas@extundo.com>
49991
49992         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
49993         small doc fix is still pending.
49994
49995 2004-11-11  Simon Josefsson  <jas@extundo.com>
49996
49997         * modules/strtok_r: New file.
49998
49999         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
50000         strtok_r.
50001
50002 2004-11-11  Simon Josefsson  <jas@extundo.com>
50003
50004         * m4/strtok_r.m4: New file.
50005
50006         * m4/getopt.m4: Replace opterr.
50007
50008 2004-11-11  Simon Josefsson  <jas@extundo.com>
50009
50010         * lib/strtok_r.h, strtok_r.c: New file.
50011
50012 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
50013
50014         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
50015         of replacing opterr, getopt, etc.  This should handle the
50016         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
50017
50018 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
50019
50020         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
50021         we can stop lying to compilers about the constness of argv when we
50022         are compiled outside glibc.
50023         (getopt, getopt_long, getopt_long_only): Use it.
50024         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
50025         _getopt_internal, getopt): Likewise.
50026         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
50027         _getopt_long_only_r): Likewise.
50028         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
50029         _getopt_long_r, _getopt_long_only_r): Likewise.
50030
50031         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
50032         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
50033         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
50034         the other external symbols.
50035         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
50036         declaration, since the above renaming now works around collisions.
50037
50038 2004-11-11  Jim Meyering  <jim@meyering.net>
50039
50040         * lib/linebreak.c: Remove trailing blanks.
50041         * lib/alloca_.h: Likewise.
50042         * lib/acosl.c: Likewise.
50043         * lib/euidaccess.c: Likewise.
50044         * lib/allocsa.h: Likewise.
50045
50046 2004-11-10  Simon Josefsson  <jas@extundo.com>
50047
50048         * m4/getaddrinfo.m4: New file.
50049
50050 2004-11-10  Simon Josefsson  <jas@extundo.com>
50051
50052         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
50053
50054 2004-11-10  Simon Josefsson  <jas@extundo.com>
50055
50056         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
50057         getaddrinfo.
50058
50059         * modules/getaddrinfo: New file.
50060
50061 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
50062
50063         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
50064
50065 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
50066
50067         * lib/mktime.c (SHR): New macro, which is a portable
50068         substitute for >> that should work even on Crays.
50069         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
50070         Problem reported by Mark D. Baushke in
50071         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
50072         * lib/getdate.y (SHR): Likewise.
50073         (tm_diff): Use it.
50074         * lib/strftime.c (SHR): Likewise.
50075         (tm_diff): Use it.
50076         * lib/quotearg.c (struct quoting_options): Use unsigned int for
50077         quote_these_too, so that right shifts are well defined.  All uses
50078         changed.
50079
50080 2004-11-10  Jim Meyering  <jim@meyering.net>
50081
50082         Ensure that no close failure goes unreported.
50083         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
50084         return early when it seems there's nothing to flush.
50085         Don't include __fpending.h.
50086
50087 2004-11-10  Jim Meyering  <jim@meyering.net>
50088
50089         * modules/closeout (Depends-on): Remove fpending.
50090
50091 2004-11-10  Jim Meyering  <jim@meyering.net>
50092
50093         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
50094
50095 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
50096
50097         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
50098         gl_FUNC_STRFTIME.
50099         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
50100         and AC_REQUIRE when possible, to avoid duplicate checks.
50101         Check for <wchar.h>.
50102
50103 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
50104
50105         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
50106
50107 2004-11-09  Bruno Haible  <bruno@clisp.org>
50108
50109         * m4/sockpfaf.m4: New file.
50110
50111 2004-11-05  Bruno Haible  <bruno@clisp.org>
50112
50113         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
50114         Reported by Mark D. Baushke <mdb@cvshome.org>.
50115
50116 2004-11-04  Bruno Haible  <bruno@clisp.org>
50117
50118         2004-09-11  Bruno Haible  <bruno@clisp.org>
50119                 * allocsa.valgrind: New file.
50120         2004-02-06  Bruno Haible  <bruno@clisp.org>
50121                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
50122                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
50123                 Reported by Christopher Seip <chris.seip@hp.com>.
50124
50125 2004-11-04  Bruno Haible  <bruno@clisp.org>
50126
50127         * modules/allocsa (Files): Add lib/allocsa.valgrind.
50128         (Makefile.am): Distribute it.
50129
50130 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
50131
50132         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
50133         with errno == ERANGE if the buffer is too small.
50134         Problem reported by Mark D. Baushke.
50135
50136 2004-11-03  Albert Chin  <china@thewrittenword.com>
50137             Paul Eggert  <eggert@cs.ucla.edu>
50138
50139         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
50140         equivalent, substitute $ac_type for equivalent type rather than
50141         blindly using uint32_t *always* which won't work if uint32_t is not
50142         available.  Define _UINT32_T to work around typedef of uint32_t if
50143         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
50144         2.5.1.
50145
50146 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
50147
50148         * m4/jm-macros.m4: Sync from coreutils.
50149         (gl_MACROS): Check for mbrlen, for pathchk.
50150         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
50151
50152 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
50153
50154         * lib/xreadlink.c (MAXSIZE): New macro.
50155         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
50156         size does not exceed MAXSIZE.  Avoid cast.
50157         As suggested by Mark D. Baushke in
50158         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
50159         if readlink fails with buffer size just under MAXSIZE, try again
50160         with MAXSIZE.
50161
50162 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
50163
50164         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
50165
50166 2004-11-02  Derek R. Price  <derek@ximbiot.com>
50167         and  Paul Eggert  <eggert@cs.ucla.edu>
50168
50169         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
50170         (get_date): Overparenthesize to avoid GCC warning.
50171
50172 2004-11-02  Bruno Haible  <bruno@clisp.org>
50173
50174         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
50175         returns void.
50176
50177 2004-11-02  Bruno Haible  <bruno@clisp.org>
50178
50179         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
50180         function returns void.
50181
50182 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
50183
50184         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
50185         fflush_unlocked, flockfile, funlockfile, funlockfile,
50186         fputs_unlocked, putc_unlocked.
50187
50188 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
50189
50190         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
50191         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
50192         already declared.
50193
50194 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
50195
50196         * modules/getdate (Files): Add doc/getdate.texi.
50197         (Depends-on): Add setenv, xalloc.
50198
50199 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
50200
50201         * lib/getdate.y: Add support for TZ="foo" within a date string.
50202         Fix some bugs near time_t boundaries.  Reject dates with
50203         out-of-range components, e.g., "Sept 31".
50204         Include <stdlib.h>, "setenv.h", "xalloc.h".
50205         (ISDIGIT_LOCALE): Remove; unused.
50206         Note that the TZ and time functions used here are not reentrant.
50207         (mktime_ok, get_tz): New functions.
50208         (TZBUFSIZE): New constant.
50209         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
50210         This requires that we sometimes generate our own TZ="XXX..." setting.
50211
50212 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
50213
50214         * doc/getdate.texi: New file, from coreutils with modifications for
50215         the new TZ parsing.
50216
50217 2004-10-27  Derek R. Price  <derek@ximbiot.com>
50218
50219         * lib/mktime.c (not_equal_tm): Remove redundant check.
50220
50221 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
50222
50223         * modules/regex (lib_SOURCES): Add regex.c.
50224         Reported by James Youngman in
50225         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
50226
50227 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
50228
50229         * lib/getdate.y: Use Bison 1.875 features, and some minor
50230         code cleanups.  This change does not affect semantics.
50231         Don't include <stdlib.h>; no longer needed.
50232         Don't include unlocked-io.h; only the "#if TEST" code uses
50233         stdio, and performance isn't crucial there.
50234         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
50235         Bison 1.875 features as described below.
50236         All uses of "PC." replaced by "pc->".
50237         (YYSTYPE): Add a forward declaration.
50238         (yylex, yyerror): Use full prototypes in forward decls.
50239         Use "%pure-parser" rather than obsolescent "%pure_parser".
50240         Use %parse-param and %lex-param instead of obsolescent
50241         YYPARSE_PARAM and YYLEX_PARAM.
50242         (meridian_table, month_and_day_table, time_units_table,
50243         relative_time_table, time_zone_table, military_table,
50244         lookup_zone, lookup_word, get_date):
50245         Use NULL instead of 0 where appropriate.
50246         (to_hour): Avoid abort (), to avoid a dependency on
50247         stdlib.h.
50248         (yyerror, yylex): Now accepts parser_control * arg.
50249         (main) [TEST]: Use '\0' rather than 0 for char.
50250
50251 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
50252
50253         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
50254
50255 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
50256
50257         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
50258         It's now the caller's responsibility to handle the case where
50259         !HAVE_GETPAGESIZE && !defined getpagesize.
50260
50261         * lib/mktime.c (leapyear): Arg is long int, not int.
50262
50263 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
50264
50265         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
50266
50267 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
50268
50269         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
50270         missing.  Problem reported by James Youngman.
50271
50272 2004-10-16  Simon Josefsson  <jas@extundo.com>
50273
50274         * gnulib-tool: Fix comments.  Fix parse problem.
50275         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
50276
50277 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
50278
50279         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
50280         implementation of getopt_long.  Problem reported by Alexander Taler in:
50281         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
50282
50283 2004-10-15  Bruno Haible  <bruno@clisp.org>
50284
50285         * gnulib-tool: Untabify. Initialize supplied_libname.
50286         (func_usage): More homogenous output.
50287         (func_modules_transitive_closure, func_modules_to_filelist,
50288         func_emit_lib_Makefile_am): New functions.
50289         (func_import): New function, extracted from big case statement. Use
50290         func_get_license, func_modules_transitive_closure,
50291         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
50292         opt_lgpl. Don't use test -a, as it's not portable.
50293         (func_create_testdir): Use func_modules_transitive_closure,
50294         func_modules_to_filelist, func_emit_lib_Makefile_am.
50295
50296 2004-10-15  Bruno Haible  <bruno@clisp.org>
50297
50298         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
50299
50300 2004-10-15  Bruno Haible  <bruno@clisp.org>
50301
50302         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
50303         the portions belonging to each module.
50304         Suggested by Derek Robert Price <derek@ximbiot.com>.
50305
50306 2004-10-12  Simon Josefsson  <jas@extundo.com>
50307
50308         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
50309         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
50310         to real functions.
50311
50312 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
50313
50314         * modules/vsnprintf: New file.
50315
50316 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
50317
50318         * m4/vsnprintf.m4: New file.
50319
50320 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
50321
50322         * lib/vsnprintf.h: New file.
50323         * lib/vsnprintf.c: New file.
50324
50325 2004-10-11  Bruno Haible  <bruno@clisp.org>
50326
50327         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
50328         vsnprintf.
50329
50330 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
50331
50332         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
50333
50334 2004-10-07  Bruno Haible  <bruno@clisp.org>
50335
50336         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
50337         fits into the provided buffer.
50338
50339 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
50340
50341         * lib/diacrit.c, diacrit.h: Add GPL notice.
50342
50343         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
50344         notice.
50345         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
50346         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
50347         This avoids a potential constant-folding bug.
50348
50349 2004-10-05  Bruno Haible  <bruno@clisp.org>
50350
50351         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
50352         for the declaration of strsep.
50353
50354 2004-10-05  Bruno Haible  <bruno@clisp.org>
50355
50356         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
50357
50358 2004-10-04  Simon Josefsson  <jas@extundo.com>
50359
50360         * modules/memmem: New file.
50361         * tests/test-memmem.c: New file.
50362         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
50363
50364 2004-10-04  Simon Josefsson  <jas@extundo.com>
50365
50366         * m4/memmem.m4: New file.
50367
50368 2004-10-04  Simon Josefsson  <jas@extundo.com>
50369
50370         * lib/memmem.h: New file.
50371         * lib/memmem.c: New file, taken from glibc.
50372
50373 2004-10-04  Simon Josefsson  <jas@extundo.com>
50374
50375         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
50376         '#ifdef USE_UNLOCKED_IO'.
50377
50378 2004-10-04  Simon Josefsson  <jas@extundo.com>
50379
50380         * config/srclist.txt: Add memmem from glibc.
50381
50382 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
50383
50384         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
50385
50386         * modules/argmatch, modules/argp, modules/closeout, modules/error,
50387         modules/exclude, modules/getdate, modules/getline,
50388         modules/getndelim2, modules/getpass, modules/getpass-gnu,
50389         modules/getusershell, modules/linebuffer, modules/md5,
50390         modules/mountlist, modules/posixtm, modules/readtokens,
50391         modules/readutmp, modules/regex, modules/sha1,
50392         modules/version-etc, modules/yesno:
50393         Remove dependency on unlocked-io.
50394
50395 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
50396
50397         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
50398
50399         * m4/unlocked-io.m4: Add copyright notice.
50400         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
50401
50402 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
50403
50404         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
50405         * lib/xmalloc.c (xmemdup): Likewise.
50406         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
50407         XFREE): Remove these long-obsolescent macros.
50408         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
50409         * lib/xstrdup.c: Remove.
50410
50411         * lib/regex.c (re_comp): Cast gettext return value to char *,
50412         Problem reported by Martin Neitzel via Mark D. Baushke.
50413
50414 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
50415
50416         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
50417         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
50418         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
50419         regex.c, sha1.c, version-etc.c, yesno.c:
50420         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
50421         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
50422         the includer's responsibility.
50423
50424         Sync from coreutils.
50425
50426         * lib/modechange.c (mode_compile): Don't decrement a pointer that
50427         points to the start of a string, as the C Standard says the
50428         resulting behavior is undefined.
50429
50430         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
50431         simple -> simple_backups, numbered_existing ->
50432         numbered_existing_backups, numbered -> numbered_backups
50433         to avoid shadowing problems.  All uses changed.
50434         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
50435         * lib/backupfile.c (check_extension, numbered_backup):
50436         Rename locals to avoid shadowing 'basename'.
50437         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
50438         once.
50439
50440         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
50441         * lib/.cvsignore: Add getopt.h.
50442
50443 2004-10-04  Bruno Haible  <bruno@clisp.org>
50444
50445         * modules/README: New file.
50446         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
50447         not a module.
50448
50449 2004-10-02  Jim Meyering  <jim@meyering.net>
50450
50451         * lib/dirfd.h, getpagesize.h: Add copyright notice.
50452
50453 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
50454
50455         * modules/strsep: New file.
50456
50457 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
50458
50459         * m4/strsep.m4: New file.
50460
50461 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
50462
50463         * lib/strsep.h: New file.
50464         * lib/strsep.c: New file.
50465
50466 2004-10-01  Simon Josefsson  <jas@extundo.com>
50467
50468         * lib/snprintf.c (snprintf): Handle size==0.
50469
50470 2004-10-01  Simon Josefsson  <jas@extundo.com>
50471             Bruno Haible  <bruno@clisp.org>
50472
50473         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
50474         (snprintf): Declare 'args'.
50475
50476 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
50477
50478         * lib/snprintf.c: Remove comments as to why each header is needed.
50479
50480 2004-10-01  Bruno Haible  <bruno@clisp.org>
50481
50482         * MODULES.html.sh: Add strsep.
50483
50484 2004-09-30  Simon Josefsson  <jas@extundo.com>
50485
50486         * modules/snprintf: New file.
50487
50488 2004-09-30  Simon Josefsson  <jas@extundo.com>
50489
50490         * m4/snprintf.m4: New file.
50491
50492 2004-09-30  Simon Josefsson  <jas@extundo.com>
50493
50494         * lib/snprintf.h, lib/snprintf.c: New files.
50495
50496 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
50497
50498         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
50499         (hol_entry_help): Never translate an empty string.
50500         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
50501         * lib/argp.h (OPTION_NO_TRANS): New option.
50502
50503 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
50504
50505         * modules/argp (Maintainer): Replace Simon Josefsson
50506         by Sergey Poznyakoff.
50507
50508 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
50509
50510         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
50511         changes merged back into glibc.
50512
50513 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
50514
50515         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
50516
50517 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
50518
50519         * lib/xvasprintf.c: Include xalloc.h.
50520         (xvasprintf): Use xalloc_die, not xmalloc_die.
50521
50522 2004-09-29  Bruno Haible  <bruno@clisp.org>
50523
50524         * modules/alloca-opt: New file, derived from modules/alloca.
50525         * modules/allocsa: Depend on alloca-opt instead of alloca.
50526         * modules/setenv: Likewise.
50527         * modules/vasnprintf: Likewise.
50528         * MODULES.html.sh: Add alloca-opt.
50529
50530 2004-09-28  Simon Josefsson  <jas@extundo.com>
50531
50532         * gnulib-tool: New parameter --lgpl, to asseert that modules are
50533         LGPL, and to replace license template from GPL to LGPL.
50534
50535 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
50536
50537         * modules/dummy: Change license to LGPL.
50538
50539 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
50540
50541         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
50542
50543 2004-09-24  Simon Josefsson  <jas@extundo.com>
50544
50545         * modules/minmax (License): Change from GPL to LGPL.
50546
50547 2004-09-23  Simon Josefsson  <jas@extundo.com>
50548
50549         * gnulib-tool (--import): Typo.
50550
50551 2004-09-23  Simon Josefsson  <jas@extundo.com>
50552
50553         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
50554
50555 2004-09-22  Bruno Haible  <bruno@clisp.org>
50556
50557         * modules/*: Add 'License' field.
50558         * gnulib-tool: Accept --extract-license option.
50559         (func_get_license): New function.
50560
50561 2004-09-21  Bruno Haible  <bruno@clisp.org>
50562
50563         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
50564         Reported by Simon Josefsson.
50565
50566 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
50567
50568         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
50569         gl_AC_TYPE_LONG_LONG.
50570
50571 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
50572
50573         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
50574
50575 2004-09-18  Simon Josefsson  <jas@extundo.com>
50576         and  Paul Eggert  <eggert@cs.ucla.edu>
50577
50578         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
50579         calls with autoreconf.  Define GL_LIB.
50580
50581 2004-09-14  Karl Berry  <karl@gnu.org>
50582
50583         * config/srclist.txt: unsync setenv.c, sigh.
50584
50585 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
50586
50587         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
50588         Problem reported by Bruno Haible in:
50589         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
50590
50591 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
50592
50593         * config/srclist.txt: Comment out argp-pvh.c.
50594
50595 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
50596
50597         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
50598         in case some system header has #define'd it.  Problem reported by
50599         Soeren D. Schulze in
50600         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
50601
50602 2004-09-09  Karl Berry  <karl@gnu.org>
50603
50604         * regex.[ch]: delete from the root.  These were supposed to be
50605                 synced with emacs cvs, but this has not happened for about
50606                 a year, and anyway nothing else uses emacs regex.[ch].
50607                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
50608                 lib/regex[.ch] is untouched.
50609
50610 2004-09-09  Bruno Haible  <bruno@clisp.org>
50611
50612         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
50613
50614 2004-09-09  Bruno Haible  <bruno@clisp.org>
50615
50616         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
50617         modifications.
50618         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
50619
50620 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
50621
50622         * modules/xvasprintf: New file.
50623         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
50624
50625 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
50626
50627         * lib/xvasprintf.h: New file.
50628         * lib/xvasprintf.c: New file.
50629         * lib/xasprintf.c: New file.
50630
50631 2004-09-08  Bruno Haible  <bruno@clisp.org>
50632
50633         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
50634
50635 2004-09-08  Bruno Haible  <bruno@clisp.org>
50636
50637         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
50638         length is > INT_MAX.
50639         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
50640         more.
50641
50642 2004-09-08  Bruno Haible  <bruno@clisp.org>
50643
50644         * lib/stdint_.h: New file, taken from GNU clisp.
50645
50646 2004-09-08  Bruno Haible  <bruno@clisp.org>
50647             Oskar Liljeblad  <oskar@osk.mine.nu>
50648
50649         * modules/stdint: New file.
50650         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
50651
50652 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
50653
50654         Import from coreutils.
50655         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
50656         strings on unbounded length.  alloca's performance benefits aren't
50657         that important here.
50658         (V_STRDUP): Remove.
50659         (parse_with_separator): New function, with most of the internals
50660         of the old parse_user_spec.  Allow user to omit both user and group,
50661         for compatibility with FreeBSD.
50662         Clone only the user name, not the entire spec.
50663         Do not set *uid, *gid unless entirely successful.
50664         Avoid memory leak in some failing cases.
50665         Fix regression for USER.GROUP reported by Dmitry V. Levin in
50666         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
50667         (parse_user_spec): Rewrite to use parse_with_separator.
50668
50669 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
50670
50671         * modules/userspec: Don't depend on alloca.
50672
50673 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
50674
50675         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
50676
50677 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
50678
50679         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
50680         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
50681         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
50682
50683 2004-08-16  Simon Josefsson  <jas@extundo.com>
50684
50685         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
50686         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
50687         Add --dry-run for --import.
50688         Let user provided command line parameters override configure.ac
50689         settings.
50690
50691 2004-08-12  Simon Josefsson  <jas@extundo.com>
50692
50693         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
50694         as discussed with Paul Eggert in threads rooted at
50695         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
50696         and
50697         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
50698         Before, the test was empty, and relied on ELIDE_CODE in source
50699         code.)
50700         (gl_PREREQ_GETOPT): New macro.
50701         (gl_GETOPT): Use them.
50702
50703 2004-08-12  Simon Josefsson  <jas@extundo.com>
50704
50705         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
50706         * lib/getopt_.h: Renamed from getopt.h.
50707
50708 2004-08-12  Simon Josefsson  <jas@extundo.com>
50709
50710         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
50711         Change default library name from libfoo to libgnu.
50712         Now, if you have a configure.ac that says:
50713                 gl_SOURCE_BASE(gl)
50714                 gl_M4_BASE(gl/m4)
50715                 gl_MODULES(error getopt etcetera)
50716                 gl_INIT
50717         you can import all you need by running:
50718                 ../gnulib/gnulib-tool --import
50719
50720         * modules/getopt (Files): Rename getopt.h to getopt_.h.
50721         (Makefile.am): Rewrite, use logic from argz.
50722         (Include): Use <getopt.h> instead of "getopt.h".
50723
50724 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
50725
50726         * modules/argp (Files): Add m4/unlocked-io.m4.
50727         (Depends-on): Add extensions.
50728
50729 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
50730
50731         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
50732         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
50733         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
50734         Check for program_invocation_name, program_invocation_short_name,
50735         flockfile, funlockfile, features.h, _getopt_long_only_r.
50736
50737 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
50738
50739         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
50740         its complicated substitute.
50741         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
50742         and program_invocation_name.
50743         (__argp_basename) [!_LIBC]: Remove; the only use was
50744         replaced by its body.
50745         (__argp_short_program_name): Change condition from
50746         !defined __argp_short_program_name to
50747         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
50748         to match argp-namefrob.h.
50749         (__argp_failure): Don't assume strerror_r returns char *.
50750         * lib/argp-parse.c (N_): Define unconditionally.
50751         (argp_default_options): Fill out initializers with 0 to avoid
50752         gcc warnings.
50753
50754 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
50755
50756         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
50757         getopt1.c.
50758
50759 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
50760
50761         Merge from coreutils.
50762
50763         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
50764
50765         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
50766         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
50767
50768 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
50769
50770         Merge from coreutils.
50771
50772         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
50773         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
50774         for Reliant Unix 5.43.
50775
50776         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
50777         (union fooround): Use uintmax_t, not long int.
50778         The rest is a merge from libc:
50779         [defined _LIBC]: Include <shlib-compat.h>.
50780         (_obstack) [defined _LIBC]: Remove after 2.3.4.
50781
50782         * lib/settime.c (settime): Recode to avoid warning with
50783         Sun Forte C 6U2.
50784
50785         * lib/strverscmp.c: Convert to UTF-8.
50786
50787 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
50788
50789         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
50790         m4/uintmax_t.m4.
50791
50792 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
50793
50794         * modules/xalloc-die: New file.
50795         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
50796
50797         * modules/md5 (Files): Add m4/uint32_t.m4.
50798         * modules/sha1: Renamed from modules/sha.
50799         (Files):
50800         Rename lib/sha.h to lib/sha1.h.
50801         Rename lib/sha.c to lib/sha1.c.
50802         Rename m4/sha.m4 to m4/sha1.m4.
50803         (lib_SOURCES): Likewise.
50804         (configure.ac): Rename gl_SHA to gl_SHA1.
50805         (Include): sha.h -> sha1.h.
50806
50807 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
50808
50809         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
50810         * m4/sha1.m4: Renamed from sha.m4.
50811         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
50812
50813 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
50814
50815         * lib/obstack.h (obstack_empty_p):
50816         Don't assume that chunk->contents is suitably aligned.
50817         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
50818         Likewise. Problem reported by Benno in
50819         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
50820
50821         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
50822         readable.  This could be improved further but it'd take some work.
50823
50824 2004-08-08  Simon Josefsson  <jas@extundo.com>
50825
50826         * modules/xgethostname (Depends-on): Remove exit and error (not
50827         used).
50828
50829         * modules/getpass-gnu: Add getpass.h.
50830         (Depends-on): Add stdbool.
50831         * modules/getpass: Add getpass.h.
50832
50833 2004-08-08  Simon Josefsson  <jas@extundo.com>
50834
50835         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
50836         Check getpass declaration.
50837
50838 2004-08-08  Simon Josefsson  <jas@extundo.com>
50839
50840         * lib/xgethostname.c: Don't include error.h (not used).
50841
50842         * lib/getpass.h: Add.
50843         * lib/getpass.c: Include getpass.h first.
50844
50845 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
50846
50847         * lib/xalloc-die.c: New file.
50848         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
50849         All uses removed.
50850         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
50851         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
50852         xalloc-die.c.
50853         (_, N_, xalloc_die): Move to xalloc-die.c.
50854         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
50855         so that we needn't mess with xalloc_msg_memory_exhausted.
50856
50857         * lib/sha1.h: Renamed from sha.h.
50858         (SHA1_H): Renamed from _SHA_H.
50859         (sha1_ctx): Renamed from sha_ctx.
50860         (sha1_init_ctx): Renamed from sha_init_ctx.
50861         (sha1_process_block): Renamed from sha_process_block.
50862         (sha1_process_bytes): Renamed from sha_process_bytes.
50863         (sha1_finish_ctx): Renamed from sha_finish_ctx.
50864         (sha1_read_ctx): Renamed from sha_read_ctx.
50865         (sha1_stream): Renamed from sha_stream.
50866         (sha1_buffer): Renamed from sha_buffer.
50867         * lib/sha1.c: Likewise; renamed from sha.c.
50868         Do not include <sys/types.h>.
50869         Include <stddef.h> rather than <stdlib.h>.
50870
50871 2004-08-08  Bruno Haible  <bruno@clisp.org>
50872
50873         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
50874         FILESYSTEM_PREFIX_LEN.
50875         * lib/progreloc.c: Likewise.
50876         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
50877
50878 2004-08-06  Simon Josefsson  <jas@extundo.com>
50879
50880         * modules/progname (Depends-on): Don't depend on stdbool.
50881
50882 2004-08-06  Simon Josefsson  <jas@extundo.com>
50883
50884         * modules/getsubopt: New file.
50885         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
50886         getsubopt.
50887
50888 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
50889
50890         More merge from coreutils.
50891
50892         * m4/utimens.m4, m4/utimecmp.m4: New files.
50893         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
50894         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
50895         prereq.m4, sha.m4: Import changes from coreutils.
50896
50897 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
50898
50899         More merge from coreutils.
50900         * modules/raise, modules/readtokens0, modules/utimens:
50901         * modules/utimecmp, module/xnanosleep: New files.
50902         * modules/strftime: Add lib/strftime.h.
50903         Change include from <time.h> to "strftime.h".
50904         * modules/yesno: Add lib/yesno.h.
50905         * modules/backupfile: Remove lib/addext.c.
50906         * modules/euidaccess: Add stat-macros.h.
50907         * modules/canonicalize, modules/euidaccess,
50908         modules/filemode, modules/lchown, modules/makepath,
50909         modules/rmdir, modules/stat: Likewise.
50910
50911 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
50912
50913         Merge from tar.
50914         * lib/argp-help.c (make_hol, hol_append): Don't assume that
50915         SIZE_MAX is a valid preprocessor constant.
50916         (__argp_basename): Change from "#ifndef _LIBC"
50917         to "#ifndef __argp_short_program_name", so that
50918         we don't compile these functions for tar.
50919
50920         More merges from coreutils.
50921         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
50922         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
50923         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
50924         * lib/addext.c: Remove; no longer needed.
50925         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
50926         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
50927         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
50928         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
50929         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
50930         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
50931         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
50932         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
50933         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
50934         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
50935         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
50936         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
50937         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
50938         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
50939         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
50940         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
50941         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
50942         Import changes from coreutils.
50943
50944 2004-08-05  Simon Josefsson  <jas@extundo.com>
50945
50946         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
50947
50948 2004-08-05  Simon Josefsson  <jas@extundo.com>
50949
50950         * m4/getsubopt.m4: New file.
50951
50952 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
50953
50954         Merge from coreutils.
50955
50956         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
50957         * m4/getcwd-path-max.m4: New files.
50958
50959         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
50960         FILESYSTEM_PREFIX_LEN ->
50961         FILE_SYSTEM_PREFIX_LEN.
50962         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
50963         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
50964         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
50965         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
50966
50967         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
50968         prerequisite modules now handle the DOS stuff.
50969         Don't check for unistd.h.
50970
50971 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
50972
50973         Merge from coreutils.
50974
50975         * lib/.gdb-history: Remove; this doesn't belong here.
50976
50977         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
50978         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
50979         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
50980         * lib/getcwd.c: New files.
50981
50982         * lib/dirname.h: Include <stdbool.h>.
50983         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
50984         for consistency with POSIX terminology.  All uses changed.
50985         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
50986         (strip_trailing_slashes): Use bool for booleans.
50987         * lib/stripslash.c (strip_trailing_slashes): Likewise.
50988
50989         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
50990         sometimes returns a positive errno value even when it succeeds.
50991         (print_errno_message) [!LIBC]: Fall back on strerror if
50992         __strerror_r fails.
50993
50994         * lib/path-concat.c (mempcpy): Don't define if a system header defines
50995         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
50996         (longest_relative_suffix): New function.
50997         (path_concat): Use it.  Assume first argument is not NULL.
50998         Port to DOS.  Omit redundant separators.
50999         Report an error instead of returning NULL.
51000         Use mempcpy instead of memcpy.
51001         (xpath_concat): Remove: not declared or used.
51002
51003         * lib/same.h: Include <stdbool.h>
51004         (same_name): Return bool, not int.
51005         * lib/same.c (same_name): Likewise.
51006         (errno): Don't declare; we assume C89 or better now.
51007
51008         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
51009         if not already defined.
51010
51011         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
51012         * lib/dup-safer.c (errno): Likewise.
51013
51014 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
51015
51016         Merge from coreutils.
51017         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
51018         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
51019         * modules/path-concat: Don't depend on strdup.
51020
51021 2004-08-03  Simon Josefsson  <jas@extundo.com>
51022
51023         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
51024         * lib/progname.h: Don't include stdbool.h.
51025
51026 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
51027
51028         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
51029         * MODULES.html.sh (func_all_modules): Remove fatal.
51030
51031 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
51032
51033         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
51034
51035 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
51036
51037         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
51038         working.
51039
51040 2004-08-02  Simon Josefsson  <jas@extundo.com>
51041
51042         * lib/getsubopt.h: New file, with comments from Bruno Haible.
51043         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
51044         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
51045
51046 2004-08-01  Simon Josefsson  <jas@extundo.com>
51047
51048         * lib/xgetdomainname.c: Include stdlib.h, for free().
51049
51050 2004-07-19  Bruno Haible  <bruno@clisp.org>
51051
51052         * MODULES.html.sh (func_all_modules): Add dummy.
51053
51054 2004-07-16  Simon Josefsson  <jas@extundo.com>
51055
51056         * modules/dummy: New file.
51057
51058 2004-07-16  Simon Josefsson  <jas@extundo.com>
51059
51060         * lib/dummy.c: New file.
51061
51062 2004-07-16  Bruno Haible  <bruno@clisp.org>
51063
51064         * lib/backupfile.h: Add extern "C" for C++.
51065         * lib/closeout.h: Likewise.
51066         * lib/copy-file.h: Likewise.
51067         * lib/findprog.h: Likewise.
51068         * lib/full-write.h: Likewise.
51069         * lib/pathname.h: Likewise.
51070         * lib/progname.h: Likewise.
51071         * lib/stpcpy.h: Likewise.
51072         * lib/stpncpy.h: Likewise.
51073         * lib/strcase.h: Likewise.
51074         * lib/strstr.h: Likewise.
51075         * lib/xalloc.h: Likewise.
51076
51077         * lib/mbswidth.h: Add extern "C" for C++.
51078         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
51079
51080 2004-07-13  Robert Millan  <robertmh@gnu.org>
51081
51082         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
51083
51084 2004-07-09  Simon Josefsson  <jas@extundo.com>
51085
51086         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
51087         failed without this.)
51088
51089 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
51090
51091         * modules/chown (Files): Add lib/fchown-stub.c, since
51092         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
51093
51094 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
51095
51096         * lib/fchown-stub.c: New file.
51097
51098 2004-06-24  Jim Meyering  <jim@meyering.net>
51099
51100         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
51101
51102 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
51103
51104         * modules/argz: Omit "#include".
51105
51106         * MODULES.html.sh (func_all_modules): Add calloc, to match
51107         2004-06-01 addition of calloc module.
51108
51109 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
51110
51111         * m4/argz.m4: New file, which is autoupdated from libtool.
51112
51113 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
51114
51115         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
51116         libtool.
51117
51118 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
51119
51120         * config/srclist-update: Don't insist on "USA." before the
51121         close-comment, as libtool omits the period and puts the */ on a
51122         separate line.
51123         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
51124         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
51125
51126 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
51127
51128         * modules/argz: New file.
51129         * MODULES.html.sh (func_all_modules): Add argz.
51130
51131 2004-06-12  Jim Meyering  <jim@meyering.net>
51132         and  Paul Eggert  <eggert@cs.ucla.edu>
51133
51134         * modules/hash (Files): Add lib/xalloc.h.
51135         * modules/pipe (Depends-on): Add wait-process.
51136         * modules/stat (Depends-on): Add xalloc.
51137         * modules/userspec (Files): Add lib/userspec.h.
51138         * modules/xstrto
51139
51140         Upgrade from gettext-0.13.
51141         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
51142         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
51143         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
51144
51145 2004-06-10  Jim Meyering  <jim@meyering.net>
51146
51147         * lib/calloc.c: New file.
51148
51149 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
51150
51151         * lib/getdate.y (yylex): Allow space between sign and number.
51152         Problem reported by Dan Jacobson.
51153
51154 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
51155
51156         Merge from coreutils CVS.
51157
51158         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
51159         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
51160         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
51161         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
51162         xstrtol.m4: Fix copyright date and/or serial number.
51163
51164         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
51165         See if we need an fchown replacement.
51166         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
51167         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
51168         and use the replacement function if we detect either defect.
51169
51170         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
51171         gl_UTIMECMP.
51172
51173 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
51174         and  Jim Meyering  <jim@meyering.net>
51175
51176         Merge from coreutils CVS.
51177
51178         * lib/stat-macros.h: New file, with contents from file-type.h
51179         and coreutils' system.h.
51180         * lib/file-type.c: Include "stat-macros.h".
51181         * lib/file-type.h (file_type): Move all macro definitions to new file,
51182         stat-macros.h.
51183
51184         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
51185         Wrap old code with this conditional.
51186         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
51187         function that does not dereference symlinks.
51188         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
51189
51190         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
51191         dependency problems.
51192         (xreadlink): Accept new arg SIZE, for efficiency.
51193         All decls and uses changed.
51194         * lib/xreadlink.h: Include <stddef.h>, for size_t.
51195
51196         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
51197         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
51198
51199         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
51200         sysexits.h.
51201
51202 2004-06-01  Jim Meyering  <jim@meyering.net>
51203
51204         * m4/calloc.m4: New file.
51205
51206 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
51207
51208         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
51209         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
51210         Also, fix a typo in a diagnostic.
51211
51212 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
51213
51214         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
51215         or AC_FUNC_REALLOC.
51216
51217 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
51218
51219         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
51220         macros to be defined.
51221         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
51222         the allocator returns NULL because the requested size is zero.
51223
51224 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
51225
51226         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
51227         var.  Add comment explaining why libc still defines it.  This
51228         merges the following patch from glibc:
51229         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
51230
51231 2004-05-20  Andreas Schwab  <schwab@suse.de>
51232
51233         * m4/free.m4: Replace free if it not known to work, not the other
51234         way round.
51235
51236 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
51237
51238         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
51239         present in glibc since revision 1.1 of this file.
51240         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
51241         obstack_alignment_mask, obstack_alloc, obstack_base,
51242         obstack_blank, obstack_blank_fast, obstack_chunk_size,
51243         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
51244         obstack_grow0, obstack_init, obstack_int_grow,
51245         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
51246         obstack_next_free, obstack_object_size, obstack_ptr_grow,
51247         obstack_ptr_grow_fast, obstack_room): Remove declarations of
51248         nonexistent functions.
51249
51250 2004-05-18  Karl Berry  <karl@gnu.org>
51251
51252         * config/srclist.txt: break link for vasnprintf.c.
51253
51254 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
51255
51256         Port obstack to the AS/400, where pointers are 16 bytes wide and
51257         you cannot cast an integer to a valid pointer.  This patch is
51258         currently waiting to be integrated into glibc; see
51259         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
51260
51261         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
51262         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
51263         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
51264         (struct obstack): temp member is now a union of a pointer and
51265         an integer, instead of an integer.  All integer uses changed.
51266         This does not affect the physical layout of struct obstack,
51267         except on hosts (like the AS/400) where the size or alignment of
51268         void * is greater than that of ptrdiff_t.
51269         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
51270         __STDC__)]: Store temporary in pointer member of union, not
51271         integer member.
51272         * lib/obstack.c: Include <stddef.h>, for offsetof.
51273         (struct fooalign): Remove; it doesn't need a name.
51274         (union fooround): Change double to long double, and add void *.
51275         (DEFAULT_ALIGNMENT): Use offsetof to compute.
51276         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
51277         not a macro.  Hence the values are always int; so remove all
51278         casts-to-int in uses.
51279
51280 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
51281
51282         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
51283         we can get this patch merged into glibc.
51284
51285 2004-05-17  Derek R. Price  <derek@ximbiot.com>
51286             Paul Eggert  <eggert@cs.ucla.edu>
51287
51288         * m4/argp: Depend on alloca.
51289
51290 2004-05-17  Derek R. Price  <derek@ximbiot.com>
51291             Paul Eggert  <eggert@cs.ucla.edu>
51292
51293         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
51294         freecoding.
51295
51296 2004-05-17  Bruno Haible  <bruno@clisp.org>
51297
51298         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
51299         precision that consists of a '.' followed by an empty digit string.
51300         Patch by Tor Lillqvist <tml@iki.fi>.
51301
51302 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
51303
51304         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
51305         for backward compatibility with older code.  We need our own
51306         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
51307         it under some other name, and our alloca.h will define it.
51308
51309 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
51310             Derek Price  <derek@ximbiot.com>
51311
51312         * lib/alloca.c: Include <alloca.h>, to get our interface.
51313         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
51314         include <alloca.h> first.  Use C89 prototype for alloca; this
51315         requires including <stddef.h> for size_t.  Use extern "C" if C++.
51316         Use #elif for simplicity, since we can assume C89 now.
51317         Don't try to source the system alloca.h since it will not be found
51318         and to prevent recursively including its replacement.
51319         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
51320         * lib/regex.c: Likewise.
51321
51322 2004-05-16  Derek Price  <derek@ximbiot.com>
51323             Paul Eggert  <eggert@cs.ucla.edu>
51324
51325         getline cleanup.  This changes the getndelim2 API: both order of
51326         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
51327         no delimiter).
51328
51329         * lib/getline.c: Don't include stddef.h or stdio.h, since our
51330         interface does that.
51331         (getline): Always use getdelim, so that we don't have two
51332         copies of this code.
51333         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
51334         if available.
51335         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
51336         (GETNDELIM2_MAXIMUM): New macro.
51337         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
51338         instead of the old practice of delim2==0.  All callers changed.
51339         Return -1 on overflow, instead of returning junk.
51340         Do not set *linesize unless allocation succeeds.
51341         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
51342         that we include sys/types.h.
51343         * lib/getnline.h: Likewise.
51344         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
51345         (getndelim2): Reorder arguments.
51346         * lib/getnline.c (getnline, getndelim):
51347         Don't discard the NMAX argument.
51348         (getnline): Invoke getndelim, to avoid code duplication.
51349         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
51350         of (size_t) -1 by callers of the getnline family.
51351
51352 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
51353
51354         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
51355         Check for gettimeofday.
51356         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
51357         Check for settimeofday, stime.
51358
51359 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
51360
51361         * lib/nanosleep.c (suspended): Change its type from int to
51362         sig_atomic_t volatile.
51363         (first_call): Make it private to rpl_nanosleep, and have it
51364         be zero initially as that's a bit faster.
51365         (my_usleep): Round up fractional times instead of truncating them,
51366         as this is the usual meaning for 'sleep'.
51367
51368         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
51369         doesn't work.
51370         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
51371         (ENOSYS): Define if not defined.
51372         (settime): Fall back on stime if it exists and settimeofday fails.
51373         But don't bother with fallbacks if a method fails with errno == EPERM.
51374
51375 2004-05-11  Jim Meyering  <jim@meyering.net>
51376
51377         Prior to this change, the save_cwd caller required read access to the
51378         current directory on most systems (ones with the fchdir function).
51379
51380         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
51381         fails, try write-only, and finally, resort to using xgetcwd.
51382
51383 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
51384
51385         * lib/obstack.c, obstack.h: Import changes from libc.
51386
51387 2004-04-28  Bruno Haible  <bruno@clisp.org>
51388
51389         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
51390         also implicitly appends .exe to executables.
51391         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
51392         accepts Windows pathnames.
51393         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
51394         Treat Cygwin like Windows, since it now accepts Windows pathnames.
51395         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
51396         Treat Cygwin like Windows, since it now accepts Windows pathnames.
51397         Reported by Derek Robert Price <derek@ximbiot.com>.
51398
51399 2004-04-21  Karl Berry  <karl@gnu.org>
51400
51401         * config/srclist.txt (localcharset.c): break sync.
51402
51403 2004-04-20  Paul Eggert  <eggert@twinsun.com>
51404
51405         * m4/host-os.m4: Add a copyright notice.
51406
51407 2004-04-20  Jim Meyering  <jim@meyering.net>
51408
51409         Change UTILS_ to gl_ in AC_DEFINE'd names.
51410         Change utils_- and jm_-prefixed variables, too.
51411         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
51412         UTILS_FUNC_MKDIR_TRAILING_SLASH.
51413         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
51414
51415         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
51416         Don't emit trailing blanks.
51417         Also rename jm_-prefixed variables to have gl_ prefix.
51418
51419         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
51420         Also rename jm_-prefixed variables to have gl_ prefix.
51421
51422         * m4/jm-macros.m4: Reflect the renamings.
51423         * m4/prereq.m4: Likewise.
51424
51425 2004-04-20  Jim Meyering  <jim@meyering.net>
51426
51427         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
51428         memory.
51429
51430 2004-04-20  Jim Meyering  <jim@meyering.net>
51431             Bruno Haible  <bruno@clisp.org>
51432
51433         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
51434         memory when realloc fails.
51435
51436 2004-04-19  Jim Meyering  <jim@meyering.net>
51437
51438         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
51439         now that readutmp.c may call `free (0)'.
51440
51441 2004-04-19  Bruno Haible  <bruno@clisp.org>
51442
51443         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
51444         * m4/inttypes_h.m4: Likewise.
51445         * m4/stdint_h.m4: Likewise.
51446         * m4/intmax_t.m4: Likewise.
51447         * m4/uintmax_t.m4: Likewise.
51448
51449 2004-04-18  Jim Meyering  <jim@meyering.net>
51450
51451         * m4/prereq.m4: Don't forbid jm_ prefix.
51452
51453         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
51454         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
51455         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
51456         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
51457         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
51458         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
51459         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
51460         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
51461         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
51462         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
51463         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
51464         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
51465         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
51466         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
51467         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
51468         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
51469         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
51470         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
51471         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
51472
51473 2004-04-18  Jim Meyering  <jim@meyering.net>
51474
51475         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
51476         failure, don't leak memory and do call END_UTMP_ENT.
51477
51478 2004-04-16  Jim Meyering  <jim@meyering.net>
51479
51480         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
51481         coreutils' stat program.
51482         (gl_PREREQ): Don't require jm_PREREQ_STAT.
51483
51484 2004-04-11  Paul Eggert  <eggert@twinsun.com>
51485
51486         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
51487         C89.
51488         (CHAR_BIT): Remove, since we assume C89.
51489         Include <stdint.h> if available, as per current Autoconf CVS advice.
51490
51491 2004-03-31  Jim Meyering  <jim@meyering.net>
51492
51493         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
51494         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
51495         * m4/xalloc.m4: Likewise.
51496
51497 2004-03-30  Paul Eggert  <eggert@twinsun.com>
51498
51499         Merge from coreutils.
51500
51501         * m4/inttostr.m4: New file.
51502         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
51503         Require AM_STDBOOL_H and gl_TIMESPEC instead.
51504         Require gl_CLOCK_TIME.
51505         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
51506
51507 2004-03-30  Paul Eggert  <eggert@twinsun.com>
51508
51509         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
51510         not bool, to be more consistent with Unix conventions.
51511         Suggested by Bruno Haible.
51512
51513         Merge from coreutils.
51514
51515         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
51516         * lib/umaxtostr.c: New files.
51517
51518         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
51519         the usual <time.h> dance.
51520         (get_date): Change signature to support fractional time stamps.
51521         All callers changed.
51522         * lib/getdate.y: Include "getdate.h" first, as we can now
51523         assume C89 and don't need to worry about 'const'.
51524         Similarly, include "unlocked-io.h" near start, not in middle.
51525         Include <limits.h>.
51526         (textint.value): Use long int rather than int.
51527         (textint.digits): Use size_t rather than int.
51528         (BILLION, LOG10_BILLION): New constants.
51529         (parser_control): New member rel_ns.  Members day_ordinal,
51530         time_zone, month, day, hour, minutes, rel_year, rel_month,
51531         rel_day, rel_hour, rel_minutes, rel_seconds
51532         are now long int, not int.  Member seconds is now struct timespec,
51533         not int.  New member timespec_seen.  Members dates_seen, days_seen,
51534         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
51535         not int.
51536         (%union.intval): Now long int, not int.
51537         New member timespec.
51538         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
51539         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
51540         (spec): Now is a timespec or an item list.
51541         (timespec, items): New nonterminals.
51542         (time, rel, relunit, number, get_date):
51543         Add support for fractional seconds.
51544         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
51545         (gmtime, localtime, mktime): Remove decls; not needed with C89.
51546         (to_hour): First arg is now long int, not int.
51547         (to_year): Returns long int, not int.
51548         Don't treat year -70 like 70.
51549         (tm_diff): Returns long int, not int.
51550         (lookup_word): Use bool instead of int when appropriate.
51551         (yylex): Use size_t for count, not int.
51552         Detect overflow when parsing large integer constants.
51553         Add support for fractions.
51554         (get_date): Make pointers 'const' if possible.
51555         Use more-portable code to detect integer overflow.
51556         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
51557         Don't use ctime; it's not reliable if the year has >4 digits.
51558
51559         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
51560         This is for compatibility with BSD.
51561
51562         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
51563         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
51564         From coreutils' system.h.
51565
51566         * lib/userspec.c: Don't include "posixver.h".
51567         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
51568         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
51569         compatible extension.  Simplify code by removing a boolean int
51570         that was always nonzero if a string was nonnull.
51571
51572 2004-03-30  Jim Meyering  <jim@meyering.net>
51573
51574         Merge from coreutils.
51575
51576         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
51577         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
51578         on some systems one must include <grp.h> before it.
51579         Reported by Christian Krackowizer.
51580
51581 2004-03-30  Jim Meyering  <jim@meyering.net>
51582
51583         Merge from coreutils.
51584
51585         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
51586
51587         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
51588         an empty input stream.
51589
51590         * lib/readtokens.c: Include <stdbool.h>.
51591         (readtoken): Use `size_t' rather than int/long.
51592         All callers adjusted.
51593         Use `bool' rather than `int' where appropriate.
51594         Use memset rather than an explicit loop.
51595         Use x2nrealloc rather than xrealloc.
51596         Allow the use of `\0' as a delimiter.
51597         (readtokens): Likewise.
51598         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
51599
51600 2004-03-30  Jim Meyering  <jim@meyering.net>
51601
51602         * m4/realloc.m4: Remove file, since now it does no more than
51603         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
51604         the `configure.ac' section of module/realloc.
51605         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
51606
51607 2004-03-30  Bruno Haible  <bruno@clisp.org>
51608
51609         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
51610         nonnull.
51611
51612 2004-03-29  Paul Eggert  <eggert@twinsun.com>
51613
51614         Merge changes to getloadavg.c from coreutils and Emacs.
51615
51616         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
51617         Define to an expression, not to the empty string.
51618         Include cloexec.h and xalloc.h.
51619         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
51620         Use set_cloexec_flag rather than rolling our own.
51621         * lib/cloexec.c, lib/cloexec.h: New files.
51622
51623 2004-03-29  Paul Eggert  <eggert@twinsun.com>
51624
51625         * m4/cloexec.m4: New file.
51626
51627 2004-03-18  Paul Eggert  <eggert@twinsun.com>
51628
51629         * lib/getopt.h: Sync with libc CVS.
51630
51631 2004-03-18  Paul Eggert  <eggert@twinsun.com>
51632             Bruno Haible  <bruno@clisp.org>
51633
51634         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
51635         mbswidth.
51636
51637 2004-03-18  Paul Eggert  <eggert@twinsun.com>
51638             Bruno Haible  <bruno@clisp.org>
51639
51640         * lib/mbswidth.h: Include <wchar.h> only if
51641         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
51642         <wchar.h>.
51643         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
51644
51645 2004-03-09  Paul Eggert  <eggert@twinsun.com>
51646
51647         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
51648         Sync with libc CVS.
51649         * lib/getopt_int.h: New file, also synced from libc.
51650
51651 2004-03-09  Paul Eggert  <eggert@twinsun.com>
51652
51653         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
51654         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
51655         Bring back getopt.c, getopt.h, getopt1.c.
51656
51657 2004-03-07  Paul Eggert  <eggert@twinsun.com>
51658
51659         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
51660         All uses changed.  Check for sa_sigaction member; this fixes
51661         a bug first reported by Jason Andrade in
51662         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
51663
51664 2004-03-07  Paul Eggert  <eggert@twinsun.com>
51665
51666         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
51667         '#if' expressions.  Unlike the code it replaces, it does not
51668         depend on (defined _SC_PAGESIZE).  However, it does depend on
51669         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
51670         first reported by Jason Andrade in
51671         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
51672
51673 2004-02-25  Simon Josefsson  <jas@extundo.com>
51674
51675         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
51676
51677 2004-02-25  Simon Josefsson  <jas@extundo.com>
51678
51679         * lib/strdup.h: New file.
51680         * lib/strdup.c: Include it.
51681         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
51682         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
51683
51684 2004-02-23  Karl Berry  <karl@gnu.org>
51685
51686         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
51687         (from fencepost.gnu.org:/gd/gnuorg).
51688
51689 2004-02-23  Karl Berry  <karl@gnu.org>
51690
51691         * config/srclistvars.sh (GNUORG) [karl]: redefine.
51692         * config/srclist.txt: add maintain/standards documents.
51693
51694 2004-02-18  Bruno Haible  <bruno@clisp.org>
51695
51696         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
51697         Reported by Derek Robert Price <derek@ximbiot.com>.
51698
51699 2004-02-16  Karl Berry  <karl@gnu.org>
51700
51701         * config/mkinstalldirs, install-sh: update from automake.
51702
51703 2004-02-06  Karl Berry  <karl@gnu.org>
51704
51705         * m4/po.m4: update from gettext 0.14.1.
51706
51707 2004-02-06  Karl Berry  <karl@gnu.org>
51708
51709         * lib/config.charset: update from gettext 0.14.1.
51710
51711 2004-02-05  Paul Eggert  <eggert@twinsun.com>
51712
51713         Add comments and code, prompted by suggestions from Bruno Haible
51714         for sh-quote.
51715         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
51716         describing the enum quoting_style values.
51717         * lib/quotearg.c (quotearg_alloc): New function.
51718         (quotearg_buffer_restyled): Treat lone { and } as special.
51719         Treat = as special.  Work around bug with older shells
51720         that "see" a '\' that is really the 2nd byte of a multibyte char.
51721         Quote empty string with shell_quoting_style.
51722
51723 2004-02-03  Bruno Haible  <bruno@clisp.org>
51724
51725         * m4/pipe.m4: New file, from GNU gettext.
51726
51727 2004-02-03  Bruno Haible  <bruno@clisp.org>
51728
51729         * lib/pipe.h: New file, from GNU gettext.
51730         * lib/pipe.c: New file, from GNU gettext.
51731
51732 2004-01-27  Bruno Haible  <bruno@clisp.org>
51733
51734         * m4/execute.m4: New file, from GNU gettext.
51735
51736 2004-01-27  Bruno Haible  <bruno@clisp.org>
51737
51738         * lib/execute.h: New file, from GNU gettext.
51739         * lib/execute.c: New file, from GNU gettext.
51740         * lib/w32spawn.h: New file, from GNU gettext.
51741
51742 2004-01-24  Paul Eggert  <eggert@twinsun.com>
51743
51744         Merge from diffutils.
51745
51746         * lib/file-type.c (file_type): Add typed memory objects.
51747         * lib/file-type.h (S_TYPEISTMO): New macro.
51748
51749         * lib/c-stack.h (c_stack_action): Remove argv argument.
51750         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
51751         (die): Don't calculate message unless segv_action returns.
51752         (get_stack_location, min_address_from_argv, max_address_from_argv,
51753         volatile stack_base, volatile_stack_size): Remove.
51754         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
51755         that every segmentation violation is a stack overflow.  (Ouch!)
51756         See Debian bug 136249 (still outstanding) for more info about why
51757         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
51758
51759 2004-01-24  Paul Eggert  <eggert@twinsun.com>
51760
51761         Exit-status fix from coreutils.
51762
51763         Use exit_failure consistently in place of EXIT_FAILURE,
51764         so that program exit statuses are consistent on failure.
51765
51766         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
51767         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
51768         * lib/argmatch.h: Comment fix to match the above.
51769         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
51770         Now a macro referring to exit_failure, instead of a separate
51771         variable.  Include "exitfail.h" to get it.
51772         * lib/xstrtol.h: Include "exitfail.h".
51773         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
51774
51775         * lib/long-options.c (parse_long_options): Use prototype
51776         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
51777         for clarity.
51778
51779 2004-01-21  Jim Meyering  <jim@meyering.net>
51780
51781         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
51782         so as not to conflict with a different-sized __mktime_internal
51783         function in GNU libc.
51784         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
51785         Problem building statically-linked `ls' reported by Michael Brunnbauer.
51786
51787 2004-01-20  Karl Berry  <karl@gnu.org>
51788
51789         * config/config.guess: update from config.
51790
51791         * config/srclistvars.sh: GNUWWWLICENSES for karl.
51792
51793 2004-01-20  Bruno Haible  <bruno@clisp.org>
51794
51795         Safer stack allocation.
51796         * lib/setenv.c: Include allocsa.h.
51797         (alloca): Remove fallback definition.
51798         (freea): Remove macro.
51799         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
51800         instead of freea.
51801
51802 2004-01-20  Bruno Haible  <bruno@clisp.org>
51803
51804         * m4/eealloc.m4: New file, from GNU gettext.
51805
51806 2004-01-20  Bruno Haible  <bruno@clisp.org>
51807
51808         * m4/allocsa.m4: New file, from GNU gettext.
51809
51810 2004-01-20  Bruno Haible  <bruno@clisp.org>
51811
51812         * lib/xallocsa.h: New file, from GNU gettext.
51813         * lib/xallocsa.c: New file, from GNU gettext.
51814
51815 2004-01-20  Bruno Haible  <bruno@clisp.org>
51816
51817         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
51818
51819 2004-01-20  Bruno Haible  <bruno@clisp.org>
51820
51821         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
51822         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
51823         specially.
51824
51825 2004-01-20  Bruno Haible  <bruno@clisp.org>
51826
51827         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
51828         patch.
51829
51830 2004-01-20  Bruno Haible  <bruno@clisp.org>
51831
51832         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
51833
51834 2004-01-20  Bruno Haible  <bruno@clisp.org>
51835
51836         * lib/eealloc.h: New file.
51837
51838 2004-01-20  Bruno Haible  <bruno@clisp.org>
51839
51840         * lib/binary-io.h: Avoid warnings on Cygwin.
51841
51842 2004-01-20  Bruno Haible  <bruno@clisp.org>
51843
51844         * lib/allocsa.h: New file, from GNU gettext.
51845         * lib/allocsa.c: New file, from GNU gettext.
51846
51847 2004-01-18  Karl Berry  <karl@gnu.org>
51848
51849         * doc/gpl.texi, doc/lgpl.texi: new files.
51850
51851 2004-01-18  Karl Berry  <karl@gnu.org>
51852
51853         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
51854         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
51855
51856 2004-01-15  Paul Eggert  <eggert@twinsun.com>
51857
51858         Merge from coreutils.
51859
51860         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
51861         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
51862         (gl_DEFAULT_POSIX2_VERSION): Move
51863         the documentation from 'configure' into 'config.hin',
51864         so that 'configure --help' isn't burdened by it and
51865         we don't have to worry about its formatting there.
51866         Reword the documentation so that it's more succinct
51867         and can be run together into a single paragraph.
51868         * m4/same.m4 (gl_SAME): Check for pathconf.
51869
51870 2004-01-15  Paul Eggert  <eggert@twinsun.com>
51871
51872         Merge from coreutils.
51873
51874         * lib/posixver.c: Include posixver.h.
51875
51876         * lib/same.c: Include <stdbool.h>, <limits.h>.
51877         (_POSIX_NAME_MAX): Define if not defined.
51878         (MIN): New macro.
51879         (same_name): If file names are silently truncated, report
51880         that the file names are the same if they are the same after
51881         the silent truncation.
51882
51883         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
51884         conversion function.
51885         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
51886         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
51887         longer needed.
51888
51889 2004-01-15  Jim Meyering  <jim@meyering.net>
51890
51891         Merge from coreutils.
51892
51893         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
51894         if no library is required.
51895         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
51896         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
51897         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
51898         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
51899         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
51900         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
51901         value, $ac_cv_search_crypt, if it's "none required".
51902         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
51903         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
51904         not gl_FUNC_GETLOADAVG.
51905         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
51906         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
51907
51908 2004-01-15  Jim Meyering  <jim@meyering.net>
51909
51910         Merge from coreutils.
51911
51912         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
51913         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
51914         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
51915
51916         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
51917         optional configure-time default.
51918
51919         * lib/version-etc.c (version_etc_copyright): Update copyright date.
51920
51921         * lib/xreadlink.c (xreadlink): Correct outdated comment.
51922
51923 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
51924
51925         Merge from coreutils.
51926
51927         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
51928         value, $ac_cv_search_nanosleep, if it's "none required".
51929
51930 2004-01-14  Paul Eggert  <eggert@twinsun.com>
51931
51932         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
51933         with like-named macro in fnmatch.c.
51934         (EXT): Use an internal constant instead.
51935
51936         Merge fnmatch patches from glibc.
51937         * lib/fnmatch.c (mbsinit): Remove define.
51938         Add libc_hidden_ver (__fnmatch, fnmatch).
51939         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
51940         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
51941
51942 2004-01-14  Karl Berry  <karl@gnu.org>
51943
51944         * config/install-sh: update from automake.
51945
51946 2004-01-13  Karl Berry  <karl@gnu.org>
51947
51948         * config/install-sh: update from automake.
51949
51950 2004-01-09  Karl Berry  <karl@gnu.org>
51951
51952         * config/install-sh: update from automake.
51953
51954 2004-01-05  Karl Berry  <karl@gnu.org>
51955
51956         * config/config.{sub,guess}: update from config.
51957
51958 2003-12-31  Karl Berry  <karl@gnu.org>
51959
51960         * config/depcomp: update from automake.
51961
51962 2003-12-14  Karl Berry  <karl@gnu.org>
51963
51964         * lib/config.charset: update from gettext-runtime.
51965
51966 2003-12-03  Paul Eggert  <eggert@twinsun.com>
51967
51968         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
51969         Bug reported by Alfred M. Szmidt.
51970
51971 2003-12-03  Bruno Haible  <bruno@clisp.org>
51972
51973         * m4/gettext.m4: Upgrade from gettext-0.13.
51974         * m4/po.m4: Upgrade from gettext-0.13.
51975         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
51976         * m4/intmax.m4: New file, from gettext-0.13.
51977         * m4/printf-posix.m4: New file, from gettext-0.13.
51978
51979 2003-11-29  Karl Berry  <karl@gnu.org>
51980
51981         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
51982
51983 2003-11-25  Paul Eggert  <eggert@twinsun.com>
51984             Bruno Haible  <bruno@clisp.org>
51985
51986         * lib/printf-parse.h: Don't include sys/types.h.
51987         (ARG_NONE): New macro.
51988         (char_directive): Change type of *arg_index fields to size_t.
51989         * lib/printf-parse.c: Don't include sys/types.h.
51990         (SSIZE_MAX): Remove macro.
51991         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
51992         Remove unnecessary overflow check.
51993         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
51994         fields.
51995
51996 2003-11-25  Bruno Haible  <bruno@clisp.org>
51997
51998         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
51999
52000 2003-11-25  Bruno Haible  <bruno@clisp.org>
52001
52002         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
52003         gt_TYPE_SSIZE_T.
52004
52005 2003-11-24  Paul Eggert  <eggert@twinsun.com>
52006
52007         * modules/alloca: Remove dependency on xalloc.
52008
52009 2003-11-24  Paul Eggert  <eggert@twinsun.com>
52010
52011         * lib/alloca.c: Remove dependency on xalloc module.
52012         (xalloc_die): Remove.
52013         (memory_full) [!defined emacs]: New macro.
52014         [!defined emacs]: Don't include xalloc.h.
52015         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
52016         address arithmetic overflows.  Change datatypes a bit to avoid
52017         unnecessary casts.
52018
52019 2003-11-22  Jim Meyering  <jim@meyering.net>
52020
52021         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
52022         s/size/size_t/.
52023
52024 2003-11-21  Karl Berry  <karl@gnu.org>
52025
52026         * config/config.{sub,guess}: update from config.
52027
52028 2003-11-18  Karl Berry  <karl@gnu.org>
52029
52030         * config/config.{sub,guess}: update from config.
52031
52032         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
52033
52034 2003-11-17  Paul Eggert  <eggert@twinsun.com>
52035
52036         * README: Mention that S+T cannot overflow if S is the size of
52037         an existing object and T is sufficiently small.
52038
52039 2003-11-17  Jim Meyering  <jim@meyering.net>
52040
52041         On systems without utime and without a utimes function capable of
52042         dealing with a NULL struct utimbuf* argument, this utime replacement
52043         could -- in unusual circumstances -- leak a file descriptor.
52044         * lib/utime.c: Include <unistd.h> and <errno.h>.
52045         (utime_null): Be sure to close `fd' and to preserve errno.
52046         Reported by Geoff Collyer via Arnold Robbins.
52047
52048 2003-11-17  Bruno Haible  <bruno@clisp.org>
52049
52050         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
52051         (Depends-on): Add xsize.
52052
52053 2003-11-17  Bruno Haible  <bruno@clisp.org>
52054
52055         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
52056
52057 2003-11-17  Bruno Haible  <bruno@clisp.org>
52058
52059         * lib/vasnprintf.c (alloca): Remove fallback definition.
52060         (freea): Remove definition.
52061         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
52062         Reported by Paul Eggert.
52063
52064 2003-11-16  Paul Eggert  <eggert@twinsun.com>
52065             Bruno Haible  <bruno@clisp.org>
52066
52067         Protect against address arithmetic overflow.
52068         * lib/printf-args.h: Include stddef.h.
52069         (arguments): Change type of field 'count' to size_t.
52070         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
52071         'unsigned int' where appropriate.
52072         * lib/printf-parse.h: Include sys/types.h.
52073         (char_directive): Change type of *arg_index fields to ssize_t.
52074         (char_directives): Change type of fields 'count', max_*_length to
52075         size_t.
52076         * lib/printf-parse.c: Include sys/types.h and xsize.h.
52077         (SSIZE_MAX): Define fallback value.
52078         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
52079         instead of 'int' where appropriate. Check a_allocated, d_allocated
52080         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
52081         * lib/vasnprintf.c: Include xsize.h.
52082         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
52083         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
52084         overflow. Avoid wraparound when converting a width or precision from
52085         decimal to binary.
52086
52087 2003-11-16  Bruno Haible  <bruno@clisp.org>
52088
52089         Update from GNU gettext.
52090         * lib/printf-parse.c: Generalize to it can be compiled for wide
52091         strings.
52092         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
52093         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
52094         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
52095         SNPRINTF): New macros.
52096         Don't include <alloca.h> if the file is used inside libintl.
52097         (local_wcslen): New function, for Solaris 2.5.1.
52098         (VASNPRINTF): Use it instead of wcslen.
52099
52100 2003-11-16  Bruno Haible  <bruno@clisp.org>
52101
52102         * lib/xsize.h (xmax): New function.
52103         (xsum, xsum3, xsum4): Declare as "pure" functions.
52104
52105 2003-11-12  Paul Eggert  <eggert@twinsun.com>
52106
52107         * modules/xalloc (Files): Undo latest change, since xalloc.h
52108         no longer needs SIZE_MAX or PTRDIFF_MAX.
52109
52110 2003-11-12  Paul Eggert  <eggert@twinsun.com>
52111
52112         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
52113         gl_PTRDIFF_MAX.
52114
52115 2003-11-12  Paul Eggert  <eggert@twinsun.com>
52116
52117         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
52118         "return", to pacify some unknown compiler.  Problem reported
52119         by Joerg Schilling.
52120
52121 2003-11-12  Paul Eggert  <eggert@twinsun.com>
52122
52123         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
52124         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
52125         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
52126         heuristic is just as accurate as far as we know, and it removes a
52127         dependency on size_max.m4 and ptrdiff_max.m4.
52128
52129 2003-11-11  Bruno Haible  <bruno@clisp.org>
52130
52131         * modules/xsize (Files): Add m4/size_max.m4.
52132         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
52133
52134 2003-11-11  Bruno Haible  <bruno@clisp.org>
52135
52136         * m4/size_max.m4: New file.
52137         * m4/ptrdiff_max.m4: New file.
52138         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
52139         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
52140         (gl_XALLOC): Invoke it.
52141
52142 2003-11-11  Bruno Haible  <bruno@clisp.org>
52143
52144         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
52145         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
52146         defined.
52147
52148 2003-11-10  Paul Eggert  <eggert@twinsun.com>
52149
52150         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
52151         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
52152         rejected some allocations of exactly SIZE_MAX - 2 bytes.
52153         From Bruno Haible.
52154         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
52155         not (size_t) -1, since it's defined here.
52156
52157 2003-11-09  Karl Berry  <karl@gnu.org>
52158
52159         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
52160
52161 2003-11-06  Paul Eggert  <eggert@twinsun.com>
52162
52163         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
52164         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
52165         Reject sizes of exactly SIZE_MAX bytes.
52166         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
52167         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
52168
52169 2003-11-05  Bruno Haible  <bruno@clisp.org>
52170
52171         * lib/xsize.h: Include limits.h, to avoid a possible collision with
52172         SIZE_MAX defined in <limits.h> on Solaris.
52173
52174 2003-11-04  Jim Meyering  <jim@meyering.net>
52175
52176         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
52177         variable names, rather than @VAR@.
52178         * modules/poll: Likewise.
52179
52180 2003-11-04  Bruno Haible  <bruno@clisp.org>
52181
52182         * modules/xsize: New file.
52183         * modules/linebreak: Depend on xsize.
52184         * MODULES.html.sh (func_all_modules): Add xsize.
52185
52186 2003-11-04  Bruno Haible  <bruno@clisp.org>
52187
52188         * m4/xsize.m4: New file.
52189
52190 2003-11-04  Bruno Haible  <bruno@clisp.org>
52191
52192         * lib/xsize.h: New file.
52193         * lib/linebreak.c: Include xsize.h.
52194         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
52195         argument for overflow.
52196         Suggested by Paul Eggert.
52197
52198 2003-11-03  Karl Berry  <karl@gnu.org>
52199
52200         * config/config.{guess,sub}: update from config.
52201
52202 2003-11-03  Jim Meyering  <jim@meyering.net>
52203
52204         * modules/userspec (lib_SOURCES): Add userspec.h.
52205         (Include): Add "userspec.h".
52206         Improve description.
52207
52208 2003-11-03  Jim Meyering  <jim@meyering.net>
52209
52210         * lib/userspec.c: Include "userspec.h".
52211         * lib/userspec.h: New file.
52212
52213 2003-11-03  Bruno Haible  <bruno@clisp.org>
52214
52215         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
52216
52217 2003-11-03  Bruno Haible  <bruno@clisp.org>
52218
52219         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
52220         available, to avoid (extremely rare) race condition.
52221         Suggested by Paul Eggert.
52222
52223 2003-11-02  Karl Berry  <karl@gnu.org>
52224
52225         * config/srclist.txt (vasprintf.c): sync broken, sigh.
52226
52227 2003-10-31  Paul Eggert  <eggert@twinsun.com>
52228
52229         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
52230         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
52231         (read_filesystem_list): Set and use me_type_malloced.
52232         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
52233         whatever the type happens to be), for brevity and consistency.
52234         Check for size calculation overflow on Alphas running OSF/1.
52235
52236 2003-10-31  Jim Meyering  <jim@meyering.net>
52237
52238         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
52239
52240         * lib/linebuffer.c: Include <string.h> for declaration of memset.
52241
52242 2003-10-30  Paul Eggert  <eggert@twinsun.com>
52243             Bruno Haible  <bruno@clisp.org>
52244
52245         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
52246         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
52247
52248 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
52249
52250         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
52251         netbsd*-gnu*.  Suggested by Robert Millan.
52252
52253 2003-10-29  Paul Eggert  <eggert@twinsun.com>
52254
52255         * modules/group-member: Depend on stdbool.
52256
52257 2003-10-29  Paul Eggert  <eggert@twinsun.com>
52258
52259         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
52260
52261 2003-10-29  Paul Eggert  <eggert@twinsun.com>
52262
52263         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
52264         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
52265         after the 'gnu' in these cases.  This fixes some bugs in the
52266         previous change, and is based on suggestions by Robert Millan.
52267
52268 2003-10-29  Paul Eggert  <eggert@twinsun.com>
52269
52270         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
52271         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
52272         no longer needed.
52273         * lib/quotearg.c (quotearg_n_options): Use it.
52274         * lib/group-member.c: Include <stdbool.h>.
52275         (free_group_info): Arg is now const *; don't free arg.
52276         (get_group_info): Now returns bool and accepts struct group_info *,
52277         rather than returning a malloc'ed struct group_info *.
52278         All uses changed.  Check for overflow in internal size calculation.
52279
52280         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
52281         rather than xmalloc/xrealloc.
52282         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
52283         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
52284         conformance bug: the old code used a pointer after freeing the
52285         storage that it addressed.
52286         * lib/hash.c (hash_initialize): Simplify the code by using
52287         xalloc_oversized rather than doing it by hand.
52288         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
52289         the buffer preserved.  Use free and xmalloc instead.
52290         * lib/quotearg.c (quotearg_n_options): Likewise.
52291         Use a simpler test for size overflow.  Don't use xalloc_oversized
52292         because unsigned int might be wider than size_t (!); this suggests
52293         that we should switch from unsigned int to size_t for slot numbers.
52294
52295 2003-10-28  Paul Eggert  <eggert@twinsun.com>
52296
52297         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
52298         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
52299         NetBSD kernels.  Requested by Richard Stallman.
52300
52301 2003-10-27  Paul Eggert  <eggert@twinsun.com>
52302
52303         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
52304         to allocate the returned structure.  Do not allocate a subarray,
52305         as x2nrealloc will do that.
52306         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
52307         instead of xnrealloc.
52308         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
52309
52310 2003-10-27  Bruno Haible  <bruno@clisp.org>
52311
52312         * lib/stdbool_.h: Better support for BeOS.
52313
52314 2003-10-26  Paul Eggert  <eggert@twinsun.com>
52315
52316         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
52317         now uses inline.
52318
52319 2003-10-26  Paul Eggert  <eggert@twinsun.com>
52320
52321         * lib/xalloc.h (xalloc_oversized): New static inline function, for
52322         callers that want to do their own size-overflow checking.  Include
52323         <stdbool.h>, since xalloc_oversized returns bool.
52324         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
52325         to use xalloc_oversized.
52326
52327         Add two functions x2realloc, x2nrealloc, for programs that grow
52328         arrays dynamically by doubling their sizes.
52329         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
52330         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
52331         New functions.
52332
52333         Port to C99 semantics for 'inline' of external functions.
52334         Bug reported by Bruno Haible.
52335         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
52336         with the old contents of xnmalloc.
52337         (xnmalloc, xmalloc): Use it.
52338         (xnrealloc_inline): New static inline function,
52339         with the old contents of xnrealloc.
52340         (xnrealloc, xrealloc): Use it.
52341
52342         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
52343         that.
52344
52345 2003-10-26  Karl Berry  <karl@gnu.org>
52346
52347         * config/srclist.txt (COPYING.DOC): no longer available from
52348         /gd/gnuorg; don't know where the ultimate source is.
52349
52350 2003-10-25  Paul Eggert  <eggert@twinsun.com>
52351
52352         Fix several address-calculation bugs in the hash modules,
52353         plus some minor code cleanup.
52354
52355         * lib/hash.h: Include <stdbool.h>, for bool.
52356         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
52357         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
52358         hash_get_n_entries, hash_get_max_bucket_length,
52359         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
52360         hash_rehash): Use size_t rather than unsigned.
52361         * lib/hash.c (struct hash_table, hash_get_n_buckets,
52362         hash_get_n_buckets_used, hash_get_n_entries,
52363         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
52364         hash_get_entries, hash_do_for_each, hash_string, is_prime,
52365         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
52366         Likewise.
52367         (SIZE_MAX): Define if not defined.
52368         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
52369         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
52370         hash_print):
52371         Use const * when possible.
52372         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
52373         (check_tuning): Fix bug: if tuning parameters were very close to
52374         0 or 1, rounding errors could have caused subscript violations.
52375         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
52376         (hash_initialize): Add 'fail:' label
52377         to free table and return NULL, and use it to simplify code.
52378         Use calloc rather than clearing the storage ourself.
52379         (hash_initialize, hash_rehash): Check for arithmetic overflow in
52380         buffer size calculations.
52381         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
52382         Include <stddef.h>, for size_t.
52383         * lib/hash-pjw.c (hash_pjw): Likewise.
52384         Switch to method described by Bruno Haible.
52385         Include <limits.h>, for CHAR_BIT.
52386         (SIZE_BITS): New macro.
52387
52388 2003-10-23  Paul Eggert  <eggert@twinsun.com>
52389
52390         * m4/getline.m4 (AM_FUNC_GETLINE):
52391         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
52392         hosts.  Problem reported by Derek Robert Price in
52393         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
52394         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
52395         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
52396
52397 2003-10-21  Paul Eggert  <eggert@twinsun.com>
52398
52399         * lib/getndelim2.c (getndelim2): When size calculation overflows,
52400         ceiling the allocation at NMAX bytes rather than silently
52401         discarding input bytes before NMAX is reached.  This makes
52402         a difference only if NMAX exceeds SIZE_MAX / 2.
52403
52404         * lib/obstack.c: Merge from glibc.
52405         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
52406         Add libc_hidden_def (_obstack_newchunk).
52407         (_obstack_free) [! defined _LIBC]: Remove.
52408         [defined _LIBC]: Make a strong alias from obstack_free, rather than
52409         a clone of the function body.
52410         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
52411         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
52412
52413         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
52414         glibc.
52415         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
52416         arg to memcpy.
52417
52418         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
52419         (obstack_ptr_grow_fast, obstack_int_grow_fast):
52420         Don't use lvalue casts, as GCC plans to remove support for them
52421         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
52422         was also present in the non-GCC version, indicating that this
52423         code had always been buggy and had never been widely used.
52424         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
52425         Use the fast variant of each macro, rather than copying the
52426         definiens of the fast variant; that way, we'll be more likely to
52427         catch future bugs in the fast variants.
52428
52429 2003-10-20  Bruno Haible  <bruno@clisp.org>
52430
52431         * modules/wait-process: New file.
52432         * MODULES.html.sh (func_all_modules): Add wait-process.
52433
52434 2003-10-20  Bruno Haible  <bruno@clisp.org>
52435
52436         * m4/wait-process.m4: New file.
52437
52438 2003-10-20  Bruno Haible  <bruno@clisp.org>
52439
52440         * lib/wait-process.h: New file, from GNU gettext.
52441         * lib/wait-process.c: New file, from GNU gettext.
52442
52443 2003-10-19  Jim Meyering  <jim@meyering.net>
52444
52445         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
52446         HPUX 10.20.
52447
52448 2003-10-18  Karl Berry  <karl@gnu.org>
52449
52450         * config/config.guess: update from config.
52451
52452 2003-10-16  Paul Eggert  <eggert@twinsun.com>
52453
52454         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
52455         (getgroups): First arg is int, not size_t.
52456         Don't let 'free' mangle errno.
52457
52458 2003-10-16  Paul Eggert  <eggert@twinsun.com>
52459
52460         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
52461
52462 2003-10-16  Karl Berry  <karl@gnu.org>
52463
52464         * config/config.{guess,sub}: update from config.
52465
52466 2003-10-16  Jim Meyering  <jim@meyering.net>
52467
52468         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
52469         memcpy.
52470
52471 2003-10-15  Paul Eggert  <eggert@twinsun.com>
52472
52473         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
52474         (SIZE_MAX): Remove.
52475         (new_exclude, add_exclude_file): Initial size no longer needs to
52476         be a power of 2.
52477         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
52478         our own address arithmetic overflow checking.
52479
52480         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
52481         (fnmatch): Do not alloca more than 2000 wide characters;
52482         instead, use malloc for large buffers.
52483         Check for address arithmetic overflow, and return -1
52484         with errno set to ENOMEM in that case.
52485         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
52486         (NEW_PATTERN): Do not alloca more than 8000 bytes;
52487         instead, return -1.  Check for address arithmetic overflow.
52488
52489 2003-10-14  Paul Eggert  <eggert@twinsun.com>
52490
52491         Handle invalid suffixes and overflow independently, so that
52492         callers can treat them independently as needed.  Fix some bugs in
52493         suffix handling, e.g., "100k@" was not diagnosed as an invalid
52494         suffix for a human-readable blocksize.  The major caller-visible
52495         change is the addition of a new
52496         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
52497         that both overflow and suffix chars were found.
52498
52499         * lib/human.c (humblock): Don't check separately for invalid suffix
52500         char; that is xstrtoumax's job (now that its bug is fixed).
52501         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
52502         INTMAX_MAX]: New macros.
52503         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
52504         TYPE_MAXIMUM): New macros.
52505         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
52506         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
52507         if overflow occurs, as it's what __strtol does and it's more useful
52508         in practice.
52509         (__xstrtol): If __strtol reports some error other than ERANGE,
52510         reflect it to the caller as LONGINT_INVALID.  If it reports
52511         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
52512         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
52513         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
52514         value.
52515         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
52516         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
52517         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
52518         [defined UINTMAX_MAX]: New macros.
52519
52520 2003-10-14  Bruno Haible  <bruno@clisp.org>
52521
52522         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
52523
52524 2003-10-14  Bruno Haible  <bruno@clisp.org>
52525
52526         * m4/sig_atomic_t: New file, from GNU gettext.
52527         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
52528
52529 2003-10-14  Bruno Haible  <bruno@clisp.org>
52530
52531         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
52532         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
52533         Also use volatile where needed.
52534
52535 2003-10-12  Paul Eggert  <eggert@twinsun.com>
52536
52537         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
52538         Change maintainer from Bruno Haible to 'all'.
52539
52540 2003-10-12  Paul Eggert  <eggert@twinsun.com>
52541
52542         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
52543
52544 2003-10-12  Paul Eggert  <eggert@twinsun.com>
52545
52546         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
52547         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
52548         and define in terms of the other primitives.
52549         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
52550         (SIZE_MAX): Define if not already defined.
52551         (array_size_overflow): New function.
52552         (xalloc_die): Abort instead of exiting if 'error' returns.
52553         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
52554         (xmalloc, xrealloc): Use them.
52555         (xcalloc): Check for address arithmetic overflow.
52556         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
52557         a bit faster than strcpy.
52558
52559 2003-10-10  Simon Josefsson  <jas@extundo.com>
52560
52561         * modules/argp (Depends-on): Add restrict and strcase.
52562
52563 2003-10-10  Simon Josefsson  <jas@extundo.com>
52564
52565         * m4/argp.m4: Add AC_C_INLINE.
52566
52567 2003-10-08  Paul Eggert  <eggert@twinsun.com>
52568
52569         Merge getpass from libc, plus a few fixes.
52570
52571         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
52572         Include <stdbool.h>.
52573         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
52574         __fsetlocking to empty.
52575         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
52576         do include <bits/libc-lock.h>.
52577         Do not include <fcntl.h>; not needed.
52578         [_LIBC]: Include <wchar.h>.
52579         (NOTCANCEL_MODE): New macro.
52580         (flockfile, funlockfile) [_LIBC]: New macros.
52581         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
52582         [!_LIBC]: New macros.
52583         (call_fclose): New function.
52584         (getpass): Use it.  Save tty stream separately; this simplifies the
52585         code and makes it more reliable if stdin happens to equal stdout.
52586         Invoke __fsetlocking on tty.
52587         Handle thread cancellation if needed.
52588         Namespace cleanup (use __tcgetattr, __getline).
52589         Use bool for Booleans.
52590         [USE_IN_LIBIO]: Handle wide streams.
52591         [!_LIBC]: Unconditionally do the fseek, since we don't know what
52592         stream might go where.
52593
52594         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
52595         doesn't have to include <stdio.h> before us.
52596         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
52597         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
52598         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
52599         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
52600         if not declared, so that we can use getpass.c code from libc without
52601         rewriting it.
52602         (flockfile, ftrylockfile, funlockfile): New macros.
52603
52604 2003-10-08  Paul Eggert  <eggert@twinsun.com>
52605
52606         * modules/getpass: Depend on stdbool.
52607
52608 2003-10-08  Paul Eggert  <eggert@twinsun.com>
52609
52610         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
52611
52612 2003-10-07  Karl Berry  <karl@gnu.org>
52613
52614         * config/config.{guess,sub}: update from config.
52615
52616 2003-10-06  Jim Meyering  <jim@meyering.net>
52617             Bruno Haible  <bruno@clisp.org>
52618
52619         This lets translators provide better translations for the
52620         "Written by ..." part of --version output.
52621         * lib/version-etc.h: Include stdarg.h.
52622         (version_etc_copyright): Declare as readonly.
52623         (version_etc): Make this function variadic with a NULL-terminated list
52624         of author name strings.
52625         (version_etc_va): New declaration.
52626         * lib/version-etc.c: Include stdarg.h, stdlib.h.
52627         (version_etc_copyright): Declare as readonly.
52628         (version_etc_va): New function. Provide a different translatable string
52629         for each possible number of authors < 10. Abbreviate when there are 10
52630         authors or more.
52631         (version_etc): Make this function variadic. Call version_etc_va.
52632         Suggestion from Gary V. Vaughan.
52633
52634         * lib/long-options.h (parse_long_options): Change prototype: the
52635         authors string is moved to the end and becomes variadic.
52636         * lib/long-options.c: Include stdarg.h.
52637         (parse_long_options): Make this function variadic, too.
52638         Call version_etc_va, not version_etc.
52639
52640 2003-10-06  Bruno Haible  <bruno@clisp.org>
52641
52642         * modules/version-etc-2: Remove file.
52643         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
52644
52645 2003-10-06  Bruno Haible  <bruno@clisp.org>
52646
52647         * modules/fatal-signal: New file.
52648         * MODULES.html.sh (func_all_modules): Add fatal-signal.
52649
52650 2003-10-06  Bruno Haible  <bruno@clisp.org>
52651
52652         * m4/fatal-signal.m4: New file.
52653         * m4/signalblocking.m4: New file, from GNU gettext.
52654
52655 2003-10-06  Bruno Haible  <bruno@clisp.org>
52656
52657         * lib/version-etc-2.h: Remove file.
52658         * lib/version-etc-2.c: Remove file.
52659
52660 2003-10-06  Bruno Haible  <bruno@clisp.org>
52661
52662         * lib/fatal-signal.h: New file, from GNU gettext.
52663         * lib/fatal-signal.c: New file, from GNU gettext.
52664
52665 2003-10-05  Paul Eggert  <eggert@twinsun.com>
52666
52667         * README: Rework advice for preventing empty .o files.
52668         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
52669         not <sys/types.h>.
52670
52671 2003-10-04  Karl Berry  <karl@gnu.org>
52672
52673         * lib/argp*: update from libc.
52674
52675 2003-10-04  Karl Berry  <karl@gnu.org>
52676
52677         * config/config.{guess,sub}: update from config.
52678
52679 2003-10-02  Bruno Haible  <bruno@clisp.org>
52680
52681         * modules/lchown (Include): Add lchown.h.
52682         * modules/time_r (Include): Use "..." syntax.
52683         * modules/xgetdomainname (Include): Add xgetdomainname.h.
52684
52685 2003-10-01  Simon Josefsson  <jas@extundo.com>
52686
52687         * MODULES.html.sh (func_all_modules): Move gethostname from section
52688         'based on' to section 'lacking' POSIX:2001.
52689
52690 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
52691
52692         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
52693         to output mode on the same stream.
52694
52695 2003-09-29  Paul Eggert  <eggert@twinsun.com>
52696
52697         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
52698         Fix arg typo in previous patch.
52699
52700 2003-09-28  Jim Meyering  <jim@meyering.net>
52701
52702         * lib/error.c: Correct cpp indentation.
52703
52704 2003-09-27  Paul Eggert  <eggert@twinsun.com>
52705
52706         * modules/free: New file.
52707
52708 2003-09-27  Paul Eggert  <eggert@twinsun.com>
52709
52710         * m4/free.m4: New file.
52711
52712 2003-09-27  Paul Eggert  <eggert@twinsun.com>
52713
52714         * lib/minmax.h (MIN, MAX)
52715         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
52716         Omit the special code that used __typeof__, since we worry that
52717         it could be more trouble than it's worth.  See:
52718         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
52719         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
52720
52721         * lib/free.c: New file.
52722
52723 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
52724
52725         Trivial fixes to Makefile.am parts of module listings.
52726         * modules/strstr: Append strstr.h to lib_SOURCES.
52727         * modules/strcase: Likewise, for strcase.h.
52728
52729 2003-09-27  Karl Berry  <karl@gnu.org>
52730
52731         * config/mkinstalldirs: update from automake.
52732
52733 2003-09-26  Paul Eggert  <eggert@twinsun.com>
52734
52735         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
52736         (error_tail): Do not loop, reallocating temporary buffer, since
52737         the output cannot contain more wide characters than the input
52738         contains bytes, the size must be big enough already.  This avoids
52739         one potential size overflow calculation.  Check for size overflow
52740         when calculating temporary buffer size.  Free temporary buffer
52741         when done, if it was allocated with malloc; this plugs a memory
52742         leak.  Remove casts from void * to pointers, that are no longer
52743         needed now that we're assuming C89 or better.
52744
52745         Merge error changes from glibc.
52746
52747         * lib/error.c, error.h: Update copyright notice header to match glibc.
52748         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
52749         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
52750         Disable cancellation while printing error.
52751         * lib/error.h: Prepend __ to parameter names.
52752
52753 2003-09-26  Jim Meyering  <jim@meyering.net>
52754
52755         * lib/error.c (error_tail): Move some declarations
52756         into inner scope where the local variables are used.
52757
52758 2003-09-26  Bruno Haible  <bruno@clisp.org>
52759
52760         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
52761         stpncpy().
52762         Don't define stpncpy through config.h; it's now done through stpncpy.h.
52763
52764 2003-09-26  Bruno Haible  <bruno@clisp.org>
52765
52766         * lib/stpncpy.h (gnu_stpncpy): New declaration.
52767         (stpncpy): Define as alias for gnu_stpncpy.
52768         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
52769
52770 2003-09-25  Simon Josefsson  <jas@extundo.com>
52771
52772         * lib/xgetdomainname.h: New file.
52773         * lib/xgetdomainname.c: New file.
52774
52775 2003-09-25  Simon Josefsson  <jas@extundo.com>
52776             Bruno Haible  <bruno@clisp.org>
52777
52778         * modules/getdomainname: New file.
52779         * modules/xgetdomainname: New file.
52780         * MODULES.html.sh (func_all_modules): Add getdomainname,
52781         xgetdomainname.
52782
52783 2003-09-25  Simon Josefsson  <jas@extundo.com>
52784             Bruno Haible  <bruno@clisp.org>
52785
52786         * m4/getdomainname.m4: New file.
52787
52788 2003-09-25  Simon Josefsson  <jas@extundo.com>
52789             Bruno Haible  <bruno@clisp.org>
52790
52791         * lib/getdomainname.h: New file.
52792         * lib/getdomainname.c: New file.
52793
52794 2003-09-25  Karl Berry  <karl@gnu.org>
52795
52796         * lib/argp-fmtstream.c, argp-help.c: update from libc.
52797
52798 2003-09-25  Karl Berry  <karl@gnu.org>
52799
52800         * config/install-sh: update from automake.
52801
52802 2003-09-25  Bruno Haible  <bruno@clisp.org>
52803
52804         * modules/version-etc-2: New file, from modules/version-etc with
52805         modifications.
52806         * MODULES.html.sh (func_all_modules): Add version-etc-2.
52807
52808 2003-09-25  Bruno Haible  <bruno@clisp.org>
52809
52810         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
52811         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
52812
52813 2003-09-24  Simon Josefsson  <jas@extundo.com>
52814
52815         * modules/xgethostname: Add xgethostname.h.
52816
52817 2003-09-24  Paul Eggert  <eggert@twinsun.com>
52818
52819         * lib/linebuffer.c (freebuffer): Don't free the argument, just
52820         the buffer associated with the argument.  Bug reported by
52821         Simon Josefsson.
52822
52823 2003-09-24  Paul Eggert  <eggert@twinsun.com>
52824
52825         * README: Document assumptions that 'int' is at least 32 bits
52826         wide, that integer arithmetic is 2's complement without overflow,
52827         that there are no holes in integer values, that adding sizes of
52828         two nonoverlapping objects can't overflow, and that all-bits-zero
52829         yields scalar zero.  Fix spelling and capitalization typos.
52830
52831 2003-09-19  Karl Berry  <karl@gnu.org>
52832
52833         * lib/argp.h: update from libc.
52834
52835 2003-09-17  Paul Eggert  <eggert@twinsun.com>
52836
52837         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
52838         to avoid spurious warnings like "AC_RUN_IFELSE was called before
52839         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
52840
52841 2003-09-17  Paul Eggert  <eggert@twinsun.com>
52842
52843         * gnulib-tool: Use "test -h", not "test -L", for portability
52844         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
52845         (tags_regexp): Remove, since \| doesn't conform to POSIX.
52846         (sed_extract_prog): Issue s commands one-by-one, rather than
52847         using \| in one s command.
52848
52849 2003-09-16  Paul Eggert  <eggert@twinsun.com>
52850
52851         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
52852         input error, instead of returning NULL the next time we are called
52853         (and therefore losing track of errno).
52854
52855 2003-09-16  Bruno Haible  <bruno@clisp.org>
52856
52857         * gnulib-tool (func_create_testdir): Warn about duplicated
52858         dependencies.
52859
52860 2003-09-15  Paul Eggert  <eggert@twinsun.com>
52861
52862         * modules/argmatch, modules/fatal, modules/obstack,
52863         modules/xalloc, modules/xgethostname: Sort dependencies by
52864         importance, not alphabetically.
52865
52866 2003-09-15  Paul Eggert  <eggert@twinsun.com>
52867
52868         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
52869         fails, so that the caller gets the proper errno.
52870
52871         * lib/readutmp.c (read_utmp): Likewise.
52872         Check for fstat error.  Close stream and free storage
52873         when failing.
52874
52875 2003-09-14  Karl Berry  <karl@gnu.org>
52876
52877         * config/srclist.txt (strdup.c): disable for c89 changes.
52878
52879 2003-09-14  Jim Meyering  <jim@meyering.net>
52880
52881         * lib/getloadavg.c: Correct cpp indentation.
52882         * lib/strdup.c: Likewise.
52883         * lib/vasnprintf.c: Likewise.
52884
52885 2003-09-14  Bruno Haible  <bruno@clisp.org>
52886
52887         * modules/fwriteerror: New file.
52888         * MODULES.html.sh (func_all_modules): Add fwriteerror.
52889
52890 2003-09-14  Bruno Haible  <bruno@clisp.org>
52891
52892         * lib/fwriteerror.h: New file.
52893         * lib/fwriteerror.c: New file.
52894
52895 2003-09-12  Paul Eggert  <eggert@twinsun.com>
52896
52897         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
52898         modules/xgethostname, modules/xalloc: Depend on exit.
52899
52900 2003-09-12  Paul Eggert  <eggert@twinsun.com>
52901
52902         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
52903
52904         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
52905         and AC_MINIX, too, so that their extensions are available.
52906
52907         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
52908         This macro has been superseded by gl_BACKUPFILE.
52909
52910         More patches to assume C89 or better.
52911
52912         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
52913
52914         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
52915         unconditionally.
52916         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
52917         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
52918         Include <string.h>, <stdlib.h> unconditionally.
52919         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
52920         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
52921         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
52922         headers or for string.h.
52923         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
52924         or strtoul.
52925
52926         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
52927         headers.
52928         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
52929         * m4/userspec.m4 (gl_USERSPEC): Likewise.
52930         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
52931         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
52932         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
52933         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
52934         memcpy, memset.
52935         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
52936         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
52937         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
52938         strtol.
52939         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
52940         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
52941         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
52942         strtoul.
52943
52944 2003-09-12  Paul Eggert  <eggert@twinsun.com>
52945
52946         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
52947         * lib/obstack.c [!defined _LIBC]: Likewise.
52948         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
52949         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
52950         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
52951
52952         More changes to assume C89 or better.
52953
52954         * lib/error.c (error_tail): Assume vprintf.
52955
52956         * lib/argmatch.c (getenv): Remove decl.
52957         * lib/progreloc.c (get_full_program_name): Define via prototype.
52958         * lib/setenv.c (clearenv): Likewise.
52959         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
52960         needed.
52961         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
52962         (malloc, memcpy): Remove decls.
52963         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
52964         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
52965         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
52966         (memcpy): Remove macro.
52967         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
52968         (__P): Remove.  All uses removed.
52969         (PTR): Remove.  All uses changed to void *.
52970         (CHAR_BIT, NULL): Remove.
52971         (spaces, zeros, memset_space, memset_zero)
52972         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
52973         Remove.
52974         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
52975         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
52976         Define with prototype.
52977         Remove now-unnecessary prototype decl.
52978         (extra_args_spec): Assume ANSI C.  All uses changed.
52979         (extra_args_spec_iso): Remove.
52980         (my_strftime, emacs_strftimeu): Define via prototype.
52981         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
52982         unconditionally.
52983         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
52984         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
52985         (strtoul, strtol): Remove decls.
52986         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
52987         LONG_MAX): Remove.
52988         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
52989         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
52990         (LOCALE_PARAM_PROTO): New macro.
52991         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
52992         (INTERNAL (strtol), strtol): Define with a prototype.
52993         (PARAMS): Remove.  All uses removed.
52994         * lib/tempname.c: Include <string.h> unconditionally.
52995         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
52996         * lib/xgethostname.c (main): Define with a prototype.
52997         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
52998         Include <stdlib.h> unconditionally.
52999         (calloc, malloc, realloc, free): Remove decls.
53000         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
53001         Include <stdlib.h> unconditionally.  Sort include file names.
53002         (strtod): Remove.
53003         (xstrtod): Define with a prototype.
53004         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
53005         (strtol, strtoul): Remove decls.
53006
53007 2003-09-11  Paul Eggert  <eggert@twinsun.com>
53008
53009         More patches to assume C89 or better.
53010         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
53011         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
53012         string.h, memchr, STDC_HEADERS.
53013
53014 2003-09-11  Paul Eggert  <eggert@twinsun.com>
53015
53016         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
53017         Include <stdlib.h>, <string.h> unconditionally.
53018         Remove now-unnecessary cast to char *.
53019         * lib/strnlen.c: Include <string.h> unconditionally.
53020         * lib/yesno.c (yesno): Define with a prototype.
53021
53022 2003-09-11  Bruno Haible  <bruno@clisp.org>
53023
53024         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
53025
53026 2003-09-10  Jim Meyering  <jim@meyering.net>
53027
53028         * lib/error.c: Correct indentation of cpp directives.
53029
53030 2003-09-10  Bruno Haible  <bruno@clisp.org>
53031
53032         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
53033         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
53034         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
53035         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
53036         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
53037         <stdlib.h> and <string.h> checks.
53038         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
53039         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
53040
53041 2003-09-10  Bruno Haible  <bruno@clisp.org>
53042
53043         * lib/strcspn.c: Include <string.h> unconditionally.
53044         * lib/strpbrk.c: Include <string.h> unconditionally.
53045         * lib/strstr.c: Include <string.h> unconditionally.
53046         * lib/unicodeio.c: Include <string.h> unconditionally.
53047         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
53048         * lib/unsetenv.c: Likewise.
53049         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
53050         * lib/yesno.c: Include <stdlib.h> unconditionally.
53051         (rpmatch): Add prototype.
53052
53053 2003-09-09  Paul Eggert  <eggert@twinsun.com>
53054
53055         More patches to assume C89 or better.
53056         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
53057         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
53058         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
53059         or for string.h.
53060         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
53061         stdlib.h.
53062         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
53063         C headers.
53064         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
53065         string.h.
53066         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
53067         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
53068         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
53069         or for string.h.
53070         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
53071         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
53072         C headers.
53073         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
53074         memcpy.
53075         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
53076         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
53077         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
53078         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
53079         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
53080         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
53081         string.h, free.
53082         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
53083         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
53084         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
53085         C headers, or for string.h.
53086         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
53087         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
53088         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
53089         headers, memory.h, stdlib.h, string.h, strings.h.
53090         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
53091         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
53092         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
53093         strchr.
53094         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
53095         headers, memory.h, string.h.
53096         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
53097         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
53098         free.
53099         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
53100         headers.
53101         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
53102         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
53103         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
53104         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
53105         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
53106
53107 2003-09-09  Paul Eggert  <eggert@twinsun.com>
53108
53109         More K&R removal.
53110
53111         * lib/acosl.c (main): Use a prototype.
53112         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
53113         tanl.c: Likewise.
53114
53115         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
53116
53117         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
53118         (getopt, etopt_long, getopt_long_only, _getopt_internal)
53119         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
53120         with a prototype.
53121         * lib/getopt.c (const): Remove macro.
53122         Include <string.h> unconditionally.
53123         (my_index): Remove; all uses changed to strchr.
53124         (strlen): Remove decl.
53125         (exchange): Remove forward decl; no longer needed.
53126         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
53127         Define with prototype.
53128         * lib/getopt1.c (const): Remove macro.
53129         (getopt_long, getopt_long_only, main): Define with prototype.
53130
53131         * lib/getugroups.c: Include <string.h> unconditionally.
53132
53133         * lib/getusershell.c: Include <stdlib.h> unconditionally.
53134         (getusershell, setusershell, endusershell, readname, main):
53135         Define with prototypes.
53136
53137         * lib/group-member.c: Include group-member.h first.
53138         Include <stdlib.h> unconditionally.
53139
53140         * lib/hard-locale.c: Include hard-locale.h first.
53141         Include <stdlib.h>, <string.h> unconditionally.
53142
53143         * lib/hash.c (free, malloc): Remove decls.
53144         Include <stdlib.h> unconditionally.
53145
53146         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
53147         (getenv): Do not declare.
53148
53149         * lib/idcache.c: Include <string.h> unconditionally.
53150
53151         * lib/long-options.c: Include long-options.h first, to test interface.
53152         Include <stdlib.h> unconditionally.
53153
53154         * lib/makepath.c: Include makepath.h first, to test interface.
53155         Include <stdlib.h> and <string.h> unconditionally.
53156
53157         * lib/linebuffer.c: Include <stdlib.h>.
53158         (free): Remove decl.
53159
53160         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
53161         stddef.h. rpl_malloc returns void *, not char *.
53162         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
53163         prototype.
53164
53165         * lib/md5.h: Include <limits.h> unconditionally.
53166         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
53167         (__P): Remove; all uses removed.
53168         * lib/md5.c: Include "md5.h" first.
53169         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
53170         md5_buffer, md5_process_bytes, md5_process_block):
53171         Define with prototypes.
53172         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
53173         * lib/sha.c: Include "sha.h" first.
53174         Include <stdlib.h>, <string.h> unconditionally.
53175
53176         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
53177         * lib/memcmp.c (__ptr_t): Likewise.
53178         * lib/memrchr.c (__ptr_t): Likewise.
53179         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
53180         Include <string.h> unconditionally.
53181         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
53182         * lib/memchr.c: Include <stdlib.h> unconditionally.
53183         * lib/memchr.c (LONG_MAX): Remove.
53184         * lib/memrchr.c (LONG_MAX): Likewise.
53185         * lib/memchr.c (__memchr): Define via a prototype.
53186         * lib/memrchr.c (__memrchr): Likewise.
53187         * lib/memcmp.c (__P): Remove, and remove all uses.
53188         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
53189         Remove forward decls; no longer needed.
53190         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
53191         Use types required by C89 in prototype.
53192
53193         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
53194         * lib/savedir.c: Likewise.
53195         * lib/mkdir.c (free): Remove decl.
53196         * lib/rmdir.c (rmdir): Define with a prototype.
53197         * lib/savedir.c: Include savedir.h first, to test interface.
53198
53199         * lib/mktime.c (STDC_HEADERS): Remove.
53200         Include <stdlib.h>, <string.h> unconditionally.
53201
53202         * lib/modechange.c: Include <stdlib.h> unconditionally.
53203         (malloc): Remove decl.
53204
53205         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
53206         (free): Remove decl.
53207
53208         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
53209         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
53210         (This type really should be intptr_t, but that's a C99ism.)
53211         (_obstack_memcpy): Remove: all uses changed to memcpy.
53212         Include <string.h> unconditionally.
53213         (struct obstack): Assume __STDC__ for types of members
53214         chunkfun, freefun, extra_arg.
53215         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
53216         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
53217         obstack_begin, obstack_specify_allocation,
53218         obstack_specify_allocation_with_arg, obstack_chunkfun,
53219         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
53220         Remove unprototyped decls and the macros that use them.
53221         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
53222         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
53223         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
53224         (defined __STDC__ && __STDC__)]:
53225         Remove nonprototyped code.
53226         Include <stdlib.h> unconditionally.
53227         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
53228         _obstack_allocated_p, _obstack_free, obstack_free,
53229         _obstack_memory_used, print_and_abort):
53230         Define using prototypes.
53231         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
53232         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
53233         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
53234         obstack_next_free, obstack_object_size, obstack_room) [0]:
53235         Remove unused, unprototyped code.
53236
53237         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
53238
53239         * lib/physmem.c (physmem_total, physmem_available, main): Define
53240         with prototypes.
53241
53242         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
53243         (main): Define with a prototype.
53244
53245         * lib/posixver.c (getenv): Remove decl.
53246
53247         * lib/putenv.c (malloc): Returns void *, not char *.
53248         Include <string.h> unconditionally.
53249         (strchr, memcpy, NULL): Do not define.
53250
53251         * lib/readtokens.c: Include readtokens.h first, to test interface.
53252         Include <stdlib.h>, <string.h> unconditionally.
53253         (init_tokenbuffer): Define with a prototype.
53254
53255         * lib/regex.c (PARAMS): Remove.  All uses removed.
53256         All uses of _RE_ARGS removed, too.
53257         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
53258         unconditionally.
53259         (bzero): Assume memset exists.
53260         (memcmp, memcpy, NULL): Remove.
53261         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
53262         char, or assignments to local vars of type signed char.
53263         (init_syntax_once, PREFIX(extract_number_and_incr),
53264         PREFIX(print_partial_compiled_pattern),
53265         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
53266         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
53267         PREFIX(regex_grow_registers), PREFIX(regex_compile),
53268         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
53269         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
53270         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
53271         wcs_compile_range, byte_compile_range, truncate_wchar,
53272         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
53273         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
53274         count_mbs_length, wcs_re_match_2_internal,
53275         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
53276         PREFIX(alt_match_null_string_p),
53277         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
53278         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
53279         regfree, PREFIX(extract_number)): Define with prototype.  Remove
53280         now-unnecessary declaration, if any.
53281         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
53282         regcomp, regexec):
53283         Remove now-unnecessary casts among pointer types.
53284         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
53285
53286         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
53287         (free): Remove decl.
53288
53289         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
53290
53291         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
53292         (free): Remove decl.
53293
53294         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
53295         * lib/xgetcwd.c: Likewise.
53296
53297         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
53298         (free): Remove decl.
53299
53300         * lib/strchrnul.c (strchrnul): Define with a prototype.
53301         Fix bug: c_in was not converted to char before searching.
53302
53303         The following changes are not K&R related:
53304
53305         * lib/group-member.h: Include <sys/types.h>, so that this file is
53306         self-contained.
53307         * lib/makepath.h: Likewise.
53308
53309         * lib/getusershell.c (readname, default_index, line_size, readname):
53310         Use size_t, not int, for sizes.
53311         (readname): If the size overflows, report an error instead of
53312         looping forever.
53313
53314 2003-09-09  Paul Eggert  <eggert@twinsun.com>
53315
53316         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
53317         libc.
53318
53319 2003-09-09  Paul Eggert  <eggert@twinsun.com>
53320
53321         * README: New section: portability guidelines.
53322
53323 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
53324
53325         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
53326         C89 spec.
53327
53328 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
53329
53330         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
53331
53332 2003-09-08  Paul Eggert  <eggert@twinsun.com>
53333
53334         Assume C89 or better; remove K&R cruft.
53335         A few of these changes were first proposed by Derek Robert Price
53336         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
53337
53338         * lib/addext.c: Include <string.h> unconditionally.
53339         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
53340         Don't declare getenv or malloc.
53341
53342         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
53343         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
53344         (NULL): Remove.
53345         (find_stack_direction, alloca): Use prototypes.
53346
53347         * lib/atexit.c (atexit): Define using a prototype.
53348
53349         * lib/basename.c, dirname.c, stripslash.c:
53350         Include <string.h> unconditionally.
53351
53352         * lib/bcopy.c: Include <stddef.h>.
53353         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
53354
53355         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
53356
53357         * lib/error.h (error, error_at_line, error_print_progname)
53358         [! (defined (__STDC__) && __STDC__)]: Remove decls.
53359         * lib/error.c: Include error.h first, to check interface.
53360         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
53361         (VA_START): Remove; all uses changeed to va_start.
53362         (exit, strerror): Remove decls.
53363         (error_print_progname): Prototype uncondionally.
53364         Don't include <errno.h>; no longer needed.
53365         (private_strerror): Remove.
53366         (error_tail): Always define.
53367         (error, error_at_line): Assume C89 or better; always use prototypes.
53368         * lib/fatal.c: Include "fatal.h" first, to test interface.
53369         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
53370         (VA_START): Remove; all uses changed to va_start.
53371         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
53372         this case.
53373         (exit): Remove decl.
53374         (fatal): Prototype unconditionally.  Assume va_start works.
53375         Abort at end, to pacify gcc.
53376
53377         * lib/euidaccess.c (main): Define with a prototype.
53378
53379         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
53380
53381         * lib/exitfail.c: Include <stdlib.h> unconditionally.
53382
53383         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
53384         prototypes.
53385         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
53386         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
53387         (getenv): Remove decl.
53388         (fnmatch): Define using a prototype.
53389         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
53390         (FCT): Define using a prototype.
53391
53392         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
53393
53394         * lib/gethostname.c: Include <stddef.h>.
53395         (gethostname): Define with prototype.  Length is size_t, not int.
53396
53397 2003-09-08  Paul Eggert  <eggert@twinsun.com>
53398
53399         Assume C89 or better; remove K&R cruft.
53400         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
53401         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
53402         string.h, getenv, malloc.
53403         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
53404         headers.
53405         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
53406         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
53407         do not check for strerror.
53408         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
53409         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
53410         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
53411         do not check for doprnt or vprintf.
53412         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
53413         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
53414
53415 2003-09-08  Paul Eggert  <eggert@twinsun.com>
53416
53417         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
53418         getversion.c should have been removed then, but was accidentally
53419         preserved.
53420
53421         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
53422         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
53423
53424 2003-09-08  Karl Berry  <karl@gnu.org>
53425
53426         * config/config.sub, config.guess, srclistvars.sh: update from savannah
53427                 config, forget about prep.
53428
53429         * config/depcomp, missing: update from automake.
53430
53431 2003-09-07  Paul Eggert  <eggert@twinsun.com>
53432
53433         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
53434         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
53435
53436 2003-09-07  Paul Eggert  <eggert@twinsun.com>
53437
53438         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
53439         copy_tm_result.  Bug reported by Simon Josefsson in
53440         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
53441
53442 2003-09-06  Paul Eggert  <eggert@twinsun.com>
53443
53444         * m4/time_r.m4: New file.
53445         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
53446         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
53447         is. Check for timegm declaration.
53448         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
53449         Do not check for gmtime_r.
53450         Replace mktime if __mktime_internal does not exist and if mktime
53451         hasn't been replaced already.
53452
53453 2003-09-06  Paul Eggert  <eggert@twinsun.com>
53454
53455         * lib/time_r.c, lib/time_r.h: New files.
53456
53457         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
53458         __localtime_r.
53459         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
53460         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
53461
53462         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
53463         __gmtime_r.
53464         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
53465         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
53466         Include <time_r.h>.
53467
53468         * lib/timegm.c: Switch to glibc implementation, with the following
53469         changes:
53470         [defined HAVE_CONFIG_H]: Include <config.h>.
53471         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
53472         (__mktime_internal) [!defined _LIBC]: New decl.
53473         (__gmtime_r) [!defined _LIBC]: New macro and function.
53474         (timegm): Use a prototype, since gnulib assumes C89.
53475         Do not bother declaring tmp to be const, as it's not really usefu.
53476         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
53477         (timegm): Declare only if HAVE_DECL_TIMEGM.
53478
53479 2003-09-06  Paul Eggert  <eggert@twinsun.com>
53480
53481         * MODULES.html.sh (func_all_modules): Add time_r.
53482         * modules/time_r: New file.
53483         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
53484         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
53485
53486 2003-09-03  Paul Eggert  <eggert@twinsun.com>
53487
53488         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
53489         Bug reported by Lute Kamstra in
53490         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
53491
53492         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
53493         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
53494         course with correspondingly smaller numbers for tomorrow and
53495         yesterday.  From Tadayoshi Funaba.  Originally installed into
53496         sh-utils on 1999-08-07, but the patch got lost (I guess during the
53497         coreutils merge?).
53498
53499 2003-08-31  Simon Josefsson  <jas@extundo.com>
53500
53501         * modules/timegm: New file.
53502         * MODULES.html.sh (func_all_modules): Add timegm.
53503
53504 2003-08-31  Simon Josefsson  <jas@extundo.com>
53505
53506         * m4/timegm.m4: New file.
53507
53508 2003-08-31  Simon Josefsson  <jas@extundo.com>
53509
53510         * lib/timegm.h: New file.
53511         * lib/timegm.c: New file.  Based on
53512         wget-1.8.2/src/http.c:mktime_from_utc.
53513
53514 2003-08-31  Karl Berry  <karl@gnu.org>
53515
53516         * lib/argp.h: update from libc.
53517
53518 2003-08-28  Bruno Haible  <bruno@clisp.org>
53519
53520         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
53521         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
53522         followed by '#define fnmatch fnmatch_posix' gives an error.
53523
53524 2003-08-28  Bruno Haible  <bruno@clisp.org>
53525
53526         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
53527         warning on QNX, which defines O_BINARY to 000000.
53528
53529 2003-08-27  Jim Meyering  <jim@meyering.net>
53530
53531         * m4/mkstemp.m4: Require that the system mkstemp be able to create
53532         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
53533         would fail after 32.  Reported by Danny Levinson.  Details here:
53534         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
53535
53536 2003-08-24  Bruno Haible  <bruno@clisp.org>
53537
53538         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
53539         MSVC7 <stdio.h> is included later.
53540
53541 2003-08-22  Simon Josefsson  <jas@extundo.com>
53542
53543         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
53544
53545 2003-08-20  Karl Berry  <karl@gnu.org>
53546
53547         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
53548
53549 2003-08-20  Bruno Haible  <bruno@clisp.org>
53550
53551         * modules/progname: New file.
53552         * MODULES.html.sh (func_all_modules): Add progname.
53553
53554 2003-08-20  Bruno Haible  <bruno@clisp.org>
53555
53556         * lib/progname.h: New file, from GNU gettext.
53557         * lib/progname.c: New file, from GNU gettext.
53558         * lib/progreloc.c: New file, from GNU gettext.
53559
53560 2003-08-19  Jim Meyering  <jim@meyering.net>
53561
53562         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
53563         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
53564
53565 2003-08-19  Bruno Haible  <bruno@clisp.org>
53566
53567         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
53568         more.
53569
53570 2003-08-19  Bruno Haible  <bruno@clisp.org>
53571
53572         * lib/xstrdup.c: Assume <string.h> exists.
53573
53574 2003-08-18  Paul Eggert  <eggert@twinsun.com>
53575
53576         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
53577         in makefile rules.
53578
53579 2003-08-18  Jim Meyering  <jim@meyering.net>
53580
53581         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
53582         * m4/lib-ld.m4: Likewise.
53583
53584 2003-08-18  Jim Meyering  <jim@meyering.net>
53585
53586         * lib/setenv.h: Indent nested cpp directive.
53587         * lib/vasnprintf.c: Remove trailing blanks.
53588
53589 2003-08-17  Simon Josefsson  <jas@extundo.com>
53590
53591         * modules/xstrndup: New file.
53592         * MODULES.html.sh (func_all_modules): Add xstrndup.
53593
53594 2003-08-17  Simon Josefsson  <jas@extundo.com>
53595
53596         * modules/argp: Fix autoconf macro name. Add more dependencies.
53597
53598 2003-08-17  Simon Josefsson  <jas@extundo.com>
53599
53600         * m4/xstrndup.m4: New file.
53601
53602 2003-08-17  Simon Josefsson  <jas@extundo.com>
53603
53604         * m4/argp.m4: New file.
53605
53606 2003-08-17  Simon Josefsson  <jas@extundo.com>
53607             Bruno Haible  <bruno@clisp.org>
53608
53609         * lib/xstrndup.h: New file.
53610         * lib/xstrndup.c: New file.
53611
53612 2003-08-17  Bruno Haible  <bruno@clisp.org>
53613
53614         * modules/strndup (Files, Include): Add lib/strndup.h.
53615
53616 2003-08-17  Bruno Haible  <bruno@clisp.org>
53617
53618         * modules/euidaccess (Files): Add lib/euidaccess.h.
53619
53620 2003-08-17  Bruno Haible  <bruno@clisp.org>
53621
53622         * lib/strndup.h: New file.
53623
53624 2003-08-17  Bruno Haible  <bruno@clisp.org>
53625
53626         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
53627         like AC_GNU_SOURCE.
53628         * modules/extensions (configure.ac): Comment out the invocation of
53629         gl_USE_SYSTEM_EXTENSIONS.
53630
53631 2003-08-16  Paul Eggert  <eggert@twinsun.com>
53632
53633         Merges from coreutils, etc.
53634         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
53635         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
53636         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
53637         fixing a typo.
53638         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
53639         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
53640
53641 2003-08-16  Paul Eggert  <eggert@twinsun.com>
53642
53643         Document merge from coreutils.
53644         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
53645         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
53646         * modules/utime: Add m4/utimes-null.m4.
53647
53648 2003-08-16  Paul Eggert  <eggert@twinsun.com>
53649
53650         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
53651         space, undoing this 2003-08-12 change:
53652         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
53653
53654 2003-08-16  Paul Eggert  <eggert@twinsun.com>
53655
53656         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
53657         strtoul.c from libc, undoing this 2003-08-12 change:
53658         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
53659
53660 2003-08-16  Jim Meyering  <jim@meyering.net>
53661
53662         Merges from coreutils.
53663         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
53664         prefix.  Adjust cache variables similarly.  Create 500 rather than
53665         just 300 files, to exercise bug on Darwin6.5, too.
53666         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
53667         $missing_dir.
53668         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
53669         AM_SYS_POSIX_TERMIOS.
53670         Reported by mkc@mathdogs.com.
53671         Also change use of $am_cv_sys_posix_termios
53672         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
53673         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
53674         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
53675         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
53676         in /proc/mounts until it finds one with matching device number.  This
53677         is unnecessary when the FILE argument *is* a mount point.  No stat call
53678         is necessary in that case.  So, disable the statvfs-testing code on
53679         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
53680         as RedHat bug# 84846.
53681         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
53682         to 1MB, so as not to render systems with no stack size limit (e.g.,
53683         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
53684         Include <unistd.h>.  On some systems,
53685         it is required for the definition of _SC_PAGESIZE.
53686
53687 2003-08-16  Jim Meyering  <jim@meyering.net>
53688
53689         Merge from coreutils.
53690         * lib/xstrtoimax.c: #else #if -> #elif.
53691         * lib/xstrtoumax.c: Likewise.
53692
53693 2003-08-16  Jim Meyering  <jim@meyering.net>
53694
53695         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
53696         * m4/utimes.m4: Removed.
53697         * m4/utimes-null.m4: Renamed from utimes.m4.
53698
53699         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
53700         to 1MB, so as not to render systems with no stack size limit (e.g.,
53701         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
53702         Include <unistd.h>.  On some systems,
53703         it is required for the definition of _SC_PAGESIZE.
53704
53705 2003-08-16  Jim Meyering  <jim@meyering.net>
53706         and Paul Eggert  <eggert@cs.ucla.edu>
53707
53708         Merges from coreutils, etc.
53709
53710         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
53711         using the latest version from cvs.  This avoids problems with #line
53712         directives using a vendor (Sun) compiler.
53713         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
53714         Don't set GETGROUPS_LIB here; now it's
53715         done via getgroups.m4's wrapper function.
53716         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
53717         rather than just in sh-util/configure.in, so that the
53718         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
53719         same.
53720         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
53721         AC_FUNC_GETLOADAVG where to find getloadavg.c.
53722         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
53723         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
53724         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
53725         Remove code that is now done by the newly-required macros.
53726         Append $(EXEEXT) to DF_PROG.
53727         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
53728         Do not invoke or require the following here,
53729         since prereq.m4 or some gnulib .m4 now does this for us:
53730         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
53731         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
53732         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
53733         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
53734         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
53735         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
53736         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
53737         AC_FUNC_OBSTACK.
53738         Do not replace the following functions, as this is now the job
53739         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
53740         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
53741         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
53742         atexit getpass, strdup, getpagesize.
53743         Replace 'raise'.
53744         Do not check for the following functions, as this is now the job
53745         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
53746         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
53747         setregid.
53748         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
53749         Check for sys/sysctl.h.
53750         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
53751         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
53752         of checking for ssize_t ourselves.
53753
53754         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
53755         Require every macro that gnulib/modules/* suggests for us.
53756         (jm_PREREQ_ADDEXT): New macro.
53757         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
53758         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
53759
53760         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
53761         (gl_PHYSMEM): Use it.
53762         Also check for `table' function.
53763         Check for new headers and functions.
53764         Add check for sys/sysmp.h.
53765         With suggestions from Kaveh Ghazi.
53766         Ignore headers that are present but cannot be compiled.  This
53767         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
53768         C 5.4.
53769
53770 2003-08-15  Paul Eggert  <eggert@twinsun.com>
53771
53772         Document merge from coreutils.
53773         * modules/userspec: Depend on posixver.
53774         * modules/strftime: Depend on tzset.
53775
53776 2003-08-15  Paul Eggert  <eggert@twinsun.com>
53777
53778         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
53779         rather than tab, after '#' in shell-script copyright notices.
53780         Suggested by Bruno Haible.
53781
53782 2003-08-15  Paul Eggert  <eggert@twinsun.com>
53783
53784         * config/srclist-update: Use three spaces, rather than tab, after '#'
53785         in shell-script copyright notices.  Suggested by Bruno Haible.
53786         Remove unnecessary parenthesization in regular expression.
53787
53788 2003-08-15  Jim Meyering  <jim@meyering.net>
53789
53790         Merge from coreutils.
53791         * lib/xgethostname.c: Include <stdlib.h>.
53792         (xghostname): Don't exit for anything other than memory-related
53793         failure; just return NULL.
53794         * lib/userspec.c: Include "posixver.h".
53795         (parse_user_spec): Accept `.' as a separator only
53796         in pre-POSIX-200112 mode.
53797         * lib/strtoimax.c: Use #elif rather than #else #if.
53798         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
53799         Remove function, now that we can rely on a working tzset function.
53800         [!_LIBC]: Ensure that the required autoconf test has been run.
53801         [!defined _NL_CURRENT && HAVE_STRFTIME]:
53802         Use underlying_strftime for %r.
53803         * lib/sha.c: Merge in some clean-up and optimization changes from
53804         glibc.
53805         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
53806         Ensure that it is a multiple of 64.
53807         Rearrange loop exit tests so as to avoid performing an
53808         additional fread after encountering an error or EOF.
53809         * lib/realloc.c: Update copyright date.
53810
53811 2003-08-15  Jim Meyering  <jim@meyering.net>
53812         and Paul Eggert  <eggert@twinsun.com>
53813
53814         Merge from coreutils.
53815         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
53816         member but strut utmpx does not.  Needed for AIX 4.3.3.
53817         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
53818
53819 2003-08-15  Jim Meyering  <jim@meyering.net>
53820         and Paul Eggert  <eggert@cs.ucla.edu>
53821
53822         Merges from coreutils, etc.
53823         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
53824         Require gl_FUNC_TZSET_CLOBBER.
53825         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
53826         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
53827         members.
53828
53829 2003-08-14  Paul Eggert  <eggert@twinsun.com>
53830
53831         Help the merge from coreutils.
53832         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
53833         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
53834         * m4/tzset.m4: Use it too.
53835
53836 2003-08-14  Paul Eggert  <eggert@twinsun.com>
53837
53838         * modules/tzset: New file.
53839
53840 2003-08-14  Jim Meyering  <jim@meyering.net>
53841
53842         Merges from coreutils.
53843         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
53844         variable names, rather than @FNMATCH_H@.
53845         * modules/alloca: Likewise for $(ALLOCA_H).
53846
53847         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
53848         the three copies of the literal target, `fnmatch.h'.
53849         * modules/alloca (alloca.h): Likewise.
53850
53851 2003-08-14  Jim Meyering  <jim@meyering.net>
53852
53853         Merge from coreutils.
53854         * m4/tzset.m4: New file.
53855         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
53856         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
53857         otherwise, AIX 5.1 systems would end up using the latter.
53858         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
53859         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
53860         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
53861         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
53862
53863 2003-08-14  Jim Meyering  <jim@meyering.net>
53864
53865         Merge from coreutils.
53866         * lib/obstack.h: Whitespace changes.
53867         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
53868         and xcalloc return values.
53869         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
53870         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
53871         hang on OSF/1 5.1 for DIR on both local and remote file systems.
53872         Reported by (and fix confirmed by) Nelson H. F. Beebe.
53873         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
53874         error from mntctl.
53875         Use mntctl's return value to drive the entry-processing loop, since
53876         we can't rely on the value of the vmt_length member in the last
53877         entry.  On some systems doing so could result in exhausting
53878         virtual memory.  Based in part on a patch from Mike Jetzer.
53879
53880 2003-08-14  Jim Meyering  <jim@meyering.net>
53881         and Paul Eggert  <eggert@twinsun.com>
53882
53883         Merges from coreutils, plus other fixes.
53884         * lib/physmem.c: Merge in portability changes from gcc/libiberty
53885         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
53886         for credits and details.  Thanks to Kaveh Ghazi for helping
53887         to keep these files in sync.
53888         (ARRAY_SIZE): Define it.
53889         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
53890         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
53891         (memcasecmp): Don't assume size_t fits in unsigned int.
53892         Remove casts and duplicate code.
53893         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
53894         (memcpy): Remove definition.
53895         Merge in some clean-up and optimization changes from glibc.
53896         [BLOCKSIZE]: Move definition to top of file.
53897         Ensure that it is a multiple of 64.
53898         Rearrange loop exit tests so as to avoid performing an
53899         additional fread after encountering an error or EOF.
53900         * lib/md5.h (md5_uintptr): Define.
53901         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
53902         return to the initial working directory.  Preserve errno
53903         for caller.
53904         * lib/idcache.c: Include "xalloc.h".
53905         (xmalloc, xrealloc): Remove decls.
53906         (getuser): Remove casts no longer required in C89.
53907         * lib/human.c: Include stdio.h, for sprintf.
53908         * lib/group-member.c: Include "xalloc.h".
53909         (xmalloc, xrealloc): Remove decls.
53910         (get_group_info): Remove casts no longer required in C89.
53911         * lib/getusershell.c (readname): Remove casts no longer required in
53912         C89.
53913         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
53914         * lib/getline.c: Whitespace fix, from coreutils.
53915
53916 2003-08-13  Paul Eggert  <eggert@twinsun.com>
53917
53918         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
53919         Check for isascii.
53920
53921         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
53922         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
53923         Undo previous (whitespace-only) change.
53924
53925 2003-08-13  Paul Eggert  <eggert@twinsun.com>
53926
53927         * lib/exclude.c: Include <ctype.h>
53928         (IN_CTYPE_DOMAIN): New macro.
53929         (is_space): New fn.
53930         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
53931         and empty lines.
53932
53933         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
53934         Undo previous (whitespace-only) change.
53935
53936 2003-08-13  Paul Eggert  <eggert@twinsun.com>
53937
53938         * config/srclist-update: Change update back to the old behavior,
53939         leaving whitespace alone.  Use one 'sed' command rather than a
53940         pipeline.
53941         (fixlicense): Now a variable, not a function.
53942         (remove_trailing_blanks): Remove.
53943         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
53944         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
53945         Undo previous (whitespace-only) change.
53946
53947 2003-08-12  Paul Eggert  <eggert@twinsun.com>
53948
53949         Merge from coreutils.
53950         * modules/euidaccess: Add lib_SOURCES, include for new
53951         file euidaccess.h
53952
53953 2003-08-12  Paul Eggert  <eggert@twinsun.com>
53954
53955         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
53956         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
53957         Normalize leading white space and remove trailing white space.
53958
53959         Merge from coreutils
53960         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
53961
53962         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
53963         0.12.1.  These files are now being upgraded automatically by
53964         ../config/srclist-update.
53965
53966 2003-08-12  Paul Eggert  <eggert@twinsun.com>
53967
53968         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
53969         Normalize leading white space and remove trailing white space.
53970         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
53971         notice, as per ../config/srclist-update.
53972
53973         Merge from coreutils.
53974         * lib/euidaccess.h: New file.
53975         * lib/euidaccess.c: Include it.
53976         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
53977         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
53978         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
53979
53980 2003-08-12  Paul Eggert  <eggert@twinsun.com>
53981
53982         * config/srclist-update: Add copyright notice.
53983         (remove_id_lines, remove_trailing_blanks): New constants.
53984         (fixfile): Use them to normalize spacing a bit in copied files.
53985         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
53986         Normalize leading white space and remove trailing white space.
53987
53988         * config/texinfo.tex: Sync with texinfo.
53989
53990         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
53991         strtoul.c from libc, to merge coreutils whitespace changes.
53992
53993         * config/srclist.txt: Get the following m4 files from gettext:
53994         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
53995         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
53996         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
53997         wint_t.m4.
53998
53999 2003-08-12  Karl Berry  <karl@gnu.org>
54000
54001         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
54002         been made.
54003
54004 2003-08-11  Paul Eggert  <eggert@twinsun.com>
54005
54006         * modules/gnu-source, m4/gnu-source.m4:
54007         Remove; we're assuming Autoconf 2.54 or later now.
54008         Suggested by Bruno Haible.
54009         * MODULES.html.sh (func_all_modules): Remove gnu-source.
54010
54011 2003-08-11  Bruno Haible  <bruno@clisp.org>
54012
54013         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
54014
54015 2003-08-11  Bruno Haible  <bruno@clisp.org>
54016
54017         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
54018         (vasnprintf): Use it instead of wcslen.
54019
54020 2003-08-11  Bruno Haible  <bruno@clisp.org>
54021
54022         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
54023         value to ensure that _Bool promotes to int. Use #define for _Bool when
54024         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
54025
54026 2003-08-10  Karl Berry  <karl@gnu.org>
54027
54028         * lib/regex.h: update from libc (whitespace fix).
54029
54030 2003-08-09  Paul Eggert  <eggert@twinsun.com>
54031
54032         Merge some files from coreutils.  These changes were
54033         originally made by Jim Meyering.
54034         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
54035         many older Unixes require this.
54036         * lib/alloca.c (alloca): Remove cast to argument of free;
54037         no longer needed in C89.
54038         * lib/alloca_.h, regex.h: Fix white space to match
54039         what GNU indent does.
54040
54041 2003-08-09  Paul Eggert  <eggert@twinsun.com>
54042
54043         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
54044         apparently Emacs's Unicode mode got confused before my 2003-08-05
54045         checkin.
54046
54047 2003-08-08  Paul Eggert  <eggert@twinsun.com>
54048
54049         * m4/extensions.m4: New file.
54050         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
54051         Require gl_USE_SYSTEM_EXTENSIONS.
54052         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
54053         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
54054
54055 2003-08-08  Paul Eggert  <eggert@twinsun.com>
54056
54057         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
54058         * modules/extensions, modules/gnu-source: New files.
54059         * modules/timespec, modules/unlocked-io: Depend on extensions.
54060
54061 2003-08-07  Paul Eggert  <eggert@twinsun.com>
54062
54063         * modules/restrict: New file.
54064         * MODULES.html.sh (func_all_modules): Add restrict.
54065         * modules/regex: Depend on restrict.
54066
54067 2003-08-07  Paul Eggert  <eggert@twinsun.com>
54068
54069         * m4/restrict.m4: New file.
54070         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
54071
54072 2003-08-07  Bruno Haible  <bruno@clisp.org>
54073
54074         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
54075         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
54076
54077 2003-08-07  Bruno Haible  <bruno@clisp.org>
54078
54079         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
54080         makes the module 'getndelim2' compatible with the module 'getline'.
54081
54082 2003-08-05  Paul Eggert  <eggert@twinsun.com>
54083
54084         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
54085         byte with "\201" to avoid glitches when editing that source file
54086         with multi-gnome-terminal.
54087
54088 2003-08-05  Paul Eggert  <eggert@twinsun.com>
54089
54090         * lib/bumpalloc.h: Remove.
54091
54092 2003-08-05  Paul Eggert  <eggert@twinsun.com>
54093
54094         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
54095         * modules/bumpalloc: Remove.
54096
54097 2003-08-04  Paul Eggert  <eggert@twinsun.com>
54098
54099         * lib/getloadavg.c: Change copyright notice and spacing to conform to
54100         GNU coding style.
54101
54102         Merge from coreutils.
54103         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
54104         1. From glibc.
54105         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
54106         from Karl Berry, implemented by Jim Meyering.
54107         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
54108         from Dmitry V. Levin.
54109         Remove anachronistic cast of xrealloc.
54110         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
54111         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
54112         type. Otherwise, it wouldn't compile with at least /bin/cc on
54113         ymp-cray-unicos9.0.2.X.
54114         Combine two mostly-identical uses of alloca into one.
54115         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
54116
54117 2003-08-04  Dave Love  <d.love@dl.ac.uk>
54118
54119         [From Emacs.]
54120
54121         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
54122         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
54123         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
54124         obsolete NLIST_NAME_UNION.
54125         [__GNU__]: Undef BSD and FSCALE.
54126         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
54127
54128 2003-08-03  Paul Eggert  <eggert@twinsun.com>
54129
54130         * lib/stdbool_.h (_Bool): Make it signed char, instead of
54131         an enum type, so that it's guaranteed to promote to int.  See:
54132         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
54133
54134 2003-08-03  Karl Berry  <karl@gnu.org>
54135
54136         * config/depcomp: update from automake.
54137
54138 2003-07-31  Paul Eggert  <eggert@twinsun.com>
54139
54140         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
54141         (strerror): Don't assume that a printable int fits in 14 bytes.
54142
54143 2003-07-31  Bruno Haible  <bruno@clisp.org>
54144
54145         * modules/getpass-gnu: New file.
54146         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
54147
54148 2003-07-31  Bruno Haible  <bruno@clisp.org>
54149
54150         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
54151
54152 2003-07-24  Karl Berry  <karl@gnu.org>
54153
54154         * config/missing: update from automake.
54155
54156 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
54157             Bruno Haible  <bruno@clisp.org>
54158
54159         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
54160         * lib/getline.c (getline, getdelim): Likewise.
54161         Remove _GNU_SOURCE define; now it's defined in config.h through
54162         m4/getline.m4.
54163
54164 2003-07-23  Karl Berry  <karl@gnu.org>
54165
54166         * config/config.sub: update from prep.
54167
54168 2003-07-22  Paul Eggert  <eggert@twinsun.com>
54169
54170         * modules/xalloc (Depends-on): Add exitfail.
54171         * modules/xmemcoll: Likewise.
54172
54173 2003-07-22  Paul Eggert  <eggert@twinsun.com>
54174
54175         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
54176         over-parenthesization in macros.
54177
54178         Sync with coreutils.
54179
54180         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
54181         required by C99.
54182
54183         Use `exit_failure' for xalloc and xmemcoll instead of their own
54184         private exit-failure variables.
54185         * lib/xalloc.h (xalloc_exit_failure): Remove.
54186         * lib/xmalloc.c: Likewise.  Include exitfail.h.
54187         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
54188         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
54189         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
54190         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
54191
54192 2003-07-20  Jim Meyering  <jim@meyering.net>
54193
54194         * modules/closeout (Depends-on): Add exitfail.
54195         Suggestion from Bruno Haible.
54196
54197 2003-07-19  Karl Berry  <karl@gnu.org>
54198
54199         * config/config.sub: update from prep.
54200
54201 2003-07-18  Paul Eggert  <eggert@twinsun.com>
54202
54203         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
54204         Remove.
54205         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
54206         to test that it can stand by itself.  Include "exitfail.h".
54207         Clients should set exit_failure instead.
54208         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
54209
54210 2003-07-18  Bruno Haible  <bruno@clisp.org>
54211
54212         * modules/getndelim2: New file.
54213         * modules/getline: Share files with module getndelim2.
54214         * modules/getnline: Depend on getndelim2 instead of sharing files with
54215         it. Add getnline.c to lib_SOURCES.
54216         * MODULES.html.sh (func_all_modules): Add getndelim2.
54217
54218 2003-07-18  Bruno Haible  <bruno@clisp.org>
54219
54220         * m4/getndelim2.m4: New file.
54221         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
54222         invoke gl_PREREQ_GETNDELIM2.
54223         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
54224         gl_PREREQ_GETNDELIM2.
54225         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
54226         gl_GETNDELIM2.
54227
54228 2003-07-18  Bruno Haible  <bruno@clisp.org>
54229
54230         * lib/getndelim2.h: New file.
54231         * lib/getndelim2.c: Make into a module of its own. Include config.h,
54232         getndelim2.h.
54233         (getndelim2): Make non-static. Change return type to ssize_t.
54234         * lib/getline.h: Change argument names.
54235         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
54236         * lib/getnline.c: Include getndelim2.h.
54237
54238 2003-07-18  Andreas Schwab  <schwab@suse.de>
54239
54240         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
54241
54242 2003-07-17  Karl Berry  <karl@gnu.org>
54243
54244         * config/config.sub: update from prep.
54245
54246 2003-07-17  Bruno Haible  <bruno@clisp.org>
54247
54248         * modules/getnline: New file.
54249         * modules/getline: Add lib/getndelim2.c to source file list.
54250         * MODULES.html.sh (func_all_modules): Add getnline.
54251
54252 2003-07-17  Bruno Haible  <bruno@clisp.org>
54253
54254         * m4/getnline.m4: New file.
54255
54256 2003-07-17  Bruno Haible  <bruno@clisp.org>
54257
54258         * m4/Makefile.am.in: Remove file.
54259         * m4/Makefile.am: Remove file.
54260         * m4/Makefile.in: Remove file.
54261
54262 2003-07-17  Bruno Haible  <bruno@clisp.org>
54263
54264         * lib/getnline.h: New file.
54265         * lib/getnline.c: New file.
54266         * lib/getndelim2.c: New file, extracted from getline.c.
54267         (getndelim2): Renamed from getdelim2, with added nmax argument.
54268         * lib/getline.c: Include getndelim2.c.
54269         (getdelim2): Moved out to getndelim2.c.
54270         (getline, getdelim): Update.
54271
54272 2003-07-17  Bruno Haible  <bruno@clisp.org>
54273
54274         * lib/Makefile.am: Remove file.
54275         * lib/Makefile.in: Remove file.
54276
54277 2003-07-17  Bruno Haible  <bruno@clisp.org>
54278
54279         * configure.in: Remove file.
54280         * Makefile.in: Remove file.
54281
54282 2003-07-17  Bruno Haible  <bruno@clisp.org>
54283
54284         * MODULES.html.sh: Put the </BODY> right before </HTML>.
54285
54286 2003-07-16  Karl Berry  <karl@gnu.org>
54287
54288         * config/srclist-update: was running fixlicense twice, which caused
54289                 texinfo.tex to be nullified for some reason.  Simplify,
54290                 $gplsrc is no longer needed as far as I can see?
54291
54292 2003-07-16  Jim Meyering  <jim@meyering.net>
54293
54294         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
54295
54296 2003-07-15  Paul Eggert  <eggert@twinsun.com>
54297
54298         * config/srclist.txt: Get the following files from gettext-runtime/intl
54299         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
54300         ref-del.sin.  From Bruno Haible.
54301         * config/srclist-update (fixfile): Change grep pattern again, since the
54302         previous fix didn't work (there was another trailing $).  Use
54303         '[$]' to escape the $s.
54304
54305 2003-07-15  Karl Berry  <karl@gnu.org>
54306
54307         * lib/vasnprintf.c: update from gettext.
54308
54309 2003-07-15  Karl Berry  <karl@gnu.org>
54310
54311         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
54312         gets expanded when surrounded by '$'.
54313
54314 2003-07-15  Jim Meyering  <jim@meyering.net>
54315
54316         * modules/save-cwd: Don't depend on error.  From Derek Price.
54317
54318 2003-07-15  Jim Meyering  <jim@meyering.net>
54319
54320         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
54321
54322 2003-07-14  Simon Josefsson  <jas@extundo.com>
54323
54324         * modules/mempcpy: New file.
54325         * MODULES.html.sh (func_all_modules): Add mempcpy.
54326
54327 2003-07-14  Simon Josefsson  <jas@extundo.com>
54328
54329         * m4/mempcpy.m4: New file.
54330
54331 2003-07-14  Simon Josefsson  <jas@extundo.com>
54332
54333         * lib/mempcpy.h: New file.
54334         * lib/mempcpy.c: New file.
54335
54336 2003-07-14  Paul Eggert  <eggert@twinsun.com>
54337
54338         * modules/getdate, modules/posixtm: Depend on mktime.
54339
54340 2003-07-14  Paul Eggert  <eggert@twinsun.com>
54341
54342         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
54343         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
54344         unicodeio.c, unicodeio.h, unlocked-io.h:
54345         Switch from LGPL to GPL.
54346
54347 2003-07-14  Paul Eggert  <eggert@twinsun.com>
54348
54349         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
54350         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
54351         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
54352         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
54353         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
54354         updated automatically by ../config/srclist-update.  This changes
54355         their license from LPGL to GPL.
54356
54357 2003-07-14  Paul Eggert  <eggert@twinsun.com>
54358
54359         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
54360         assumed to refer to the root of the most recent stable gettext version.
54361         * config/srclistvars.sh: Add defaults for eggert.
54362         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
54363         Match "This program" as well as "The program".  This is needed
54364         for gettext.
54365
54366 2003-07-14  Jim Meyering  <jim@meyering.net>
54367
54368         Don't emit diagnostics.  Let callers do that.
54369         * lib/save-cwd.c: Don't include "error.h".
54370         (save_cwd): Don't call error.  Ensure that errno is valid
54371         when returning nonzero.
54372
54373         * lib/save-cwd.h (restore_cwd): Update prototype.
54374         * lib/save-cwd.c (restore_cwd): Remove two parameters.
54375         Simplify.  Don't call error upon failure.  Let callers do that.
54376         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
54377         when auditing is enabled.  But don't bother updating the #if.
54378
54379 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
54380
54381         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
54382         it breaks C++ compilation.
54383         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
54384
54385 2003-07-10  Simon Josefsson  <jas@extundo.com>
54386
54387         * modules/strchrnul (Makefile.am): Add strchrnul.h.
54388
54389 2003-07-10  Jim Meyering  <jim@meyering.net>
54390
54391         * m4/clock_time.m4: Remove trailing blank.
54392         * m4/intmax_t.m4: Likewise.
54393
54394 2003-07-10  Jim Meyering  <jim@meyering.net>
54395
54396         * lib/vasnprintf.c: Remove trailing blanks.
54397         Make cpp indentation consistent.
54398
54399 2003-07-09  Paul Eggert  <eggert@twinsun.com>
54400
54401         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
54402         posixver.c, strftime.c, strnlen.c, strverscmp.c:
54403         Switch from LGPL to GPL.
54404
54405 2003-07-09  Paul Eggert  <eggert@twinsun.com>
54406
54407         * config/srclist.txt: Sort sublists.  Add
54408         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
54409         that differ from gnulib for one reason or another; we'd like this list
54410         to be smaller but for now let's document what we have.
54411
54412 2003-07-08  Paul Eggert  <eggert@twinsun.com>
54413
54414         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
54415         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
54416         and sweeter "eval x=$x".
54417         * config/srclist.txt: Get lib/argp* from glibc.
54418
54419 2003-07-07  Paul Eggert  <eggert@twinsun.com>
54420
54421         * lib/mktime.c: Fix some boundary cases and remove need for floating
54422         point.
54423
54424         Issue a compile-time diagnostic if time_t is floating point, or if
54425         two's complement arithmetic is not in effect, or if arithmetic
54426         right shift does not propagate the sign.  These assumptions were
54427         all in the original code but they weren't checked.
54428
54429         (TIME_T_MIDPOINT, verify): New macros.
54430         (__isleap): Remove; it has integer overflow problems.
54431         (leapyear): New function, without those problems.
54432         (ydhms_tm_diff): Remove; splitting into two parts.
54433         (ydhms_diff): New function, containing the arithmetic part of
54434         the old ydhms_tm_diff function.  Issue a compile-time
54435         diagnostic if we are not using C99 integer division.
54436         Avoid casts when possible.
54437         (guess_time_tm): New function, containing the checking part of
54438         the old ydhms_tm_diff function.  Return the new value, rather than
54439         the difference between it and the old.  Accept a new argument T
54440         so that *T specifies the old value.  Check for overflow in the result.
54441
54442         (__mktime_internal): Use a time_t offset, not a long int offset.
54443         This undoes the 2003-06-04 change, which is no longer needed now
54444         that we have better overflow checking.
54445         (localtime_offset): Likewise.
54446
54447         (__mktime_internal): Avoid harmful overflow on hosts where time_t
54448         and long are 64-bit but int is only 32-bit.
54449         (ydhms_diff): Use long int to store year1 and yday1.
54450         Issue a compile-time diagnostic if long int is not wide enough.
54451
54452         (__mktime_internal): Use long int to store adjusted year and yday.
54453         Use plain C rather than preprocessor commands, if that doesn't
54454         affect efficiency.
54455         Check for overflow (and try to repair) after each probe
54456         rather than checking only at the very end.  This avoids some bugs
54457         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
54458         does not equal GMT offset at maximum time).
54459         Use integer to check for overflow rather than floating point; this
54460         is more portable to non-IEEE hosts, and is a tad faster.
54461         When we detect that we are oscillating between two values,
54462         don't check whether tm_isdst has the requested value, since
54463         we already know the answer.  When tm_isdst has the wrong value,
54464         use a different heuristic to find the right one, based on the
54465         extreme values actually observed in practice in tz2003a,
54466         rather than the (overly optimistic) "previous 3 calendar quarters".
54467
54468         (not_equal_tm, print_tm, check_result): Use "const T" rather than
54469         "T const" to accommodate glibc style.
54470         (check_result): Use less-confusing report format.  "long" -> "long int.
54471         (main): Likewise.
54472         Don't loop if the iteration overflows time_t.
54473         Allow a negative step in the iteration.
54474
54475 2003-07-06  Karl Berry  <karl@gnu.org>
54476
54477         * config/depcomp: update from automake.
54478         * config/config.sub: update from prep.
54479
54480 2003-07-03  Karl Berry  <karl@gnu.org>
54481
54482         * config/config.guess: update from prep.
54483
54484 2003-07-01  Paul Eggert  <eggert@twinsun.com>
54485
54486         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
54487         xreadlink.c now includes it unconditionally.
54488
54489 2003-07-01  Paul Eggert  <eggert@twinsun.com>
54490
54491         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
54492         having it depend on HAVE_SYS_TYPES_H.
54493
54494 2003-07-01  Bruno Haible  <bruno@clisp.org>
54495
54496         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
54497         <sys/types.h> should be sufficient.
54498         Reported by Paul Eggert.
54499
54500 2003-06-26  Karl Berry  <karl@gnu.org>
54501
54502         * config/depcomp: update from automake.
54503
54504 2003-06-26  Bruno Haible  <bruno@clisp.org>
54505
54506         * modules/human: Depend on module stdbool.
54507
54508 2003-06-25  Bruno Haible  <bruno@clisp.org>
54509
54510         * modules/readlink: New file.
54511         * modules/xreadlink: Depend on it.
54512         * MODULES.html.sh (func_all_modules): Add readlink.
54513
54514 2003-06-25  Bruno Haible  <bruno@clisp.org>
54515
54516         * m4/readlink.m4: New file.
54517
54518 2003-06-25  Bruno Haible  <bruno@clisp.org>
54519
54520         * lib/readlink.c: New file.
54521
54522 2003-06-22  Karl Berry  <karl@gnu.org>
54523
54524         * config/srclist.txt: update mkinstalldirs from automake.
54525         * config/mkinstalldirs: update.
54526
54527 2003-06-22  Bruno Haible  <bruno@clisp.org>
54528
54529         Portability to mingw32.
54530         * m4/ssize_t.m4: New file, from GNU gettext.
54531         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
54532         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
54533
54534 2003-06-22  Bruno Haible  <bruno@clisp.org>
54535
54536         * modules/safe-read: Add m4/ssize_t.m4.
54537         * modules/xreadlink: Add m4/ssize_t.m4.
54538
54539 2003-06-20  Bruno Haible  <bruno@clisp.org>
54540
54541         Assume C89, so PARAMS isn't needed.
54542         * lib/unicodeio.h (PARAMS): Remove.
54543         * lib/unicodeio.c: Don't use PARAMS.
54544
54545 2003-06-18  Karl Berry  <karl@gnu.org>
54546
54547         * config/config.{guess,sub}: update from prep.
54548
54549 2003-06-18  Jim Meyering  <jim@meyering.net>
54550
54551         Merge changes from coreutils.
54552         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
54553         Remove explicit declarations of xmalloc and realloc.
54554         Include xalloc.h.
54555         (read_utmp): Remove anachronistic cast of xmalloc.
54556
54557 2003-06-17  Paul Eggert  <eggert@twinsun.com>
54558
54559         Assume C89, so PARAMS isn't needed.
54560         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
54561         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
54562         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
54563         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
54564         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
54565         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
54566         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
54567         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
54568         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
54569         lib/xstrtod.h, lib/xstrtol.h: Likewise.
54570         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
54571         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
54572         no longer needed. Anyway, config.h should always be included before any
54573         other file.
54574
54575 2003-06-11  Simon Josefsson  <jas@extundo.com>
54576
54577         * modules/sysexits: New file.
54578         * MODULES.html.sh (func_all_modules): Add sysexits.
54579
54580 2003-06-11  Simon Josefsson  <jas@extundo.com>
54581
54582         * lib/sysexit_.h: New file.
54583
54584 2003-06-11  Derek Price  <derek@ximbiot.com>
54585
54586         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
54587         necessary.
54588
54589 2003-06-11  Bruno Haible  <bruno@clisp.org>
54590
54591         * m4/sysexits.m4: New file.
54592
54593 2003-06-10  Simon Josefsson  <jas@extundo.com>
54594
54595         * lib/argp.h: New file, from glibc.
54596         * lib/argp-ba.c: New file, from glibc.
54597         * lib/argp-eexst.c: New file, from glibc.
54598         * lib/argp-fmtstream.c: New file, from glibc.
54599         * lib/argp-fmtstream.h: New file, from glibc.
54600         * lib/argp-fs-xinl.c: New file, from glibc.
54601         * lib/argp-help.c: New file, from glibc.
54602         * lib/argp-namefrob.h: New file, from glibc.
54603         * lib/argp-parse.c: New file, from glibc.
54604         * lib/argp-pv.c: New file, from glibc.
54605         * lib/argp-pvh.c: New file, from glibc.
54606         * lib/argp-xinl.c: New file, from glibc.
54607
54608 2003-06-10  Simon Josefsson  <jas@extundo.com>
54609
54610         * modules/strchrnul: New file.
54611
54612 2003-06-10  Simon Josefsson  <jas@extundo.com>
54613
54614         * modules/argp: New file.
54615
54616 2003-06-10  Simon Josefsson  <jas@extundo.com>
54617
54618         * m4/strchrnul.m4: New file.
54619
54620 2003-06-10  Simon Josefsson  <jas@extundo.com>
54621
54622         * lib/strchrnul.h: New file.
54623         * lib/strchrnul.c: New file.
54624
54625 2003-06-10  Bruno Haible  <bruno@clisp.org>
54626
54627         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
54628
54629 2003-06-07  Karl Berry  <karl@gnu.org>
54630
54631         * config/config.{guess,sub}: update from prep.
54632
54633 2003-06-07  Jim Meyering  <jim@meyering.net>
54634
54635         * modules/strtod: Use $(...) notation, not @...@ for
54636         AC_REPLACE'd variables.
54637         * modules/localcharset: Likewise.
54638
54639 2003-06-07  Jim Meyering  <jim@meyering.net>
54640
54641         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
54642         in place of my name in the copyright comment.
54643         Remove definition and uses of __P.
54644
54645         From coreutils.
54646         * lib/stat.c: Don't declare xmalloc explicitly.
54647         Instead, include "xalloc.h".
54648         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
54649         xrealloc, and xcalloc return values.
54650         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
54651         Improve comment.
54652         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
54653
54654 2003-06-07  Bruno Haible  <bruno@clisp.org>
54655
54656         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
54657         avoid AC_CONFIG_LINKS.
54658         * modules/fnmatch (Makefile.am): Use explicit creation rule for
54659         fnmatch.h, to avoid AC_CONFIG_LINKS.
54660         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
54661
54662 2003-06-07  Bruno Haible  <bruno@clisp.org>
54663
54664         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
54665         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
54666         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
54667         directory.
54668         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
54669         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
54670         directory.
54671
54672 2003-06-06  Jim Meyering  <jim@meyering.net>
54673
54674         Merge from coreutils.
54675         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
54676         Consolidate declarations and initializations of *_base* locals.
54677
54678         Merge from coreutils.
54679         This avoids a core dump on systems without GNU putenv,
54680         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
54681         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
54682         (unsetenv): New static function, from GNU libc.
54683         (rpl_putenv): Use it.
54684
54685         * lib/modechange.c: Remove trailing blanks.
54686
54687         Merge from coreutils.
54688         * lib/fsusage.c: Remove declaration of statfs.
54689         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
54690
54691         * lib/posixtm.c: Include <stdbool.h> unconditionally.
54692
54693 2003-06-06  Jim Meyering  <jim@meyering.net>
54694
54695         * lib/stdbool_.h: Renamed from stdbool.h.in.
54696
54697 2003-06-06  Jim Meyering  <jim@meyering.net>
54698             Bruno Haible  <bruno@clisp.org>
54699
54700         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
54701         Adjust Makefile.am snippet not to redirect directly to target.
54702         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
54703
54704 2003-06-05  Paul Eggert  <eggert@twinsun.com>
54705
54706         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
54707         mismatch, look in future quarters as well as past.  This fixes a
54708         bug when processing fall-backwards gaps immediately after a long
54709         period of daylight-saving time.
54710
54711         * lib/mktime.c: Assume freestanding C89 or better.
54712         (HAVE_LIMITS_H): Remove.  Assume it's 1.
54713         (__P): Remove; not used.
54714         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
54715         (mktime, not_equal_tm, print_tm, check_result,
54716         main): Use prototypes.  Use const * where appropriate.
54717         (main): Fix typo in testing code that uncovered by above changes.
54718         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
54719
54720 2003-06-04  Paul Eggert  <eggert@twinsun.com>
54721
54722         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
54723         locale.h, localeconv.  This merges changes from coreutils.
54724
54725         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
54726         It can be removed after the next Autoconf is released.
54727         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
54728         needed.
54729
54730 2003-06-04  Paul Eggert  <eggert@twinsun.com>
54731
54732         * lib/mktime.c: Fix Debian bug 177940
54733         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
54734         (localtime_offset): Now long int, not time_t, because we want it
54735         to be guaranteed to be signed.  All uses changed.
54736         (__mktime_internal): If overflow would occur when adding offset,
54737         don't add it.
54738
54739         Merge 'human' changes from coreutils.  Rewrite to support
54740         locale-specific notations like thousands separators.
54741         * lib/human.c: Simplify authorship notice.
54742         Include human.h immediately after config.h.
54743         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
54744         <limits.h>: Do not include, since human.h does.
54745         (SIZE_MAX, UINTMAX_MAX): New macros.
54746         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
54747         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
54748         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
54749         (power_letter): Renamed from suffixes.
54750         (generate_suffix_backwards): Remove.
54751         (adjust_value): Now takes int style (because of human.h changes)
54752         and long double value (for greater precision on some platforms).
54753         (group_number): New function.
54754         (human_readable): Use it.  Use integer options, not enum.
54755         Put the options before the sizes in the arg list.
54756         Support all the new options.
54757         The old human_readable function has been removed;
54758         use inttostr.h instead.
54759         (human_readable, default_block_size, humblock):
54760         Use uintmax_t, not int, for block sizes.
54761         (human_readable_inexact, block_size_types): Remove.
54762         (block_size_opts): New constant.
54763         (human_options): Renamed from human_block_size, with new signature
54764         that allows block sizes up to UINTMAX_MAX.  All callers changed.
54765         * lib/human.h: Add copyright and authorship notice.
54766         Include <limits.h> and <stdbool.h> unconditionally.
54767         (PARAMS): Remove.  All uses removed.
54768         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
54769         (enum human_inexact_style): Remove tag; now a nameless enum.
54770         (human_floor, human_ceiling, human_round_to_even): Now have
54771         values 2, 0, 1 rather than -1, 1, 0.
54772         (human_group_digits, human_suppress_point_zero, human_autoscale,
54773         human_base_1024, human_SI, human_B): New constants.
54774         (human_readable_inexact, human_block_size): Remove.
54775         (human_readable): Size args are now uintmax_t, not int.
54776         (human_options): New decl.
54777
54778         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
54779         unnecessary now that we assume C89 or better.  This change
54780         imported from coreutils.
54781
54782         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
54783         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
54784         in the 2003-05-30 sync from glibc.
54785
54786         .h files should stand alone, but we shouldn't include <sys/types.h>
54787         if we can get away with just <stddef.h>.
54788
54789         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
54790         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
54791         rather than <sys/types.h>, as we merely need size_t.
54792         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
54793         to get size_t.
54794         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
54795         Include <stdio.h>, to get FILE.
54796         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
54797         memcasecmp.h has included <stddef.h> and all we need is size_t.
54798         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
54799         our interface, instead of including <sys/types.h>
54800
54801 2003-06-04  Paul Eggert  <eggert@twinsun.com>
54802
54803         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
54804         now, as glibc mktime is buggy on non-glibc systems.
54805
54806 2003-06-03  Karl Berry  <karl@gnu.org>
54807
54808         * config/config.sub: update from prep.
54809
54810 2003-06-02  Paul Eggert  <eggert@twinsun.com>
54811
54812         [from coreutils]
54813         Fix some minor time-related bugs with POSIX time arguments.
54814         Some valid time stamps were being rejected (notably -1, and
54815         time stamps before 1900 on 64-bit hosts).  And some invalid
54816         time stamps were being accepted, e.g. September 31.
54817
54818         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
54819         that we can return (time_t) -1 successfully.
54820         * lib/posixtm.c: Likewise.
54821         [HAVE_STDBOOL_H]: Include <stdbool.h>.
54822         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
54823         (t): Remove static var.
54824         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
54825         of static var.  All uses changed.
54826         (year): Do not reject years before 1900; they can occur with
54827         64-bit time_t.
54828         (posix_time_parse): Do not check for out-of-range components;
54829         that is now the caller's responsibility, since our checks were
54830         only approximations.
54831         (posixtime): Use mktime to check for out-of-range components,
54832         since it knows them exactly.
54833         If mktime returns (time_t) -1, check whether an error actually occurred
54834         by invoking localtime on -1.
54835         (main) [TEST_POSIXTIME]: Check for input data errors, and report
54836         posixtime failures better.
54837         Improve the test data (in comments only).
54838
54839 2003-06-02  Karl Berry  <karl@gnu.org>
54840
54841         * config/mkinstalldirs (version): new variable.
54842         (--version): new option.
54843         (usage): improve message.
54844
54845 2003-05-30  Karl Berry  <karl@gnu.org>
54846
54847         * lib/mktime.c: update from libc.
54848
54849 2003-05-30  Bruno Haible  <bruno@clisp.org>
54850
54851         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
54852         * config/config.rpath: Upgrade to gettext-0.12.1.
54853
54854 2003-05-30  Bruno Haible  <bruno@clisp.org>
54855
54856         * m4/gettext.m4: Upgrade to gettext-0.12.1.
54857         * m4/nls.m4: New file, from gettext-0.12.1.
54858         * m4/po.m4: New file, from gettext-0.12.1.
54859         * m4/progtest.m4: Upgrade to gettext-0.12.1.
54860
54861 2003-05-30  Bruno Haible  <bruno@clisp.org>
54862
54863         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
54864         * lib/localcharset.h: Likewise.
54865         * lib/localcharset.c: Likewise.
54866
54867 2003-05-29  Karl Berry  <karl@gnu.org>
54868
54869         * config/config.rpath: update from gettext.
54870
54871 2003-05-28  Paul Eggert  <eggert@twinsun.com>
54872
54873         Assume the headers required for C89 freestanding compilers.
54874         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
54875         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
54876         * m4/human.m4 (gl_HUMAN): Likewise.
54877         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
54878         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
54879         * m4/userspec.m4 (gl_USERSPEC): Likewise.
54880         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
54881         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
54882         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
54883
54884 2003-05-28  Paul Eggert  <eggert@twinsun.com>
54885
54886         Assume the headers required for C89 freestanding compilers.
54887         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
54888         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
54889         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
54890         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
54891         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
54892         define, since <limits.h> is guaranteed to do that.
54893         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
54894         * lib/exclude.c: Include <stdbool.h> unconditionally.
54895         * lib/tempname.c: Include <stddef.h> unconditionally.
54896         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
54897         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
54898         <stddef.h> does that.
54899         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
54900         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
54901         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
54902         needed.
54903         * lib/xstrtol.c: Likewise.
54904         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
54905         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
54906
54907         * lib/addext.c (addext): Use assignment rather than cast, to avoid
54908         warnings on some platforms.
54909
54910         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
54911         arbitrarily.
54912
54913 2003-05-26  Jim Meyering  <jim@meyering.net>
54914
54915         Merge in a change from coreutils:
54916         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
54917         that is guaranteed to be `no'.  Use `no_such_member' to indicate
54918         that condition, rather than `-1' which is slightly misleading.
54919         Change the name of the cache variable to have the gl_ prefix.
54920         Prompted by a patch from Richard Dawe for DJGPP.
54921
54922 2003-05-24  Karl Berry  <karl@gnu.org>
54923
54924         * config/config.guess: update from prep.
54925
54926 2003-05-22  Karl Berry  <karl@gnu.org>
54927
54928         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
54929
54930 2003-05-20  Karl Berry  <karl@gnu.org>
54931
54932         * config/config.guess: update from prep.
54933
54934 2003-05-18  Karl Berry  <karl@gnu.org>
54935
54936         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
54937         might actually be set by the user.
54938
54939         * config/depcomp, install-sh, mdate-sh: update from automake.
54940
54941 2003-05-17  Bruno Haible  <bruno@clisp.org>
54942
54943         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
54944         invalid expansion for AC_EGREP_CPP.
54945         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
54946         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
54947         Suggested by Akim Demaille <akim@epita.fr> in
54948         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
54949
54950 2003-05-12  Jim Meyering  <jim@meyering.net>
54951
54952         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
54953         the space-padded-by-default conversion specifiers, %e, %k, %l.
54954
54955 2003-05-12  Bruno Haible  <bruno@clisp.org>
54956
54957         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
54958         the string is longer than 4 KB.
54959
54960 2003-05-11  Karl Berry  <karl@gnu.org>
54961
54962         * config/config.{guess,sub}: update from prep.
54963
54964 2003-05-09  Bruno Haible  <bruno@clisp.org>
54965
54966         * modules/error: Add m4/strerror_r.m4 to file list.
54967
54968 2003-05-03  Bruno Haible  <bruno@clisp.org>
54969
54970         Upgrade to Unicode-4.0.
54971         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
54972         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
54973         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
54974         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
54975         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
54976         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
54977         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
54978         Change width of U+E0100..U+E01EF from 1 to 0.
54979
54980 2003-04-25  Jim Meyering  <jim@meyering.net>
54981
54982         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
54983         of type size_t, not int.
54984
54985 2003-04-25  Bruno Haible  <bruno@clisp.org>
54986
54987         * lib/copy-file.c: Include <stddef.h>, for size_t.
54988
54989 2003-04-21  Paul Eggert  <eggert@twinsun.com>
54990
54991         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
54992         code which expansion is under static control.  Patch imported from
54993         Akim Demaille's patch to Bison; see
54994         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
54995
54996 2003-04-14  Bruno Haible  <bruno@clisp.org>
54997
54998         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
54999
55000 2003-04-11  Jim Meyering  <jim@meyering.net>
55001
55002         Merge changes from Coreutils.
55003
55004         2003-03-22  Jim Meyering  <jim@meyering.net>
55005
55006         * lib/strftime.c (widen): Cast alloca return value to proper type.
55007
55008         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
55009
55010         From GNU libc.
55011         * lib/strftime.c (my_strftime): Handle very large width
55012         specifications for numeric values correctly.  Improve checks for
55013         overflow.
55014
55015         2003-01-19  Jim Meyering  <jim@meyering.net>
55016
55017         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
55018         definitions.
55019         (nl_get_alt_digit) [! defined my_strftime]: Define.
55020         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
55021         _nl_get_alt_digit and _nl_get_walt_digit.
55022
55023         * lib/strftime.c (my_strftime): Merge in locale-related changes from
55024         libc. These changes have no effect outside of _LIBC.
55025
55026 2003-04-10  Bruno Haible  <bruno@clisp.org>
55027
55028         * modules/findprog: New file.
55029         * MODULES.html.sh (func_all_modules): Add it.
55030
55031 2003-04-10  Bruno Haible  <bruno@clisp.org>
55032
55033         * m4/findprog.m4: New file.
55034         * m4/eaccess.m4: New file.
55035
55036 2003-04-10  Bruno Haible  <bruno@clisp.org>
55037
55038         * lib/findprog.h: New file, from GNU gettext.
55039         * lib/findprog.c: New file, from GNU gettext.
55040
55041 2003-04-05  Jim Meyering  <jim@meyering.net>
55042
55043         Merge changes from Coreutils.
55044
55045         * lib/exclude.h (PARAMS): Remove definition and uses.
55046         * lib/exclude.c: Remove uses of `PARAMS'.
55047
55048         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
55049         Add test-cases for DOS filenames. Declare program_name.
55050         (main): Set up program_name.  Patch by Rich Dawe.
55051
55052         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
55053         error from mntctl.
55054         Use mntctl's return value to drive the entry-processing loop, since
55055         we can't rely on the value of the vmt_length member in the last
55056         entry.  On some systems doing so could result in exhausting
55057         virtual memory.  Based in part on a patch from Mike Jetzer.
55058
55059 2003-04-04  Bruno Haible  <bruno@clisp.org>
55060
55061         * modules/linebreak: New file.
55062         * MODULES.html.sh (func_all_modules): Add it.
55063
55064 2003-04-04  Bruno Haible  <bruno@clisp.org>
55065
55066         * m4/linebreak.m4: New file.
55067
55068 2003-04-04  Bruno Haible  <bruno@clisp.org>
55069
55070         * lib/linebreak.h: New file, from GNU gettext.
55071         * lib/linebreak.c: New file, from GNU gettext with slight
55072         modifications.
55073         * lib/lbrkprop.h: New file, from GNU gettext.
55074
55075 2003-04-03  Bruno Haible  <bruno@clisp.org>
55076
55077         * modules/utf8-ucs4: New file.
55078         * modules/utf16-ucs4: New file.
55079         * modules/ucs4-utf8: New file.
55080         * modules/ucs4-utf16: New file.
55081         * MODULES.html.sh (func_all_modules): Add them.
55082
55083 2003-04-03  Bruno Haible  <bruno@clisp.org>
55084
55085         * m4/utf-ucs4.m4: New file.
55086         * m4/ucs4-utf.m4: New file.
55087
55088 2003-04-03  Bruno Haible  <bruno@clisp.org>
55089
55090         * lib/utf8-ucs4.h: New file, from GNU gettext.
55091         * lib/utf16-ucs4.h: New file, from GNU gettext.
55092         * lib/ucs4-utf8.h: New file, from GNU gettext.
55093         * lib/ucs4-utf16.h: New file, from GNU gettext.
55094
55095 2003-04-02  Bruno Haible  <bruno@clisp.org>
55096
55097         * modules/binary-io: New file.
55098         * MODULES.html.sh (func_all_modules): Add it.
55099
55100 2003-04-02  Bruno Haible  <bruno@clisp.org>
55101
55102         * lib/binary-io.h: New file, from GNU gettext.
55103
55104 2003-04-01  Bruno Haible  <bruno@clisp.org>
55105
55106         * modules/pathname: New file.
55107         * MODULES.html.sh (func_all_modules): Add it.
55108
55109 2003-04-01  Bruno Haible  <bruno@clisp.org>
55110
55111         * lib/pathname.h: New file, from GNU gettext.
55112         * lib/concatpath.c: New file, from GNU gettext.
55113
55114 2003-03-30  Bruno Haible  <bruno@clisp.org>
55115
55116         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
55117
55118 2003-03-30  Bruno Haible  <bruno@clisp.org>
55119
55120         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
55121         function chown() doesn't exist.
55122
55123 2003-03-28  Bruno Haible  <bruno@clisp.org>
55124
55125         * modules/copy-file: New file.
55126         * MODULES.html.sh (func_all_modules): Add it.
55127
55128 2003-03-28  Bruno Haible  <bruno@clisp.org>
55129
55130         * m4/copy-file.m4: New file.
55131
55132 2003-03-28  Bruno Haible  <bruno@clisp.org>
55133
55134         * lib/copy-file.h: New file, from GNU gettext.
55135         * lib/copy-file.c: New file, from GNU gettext.
55136
55137 2003-03-18  Jim Meyering  <jim@meyering.net>
55138
55139         * lib/quote.c (quote_n): Fix typo in comment.
55140
55141 2003-03-18  Bruno Haible  <bruno@clisp.org>
55142
55143         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
55144         checking.
55145         * m4/onceonly_2_57.m4: Likewise.
55146
55147 2003-03-17  Bruno Haible  <bruno@clisp.org>
55148
55149         * m4/onceonly.m4: Require autoconf 2.54 or newer.
55150         (m4_quote): Remove macro.
55151         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
55152
55153 2003-03-14  Jim Meyering  <jim@meyering.net>
55154
55155         Merge changes from Coreutils.
55156         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
55157         to be const, in order to avoid warnings.
55158         (obstack_room): Likewise.
55159         (obstack_empty_p): Likewise.
55160
55161 2003-03-14  Bruno Haible  <bruno@clisp.org>
55162
55163         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
55164         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
55165
55166 2003-03-13  Paul Eggert  <eggert@twinsun.com>
55167
55168         Merge changes from Bison.
55169         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
55170         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
55171         when compiling Bison 1.875's `bitset bset = obstack_alloc
55172         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
55173         * lib/hash.c: Include <stdbool.h> unconditionally.
55174
55175 2003-03-13  Paul Eggert  <eggert@twinsun.com>
55176
55177         * m4/onceonly.m4 (m4_quote): New macro.
55178         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
55179         Quote AC_FOREACH variable-expansions properly.
55180
55181 2003-03-13  Paul Eggert  <eggert@twinsun.com>
55182
55183         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
55184
55185 2003-03-09  Paul Eggert  <eggert@twinsun.com>
55186
55187         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
55188         Reported by Bruce Becker; see:
55189         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
55190
55191 2003-03-03  Paul Eggert  <eggert@twinsun.com>
55192             Bruno Haible  <bruno@clisp.org>
55193
55194         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
55195         Reported by John Hughes, see
55196         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
55197
55198 2003-02-20  Bruno Haible  <bruno@clisp.org>
55199
55200         * MODULES.html.sh (func_all_modules): Add poll.
55201
55202 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
55203
55204         * modules/poll: New file.
55205
55206 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
55207
55208         * lib/poll_.h: New file.
55209         * lib/poll.c: New file.
55210
55211 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
55212
55213         * m4/poll.m4: New file.
55214
55215 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
55216
55217         * modules/mathl: New file.
55218
55219 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
55220
55221         * lib/mathl.h: New file.
55222         * lib/acosl.c: New file.
55223         * lib/asinl.c: New file.
55224         * lib/atanl.c: New file.
55225         * lib/ceill.c: New file.
55226         * lib/cosl.c: New file.
55227         * lib/expl.c: New file.
55228         * lib/floorl.c: New file.
55229         * lib/frexpl.c: New file.
55230         * lib/ldexpl.c: New file.
55231         * lib/logl.c: New file.
55232         * lib/sincosl.c: New file.
55233         * lib/sinl.c: New file.
55234         * lib/sqrtl.c: New file.
55235         * lib/tanl.c: New file.
55236         * lib/trigl.c: New file.
55237         * lib/trigl.h: New file.
55238
55239 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
55240
55241         * m4/mathl.m4: New file.
55242
55243 2003-02-18  Bruno Haible  <bruno@clisp.org>
55244
55245         * MODULES.html.sh (func_all_modules): Add mathl.
55246
55247 2003-02-17  Bruno Haible  <bruno@clisp.org>
55248
55249         * modules/mkdtemp: New module.
55250         * MODULES.html.sh (func_all_modules): Add it.
55251
55252 2003-02-17  Bruno Haible  <bruno@clisp.org>
55253
55254         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
55255
55256 2003-02-17  Bruno Haible  <bruno@clisp.org>
55257
55258         * lib/mkdtemp.h: New file, from GNU gettext.
55259         * lib/mkdtemp.c: New file, from GNU gettext.
55260
55261 2003-02-02  Jim Meyering  <jim@meyering.net>
55262
55263         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
55264         e.g. glibc-2.2.93.
55265
55266 2003-01-31  Bruno Haible  <bruno@clisp.org>
55267
55268         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
55269         'rpl_rename'.
55270         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
55271         'rpl_strnlen'.
55272         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
55273         'rpl_strtod'.
55274         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
55275         'rpl_utime'.
55276
55277 2003-01-31  Bruno Haible  <bruno@clisp.org>
55278
55279         * lib/rename.c: #undef rename before defining rpl_rename.
55280         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
55281
55282 2003-01-30  Bruno Haible  <bruno@clisp.org>
55283
55284         * modules/vasnprintf, modules/vasprintf: New modules.
55285         * MODULES.html.sh (func_all_modules): Add them.
55286
55287 2003-01-30  Bruno Haible  <bruno@clisp.org>
55288
55289         * m4/signed.m4: New file, from GNU gettext.
55290         * m4/longdouble.m4: New file, from GNU gettext.
55291         * m4/wchar_t.m4: New file, from GNU gettext.
55292         * m4/wint_t.m4: New file, from GNU gettext.
55293         * m4/vasnprintf.m4: New file.
55294         * m4/vasprintf.m4: New file.
55295
55296 2003-01-30  Bruno Haible  <bruno@clisp.org>
55297
55298         * lib/printf-args.h: New file, from GNU gettext.
55299         * lib/printf-args.c: New file, from GNU gettext.
55300         * lib/printf-parse.h: New file, from GNU gettext.
55301         * lib/printf-parse.c: New file, from GNU gettext.
55302         * lib/vasnprintf.h: New file, from GNU gettext.
55303         * lib/vasnprintf.c: New file, from GNU gettext.
55304         * lib/asnprintf.c: New file, from GNU gettext.
55305         * lib/vasprintf.h: New file, from GNU gettext with modifications.
55306         * lib/vasprintf.c: New file, from GNU gettext.
55307         * lib/asprintf.c: New file, from GNU gettext.
55308
55309 2003-01-29  Bruno Haible  <bruno@clisp.org>
55310
55311         * modules/stpncpy: New module.
55312         * MODULES.html.sh (func_all_modules): Add it.
55313
55314 2003-01-29  Bruno Haible  <bruno@clisp.org>
55315
55316         * m4/stpncpy.m4: New file.
55317
55318 2003-01-29  Bruno Haible  <bruno@clisp.org>
55319
55320         * lib/stpncpy.h: New file, from GNU gettext with modifications.
55321         * lib/stpncpy.c: New file, from GNU gettext with modifications.
55322
55323 2003-01-28  Bruno Haible  <bruno@clisp.org>
55324
55325         * modules/c-ctype: New module.
55326         * MODULES.html.sh (func_all_modules): Add it.
55327
55328 2003-01-28  Bruno Haible  <bruno@clisp.org>
55329
55330         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
55331         Paul Eggert.
55332         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
55333         Paul Eggert.
55334
55335 2003-01-27  Bruno Haible  <bruno@clisp.org>
55336
55337         * modules/xsetenv: New module.
55338         * MODULES.html.sh (func_all_modules): Add it.
55339
55340 2003-01-27  Bruno Haible  <bruno@clisp.org>
55341
55342         * lib/xsetenv.h: New file, from GNU gettext.
55343         * lib/xsetenv.c: New file, from GNU gettext.
55344
55345 2003-01-23  Jim Meyering  <jim@meyering.net>
55346
55347         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
55348         from working on systems without dirfd (at least Irix and OSF1/Tru64).
55349
55350 2003-01-23  Bruno Haible  <bruno@clisp.org>
55351
55352         * modules/minmax: New module.
55353         * MODULES.html.sh (func_all_modules): Add it.
55354
55355 2003-01-23  Bruno Haible  <bruno@clisp.org>
55356
55357         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
55358         Eggert.
55359
55360 2003-01-22  Bruno Haible  <bruno@clisp.org>
55361
55362         * modules/exit: New module.
55363         * MODULES.html.sh (func_all_modules): Add it.
55364
55365 2003-01-22  Bruno Haible  <bruno@clisp.org>
55366
55367         * lib/exit.h: New file, from GNU gettext.
55368
55369 2003-01-19  Bruno Haible  <bruno@clisp.org>
55370
55371         * gnulib-tool: Recognize option --extract-maintainer.
55372         (func_get_maintainer): New function.
55373         * modules/*: Add Maintainer entry.
55374
55375 2003-01-16  Jim Meyering  <jim@meyering.net>
55376
55377         * m4/regex.m4: The `regex' struct is both input and output.
55378         Initialize it before each use.  Patch by Tim Waugh.
55379
55380 2003-01-16  Bruno Haible  <bruno@clisp.org>
55381
55382         * MODULES.html.sh: Add a table of contents. Add the module name as
55383         leftmost column. Add hyperlinks.
55384
55385 2003-01-15  Bruno Haible  <bruno@clisp.org>
55386
55387         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
55388
55389 2003-01-15  Bruno Haible  <bruno@clisp.org>
55390
55391         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
55392         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
55393         suffix.
55394
55395 2003-01-15  Bruno Haible  <bruno@clisp.org>
55396
55397         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
55398
55399 2003-01-15  Bruno Haible  <bruno@clisp.org>
55400
55401         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
55402         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
55403
55404 2003-01-14  Jim Meyering  <jim@meyering.net>
55405
55406         * lib/same.c (same_name): Tweak a comment.
55407
55408 2003-01-14  Bruno Haible  <bruno@clisp.org>
55409
55410         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
55411         when a string comparison is sufficient.
55412
55413 2003-01-14  Bruno Haible  <bruno@clisp.org>
55414
55415         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
55416         'unsigned int'.
55417
55418 2003-01-14  Bruno Haible  <bruno@clisp.org>
55419
55420         * lib/hash-pjw.c: Add comment about low quality of this function.
55421
55422 2003-01-13  Bruno Haible  <bruno@clisp.org>
55423
55424         * modules/stpcpy: Distribute lib/stpcpy.h.
55425         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
55426
55427 2003-01-13  Bruno Haible  <bruno@clisp.org>
55428
55429         * modules/*: Add a description.
55430         * modules/strpbrk: Fix Makefile.am snippet.
55431         * modules/strtoimax: Fix dependencies.
55432         * modules/strtoumax: Likewise.
55433
55434 2003-01-13  Bruno Haible  <bruno@clisp.org>
55435
55436         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
55437         * modules/alloca (Makefile.am): All object files depend on alloca.h.
55438         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
55439
55440 2003-01-13  Bruno Haible  <bruno@clisp.org>
55441
55442         * gnulib-tool (func_create_testdir): Store config/* files in the main
55443         directory.
55444         * config.rpath: Move to ...
55445         * config/config.rpath: ... here.
55446         * modules/gettext: Contains config/config.rpath, not config.rpath.
55447         * modules/iconv: Likewise.
55448
55449 2003-01-12  Paul Eggert  <eggert@twinsun.com>
55450
55451         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
55452         to avoid collisions with libcurses and libreadline.
55453
55454         * m4/getstr.m4: Remove.
55455         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
55456
55457 2003-01-12  Paul Eggert  <eggert@twinsun.com>
55458
55459         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
55460         to avoid collisions with libcurses and libreadline.
55461
55462         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
55463         * lib/getstr.h, getstr.c: Remove.
55464         * lib/getline.c: Include "getline.h", to check interface.
55465         Move body of old getstr.c here: this defines MIN_CHUNK and
55466         declares getdelim2, which is renamed from getstr.
55467         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
55468
55469         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
55470         All uses changed.
55471         * lib/linebuffer.h: Likewise.
55472         (readline): Remove backward-compatibility macro.
55473
55474 2003-01-12  Paul Eggert  <eggert@twinsun.com>
55475
55476         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
55477         to avoid collisions with libcurses and libreadline.
55478         * getstr: Remove.
55479         * MODULES.html.sh: Remove getstr.
55480         * modules/getline: Depend on unlocked-io, not getstr.
55481
55482 2003-01-12  Jim Meyering  <jim@meyering.net>
55483
55484         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
55485
55486 2003-01-10  Bruno Haible  <bruno@clisp.org>
55487
55488         * modules/alloca: Change Makefile.am requirements. Simplify Include
55489         requirements. Add lib/alloca_.h to file list.
55490
55491 2003-01-10  Bruno Haible  <bruno@clisp.org>
55492
55493         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
55494
55495 2003-01-10  Bruno Haible  <bruno@clisp.org>
55496
55497         * lib/alloca_.h: New file.
55498         * lib/getdate.y: Unconditionally include alloca.h.
55499         * lib/makepath.c: Likewise.
55500         * lib/setenv.c: Likewise.
55501         * lib/userspec.c: Likewise.
55502
55503 2003-01-09  Karl Berry  <karl@gnu.org>
55504
55505         * MODULES.html.sh: include `dirname $0` in PATH, to find
55506         gnulib-tool.
55507
55508 2003-01-09  Bruno Haible  <bruno@clisp.org>
55509
55510         * modules/stdbool: Change configure.ac, Makefile.am requirements.
55511         Simplify Include requirements. Add lib/stdbool.h.in to file list.
55512
55513 2003-01-09  Bruno Haible  <bruno@clisp.org>
55514
55515         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
55516
55517 2003-01-09  Bruno Haible  <bruno@clisp.org>
55518
55519         * lib/stdbool.h.in: New file.
55520
55521 2003-01-09  Bruno Haible  <bruno@clisp.org>
55522
55523         * gnulib-tool (func_all_modules): Ignore files ending in ~.
55524         * MODULES.html.sh: Likewise.
55525
55526 2003-01-08  Jim Meyering  <jim@meyering.net>
55527
55528         * lib/full-write.c: Undefine and define-away `const' after inclusion
55529         of errno.h, not before.  Suggestion from Bruno Haible.
55530
55531 2003-01-08  Bruno Haible  <bruno@clisp.org>
55532
55533         * modules/full-read: Depend on full-write.
55534
55535 2003-01-08  Bruno Haible  <bruno@clisp.org>
55536
55537         * lib/safe-read.c: Include specification header first, to ensure its
55538         selfcontainedness.
55539         * lib/full-write.c: Likewise.
55540
55541 2003-01-07  Jim Meyering  <jim@meyering.net>
55542
55543         * lib/full-write.c: Rework so that it may serve to define full_read,
55544         too.
55545         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
55546
55547 2003-01-07  Bruno Haible  <bruno@clisp.org>
55548
55549         * lib/strtoimax.c: Include <stdint.h> as an alternative to
55550         <inttypes.h>.
55551         * lib/xstrtol.h: Likewise.
55552         * lib/xstrtoimax.c: Likewise.
55553         * lib/xstrtoumax.c: Likewise.
55554         * lib/human.h: Likewise.
55555
55556         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
55557         on systems that have <inttypes.h> but not <stdint.h>.
55558
55559 2003-01-07  Bruno Haible  <bruno@clisp.org>
55560
55561         * MODULES.html.sh: Add copyright notice.
55562         (missed_files): Omit CVS directory entries.
55563         (func_module): Make it work with sed-3.02.
55564         * MODULES.txt: Remove file.
55565
55566 2003-01-06  Jim Meyering  <jim@meyering.net>
55567
55568         * lib/version-etc.c: Update year in translatable copyright string.
55569
55570 2003-01-03  Karl Berry  <karl@gnu.org>
55571
55572         * config/config.{guess,sub}: update from prep.
55573
55574 2003-01-02  Karl Berry  <karl@gnu.org>
55575
55576         * doc/COPYING.DOC: belatedly updated to 1.2.
55577
55578 2003-01-01  Karl Berry  <karl@gnu.org>
55579
55580         * gnulib-tool (func_verify_module): report module name $module in
55581         error message, not $1.
55582         * gnulib-tool (create-testdir): don't complain if destdir couldn't
55583         be created, only if it doesn't exist.
55584         * gnulib-tool (last_checkin_date): don't expand the $Date here.
55585
55586 2002-12-31  Paul Eggert  <eggert@twinsun.com>
55587
55588         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
55589
55590 2002-12-31  Paul Eggert  <eggert@twinsun.com>
55591
55592         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
55593         memcmp if strcoll doesn't work.
55594
55595 2002-12-31  Bruno Haible  <bruno@clisp.org>
55596
55597         * lib/utime.c (utime_null): No need to call ftruncate if the file was
55598         nonempty.
55599
55600 2002-12-31  Bruno Haible  <bruno@clisp.org>
55601
55602         * lib/memcoll.c (STRCOLL): New macro.
55603         (memcoll): Use it.
55604
55605 2002-12-31  Bruno Haible  <bruno@clisp.org>
55606
55607         * lib/localcharset.h: New file.
55608         * lib/localcharset.c: Include it.
55609         * lib/unicodeio.c: Likewise.
55610
55611 2002-12-31  Bruno Haible  <bruno@clisp.org>
55612
55613         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
55614         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
55615
55616 2002-12-31  Bruno Haible  <bruno@clisp.org>
55617
55618         * lib/getline.h: Include <stddef.h>, for size_t.
55619
55620         * lib/unicodeio.h: Include <stddef.h>, for size_t.
55621         * lib/unicodeio.c: Don't include <stddef.h>.
55622
55623 2002-12-31  Bruno Haible  <bruno@clisp.org>
55624
55625         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
55626         HAVE_TM_ZONE.
55627
55628 2002-12-24  Karl Berry  <karl@gnu.org>
55629
55630         * config/config.guess: update from prep.
55631
55632 2002-12-24  Bruno Haible  <bruno@clisp.org>
55633
55634         General infrasructure.
55635         * m4/README: Rewritten.
55636         * m4/onceonly.m4: New file.
55637         * m4/onceonly_2_57.m4: New file.
55638
55639         Module atexit.
55640         * m4/atexit.m4: New file.
55641
55642         Module strtod.
55643         * m4/strtod.m4: New file.
55644
55645         Module strtol.
55646         * m4/strtol.m4: New file.
55647
55648         Module strtoul.
55649         * m4/strtoul.m4: New file.
55650
55651         Module memchr.
55652         * m4/memchr.m4: New file.
55653
55654         Module memcmp.
55655         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
55656         (jm_FUNC_MEMCMP): Invoke it.
55657
55658         Module memcpy.
55659         * m4/memcpy.m4: New file.
55660
55661         Module memmove.
55662         * m4/memmove.m4: New file.
55663
55664         Module memset.
55665         * m4/memset.m4: New file.
55666
55667         Module strcspn.
55668         * m4/strcspn.m4: New file.
55669
55670         Module strpbrk.
55671         * m4/strpbrk.m4: New file.
55672
55673         Module strstr.
55674         * m4/strstr.m4: New file.
55675
55676         Module strerror.
55677         * m4/strerror.m4: New file.
55678
55679         Module mktime.
55680         * m4/mktime.m4: Renamed from jm-mktime.m4.
55681         (gl_PREREQ_MKTIME): New macro.
55682         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
55683
55684         Module malloc.
55685         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
55686         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
55687         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
55688
55689         Module realloc.
55690         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
55691         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
55692         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
55693
55694         Module strftime.
55695         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
55696         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
55697         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
55698         gl_TM_GMTOFF.
55699         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
55700
55701         Module xalloc.
55702         * m4/xalloc.m4: New file.
55703
55704         Module alloca.
55705         * m4/alloca.m4: New file.
55706
55707         Module putenv.
55708         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
55709         (jm_FUNC_PUTENV): Invoke it.
55710
55711         Module setenv.
55712         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
55713         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
55714         when invoked twice.
55715         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
55716         gt_FUNC_SETENV.
55717
55718         Module memrchr.
55719         * m4/memrchr.m4: New file.
55720
55721         Module stpcpy.
55722         * m4/stpcpy.m4: New file.
55723
55724         Module strcase.
55725         * m4/strcase.m4: New file.
55726
55727         Module strdup.
55728         * m4/strdup.m4: New file.
55729
55730         Module strnlen.
55731         * m4/strnlen.m4: New file.
55732
55733         Module strndup.
55734         * m4/strndup.m4: New file.
55735
55736         Module xstrtod.
55737         * m4/xstrtod.m4: New file.
55738
55739         Module xstrtol.
55740         * m4/xstrtol.m4: New file.
55741
55742         Module getdate.
55743         * m4/getdate.m4: New file.
55744
55745         Module unlocked-io.
55746         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
55747         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
55748         * m4/jm-glibc-io.m4n: Remove file.
55749
55750         Module long-options.
55751         * m4/long-options.m4: New file.
55752
55753         Module md5.
55754         * m4/md5.m4: New file.
55755
55756         Module sha.
55757         * m4/sha.m4: New file.
55758
55759         Module getstr.
55760         * m4/getstr.m4: New file.
55761
55762         Module getline.
55763         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
55764         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
55765         <sys/types.h>, for size_t. Use the function name gnu_getline, not
55766         simply getline. Infoke gl_PREREQ_GETLINE.
55767
55768         Module obstack.
55769         * m4/obstack.m4: New file.
55770
55771         Module hash.
55772         * m4/hash.m4: New file.
55773
55774         Module readtokens.
55775         * m4/readtokens.m4: New file.
55776
55777         Module strverscmp.
55778         * m4/strverscmp.m4: New file.
55779
55780         Module stdbool.
55781         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
55782         OSF/1.
55783
55784         Module strtoll.
55785         * m4/strtoll.m4: New file.
55786
55787         Module strtoull.
55788         * m4/strtoull.m4: New file.
55789
55790         Module strtoimax.
55791         * m4/strtoimax.m4: New file.
55792
55793         Module strtoumax.
55794         * m4/strtoumax.m4: New file.
55795
55796         Module xstrtoimax.
55797         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
55798         jm_AC_PREREQ_XSTRTOIMAX.
55799         Moved the strtol prerequisites to strtol.m4.
55800         Moved the strtoll prerequisites to strtoll.m4.
55801         Moved the strtoimax prerequisites to strtoimax.m4.
55802
55803         Module xstrtoumax.
55804         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
55805         jm_AC_PREREQ_XSTRTOUMAX.
55806         Moved the strtoul prerequisites to strtoul.m4.
55807         Moved the strtoull prerequisites to strtoull.m4.
55808         Moved the strtoumax prerequisites to strtoumax.m4.
55809
55810         Module chown.
55811         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
55812         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
55813
55814         Module dup2.
55815         * m4/dup2.m4: New file.
55816
55817         Module ftruncate.
55818         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
55819         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
55820
55821         Module getgroups.
55822         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
55823         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
55824
55825         Module gettimeofday.
55826         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
55827         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
55828         gl_PREREQ_GETTIMEOFDAY.
55829
55830         Module mkdir.
55831         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
55832         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
55833
55834         Module mkstemp.
55835         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
55836         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
55837         jm_AC_TYPE_UINTMAX_T.
55838         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
55839
55840         Module stat.
55841         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
55842         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
55843
55844         Module lstat.
55845         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
55846         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
55847
55848         Module timespec.
55849         * m4/timespec.m4 (gl_TIMESPEC): New macro.
55850         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
55851         * m4/st_mtim.m4: Indentation.
55852
55853         Module nanosleep.
55854         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
55855         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
55856         gl_PREREQ_NANOSLEEP.
55857
55858         Module regex.
55859         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
55860         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
55861         (gl_REGEX): New macro.
55862
55863         Module rename.
55864         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
55865         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
55866
55867         Module rmdir.
55868         * m4/rmdir.m4: New file.
55869
55870         Module utime.
55871         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
55872         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
55873         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
55874
55875         Module dirname.
55876         * m4/dirname.m4: New file.
55877
55878         Module getopt.
55879         * m4/getopt.m4: New file.
55880
55881         Module unistd-safer.
55882         * m4/unistd-safer.m4: New file.
55883
55884         Module fnmatch.
55885         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
55886         declaration.
55887         (gl_PREREQ_FNMATCH_EXTRA): New macro.
55888         (gl_FUNC_FNMATCH_POSIX): New macro.
55889         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
55890         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
55891         simply fnmatch.
55892
55893         Module exclude.
55894         * m4/exclude.m4: New file.
55895
55896         Module human.
55897         * m4/human.m4: New file.
55898
55899         Module acl.
55900         * m4/acl.m4: Nop.
55901
55902         Module backupfile.
55903         * m4/backupfile.m4: New file.
55904         * m4/d-ino.m4: Indentation.
55905
55906         Module fsusage.
55907         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
55908         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
55909         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
55910
55911         Module dirfd.
55912         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
55913         requirements.
55914
55915         Module euidaccess.
55916         * m4/euidaccess.m4: New file.
55917
55918         Module file-type.
55919         * m4/file-type.m4: New file.
55920
55921         Module fileblocks.
55922         * m4/fileblocks.m4: New file.
55923
55924         Module filemode.
55925         * m4/filemode.m4: New file.
55926
55927         Module isdir.
55928         * m4/isdir.m4: New file.
55929
55930         Module lchown.
55931         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
55932         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
55933
55934         Module makepath.
55935         * m4/makepath.m4: New file.
55936
55937         Module modechange.
55938         * m4/modechange.m4: New file.
55939
55940         Module mountlist.
55941         * m4/mountlist.m4: New file.
55942         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
55943         Indentation.
55944
55945         Module path-concat.
55946         * m4/path-concat.m4: New file.
55947
55948         Module pathmax.
55949         * m4/pathmax.m4: New file.
55950
55951         Module same.
55952         * m4/same.m4: New file.
55953
55954         Module save-cwd.
55955         * m4/save-cwd.m4: New file.
55956
55957         Module savedir.
55958         * m4/savedir.m4: New file.
55959
55960         Module xgetcwd.
55961         * m4/xgetcwd.m4: New file.
55962         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
55963
55964         Module xreadlink.
55965         * m4/xreadlink.m4: New file.
55966
55967         Module safe-read.
55968         * m4/safe-read.m4: New file.
55969
55970         Module safe-write.
55971         * m4/safe-write.m4: New file.
55972
55973         Module closeout.
55974         * m4/closeout.m4: New file.
55975
55976         Module stdio-safer.
55977         * m4/stdio-safer.m4: New file.
55978
55979         Module getpass.
55980         * m4/getpass.m4: New file.
55981
55982         Module getugroups.
55983         * m4/getugroups.m4: New file.
55984
55985         Module group-member.
55986         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
55987         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
55988
55989         Module idcache.
55990         * m4/idcache.m4: New file.
55991
55992         Module userspec.
55993         * m4/userspec.m4: New file.
55994
55995         Module gettime.
55996         * m4/clock_time.m4: New file.
55997         * m4/gettime.m4: New file.
55998
55999         Module settime.
56000         * m4/settime.m4: New file.
56001
56002         Module posixtm.
56003         * m4/posixtm.m4: New file.
56004
56005         Module gethostname.
56006         * m4/gethostname.m4: New file.
56007
56008         Module canon-host.
56009         * m4/canon-host.m4: New file.
56010
56011         Module gettext.
56012         * m4/codeset.m4: New file, from gettext-0.11.5.
56013         * m4/gettext.m4: New file, from gettext-0.11.5.
56014         * m4/glibc21.m4: New file, from gettext-0.11.5.
56015         * m4/iconv.m4: New file, from gettext-0.11.5.
56016         * m4/intdiv0.m4: New file, from gettext-0.11.5.
56017         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
56018         * m4/inttypes.m4: New file, from gettext-0.11.5.
56019         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
56020         * m4/isc-posix.m4: New file, from gettext-0.11.5.
56021         * m4/lcmessage.m4: New file, from gettext-0.11.5.
56022         * m4/lib-ld.m4: New file, from gettext-0.11.5.
56023         * m4/lib-link.m4: New file, from gettext-0.11.5.
56024         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
56025         * m4/progtest.m4: New file, from gettext-0.11.5.
56026         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
56027         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
56028         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
56029
56030         Module localcharset.
56031         * m4/localcharset.m4: New file.
56032
56033         Module hard-locale.
56034         * m4/hard-locale.m4: New file.
56035
56036         Module mbswidth.
56037         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
56038         onceonly macros.
56039         * m4/mbrtowc.m4: Add comment.
56040
56041         Module memcasecmp.
56042         * m4/memcasecmp.m4: New file.
56043
56044         Module memcoll.
56045         * m4/memcoll.m4: New file.
56046
56047         Module unicodeio.
56048         * m4/unicodeio.m4: New file.
56049
56050         Module rpmatch.
56051         * m4/rpmatch.m4: New file.
56052
56053         Module yesno.
56054         * m4/yesno.m4: New file.
56055
56056         Module exitfail.
56057         * m4/exitfail.m4: New file.
56058
56059         Module c-stack.
56060         * m4/c-stack.m4 (gl_C_STACK): New macro.
56061         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
56062
56063         Module error.
56064         * m4/error.m4 (gl_ERROR): New macro.
56065         (jm_PREREQ_ERROR): Use onceonly macros.
56066
56067         Module fatal.
56068         * m4/fatal.m4: New file.
56069
56070         Module getloadavg.
56071         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
56072         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
56073
56074         Module getpagesize.
56075         * m4/getpagesize.m4: New file.
56076
56077         Module getusershell.
56078         * m4/getusershell.m4: New file.
56079
56080         Module physmem.
56081         * m4/physmem.m4: New file.
56082
56083         Module posixver.
56084         * m4/posixver.m4: New file.
56085
56086         Module quotearg.
56087         * m4/quotearg.m4: New file.
56088
56089         Module quote.
56090         * m4/quote.m4: New file.
56091
56092         Module readutmp.
56093         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
56094
56095         Module sig2str.
56096         * m4/sig2str.m4: New file.
56097
56098         Other.
56099         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
56100         ulonglong.m4.
56101         * m4/intmax_t.m4: New file.
56102         * m4/d-type.m4: Indentation.
56103         * m4/jm-macros.m4: Update.
56104         * m4/prereq.m4 (jm_PREREQ): Update.
56105         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
56106         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
56107         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
56108         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
56109         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
56110         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
56111         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
56112         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
56113         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
56114         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
56115         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
56116         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
56117         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
56118         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
56119         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
56120         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
56121         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
56122         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
56123         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
56124
56125 2002-12-24  Bruno Haible  <bruno@clisp.org>
56126
56127         * MODULES.txt: Update according to m4/ changes.
56128
56129         Module gettext.
56130         * config.rpath: New file, from gettext-0.11.5.
56131
56132         * modules/*: New module descriptions.
56133         * gnulib-tool: New file.
56134         * MODULES.html.sh: New file.
56135
56136 2002-12-21  Karl Berry  <karl@gnu.org>
56137
56138         * doc/fdl.texi: update to version 1.2.
56139
56140 2002-12-19  Karl Berry  <karl@gnu.org>
56141
56142         * config/config.guess: update from prep.
56143
56144 2002-12-18  Bruno Haible  <bruno@clisp.org>
56145
56146         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
56147         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
56148
56149 2002-12-17  Bruno Haible  <bruno@clisp.org>
56150
56151         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
56152         stdlib.h, string.h.
56153
56154 2002-12-17  Bruno Haible  <bruno@clisp.org>
56155
56156         * lib/canon-host.c (strdup): Remove unused declaration.
56157
56158         * lib/fsusage.c: Include full_read.h.
56159         (get_fs_usage): Use full_read instead of safe_read.
56160
56161         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
56162
56163 2002-12-12  Karl Berry  <karl@gnu.org>
56164
56165         * config/config.guess: update from prep.
56166
56167 2002-12-11  Bruno Haible  <bruno@clisp.org>
56168
56169         * m4/setenv.m4: New file, from gettext-0.11.5.
56170
56171 2002-12-11  Bruno Haible  <bruno@clisp.org>
56172
56173         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
56174         not unsetenv().
56175         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
56176         modifications:
56177
56178         2002-12-11  Bruno Haible  <bruno@clisp.org>
56179
56180                 * setenv.c (alloca): Fall back to malloc.
56181                 (freea): New macro.
56182                 (setenv): Use freea() to free memory allocated with alloca().
56183
56184         2002-11-13  Bruno Haible  <bruno@clisp.org>
56185
56186                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
56187                 function declarations.
56188                 * unsetenv.c (unsetenv): Likewise.
56189
56190         2002-03-04  Bruno Haible  <bruno@clisp.org>
56191
56192                 Portability to AIX 4.3.3.
56193                 * unsetenv.c: New file, extracted from setenv.c.
56194                 * setenv.c: Move the unsetenv() function to unsetenv.c.
56195
56196         2001-12-20  Bruno Haible  <bruno@clisp.org>
56197
56198                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
56199                 use malloc instead. For SunOS 4.
56200
56201         2001-12-11  Bruno Haible  <bruno@clisp.org>
56202
56203                 * setenv.c: Declare alloca.
56204                 (compar_fn_t): New typedef.
56205                 (KNOWN_VALUE, STORE_VALUE): Use it.
56206
56207         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
56208         setenv.h.
56209
56210 2002-12-10  Paul Eggert  <eggert@twinsun.com>
56211
56212         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
56213         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
56214         Choose values that are less likely to collide with system fnmatch
56215         options.
56216         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
56217         defined (e.g., a pure POSIX system).
56218         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
56219         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
56220
56221 2002-12-06  Paul Eggert  <eggert@twinsun.com>
56222
56223         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
56224         a pain in practice to deal with generated m4 files.  This change
56225         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
56226
56227         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
56228         and jm-glibc-io.m4, as they are no longer a special case.
56229         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
56230         kludge and the auto-generation stuff.  Check only whether the
56231         functions are declared, not whether they exist, since older hosts
56232         that don't declare the functions can't use the optimization anyway.
56233
56234 2002-12-06  Jim Meyering  <jim@meyering.net>
56235
56236         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
56237
56238         Merge in changes from libc's misc/error.c, in preparation
56239         for the merge of gnulib's changes back into libc.
56240
56241         * lib/error.c (_): Define only if not already defined.
56242         Move definition to follow all #include directives.
56243         Include unlocked-io.h only if !_LIBC.
56244         [_LIBC]: Include <libio/libioP.h>.
56245         [USE_IN_LIBIO]: Include <libio/iolibio.h>
56246         (fflush): Tweak definition to use INTUSE.
56247         (putc): Define.
56248
56249 2002-12-05  Paul Eggert  <eggert@twinsun.com>
56250
56251         * lib/alloca.c [defined emacs]: Include "lisp.h".
56252         (xalloc_die) [defined emacs]: New macro.
56253         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
56254         [! defined emacs]: Include <xalloc.h>.
56255         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
56256         (pointer): Typedef to POINTER_TYPE *.
56257         (malloc): Remove decl; we now always use xmalloc.
56258         (alloca): Use old-style definition, since Emacs needs this.
56259         Check for arithmetic overflow when computing combined size.
56260
56261 2002-12-04  Paul Eggert  <eggert@twinsun.com>
56262
56263         Do not generate unlocked-io.h automatically, since it's easier to
56264         maintain it by hand.
56265
56266         * lib/unlocked-io.h: New file, from GNU diffutils,
56267         but with proper copyright notice and attribution.
56268         * lib/gen-uio: Remove.
56269         * lib/Makefile.am: Add copyright notice.
56270         (libfetish_a_SOURCES): Add unlocked-io.h.
56271         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
56272         (DISTCLEANFILES, io_functions): Remove macros.
56273         (EXTRA_DIST): Remove gen_uio.
56274         (unlocked-io.h): Remove rule.
56275
56276 2002-12-04  Jim Meyering  <jim@meyering.net>
56277
56278         Reflect the fact that stat.c and lstat.c are no longer generated.
56279         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
56280         (DISTCLEANFILES): Likewise.
56281         (EXTRA_DIST): Likewise.
56282         (all_local): Don't depend on stat.c or lstat.c.
56283         (stat.c, lstat.c): Remove rules.
56284         (EXTRA_DIST): Remove xstat.in.
56285
56286         * lib/xstat.in: Remove file.  Contents moved into stat.c.
56287         * lib/stat.c: New file.  Contents mostly from xstat.in.
56288         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
56289         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
56290
56291         * lib/safe-read.c: Rework so that it may serve to define safe_write,
56292         too.
56293         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
56294
56295 2002-12-03  Jim Meyering  <jim@meyering.net>
56296
56297         * lib/safe-read.c, safe-write.c: Change variable names and comments,
56298         but not semantics, to minimize the differences between these two files.
56299         (safe_read): Change comment to mention SAFE_READ_ERROR.
56300
56301         * lib/safe-read.c (IS_EINTR): Define.
56302         (safe_read): Use IS_EINTR in place of in-function cpp directives.
56303
56304 2002-12-02  Jim Meyering  <jim@meyering.net>
56305
56306         * lib/safe-read.c (EINTR): Define.
56307         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
56308         (INT_MAX): Provide fallback.
56309         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
56310
56311         * lib/safe-read.h (SAFE_READ_ERROR): Define.
56312
56313 2002-12-02  Bruno Haible  <bruno@clisp.org>
56314
56315         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
56316         Define, taken from safe-read.c.
56317         (INT_MAX): Provide fallback.
56318         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
56319         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
56320
56321         * lib/safe-read.c (EINTR): Remove definition.
56322         (safe_read): Don't use EINTR if it is absent.
56323
56324 2002-12-01  Jim Meyering  <jim@meyering.net>
56325
56326         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
56327         zero.
56328         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
56329
56330 2002-11-27  Paul Eggert  <eggert@twinsun.com>
56331
56332         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
56333         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
56334         with `if (! (value < limit)) abort ();', for readability.
56335
56336 2002-11-26  Karl Berry  <karl@gnu.org>
56337
56338         * lib/strdup.c: copy from libc again, with jim's ok.
56339         * lib/.cppi-disable: re-add strdup.c
56340
56341 2002-11-25  Karl Berry  <karl@gnu.org>
56342
56343         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
56344         instead of "strtol.c".
56345
56346 2002-11-25  Karl Berry  <karl@gnu.org>
56347
56348         * config/install-sh: update from automake for variable quoting, $0 in
56349         error msgs, etc.
56350
56351         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
56352         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
56353         entry.
56354
56355 2002-11-25  Jim Meyering  <jim@meyering.net>
56356
56357         * lib/mktime.c: Sync from libc, now that it has the latest fix.
56358
56359 2002-11-24  Karl Berry  <karl@gnu.org>
56360
56361         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
56362         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
56363
56364 2002-11-24  Jim Meyering  <jim@meyering.net>
56365
56366         Update from coreutils:
56367
56368         * lib/mktime.c: Merge in changes from libc.
56369
56370         Avoid a link-time failure on some Linux systems.
56371         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
56372         (otherwise).
56373         (__mon_yday): Declare with the STATIC attribute.
56374         (__mktime_internal): Likewise.
56375         Based on a report from Greg Schafer.
56376
56377 2002-11-23  Jim Meyering  <jim@meyering.net>
56378
56379         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
56380         Use `unsigned', not `int', as type of index.
56381
56382         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
56383
56384         * lib/fsusage.c: Remove unneeded parentheses around operands of
56385         `defined'.
56386
56387 2002-11-22  Paul Eggert  <eggert@twinsun.com>
56388
56389         * lib/quotearg.h: Allow multiple inclusion by surrounding with
56390         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
56391         so that we can be included first.
56392         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
56393         * lib/quotearg.c: Include quotearg.h immediately after config.h.
56394         No need to include stddef.h or sys/types.h any more.
56395         Surround local include files with "", not "<>".
56396         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
56397         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
56398         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
56399         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
56400         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
56401         (ISPRINT): Remove; no longer needed now that we assume C89.
56402
56403         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
56404         Preserve errno.
56405
56406         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
56407         quotearg_char): Use SIZE_MAX rather than
56408         (size_t) -1 when we are talking about "infinity".
56409
56410         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
56411
56412 2002-11-22  Paul Eggert  <eggert@twinsun.com>
56413
56414         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
56415         hint that one should use `if (! x) abort ();' rather than `assert
56416         (x);', and anyway it's one less thing to worry about configuring.
56417         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
56418         hash_rehash, hash_insert): Use abort rather than assert.
56419
56420 2002-11-22  Bruno Haible  <bruno@clisp.org>
56421
56422         * lib/safe-read.h: Assume C89. Add comments.
56423         (safe_read): Change return type to size_t.
56424         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
56425         byte counts > SSIZE_MAX correctly.
56426         * lib/safe-write.h: New file.
56427         * lib/safe-write.c: New file.
56428         * lib/full-read.h: New file.
56429         * lib/full-read.c: New file.
56430         * lib/full-write.h: Assume C89. Add comments.
56431         * lib/full-write.c: Include safe-write.h.
56432         (full_write): Rewritten to use safe_write.
56433         Suggested by Jim Meyering and Paul Eggert.
56434
56435 2002-11-21  Jim Meyering  <jim@meyering.net>
56436
56437         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
56438
56439         Merge in changes from the coreutils.
56440
56441         2002-09-25  Paul Eggert  <eggert@twinsun.com>
56442         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
56443         <stdint.h>.
56444         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
56445         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
56446         int.  Work more efficiently if X is the same width as uintmax_t.
56447         Do not compare X to -1, to avoid bogus compiler warning.
56448         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
56449         Don't assume that f_frsize and f_bsize are the same type.
56450
56451         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
56452         warning on FreeBSD.
56453
56454         * lib/makepath.c (make_path): Restore umask *before* creating the final
56455         component.
56456         (make_path): Minor reformatting.
56457
56458         * lib/xmalloc.c: Adjust to work with new autoconf macros,
56459         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
56460         HAVE_MALLOC/HAVE_REALLOC.
56461
56462         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
56463         dummy ones.  At least on GNU/Linux systems, `auto' means something
56464         else.
56465         From Michael Stone.
56466
56467 2002-11-21  Bruno Haible  <bruno@clisp.org>
56468
56469         Remove case insensitive option matching.
56470         * lib/argmatch.h (argcasematch): Remove declaration.
56471         (ARGCASEMATCH): Remove macro.
56472         (__xargmatch_internal): Remove case_sensitive argument.
56473         (XARGMATCH): Update.
56474         (XARGCASEMATCH): Remove macro.
56475         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
56476         case_sensitive argument.
56477         (argcasematch): Remove function.
56478         (__xargmatch_internal): Remove case_sensitive argument.
56479         (main): Use XARGMATCH instead of XARGCASEMATCH.
56480
56481         * lib/xmalloc.c: Change compile-time error message. Add comment about
56482         required autoconf version.
56483
56484 2002-11-20  Paul Eggert  <eggert@twinsun.com>
56485
56486         Merge argmatch cleanups from Bison.  Assume C89.
56487
56488         * lib/argmatch.c: Include config.h here, not in argmatch.h.
56489         Include stdlib.h, for EXIT_FAILURE.
56490         Always include <string.h>, since we assume C89.
56491         (EXIT_FAILURE): Remove pre-C89 bug workaround.
56492         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
56493         Include <stddef.h> instead, since it's all we need for size_t.
56494         (PARAMS): Remove.  All uses removed.
56495         (ARRAY_CARDINALITY): Do not bother to #undef.
56496         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
56497         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
56498         Remove unnecessary parentheses.
56499         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
56500         Insert necessary parentheses.
56501         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
56502         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
56503
56504 2002-11-19  Bruno Haible  <bruno@clisp.org>
56505
56506         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
56507         * lib/mbswidth.h: Include <stddef.h>, for size_t.
56508
56509         * lib/mbswidth.h (PARAMS): Remove macro.
56510         (mbswidth, mbsnwidth): Use ANSI C function declarations.
56511         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
56512
56513         * lib/gcd.h (PARAMS): Remove macro.
56514         (gcd): Use ANSI C function declarations.
56515         * lib/gcd.c (gcd): Likewise.
56516
56517 2002-11-15  Bruno Haible  <bruno@clisp.org>
56518
56519         * lib/strcspn.c: Include <stddef.h>.
56520         (strcspn): Use ANSI C function declaration. Change return type to
56521         size_t. Use NULL.
56522         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
56523         (strpbrk): Use NULL.
56524         * lib/strpbrk.h (PARAMS): Remove macro.
56525         (strpbrk): Use ANSI C function declaration.
56526         * lib/strstr.c: Don't include <sys/types.h>.
56527         * lib/strstr.h (PARAMS): Remove macro.
56528         (strstr): Use ANSI C function declarations.
56529
56530 2002-11-14  Karl Berry  <karl@gnu.org>
56531
56532         * config/mkinstalldirs: `do' on separate line, instead of
56533         `for var; do'.
56534
56535 2002-11-06  Bruno Haible  <bruno@clisp.org>
56536
56537         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
56538         * lib/gcd.c (gcd): Likewise.
56539
56540 2002-11-05  Bruno Haible  <bruno@clisp.org>
56541
56542         * lib/gcd.h: New file, from gettext-0.11.5.
56543         * lib/gcd.c: New file, from gettext-0.11.5.
56544
56545 2002-11-05  Bruno Haible  <bruno@clisp.org>
56546
56547         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
56548         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
56549         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
56550         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
56551
56552         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
56553         <libintl.h>.
56554         * lib/makepath.c: Include gettext.h instead of <locale.h> and
56555         <libintl.h>.
56556
56557         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
56558         * lib/human.c: Include gettext.h instead of <libintl.h>.
56559         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
56560         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
56561         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
56562         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
56563         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
56564         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
56565         (textdomain): Remove definition.
56566         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
56567
56568         * lib/long-options.c: Remove include of <libintl.h> and definition of
56569         _.
56570         * lib/same.c: Remove include of <libintl.h> and definition of _.
56571
56572 2002-11-04  Owen Taylor  <otaylor@redhat.com>
56573
56574         * lib/config.charset: A few additions for Solaris.
56575
56576 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
56577
56578         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
56579         * lib/localcharset.c (locale_charset): Declare as extern "C".
56580
56581 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
56582
56583         * lib/config.charset: msdos in uk_UA uses CP1125.
56584
56585 2002-11-04  Bruno Haible  <bruno@clisp.org>
56586
56587         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
56588         * lib/strcase.h: New file, from GNU gettext-0.11.5.
56589         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
56590         * lib/strstr.h: New file, from GNU gettext-0.11.5.
56591         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
56592
56593 2002-11-04  Bruno Haible  <bruno@clisp.org>
56594
56595         * lib/localcharset.c (locale_charset): Don't return an empty string.
56596
56597 2002-11-04  Bruno Haible  <bruno@clisp.org>
56598
56599         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
56600         aliases.
56601
56602 2002-11-04  Bruno Haible  <bruno@clisp.org>
56603
56604         * lib/config.charset: Update for newest glibc. Add canonical names
56605         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
56606
56607 2002-11-04  Bruno Haible  <bruno@clisp.org>
56608
56609         * lib/config.charset: Add support for NetBSD.
56610
56611 2002-11-04  Bruno Haible  <bruno@clisp.org>
56612
56613         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
56614
56615 2002-11-01  Bruno Haible  <bruno@clisp.org>
56616
56617         * configure.in: Add AC_CONFIG_AUX_DIR call.
56618         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
56619         test/Makefile.
56620         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
56621
56622 2002-09-28  Karl Berry  <karl@gnu.org>
56623
56624         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
56625         installed automake until the next release, since changes have been
56626         made.
56627
56628 2002-09-25  Karl Berry  <karl@gnu.org>
56629
56630         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
56631         * lib/getopt*: copy from libc/posix.
56632         * lib/gettext.h: copy from gettext.
56633         * lib/.cppi-disable: add strdup.c, gettext.h.
56634
56635 2002-09-25  Karl Berry  <karl@gnu.org>
56636
56637         * config/srclist.txt: enable gettext.h check.
56638         * config/config.{guess,sub}: update from prep.
56639         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
56640                 from automake 1.6.3.
56641         See srclist*.
56642
56643 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
56644
56645         * regex.c (PATFETCH): Remove the translating fetch.
56646         (PATFETCH_RAW): Rename to PATFETCH.
56647         (set_image_of_range): New fun.
56648         (SET_RANGE_TABLE_WORK_AREA): Use it.
56649         (regex_compile): Don't translate the pattern chars so eagerly.
56650         Only do it when inserting an `exactn' bytecode or when handling
56651         a char-range.
56652         (mutually_exclusive_p): Avoid empty statement.
56653
56654 2002-07-06  Jim Meyering  <meyering@lucent.com>
56655
56656         * m4/README: Don't mention Makefile.am.in.
56657         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
56658
56659 2002-07-01  Jim Meyering  <meyering@lucent.com>
56660
56661         * lib/c-stack.c: Include sys/time.h.
56662         From Volker Borchert.
56663
56664 2002-06-26  Paul Eggert  <eggert@twinsun.com>
56665
56666         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
56667
56668 2002-06-26  Paul Eggert  <eggert@twinsun.com>
56669
56670         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
56671         New macro.  Use it uniformly instead of
56672         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
56673         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
56674         reported by Vin Shelton.
56675
56676 2002-06-22  Paul Eggert  <eggert@twinsun.com>
56677
56678         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
56679         Do not assume SA_SIGINFO behavior.
56680         Bug reported by Jim Meyering on NetBSD 1.5.2.
56681
56682 2002-06-22  Jim Meyering  <meyering@lucent.com>
56683
56684         * m4/c-stack.m4: New file, from diffutils-2.8.2.
56685         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
56686
56687         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
56688         now that configure.ac uses AC_GNU_SOURCE.
56689         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
56690         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
56691
56692         Update to latest tools.  Suggestions from Paul Eggert.
56693         * m4/stdbool.m4: New file, from diffutils-2.8.2.
56694         * m4/gnu-source.m4: Update from diffutils-2.8.2.
56695         * m4/fnmatch.m4: Likewise.
56696         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
56697         to AC_HEADER_STDBOOL
56698
56699 2002-06-22  Jim Meyering  <meyering@lucent.com>
56700
56701         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
56702         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
56703
56704 2002-06-22  Jim Meyering  <meyering@lucent.com>
56705
56706         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
56707
56708         * lib/exitfail.c, exitfail.h: Likewise.
56709         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
56710
56711         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
56712         of fnmatch.h.
56713         (EXTRA_DIST): Add fnmatch_loop.c.
56714         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
56715
56716         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
56717         * lib/fnmatch.c: Update from diffutils-2.8.2.
56718         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
56719         * lib/fnmatch.h: Remove file.
56720
56721 2002-06-21  Jim Meyering  <meyering@lucent.com>
56722
56723         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
56724         * m4/mbrtowc.m4: Likewise.
56725
56726         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
56727         * m4/mbswidth.m4: Reflect name change:
56728         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
56729         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
56730
56731         * m4/lib-link.m4: Update from gettext-0.11.2.
56732         * m4/gettext.m4: Likewise.
56733
56734         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
56735         From Alfred M. Szmidt.
56736
56737 2002-06-18  Paul Eggert  <eggert@twinsun.com>
56738
56739         * lib/file-type.h: Report an error if neither S_ISREG nor
56740         S_IFREG is defined, instead of using a test specific to glibc
56741         2.2.  This should be safe, since POSIX requires S_ISREG and
56742         Unix Version 7 had S_IFREG.  We don't need to check for
56743         <sys/types.h> since we don't use any symbols that it defines.
56744
56745 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
56746
56747         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
56748         $@-t, so that each temporary file name is unique and valid in the first
56749         8 characters, for operation under DOS.
56750
56751 2002-06-15  Paul Eggert  <eggert@twinsun.com>
56752
56753         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
56754
56755 2002-06-15  Jim Meyering  <meyering@lucent.com>
56756
56757         Work even with DJGPP 2.03, which lacks support for symlinks.
56758         From Richard Dawe.
56759         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
56760         is defined.
56761         * lib/lchown.c (S_ISLNK): Likewise.
56762
56763 2002-06-15  Jim Meyering  <meyering@lucent.com>
56764
56765         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
56766         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
56767         have been included before this file.
56768
56769 2002-06-14  Jim Meyering  <meyering@lucent.com>
56770
56771         * lib/file-type.h: Use the version from diffutils-2.8.2.
56772         * lib/file-type.c: Likewise.
56773
56774 2002-06-07  Jim Meyering  <meyering@lucent.com>
56775
56776         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
56777         They're needed at least for NetBSD 1.5.2.
56778         ($statxfs_includes): Include those same headers.
56779         ($statxfs_includes): Include sys/vfs.h if available.
56780         ($statxfs_includes): Likewise for sys/statvfs.h.
56781         Check for the following members in both structs statfs and statvfs:
56782         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
56783
56784 2002-06-01  Jim Meyering  <meyering@lucent.com>
56785
56786         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
56787         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
56788
56789 2002-05-28  Jim Meyering  <meyering@lucent.com>
56790
56791         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
56792         Reported by Volker Borchert.
56793
56794 2002-05-27  Jim Meyering  <meyering@lucent.com>
56795
56796         Fix a problem seen only on nonconforming systems whereby ls.c's
56797         use of localtime, and then of gettimeofday would cause trouble:
56798         the localtime call used to initialize rpl_gettimeofday's save
56799         mechanism would clobber ls's current local time information so
56800         that in any long listing the first file would always be listed
56801         with date 1970-01-01.  Analysis by Volker Borchert.
56802
56803         * lib/gettimeofday.c (localtime): Undefine.
56804         (rpl_localtime): New function.
56805
56806 2002-05-27  Jim Meyering  <meyering@lucent.com>
56807
56808         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
56809         localtime.
56810
56811         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
56812         use the replacement function; it wouldn't resolve at link time.
56813         Reported by Volker Borchert.
56814
56815 2002-05-22  Jim Meyering  <meyering@lucent.com>
56816
56817         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
56818         file-type.h.
56819         * lib/file-type.h: New file.
56820         * lib/file-type.c (file_type): New file/function.  Extracted from
56821         diffutils.
56822
56823 2002-04-30  Jim Meyering  <meyering@lucent.com>
56824
56825         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
56826
56827 2002-04-29  Paul Eggert  <eggert@twinsun.com>
56828
56829         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
56830
56831 2002-04-29  Paul Eggert  <eggert@twinsun.com>
56832
56833         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
56834         Do not check for alloca.h (no longer used) or stdbool.h (was never
56835         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
56836
56837 2002-04-29  Paul Eggert  <eggert@twinsun.com>
56838
56839         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
56840
56841 2002-04-29  Jim Meyering  <meyering@lucent.com>
56842
56843         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
56844         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
56845         Use AC_FUNC_STRNLEN here instead.
56846
56847         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
56848         With autoconf-2.53a, it's part of AC_PROG_CC.
56849
56850 2002-04-28  Paul Eggert  <eggert@twinsun.com>
56851
56852         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
56853         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
56854
56855 2002-04-28  Paul Eggert  <eggert@twinsun.com>
56856
56857         * lib/sig2str.h, lib/sig2str.c: New files.
56858         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
56859
56860 2002-04-28  Paul Eggert  <eggert@twinsun.com>
56861
56862         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
56863         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
56864         of 127, since 64 is the largest conceivable number for ancient
56865         nonstandard hosts.
56866         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
56867
56868 2002-04-28  Jim Meyering  <meyering@lucent.com>
56869
56870         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
56871
56872 2002-04-24  Jim Meyering  <meyering@lucent.com>
56873
56874         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
56875         (jm_PREREQ): Use it.
56876
56877         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
56878         mach/mach.h fcntl.h.
56879         Check for this function: setlocale.
56880
56881 2002-04-24  Jim Meyering  <meyering@lucent.com>
56882
56883         * lib/gettext.h: New file, from Gettext.
56884         * lib/Makefile.am (INCLUDES): Remove -I../intl.
56885         (libfetish_a_SOURCES): Add gettext.h.
56886
56887 2002-04-16  Jim Meyering  <meyering@lucent.com>
56888
56889         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
56890         ut_pid, ut_id, ut_exit.
56891
56892 2002-04-16  Jim Meyering  <meyering@lucent.com>
56893
56894         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
56895         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
56896         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
56897
56898 2002-04-12  Jim Meyering  <meyering@lucent.com>
56899
56900         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
56901         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
56902         existence of the getmntinfo function.  Needed for Darwin 5.3.
56903
56904         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
56905         This is necessary at least on Darwin 5.3.
56906
56907         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
56908         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
56909         strnlen.o in the library, and that makes some versions of ranlib
56910         object.
56911
56912 2002-04-12  Jim Meyering  <meyering@lucent.com>
56913
56914         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
56915
56916 2002-04-09  Jim Meyering  <meyering@lucent.com>
56917
56918         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
56919         to be more precise.  Rather than saying we're checking whether the
56920         function `works', say what we're testing.
56921         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
56922         Reported by Bruno Haible.
56923
56924 2002-03-10  Jim Meyering  <meyering@lucent.com>
56925
56926         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
56927         Suggestion from Santiago Vila.
56928
56929 2002-03-08  Jim Meyering  <meyering@lucent.com>
56930
56931         * lib/rename.c: Mention that this wrapper is needed also on
56932         mips-dec-ultrix4.4 systems.
56933
56934 2002-03-02  Jim Meyering  <meyering@lucent.com>
56935
56936         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
56937         not HAVE_CLOCK_SETTIME.
56938
56939 2002-02-27  Paul Eggert  <eggert@twinsun.com>
56940
56941         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
56942         Check for clock_settime.
56943
56944 2002-02-27  Paul Eggert  <eggert@twinsun.com>
56945
56946         * lib/nanosleep.h: Rename to....
56947         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
56948
56949         * lib/gettime.c: New file.
56950         * lib/settime.c: New file.
56951         * lib/stime.c: Remove.
56952
56953         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
56954         timespec.h.  Remove nanosleep.h.
56955
56956 2002-02-25  Paul Eggert  <eggert@twinsun.com>
56957
56958         * m4/acl.m4: New file.
56959         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
56960         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
56961
56962 2002-02-25  Paul Eggert  <eggert@twinsun.com>
56963
56964         * lib/acl.c, lib/acl.h: New files.
56965         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
56966
56967 2002-02-24  Jim Meyering  <meyering@lucent.com>
56968
56969         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
56970         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
56971         cause trouble.  Reported by Nelson Beebe.
56972
56973 2002-02-23  Paul Eggert  <eggert@twinsun.com>
56974
56975         * lib/path-concat.c (xpath_concat): Reorder code to pacify
56976         compilers that don't know that xalloc_die never returns.
56977
56978 2002-02-20  Jim Meyering  <meyering@lucent.com>
56979
56980         * lib/getdate.c: Regenerate using bison-1.33.
56981
56982 2002-02-17  Jim Meyering  <meyering@lucent.com>
56983
56984         * config/config.guess (main): Don't use `head -1'; it's no longer
56985         portable. Use `sed 1q' instead.
56986
56987 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
56988
56989         * m4/codeset.m4: Upgrade to gettext-0.11.
56990         * m4/gettext.m4: Upgrade to gettext-0.11.
56991         * m4/glibc21.m4: Upgrade to gettext-0.11.
56992         * m4/iconv.m4: Upgrade to gettext-0.11.
56993         * m4/isc-posix.m4: Upgrade to gettext-0.11.
56994         * m4/lcmessage.m4: Upgrade to gettext-0.11.
56995         * m4/lib-ld.m4: New file, from gettext-0.11.
56996         * m4/lib-link.m4: New file, from gettext-0.11.
56997         * m4/lib-prefix.m4: New file, from gettext-0.11.
56998         * m4/progtest.m4: Upgrade to gettext-0.11.
56999
57000 2002-02-15  Paul Eggert  <eggert@twinsun.com>
57001
57002         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
57003         (jm_PREREQ): Use it.
57004
57005 2002-02-15  Paul Eggert  <eggert@twinsun.com>
57006
57007         * lib/posixver.c, lib/posixver.h: New files.
57008         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
57009
57010 2002-02-02  Paul Eggert  <eggert@twinsun.com>
57011             Bruno Haible  <bruno@clisp.org>
57012
57013         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
57014         (fwrite_success_callback): New declaration.
57015         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
57016         print_unicode_char. Call failure callback instead of error.
57017         (fwrite_success_callback): New function.
57018         (exit_failure_callback): New function.
57019         (fallback_failure_callback): New function.
57020         (print_unicode_char): Call unicode_to_mb.
57021
57022 2002-01-26  Jim Meyering  <meyering@lucent.com>
57023
57024         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
57025         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
57026
57027 2002-01-26  Jim Meyering  <meyering@lucent.com>
57028
57029         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
57030
57031 2002-01-22  Paul Eggert  <eggert@twinsun.com>
57032
57033         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
57034
57035 2002-01-22  Jim Meyering  <meyering@lucent.com>
57036
57037         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
57038         Otherwise, some versions of automake would omit the rule that makes
57039         Makefile from Makefile.in.
57040
57041 2002-01-21  Paul Eggert  <eggert@twinsun.com>
57042
57043         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
57044         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
57045         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
57046         (memcoll): Set errno to zero if there is no error.
57047
57048         * lib/quotearg.c (quotearg_buffer_restyled):
57049         Fix bug with quoting buffers containing NUL when backslashing escapes.
57050         This bug was exposed by the other changes in this patch.
57051         (quotearg_n_options): New arg ARGSIZE.
57052         All callers changed.
57053         (quoting_options_from_style): New function.
57054         (quotearg_n_style): Use it.
57055         (quotearg_n_style_mem): New function.
57056
57057         * lib/quotearg.h (quotearg_n_style_mem): New function.
57058
57059 2002-01-19  Jim Meyering  <meyering@lucent.com>
57060
57061         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
57062         Remove useless quotes: DF_PROG="df".
57063         * m4/strnlen.m4: New file.
57064
57065 2002-01-16  Paul Eggert  <eggert@twinsun.com>
57066
57067         * lib/backupfile.c (ISDIGIT): Comment fix.
57068         * lib/getdate.y (ISDIGIT): Likewise.
57069         * lib/posixtm.c (ISDIGIT, year): Likewise.
57070         * lib/strverscmp.c (ISDIGIT): Likewise.
57071         * lib/userspec.c (ISDIGIT): Likewise.
57072
57073 2002-01-16  Jim Meyering  <meyering@lucent.com>
57074
57075         * lib/getdate.y: Add three semicolons, each just before a closing
57076         brace. Bison (as of version 1.31) no longer papers over that mistake.
57077
57078 2002-01-05  Jim Meyering  <meyering@lucent.com>
57079
57080         * lib/version-etc.c (version_etc_copyright): Update copyright year.
57081
57082 2001-12-19  Paul Eggert  <eggert@twinsun.com>
57083
57084         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
57085         not silently exit merely because the output buffer happens to
57086         have nothing pending.
57087
57088 2001-12-18  Paul Eggert  <eggert@twinsun.com>
57089
57090         See the big note in ../ChangeLog.
57091         * lib/human.c (suffixes): Prefer K to k for 1024.
57092         (generate_suffix_backwards): New function.
57093         (human_readable_inexact): Use it.
57094         * lib/xstrtol.c (__xstrtol): If there is no number but there
57095         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
57096         Accept 'K' as well as 'k'.
57097
57098 2001-12-15  Jim Meyering  <meyering@lucent.com>
57099
57100         * lib/regex.h (__restrict_arr): Update from libc.
57101
57102         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
57103         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
57104         (STREQ): Define.
57105
57106 2001-12-14  Jim Meyering  <meyering@lucent.com>
57107
57108         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
57109         Suggestion from Bruno Haible.
57110
57111 2001-12-10  Jim Meyering  <meyering@lucent.com>
57112
57113         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
57114         xrealloc, Instead, include "xalloc.h".
57115         (initbuffer): Don't cast xmalloc return value to char*.
57116         (readline): Reword comment.
57117         Don't cast xrealloc return value to char*
57118         Return NULL, not 0.
57119
57120 2001-12-09  Jim Meyering  <meyering@lucent.com>
57121
57122         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
57123         about `signed and unsigned type in conditional expression'.
57124         * lib/posixtm.c (posix_time_parse): Likewise.
57125
57126         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
57127
57128         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
57129         to avoid a pedantic warning.
57130
57131         * lib/getstr.c: Don't include assert.h.
57132         (getstr): Remove warning-evoking assertions.
57133         Return -1 if offset parameter is out of bounds.
57134         Change the type of a local from int to size_t.
57135
57136         * lib/strftime.c (my_strftime_localtime_r): Include this function
57137         definition in the `#if ! HAVE_TM_GMTOFF' block.
57138
57139         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
57140         Include xalloc.h instead.
57141
57142 2001-12-02  Jim Meyering  <meyering@lucent.com>
57143
57144         * lib/tempname.c: Don't declare getenv, thus reverting the change of
57145         2001-11-18.  It's no longer necessary, now that stdlib.h is always
57146         included.
57147
57148         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
57149         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
57150
57151 2001-11-30  Akim Demaille  <akim@epita.fr>
57152
57153         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
57154         before being defined.
57155
57156 2001-11-27  Paul Eggert  <eggert@twinsun.com>
57157
57158         * lib/quotearg.h (quotearg_n, quotearg_n_style):
57159         First arg is int, not unsigned.
57160         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
57161         (SIZE_MAX, UINT_MAX): New macros.
57162         (quotearg_n_options): Abort if N is negative.
57163         Avoid overflow check on hosts where size_t is 64 bits and int
57164         is 32 bits, as overflow is impossible there.
57165         Fix off-by-one typo that caused unnecessary reallocation.
57166
57167 2001-11-27  Jim Meyering  <meyering@lucent.com>
57168
57169         * lib/tempname.c: Merge with version from libc.
57170         * lib/regex.c: Likewise.
57171
57172         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
57173         systems for which STDC_HEADERS is 0, it was not included, resulting in
57174         a warning about an integer-to-pointer conversion problem with getenv.
57175         Reported by Volker Borchert.
57176
57177 2001-11-26  Jim Meyering  <meyering@lucent.com>
57178
57179         * lib/gtod.h: Remove file.
57180         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
57181         * lib/gettimeofday.c: Don't include gtod.h.
57182         (GTOD_init): Remove function.
57183         (rpl_gettimeofday): Do its job here instead, rather than aborting.
57184         Suggestion from Volker Borchert.
57185
57186 2001-11-23  Jim Meyering  <meyering@lucent.com>
57187
57188         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
57189         it.
57190         * lib/hash.c (struct hash_table): Define it here instead.
57191
57192 2001-11-22  Jim Meyering  <meyering@lucent.com>
57193
57194         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
57195
57196 2001-11-20  Jim Meyering  <meyering@lucent.com>
57197
57198         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
57199         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
57200
57201 2001-11-19  Jim Meyering  <meyering@lucent.com>
57202
57203         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
57204         directory.  Use "conftestXXXXXX" as the template.
57205         Suggestion from Paul Eggert.
57206
57207         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
57208         immediately, so the test doesn't mistakenly hit the max-open-files
57209         limit.
57210
57211 2001-11-18  Paul Eggert  <eggert@twinsun.com>
57212
57213         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
57214         (TEMPORARIES): New macro.
57215         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
57216         removes an artificial limitation (e.g. HP-UX 10.20, where
57217         TMP_MAX is 17576).
57218
57219 2001-11-18  Jim Meyering  <meyering@lucent.com>
57220
57221         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
57222
57223 2001-11-18  Jim Meyering  <meyering@lucent.com>
57224
57225         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
57226         on SunOS 4.
57227
57228         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
57229         files will be created before anything else.
57230
57231 2001-11-17  Paul Eggert  <eggert@twinsun.com>
57232
57233         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
57234         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
57235
57236 2001-11-17  Jim Meyering  <meyering@lucent.com>
57237
57238         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
57239         Prompted by a report from Bob Proulx.
57240
57241         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
57242         Instead, require UTILS_FUNC_MKSTEMP.
57243
57244 2001-11-17  Jim Meyering  <meyering@lucent.com>
57245
57246         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
57247         Now, that's done as part of AC_FUNC_STRTOD.
57248
57249 2001-11-17  Jim Meyering  <meyering@lucent.com>
57250
57251         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
57252         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
57253         rather than group writable.  Patch by Juan F. Codagnone.
57254
57255         * lib/readtokens.c: Remove explicit declarations of xmalloc and
57256         xrealloc, Instead, include "xalloc.h".
57257
57258         * lib/mountlist.c: Include unlocked-io.h after all system headers.
57259         Remove explicit declarations of xmalloc, xrealloc,
57260         and xstrdup.  Instead, include "xalloc.h".
57261
57262         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
57263         unlocked-io.h.
57264         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
57265         Likewise.
57266         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
57267
57268         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
57269         Reported by Padraig Brady.
57270
57271         * lib/mkstemp.c: #undef mkstemp.
57272         Include config.h.
57273         (rpl_mkstemp): Rename from mkstemp.
57274         Protoize.
57275
57276 2001-11-16  Jim Meyering  <meyering@lucent.com>
57277
57278         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
57279         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
57280         determine the amount of total physical memory, use pstat_getstatic.
57281         HPUX-11 doesn't define _SC_PHYS_PAGES.
57282         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
57283         If sysconf couldn't be used to determine the amount of available
57284         physical memory, use both pstat_getstatic and pstat_getdynamic.
57285         Based on a patch from Bob Proulx.
57286
57287 2001-11-10  Jim Meyering  <meyering@lucent.com>
57288
57289         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
57290         (jm_PREREQ): Use it.
57291
57292 2001-11-09  Jim Meyering  <meyering@lucent.com>
57293
57294         * m4/jm-macros.m4: Require autoconf-2.52f.
57295         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
57296         Use these AC_-prefixed names, not the AM_-prefixed ones.
57297
57298         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
57299
57300 2001-11-05  Jim Meyering  <meyering@lucent.com>
57301
57302         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
57303
57304 2001-11-04  Jim Meyering  <meyering@lucent.com>
57305
57306         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
57307         $DEFS.
57308
57309 2001-11-03  Jim Meyering  <meyering@lucent.com>
57310
57311         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
57312         of AC_DEFUN.
57313
57314         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
57315         know the name of the variable in the macro definition.
57316
57317 2001-11-03  Jim Meyering  <meyering@lucent.com>
57318
57319         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
57320         in argmatch_to_argument call.
57321
57322         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
57323         argument.
57324
57325         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
57326         e.g., a fault due to an attempt to free a NULL pointer.
57327
57328 2001-11-01  Jim Meyering  <meyering@lucent.com>
57329
57330         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
57331         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
57332
57333 2001-11-01  Jim Meyering  <meyering@lucent.com>
57334
57335         * lib/dirfd.c, lib/dirfd.h: New files.
57336         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
57337
57338         * lib/hash.c (hash_print) [TESTING]: Clean up.
57339
57340 2001-10-22  Paul Eggert  <eggert@twinsun.com>
57341
57342         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
57343         to avoid a warning if -Wall.
57344
57345 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
57346
57347         * README: New file
57348         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
57349         (per RMS's instructions, this is now the canonical source)
57350         * lgpl/, gpl/: New directories.
57351
57352 2001-10-21  Paul Eggert  <eggert@twinsun.com>
57353
57354         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
57355
57356 2001-10-21  Jim Meyering  <meyering@lucent.com>
57357
57358         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
57359         this code would end up calling gettext even in packages built
57360         with --disable-nls.
57361         * lib/getopt.c (_): Likewise.
57362         * lib/regex.c (_): Likewise.
57363
57364 2001-10-20  Paul Eggert  <eggert@twinsun.com>
57365
57366         * m4/error.m4 (jm_PREREQ_ERROR):
57367         Do not invoke AC_CHECK_FUNCS with strerror_r, as
57368         AC_FUNC_STRERROR_R does that.
57369         Check for strerror declaration.
57370
57371         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
57372         are supposed to have them these days.
57373         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
57374         Merge changes from latest Autoconf CVS.
57375         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
57376         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
57377         POSIX decided to standardize on the int flavor of strerror_r.
57378
57379 2001-10-20  Paul Eggert  <eggert@twinsun.com>
57380
57381         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
57382         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
57383         Use strerror_r that is only a macro, even if it is not a function.
57384         (strerror): Check for HAVE_DECL_STRERROR before declaring.
57385         (private_strerror): Use prototypes, not old-style function definition.
57386         (print_errno_message): New function.
57387         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
57388         char*-flavored one.
57389         (error_tail, error, error_at_line): Use it.
57390
57391 2001-10-11  Jim Meyering  <meyering@lucent.com>
57392
57393         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
57394         and quote_n (1, ... to avoid clobbering a buffer.
57395
57396 2001-10-05  Jim Meyering  <meyering@lucent.com>
57397
57398         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
57399         hash-pjw.h.
57400         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
57401         * lib/hash-pjw.h: New file.
57402
57403 2001-09-30  Jim Meyering  <meyering@lucent.com>
57404
57405         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
57406         `struct fsstat' has the `f_fstypename' member.
57407         Use that to define FS_TYPE, which is now used to make
57408         the getfsstat link test tighter.
57409
57410 2001-09-30  Jim Meyering  <meyering@lucent.com>
57411
57412         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
57413         Include <sys/ucred.h>, for Apple Darwin.
57414         Include sys/mount.h and sys/fs_types.h only if available.
57415         (FS_TYPE): Define.
57416         (read_filesystem_list): Use FS_TYPE.
57417
57418 2001-09-29  Paul Eggert  <eggert@twinsun.com>
57419
57420         * lib/exclude.c (excluded_filename): 0 -> false, since it's
57421         a boolean context.
57422
57423 2001-09-29  Jim Meyering  <meyering@lucent.com>
57424
57425         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
57426         [one-argument getmntent function]): Include stdio.h before mntent.h.
57427         SunOS 4.1.x needs it for the declaration of `FILE'.
57428         Patch by Volker Borchert.
57429
57430         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
57431         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
57432         sys/fs_types.h, and make the link-test for getfsstat guard #include
57433         directives with appropriate #if HAVE_*_H tests so that we can
57434         detect getfsstat on Apple Darwin1.3.7 systems.
57435         Reported by Nelson Beebe.
57436         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
57437
57438 2001-09-28  Paul Eggert  <eggert@twinsun.com>
57439
57440         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
57441         #defines strtoimax.  Also treat the other strto* functions
57442         like strtoimax.
57443
57444         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
57445         Check for strtoul and strtoumax,
57446         as those declarations are made even in the signed case.
57447         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
57448         Likewise, for strtol and strtoimax.
57449
57450 2001-09-28  Paul Eggert  <eggert@twinsun.com>
57451
57452         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
57453         #defines strtoimax.  Also treat the other strto* functions
57454         like strtoimax.
57455
57456         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
57457         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
57458         (strtoimax, strtoumax): Do not declare if already defined as a macro.
57459
57460 2001-09-26  Jim Meyering  <meyering@lucent.com>
57461
57462         Most macros in unlocked-io.h had the wrong number of arguments.
57463         * lib/gen-uio: New script.
57464         (USE_UNLOCKED_IO): Define to 1 if not already defined.
57465         * lib/unlocked-io.hin: Remove file.
57466         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
57467         rather than trying to embed it here.
57468         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
57469         Reported by Padraig Brady.
57470
57471 2001-09-25  Volker Borchert  <bt@teknon.de>
57472
57473         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
57474         `result'.
57475
57476 2001-09-24  Jim Meyering  <meyering@lucent.com>
57477
57478         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
57479
57480 2001-09-23  Jim Meyering  <meyering@lucent.com>
57481
57482         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
57483         instead of the mere test for existence of mntent.h.  The latter
57484         would get a false-positive on AIX 3.4 systems.
57485         In the outer getmntent if-block, don't die if neither of the getmntent
57486         tests succeeds.  Instead, just fall through and continue with the
57487         remaining tests.
57488
57489 2001-09-23  Jim Meyering  <meyering@lucent.com>
57490
57491         * lib/mountlist.c: Remove useless parentheses in #if directives.
57492         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
57493         the deprecated MOUNTED symbol is no longer defined in mntent.h.
57494
57495 2001-09-22  Jim Meyering  <meyering@lucent.com>
57496
57497         * m4/gettext.m4: New file.  From gettext.
57498         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
57499         * m4/progtest.m4: Likewise
57500         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
57501         * m4/glibc21.m4: Likewise.
57502
57503         * m4/libintl.m4: Remove.  No longer used.
57504
57505 2001-09-22  Jim Meyering  <meyering@lucent.com>
57506
57507         * lib/localcharset.c: Update from latest gettext.
57508         * lib/config.charset: Likewise.
57509
57510 2001-09-20  Jim Meyering  <meyering@lucent.com>
57511
57512         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
57513         strtoimax.
57514         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
57515         strtoumax.
57516
57517 2001-09-20  Jim Meyering  <meyering@lucent.com>
57518
57519         * lib/xstrtol.c (strtoimax): Guard declaration with
57520         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
57521         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
57522         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
57523         (strtoumax): Likewise, for completeness (it wasn't necessary).
57524
57525 2001-09-17  Paul Eggert  <eggert@twinsun.com>
57526
57527         * lib/strtoimax.c (HAVE_LONG_LONG):
57528         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
57529         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
57530         to work around bug in IBM C compiler.
57531
57532 2001-09-17  Jim Meyering  <meyering@lucent.com>
57533
57534         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
57535         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
57536         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
57537         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
57538         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
57539         whenever the right hand side need not be expanded by the shell.
57540
57541 2001-09-16  Paul Eggert  <eggert@twinsun.com>
57542
57543         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
57544         library.  It's not correct, as some older glibcs are buggy.
57545         fnmatch wasn't fixed until glibc 2.2.
57546
57547         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
57548         special shell magic here.
57549
57550 2001-09-16  Jim Meyering  <meyering@lucent.com>
57551
57552         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
57553         * m4/jm-macros.m4: Require it.
57554
57555 2001-09-16  Jim Meyering  <meyering@lucent.com>
57556
57557         * lib/mkdir.c: New file.
57558
57559 2001-09-15  Jim Meyering  <meyering@lucent.com>
57560
57561         * m4/jm-macros.m4: Check for help2man.
57562
57563 2001-09-11  Jim Meyering  <meyering@lucent.com>
57564
57565         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
57566         The body, by Paul Eggert, was moved here from configure.in.
57567         * m4/jm-macros.m4: Require UTILS_HOST_OS.
57568
57569 2001-09-04  Paul Eggert  <eggert@twinsun.com>
57570
57571         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
57572         (jm_PREREQ): Use it.
57573
57574 2001-09-04  Paul Eggert  <eggert@twinsun.com>
57575
57576         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
57577         Use ssize_t, not int, to store result of readlink.
57578         Check for ssize_t overflow as well as size_t overflow,
57579         as POSIX says the result of readlink is implementation-defined
57580         when ssize_t overflows.
57581         Remove unnecessary cast to char*.
57582         Use free+malloc instead of realloc, as the storage doesn't need
57583         to be preserved and it's clearer and can be more efficient that way.
57584         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
57585         * lib/xreadlink.h (xreadlink): Update prototype.
57586
57587 2001-09-04  Paul Eggert  <eggert@twinsun.com>
57588
57589         * lib/xgetcwd.c: Revert some of the previous change; intead,
57590         fix the HAVE_GETCWD_NULL code to behave more like the
57591         !HAVE_GETCWD_NULL code used to.
57592
57593         Include "xalloc.h".
57594         (xgetcwd): Do not return NULL when memory is exhausted; instead,
57595         invoke xalloc_die.
57596
57597 2001-09-03  Paul Eggert  <eggert@twinsun.com>
57598
57599         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
57600         sys/param.h, as pathmax.h includes them.
57601
57602 2001-09-03  Paul Eggert  <eggert@twinsun.com>
57603
57604         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
57605         (jm_PREREQ_XGETCWD): New macro.
57606
57607         * m4/getcwd.m4: New file.
57608
57609 2001-09-03  Paul Eggert  <eggert@twinsun.com>
57610
57611         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
57612         like the HAVE_GETCWD_NULL code.
57613         Include pathmax.h if not HAVE_GETCWD.
57614         Do not include xalloc.h.
57615         (INITIAL_BUFFER_SIZE): New symbol.
57616         Do not use xmalloc / xrealloc, since the caller is responsible for
57617         handling errors.  Preserve errno around `free' during failure.
57618         Do not overrun buffer when using getwd.
57619
57620 2001-09-03  Paul Eggert  <eggert@twinsun.com>
57621
57622         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
57623         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
57624         getcwd (NULL, 0).
57625
57626 2001-09-03  Paul Eggert  <eggert@twinsun.com>
57627
57628         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
57629         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
57630         spotted by Jim Meyering.
57631
57632 2001-09-03  Jim Meyering  <meyering@lucent.com>
57633
57634         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
57635         failure.
57636
57637 2001-09-02  Jim Meyering  <meyering@lucent.com>
57638
57639         * lib/error.c: Update from GNU libc.
57640
57641 2001-09-01  Jim Meyering  <meyering@lucent.com>
57642
57643         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
57644         Used by df.
57645
57646 2001-09-01  Jim Meyering  <meyering@lucent.com>
57647
57648         * lib/xreadlink.c: New file.
57649         * lib/xreadlink.h: New file.
57650         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
57651         xreadlink.h.
57652
57653         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
57654         doesn't conflict with sparc Solaris 7's definition in
57655         /usr/include/sys/int_types.h.
57656
57657         * lib/exclude.c: Use `""', not `<>' to #include non-system header
57658         files.
57659         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
57660         and strncasecmp as r-values.  Unixware didn't have declarations.
57661
57662 2001-08-31  Paul Eggert  <eggert@twinsun.com>
57663
57664         * lib/xstrtol.h: Add copyright notice.
57665         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
57666         LONGINT_INVALID_SUFFIX_CHAR.
57667
57668 2001-08-31  Paul Eggert  <eggert@twinsun.com>
57669
57670         * lib/xstrtol.c (strtoimax): New decl.
57671
57672 2001-08-31  Paul Eggert  <eggert@twinsun.com>
57673
57674         * lib/xgetcwd.c: Don't include pathmax.h.
57675         Include stdlib.h and unistd.h if available.
57676         Include xalloc.h.
57677         (xmalloc, xstrdup, free): Remove decls.
57678         (xgetcwd): Don't assume sizes fit in unsigned.
57679         Check for overflow when computing sizes.
57680         Simplify reallocation code.
57681
57682 2001-08-31  Paul Eggert  <eggert@twinsun.com>
57683
57684         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
57685         a directory's st_size can have an arbitrary value, so the old
57686         usage could waste an arbitrary amount of memory.  All uses
57687         changed.
57688         * lib/savedir.h: Update prototype.
57689
57690 2001-08-31  Paul Eggert  <eggert@twinsun.com>
57691
57692         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
57693
57694         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
57695         old strtoimax.c.
57696
57697         Also, make the following further changes to make this file's
57698         configuration more similar to that of strtol.c:
57699         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
57700         (strtoumax, uintmax_t, strtoull, strtol): Remove.
57701         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
57702         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
57703         changed to signed values.
57704
57705         And make the following changes as well:
57706         Fix copyright notice, as 1999 was missing.
57707         (verify): New macro.
57708         (strtoimax): Check sizes at compile-time, not run-time.
57709         Prefer strtol to strtoll if both work.
57710         (main): Remove; it was not that useful and was a pain to maintain.
57711
57712         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
57713
57714 2001-08-31  Jim Meyering  <meyering@lucent.com>
57715
57716         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
57717         Use an initial, malloc'd, buffer of length 128 rather than
57718         a statically allocated one of length 1024.
57719
57720 2001-08-30  Paul Eggert  <eggert@twinsun.com>
57721
57722         Simplify code, partly by assuming autoconf 2.52 semantics.
57723
57724         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
57725
57726         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
57727         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
57728         All uses removed.
57729         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
57730         Move AC_REQUIRE to next-to-top level, to avoid confusion.
57731         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
57732         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
57733         jm_AC_HEADER_INTTYPES_H.
57734         * m4/jm-macros.m4 (jm_MACROS): Likewise.
57735
57736         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
57737
57738         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
57739         Quote first arg of AC_DEFUN.
57740         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
57741         since they are needed to parse the include file even if we need
57742         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
57743         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
57744         but with opposite signedness.
57745
57746 2001-08-30  Paul Eggert  <eggert@twinsun.com>
57747
57748         Merge 'exclude' changes from tar 1.13.22.
57749         This fixes one or two unlikely storage allocation overflow bugs,
57750         but doesn't change user-visible behavior otherwise.
57751
57752 2001-08-30  Paul Eggert  <eggert@twinsun.com>
57753
57754         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
57755         (jm_PREREQ_EXCLUDE): New macro.
57756
57757 2001-08-30  Paul Eggert  <eggert@twinsun.com>
57758
57759         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
57760         tm to be declared.
57761
57762 2001-08-30  Paul Eggert  <eggert@twinsun.com>
57763
57764         * lib/hash.c: Remove '2001' from copyright notice.
57765
57766 2001-08-30  Paul Eggert  <eggert@twinsun.com>
57767
57768         * lib/full-write.h: New file.
57769         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
57770         * lib/full-write.c: Correct credits, as cccp.c no longer
57771         exists and anyway it was so heavily changed from the old cccp
57772         code as to be unrecognizable.  Include full-write.h.
57773         (full_write) Return size_t, with short writes meaning failure.
57774         All callers changed.  This fixes a bug with large buffers
57775         on 64-bit hosts.
57776         * lib/utime.c: Include full-write.h.
57777
57778 2001-08-30  Paul Eggert  <eggert@twinsun.com>
57779
57780         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
57781         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
57782         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
57783         Include if available.
57784         (<xalloc.h>): Include
57785         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
57786         (verify): New macro.  Use it to verify that EXCLUDE macros do not
57787         collide with FNM macros.
57788         (struct patopts): New struct.
57789         (struct exclude): Use it, as exclude patterns now come with options.
57790         (new_exclude): Support above changes.
57791         (new_exclude, add_exclude_file):
57792         Initial size must now be a power of two to simplify overflow checking.
57793         (free_exclude, fnmatch_no_wildcards): New function.
57794         (excluded_filename): No longer requires options arg, as the options
57795         are determined by add_exclude.  Now returns bool, not int.
57796         (excluded_filename, add_exclude):
57797         Add support for the fancy new exclusion options.
57798         (add_exclude, add_exclude_file): Now takes int options arg.
57799         Check for arithmetic overflow when computing sizes.
57800         (add_exclude_file): xrealloc might modify errno, so don't
57801         realloc until after errno might be used.
57802
57803         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
57804         New macros.
57805         (free_exclude): New decl.
57806         (add_exclude, add_exclude_file): Now takes int options arg.
57807         (excluded_filename): No longer requires options arg, as the options
57808         are determined by add_exclude.  Now returns bool, not int.
57809
57810 2001-08-30  Paul Eggert  <eggert@twinsun.com>
57811
57812         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
57813
57814 2001-08-27  Jim Meyering  <meyering@lucent.com>
57815
57816         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
57817
57818         * lib/version-etc.c (N_): Remove definition.
57819         Revert most of last change.
57820         Instead, simply don't mark the `Copyright...' string for translation.
57821         Based on advice from Paul Eggert.
57822
57823         * lib/strtoxmax.c: Tweak comment.
57824
57825 2001-08-26  Jim Meyering  <meyering@lucent.com>
57826
57827         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
57828
57829         * m4/xstrtoimax.m4: New file.
57830         * m4/xstrtoumax.m4: Add comments explaining why we
57831         AC_REPLACE_FUNCS(strtol).
57832
57833 2001-08-26  Jim Meyering  <meyering@lucent.com>
57834
57835         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
57836         of copyright with `%s' so translators don't get an untranslated
57837         message in 2002.
57838         (COPYRIGHT_YEAR): Define.
57839         (version_etc): Use fprintf rather than fputs.
57840         Suggestion from Ulrich Drepper.
57841
57842         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
57843
57844         * lib/strtoll.c: New file, from GNU libc.
57845         * lib/xstrtoimax.c: New file.
57846
57847         * lib/xstrtol.h: Add xstrtoimax.
57848         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
57849         * lib/strtoimax.c: New file.  Likewise, but first define
57850         STRTOUXMAX_SIGNED.
57851
57852         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
57853         ...
57854         * lib/strtoxmax.c: ... then renamed to this.
57855
57856 2001-08-18  Paul Eggert  <eggert@twinsun.com>
57857
57858         * m4/inttypes.m4: Add AC_PREREQ(2.13).
57859         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
57860         (jm_AC_TYPE_INTMAX_T): New macro.
57861         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
57862
57863         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
57864
57865         * m4/longlong.m4: Renamed from ulonglong.m4.
57866         * m4/inttypes.m4: Renamed from inttypes_h.m4.
57867         * m4/uintmax_t.m4: Removed.
57868
57869 2001-08-13  Paul Eggert  <eggert@twinsun.com>
57870
57871         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
57872         Port to Solaris 8, where 'sed' requires a space after the 'r'
57873         command, and where sh dislikes "$/".  Clean up the spacing a bit.
57874         Redirect output to $tmp just once.
57875
57876 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
57877
57878         * lib/addext.c (<errno.h>): Include.
57879         (errno): Declare if not defined.
57880         (addext): Work correctly when pathconf returns -1 and leaves
57881         errno alone because there is no limit.  Also, work even if
57882         pathconf returns a value greater than SIZE_MAX.
57883
57884 2001-08-12  Jim Meyering  <meyering@lucent.com>
57885
57886         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
57887         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
57888         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
57889         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
57890         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
57891         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
57892         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
57893         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
57894         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
57895         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
57896         utime.m4, utimes.m4, xstrtoumax.m4:
57897         Quote the first argument in each use of AC_DEFUN.
57898
57899 2001-08-12  Jim Meyering  <meyering@lucent.com>
57900
57901         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
57902         Simply `return getcwd (NULL, 0);'.
57903         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
57904         Use 1300 as initial value for length, not PATH_MAX.
57905
57906         * lib/pathmax.h: Clean up cpp syntax.
57907
57908 2001-08-12  Jim Meyering  <meyering@lucent.com>
57909
57910         * lib/gettimeofday.c: New file.
57911         * lib/gtod.h: New file.
57912         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
57913
57914 2001-08-05  Jim Meyering  <meyering@lucent.com>
57915
57916         * m4/jm-macros.m4: Require autoconf-2.52.
57917
57918 2001-08-04  Jim Meyering  <meyering@lucent.com>
57919
57920         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
57921         stmt, to get in sync with glibc.
57922
57923 2001-08-03  Paul Eggert  <eggert@twinsun.com>
57924
57925         The following changes are from gettext 0.10.39 as maintained by
57926         Bruno Haible.
57927
57928         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
57929         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
57930         with inverted sense.  All uses changed.
57931
57932         * lib/mbswidth.c: Don't include <limits.h>.
57933         Include <stdlib.h> and <string.h> unconditionally.
57934         (iswcntrl, mbsinit, ISCNTRL): New macros.
57935         (mbsnwidth): Use K&R style function declarations.
57936         Don't bother checking for MB_LEN_MAX == 1, since the compiler
57937         can optimize it when MB_CUR_MAX == 1.
57938         The width of control characters is zero, not 1.
57939
57940 2001-08-03  Paul Eggert  <eggert@twinsun.com>
57941
57942         The following changes are from gettext 0.10.39 as maintained by
57943         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
57944
57945         * m4/codeset.m4: Upgrade to serial AM1.
57946         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
57947         all uses changed.  Quote first arg of AC_DEFUN.
57948         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
57949
57950         * m4/iconv.m4: Upgrade to serial AM2.
57951         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
57952         Add --with-libconv-prefix.
57953         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
57954         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
57955         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
57956         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
57957         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
57958
57959         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
57960         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
57961         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
57962         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
57963         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
57964         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
57965         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
57966         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
57967         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
57968
57969         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
57970         string.h any more.
57971
57972         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
57973         not the default value.
57974
57975         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
57976         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
57977         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
57978         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
57979         Also check for iswcntrl, used for wcwidth fallback.
57980         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
57981         to Autoconf 2.13.
57982
57983 2001-08-03  Jim Meyering  <meyering@lucent.com>
57984
57985         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
57986         as it was in the original.  Reported by Paul Eggert.
57987
57988 2001-07-16  Jim Meyering  <meyering@lucent.com>
57989
57990         * m4/gettimeofday.m4: New file.
57991         Prompted by a report from Bernhard Baehr.
57992
57993 2001-07-15  Jim Meyering  <meyering@lucent.com>
57994
57995         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
57996         stuff. Now it's in ../Makefile.cfg.
57997
57998 2001-07-15  Jim Meyering  <meyering@lucent.com>
57999
58000         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
58001         (BUILT_SOURCES): Add unlocked-io.h.
58002         (io_functions): Define.
58003         (unlocked-io.h): New rule.
58004         (DISTCLEANFILES): Add unlocked-io.h.
58005         (all-local): Depend on unlocked-io.h, to ensure it is created.
58006
58007         * lib/unlocked-io.hin: New file
58008
58009         * lib/regex.c: Update from glibc.
58010
58011 2001-07-05  Jim Meyering  <meyering@lucent.com>
58012
58013         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
58014         recommendation.
58015         (libfetish_a_SOURCES): Put all .h files here instead.
58016         Remove a thus-exposed (better checks in automake) duplicate and
58017         two unnecessary .h files.
58018
58019 2001-07-04  Jim Meyering  <meyering@lucent.com>
58020
58021         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
58022         that generates jm-glibc-io.m4 so that it doesn't trigger any make
58023         distcheck failure.
58024
58025 2001-07-02  Jim Meyering  <meyering@lucent.com>
58026
58027         The following changes were prompted by suggestions from Bruno Haible.
58028
58029         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
58030         is now generated.
58031         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
58032         definition of EXTRA_DIST.
58033         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
58034         ensure that the generated file is created/updated whenever the list
58035         of $(unlocked_functions) is changed.
58036         (jm-glibc-io.m4): New rule.
58037         (unlocked-io.h): New rule -- currently unused.
58038
58039 2001-06-24  Jim Meyering  <meyering@lucent.com>
58040
58041         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
58042         unmatched right bracket, rather than kludging it with an extra,
58043         falsely-matching quote in a comment.  Patch by Akim Demaille.
58044
58045 2001-06-11  Jim Meyering  <meyering@lucent.com>
58046
58047         * lib/regex.c: Update from GNU libc.
58048
58049 2001-05-27  Jim Meyering  <meyering@lucent.com>
58050
58051         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
58052         Check for ut_type in struct utmp.
58053
58054 2001-05-27  Jim Meyering  <meyering@lucent.com>
58055
58056         * lib/readutmp.h (UT_TYPE): Define.
58057
58058 2001-05-24  Jim Meyering  <meyering@lucent.com>
58059
58060         * lib/argmatch.c: Include "quote.h".
58061         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
58062         quote function.  Reported by Göran Uddeborg.
58063
58064 2001-05-22  Jim Meyering  <meyering@lucent.com>
58065
58066         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
58067         now that we use the package-supplied version unconditionally.
58068         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
58069
58070 2001-05-21  Jim Meyering  <meyering@lucent.com>
58071
58072         * m4/regex.m4: Change a couple backticks to single quotes to avoid
58073         shell syntax errors.
58074
58075 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
58076
58077         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
58078
58079 2001-05-20  Paul Eggert  <eggert@twinsun.com>
58080
58081         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
58082         Don't bother to check library strftime, since
58083         we'll be using our own my_strftime function anyway.
58084         Define my_strftime instead of strftime.
58085
58086 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
58087
58088         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
58089         which is not yet declared.
58090
58091 2001-05-15  Jim Meyering  <meyering@lucent.com>
58092
58093         * m4/regex.m4: Use proper quoting so brackets appear in the test
58094         program.
58095         Reported by, and with help from, Bruno Haible.
58096
58097 2001-05-13  Jim Meyering  <meyering@lucent.com>
58098
58099         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
58100         undefined.
58101
58102 2001-05-11  Paul Eggert  <eggert@twinsun.com>
58103
58104         dirname code cleanup.  base_name now behaves more compatibly
58105         with POSIX basename when given file names that have trailing
58106         slashes, and similarly for dir_name.  Add new primitives
58107         base_len and dir_len.  Put the directory-name-related decls
58108         into dirname.h.
58109
58110         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
58111         * lib/backupfile.c (base_name): Likewise.
58112         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
58113         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
58114         * lib/makepath.c (strip_trailing_slashes): Likewise.
58115         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
58116         ISSLASH): Likewise.
58117         * lib/rename.c (strip_trailing_slashes): Likewise.
58118         * lib/same.c (base_name): Likewise.
58119         * lib/stripslash.c (ISSLASH): Likewise.
58120
58121         * lib/addext.c: Include <dirname.h> after size_t is defined.
58122         * lib/backupfile.c: Likewise.
58123
58124         * lib/addext.c (addext): Use base_len to trim redundant
58125         trailing slashes instead of doing it ourselves.
58126         But do not trim the last slash if it is not redundant.
58127
58128         * lib/backupfile.c (find_backup_file_name,
58129         max_backup_version): Use base_len instead of rolling it ourselves.
58130         Handle the case of "" and (on DOS) "C:" correctly.
58131
58132         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
58133         needed. Include <string.h>, <dirname.h>.
58134         (base_name): Allow file names ending in slashes, other than names
58135         that are all slashes.  In this case, return the basename followed
58136         by the slashes.  This is more general, and can be used in places
58137         where the original base_name purposely had an assertion failure.
58138         (base_len): New function.
58139
58140         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
58141         Do not include <assert.h>; no longer needed.
58142         Include xalloc.h.
58143         (memrchr): Remove decl.
58144         (dir_name_r): Remove.
58145         (dir_len): Renamed from dirlen.  All callers changed.
58146         Rewrite in terms of base_name, for simplicity and consistency.
58147         (dir_name): Never return NULL.  All callers changed.
58148         Do not include <stdlib.h> in test program; no longer needed.
58149         return 0; is fine for test program.
58150
58151         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
58152         New macros.
58153         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
58154
58155         * lib/path-concat.c (path_concat): Use base_len to compute
58156         base length, not strlen; this means we cannot rely on memcpy
58157         to null-terminate.
58158
58159         * lib/same.c (STREQ): Remove.
58160         (same_name): Handle the case where the basename ends in trailing '/'.
58161
58162         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
58163         a slash was stripped.  Do not strip the last slash after a
58164         file system prefix.
58165
58166 2001-05-11  Paul Eggert  <eggert@twinsun.com>
58167
58168         * lib/Makefile.am (libfetish_a_SOURCES):
58169         Add strftime.c, since we now compile it on all hosts.
58170
58171         * lib/strftime.c (my_strftime):
58172         Define to nstrftime if emacs, but only if my_strftime is not defined.
58173         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
58174         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
58175         Add one more extra argument: a nanoseconds value.
58176         All uses changed.
58177         (ns): New macro.
58178         (my_strftime function): Add %N format.
58179         (emacs_strftimeu): Renamed from emacs_strftime,
58180         with extra ut argument.
58181
58182 2001-05-09  Paul Eggert  <eggert@twinsun.com>
58183
58184         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
58185
58186 2001-04-21  Jim Meyering  <meyering@lucent.com>
58187
58188         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
58189         doesn't interfere.
58190
58191 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
58192
58193         * m4/ftruncate.m4: Check for chsize.
58194         Link with ftruncate.o unconditionally if ftruncate is missing.
58195         This was required when cross-compiling to i586-mingw32msvc.
58196
58197 2001-04-08  Jim Meyering  <meyering@lucent.com>
58198
58199         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
58200         recomputed; that's necessary when the offset spans a DST transition.
58201         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
58202
58203 2001-04-02  Jim Meyering  <meyering@lucent.com>
58204
58205         * lib/regex.h, regex.c: Update from GNU libc.
58206
58207 2001-03-24  Jim Meyering  <meyering@lucent.com>
58208
58209         * m4/jm-macros.m4: Require autoconf-2.49d.
58210
58211 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
58212
58213         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
58214
58215 2001-03-19  Paul Eggert  <eggert@twinsun.com>
58216
58217         * lib/version-etc.c (version_etc_copyright): Update to 2001.
58218
58219 2001-03-17  Jim Meyering  <meyering@lucent.com>
58220
58221         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
58222         now that the version in autoconf is equivalent.
58223         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
58224
58225         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
58226         Suggestion from Akim Demaille.
58227
58228         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
58229         (jm_PREREQ_TEMPNAME): New function.
58230
58231 2001-03-16  Paul Eggert  <eggert@twinsun.com>
58232
58233         * lib/tempname.c (uint64_t): Define to uintmax_t if
58234         not defined, and if UINT64_MAX is not defined.
58235         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
58236         Reported by John David Anglin.
58237
58238 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
58239
58240         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
58241         resolve alias if codeset is empty.
58242         * lib/config.charset (BeOS): Use wildcard syntax.
58243
58244 2001-03-13  Jim Meyering  <meyering@lucent.com>
58245
58246         * lib/path-concat.c (path_concat)
58247         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
58248         concatenating e.g., `C:' and `foo'.
58249         From Bruno Haible.
58250
58251 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
58252
58253         * lib/localcharset.c (locale_charset): Don't use
58254         setlocale(LC_CTYPE,NULL). Don't return NULL.
58255         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
58256
58257 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
58258
58259         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
58260         support for DOS/DJGPP.
58261
58262 2001-03-01  Paul Eggert  <eggert@twinsun.com>
58263
58264         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
58265         lacks mkstemp.  Compile our own tempname.c if we compile our own
58266         mkstemp.c, as mkstemp relies on tempname.
58267
58268 2001-03-01  Jim Meyering  <meyering@lucent.com>
58269
58270         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
58271         AH_VERBATIM really does output its argument verbatim.
58272
58273 2001-02-28  Paul Eggert  <eggert@twinsun.com>
58274
58275         * lib/Makefile.am (libfetish_a_SOURCES):
58276         Add dup-safer.c, fopen-safer.c.
58277         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
58278
58279         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
58280         * lib/unistd-safer.h: New files.
58281
58282 2001-02-25  Paul Eggert  <eggert@twinsun.com>
58283
58284         The mkstemp replacement is taken from glibc 2.2.2, with some
58285         portability fixes for use outside glibc, as follows:
58286
58287         * lib/tempname.c (struct_stat64): New macro.
58288         (direxists, __gen_tempname): Use it.
58289         This avoids a portability problem with Solaris 8.
58290
58291         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
58292         (<stddef.h>, <stdint.h>, <string.h>):
58293         Include only if STDC_HEADERS || _LIBC.
58294         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
58295         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
58296         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
58297         (__set_errno): Define this macro if <errno.h> doesn't.
58298         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
58299         Define these macros if <stdio.h> doesn't.
58300         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
58301         Define these macros if <sys/stat.h>
58302         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
58303         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
58304         __xstat64): Define if not _LIBC.
58305         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
58306         (__gen_tempname): Invoke gettimeofday only if
58307         HAVE_GETTIMEOFDAY || _LIBC;
58308         otherwise, fall back on plain "time".
58309         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
58310
58311         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
58312
58313         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
58314
58315 2001-02-18  Paul Eggert  <eggert@twinsun.com>
58316
58317         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
58318
58319 2001-02-17  Paul Eggert  <eggert@twinsun.com>
58320
58321         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
58322         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
58323         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
58324         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
58325
58326 2001-02-17  Paul Eggert  <eggert@twinsun.com>
58327
58328         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
58329         Remove workaround macros for hosts that have mbrtowc but not
58330         mbstate_t, as we now insist on proper declarations for both
58331         before using mbrtowc.
58332
58333 2001-02-17  Jim Meyering  <meyering@lucent.com>
58334
58335         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
58336         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
58337         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
58338         UnixWare 7.1.1.
58339
58340         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
58341         rather than AC_CACHE_VAL.
58342
58343 2001-02-17  Jim Meyering  <meyering@lucent.com>
58344
58345         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
58346         around included file name.
58347
58348         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
58349
58350         * lib/strftime.c: Update from GNU libc (the only changes were to
58351         comments).
58352
58353 2001-02-17  Jim Meyering  <meyering@lucent.com>
58354
58355         * lib/regex.c: Update from libc.
58356
58357 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
58358
58359         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
58360         clash.
58361
58362 2001-02-16  Paul Eggert  <eggert@twinsun.com>
58363
58364         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
58365         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
58366         Reported by Mark Hounschell via Paul Eggert.
58367
58368 2001-02-07  Jim Meyering  <meyering@lucent.com>
58369
58370         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
58371
58372 2001-02-05  Jim Meyering  <meyering@lucent.com>
58373
58374         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
58375         it includes the patch required for `large file' support with at least
58376         HP-UX's 10.20 /bin/cc.
58377
58378 2001-02-03  Jim Meyering  <meyering@lucent.com>
58379
58380         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
58381         AS_IF, now that it works once again (mysteriously).
58382         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
58383
58384 2001-01-30  Jim Meyering  <meyering@lucent.com>
58385
58386         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
58387         * m4/chown.m4: Rename conftestchown to conftest.chown.
58388         * m4/rename.m4: s/conftestdir/conftest.d1/ and
58389         s/conftestdir2/conftest.d2/.
58390         * m4/utimes.m4: s/conftestdata/conftest.data/
58391         Inspired by Pavel Roskin's change in autoconf.
58392
58393 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
58394
58395         * lib/config.charset: Update for FreeBSD 4.2.
58396
58397 2001-01-27  Jim Meyering  <meyering@lucent.com>
58398
58399         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
58400         a use of AS_IF.
58401         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
58402
58403 2001-01-26  Jim Meyering  <meyering@lucent.com>
58404
58405         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
58406         quotearg.c includes it.
58407
58408 2001-01-26  Jim Meyering  <meyering@lucent.com>
58409
58410         * lib/quotearg.c: Include stddef.h.
58411         * lib/quote.c: Include stddef.h.
58412         Reported by Axel Kittenberger.
58413
58414         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
58415         line in double quotes so that it evokes a better diagnostic.
58416         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
58417         Reported by Axel Kittenberger.
58418
58419 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
58420
58421         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
58422         as if it was a `charset'.
58423
58424 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
58425
58426         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
58427         has const.
58428
58429 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
58430
58431         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
58432         to avoid a warning.  Add back 'const' to inptr.
58433
58434 2001-01-20  Jim Meyering  <meyering@lucent.com>
58435
58436         Be sure that headers are checked before used in code compiled
58437         for the type checks.
58438         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
58439         In place of that, invoke jm_CHECK_ALL_TYPES.
58440         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
58441         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
58442         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
58443         The check for ssize_t was mistakenly run before the test for unistd.h.
58444
58445         The configure-time check for stdbool.h was missing.
58446         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
58447         (jm_PREREQ_HASH): New function.
58448
58449 2001-01-17  Jim Meyering  <meyering@lucent.com>
58450
58451         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
58452         for autoconf-2.49c.
58453         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
58454
58455 2001-01-16  Jim Meyering  <meyering@lucent.com>
58456
58457         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
58458         From Bruno Haible.
58459
58460 2001-01-14  Jim Meyering  <meyering@lucent.com>
58461
58462         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
58463         foo and bar.  Create conftestdir/ in the script, not in the C code.
58464         Remove directories in the script, not in the C code.
58465         Remove conftestdir{,2} before trying to create the directory.
58466         Make the entire configure script fail if the mkdir fails.
58467
58468 2001-01-14  Jim Meyering  <meyering@lucent.com>
58469
58470         * lib/rename.c: New file.  From Volker Borchert.
58471         Include stdlib.h, string.h or strings.h, and xalloc.h.
58472         Use strip_trailing_slashes rather than open-coding it.
58473
58474 2001-01-03  Paul Eggert  <eggert@twinsun.com>
58475
58476         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
58477
58478 2001-01-03  Jim Meyering  <meyering@lucent.com>
58479
58480         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
58481         of local `inptr' to avoid warning with some system declarations of
58482         iconv.
58483
58484 2001-01-02  Volker Borchert  <bt@teknon.de>
58485
58486         * m4/rename.m4: New file.
58487         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
58488
58489 2001-01-01  Jim Meyering  <meyering@lucent.com>
58490
58491         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
58492         even on systems with utmpx.h.  It's necessary for the declaration of
58493         utmp's ut_user member.  Reported by Andreas Jaeger.
58494
58495         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
58496         available. They are required for the declarations of getgrgid and
58497         getpwuid resp.
58498         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
58499         Reported by Andreas Jaeger.
58500
58501 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
58502
58503         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
58504         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
58505         so `make install' also works in VPATH builds.
58506
58507 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
58508
58509         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
58510         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
58511         can be used in subdirectories.
58512
58513 2000-12-29  Paul Eggert  <eggert@twinsun.com>
58514
58515         * lib/modechange.c: Do not assume that mode_t uses the
58516         traditional octal encoding.  E.g. "chmod 1 FOO" should set
58517         the other-execute bit of FOO even if S_IXOTH != 1.
58518
58519         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
58520         WOTH, XOTH, ALLM): New macros.
58521         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
58522          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
58523         Use them.
58524         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
58525         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
58526         (mode_compile):
58527         No need to use uintmax_t; unsigned long is long enough.
58528         Don't bother to get suffix since we don't use it.
58529
58530 2000-12-26  Jim Meyering  <meyering@lucent.com>
58531
58532         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
58533         better with autoheader.
58534
58535 2000-12-24  Jim Meyering  <meyering@lucent.com>
58536
58537         * lib/hash.c (is_prime): Return explicit boolean values.
58538         (hash_get_first): Return NULL to appease Irix5.6's 89.
58539         Reported by Nelson Beebe.
58540
58541 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
58542
58543         * lib/localcharset.c (locale_charset): Add support for Win32.
58544
58545 2000-12-18  Paul Eggert  <eggert@twinsun.com>
58546
58547         * lib/physmem.h, lib/physmem.c: New files.
58548
58549         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
58550         (noinst_HEADERS): Add physmem.h.
58551
58552         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
58553         't' for compatibility with Solaris 8 sort.
58554
58555 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
58556
58557         * lib/config.charset: Add support for BeOS.
58558
58559 2000-12-17  Jim Meyering  <meyering@lucent.com>
58560
58561         * m4/dos.m4 (jm_AC_DOS): New file and macro.
58562         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
58563
58564 2000-12-16  Jim Meyering  <meyering@lucent.com>
58565
58566         This bug had a serious impact on chown: `chown N:M FILE' (for integer
58567         N and M) would have treated it like `chown N:N FILE'.
58568
58569         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
58570
58571 2000-12-16  Jim Meyering  <meyering@lucent.com>
58572
58573         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
58574         SHELLS_FILE to a file name that's useful on djgpp systems.
58575         Include stdlib.h.
58576         (ADDITIONAL_DEFAULT_SHELLS): Define.
58577         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
58578         Based mostly on a patch from Prashant TR.
58579
58580 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
58581
58582         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
58583         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
58584         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
58585
58586 2000-12-08  Andreas Schwab  <schwab@suse.de>
58587
58588         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
58589         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
58590
58591 2000-12-07  Jim Meyering  <meyering@lucent.com>
58592
58593         * lib/stripslash.c (ISSLASH): Define.
58594         (strip_trailing_slashes): Use ISSLASH rather than comparing against
58595         `/'.
58596         From Prashant TR.
58597
58598         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
58599         (dir_name_r): Declare this function as static.
58600         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
58601         manifest itself on a name containing a mix of slashes and
58602         backslashes.
58603         Make this function work with names starting with a DOS-style
58604         drive letter and colon prefix.
58605         (dir_name): Append `.' if necessary.
58606         Based mostly on patches from Prashant TR and Eli Zaretskii.
58607
58608         * lib/dirname.h (dir_name_r): Remove prototype.
58609
58610 2000-12-06  Paul Eggert  <eggert@twinsun.com>
58611
58612         * m4/off_t-format.m4: Remove this file.
58613         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
58614
58615 2000-12-06  Jim Meyering  <meyering@lucent.com>
58616
58617         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
58618         replacement strtoull, we may well need the replacement strtoul, too.
58619         Check for declarations of strtoul and strtoull.
58620         Check for strtol.  Mainly as a cue to cause automake to include
58621         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
58622         Check for limits.h -- strtol.c needs it.
58623
58624 2000-12-05  Jim Meyering  <meyering@lucent.com>
58625
58626         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
58627
58628 2000-12-04  Jim Meyering  <meyering@lucent.com>
58629
58630         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
58631         Also include memory.h, stdlib.h, unistd.h if appropriate.
58632         Reported by Andreas Jaeger (conflicting declaration of malloc).
58633
58634 2000-12-02  Jim Meyering  <meyering@lucent.com>
58635
58636         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
58637         * m4/jm-macros.m4 (jm_MACROS): require it.
58638
58639 2000-12-02  Jim Meyering  <meyering@lucent.com>
58640
58641         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
58642
58643 2000-12-01  Paul Eggert  <eggert@twinsun.com>
58644
58645         * lib/memrchr.c: Include <config.h> before any system include file.
58646
58647 2000-11-30  Jim Meyering  <meyering@lucent.com>
58648
58649         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
58650
58651 2000-11-30  Jim Meyering  <meyering@lucent.com>
58652
58653         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
58654
58655 2000-11-29  Paul Eggert  <eggert@twinsun.com>
58656
58657         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
58658
58659 2000-11-26  Jim Meyering  <meyering@lucent.com>
58660
58661         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
58662
58663 2000-11-22  Paul Eggert  <eggert@twinsun.com>
58664
58665         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
58666         size of (size_t) -1; it's not portable.
58667
58668 2000-11-17  Jim Meyering  <meyering@lucent.com>
58669
58670         * lib/strstr.c: Update from GNU libc.
58671
58672 2000-11-17  Akim Demaille  <akim@epita.fr>
58673
58674         * lib/obstack.h: Formatting changes.
58675         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
58676         prevent type checking.
58677         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
58678         cast the value to (void *): assigning a `foo *' to a `void *'
58679         variable is valid.
58680         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
58681
58682 2000-11-16  Jim Meyering  <meyering@lucent.com>
58683
58684         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
58685
58686 2000-11-11  Jim Meyering  <meyering@lucent.com>
58687
58688         * lib/error.c: Add a couple #includes, merging from GNU libc version.
58689
58690 2000-11-10  Jim Meyering  <meyering@lucent.com>
58691
58692         * lib/obstack.h: Update from GNU libc.
58693         * lib/obstack.c: Likewise.
58694
58695 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
58696
58697         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
58698
58699 2000-11-06  Paul Eggert  <eggert@twinsun.com>
58700
58701         * lib/getusershell.c (setusershell): Use rewind rather than
58702         fseek/fseeko, to avoid configuration hassles with fseeko.
58703         Don't bother opening SHELLS_FILE if shellstream is NULL;
58704         it's not necessary.
58705
58706 2000-11-05  Jim Meyering  <meyering@lucent.com>
58707
58708         * lib/makepath.h (make_dir): Declare.
58709         * lib/makepath.c (make_dir): Remove `static' attribute.
58710         Tweak a comment.
58711
58712 2000-11-04  Jim Meyering  <meyering@lucent.com>
58713
58714         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
58715
58716 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
58717
58718         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
58719         last one in a bucket, advance to the next bucket.
58720
58721 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
58722
58723         * lib/fnmatch.c: Do not comment out all the code if we are using
58724         the GNU C library, because in some cases we are replacing buggy
58725         code in the GNU C library itself.
58726
58727 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
58728
58729         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
58730         (regex_compile): Catch bogus \(\1\).
58731
58732 2000-10-30  Paul Eggert  <eggert@twinsun.com>
58733
58734         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
58735         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
58736         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
58737
58738 2000-10-30  Paul Eggert  <eggert@twinsun.com>
58739
58740         * lib/error.h, getline.h, modechange.h:
58741         Remove "2000" from Copyright line, as the file hasn't been
58742         changed this year other than in the copyright notice.
58743
58744         * lib/xalloc.h: Add "2000" to Copyright line, as this file
58745         was changed this year.
58746
58747 2000-10-29  Jim Meyering  <meyering@lucent.com>
58748
58749         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
58750         renaming.
58751         * m4/ls-mntd-fs.m4: Likewise
58752
58753 2000-10-29  Jim Meyering  <meyering@lucent.com>
58754
58755         * lib/xstat.in: Fix grammar in comment.
58756
58757 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
58758
58759         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
58760         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
58761         doesn't define __restrict_arr.
58762
58763 2000-10-28  Jim Meyering  <meyering@lucent.com>
58764
58765         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
58766         (jm_PREREQ_MEMCHR): New function.
58767
58768 2000-10-28  Jim Meyering  <meyering@lucent.com>
58769
58770         * lib/memchr.c: Update from libc.
58771         Adjust for portability:
58772         [HAVE_STDLIB_H]: Include stdlib.h.
58773         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
58774         Undef __memchr, too.
58775         [!weak_alias]: Define __memchr to memchr.
58776
58777         * lib/regex.c: Update from libc.
58778         * lib/regex.h: Likewise.
58779         * lib/getopt1.c: Likewise.
58780         * lib/memcmp.c: Likewise.
58781
58782         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
58783         Avoid using fseek, when possible -- it's broken by design.
58784         Patch by Ulrich Drepper.
58785
58786 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
58787
58788         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
58789         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
58790         Giving in to popular pressure to shut up the compiler with casts.
58791
58792 2000-10-26  Jim Meyering  <meyering@lucent.com>
58793
58794         * lib/strftime.c: Update from libc.
58795
58796 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
58797
58798         * regex.c: More `unsigned char' -> `re_char' changes.
58799         Also change several `int' into `re_wchar_t'.
58800         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
58801         (PUSH_FAILURE_POINTER): Don't cast any more.
58802         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
58803         We want GCC to complain, since this piece of code makes
58804         re_match non-reentrant, which *should* be fixed.
58805         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
58806         (EXTEND_BUFFER): Use RETALLOC.
58807         (SET_LIST_BIT): Don't cast.
58808         (re_wchar_t): New type.
58809         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
58810         that those two functions will always properly return.
58811         (IMMEDIATE_QUIT_CHECK): Cast to void.
58812         (analyse_first): Use recursion rather than an explicit stack.
58813         (re_compile_fastmap): Can't fail anymore.
58814         (re_search_2): Don't check re_compile_fastmap for failure.
58815         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
58816         Now also sets the new value (passed in a new argument).
58817         (re_match_2_internal): Use it.
58818         Also, use a new var `reg' of type size_t when looping through regs
58819         rather than reuse the inappropriate `mcnt'.
58820
58821 2000-10-25  Jim Meyering  <meyering@lucent.com>
58822
58823         * lib/obstack.c: Update from libc.
58824
58825 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
58826
58827         * regex.c (regex_compile): Change the way of handling a range from
58828         a char less than 256 to a char not less than 256.
58829
58830 2000-10-24  Andrew Innes  <andrewi@gnu.org>
58831
58832         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
58833         NT-Emacs only.
58834         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
58835         so that re_search functions only quit when callers expect them to.
58836
58837 2000-10-23  Jim Meyering  <meyering@lucent.com>
58838
58839         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
58840         wrong.  That set_locale call must not have any side effects.
58841         From Paul Eggert.
58842
58843 2000-10-22  Jim Meyering  <meyering@lucent.com>
58844
58845         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
58846         [CYCLIC]: Remove now-unused definition.
58847
58848         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
58849         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
58850         Suggestion from Ulrich Drepper.
58851
58852 2000-10-21  Jim Meyering  <meyering@lucent.com>
58853
58854         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
58855         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
58856         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
58857
58858 2000-10-21  Jim Meyering  <meyering@lucent.com>
58859
58860         * lib/dirname.c (memrchr): Declare if necessary.
58861         (dir_name): Remove the restriction that there be no
58862         trailing slashes.  Now, this code skips past them, effectively
58863         ignoring them.
58864         [TEST_DIRNAME] (main): New unit tests.
58865
58866         * lib/memrchr.c: New file from GNU libc.
58867         Undef __memrchr, too.
58868         [!weak_alias]: Define __memrchr to memrchr.
58869         Guard weak_alias use with `#ifdef weak_alias'.
58870
58871 2000-10-21  Jim Meyering  <meyering@lucent.com>
58872
58873         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
58874         (dir_name): Use dir_name_r.
58875         * lib/dirname.h (dir_name_r): Declare it.
58876
58877 2000-10-17  Jim Meyering  <meyering@lucent.com>
58878
58879         * lib/quote.h (PARAMS): Define and use.
58880         Reported by Akim Demaille.
58881
58882         * lib/getopt.c: Update from libc.
58883
58884 2000-10-16  Jim Meyering  <meyering@lucent.com>
58885
58886         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
58887         setlocale.
58888         From Jan Fedak.
58889
58890 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
58891
58892         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
58893
58894 2000-09-25  Jim Meyering  <meyering@lucent.com>
58895
58896         * lib/md5.h (rol): Define (from GnuPG).
58897
58898         * lib/sha.c: Give credit (GnuPG) where due.
58899         (M): Use rol rather than open-coding it.
58900         Add a FIXME comment.
58901
58902 2000-09-21  Jim Meyering  <meyering@lucent.com>
58903
58904         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
58905         Reported by Michael Stone.
58906
58907 2000-09-20  Jim Meyering  <meyering@lucent.com>
58908
58909         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
58910         (noinst_HEADERS): Add sha.h.
58911         Based on code from Scott G. Miller and from GnuPG.
58912
58913 2000-09-18  Jim Meyering  <meyering@lucent.com>
58914
58915         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
58916         LIBS. Otherwise, everyone ends up linking with -lelf for some
58917         configurations.
58918         Reported by Mike Stone.
58919
58920 2000-09-15  Jim Meyering  <meyering@lucent.com>
58921
58922         * lib/regex.c: Update from libc.
58923
58924 2000-09-10  Jim Meyering  <meyering@lucent.com>
58925
58926         * lib/getopt.c (_getopt_internal): Update from glibc.
58927
58928 2000-09-09  Jim Meyering  <meyering@lucent.com>
58929
58930         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
58931         think it should be used as a general replacement for isascii.
58932         * lib/fnmatch.c: Likewise.
58933         * lib/mbswidth.c: Likewise
58934         * lib/regex.c: Likewise.
58935
58936         Don't use atoi.
58937         * lib/userspec.c: Include sys/param.h and limits.h.
58938         Include xstrtol.h.
58939         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
58940         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
58941         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
58942         UID, GID.  Check range.
58943
58944 2000-09-06  Jim Meyering  <meyering@lucent.com>
58945
58946         * lib/getopt.c (_getopt_internal): Update from glibc.
58947
58948 2000-08-30  Jim Meyering  <meyering@lucent.com>
58949
58950         * lib/strftime.c: Merge in changes from GNU libc.
58951
58952 2000-08-26  Jim Meyering  <meyering@lucent.com>
58953
58954         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
58955         * m4/fpending.m4: New file.
58956
58957 2000-08-26  Jim Meyering  <meyering@lucent.com>
58958
58959         * lib/closeout.c: Include "__fpending.h".
58960         (close_stdout_status): Return right away if there's nothing to flush.
58961
58962         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
58963         * lib/__fpending.c: New file.
58964         * lib/__fpending.h: New file.
58965
58966 2000-08-20  Jim Meyering  <meyering@lucent.com>
58967
58968         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
58969         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
58970         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
58971
58972 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
58973
58974         Improve fileutils installation on systems where running
58975         programs (like install) can't be unlinked.
58976         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
58977         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
58978
58979 2000-08-07  Paul Eggert  <eggert@twinsun.com>
58980
58981         Standardize on "memory exhausted" instead of "Memory exhausted"
58982         or "virtual memory exhausted".
58983         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
58984         "virtual memory exhausted".
58985         * lib/same.c (same_name): Invoke xalloc_die instead of printing
58986         our own message.
58987         * lib/userspec.c (parse_user_spec): Likewise.
58988         * lib/bumpalloc.h: comment fix
58989         * lib/same.c, userspec.c: Include xalloc.h.
58990
58991         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
58992         not char *const and pointing to a constant array.
58993         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
58994         (xrealloc): Comment fix.
58995
58996         * lib/userspec.c (parse_user_spec):
58997         Don't translate a message until just before returning,
58998         to avoid unnecessary translation.
58999
59000 2000-08-07  Jim Meyering  <meyering@lucent.com>
59001
59002         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
59003         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
59004         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
59005         getgroups.c, gethostname.c, getopt.h, group-member.c,
59006         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
59007         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
59008         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
59009         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
59010         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
59011         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
59012         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
59013         yesno.c: Back out Copyright date changes for each file with no change
59014         this year.  This eases coordination with other programs using the same
59015         source code modules.  From Paul Eggert.
59016
59017 2000-08-06  Paul Eggert  <eggert@twinsun.com>
59018
59019         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
59020         not char, for compatibility with glibc 2.1.3 strftime.c.
59021
59022 2000-08-03  Greg McGary  <greg@mcgary.org>
59023
59024         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
59025         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
59026         (EXTEND_BUFFER): Use them.
59027
59028 2000-08-01  Jim Meyering  <meyering@lucent.com>
59029
59030         * lib/dirname.c (ISSLASH): Define.
59031         (BACKSLASH_IS_PATH_SEPARATOR): Define.
59032         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
59033         both `\' and `/' may be use as path separators.
59034         Based on a patch from Prashant TR.
59035
59036 2000-07-31  Paul Eggert  <eggert@twinsun.com>
59037
59038         * lib/quotearg.c (quotearg_n_options): Don't make the initial
59039         slot vector a constant, since it might get modified.
59040
59041 2000-07-31  Jim Meyering  <meyering@lucent.com>
59042
59043         * lib/xmalloc.c: Use `virtual memory exhausted', not
59044         `Memory exhausted'.
59045         * lib/obstack.c (print_and_abort): Likewise.
59046
59047 2000-07-30  Paul Eggert  <eggert@twinsun.com>
59048
59049         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
59050         buffer, so that the caller can always quote one small
59051         component of a "memory exhausted" message in slot 0.
59052         From a suggestion by Jim Meyering.
59053
59054 2000-07-30  Jim Meyering  <meyering@lucent.com>
59055
59056         * lib/makepath.c (make_path): Quote the other instance, too.
59057
59058         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
59059         (STATIC_BUF_SIZE): Define.
59060         (quotearg_n_options): Use only statically allocated storage when
59061         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
59062         than STATIC_BUF_SIZE.
59063
59064 2000-07-29  Jim Meyering  <meyering@lucent.com>
59065
59066         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
59067         * lib/dirname.c (dir_name): Likewise.
59068
59069         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
59070         `/'.
59071
59072         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
59073         (dir_name): Assert that there are no trailing slashes.
59074
59075 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
59076
59077         * lib/mbswidth.h (mbswidth): Add a flags argument.
59078         (mbswidth): New declaration.
59079         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
59080         * lib/mbswidth.c (mbswidth): Add a flags argument.
59081         (mbsnwidth): New function.
59082
59083 2000-07-24  Jim Meyering  <meyering@lucent.com>
59084
59085         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
59086
59087 2000-07-23  Paul Eggert  <eggert@twinsun.com>
59088
59089         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
59090
59091 2000-07-23  Paul Eggert  <eggert@twinsun.com>
59092
59093         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
59094         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
59095         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
59096         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
59097         invoke multibyte primitives.
59098
59099 2000-07-23  Paul Eggert  <eggert@twinsun.com>
59100
59101         * lib/quotearg.c:
59102         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
59103         so that mbstate_t is always defined.
59104
59105         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
59106         be 1 in at least one GCC installation, and this configuration
59107         error is likely to be common.  Ignoring MB_LEN_MAX hurts
59108         performance on hosts that have mbrtowc but have only unibyte
59109         locales, but I assume these hosts are rare.
59110
59111 2000-07-23  Paul Eggert  <eggert@twinsun.com>
59112
59113         * lib/mbswidth.c (_XOPEN_SOURCE):
59114         Don't define; this causes problems on Solaris 7.
59115         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
59116
59117 2000-07-23  Jim Meyering  <meyering@lucent.com>
59118
59119         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
59120         too: getgrgid, getpwuid, getuid.
59121
59122 2000-07-23  Jim Meyering  <meyering@lucent.com>
59123
59124         * lib/basename.c (base_name): Add an assertion.
59125
59126 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
59127
59128         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
59129         shadow its mbsinit function.
59130
59131 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
59132
59133         * lib/mbswidth.h: New file.
59134         * lib/mbswidth.c: New file.
59135         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
59136         (noinst_HEADERS): Add mbswidth.h.
59137
59138 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
59139
59140         * lib/config.charset: Add support for FreeBSD. Improve support for
59141         HP-UX and IRIX 6.
59142
59143 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
59144
59145         * m4/mbswidth.m4: New file.
59146         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
59147
59148 2000-07-15  Jim Meyering  <meyering@lucent.com>
59149
59150         * lib/makepath.c: Include quote.h.
59151         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
59152         corresponding argument in a `quote (...)' call.
59153         Give better diagnostics.
59154
59155         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
59156         (noinst_HEADERS): Add quote.h.
59157
59158         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
59159         from tar's src/misc.c.
59160         * lib/quote.h: New file.  Prototypes for same.
59161
59162 2000-07-14  Paul Eggert  <eggert@twinsun.com>
59163
59164         From a suggestion by Bruno Haible.
59165         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
59166         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
59167         to decide whether to define the BeOS workaround macro;
59168         this adjusts to the change to AC_MBSTATE_T.
59169
59170 2000-07-14  Jim Meyering  <meyering@lucent.com>
59171
59172         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
59173         jm_AC_TYPE_UINTMAX_T.
59174
59175 2000-07-13  Paul Eggert  <eggert@twinsun.com>
59176
59177         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
59178
59179         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
59180         quotearg_buffer_restyled): Add support for
59181         clocale_quoting_style.  Undo previous change to
59182         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
59183         and "{RIGHT QUOTATION MARK}" msgids.
59184
59185 2000-07-10  Paul Eggert  <eggert@twinsun.com>
59186
59187         From a suggestion by Bruno Haible.
59188         * m4/mbstate_t.m4 (AC_MBSTATE_T):
59189         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
59190         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
59191         and mbstate_t, to a single-part test that simply defines mbstate_t.
59192         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
59193         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
59194
59195 2000-07-10  Jim Meyering  <meyering@lucent.com>
59196
59197         * m4/strerror_r.m4: Mirror the correction made in autoconf.
59198
59199         * m4/gnu-source.m4: Output to confdefs.h directly.
59200         Suggestion from Akim Demaille.
59201
59202 2000-07-09  Paul Eggert  <eggert@twinsun.com>
59203
59204         The old behavior of quoting `like this' doesn't look good with
59205         newer, ISO-style fonts.  See:
59206         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
59207
59208         Instead, quote "like this" by default.  Let the translator
59209         tailor the locale-specific quoting behavior by providing
59210         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
59211
59212         * lib/quotearg.c (N_): New macro.
59213         (gettext_default): New function.
59214         (quotearg_buffer_restyled): Use
59215         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
59216         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
59217
59218 2000-07-09  Jim Meyering  <meyering@lucent.com>
59219
59220         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
59221         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
59222
59223         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
59224         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
59225
59226 2000-07-09  Jim Meyering  <meyering@lucent.com>
59227
59228         * lib/Most files: Update copyright dates to include 2000.
59229
59230 2000-07-08  Jim Meyering  <meyering@lucent.com>
59231
59232         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
59233         if not defined.
59234         (xgethostname): Remove now-unnecessary #ifdef.
59235         Move declaration of `err' into loop where it's used.
59236
59237 2000-07-05  Paul Eggert  <eggert@twinsun.com>
59238         and Bruno Haible  <haible@clisp.cons.org>
59239
59240         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
59241         only if the test for an object-type mbstate_t fails.  This
59242         prevents us from mistakenly reporting that mbstate_t is a
59243         system object type after we "#define mbstate_t int" to work
59244         around its lack.
59245
59246 2000-07-05  Paul Eggert  <eggert@twinsun.com>
59247         and Bruno Haible  <haible@clisp.cons.org>
59248
59249         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
59250
59251 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
59252
59253         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
59254         to strerror_r.
59255         Include <ctype.h> for use of isalpha.
59256
59257 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
59258
59259         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
59260         by allocating a larger buffer. Test the gethostname return value for
59261         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
59262         returns an error and ENAMETOOLONG isn't defined.
59263
59264 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
59265
59266         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
59267         dimension.
59268
59269 2000-07-04  Jim Meyering  <meyering@lucent.com>
59270
59271         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
59272         of the deprecated AC_CHECKING.
59273
59274 2000-07-04  Jim Meyering  <meyering@lucent.com>
59275
59276         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
59277         Reported by Bruno Haible.
59278
59279 2000-07-04  Jim Meyering  <meyering@lucent.com>
59280
59281         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
59282         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
59283         lacks mbrtowc.
59284
59285 2000-07-03  Paul Eggert  <eggert@twinsun.com>
59286
59287         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
59288         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
59289
59290 2000-07-03  Paul Eggert  <eggert@twinsun.com>
59291         and Bruno Haible  <haible@clisp.cons.org>
59292
59293         * lib/quotearg.c (mbrtowc):
59294         Assign to *pwc, and return 1 only if result is nonzero.
59295         (iswprint): Use ISPRINT when substituting our own mbrtowc.
59296
59297 2000-07-03  Jim Meyering  <meyering@lucent.com>
59298
59299         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
59300
59301 2000-07-03  Jim Meyering  <meyering@lucent.com>
59302
59303         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
59304         This is necessary to get a definition of e.g., UTMP_FILE on
59305         HP-UX 10.20.
59306         From Bob Proulx.
59307
59308 2000-07-02  Jim Meyering  <meyering@lucent.com>
59309
59310         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
59311
59312         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
59313         AC_LIBOBJ(function_name).
59314         * m4/chown.m4: Likewise.
59315         * m4/fnmatch.m4: Likewise.
59316         * m4/ftruncate.m4: Likewise.
59317         * m4/getgroups.m4: Likewise.
59318         * m4/getline.m4: Likewise.
59319         * m4/group-member.m4: Likewise.
59320         * m4/jm-macros.m4: Likewise.
59321         * m4/lstat.m4: Likewise.
59322         * m4/malloc.m4: Likewise.
59323         * m4/memcmp.m4: Likewise.
59324         * m4/nanosleep.m4: Likewise.
59325         * m4/putenv.m4: Likewise.
59326         * m4/realloc.m4: Likewise.
59327         * m4/regex.m4: Likewise.
59328         * m4/stat.m4: Likewise.
59329         * m4/strftime.m4: Likewise.
59330
59331 2000-07-02  Jim Meyering  <meyering@lucent.com>
59332
59333         * lib/quotearg.c (mbstate_t): Don't define here.
59334
59335 2000-07-02  Jim Meyering  <meyering@lucent.com>
59336
59337         * lib/nanosleep.c (SIGCONT): Define if not already defined.
59338
59339 2000-07-01  Jim Meyering  <meyering@lucent.com>
59340
59341         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
59342
59343 2000-07-01  Jim Meyering  <meyering@lucent.com>
59344
59345         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
59346         problem.
59347
59348 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
59349
59350         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
59351         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
59352
59353 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
59354
59355         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
59356         per change in ../m4/ls-mntd-fs.m4.
59357         (read_filesystem_list): Ignore symbolic links.
59358
59359 2000-06-29  Jim Meyering  <meyering@lucent.com>
59360
59361         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
59362         for declaration of strcmp.
59363
59364         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
59365
59366         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
59367         Avoid warning by casting result to `char *' to remove `const'.
59368
59369 2000-06-28  Jim Meyering  <meyering@lucent.com>
59370
59371         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
59372         included by quotearg.c, for which we perform this test.  From
59373         Bruno Haible.
59374
59375 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
59376
59377         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
59378         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
59379         <utmpx.h> exists, put readutmp.o into LIBOBJS.
59380
59381 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
59382
59383         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
59384
59385 2000-06-26  Paul Eggert  <eggert@twinsun.com>
59386
59387         savedir now sets errno on failure and invokes xmalloc to get memory.
59388         Fix a couple of other minor bugs while we're at it.
59389
59390         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
59391         (NAMLEN): Remove macro.
59392         (malloc, realloc): Remove decls.
59393         (stpcpy): Likewise.
59394         ("xalloc.h"): Include.
59395         (NAME_SIZE_DEFAULT): New macro.
59396         (savedir): Use xmalloc / xrealloc to allocate memory.
59397         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
59398         Skip "" directory entries.
59399         Use strlen to calculate directory entry length, since the old method
59400         is rarely used these days and isn't worth supporting.
59401         Don't use a pointer after freeing it.
59402         Check for integer overflow when calculating allocation size.
59403         Use memcpy to copy entries, instead of stpcpy.
59404         Set errno properly when returning NULL.
59405         Check for readdir error.
59406
59407 2000-06-26  Jim Meyering  <meyering@lucent.com>
59408
59409         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
59410
59411 2000-06-25  Jim Meyering  <meyering@lucent.com>
59412
59413         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
59414         Linux header bug when _XOPEN_SOURCE is defined to 500.
59415
59416 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
59417
59418         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
59419         deficiency.
59420
59421 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
59422
59423         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
59424         Include xalloc.h.
59425         Don't include <stdlib.h>.  Don't declare malloc, realloc.
59426
59427 2000-06-24  Jim Meyering  <meyering@lucent.com>
59428
59429         * m4/strerror_r.m4: Revive this file -- to try out an experimental
59430         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
59431         for which strerror does return char*, but which lacks a conveniently
59432         accessible declaration of the function.  If the compile-test says
59433         strerror_r doesn't work, then resort to a `run'-test that works on
59434         BeOS and segfaults on DEC Unix.
59435
59436 2000-06-24  Jim Meyering  <meyering@lucent.com>
59437
59438         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
59439
59440 2000-06-23  Paul Eggert  <eggert@twinsun.com>
59441
59442         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
59443         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
59444
59445 2000-06-23  Paul Eggert  <eggert@twinsun.com>
59446
59447         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
59448         (mbrtowc, mbstate_t): Define substitutes if
59449         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
59450         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
59451         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
59452
59453 2000-06-23  Jim Meyering  <meyering@lucent.com>
59454
59455         * m4/afs.m4: Add missing AC_MSG_RESULT.
59456         Reported by Bruno Haible.
59457
59458         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
59459         Suggestion from Bruno Haible.
59460
59461 2000-06-23  Jim Meyering  <meyering@lucent.com>
59462
59463         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
59464
59465 2000-06-21  Jim Meyering  <meyering@lucent.com>
59466
59467         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
59468
59469 2000-06-21  Jim Meyering  <meyering@lucent.com>
59470
59471         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
59472         (noinst_HEADERS): Add getstr.h.
59473
59474         * lib/getline.c (getstr): Move into a separate file.
59475         * lib/getstr.c (getstr): New file, extracted from getline.c, with
59476         the following changes: new parameter, delim2; both delim[12]
59477         parameters have type `int', not `char'.  The latter would lose
59478         with 8-bit delimiters.
59479         * lib/getstr.h: New file.
59480
59481 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
59482
59483         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
59484         than 1024, return a memory chunk of least possible size, instead
59485         of size PATH_MAX + 2. In the loop, increment the size proportionally.
59486         Use free/xmalloc instead of xrealloc to avoid copying for very long
59487         paths.
59488
59489 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
59490
59491         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
59492         the empty string.
59493
59494 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
59495
59496         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
59497         address, not strdup.  Include <stdlib.h> and don't declare free().
59498
59499 2000-06-19  Jim Meyering  <meyering@lucent.com>
59500
59501         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
59502
59503 2000-06-18  Jim Meyering  <meyering@lucent.com>
59504
59505         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
59506
59507         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
59508         `checking whether...' message to be consistent with that of the
59509         lstat test.
59510
59511 2000-06-18  Jim Meyering  <meyering@lucent.com>
59512
59513         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
59514         Besides, these days every porting target provides a mkdir function.
59515
59516         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
59517         needed. (this snippet comes from src/system.h).
59518
59519 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
59520
59521         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
59522
59523 2000-06-15  Paul Eggert  <eggert@twinsun.com>
59524
59525         * lib/human.c (adjust_value): New function.
59526         (human_readable_inexact): Apply rounding style even when
59527         printing approximate values.
59528
59529 2000-06-14  Paul Eggert  <eggert@twinsun.com>
59530
59531         * lib/human.c (human_readable_inexact): Allow an input block
59532         size that is not a multiple of the output block size, and vice versa.
59533         Reported by Piergiorgio Sartor.
59534
59535 2000-06-14  Paul Eggert  <eggert@twinsun.com>
59536
59537         * lib/getdate.y (get_date): Apply relative times after time
59538         zone indicator, not before.  Reported by Todd A. Jacobs.
59539
59540 2000-06-13  Jim Meyering  <meyering@lucent.com>
59541
59542         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
59543
59544         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
59545
59546 2000-06-12  Paul Eggert  <eggert@twinsun.com>
59547
59548         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
59549
59550 2000-06-12  Jim Meyering  <meyering@lucent.com>
59551
59552         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
59553         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
59554         optional argument.
59555         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
59556         the optional argument, `lib'.
59557
59558 2000-06-08  Jim Meyering  <meyering@lucent.com>
59559
59560         * m4/largefile.m4: Remove file (now that it's part of autoconf).
59561
59562 2000-06-04  Paul Eggert  <eggert@twinsun.com>
59563
59564         Rewrite largefile configuration so that we don't need to run
59565         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
59566         AC_CANONICAL_HOST in configure.in -- jmm]
59567
59568         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
59569         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
59570         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
59571         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
59572         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
59573         All uses changed.
59574         Instead of inspecting the output of getconf, try to compile the
59575         test program without and with the macro definition.
59576         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
59577         for getconf.  Instead, check for the needed flags by compiling
59578         test programs.
59579
59580 2000-06-04  Paul Eggert  <eggert@twinsun.com>
59581
59582         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
59583
59584 2000-06-04  Jim Meyering  <meyering@lucent.com>
59585
59586         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
59587         SunOS 4.1.4 for which gid_t is an unsigned type.
59588
59589 2000-06-03  Jim Meyering  <meyering@lucent.com>
59590
59591         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
59592         now that autoconf requires that.
59593
59594         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
59595         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
59596         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
59597
59598 2000-06-03  Jim Meyering  <meyering@lucent.com>
59599
59600         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
59601
59602 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
59603
59604         * m4/glibc21.m4: New file.
59605         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
59606
59607 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
59608
59609         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
59610         newer, don't install charset.alias.
59611         * lib/config.charset: Change the Linux/glibc rules so they become empty
59612         on glibc-2.1 or newer.
59613
59614 2000-06-02  Jim Meyering  <meyering@lucent.com>
59615
59616         * lib/mountlist.c: Back out last change.  Instead, do this...
59617         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
59618         me_dummy member using the same `ignore'-testing code.
59619         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
59620         fs_type strings.
59621         From Mark D. Roth.
59622
59623 2000-05-29  Jim Meyering  <meyering@lucent.com>
59624
59625         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
59626         mounts with the `ignore' attribute.  Based on a patch from
59627         Mark D. Roth.
59628
59629 2000-05-28  Jim Meyering  <meyering@lucent.com>
59630
59631         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
59632         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
59633         * m4/stat.m4: Likewise.
59634         * m4/lstat.m4: Likewise.
59635         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
59636
59637         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
59638         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
59639
59640 2000-05-26  Jim Meyering  <meyering@lucent.com>
59641
59642         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
59643
59644 2000-05-24  Jim Meyering  <meyering@lucent.com>
59645
59646         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
59647         autoconf requires that.
59648         * m4/lib-check.m4: Likewise.
59649         * m4/jm-macros.m4: Likewise.
59650         * m4/strftime.m4: Likewise.
59651
59652         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
59653         AC_CHECK_DECLS, now that autoconf requires that.
59654
59655 2000-05-22  Jim Meyering  <meyering@lucent.com>
59656
59657         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
59658         * m4/lstat.m4: Likewise.
59659
59660 2000-05-22  Jim Meyering  <meyering@lucent.com>
59661
59662         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
59663
59664 2000-05-20  Jim Meyering  <meyering@lucent.com>
59665
59666         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
59667         (jm_PREREQ): Use it.
59668
59669 2000-05-18  Jim Meyering  <meyering@lucent.com>
59670
59671         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
59672         back, too, since it may have been modified by allocate_entry.
59673         (hash_delete): Rewrite to use neither the assignment operator
59674         nor the comma operator in an if-expression.
59675
59676 2000-05-15  Paul Eggert  <eggert@twinsun.com>
59677
59678         * lib/closeout.c:
59679         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
59680         Remove; no longer needed.
59681         "quotearg.h": Add include.
59682         (file_name): Do not bother to explicitly initialize to NULL; it's less
59683         efficient on some hosts.
59684         (close_stdout_status): Remove test as to whether stdout was already
59685         closed; it breaks for the case "echo x | sort >&-".
59686         Quote file name colons.
59687         Do not assume that _("write error") lacks format strings.
59688
59689 2000-05-15  Jim Meyering  <meyering@lucent.com>
59690
59691         * lib/version-etc.c (version_etc_copyright): Update the copyright
59692         string used in all --version output.
59693
59694 2000-05-14  Jim Meyering  <meyering@lucent.com>
59695
59696         * lib/closeout.c (close_stdout_set_file_name): New function.
59697         (close_stdout_status): Use new file-scoped global.
59698         Return right away if fstat says the stdout file descriptor is invalid.
59699         * lib/closeout.h (close_stdout_set_file_name): Declare.
59700
59701 2000-05-10  Jim Meyering  <meyering@lucent.com>
59702
59703         * lib/closeout.c [default_exit_status]: New file-scoped variable.
59704         (close_stdout_set_status): New function.
59705         * lib/closeout.h (close_stdout_set_status): Declare.
59706
59707 2000-05-09  Jim Meyering  <meyering@lucent.com>
59708
59709         * m4/gettext.m4: Rename this...
59710         * m4/libintl.m4: ...to this.
59711
59712 2000-05-08  Jim Meyering  <meyering@lucent.com>
59713
59714         * lib/long-options.c: Don't include closeout.h.
59715         (parse_long_options): Don't call close_stdout for --version.
59716
59717 2000-05-06  Paul Eggert  <eggert@twinsun.com>
59718
59719         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
59720         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
59721         2.1.3 bug.  This avoids a clash when files like regex.c define
59722         _GNU_SOURCE.
59723
59724 2000-05-06  Jim Meyering  <meyering@lucent.com>
59725
59726         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
59727         (AC_REPLACE_FUNCS): Add strnlen.
59728
59729         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
59730         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
59731
59732         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
59733         AC_SEARCH_LIBS call for nanosleep.
59734         (LIB_NANOSLEEP): Set and AC_SUBST.
59735
59736 2000-05-06  Jim Meyering  <meyering@lucent.com>
59737
59738         * lib/strnlen.c: Undefine __strnlen and strnlen.
59739         [!weak_alias]: Define __strnlen to strnlen.
59740
59741         * lib/atexit.c: New file, from libiberty.
59742
59743 2000-05-06  Jim Meyering  <meyering@lucent.com>
59744
59745         * lib/closeout.c (close_stdout_status): Also check for errors on the
59746         stderr stream.
59747
59748 2000-05-05  Jim Meyering  <meyering@lucent.com>
59749
59750         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
59751         AC_SEARCH_LIBS call for clock_gettime.
59752         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
59753
59754         * m4/search-libs.m4: Update from autoconf.
59755
59756         su doesn't work on Solaris 2.6.
59757         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
59758         <shadow.h>.  Reported by Dragos Harabor.
59759
59760 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
59761
59762         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
59763         memcpy instead of xmalloc, xrealloc, path_concat.
59764         (locale_charset): Treat empty environment variables as absent.
59765         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
59766
59767 2000-05-04  Jim Meyering  <meyering@lucent.com>
59768
59769         * lib/getopt.c: Update from glibc.
59770         * lib/obstack.c: Likewise.
59771         * lib/obstack.h: Likewise.
59772         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
59773         file
59774
59775         * lib/regex.h: Likewise.
59776         * lib/strndup.c: Likewise.
59777         * lib/strnlen.c: New file, from glibc.
59778
59779 2000-05-03  Jim Meyering  <meyering@lucent.com>
59780
59781         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
59782
59783 2000-05-02  Paul Eggert  <eggert@twinsun.com>
59784
59785         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
59786         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
59787         compile-time test, rather than inspecting host and OS, to
59788         decide whether to define _LARGEFILE_SOURCE.
59789
59790 2000-05-01  Jim Meyering  <meyering@lucent.com>
59791
59792         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
59793
59794         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
59795         Based on a patch from Bruno Haible.
59796
59797 2000-05-01  Jim Meyering  <meyering@lucent.com>
59798
59799         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
59800
59801 2000-04-29  Jim Meyering  <meyering@lucent.com>
59802
59803         * lib/path-concat.c: Declare strdup only if it's not defined.
59804         * lib/canon-host.c: Likewise.
59805
59806 2000-04-28  Jim Meyering  <meyering@lucent.com>
59807
59808         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
59809         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
59810         is included first, then limits.h is included by locale.h by libintl.h.
59811         From John David Anglin.
59812
59813 2000-04-25  Jim Meyering  <meyering@lucent.com>
59814
59815         * lib/makepath.c (S_IRWXUGO): Define.
59816         (make_path): Always perform explicit chmod if MODE specifies any
59817         of the `special' permission bits.  Prompted by a bug report against
59818         install from Mate Wierdl and Joost van Baal.
59819
59820 2000-04-18  Jim Meyering  <meyering@lucent.com>
59821
59822         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
59823         (jm_PREREQ): Use it.
59824
59825 2000-04-18  Jim Meyering  <meyering@lucent.com>
59826
59827         * lib/README: New file.
59828
59829         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
59830         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
59831
59832 2000-04-17  Jim Meyering  <meyering@lucent.com>
59833
59834         Get it right :-)
59835         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
59836         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
59837         Suggestion from Akim Demaille.
59838
59839 2000-04-17  Jim Meyering  <meyering@lucent.com>
59840
59841         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
59842         the definition of it to rpl_strftime also defined-away the system's
59843         declaration.
59844
59845 2000-04-15  Jim Meyering  <meyering@lucent.com>
59846
59847         Use `C' to denote so-called `contiguous' files, the same way
59848         that tar does.
59849         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
59850         (ftypelet): Use S_ISCTG.
59851         From Michael Deutschmann.
59852
59853 2000-04-14  Jim Meyering  <meyering@lucent.com>
59854
59855         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
59856         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
59857         clobbered.
59858
59859 2000-04-14  Jim Meyering  <meyering@lucent.com>
59860
59861         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
59862
59863 2000-04-13  Jim Meyering  <meyering@lucent.com>
59864
59865         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
59866         AH_VERBATIM to insert required #ifndef into config.h.in.
59867         Suggestion from Akim Demaille.
59868
59869 2000-04-12  Jim Meyering  <meyering@lucent.com>
59870
59871         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
59872         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
59873         Christian Krackowizer.
59874
59875         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
59876         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
59877         (AC_SYS_LARGEFILE): Require.
59878         (AM_C_PROTOTYPES): Require.
59879
59880 2000-04-08  Jim Meyering  <meyering@lucent.com>
59881
59882         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
59883         names don't conflict.  Reported by Eli Zaretskii.
59884
59885 2000-04-07  Jim Meyering  <meyering@lucent.com>
59886
59887         * lib/putenv.c: Move inclusion of errno.h so it follows that of
59888         sys/types.h, to work around system header problems on AIX 3.2.5.
59889         From Bruno Haible.
59890
59891 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
59892
59893         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
59894         bug.  Deal with the different error behavior of Irix iconv.
59895
59896 2000-04-05  Paul Eggert  <eggert@twinsun.com>
59897
59898         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
59899         IRIX if the installer said otherwise.
59900
59901 2000-04-05  Jim Meyering  <meyering@lucent.com>
59902
59903         Portability tweaks required for ultrix4.3.
59904         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
59905         (jm_CHECK_DECLS): Add getutent to the list of functions.
59906         (_jm_DECL_HEADERS): Add utmpx.h.
59907         From John David Anglin.
59908
59909         * m4/strftime.m4: Back out the 2000-04-02 change.
59910         Instead of that change, simply undefine putenv in the test program.
59911
59912 2000-04-05  Jim Meyering  <meyering@lucent.com>
59913
59914         Portability tweaks required for ultrix4.3.
59915         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
59916         getutent.
59917         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
59918         * lib/canon-host.c: Declare strdup.
59919         * lib/path-concat.c: Likewise.
59920         From John David Anglin.
59921
59922 2000-04-04  Jim Meyering  <meyering@lucent.com>
59923
59924         Be more DOS 8.3-friendly.
59925         * lib/ref-add.sin: Renamed from ref-add.sed.in.
59926         * lib/ref-del.sin: Renamed from ref-del.sed.in.
59927         * lib/Makefile.am: Reflect renaming.
59928         Reported by Eli Zaretskii.
59929
59930         Use a temporary file name that won't clash with `charset.alias'
59931         in the DOS 8.3 name space.
59932         * lib/Makefile.am (charset_tmp): Define.
59933         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
59934         (uninstall-local): Likewise.
59935         Reported by Eli Zaretskii.
59936
59937 2000-04-03  Jim Meyering  <meyering@lucent.com>
59938
59939         * m4/gettext.m4: Fix typo in comment.
59940
59941         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
59942         textutils/configure.in).  Suggestion from Paul Eggert.
59943         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
59944
59945 2000-04-02  Paul Eggert  <eggert@twinsun.com>
59946
59947         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
59948         variable in the shell rather than using putenv, which isn't
59949         portable.  This avoids the configure-time inter-test dependency
59950         on the potentially-renamed putenv function.
59951
59952 2000-03-30  Paul Eggert  <eggert@twinsun.com>
59953
59954         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
59955         before checking struct stat.st_blksize, so that
59956         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
59957
59958 2000-03-29  Paul Eggert  <eggert@twinsun.com>
59959
59960         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
59961         since strftime.c uses HAVE_STRFTIME to decide whether to use
59962         the underlying strftime.
59963
59964 2000-03-29  Paul Eggert  <eggert@twinsun.com>
59965
59966         * lib/time/strftime.c (my_strftime): Make sure we call the system
59967         strftime, not ourselves, when invoking the underlying strftime.
59968
59969 2000-03-24  Jim Meyering  <meyering@lucent.com>
59970
59971         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
59972         (charset_alias): Define.
59973         (install-exec-local): Factor out common code.
59974         (uninstall-local): Split lines longer than 80.
59975         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
59976         (SUFFIXES): Define.
59977         (.sed.in.sed): New rule.  Don't redirect directly to $@.
59978         (CLEANFILES): Add ref-add.sed and ref-del.sed.
59979
59980 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
59981
59982         * lib/config.charset: Output a line containing "Packages using this
59983         file".
59984         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
59985         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
59986         ref-del.sed): New rules.
59987
59988 2000-03-17  Jim Meyering  <meyering@lucent.com>
59989
59990         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
59991         Otherwise, include <strings.h>
59992
59993 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
59994
59995         * lib/unicodeio.c (utf8_wctomb): New function.
59996         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
59997         format instead of in UCS-4 with platform dependent endianness.
59998
59999 2000-03-10  Jim Meyering  <meyering@lucent.com>
60000
60001         * m4/lib-check.m4: Look for getspnam in -lgen, too.
60002         From Marco Franzen.
60003
60004 2000-03-07  Paul Eggert  <eggert@twinsun.com>
60005
60006         * lib/savedir.c (savedir): Work even if directory size is
60007         negative; this can happen with some screwy NFS configurations.
60008
60009 2000-03-06  Jim Meyering  <meyering@lucent.com>
60010
60011         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
60012         if it's NULL (because we ran out of memory).  From Bruno Haible.
60013
60014 2000-03-05  Jim Meyering  <meyering@lucent.com>
60015
60016         * lib/localcharset.c ("path-concat.h"): Include.
60017         (get_charset_aliases): Use path_concat instead of ANSI string
60018         concatenation.
60019
60020         * lib/unicodeio.h (PARAMS): Define.
60021         Use it to guard prototype.
60022
60023 2000-03-04  Jim Meyering  <meyering@lucent.com>
60024
60025         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
60026         for lib/localcharset.c.
60027
60028 2000-03-04  Jim Meyering  <meyering@lucent.com>
60029
60030         * lib/Makefile.am (install-exec-local): Create $(libdir) before
60031         installing into it.
60032         (uninstall-local): Uncomment this rule so `make distcheck' works
60033         once again.
60034
60035         * lib/unicodeio.c (<errno.h>): Include it.
60036         (errno): Declare if not defined.
60037
60038         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
60039
60040         * lib/config.charset: New version, incorporating remarks from a linux
60041         i18n mailing list.  From Bruno Haible.
60042
60043 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
60044
60045         * m4/codeset.m4: New file.
60046         * m4/iconv.m4: New file.
60047         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
60048
60049 2000-03-03  Jim Meyering  <meyering@lucent.com>
60050
60051         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
60052
60053 2000-03-02  Jim Meyering  <meyering@lucent.com>
60054
60055         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
60056         the messages come out on separate lines.
60057
60058         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
60059         rather than jm_CHECK_DECLARATIONS.
60060         * m4/decl.m4: Remove now-unused file.
60061
60062         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
60063         geteuid.
60064
60065 2000-03-02  Jim Meyering  <meyering@lucent.com>
60066
60067         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
60068
60069 2000-03-01  Jim Meyering  <meyering@lucent.com>
60070
60071         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
60072         * lib/unicodeio.c: Likewise.
60073
60074 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
60075
60076         * lib/config.charset: New file.
60077         * lib/localcharset.c: New file.
60078         * lib/unicodeio.h, lib/unicodeio.c: New files.
60079         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
60080         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
60081         (noinst_HEADERS): Add unicodeio.h.
60082         (all-local, install-exec-local, charset.alias): New targets.
60083
60084 2000-02-28  Paul Eggert  <eggert@twinsun.com>
60085
60086         * lib/quotearg.c (ALERT_CHAR): New macro.
60087         (quotearg_buffer_restyled): Use it.
60088
60089 2000-02-27  Jim Meyering  <meyering@lucent.com>
60090
60091         * m4/check-decl.m4: Add getenv to the list.
60092
60093 2000-02-27  Jim Meyering  <meyering@lucent.com>
60094
60095         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
60096         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
60097
60098         * lib/backupfile.c: Guard inclusion of stdlib.h with
60099         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
60100         Declare malloc if needed.
60101
60102         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
60103         `#ifndef HAVE_DECL..'
60104         now that autoconf always defines the HAVE_DECL_ symbols.
60105         * lib/human.c: Likewise.
60106         * lib/same.c: Likewise.
60107         * lib/strtoumax.c: Likewise.
60108
60109         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
60110         declaration check was not run.
60111         * lib/hash.c: Likewise.
60112         * lib/human.c: Likewise.
60113         * lib/same.c: Likewise.
60114         * lib/strtoumax.c: Likewise.
60115
60116         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
60117         `.', then first look up the entire `.'-containing string as a login
60118         name.
60119
60120 2000-02-23  Jim Meyering  <meyering@lucent.com>
60121
60122         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
60123         in place of my hack.
60124
60125 2000-02-18  Paul Eggert  <eggert@twinsun.com>
60126
60127         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
60128         (textint): New typedef.
60129         (parser_control): Member year changed from int to textint.
60130         All uses changed.
60131         (YYSTYPE): Removed; replaced by %union with int and textint members.
60132         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
60133         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
60134         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
60135         (tSNUMBER, tUNUMBER): Now of type <textintval>.
60136         (date, number, to_year): Use width of number in digits, not its value,
60137         to determine whether it's a 2-digit year, or a 2-digit time.
60138         (yylex): Store number of digits of numeric tokens.
60139         Reported by John Kendall.
60140
60141         (parser_control): Changed from struct parser_control to typedef (for
60142         consistency).  All uses changed.
60143
60144         (tID): Removed; not used.
60145         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
60146
60147 2000-02-14  Paul Eggert  <eggert@twinsun.com>
60148
60149         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
60150         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
60151
60152 2000-02-12  Jim Meyering  <meyering@lucent.com>
60153
60154         * lib/userspec.c (ISDIGIT): Define it.
60155         (isdigit): Remove definition.
60156         (is_number): Use ISDIGIT, not isdigit.
60157         <libintl.h>: Include.
60158         (_ and N_): Define.
60159         (parse_user_spec): Mark translatable strings.
60160
60161 2000-02-10  Jim Meyering  <meyering@lucent.com>
60162
60163         With these changes, nanosleep.[ch] are finally enough like the other
60164         lib/* replacement files to compile on a few more losing systems.
60165
60166         * lib/nanosleep.h: Don't include config.h.
60167         Remove prototype from declaration of nanosleep.
60168         (PARAMS): Remove now-unneeded definition.
60169         * lib/nanosleep.c: #undef nanosleep.
60170         (rpl_nanosleep): Rename from nanosleep.
60171
60172 2000-02-10  Jim Meyering  <meyering@lucent.com>
60173
60174         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
60175         gnu_nanosleep to rpl_nanosleep.
60176
60177 2000-02-09  Jim Meyering  <meyering@lucent.com>
60178
60179         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
60180         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
60181
60182 2000-02-08  Akim Demaille  <akim@epita.fr>
60183
60184         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
60185         `[' and `]' and remove uses of `changequote'.
60186         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
60187         (AC_SYS_LARGEFILE): Likewise.
60188         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
60189         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
60190         of changequote.
60191         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
60192         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
60193         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
60194         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
60195
60196 2000-02-05  Jim Meyering  <meyering@lucent.com>
60197
60198         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
60199         Remove explicit use of AC_HEADER_TIME.  It is required by
60200         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
60201         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
60202         in autoconf whereby the expansion of the latter ended up preceding
60203         the expansion of its prerequisite, AC_HEADER_TIME.
60204         Reported by Volker Borchert.
60205
60206 2000-02-03  Jim Meyering  <meyering@lucent.com>
60207
60208         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
60209
60210 2000-02-03  Jim Meyering  <meyering@lucent.com>
60211
60212         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
60213         rather than with `#if HAVE_UTMPNAME'.
60214
60215 2000-02-02  Jim Meyering  <meyering@lucent.com>
60216
60217         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
60218         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
60219         Reported by Eli Zaretskii.
60220
60221 2000-02-01  Jim Meyering  <meyering@lucent.com>
60222
60223         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
60224
60225 2000-01-31  Jim Meyering  <meyering@lucent.com>
60226
60227         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
60228         functions.  Add the time.h and sys/time.h headers along with the
60229         AC_REQUIRE'ment of AC_HEADER_TIME.
60230
60231 2000-01-31  Jim Meyering  <meyering@lucent.com>
60232
60233         * lib/nanosleep.h (nanosleep): Guard declaration with
60234         `#if ! HAVE_DECL_NANOSLEEP'.
60235         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
60236         the declaration in that vendor's sys/timers.h.
60237         Reported by Christian Krackowizer.
60238
60239         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
60240         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
60241         (ISPRINT): Likewise.
60242         Reported by Tom Tromey.
60243
60244 2000-01-30  Jim Meyering  <meyering@lucent.com>
60245
60246         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
60247
60248         * m4/prereq.m4 (utmp_includes): Define.
60249         Check for ut_user and ut_name members in both struct utmpx
60250         and struct utmp.
60251
60252 2000-01-30  Jim Meyering  <meyering@lucent.com>
60253
60254         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
60255         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
60256         header files where only utmpx.ut_user is declared.
60257
60258         * lib/readutmp.h (UT_USER): Define.
60259
60260 2000-01-29  Jim Meyering  <meyering@lucent.com>
60261
60262         * m4/lib-check.m4: New file containing library-related checks from
60263         fileutils and sh-utils (textutils had none).
60264
60265 2000-01-28  Jim Meyering  <meyering@lucent.com>
60266
60267         * m4/perl.m4: Change format of warning message to look more like that
60268         from the missing script.  Suggestion from François Pinard.
60269
60270 2000-01-25  Jim Meyering  <meyering@lucent.com>
60271
60272         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
60273         well as time.h in the compile check.
60274         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
60275         Fix typo in cross-compiling case: s/yes/no/.
60276
60277 2000-01-23  Jim Meyering  <meyering@lucent.com>
60278
60279         * m4/jm-macros.m4: Move df-related tests here from
60280         fileutils/configure.in
60281
60282         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
60283         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
60284
60285         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
60286         s/space/ac_fsusage_space/.
60287         (jm_FILE_SYSTEM_USAGE): Take two parameters.
60288
60289         * m4/ftruncate.m4: New file (derived from part of
60290         fileutils/configure.in).
60291         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
60292         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
60293
60294         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
60295         AC_SUBST these here, rather than just in sh-util/configure.in, so
60296         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
60297         all the same.
60298         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
60299         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
60300         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
60301         (AC_SUBST(POW_LIBM)): Likewise.
60302         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
60303
60304 2000-01-23  Jim Meyering  <meyering@lucent.com>
60305
60306         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
60307         obstack.c.
60308
60309 2000-01-22  Jim Meyering  <meyering@lucent.com>
60310
60311         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
60312
60313         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
60314
60315         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
60316         configure.in
60317         (AC_CHECK_HEADERS): Likewise for sh-utils.
60318         (AC_CHECK_HEADERS): Likewise for textutils.
60319         Merge the three lists of headers.
60320
60321         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
60322         from fileutils' configure.in.
60323
60324         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
60325         code. Moved tests into their own function (_jm_DECL_HEADERS) in
60326         check-decl.m4.
60327
60328         * m4/check-decl.m4: Use #if rather than #ifdef.
60329         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
60330         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
60331         (_jm_DECL_HEADERS): Define new function.
60332         (jm_CHECK_DECLARATIONS): Require it.
60333
60334 2000-01-22  Jim Meyering  <meyering@lucent.com>
60335
60336         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
60337         [! HAVE_DECL_STRTOULL]: Declare strtoull.
60338         Required for some AIX systems.  Reported by Christian Krackowizer.
60339         [TESTING] (main): New function.
60340
60341         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
60342         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
60343         letters.
60344
60345         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
60346         iswprint.
60347
60348         * lib/strverscmp.c (ISDIGIT): Define.
60349         (strverscmp): Use ISDIGIT, not isdigit.
60350
60351 2000-01-19  Jim Meyering  <meyering@lucent.com>
60352
60353         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
60354         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
60355         defines `struct timespec' in <sys/time.h>
60356
60357         * m4/c-bs-a.m4: Remove uses of changequote altogether.
60358         Thanks to Akim for explaining.
60359
60360 2000-01-17  Paul Eggert  <eggert@twinsun.com>
60361
60362         * lib/nanosleep.c (nanosleep):
60363         Don't use SA_INTERRUPT to decide whether to call sigaction, as
60364         POSIX.1 doesn't require SA_INTERRUPT and some systems
60365         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
60366         it's been part of POSIX.1 since day 1 (in 1988).
60367
60368 2000-01-17  Jim Meyering  <meyering@lucent.com>
60369
60370         * lib/interlock: Remove unused file.  Reported by François Pinard.
60371
60372 2000-01-16  Paul Eggert  <eggert@twinsun.com>
60373
60374         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
60375         alert, backslash, formfeed, and vertical tab unnecessarily in
60376         shell quoting style.
60377
60378 2000-01-16  Jim Meyering  <meyering@lucent.com>
60379
60380         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
60381         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
60382         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
60383         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
60384
60385 2000-01-16  Jim Meyering  <meyering@lucent.com>
60386
60387         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
60388         because the latter didn't work.
60389
60390 2000-01-15  Jim Meyering  <meyering@lucent.com>
60391
60392         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
60393         (AC_REPLACE_FUNCS): Add memcpy and memset.
60394         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
60395         Add strpbrk.
60396         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
60397
60398 2000-01-12  Jim Meyering  <meyering@lucent.com>
60399
60400         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
60401         (jm_PREREQ): Use it.
60402         (jm_PREREQ_READUTMP): New macro.
60403         (jm_PREREQ): Use it.
60404
60405 2000-01-11  Paul Eggert  <eggert@twinsun.com>
60406
60407         Quote multibyte characters correctly.
60408         * m4/c-bs-a.m4: New file.
60409         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
60410         (jm_PREREQ): Use it.
60411
60412 2000-01-11  Paul Eggert  <eggert@twinsun.com>
60413
60414         * m4/uintmax_t.m4: Port to autoconf 2.13.
60415
60416 2000-01-08  Jim Meyering  <meyering@ascend.com>
60417
60418         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
60419         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
60420
60421 2000-01-04  Jim Meyering  <meyering@ascend.com>
60422
60423         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
60424         jm_STRUCT_DIRENT_D_TYPE.
60425         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
60426         jm_STRUCT_DIRENT_D_INO.
60427         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
60428         jm_STRUCT_UTIMBUF.
60429         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
60430         renamings.
60431         * m4/utime.m4: Likewise.
60432
60433         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
60434         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
60435
60436 2000-01-03  Paul Eggert  <eggert@twinsun.com>
60437
60438         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
60439         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
60440
60441 2000-01-02  Jim Meyering  <meyering@ascend.com>
60442
60443         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
60444         remember if this is necessary.
60445
60446 1999-12-26  Jim Meyering  <meyering@ascend.com>
60447
60448         * m4/jm-macros.m4: Use it here.
60449         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
60450
60451 1999-12-23  Jim Meyering  <meyering@ascend.com>
60452
60453         * m4/jm-macros.m4: Check for clock_gettime (moved from
60454         fileutils/configure.in)
60455         Check for gettimeofday.
60456
60457 1999-12-20  Jim Meyering  <meyering@ascend.com>
60458
60459         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
60460         autoconf-2.14a-1999-12-20.
60461
60462 1999-12-19  Jim Meyering  <meyering@ascend.com>
60463
60464         * m4/lstat-slash.m4: New file.
60465         * m4/jm-macros.m4: Use the new macro:
60466         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
60467
60468 1999-12-07  Jim Meyering  <meyering@ascend.com>
60469
60470         * m4/perl.m4: Require that File::Compare be available, too.
60471         Too many systems seem to lack it.
60472
60473         * m4/strftime.m4: Add checks for most of the cpp macros tested in
60474         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
60475
60476 1999-11-18  Paul Eggert  <eggert@twinsun.com>
60477
60478         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
60479         problem with the QNX 4.25 shell, which doesn't propagate exit
60480         status of failed commands inside shell assignments.
60481
60482 1999-11-17  Jim Meyering  <meyering@ascend.com>
60483
60484         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
60485
60486 1999-11-07  Jim Meyering  <meyering@ascend.com>
60487
60488         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
60489
60490 1999-11-06  Jim Meyering  <meyering@ascend.com>
60491
60492         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
60493         * m4/jm-macros.m4 (jm_MACROS): Use it here.
60494
60495 1999-11-05  Jim Meyering  <meyering@ascend.com>
60496
60497         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
60498         configure.in of textutils, fileutils, and sh-utils into this one
60499         (shared between those packages) file.
60500         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
60501         AC_STRUCT_ST_BLKSIZE.
60502
60503 1999-11-03  Jim Meyering  <meyering@ascend.com>
60504
60505         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
60506         of AC_CHECK_TYPE checks includes unistd.h.
60507         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
60508         Suggestion from Akim Demaille.
60509
60510 1999-10-30  Jim Meyering  <meyering@ascend.com>
60511
60512         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
60513         m4-quoted string.
60514         * m4/ls-mntd-fs.m4: Likewise.
60515         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
60516         * m4/jm-winsz1.m4: Likewise.
60517
60518         * m4/const.m4: Remove file, since the fix made it into the experimental
60519         version of autoconf.
60520         * m4/mktime.m4: Likewise.
60521
60522         * m4/check-type.m4: Remove file, now that the latest version of
60523         AC_CHECK_TYPE takes a third arg to specify additional #includes.
60524
60525         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
60526         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
60527         AC_CHECK_TYPE.
60528
60529 1999-10-04  Jim Meyering  <meyering@ascend.com>
60530
60531         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
60532
60533 1999-09-22  Paul Eggert  <eggert@twinsun.com>
60534
60535         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
60536         2.95.1 bug with HP-UX 10.20.
60537
60538 1999-09-17  Jim Meyering  <meyering@ascend.com>
60539
60540         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
60541         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
60542         due to missing strdup (against sh-utils-2.0).
60543
60544 1999-08-29  Jim Meyering  <meyering@ascend.com>
60545
60546         * m4/jm-macros.m4: Require jm_BISON.
60547         * m4/bison.m4: New file.
60548
60549 1999-08-17  Paul Eggert  <eggert@twinsun.com>
60550
60551         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
60552         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
60553
60554 1999-08-05  Jim Meyering  <meyering@ascend.com>
60555
60556         * m4/getline.m4: Rename test file from conftestdata to conftest.data
60557         to avoid conflicts with `conftest' on 8+3 filesystems.
60558         Suggestion from Eli Zaretskii.
60559
60560 1999-08-04  Jim Meyering  <meyering@ascend.com>
60561
60562         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
60563         fileutils and sh-utils (textutils's getline test was inadequate).
60564         (AM_FUNC_GETLINE): Run this test.
60565         (AC_CHECK_FUNCS): Check for getdelim.
60566         Reported by Bob Proulx.
60567
60568 1999-08-02  Jim Meyering  <meyering@ascend.com>
60569
60570         * m4/jm-macros.m4: Add a comment.
60571
60572 1999-08-01  Paul Eggert  <eggert@twinsun.com>
60573
60574         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
60575         <inttypes.h> defines strtoumax as a macro (and not as a
60576         function).
60577
60578 1999-08-01  Paul Eggert  <eggert@twinsun.com>
60579
60580         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
60581         that we can shift, multiply and divide unsigned long long
60582         values; Ultrix cc can't do it.
60583
60584 1999-08-01  Paul Eggert  <eggert@twinsun.com>
60585
60586         * m4/mktime.m4: New file, which is a preview of what should appear
60587         in the next public autoconf release.
60588
60589 1999-08-01  Paul Eggert  <eggert@twinsun.com>
60590
60591         * m4/lfs.m4: Remove this file.
60592         * m4/largefile.m4: New file.  It contains the old contents of
60593         lfs.m4, except that all names with prefix AC_LFS have been
60594         changed to use the prefix AC_SYS_LARGEFILE instead, to be
60595         compatible with future autoconf versions.  Also, some minor m4
60596         quoting problems have been fixed.
60597
60598 1999-08-01  Paul Eggert  <eggert@twinsun.com>
60599
60600         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
60601         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
60602         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
60603         and simplify the shell code.
60604
60605 1999-08-01  Jim Meyering  <meyering@ascend.com>
60606
60607         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
60608         m4.
60609
60610 1999-07-20  Jim Meyering  <meyering@ascend.com>
60611
60612         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
60613
60614 1999-07-15  Jim Meyering  <meyering@ascend.com>
60615
60616         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
60617
60618 1999-05-22  Jim Meyering  <meyering@ascend.com>
60619
60620         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
60621
60622 1999-05-20  Jim Meyering  <meyering@ascend.com>
60623
60624         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
60625         Add a colon after each `then' in case $4 is empty.
60626
60627 1999-05-16  Jim Meyering  <meyering@ascend.com>
60628
60629         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
60630
60631 1999-05-10  Jim Meyering  <meyering@ascend.com>
60632
60633         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
60634
60635         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
60636         AC_FUNC_MKTIME.
60637
60638 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
60639
60640         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
60641
60642 1999-05-04  Paul Eggert  <eggert@twinsun.com>
60643
60644         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
60645         not CPPFLAGS, so that linking works correctly in IRIX.
60646
60647 1999-04-30  Paul Eggert  <eggert@twinsun.com>
60648
60649         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
60650
60651 1999-04-20  Paul Eggert  <eggert@twinsun.com>
60652
60653         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
60654         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
60655         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
60656         jm_AC_TYPE_UNSIGNED_LONG_LONG.
60657         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
60658
60659         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
60660
60661 1999-04-20  Jim Meyering  <meyering@ascend.com>
60662
60663         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
60664         AC_REPLACE xstroull if necessary.  From Paul Eggert.
60665         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
60666
60667 1999-04-18  Jim Meyering  <meyering@ascend.com>
60668
60669         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
60670         * m4/jm-macros.m4: Use it.
60671
60672 1999-04-06  Jim Meyering  <meyering@ascend.com>
60673
60674         * m4/strftime.m4: Remove test for %f.
60675
60676 1999-03-29  Jim Meyering  <meyering@ascend.com>
60677
60678         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
60679         superset of the AC_TYPE_* checks in the textutils, fileutils,
60680         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
60681         AC_TYPE_PID_T.
60682
60683 1999-03-28  Jim Meyering  <meyering@ascend.com>
60684
60685         * m4/jm-macros.m4: Define GNU_PACKAGE here.
60686         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
60687         replaced e.g., in the *.sh files of the sh-utils.
60688
60689 1999-03-20  Jim Meyering  <meyering@ascend.com>
60690
60691         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
60692         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
60693         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
60694
60695 1999-03-19  Jim Meyering  <meyering@ascend.com>
60696
60697         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
60698
60699 1999-03-12  Jim Meyering  <meyering@ascend.com>
60700
60701         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
60702
60703 1999-03-07  Jim Meyering  <meyering@ascend.com>
60704
60705         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
60706         declared.
60707
60708 1999-02-17  Jim Meyering  <meyering@ascend.com>
60709
60710         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
60711         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
60712
60713 1999-02-07  Jim Meyering  <meyering@ascend.com>
60714
60715         * m4/group-member.m4: New file -- extracted from sh-utils'
60716         configure.in.
60717
60718         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
60719         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
60720
60721 1999-02-06  Jim Meyering  <meyering@ascend.com>
60722
60723         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
60724         * m4/fnmatch.m4: Likewise.
60725         * m4/getgroups.m4: Likewise.
60726         * m4/lstat.m4: Likewise.
60727         * m4/malloc.m4: Likewise.
60728         * m4/putenv.m4: Likewise.
60729         * m4/realloc.m4: Likewise.
60730         * m4/regex.m4: Likewise.
60731         * m4/stat.m4: Likewise.
60732         * m4/strftime.m4: Likewise.
60733         Suggestion from Alain Magloire.
60734
60735         * m4/chown.m4: Use `.$ac_objext', not `.o'.
60736         * m4/fnmatch.m4: Likewise.
60737         * m4/getgroups.m4: Likewise.
60738         * m4/getline.m4: Likewise.
60739         * m4/lstat.m4: Likewise.
60740         * m4/malloc.m4: Likewise.
60741         * m4/memcmp.m4: Likewise.
60742         * m4/putenv.m4: Likewise.
60743         * m4/realloc.m4: Likewise.
60744         * m4/regex.m4: Likewise.
60745         * m4/stat.m4: Likewise.
60746         * m4/strftime.m4: Likewise.
60747         Suggestion from Alain Magloire.
60748
60749         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
60750         an argument.
60751
60752         * m4/regex.m4: Add a run-time Test for proper operation of
60753         re_compile_pattern.
60754
60755 1999-01-31  Jim Meyering  <meyering@ascend.com>
60756
60757         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
60758
60759 1999-01-30  Jim Meyering  <meyering@ascend.com>
60760
60761         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
60762
60763         * m4/jm-mktime.m4: Make this a wrapper around the official
60764         AM_FUNC_MKTIME rather than my private copy, now that the official one
60765         is up to date.
60766         * m4/mktime.m4: Remove file.
60767
60768         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
60769         * m4/uptime.m4: Likewise.
60770         * m4/uintmax_t.m4: Likewise.
60771
60772 1999-01-28  Jim Meyering  <meyering@ascend.com>
60773
60774         * m4/jm-macros.m4: Use jm_AFS.
60775         * m4/afs.m4: New file (from fileutils' configure.in).
60776
60777         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
60778         * m4/chown.m4: Likewise.
60779         * m4/d-ino.m4: Likewise.
60780         * m4/d-type.m4: Likewise.
60781         * m4/fnmatch.m4: Likewise.
60782         * m4/getgroups.m4: Likewise.
60783         * m4/gettext.m4: Likewise.
60784         * m4/jm-mktime.m4: Likewise.
60785         * m4/jm-winsz2.m4: Likewise.
60786         * m4/lcmessage.m4: Likewise.
60787         * m4/ls-mntd-fs.m4: Likewise.
60788         * m4/malloc.m4: Likewise.
60789         * m4/memcmp.m4: Likewise.
60790         * m4/putenv.m4: Likewise.
60791         * m4/realloc.m4: Likewise.
60792         * m4/st_mtim.m4: Likewise.
60793         * m4/strftime.m4: Likewise.
60794
60795 1999-01-16  Jim Meyering  <meyering@ascend.com>
60796
60797         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
60798         (ARGMATCH_DIE_DECL): Define.
60799
60800 1999-01-12  Jim Meyering  <meyering@ascend.com>
60801
60802         * m4/Makefile.am.in: Rewrite to avoid using fmt.
60803         Reported by Lars Hecking.
60804
60805 1999-01-10  Jim Meyering  <meyering@ascend.com>
60806
60807         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
60808         gross kludge.
60809         * m4/inttypes_h.m4: Likewise.
60810         * m4/lstat.m4: Likewise.
60811         * m4/malloc.m4: Likewise.
60812         * m4/readdir.m4: Likewise.
60813         * m4/realloc.m4: Likewise.
60814         * m4/st_dm_mode.m4: Likewise.
60815         * m4/stat.m4: Likewise.
60816         * m4/utimbuf.m4: Likewise.
60817         * m4/utimes.m4: Likewise.
60818
60819         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
60820         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
60821         comments in config.h.in are meaningful.
60822
60823         * m4/jm-macros.m4: Require autoconf-2.13 here.
60824
60825         * m4/regex.m4: By default, don't use the included regex.c on systems
60826         with glibc 2.  Suggestion from Uli Drepper.
60827
60828 1999-01-02  Jim Meyering  <meyering@ascend.com>
60829
60830         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
60831
60832 1998-12-18  Jim Meyering  <meyering@ascend.com>
60833
60834         * m4/Makefile.am.in (Makefile.am): Simplify rule.
60835         Based on a suggestion from Lars Hecking.
60836
60837 1998-11-16  Paul Eggert  <eggert@twinsun.com>
60838
60839         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
60840
60841 1998-11-16  Jim Meyering  <meyering@ascend.com>
60842
60843         * m4/lfs.m4: Double-quote the `uname...` expression.
60844
60845 1998-11-14  Jim Meyering  <meyering@ascend.com>
60846
60847         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
60848         * m4/stat.m4: Likewise.
60849
60850 1998-11-03  Jim Meyering  <meyering@ascend.com>
60851
60852         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
60853         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
60854
60855 1998-10-18  Jim Meyering  <meyering@ascend.com>
60856
60857         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
60858
60859 1998-10-17  Jim Meyering  <meyering@ascend.com>
60860
60861         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
60862         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
60863         calls for those previously hard-coded headers.  Instead, take a new
60864         parameter.
60865         (jm_CHECK_DECLARATIONS): Reflect interface change.
60866         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
60867         (jm_CHECK_DECL_LOCALTIME_R): New macro.
60868
60869         * m4/mktime.m4: Test for spring-forward gap before long-running test.
60870
60871 1998-10-14  Jim Meyering  <meyering@ascend.com>
60872
60873         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
60874         instead of "TZ=America/Vancouver".  From Paul Eggert.
60875
60876 1998-10-11  Jim Meyering  <meyering@ascend.com>
60877
60878         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
60879         This adds a test for a recently added compatibility fix for mktime.c.
60880         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
60881
60882 1998-09-27  Jim Meyering  <meyering@ascend.com>
60883
60884         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
60885
60886         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
60887         ../configure.in, including a change from Gordon Matzigkeit to allow
60888         cross-compiling for the Hurd.
60889
60890         * m4/glibc.m4: New file/macro to test for the GNU C Library
60891         versions 1 and 2.  From Gordon Matzigkeit.
60892         Indent.
60893
60894 1998-09-21  Jim Meyering  <meyering@ascend.com>
60895
60896         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
60897
60898 1998-08-18  Paul Eggert  <eggert@twinsun.com>
60899
60900         Port nanosecond-resolution times to UnixWare 2.1.2 and
60901         pedantic Solaris 2.6.
60902
60903         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
60904         AC_STRUCT_ST_MTIM.
60905         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
60906         Generate name of ns member, instead of just 1 or undef.
60907         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
60908
60909 1998-08-15  Jim Meyering  <meyering@ascend.com>
60910
60911         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
60912         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
60913         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
60914         instead of jm_TYPE_SSIZE_T.
60915
60916 1998-08-12  Jim Meyering  <meyering@ascend.com>
60917
60918         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
60919
60920 1998-08-02  Jim Meyering  <meyering@ascend.com>
60921
60922         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
60923         in acconfig.h manually.
60924
60925 1998-07-31  Paul Eggert  <eggert@twinsun.com>
60926
60927         * m4/st_mtim.m4: New file.
60928
60929 1998-07-28  Jim Meyering  <meyering@ascend.com>
60930
60931         * m4/utimes.m4: Undef stat.
60932
60933 1998-07-25  Jim Meyering  <meyering@ascend.com>
60934
60935         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
60936         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
60937
60938 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
60939
60940         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
60941         uid and gid actually remain unchanged.
60942
60943 1998-07-07  Jim Meyering  <meyering@ascend.com>
60944
60945         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
60946
60947 1998-07-04  Jim Meyering  <meyering@ascend.com>
60948
60949         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
60950         to prove that this macro can be used in packages without regex.c.
60951
60952 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
60953
60954         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
60955         is to be used.
60956
60957 1998-07-03  Jim Meyering  <meyering@ascend.com>
60958
60959         * m4/gettext.m4: Add -lintl if it's found to be necessary.
60960
60961         * m4/gettext.m4: New file -- from gettext-0.10.35.
60962         * m4/lcmessage.m4: Likewise.
60963         * m4/progtest.m4: Likewise.
60964
60965         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
60966         * m4/jm-macros.m4: Require the new macro.
60967
60968 1998-06-29  Jim Meyering  <meyering@ascend.com>
60969
60970         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
60971         for the definition of NGROUPS (used in a system header included
60972         by sys/mount.h).
60973
60974 1998-06-28  Jim Meyering  <meyering@ascend.com>
60975
60976         * m4/ls-mntd-fs.m4: New file.
60977         * m4/fstypename.m4: New file.
60978
60979         * m4/jm-macros.m4: Require the new macro.
60980         * m4/jm-glibc-io.m4: New file.
60981
60982 1998-05-19  Jim Meyering  <meyering@ascend.com>
60983
60984         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
60985         * m4/lchown.m4: New file.
60986
60987         * m4/Makefile.am.in: New file.
60988         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
60989
60990 1998-05-14  Jim Meyering  <meyering@ascend.com>
60991
60992         * m4/Makefile.am (EXTRA_DIST): Add them.
60993         * m4/jm-macros.m4: New file.
60994         * m4/utimbuf.m4: New file.
60995
60996 1998-05-12  Jim Meyering  <meyering@ascend.com>
60997
60998         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
60999
61000 1998-05-11  Jim Meyering  <meyering@ascend.com>
61001
61002         * m4/isc-posix.m4: New file.
61003
61004 1998-05-10  Jim Meyering  <meyering@ascend.com>
61005
61006         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
61007
61008 1998-05-09  Jim Meyering  <meyering@ascend.com>
61009
61010         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
61011         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
61012         with automake.
61013
61014         * m4/ssize_t.m4: New file.
61015         * m4/mktime.m4: Remove file -- the new automake has this now.
61016
61017 1998-04-26  Jim Meyering  <meyering@ascend.com>
61018
61019         * m4/assert.m4: New file.
61020         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
61021
61022 1998-04-05  Jim Meyering  <meyering@ascend.com>
61023
61024         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
61025         (jm_PREREQ): Use it here.
61026
61027 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
61028
61029         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
61030         in acconfig.h.
61031
61032 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
61033
61034         * m4/prereq.m4: New file.
61035         * m4/error.m4: New file.
61036         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
61037
61038 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
61039
61040         * m4/getline.m4: Don't set am_cv_func_working_getline before the
61041         cache-check for the same variable -- that defeated the purpose of
61042         the test; the test program was never run.  This was a problem only
61043         on systems with losing getline functions -- HP-UX 10.20 is one.
61044         Reported by Bjorn Helgaas.
61045
61046 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
61047
61048         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
61049
61050 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
61051
61052         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
61053
61054         * m4/const.m4: New file.  Use an initializer in this declaration
61055         typedef int charset[2]; const charset x;
61056         Reported by Bob Glickstein.
61057
61058 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
61059
61060         * m4/chown.m4: Fix reversed types on -1 args to chown.
61061         From Kaveh Ghazi.
61062
61063 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
61064
61065         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
61066         Add lseek and memchr.
61067
61068         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
61069         T.E.Dickey <dickey@clark.net> said that some older preprocessors
61070         have a 20-character limit on names.
61071
61072 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
61073
61074         * m4/inttypes_h.m4: New file.
61075         * m4/uintmax_t.m4: New file.
61076         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
61077
61078
61079         -----
61080
61081         Local Variables:
61082         coding: utf-8
61083         End:
61084
61085         Copyright (C) 1997-2010 Free Software Foundation, Inc.
61086
61087         Copying and distribution of this file, with or without
61088         modification, are permitted provided the copyright notice
61089         and this notice are preserved.