mwoehlke <[EMAIL PROTECTED]> writes: > source='xstrtoimax.c' object='xstrtoimax.o' libtool=no \ > DEPDIR=.deps depmode=tru64 /usr/bin/posix/sh ../build-aux/depcomp \ > cc -std -I. -I. -I. -I/home/install/gnu/alpha_osf/include -g -c > xstrtoimax.c > cc: Warning: ./config.h, line 1741: The redefinition of the macro > "intmax_t" conflicts with a current definition because the replacement > lists differ. The redefinition is now in effect. (macroredef) > #define intmax_t long long > -----------------^
I think I see the problem now; you can't include <config.h>, then <inttypes.h>, then <config.h>, due to <config.h> having some semi-obsolescent definitions of intmax_t (due to gettext not yet upgrading to assume inttypes.h). I installed this into gnulib to fix things: 2006-10-08 Paul Eggert <[EMAIL PROTECTED]> Don't include <config.h> twice; this doesn't work in some cases, e.g., when config.h has "#define intmax_t long long int" and we include <config.h>, <inttypes.h>, <config.h> in that order. Problem reported by Matthew Woehlke in: http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html * fprintftime.c: Don't include config.h or fprintftime.h. * fts-cycle.c: Don't include config.h. * strftime.c: Include fprintftime.h if FPRINTFTIME is defined. * xstrtoimax.c: Remove copyright notice since it's short tnow. Don't include config.h or xstrtol.h. Define STRTOL_T_MINIMUM and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib inttypes.h. * xstrtoumax.c: Likewise. * xstrtol.c: Include config.h and xstrtol.h after defining __strtol and the like, so that this module is more like its siblings. (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]: Remove; no longer needed now that we assume gnulib inttypes.h. Index: lib/fprintftime.c =================================================================== RCS file: /cvsroot/gnulib/gnulib/lib/fprintftime.c,v retrieving revision 1.2 diff -p -u -r1.2 fprintftime.c --- lib/fprintftime.c 13 Sep 2006 22:38:14 -0000 1.2 +++ lib/fprintftime.c 8 Oct 2006 07:16:11 -0000 @@ -1,5 +1,2 @@ -#include <config.h> - -#include "fprintftime.h" #define FPRINTFTIME 1 #include "strftime.c" Index: lib/fts-cycle.c =================================================================== RCS file: /cvsroot/gnulib/gnulib/lib/fts-cycle.c,v retrieving revision 1.6 diff -p -u -r1.6 fts-cycle.c --- lib/fts-cycle.c 13 Sep 2006 22:38:14 -0000 1.6 +++ lib/fts-cycle.c 8 Oct 2006 07:16:11 -0000 @@ -18,8 +18,6 @@ along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ -#include <config.h> - #include "cycle-check.h" #include "hash.h" Index: lib/strftime.c =================================================================== RCS file: /cvsroot/gnulib/gnulib/lib/strftime.c,v retrieving revision 1.90 diff -p -u -r1.90 strftime.c --- lib/strftime.c 13 Sep 2006 22:38:14 -0000 1.90 +++ lib/strftime.c 8 Oct 2006 07:16:11 -0000 @@ -30,6 +30,9 @@ # include "../locale/localeinfo.h" #else # include <config.h> +# if FPRINTFTIME +# include "fprintftime.h" +# endif #endif #include <ctype.h> Index: lib/xstrtoimax.c =================================================================== RCS file: /cvsroot/gnulib/gnulib/lib/xstrtoimax.c,v retrieving revision 1.8 diff -p -u -r1.8 xstrtoimax.c --- lib/xstrtoimax.c 13 Sep 2006 22:38:14 -0000 1.8 +++ lib/xstrtoimax.c 8 Oct 2006 07:16:11 -0000 @@ -1,32 +1,6 @@ -/* xstrtoimax.c -- A more useful interface to strtoimax. - - Copyright (C) 2001, 2003, 2004, 2006 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2, or (at your option) - any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software Foundation, - Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ - -/* Cloned by Jim Meyering. */ - -#include <config.h> - -#include "xstrtol.h" - #define __strtol strtoimax #define __strtol_t intmax_t #define __xstrtol xstrtoimax -#ifdef INTMAX_MAX -# define STRTOL_T_MINIMUM INTMAX_MIN -# define STRTOL_T_MAXIMUM INTMAX_MAX -#endif +#define STRTOL_T_MINIMUM INTMAX_MIN +#define STRTOL_T_MAXIMUM INTMAX_MAX #include "xstrtol.c" Index: lib/xstrtol.c =================================================================== RCS file: /cvsroot/gnulib/gnulib/lib/xstrtol.c,v retrieving revision 1.40 diff -p -u -r1.40 xstrtol.c --- lib/xstrtol.c 13 Sep 2006 22:38:14 -0000 1.40 +++ lib/xstrtol.c 8 Oct 2006 07:16:11 -0000 @@ -19,10 +19,6 @@ /* Written by Jim Meyering. */ -#include <config.h> - -#include "xstrtol.h" - #ifndef __strtol # define __strtol strtol # define __strtol_t long int @@ -31,6 +27,10 @@ # define STRTOL_T_MAXIMUM LONG_MAX #endif +#include <config.h> + +#include "xstrtol.h" + /* Some pre-ANSI implementations (e.g. SunOS 4) need stderr defined if assertion checking is enabled. */ #include <stdio.h> @@ -44,19 +44,6 @@ #include "intprops.h" -#ifndef STRTOL_T_MINIMUM -# define STRTOL_T_MINIMUM TYPE_MINIMUM (__strtol_t) -# define STRTOL_T_MAXIMUM TYPE_MAXIMUM (__strtol_t) -#endif - -#if !HAVE_DECL_STRTOIMAX && !defined strtoimax -intmax_t strtoimax (); -#endif - -#if !HAVE_DECL_STRTOUMAX && !defined strtoumax -uintmax_t strtoumax (); -#endif - static strtol_error bkm_scale (__strtol_t *x, int scale_factor) { Index: lib/xstrtoumax.c =================================================================== RCS file: /cvsroot/gnulib/gnulib/lib/xstrtoumax.c,v retrieving revision 1.12 diff -p -u -r1.12 xstrtoumax.c --- lib/xstrtoumax.c 13 Sep 2006 22:38:14 -0000 1.12 +++ lib/xstrtoumax.c 8 Oct 2006 07:16:11 -0000 @@ -1,32 +1,6 @@ -/* xstrtoumax.c -- A more useful interface to strtoumax. - - Copyright (C) 1999, 2003, 2004, 2006 Free Software Foundation, Inc. - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2, or (at your option) - any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software Foundation, - Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ - -/* Written by Paul Eggert. */ - -#include <config.h> - -#include "xstrtol.h" - #define __strtol strtoumax #define __strtol_t uintmax_t #define __xstrtol xstrtoumax -#ifdef UINTMAX_MAX -# define STRTOL_T_MINIMUM 0 -# define STRTOL_T_MAXIMUM UINTMAX_MAX -#endif +#define STRTOL_T_MINIMUM 0 +#define STRTOL_T_MAXIMUM UINTMAX_MAX #include "xstrtol.c" _______________________________________________ Bug-coreutils mailing list Bug-coreutils@gnu.org http://lists.gnu.org/mailman/listinfo/bug-coreutils