🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gcc.help
Article #49744

Re: Outputing predefined symbols

#49744
From: Kevin Rodgers
Date: Thu, 09 Dec 1993 20:32
36 lines
1830 bytes
In article <CHouIH.9rC@candle.uucp> Bruce Momjian <root%candle.uucp@bts.com> writes:
>Is there a way under gcc 1.40 on a 386 to output the symbols predefined
>by the preprocessor/compiler, like 'unix', __386__, etc?  I know there
>was a switch under System V cc. 

This works for gcc 2.3.3:

% cp /dev/null null.c
% gcc -E -dM null.c
#define __sparc 1 
#define __sun 1 
#define sparc 1 
#define __sun__ 1 
#define __unix 1 
#define __unix__ 1 
#define sun 1 
#define __GNUC__ 2 
#define __sparc__ 1 
#define unix 1 
% gcc -ansi -E -dM null.c
#define __STRICT_ANSI__ 1 
#define __sparc 1 
#define __sun 1 
#define __sun__ 1 
#define __unix 1 
#define __unix__ 1 
#define __GNUC__ 2 
#define __sparc__ 1 

Hmmm.  I know __STDC__ is #define'd to be 1; why doesn't it show up in
this output?
-- 
Kevin Rodgers				kevin@traffic.den.mmc.com
Martin Marietta MS DC5695		(303) 971-2396 [voice] / -1666 [fax]
P.O. Box 179				"Shoulder to shoulder, we will
Denver CO 80201 USA			 Fight!  Fight!  Fight, Fight, Fight!"
Technical Details
Message-ID: <9312092026.AA02848@traffic.den.mmc.com>
Path: arc1-ca.pugleaf.net!gmd.de!Germany.EU.net!EU.net!howland.reston.ans.net!usenet.ins.cwru.edu!magnus.acs.ohio-state.edu!math.ohio-state.edu!pacific.mps.ohio-state.edu!cis.ohio-state.edu!traffic.den.mmc.com!kevin
References: <CHouIH.9rC@candle.uucp>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 11318c,e6f39d07d723f73f
X-Google-Attributes: gid11318c,public
X-Google-ArrivalTime: 1993-12-14 09:49:23 PST
Path: arc1-ca.pugleaf.net!gmd.de!Germany.EU.net!EU.net!howland.reston.ans.net!usenet.ins.cwru.edu!magnus.acs.ohio-state.edu!math.ohio-state.edu!pacific.mps.ohio-state.edu!cis.ohio-state.edu!traffic.den.mmc.com!kevin
From: kevin@traffic.den.mmc.com (Kevin Rodgers)
Newsgroups: gnu.gcc.help
Subject: Re: Outputing predefined symbols
Date: 9 Dec 1993 15:32:16 -0500
Organization: Martin Marietta Internal Information Systems (Western Region),
              Technology Support
Lines: 36
Sender: daemon@cis.ohio-state.edu
Distribution: gnu
Message-ID: <9312092026.AA02848@traffic.den.mmc.com>
References: <CHouIH.9rC@candle.uucp>