strange error!

Discussion in 'C Programming' started by Sheldon, Nov 6, 2006.

  1. Sheldon

    Sheldon Guest

    Good day,

    I came across this error during compilation of my program:
    *******************************************
    cc -g -I/local_disk/opt/HLHDF/0_49/include -I/usr/include -c
    msgpps_functions.c
    In file included from /usr/include/stdio.h:34,
    from msgpps_functions.c:10:
    /usr/lib/gcc-lib/i586-mandrake-linux-gnu/3.3.2/include/stddef.h:213:
    error: syntax error before "typedef"
    make: *** [msgpps_functions.o] Error 1
    *******************************************

    What is strange is that I have not edited the standard library at all
    so what can give me an error in the standard library?

    Any ideas?

    Thanks

    /Sheldon
     
    Sheldon, Nov 6, 2006
    #1
    1. Advertising

  2. Sheldon

    BRG Guest

    Sheldon wrote:
    > Good day,
    >
    > I came across this error during compilation of my program:
    > *******************************************
    > cc -g -I/local_disk/opt/HLHDF/0_49/include -I/usr/include -c
    > msgpps_functions.c
    > In file included from /usr/include/stdio.h:34,
    > from msgpps_functions.c:10:
    > /usr/lib/gcc-lib/i586-mandrake-linux-gnu/3.3.2/include/stddef.h:213:
    > error: syntax error before "typedef"
    > make: *** [msgpps_functions.o] Error 1
    > *******************************************
    >
    > What is strange is that I have not edited the standard library at all
    > so what can give me an error in the standard library?
    >
    > Any ideas?


    I would look at any defines that occur before the standard headers are
    included.

    A define that conflicts with the names of standard types such as, for
    example:

    #define size_t

    can make a subsequent type definition in a standard header illegal.

    Brian Gladman
     
    BRG, Nov 6, 2006
    #2
    1. Advertising

  3. Sheldon

    Sheldon Guest

    BRG wrote:
    > Sheldon wrote:
    > > Good day,
    > >
    > > I came across this error during compilation of my program:
    > > *******************************************
    > > cc -g -I/local_disk/opt/HLHDF/0_49/include -I/usr/include -c
    > > msgpps_functions.c
    > > In file included from /usr/include/stdio.h:34,
    > > from msgpps_functions.c:10:
    > > /usr/lib/gcc-lib/i586-mandrake-linux-gnu/3.3.2/include/stddef.h:213:
    > > error: syntax error before "typedef"
    > > make: *** [msgpps_functions.o] Error 1
    > > *******************************************
    > >
    > > What is strange is that I have not edited the standard library at all
    > > so what can give me an error in the standard library?
    > >
    > > Any ideas?

    >
    > I would look at any defines that occur before the standard headers are
    > included.
    >
    > A define that conflicts with the names of standard types such as, for
    > example:
    >
    > #define size_t
    >
    > can make a subsequent type definition in a standard header illegal.
    >
    > Brian Gladman


    Fantastic Brian,
    You are a genius!
    It was a letter that at the very beginning of the file. One of things
    that happen when you think that are writing in the active window.

    Much obliged!

    /Sheldon
     
    Sheldon, Nov 6, 2006
    #3
  4. Sheldon

    BRG Guest

    Sheldon wrote:
    > BRG wrote:
    >> Sheldon wrote:
    >>> Good day,
    >>>
    >>> I came across this error during compilation of my program:
    >>> *******************************************
    >>> cc -g -I/local_disk/opt/HLHDF/0_49/include -I/usr/include -c
    >>> msgpps_functions.c
    >>> In file included from /usr/include/stdio.h:34,
    >>> from msgpps_functions.c:10:
    >>> /usr/lib/gcc-lib/i586-mandrake-linux-gnu/3.3.2/include/stddef.h:213:
    >>> error: syntax error before "typedef"
    >>> make: *** [msgpps_functions.o] Error 1
    >>> *******************************************
    >>>
    >>> What is strange is that I have not edited the standard library at all
    >>> so what can give me an error in the standard library?
    >>>
    >>> Any ideas?

    >> I would look at any defines that occur before the standard headers are
    >> included.
    >>
    >> A define that conflicts with the names of standard types such as, for
    >> example:
    >>
    >> #define size_t
    >>
    >> can make a subsequent type definition in a standard header illegal.
    >>
    >> Brian Gladman

    >
    > Fantastic Brian,
    > You are a genius!


    Sadly not, just someone who has been bitten by the same problem :-(

    Brian Gladman
     
    BRG, Nov 6, 2006
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Panic
    Replies:
    2
    Views:
    5,458
    Marc Guardiani
    Oct 24, 2003
  2. kwaj
    Replies:
    1
    Views:
    442
    Egbert Molenkamp
    Mar 7, 2004
  3. Jan
    Replies:
    2
    Views:
    1,480
    Mike Treseler
    Dec 16, 2004
  4. Harvey Twyman
    Replies:
    8
    Views:
    587
    August Derleth
    Oct 25, 2003
  5. Sam
    Replies:
    2
    Views:
    158
    Bob Barrows [MVP]
    Nov 16, 2007
Loading...

Share This Page