__STDC__?

__STDC__?

Post by Ron Hardi » Mon, 07 Jul 2003 19:10:03



Is there a way to get cc to set __STDC__?
--
Ron Hardin

On the internet, nobody knows you're a jerk.

 
 
 

__STDC__?

Post by Paul Pluzhniko » Tue, 08 Jul 2003 03:02:45



> Is there a way to get cc to set __STDC__?

Yes: use 'xlc' instead, or add '-qlanglvl=ansi' ...

Cheers,
--
In order to understand recursion you must first understand recursion.

 
 
 

1. Why are lots of typedefs not defined unless __STDC__ == 0 on Solaris 2.6?

I've been working on a program to display process trees dynamically to
work non-suid for Solaris 2.6 and up. I've been getting compiler
errors with egcs (the only compiler I have and have tried) because
lots of typedefs are missing such as for sigset_t and uint64_t (used
by "sys/procfs.h").

In /usr/include/sys/int_types.h we have
#if __STDC__ - 0 == 0 && !defined(_NO_LONGLONG)
typedef unsigned long long      uint64_t;
#endif

Looking at /usr/include/sys/signal.h we have:

#if defined(__EXTENSIONS__) || (__STDC__ - 0 == 0) || ...

Actually, the C-Preprocssor logic for sigset_t in sys/signal.h is
so complicated that I really have a hard time pinpointing why it is
not defined, other than knowing that you can #define __EXTENSIONS__ or
#define __STDC__ 0 and that will work.

Anyway, the question is what are the various meanings of the values of
__STDC__? Is this documented somewhere?

2. sockd proxy server woes

3. __STDC__ - Can I undef ?

4. LILO Hangs system

5. Why are lots of typedefs not defined unless __STDC__ == 0 on 2.6?

6. Solaris for DEC Alpha?

7. why isn't __STDC__ being defined?

8. Forte 5.3 linking questions