Eric Blake [Tue, 11 Jul 2006 12:58:27 +0000 (12:58 +0000)]
* modules/fdl: New module, to install doc/fdl.texi.
* MODULES.html.sh: Add new section for documentation modules.
* gnulib-tool: Avoid space-tab.
(--doc-base): New option, to manage files from doc.
Paul Eggert [Tue, 11 Jul 2006 06:02:51 +0000 (06:02 +0000)]
* backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
Ignore the obsolescent !HAVE_DIRENT_H case. Consolidate NAMLEN
macros into the GNU _D_EXACT_NAMLEN.
* savedir.c: Likewise.
(savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
* backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
* savedir.m4:
Ignore the obsolescent !HAVE_DIRENT_H case. Consolidate NAMLEN
macros into the GNU _D_EXACT_NAMLEN.
Paul Eggert [Tue, 11 Jul 2006 03:30:49 +0000 (03:30 +0000)]
* stdint.m4 (gl_STDINT_H): Like yesterday's change to
absolute-header.m4. Also, set ABSOLUTE_STDINT_H to a string
"no/such/file/stdint.h" when there is no such file, so that
the resulting C code can be parsed by dodgy compilers.
Problems reported by Bob Proulx.
Paul Eggert [Mon, 10 Jul 2006 04:37:09 +0000 (04:37 +0000)]
* absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
around the absolute name, to work around a problem with the HP-UX
11.23 native C compiler, reported by Bob Proulx.
Jim Meyering [Sun, 9 Jul 2006 10:18:17 +0000 (10:18 +0000)]
* lib/argp-pv.c: Remove a doubled word in a comment.
* lib/check-version.c (check_version): Likewise.
* lib/javacomp.c (compile_java_class): Likewise.
* m4/glob.m4: Likewise.
Paul Eggert [Sun, 9 Jul 2006 03:31:53 +0000 (03:31 +0000)]
* gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
for the benefit of people using Autoconf 2.60. If you want to
support older Autoconf versions you can copy m4/onceonly_2_57.m4
(or m4/onceonly.m4, if pre-2.57) manually.
Simon Josefsson [Fri, 7 Jul 2006 07:37:16 +0000 (07:37 +0000)]
2006-07-06 Jim Hyslop <jhyslop@dreampossible.ca> (tiny change)
* lib/getaddrinfo.c: Changes to compile under MSVC6: changed
'#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
brackets. Other minor changes to suppress some compiler
warnings.
Paul Eggert [Thu, 6 Jul 2006 23:29:27 +0000 (23:29 +0000)]
* lib/getloadavg.c: Use __VMS, not VMS.
* lib/getopt.c: Likewise.
* lib/getpagesize.h: Likewise.
* lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while and
probably does not work.
* lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
Don't worry about this obsolete case any more.
(HAVE_DIR): Remove. All uses removed; we now assume you can read
directories.
* lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
worry about this obsolete case any more.
* lib/fts.c: Likewise.
* lib/getcwd.c: Likewise.
* lib/glob.h: Likewise.
* lib/savedir.c: Likewise.
* m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
of invoking obsolescent AC_HEADER_DIRENT macro.
* m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
* m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
* m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
* m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
* m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
* m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
* m4/savedir.m4 (gl_SAVEDIR): Likewise.
* m4/readdir.m4: Remove; no longer needed.
Paul Eggert [Thu, 6 Jul 2006 22:16:59 +0000 (22:16 +0000)]
* _inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
with only one argument, for Autoconf 2.60.
* fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
expand to nothing, so add a shell command to avoid syntax error.
* getpass.m4 (gl_PREREQ_GETPASS): Likewise.
Paul Eggert [Wed, 5 Jul 2006 23:35:19 +0000 (23:35 +0000)]
* lib/memcasecmp.c: Include <limits.h>.
(memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
* lib/strtod.c (strtod): Don't assume isspace works on negative chars.
Don't assume isdigit succeeds only on '0' through '9'.
* lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
All uses of is_space replaced by isspace.
* lib/fnmatch.c (ISASCII): Remove; no longer needed. All uses removed.
(ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
(ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed. All uses
replaced by isprint etc.
* lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
* lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
* lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
* lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
* lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
* lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
Paul Eggert [Tue, 4 Jul 2006 07:38:59 +0000 (07:38 +0000)]
* absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
to the absolute name, not just one, to bypass Sun C 5.8's
"warning: #include of /usr/include/... may be non-portable".
Paul Eggert [Tue, 4 Jul 2006 06:37:09 +0000 (06:37 +0000)]
* m4/absolute-header.m4: Renamed from full-header-path.m4.
This is to keep the terminology clean; POSIX talks about
"absolute pathnames", not "full pathnames", but the GNU
Coding Standards say to use "path" for something else;
so use "absolute" to keep both sides happy.
(gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
Set gl_absolute_header, not gl_full_header_path.
Set gl_cv_absolute_<header>, not gl_full_path_<header>.
Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
All uses changed.
Paul Eggert [Sun, 2 Jul 2006 09:12:28 +0000 (09:12 +0000)]
* stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
both are 64 bits, since this seems to be the tradition, and this
prevents gcc -Wformat from warning about usages with PRIuMAX. If
we ever run into a host that prefers long long to long in this
case, we'll need another configure-time test.
Paul Eggert [Sun, 2 Jul 2006 06:49:07 +0000 (06:49 +0000)]
Simplification rewrite for stdint module.
* modules/inttypes (Depends-on): No longer depends on stdint.
* modules/stdint (Description): Say more about assumptions.
Say that the fast types might differ. Say macros are used.
(Files): Remove m4/size_max.m4, m4/wchar_t.m4. Add m4/longlong.m4.
(Makefile.am): Revise list of substituted symbols to match
new stdint.m4.
* modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
(configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
* tests/test-stdint.c (verify_same_types)
[! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
the code conforms to C99/C89.
Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
* lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
possible collision with system files.
(<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
__STDC_CONSTANT_MACROS)]: Do not include, since we don't need
WCHAR_MIN and WCHAR_MAX in this case.
(<stddef.h>): Do not include; no longer needed.
(<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
(defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
(<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
!@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
&& (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
(__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
__c99]: Define, to work around IRIX <stdint.h> incompatibility.
(@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
!defined(__c99))]: Include in this case too, since it's harmless
now.
(<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
dangerous to do so.
(@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
@HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
(_STDINT_MIN, _STDINT_MAX): New macros.
(int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
(uint64_t, int_least8_t, uint_least8_t, int_least16_t):
(uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
(uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
(uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
(uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
macros, not typedefs; this simplifies things quite a bit.
Use long int for all types narrower than int64_t.
(intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
Define in terms of long long int or int64_t or long int,
not int64_t or int32_t. This saves some compile-time testing.
(INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
(INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
(UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
(INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
(INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
(INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
(INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
(UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
(INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
(INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
(PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
(SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
undef any previous version and define our own version, for
simplicity and consistency with the new macros for types.
(PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
(SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
Simplify definitions by using _STDINT_MIN and _STDINT_MAX
where appropriate. Rely on new symbols @PTRDIFF_T_SUFFIX@,
@SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
@WINT_T_SUFFIX@ to keep things simple here.
(UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
Simplify by assuming typical 8/16/32/64 host, since we're
already doing that elsewhere anyway.
Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
and assume long long int is 64 bits if available. This
speeds up 'configure'.
* m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
but fix a bug, by requiring at least 64 bits.
* m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
* m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
AC_TYPE_LONG_LONG_INT. This macro is obsolete and will go soon.
* m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
* m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
changes. Make 2.59 a prerequisite. Check and substitute for
HAVE_LONG_LONG_INT. Rely on Autoconf to check for stdint.h and
inttypes.h. Do not use special include files; just use the
defaults. Check for sys/inttypes.h and sys/bitypes.h in the usual
way now. Remove no-longer-needed tests for HAVE_LONG_64BIT,
HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
WINT_MAX. Check for C99 conformance more strictly, by detecting
bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9. On the other hand do
not check for things that C99 does not require, e.g., int8_t. If
a test isn't needed unless <stdint.h> isn't working, and is
unlikely to be needed for any other reason, then don't do it
unless <stdint.h> isn't working. Do not check for ptrdiff_t or
size_t, since we assume C89 freestanding at least. Do not check
for sig_atomic_t, wchar_t, or wint_t, since the code now does
the right thing even if the types are not defined. Instead use:
(gl_STDINT_TYPE_PROPERTIES): New macro.
(gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove. Don't bother
testing whether <sys/types.h> clashes, as Autoconf does this for
us now. All uses removed.
(gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
(gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
(gl_CHECK_TYPE_SAME):
Remove; no longer needed.
(gl_STDINT_BITSIZEOF): Don't bother to check whether the type
exists, since we'll return 0 anyway in that case.
(gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.