Thread (6 messages) flat view 6 messages, 3 authors, 2016-06-15

Re: [PATCH] Support SPARSE in Makefile, better SPARSE_FLAGS

From: "H. Peter Anvin" <hpa@zytor.com>
Date: 2016-06-15 22:42:07

Pavel Roskin wrote:
I hate to say that, but a better alternative is to fix sparse to act
like the native compiler by default (possibly with options to imitate
other architectures or to be fully arch-neutral).
$(CC) $(CFLAGS) -E -dM -x c /dev/null -o builtin.h

... will output a file containing all the buildin macros that you can 
feed to sparse with -include.

Replacing -x c with, say, -x c++ gives you the builtins for C++; 
including $(CFLAGS) gives the appropriate set of macros for any 
particular combination of options (which can affect the builtin macro set.)

	-hpa
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help