Hi all,

I just tried do an MSP430 build of GCC 3.2.3 on a Fedora Core 4 machine. Fedora Core 4 uses GCC 4.0. It seems GCC 4.0 refuses to build GCC 3.2.3, saying there is a syntax error. The following patch makes it compile, and it seems to work OK. I haven't tested very thoroughly, though.

Has anyone else experienced this problem?

Regards,
Steve


--- gcc-3.2.3/include/obstack.h 2001-03-15 03:44:38.000000000 +0800
+++ gcc-3.2.3.patched/include/obstack.h 2005-08-21 19:57:04.000000000 +0800
@@ -421,11 +421,12 @@
# define obstack_ptr_grow(OBSTACK,datum)                               \
__extension__                                                          \
({ struct obstack *__o = (OBSTACK);                                    \
   if (__o->next_free + sizeof (void *) > __o->chunk_limit)            \
     _obstack_newchunk (__o, sizeof (void *));                         \
-   *((void **)__o->next_free)++ = ((void *)datum);                     \
+   *((void **)__o->next_free) = ((void *)datum);                       \
+   __o->next_free += sizeof(void *);                                   \
   (void) 0; })

# define obstack_int_grow(OBSTACK,datum)                               \
__extension__                                                          \
({ struct obstack *__o = (OBSTACK);                                    \


Reply via email to