[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gcl-devel] [axiom] Uppercase CONST bug in /usr/include/bfd.h

From: root
Subject: Re: [Gcl-devel] [axiom] Uppercase CONST bug in /usr/include/bfd.h
Date: Thu, 13 Jun 2002 23:40:03 -0400

I fetched the latest CVS from the source you gave me.
The build fails with:

gcc -pipe -fwritable-strings  -DVOL=volatile -I/home/gcl3/o -fsigned-char -c 
-O4 -I../gcl-tk -I../h/ -O  main.c  
In file included from ../h/gclincl.h:95,
                 from ../h/include.h:36,
                 from main.c:38:
/usr/include/bfd.h:344: parse error before `CONST'
/usr/include/bfd.h:344: warning: no semicolon at end of struct or union
/usr/include/bfd.h:348: syntax error before `char'
/usr/include/bfd.h:349: parse error before `}'
/usr/include/bfd.h:349: warning: data definition has no type or storage class

The source of the problem is that /usr/include/bfd.h has an uppercase
CONST in several definitions. The first example happens at line 344, thus:

typedef struct _symbol_info
  symvalue value;
  char type;
  CONST char *name;            /* Symbol name.  */
  unsigned char stab_type;     /* Stab type.  */
  char stab_other;             /* Stab other.  */
  short stab_desc;             /* Stab desc.  */
  CONST char *stab_name;       /* String for stab type.  */
} symbol_info;

In order to fix this I added the following lines at the top of h/gclincl.h:

/* 20020613000 tpd fix uppercase CONST in /usr/include/bfd.h */
#define CONST const

Once that happened the build worked fine. 

Since gclincl.h is a generated file this is clearly NOT the correct
solution. However, I'm unfamiliar with the configure scripts so I
can't recommend a change there.

Thanks for your help.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]