0

I am trying to install gcc-2.7.2 after reading the requirements for installing Festival here. On my workstation, I have gcc 4.4.1 installed. I am running into problems while running make. Here is how I am running make:

make |& tee make.log

The error message is as follows:

decl.c: In function ‘push_class_level_binding’:
decl.c:3606: error: lvalue required as increment operand 

The offending line from decl.c is: obstack_ptr_grow (&decl_obstack, x);

The above function returns void. A look at the function definition in the file obstack.h shows:

#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 *));              \
   if (!__o->alloc_failed)                      \
     *((void **)__o->next_free)++ = ((void *)datum);            \
   (void) 0; })

There is only one increment operation happening here. I am not sure how to change it to make the error go away. Or am I looking in the wrong place?

Any help is most welcome.

P.S: Please let me know in case more information is needed.

Sriram
  • 10,298
  • 21
  • 83
  • 136
  • 1
    Don't do that. Try to compile your code with a recent GCC. If needed, patch teh Festival code. But 2.7.2 is a crappy compiler w.r.t. recent GCC 4.6 compiler. – Basile Starynkevitch Nov 16 '11 at 08:49
  • I did. And ended up with this: http://stackoverflow.com/questions/8122478/declaration-of-void-abort-throws-different-exceptions - I tried pretty much everything and finally thought of re-installing a compiler that the Festival guys themselves suggest. – Sriram Nov 16 '11 at 08:51
  • You can edit their code, and at least remove the -pedantic flag. – Basile Starynkevitch Nov 16 '11 at 08:54
  • @Sriram: If the Festival folks suggest 2.7.2, their project would be completely abandoned for some reason. In fact, the [festival folks themselves say they support gcc 4.5](http://www.cstr.ed.ac.uk/projects/festival/download.html). So, if you experience problems like in the other post, go ahead **and report them in the upstream**. This means the Festival developers. They have a contact page for good reason. – thiton Nov 16 '11 at 10:21
  • @thiton: That has to be a major D-OH! moment for me.. You are right, the gcc 2.7.2 version is for festival 1.4 while the version I have installed is 2.1 - which is also compatible with gcc 4.4. The docs that they have put up are for festival 1.4 (and they seem most complete and are returned as most relevant in search results). Since this seems like a non-question, I will delete this unless you want to make your comment into an answer.. – Sriram Nov 16 '11 at 14:11
  • @Sriram: You might save someone a similar d'oh moment if we leave this question undeleted :-). – thiton Nov 16 '11 at 14:14
  • Haha! Ok... I will leave this as is. Thanks for your reply. – Sriram Nov 16 '11 at 14:26

1 Answers1

1

If the Festival folks suggest 2.7.2, their project would be completely abandoned for some reason. In fact, the festival folks themselves say they support gcc 4.5. So, if you experience problems like in the other post, go ahead and report them in the upstream.

thiton
  • 35,651
  • 4
  • 70
  • 100