Re: Preprocessor log?
Re: Preprocessor log?
- Subject: Re: Preprocessor log?
- From: Eric Slosser <email@hidden>
- Date: Tue, 18 Mar 2008 00:36:14 -0400
On Mar 17, 2008, at 10:31 PM, Ken G. Brown wrote:
What is the best way to get the preprocessor to output a log of all
the #defines it is doing and what the values are at the different
points of the compile.
If the log could show the #includes as well that would be great.
short answer: use gcc's -dD option.
long answer:
- do a 'preprocess'
- in the 'build output' window, look at the commands that did the
preprocess
- copy-n-paste-n-execute the 'cd' command in a terminal window
- copy-n-paste the long command
- add "-dD" to it
- execute it
- go back to the .i file that the very first step opened
- you should see the preprocessor macros with their values,
interspersed with the pre-processed source.
see <http://gcc.gnu.org/onlinedocs/gcc-3.3.6/gcc/Preprocessor-Options.html
>, look for -dCHARS
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden