From: Alexey Dobriyan Date: Tue, 23 Jan 2007 18:30:14 +0000 (+0300) Subject: [MIPS] There is no __GNUC_MAJOR__ X-Git-Tag: v2.6.20-rc6~1^2~7 X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=48c35b2d245fffedadce62769aafea8ecf493d19;p=~emulex%2Finfiniband.git [MIPS] There is no __GNUC_MAJOR__ Gcc major version number is in __GNUC__. As side effect fix checking with sparse if sparse was built with gcc 4.1 and mips cross-compiler is 3.4. Sparse will inherit version 4.1, __GNUC__ won't be filtered from "-dM -E -xc" output, sparse will pick only new major, effectively becoming gcc version 3.1 which is unsupported. Signed-off-by: Alexey Dobriyan Signed-off-by: Ralf Baechle --- diff --git a/arch/mips/Makefile b/arch/mips/Makefile index d1b026a0337..c68b5d3e5d1 100644 --- a/arch/mips/Makefile +++ b/arch/mips/Makefile @@ -623,7 +623,7 @@ LDFLAGS += -m $(ld-emul) ifdef CONFIG_MIPS CHECKFLAGS += $(shell $(CC) $(CFLAGS) -dM -E -xc /dev/null | \ - egrep -vw '__GNUC_(MAJOR|MINOR|PATCHLEVEL)__' | \ + egrep -vw '__GNUC_(|MINOR_|PATCHLEVEL_)_' | \ sed -e 's/^\#define /-D/' -e "s/ /='/" -e "s/$$/'/") ifdef CONFIG_64BIT CHECKFLAGS += -m64