Re: sigset_t and gcc

From: Chris Dollin (kers_at_hpl.hp.com)
Date: 11/26/03


Date: Wed, 26 Nov 2003 15:20:47 +0000

Jade Fox wrote:

> Can anybody tell me what is wrong with the following code?
> It compiles ok with 'gcc file.c',
> but not 'gcc -ansi file.c' or 'gcc -std=c99 file.c'.
> It complains that 'sigset_t' is undeclared.
> What options am I missing? Thanks
>
> #include <signal.h>
>
> int main()
> {
> sigset_t set;
> }

I'd hypothesise that sigset_t is not in the ISO standards for C.

<fx:peek/>

Can't see it in C90.

Perhaps it's POSIX.

-- 
Chris "electric hedgehog" Dollin
C FAQs at: http://www.faqs.org/faqs/by-newsgroup/comp/comp.lang.c.html
C welcome: http://www.angelfire.com/ms3/bchambless0/welcome_to_clc.html


Relevant Pages

  • Re: self-confidence of compiler
    ... it still complains at: ... int main ... gcc, aCC, and Digital Mars all complain in some fashion about ... uninitialized variables if you set the warning level high enough. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: weird behaviour by gcc
    ... > void function ... > int main ... > Is something wrong with gcc or am I missing on some knowledge here.... ...
    (comp.lang.c)
  • missing $ operand number in format
    ... int main ... Although this code works, when I compiled it with -Wall, gcc produces a warning ... about "missing $ operand number in format". ...
    (comp.os.linux.development.apps)
  • strange feature... or bug
    ... or am i missing something obvious (btw i've tested with gcc on ... latest Tiger OS X and linux); or should i post to gcc? ... int main ...
    (comp.lang.c)
  • sigset_t and gcc
    ... It compiles ok with 'gcc file.c', ... It complains that 'sigset_t' is undeclared. ... int main ...
    (comp.lang.c)