[Bug bootstrap/38088] gcc fails to compile with undefined symbol: __LONG_LONG_MAX__ error
jakub at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Wed Nov 12 14:28:00 GMT 2008
------- Comment #3 from jakub at gcc dot gnu dot org 2008-11-12 14:27 -------
I have tested:
2008-11-12 Jakub Jelinek <jakub@redhat.com>
PR bootstrap/38088
* mcf.c (CAP_INFINITY): Use HOST_WIDE_INT maximum, not GCC specific
__LONG_LONG_MAX__.
--- gcc/mcf.c.jj 2008-09-30 16:57:11.000000000 +0200
+++ gcc/mcf.c 2008-11-12 14:05:04.000000000 +0100
@@ -56,7 +56,9 @@ along with GCC; see the file COPYING3.
#include "profile.h"
/* CAP_INFINITY: Constant to represent infinite capacity. */
-#define CAP_INFINITY __LONG_LONG_MAX__
+#define CAP_INFINITY \
+ ((HOST_WIDEST_INT) \
+ ((((unsigned HOST_WIDEST_INT) 1) << (HOST_BITS_PER_WIDEST_INT - 1)) - 1))
/* COST FUNCTION. */
#define K_POS(b) ((b))
but INTTYPE_MAXIMUM (HOST_WIDEST_INT) will work as well.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38088
More information about the Gcc-bugs
mailing list