gcl-devel
[Top][All Lists]
Advanced

[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: Camm Maguire
Subject: Re: [Gcl-devel] [axiom] Uppercase CONST bug in /usr/include/bfd.h
Date: 14 Jun 2002 11:14:33 -0400

Greetings, and thanks for this report!

Hmm, here is what I have on my Debian machine:

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;


intech19:~/src/dtcp1/src$ dpkg -l binutils-dev
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Installed/Config-files/Unpacked/Failed-config/Half-installed
|/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: uppercase=bad)
||/ Name              Version           Description
+++-=================-=================-==================================================
ii  binutils-dev      2.11.92.0.10-3    The GNU binary utilities (BFD 
development files)
intech19:~/src/dtcp1/src$ 


What binutils version are you using?  If it is widespread, could
certainly add a #define CONST const in gclincl.h.in to be used
automatically, I'd think, with little/no consequences.

Take care,


root <address@hidden> writes:

> I fetched the latest CVS from the source you gave me.
> The build fails with:
> 
> .....(snip).....
> 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
> .....(snip).....
> 
> 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.
> Tim
> 
> 

-- 
Camm Maguire                                            address@hidden
==========================================================================
"The earth is but one country, and mankind its citizens."  --  Baha'u'llah



reply via email to

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